This prompt is for DevOps and platform engineering teams building AI-assisted infrastructure workflows. Use it when an AI agent or copilot proposes to create, modify, or destroy cloud resources and you need a structured, human-readable summary before execution. The prompt forces the model to surface resource details, estimated cost impact, region, tagging compliance, and security group implications in a consistent format that a human operator can approve, reject, or escalate. It is designed for pre-provisioning gates in Terraform, Pulumi, CloudFormation, or custom infrastructure pipelines.
Prompt
Infrastructure Provisioning Approval Prompt

When to Use This Prompt
Defines the operational context, ideal user, and boundaries for the Infrastructure Provisioning Approval Prompt.
Do not use this prompt for read-only queries, status checks, or actions that have already executed. It belongs at the approval step before terraform apply or equivalent, not after. The ideal user is a platform engineer embedding this prompt into a CI/CD pipeline or internal developer portal where a human must explicitly sign off on infrastructure changes. Required context includes the full plan output, the target environment, cost thresholds, and the organization's tagging and security group policies. Without this context, the model cannot produce a reliable summary.
Before wiring this into a production system, define your cost threshold for automatic escalation, your required tag schema, and your security group naming conventions. The prompt is a pre-execution gate, not a post-mortem tool. If you need to verify what already happened, use a post-action verification prompt instead. If the plan is empty or a no-op, skip this prompt entirely to avoid approval fatigue.
Use Case Fit
Where the Infrastructure Provisioning Approval Prompt works, where it fails, and the operational conditions required for safe production use.
Good Fit: Pre-Provisioning Gate
Use when: an AI agent or operator is about to create, modify, or destroy cloud resources via Terraform, Pulumi, or direct API calls. Guardrail: the prompt must run and receive explicit human confirmation before the provisioning tool is invoked.
Bad Fit: Real-Time Autoscaling
Avoid when: latency-sensitive autoscaling events require sub-second decisions. A human-in-the-loop summary step introduces unacceptable delay. Guardrail: use this prompt for planned changes only; autoscaling should rely on pre-approved metric thresholds.
Required Inputs
Risk: missing fields produce an incomplete summary that fails to surface critical cost or security implications. Guardrail: enforce required inputs (resource type, region, tags, estimated cost) in the application harness before the prompt is assembled. Reject the request if mandatory fields are absent.
Operational Risk: Cost Threshold Breach
Risk: a provisioning request that silently exceeds a budget threshold. Guardrail: the harness must evaluate the estimated cost against a pre-defined limit. If breached, escalate to a finance or engineering lead before presenting the confirmation prompt.
Operational Risk: Missing Compliance Tags
Risk: resources created without mandatory compliance tags (e.g., data-classification, cost-center) bypass audit controls. Guardrail: the prompt must explicitly list all required tags and flag any missing ones. The harness should block provisioning if a required tag is absent.
Operational Risk: Security Group Over-Permission
Risk: a proposed security group rule opens access too broadly (e.g., 0.0.0.0/0 on sensitive ports). Guardrail: the summary must highlight the effective ingress/egress rules. The harness should run a policy check and escalate wide-open rules for a secondary security review.
Copy-Ready Prompt Template
A copy-ready prompt for generating a pre-provisioning summary of cloud infrastructure changes before execution.
This prompt template is designed to be pasted directly into your AI orchestration layer. It instructs the model to act as a pre-provisioning gate, generating a structured summary of a planned infrastructure change. The summary must be approved by a human before any actual provisioning API calls are made. The template uses square-bracket placeholders that your application must replace with live data from your Infrastructure as Code (IaC) plan, CI/CD pipeline, or ticketing system.
textYou are an infrastructure compliance reviewer. Before any cloud resource is provisioned, you must generate a concise, human-readable summary of the planned action. Your summary will be the final checkpoint before execution. Do not proceed with the action itself. Generate a pre-provisioning summary based on the following inputs: [PLANNED_RESOURCES]: A detailed list of cloud resources to be created, modified, or destroyed, including their types, names, and configurations. [ESTIMATED_MONTHLY_COST]: The projected monthly cost impact of this change. [DEPLOYMENT_REGION]: The target cloud region (e.g., us-east-1). [RESOURCE_TAGS]: A key-value map of all tags that will be applied to the resources. [SECURITY_GROUP_CHANGES]: A description of any new or modified security group rules, including open ports and CIDR ranges. [CHANGE_REASON]: The business justification or ticket ID for this provisioning request. Structure your output precisely as follows: **Provisioning Summary** * **Intent:** A one-sentence summary of the change. * **Resources:** A bulleted list of each resource, its type, and its purpose. * **Cost Impact:** The [ESTIMATED_MONTHLY_COST], with a flag if it exceeds the $[COST_THRESHOLD] monthly threshold. * **Compliance Check:** * **Region:** Confirm the [DEPLOYMENT_REGION] is an approved region. * **Tags:** Verify all mandatory tags from the list [MANDATORY_TAG_KEYS] are present. Flag any missing tags. * **Security:** Highlight any security group rules that open port 22 (SSH) or 3389 (RDP) to 0.0.0.0/0 as a critical risk. * **Approval Required:** State clearly that explicit human approval is required to proceed. If any compliance check fails, add a final section titled **BLOCKING ISSUES** and list each failure. The provisioning must not proceed until all blocking issues are resolved.
To adapt this template, replace the square-bracket placeholders with data from your infrastructure pipeline. For example, [PLANNED_RESOURCES] should be populated by parsing your Terraform plan or CloudFormation change set. The [COST_THRESHOLD] and [MANDATORY_TAG_KEYS] variables should be injected from a central policy configuration. After the summary is generated, your application harness must parse the output, check for the **BLOCKING ISSUES** section, and either halt the pipeline or route the summary to a human approval queue. Never allow the model to directly call a provisioning API.
Prompt Variables
Inputs required by the Infrastructure Provisioning Approval Prompt to produce a reliable pre-provisioning summary. Each placeholder must be populated by the application harness before the prompt is sent.
| Placeholder | Purpose | Example | Validation Notes |
|---|---|---|---|
[PROVISIONING_REQUEST] | The raw request describing the infrastructure to provision, including resource types, counts, and intended purpose. | Provision 3 t3.medium EC2 instances in us-east-1 for the new checkout service. | Must be a non-empty string. If the request is ambiguous, the harness should route to an Ambiguous Intent Clarification prompt before this one. |
[TARGET_ACCOUNT_ID] | The cloud account ID where resources will be provisioned. Used to verify the correct billing and security context. | 123456789012 | Must match the regex ^\d{12}$. If null or invalid, the workflow must halt and request the correct account ID. |
[COST_BUDGET_THRESHOLD] | The maximum estimated monthly cost allowed before the request requires an additional financial approval step. | 500.00 | Must be a positive float. The harness must parse the model's estimated cost output and compare it to this value. If exceeded, route to a Financial Transaction Summary and Approval Prompt. |
[REQUIRED_TAGS] | A list of mandatory tags that must be applied to all resources for compliance, cost allocation, and ownership tracking. | ["env:production", "team:checkout", "cost-center:eng-42"] | Must be a valid JSON array of strings. The harness must check the model's output for the presence of all required tags. Missing tags should trigger a Missing Information Interruption Prompt. |
[SECURITY_GROUP_POLICY] | A description of the organization's security group rules, such as restrictions on open ingress or required CIDR block formats. | No 0.0.0.0/0 ingress allowed. All SSH access must be restricted to the bastion host security group. | Must be a non-empty string. The harness should instruct the model to flag any proposed security group that violates this policy. The eval must check for a violation flag in the output. |
[REGION_CONSTRAINTS] | A list of allowed or disallowed cloud regions based on data residency, latency, or service availability requirements. | ["us-east-1", "us-west-2"] | Must be a valid JSON array of strings. The harness must verify that the region in the model's output is present in this list. If not, the output is invalid and requires a retry or escalation. |
[APPROVAL_ROUTING_RULES] | A definition of which roles or individuals must approve the provisioning request based on cost, risk, or resource type. | {"cost_gt_1000": ["engineering-manager", "vp-infra"], "default": ["sre-oncall"]} | Must be a valid JSON object. The harness must parse the model's risk and cost assessment and use these rules to determine the approval queue. If no rule matches, escalate to a human operator. |
Implementation Harness Notes
How to wire the Infrastructure Provisioning Approval Prompt into a secure, auditable application workflow.
The Infrastructure Provisioning Approval Prompt is not a standalone artifact; it is a gate within a larger orchestration pipeline. The harness should treat the LLM call as a structured summary generator whose output is then validated, logged, and presented to a human reviewer before any provisioning API is invoked. The core principle is that the model proposes, the system validates, and a human decides. The harness must therefore enforce a strict separation between the read-only generation of the summary and the write-enabled execution of the plan.
Begin by constructing the prompt with the required variables: [PLAN_DETAILS] (the raw Terraform plan, Pulumi preview, or equivalent diff), [COST_ESTIMATE] (a structured cost breakdown), [COMPLIANCE_TAGS] (a list of required tags like data-classification or environment), and [SECURITY_GROUP_RULES] (the proposed network changes). The harness should call the model with temperature=0 to maximize deterministic output and request a strict JSON schema for the response, including fields like resources_to_create, estimated_monthly_cost, missing_compliance_tags, and security_risk_summary. On receiving the response, the system must not trust it blindly. Implement a post-generation validation layer that programmatically checks: (1) the JSON schema is valid, (2) the estimated_monthly_cost does not exceed a pre-configured [COST_THRESHOLD], and (3) the missing_compliance_tags array is empty. If any of these checks fail, the workflow must branch to an automatic rejection or an escalated review queue, not to the provisioning step.
For high-risk environments, the harness should integrate with a change management system like ServiceNow or Jira. After validation passes, the generated summary is formatted into a ticket or approval request containing the full LLM output, a unique plan_id, and a deep link to the raw execution plan. The human reviewer's decision—approve or reject—must be captured as a structured event with a timestamp, user ID, and optional justification. Only upon receiving an explicit approval signal should the harness invoke the downstream provisioning tool (e.g., terraform apply or a cloud SDK call). Log every step: the raw prompt, the model's raw response, the validation results, the approval ticket ID, and the final human decision. This audit trail is essential for post-deployment reviews and security investigations.
When choosing a model, prefer one with strong JSON mode and instruction-following capabilities. If using a model that does not support strict JSON mode, implement a retry loop with a repair prompt that feeds validation errors back to the model for correction. Set a maximum of 2 retries before escalating to a human operator with the malformed output. Finally, never pass raw cloud credentials in the prompt context. The harness should inject resource identifiers and configuration summaries, not secrets. The LLM's role is to summarize risk and compliance posture, not to generate or execute the final Terraform configuration.
Expected Output Contract
Validate the structure and content of the pre-provisioning summary before it is presented for human approval. Each field must pass the defined rule before the approval workflow proceeds.
| Field or Element | Type or Format | Required | Validation Rule |
|---|---|---|---|
provisioning_summary_id | string (UUID v4) | Must match UUID v4 regex. Reject if null or malformed. | |
resources_to_create | array of objects | Array must not be empty. Each object must contain 'resource_type', 'region', and 'estimated_cost' fields. | |
estimated_total_cost | object | Must contain 'amount' (number) and 'currency' (string). 'amount' must be >= 0. Reject if negative. | |
cost_threshold_breach | boolean | Must be true if estimated_total_cost.amount exceeds [COST_THRESHOLD]. Reject if mismatch detected. | |
compliance_tags | array of strings | Must contain all tags from [REQUIRED_TAGS]. Reject if any required tag is missing. | |
security_group_implications | array of objects | Each object must include 'rule_description' (string) and 'risk_level' (enum: low, medium, high). Reject if 'risk_level' is 'high' and no explicit justification is present. | |
rollback_plan | string | Must be non-empty and contain the substring 'rollback' or 'revert'. Reject if length < 50 characters. | |
approval_required | boolean | Must be true if cost_threshold_breach is true or any security_group_implications has risk_level 'high'. Reject if false under these conditions. |
Common Failure Modes
What breaks first when generating infrastructure provisioning summaries and how to guard against it.
Silent Cost Threshold Breaches
What to watch: The model generates a summary that omits or miscalculates the estimated monthly cost, or fails to flag that the cost exceeds a defined budget threshold. This leads to sticker-shock bills. Guardrail: Implement a post-generation validation step that extracts the cost estimate from the output, compares it against a pre-defined [MAX_BUDGET] variable, and blocks the summary from proceeding to human review if the threshold is breached without an explicit overage warning.
Missing Compliance and Security Tags
What to watch: The generated summary fails to include required compliance tags (e.g., data_classification, encryption_required) or security group implications, creating a false sense of security for the human approver. Guardrail: Define a strict [REQUIRED_TAGS] schema in the prompt. Use a simple output validator that checks for the presence and non-null values of these specific keys before the summary is presented. If missing, trigger a retry or auto-reject the summary.
Hallucinated Resource Names and Regions
What to watch: The model invents plausible-sounding but non-existent resource names, instance types, or deploys to an incorrect region not specified in the input context. Guardrail: Constrain the prompt to only use resource identifiers and regions from the provided [CONTEXT] block. Add an eval that cross-references every generated resource name and region against the original input to detect fabrications before the summary reaches a human.
Ambiguous or Missing Rollback Plan
What to watch: The summary describes the "happy path" provisioning steps but provides a vague or entirely absent rollback plan, leaving operators with no clear path to reverse a failed deployment. Guardrail: The prompt must explicitly request a "Rollback Steps" section. A post-generation check should verify this section is present and contains at least one concrete, imperative action (e.g., "Run terraform destroy") rather than generic advice.
Ignoring Implicit Dependencies
What to watch: The summary lists resources in isolation, failing to note that a database cannot be created before its network or that a load balancer depends on a target group that hasn't been provisioned yet. Guardrail: Include a [DEPENDENCY_MAP] variable in the prompt harness. Instruct the model to generate a "Provisioning Order" section that explicitly sequences resource creation based on these dependencies, and flag any circular dependencies for human review.
Overly Technical or Jargon-Filled Summaries
What to watch: The summary is written in dense, low-level infrastructure-as-code jargon, making it unreadable for the security or compliance stakeholders who must also approve it. Guardrail: Add a [SUMMARY_AUDIENCE] variable to the prompt (e.g., "DevOps Lead and CISO"). Instruct the model to include a high-level "Business Impact" section that explains the change in plain language, translating technical details into risk and cost implications.
Evaluation Rubric
Criteria for testing the Infrastructure Provisioning Approval Prompt before deployment. Each row defines a pass standard, a failure signal, and a test method to catch regressions early.
| Criterion | Pass Standard | Failure Signal | Test Method |
|---|---|---|---|
Cost Threshold Breach Detection | Prompt output explicitly flags when estimated monthly cost exceeds [COST_THRESHOLD] and blocks auto-approval | Output omits cost estimate, states cost is within threshold when it is not, or fails to escalate | Run with a test payload where estimated cost is 150% of [COST_THRESHOLD]; assert escalation flag is true and approval status is blocked |
Missing Compliance Tags | Prompt output lists all required compliance tags from [REQUIRED_TAGS] and marks any missing tags as a blocking issue | Output states all tags are present when one or more required tags are missing from the request | Run with a test payload missing a required tag from [REQUIRED_TAGS]; assert missing tag is listed and approval is blocked |
Security Group Exposure | Prompt output describes inbound/outbound rules and flags any rule with 0.0.0.0/0 CIDR as a high-risk finding | Output fails to mention a wide-open security group rule or classifies it as low risk | Run with a test payload that includes a security group rule with source 0.0.0.0/0; assert high-risk flag is present in the summary |
Region Compliance | Prompt output confirms the requested region is in [ALLOWED_REGIONS] or blocks approval with the disallowed region named | Output approves provisioning in a region outside [ALLOWED_REGIONS] without flagging it | Run with a test payload specifying a region not in [ALLOWED_REGIONS]; assert output blocks approval and names the disallowed region |
Resource Inventory Completeness | Prompt output lists every resource type and count from the request; no resource is silently dropped | Output omits one or more resource types present in the input payload | Run with a test payload containing three distinct resource types; assert all three appear in the summary output |
Rollback Plan Presence | Prompt output includes a non-empty rollback plan section with at least one concrete rollback step | Rollback plan section is missing, contains only generic placeholder text, or is empty | Run with any valid test payload; assert the output contains a rollback plan field with length greater than 50 characters |
Approval Decision Clarity | Prompt output returns a single, unambiguous approval decision: approved, blocked, or needs_review | Output returns contradictory signals, multiple conflicting decisions, or no decision field | Run with three test payloads (clean, over-threshold, missing-tag); assert each returns exactly one decision value from the allowed enum |
Output Schema Validity | Prompt output parses successfully against [OUTPUT_SCHEMA] with all required fields present and correctly typed | Output is missing required fields, contains fields with wrong types, or fails JSON parse | Validate output against [OUTPUT_SCHEMA] using a schema validator; assert zero validation errors for five varied test payloads |
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Adapt This Prompt
How to adapt\nAdd strict JSON schema validation, cost estimation via tool call, retry logic on parse failure, and structured logging. Wire the prompt into a CI/CD or chatbot harness that blocks execution until a human approves the summary. Include eval cases for cost threshold breaches, missing tags, and security group over-permissioning.\n\n### Prompt snippet\n`You are an infrastructure provisioning reviewer. Generate a pre-provisioning summary as valid JSON matching [OUTPUT_SCHEMA]. Include: resources to create, estimated cost from the pricing tool, region, required tags, security group implications, and a risk assessment. Flag any cost above [COST_THRESHOLD] or missing [REQUIRED_TAGS]. Do not execute.\n\nRequest: [INFRA_REQUEST]\nCurrent State: [CURRENT_INFRA_STATE]`\n\n### Watch for\n- Silent format drift when model changes versions\n- Missing human review step before automated execution\n- Cost estimation tool returning stale or incorrect pricing

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us