This prompt is for compliance and data engineering teams building AI-assisted workflows that handle regulated data. Its job is to generate a structured, human-readable summary of a planned data deletion operation before any destructive action executes. The summary must capture what data will be deleted, the retention policy justification, affected systems, irreversibility warnings, and required stakeholder approvals. Use this prompt when the cost of a wrong deletion is high, when regulatory frameworks like GDPR or HIPAA require documented review, or when deletion requests must be routed through multiple approval layers.
Prompt
Data Deletion Pre-Action Summary Prompt

When to Use This Prompt
Defines the job-to-be-done, ideal user, and operational boundaries for the Data Deletion Pre-Action Summary Prompt.
The prompt assumes that the deletion scope, policy references, and system inventory are provided as input variables and that a separate verification step confirms backup integrity before the summary is routed for human sign-off. In a production harness, this means the prompt should never be the sole gate. The application layer must first validate that a recent, successful backup exists for the target data and attach that evidence to the prompt's input context. The generated summary then becomes the payload for a multi-stakeholder approval queue, where designated reviewers confirm the intent, scope, and compliance justification before any DELETE, DROP, or PURGE command is issued.
Do not use this prompt for low-risk, non-regulated data cleanup where a simple confirmation dialog is sufficient. It is over-engineered for clearing a cache, removing a test user, or pruning logs past a standard retention window. Reserve it for irreversible actions on production data subject to legal hold, data subject access requests (DSARs), or retention schedules that require human judgment. If the deletion scope is fully deterministic and pre-approved by policy, replace this summary prompt with an automated, policy-enforced deletion job that logs its actions without blocking on human review.
Use Case Fit
Where the Data Deletion Pre-Action Summary Prompt works, where it fails, and the operational preconditions required before putting it into production.
Good Fit: Regulated Data Lifecycle Management
Use when: You are deleting PII, PHI, or PCI data and need a human-readable checkpoint before execution. Guardrail: The prompt excels when the harness enforces multi-stakeholder approval routing and attaches backup verification evidence to the summary.
Bad Fit: Real-Time Streaming Deletion
Avoid when: Deletion requests must be processed in milliseconds without human latency. Guardrail: This prompt is designed for a human-in-the-loop review queue. For low-latency, non-sensitive cleanup, use an automated retention policy without the summary step.
Required Inputs: Source of Truth Verification
What to watch: The prompt hallucinates affected systems or retention justifications if it lacks a data catalog. Guardrail: The harness must inject a structured [DATA_INVENTORY] and [RETENTION_POLICY] context block. Never rely on the model's parametric knowledge of your internal systems.
Operational Risk: Irreversibility Blind Spots
What to watch: The summary may downplay the permanence of the deletion or omit soft-delete/recycle-bin options. Guardrail: The prompt template must include a hardcoded [IRREVERSIBILITY_WARNING] section. The eval harness should fail any output that does not explicitly state that the action cannot be undone.
Operational Risk: Stakeholder Routing Gaps
What to watch: The summary is generated but sent only to the requester, bypassing Data Protection Officers (DPO) or legal. Guardrail: The application logic must parse the [AFFECTED_SYSTEMS] output and dynamically route approval to the owners of those systems, not just the prompt's author.
Variant: Dry-Run Mode
Use when: You need to test the deletion logic without executing it. Guardrail: Adapt the prompt to generate a 'Simulated Deletion Report' that identifies the same affected records and systems but explicitly states 'DRY RUN: NO DATA DELETED' in the summary header.
Copy-Ready Prompt Template
A copy-ready prompt that generates a structured pre-action summary for a data deletion request, formatted for a human approval queue.
The following prompt template is designed to be wired directly into an application's approval workflow. It takes a deletion request and its surrounding context and produces a structured summary that a human reviewer can quickly assess. The prompt is engineered to be descriptive and analytical, not executive; it must not execute any deletion, call any tool, or make any irreversible change. Its sole job is to create a clear, auditable checkpoint.
textYou are a compliance-focused pre-action summarizer. Your output is a structured summary for a human approval queue. You do not execute deletions. You do not call tools. You only produce the summary. Generate a Data Deletion Pre-Action Summary using the following inputs: [REQUEST_DETAILS] [REQUESTOR_IDENTITY] [DATA_CLASSIFICATION] [REGULATORY_POLICY] [RETENTION_RULES] [BACKUP_VERIFICATION_STATUS] [AFFECTED_SYSTEMS] [ROLLBACK_PLAN] # OUTPUT_SCHEMA Return a single JSON object with the following fields. Do not include any text outside the JSON. { "summary_id": "string, a unique identifier for this summary", "status": "string, always set to 'PENDING_APPROVAL'", "requestor": { "identity": "string, from [REQUESTOR_IDENTITY]", "on_behalf_of": "string or null" }, "deletion_target": { "data_description": "string, a clear, non-technical description of the data to be deleted", "data_classification": "string, from [DATA_CLASSIFICATION]", "affected_systems": ["list of strings, from [AFFECTED_SYSTEMS]"], "volume_estimate": "string, e.g., '150 records' or '2.3 GB'" }, "policy_justification": { "regulatory_basis": "string, from [REGULATORY_POLICY]", "retention_rule_applied": "string, from [RETENTION_RULES]", "policy_compliant": "boolean, your assessment based on provided rules" }, "risk_assessment": { "irreversibility_warning": "string, a clear statement that this action is permanent", "backup_verified": "boolean, from [BACKUP_VERIFICATION_STATUS]", "rollback_plan_summary": "string, from [ROLLBACK_PLAN]", "risk_level": "string, one of: 'LOW', 'MEDIUM', 'HIGH', 'CRITICAL'" }, "required_approvals": [ { "role": "string, e.g., 'Data Owner', 'Compliance Officer'", "justification": "string, why this role is required" } ], "generated_at": "string, ISO 8601 timestamp" } # CONSTRAINTS - If [BACKUP_VERIFICATION_STATUS] is false, set risk_level to 'CRITICAL' and add a note in the irreversibility_warning. - If [DATA_CLASSIFICATION] is 'PII', 'PHI', or 'PCI', always require 'Compliance Officer' and 'Data Protection Officer' in required_approvals. - Do not hallucinate any details not present in the input variables. - If any required input is missing or 'UNKNOWN', set the corresponding output field to null and add a flag "input_missing": true to the root object.
To adapt this template, replace the bracketed variables with data from your application's context. The [REQUEST_DETAILS] should be a natural-language description of the deletion request. The other variables are expected to be pre-resolved by your application logic before the prompt is assembled. The output is strict JSON, making it trivial to parse in your approval pipeline. The constraints section encodes critical business logic—such as forcing a 'CRITICAL' risk level when backups aren't verified—directly into the prompt, reducing the chance of a misleading summary reaching a reviewer.
Prompt Variables
Inputs the Data Deletion Pre-Action Summary Prompt needs to work reliably. Validate these before calling the model. Missing or malformed variables will cause the summary to be incomplete, which blocks the approval gate and prevents safe execution.
| Placeholder | Purpose | Example | Validation Notes |
|---|---|---|---|
[DELETION_TARGET] | Identifies the specific data resource, table, or record set to be deleted | user_profiles.pii_data WHERE retention_date < '2022-01-01' | Must be a non-empty string. Validate against a known resource catalog. Reject if the target is a full production database without a WHERE clause. |
[RETENTION_POLICY_REF] | The specific policy clause or regulation that justifies the deletion | GDPR Art.17 Right to Erasure; Internal Policy RET-104 | Must match an active policy ID in the governance registry. If null, the harness must block execution and request a valid policy citation. |
[AFFECTED_SYSTEMS] | List of downstream systems, backups, and replicas impacted by the deletion | ['primary-db-prod', 'replica-analytics', 'backup-s3-eu-west'] | Must be a non-empty array of system identifiers. Validate each ID against the CMDB. If a known system is missing, flag for human review. |
[BACKUP_VERIFICATION_ID] | Evidence that a verified backup exists before deletion proceeds | backup-job-8842-20250327-verified | Must be a non-null string. Validate the backup ID is in a COMPLETED state and has passed integrity checks within the last 24 hours. Block if verification is stale or missing. |
[IRREVERSIBILITY_WARNING] | A pre-approved statement confirming the action cannot be undone | This deletion is permanent and cannot be recovered from backups after the retention window expires. | Must be a non-empty string. Compare against a library of approved warning templates. If the warning is custom, route for legal review before the prompt runs. |
[APPROVAL_ROUTING_LIST] | Ordered list of roles or individuals who must approve before execution | ['data_protection_officer', 'engineering_lead', 'compliance_auditor'] | Must be a non-empty array. Validate each role against the current on-call and authorization matrix. Reject if a required role is missing for the data classification level. |
[DATA_CLASSIFICATION_LEVEL] | The sensitivity tier of the data being deleted | PII-Sensitive | Must match an enum from the data classification policy: ['Public', 'Internal', 'Confidential', 'PII-Sensitive', 'PHI-Regulated']. Block if the level is 'PHI-Regulated' and no legal hold check has been performed. |
[DRY_RUN_RESULT] | Output from a dry-run deletion query confirming the scope and count of affected records | Matched 12,450 rows across 3 partitions. No lock contention detected. | Must be a non-null string containing a record count. Parse the count and block if it exceeds the threshold defined in the deletion policy without executive approval. |
Implementation Harness Notes
How to wire the Data Deletion Pre-Action Summary Prompt into a production application with validation, routing, and audit controls.
This prompt is the first stage in a multi-step deletion workflow. It should never be the final gate. The harness must treat the model's output as a structured summary for human review, not as an executable command. Wire the prompt into an application layer that receives a deletion request, assembles the required context (data inventory, retention policies, affected systems, backup status), calls the model, validates the output against a strict schema, and then routes the summary to the correct approval queue based on the data classification and risk level detected in the response.
Validation and Schema Enforcement: Before the summary reaches a human, validate the model's JSON output against a defined schema. Required fields include deletion_scope (list of data categories), affected_systems (list of system identifiers), retention_policy_justification (string), irreversibility_warning (string), backup_verification_status (enum: verified | unverified | not_applicable), and risk_level (enum: low | medium | high | critical). If the output fails schema validation, retry the prompt once with the validation error injected into the [CONSTRAINTS] block. If it fails again, escalate to a human operator with the raw output and error details. Do not proceed with an invalid summary. For critical risk deletions, the harness must require multi-stakeholder approval (e.g., Data Protection Officer and Engineering Lead) before any deletion action is queued.
Routing and Audit Trail: Use the risk_level and affected_systems fields from the validated summary to route the approval request. A deletion touching production databases with PII and a critical risk level should follow a different approval path than a deletion of stale logs from a staging environment. The harness must log the full prompt, the validated summary, the reviewer's identity, the approval timestamp, and any override justification into an immutable audit store. This audit trail is the primary evidence for compliance reviews. The deletion action itself should be executed by a separate, permissioned service that verifies the approval record exists before proceeding. The prompt's job is to create clarity and accountability; the harness's job is to enforce the rules that keep the organization safe.
Expected Output Contract
Fields, format, and validation rules for the model's JSON response. Use this contract to validate the summary before routing it to the approval queue.
| Field or Element | Type or Format | Required | Validation Rule |
|---|---|---|---|
deletion_summary | object | Top-level object must contain all required child fields. Schema validation required. | |
deletion_summary.request_id | string (UUID v4) | Must match the [REQUEST_ID] input exactly. Parse check. | |
deletion_summary.data_subject | string | Must be a non-empty string. Must match the [DATA_SUBJECT] input. | |
deletion_summary.affected_systems | array of objects | Array must contain at least 1 item. Each item must have 'system_name' (string) and 'record_count' (integer >= 0). | |
deletion_summary.retention_policy_justification | string | Must be a non-empty string. Must reference the [RETENTION_POLICY] input or state 'No policy override required'. | |
deletion_summary.backup_verification | object | Must contain 'verified' (boolean) and 'verification_timestamp' (ISO 8601 string). If 'verified' is false, approval must be blocked. | |
deletion_summary.irreversibility_warning | string | Must be a non-empty string. Must contain the phrase 'This action is irreversible' or a close semantic equivalent. Retry if missing. | |
deletion_summary.required_approvals | array of strings | Array must contain at least 1 item. Each item must match a role from [APPROVAL_ROLES] input. Schema check against allowed enum. |
Common Failure Modes
What breaks first when generating data deletion summaries and how to prevent irreversible mistakes.
Incomplete Scope Enumeration
What to watch: The prompt summarizes only the primary table or dataset, omitting related records, backups, logs, or downstream replicas that will also be affected. Guardrail: Require the prompt to ingest a machine-generated dependency map or data catalog entry. Validate the summary against a completeness checklist before routing for approval.
Retention Policy Misapplication
What to watch: The model hallucinates a retention justification by citing a generic policy that does not apply to this specific data class, jurisdiction, or contractual obligation. Guardrail: Inject the exact policy text and jurisdiction as grounded context. Add an eval that scores whether the summary's justification quotes or accurately paraphrases the provided policy.
Irreversibility Downplaying
What to watch: The summary uses soft language like 'data will be removed' instead of explicitly stating that the operation is irreversible and that backups will also be purged after the retention window. Guardrail: Add a hard constraint in the prompt requiring a dedicated 'Irreversibility Warning' section with prescribed language. Validate output with a keyword check for 'irreversible' and 'cannot be recovered'.
Stakeholder Routing Omission
What to watch: The prompt identifies only the requestor as the approver, missing required sign-offs from Data Protection Officer, legal, or application owners. Guardrail: Provide a structured approval matrix as input. Validate the output's approval list against the matrix. Escalate to a human coordinator if the output list does not match the required set.
Backup Verification Blind Spot
What to watch: The summary states that a backup exists without verifying the backup's integrity, recency, or recoverability. Guardrail: The harness must call a backup verification tool and inject the result (success/failure/timestamp) into the prompt context. The prompt must be instructed to explicitly state 'Backup verification: FAILED' if the tool returns a negative result, blocking the workflow.
Ambiguous Affected Systems
What to watch: The summary uses vague terms like 'related services' instead of listing specific system names, causing operators to underestimate the blast radius. Guardrail: Require the prompt to output a structured list of affected systems from a provided configuration management database (CMDB) input. Validate that the output list contains concrete system identifiers, not generic categories.
Evaluation Rubric
Run these checks against a golden dataset of 20-50 deletion requests to validate output quality before shipping. Each criterion maps to a concrete pass standard, failure signal, and test method.
| Criterion | Pass Standard | Failure Signal | Test Method |
|---|---|---|---|
Completeness of Affected Systems | All systems listed in [DELETION_REQUEST] appear in the output summary under affected systems | Output omits a system mentioned in the input request or lists a system not present in the request | Schema check: compare set of systems in input to set in output. Fail if mismatch |
Retention Policy Justification Accuracy | Every retention policy cited matches the policy document for that data class and the justification references a specific policy clause | Output invents a policy name, cites an expired policy, or claims a retention period that contradicts the policy document | Citation check: verify each policy reference against the [RETENTION_POLICY_DOC] source. Fail if hallucinated or contradictory |
Irreversibility Warning Presence | Output contains an explicit irreversibility warning with language indicating the action cannot be undone and data recovery is not guaranteed | Warning is absent, uses hedging language like 'may be difficult to recover', or omits the recovery impossibility statement | String match: scan for required warning phrases from [WARNING_TEMPLATE]. Fail if missing or softened |
Backup Verification Evidence | Output includes a boolean field |
| Harness integration test: assert |
Stakeholder Approval Routing Correctness | Required approvers for each data class match the [APPROVAL_MATRIX] and the output lists no fewer than the minimum required approvers | Output routes approval to a role not in the matrix, skips a required approver, or includes an approver with no authority for this data class | Schema check: validate approver list against [APPROVAL_MATRIX] for each data class. Fail if any deviation |
Data Scope Precision | Output specifies exact records, date ranges, or filters matching the deletion request scope without over-deletion or under-deletion | Output uses vague language like 'all related data', expands scope beyond the request, or narrows scope without justification | Diff check: compare requested scope to output scope. Fail if scope boundaries differ without an explicit override justification |
Regulatory Citation Accuracy | Any regulation cited in the output matches the regulation name and article number from the [REGULATORY_REFERENCE] source | Output cites a regulation not in the reference source, misstates an article number, or claims a requirement that does not exist in the cited regulation | Citation check: verify each regulatory reference against [REGULATORY_REFERENCE]. Fail if hallucinated or incorrect |
Confidence Score Threshold | Output includes a | Confidence score is missing, exceeds 1.0, or is below threshold but no escalation flag is set | Threshold test: assert |
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
Use the base prompt with a single approval role and lighter validation. Replace multi-stakeholder routing with a simple [APPROVER_ROLE] placeholder. Skip backup verification checks and use a static list of [AFFECTED_SYSTEMS] instead of dynamic discovery.
Watch for
- Missing schema checks on the output JSON
- Overly broad deletion scope descriptions
- No irreversibility warning in the summary

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