Inferensys

Prompt

Pending Approval Tracking Prompt Template

A practical prompt playbook for building AI assistants that track items blocked waiting for user or stakeholder approval, with timeout warnings, dependency mapping, and escalation triggers.
Developer doing prompt engineering on laptop, prompt variations visible on screen, casual coding session.
PROMPT PLAYBOOK

When to Use This Prompt

Define the job, ideal user, and constraints for the Pending Approval Tracking prompt before wiring it into a production approval-gated workflow.

This prompt is designed for AI assistants operating inside approval-gated workflows where progress stalls until a human or system stakeholder explicitly approves a pending item. The core job-to-be-done is maintaining a structured, auditable inventory of items blocked on approval, surfacing them at the right time, and preventing silent workflow failures caused by forgotten approvals. The ideal user is an engineering lead or product developer building a copilot for procurement, contract review, change management, content publishing, or any multi-step business process that requires explicit sign-off before the next stage can proceed.

Use this prompt when your assistant must track multiple concurrent approval requests across long-running sessions, detect when an approval is overdue, and re-prompt the user without being annoying or losing context. It is appropriate when approvals have clear identifiers, requestors, approvers, and deadlines that can be extracted or inferred from conversation context. The prompt expects structured input including the current pending approval inventory, conversation history, and a defined escalation policy. Do not use this prompt for simple yes/no confirmations within a single turn, for workflows where approval is implicit (e.g., the user's continued engagement counts as approval), or for systems where the approval decision is made by the model itself rather than an external human or system actor. In high-stakes domains such as healthcare, legal, or financial compliance, always pair this prompt with human review of the generated approval status and escalation triggers before any action is taken.

Before implementing, define your approval state machine: what states an item can be in (e.g., pending, approved, rejected, expired, cancelled), what transitions are valid, and what timeout thresholds trigger escalation. The prompt works best when fed a structured [PENDING_APPROVALS] array with fields for item_id, description, requestor, approver, requested_at, deadline, and status. If your application cannot provide this structured input reliably, invest in upstream extraction before relying on this prompt. The output should be consumed programmatically—parsed into your state management layer—rather than displayed raw to users. Start by running the prompt against a golden dataset of conversations with known approval events and verify that no approval is dropped, duplicate reminders are not generated for the same item within a cooldown window, and escalation triggers fire at the correct thresholds.

PRACTICAL GUARDRAILS

Use Case Fit

Where the Pending Approval Tracking prompt works, where it fails, and what you must provide before deploying it in a production approval-gated workflow.

01

Good Fit: Explicit Approval Gates

Use when: The workflow has a defined approval step where a human or system must explicitly authorize progression. The prompt excels at tracking items blocked on a named approver with a clear due date. Avoid when: Approval is implicit, cultural, or decided in side channels outside the tracked conversation.

02

Bad Fit: Real-Time Safety-Critical Decisions

Risk: The prompt tracks pending approvals but does not enforce them in real time. Using it to gate physical actions, financial transfers, or clinical decisions without a hard system interlock creates a dangerous gap. Guardrail: The prompt output must feed a deterministic state machine that physically blocks action execution until approval is confirmed.

03

Required Inputs

What you must provide: A structured list of items awaiting approval, each with a unique ID, description, requester, designated approver, submission timestamp, and SLA deadline. Without these fields, the prompt cannot calculate age, detect overdue items, or map dependencies. Guardrail: Validate input schema before prompt assembly.

04

Operational Risk: Stale Approval State

Risk: The prompt tracks approvals based on the state you provide. If the underlying system of record updates an approval status without refreshing the prompt's input, the model will confidently report outdated information. Guardrail: Re-run the prompt on every state change and include a last_updated timestamp in the output for traceability.

05

Dependency Mapping Limitations

Risk: The prompt can identify that Item B is blocked by Item A's approval, but it cannot resolve circular dependencies or complex transitive blocks without explicit graph input. Guardrail: Pre-compute the dependency graph in application code and pass a flattened, ordered list of blocking relationships into the prompt context.

06

Escalation Trigger Precision

Risk: The prompt may flag items as overdue and suggest escalation, but it lacks the authority to decide who to escalate to or whether escalation is appropriate for a given stakeholder relationship. Guardrail: Pair the prompt's overdue detection with a routing table in application logic that maps item type and approver role to a specific escalation path.

PROMPT PLAYBOOK

Copy-Ready Prompt Template

A reusable prompt template with square-bracket placeholders for tracking items blocked on approval in multi-turn conversations.

This section provides the core prompt template for detecting, tracking, and surfacing approval-blocked items across conversation turns. The template is designed to be dropped into an AI harness that maintains session state, feeding it the current conversation context and a structured inventory of previously identified pending approvals. It expects the model to return a machine-readable JSON object that your application can parse, validate, and use to drive reminder logic, escalation workflows, or user-facing status displays.

text
You are an approval tracking assistant operating inside a multi-turn conversation system. Your job is to maintain an accurate inventory of items that are blocked waiting for user or stakeholder approval. You must detect new approval needs, update existing items when their status changes, and flag items that are overdue or at risk of timeout.

## Current Conversation Context
[CONVERSATION_HISTORY]

## Existing Pending Approvals Inventory
[EXISTING_APPROVALS_STATE]

## Current Date and Time
[CURRENT_DATETIME]

## Instructions
1. Scan the conversation for any new items that require approval. An item requires approval when a decision, sign-off, or explicit confirmation is needed before work can proceed. Look for phrases like "needs your approval," "please confirm," "waiting on sign-off," "blocked until you decide," or explicit decision points presented to the user.
2. For each existing item in the inventory, determine if its status has changed based on the conversation. An item is resolved when the user provides explicit approval or rejection. Do not infer resolution from silence or topic changes.
3. For each item (new or existing), compute or update the following fields:
   - `item_id`: A stable identifier. Use existing IDs for known items; generate new unique IDs for new items.
   - `description`: A concise description of what requires approval.
   - `requested_by`: Who or what system requested the approval.
   - `approver`: The person or role whose approval is needed.
   - `status`: One of `pending`, `approved`, `rejected`, `cancelled`, or `expired`.
   - `requested_at_turn`: The conversation turn number when the approval was first requested.
   - `last_mentioned_turn`: The most recent turn where this item was discussed.
   - `timeout_timestamp`: If a deadline or SLA was mentioned, the ISO 8601 timestamp when the item becomes overdue. Otherwise null.
   - `dependency_of`: An array of item_ids that are blocked by this approval. Empty array if none.
   - `blocked_by`: An array of item_ids that block this approval. Empty array if none.
   - `escalation_triggered`: Boolean. Set to true if the item is past its timeout_timestamp and has not been resolved.
   - `urgency_rationale`: A brief explanation of why this item is urgent or can wait, based on conversation signals.
4. If an item has been resolved (approved or rejected), keep it in the inventory but mark its status accordingly. Do not delete resolved items.
5. If an item's timeout has passed and it remains unresolved, set `escalation_triggered` to true and include a brief escalation note in the output.
6. If the user explicitly cancels an approval request, set status to `cancelled`.
7. Do not invent approvals that were not mentioned in the conversation. Do not mark items as resolved without explicit user confirmation.

## Output Schema
Return a single JSON object with the following structure:
{
  "approvals": [
    {
      "item_id": "string",
      "description": "string",
      "requested_by": "string",
      "approver": "string",
      "status": "pending|approved|rejected|cancelled|expired",
      "requested_at_turn": integer,
      "last_mentioned_turn": integer,
      "timeout_timestamp": "ISO 8601 string or null",
      "dependency_of": ["item_id strings"],
      "blocked_by": ["item_id strings"],
      "escalation_triggered": boolean,
      "urgency_rationale": "string"
    }
  ],
  "summary": {
    "total_pending": integer,
    "total_overdue": integer,
    "new_items_detected": integer,
    "items_resolved_this_turn": integer
  },
  "escalation_alerts": [
    {
      "item_id": "string",
      "alert_message": "string",
      "recommended_action": "string"
    }
  ]
}

## Constraints
- Do not include conversational filler or explanations outside the JSON object.
- Ensure all item_ids are unique and stable across turns.
- If no approvals exist, return an empty approvals array with appropriate summary counts.
- If the conversation contains no new information about approvals, return the existing inventory unchanged with `new_items_detected` and `items_resolved_this_turn` set to 0.

To adapt this template, start by defining how your application serializes [CONVERSATION_HISTORY]. A common approach is to pass the last N turns as structured messages with turn numbers, speaker roles, and timestamps. The [EXISTING_APPROVALS_STATE] placeholder should receive the JSON output from the previous invocation of this prompt, allowing the model to maintain continuity. If this is the first turn, pass an empty approvals array. The [CURRENT_DATETIME] field should be injected by your application server to prevent timezone drift. Before deploying, test the template against conversations with overlapping approval requests, implicit rejections, and multi-party approval chains to ensure the dependency mapping logic holds. Wire the output into a validation layer that checks for duplicate item_ids, invalid status transitions, and missing required fields before persisting the state update.

IMPLEMENTATION TABLE

Prompt Variables

Required and optional inputs for the Pending Approval Tracking prompt. Each placeholder must be populated before the prompt is assembled and sent to the model.

PlaceholderPurposeExampleValidation Notes

[APPROVAL_ITEMS]

Array of items currently awaiting approval, each with an ID, description, and submission timestamp.

[{"id":"REQ-142","description":"Database schema change for user table","submitted_at":"2025-03-21T14:00:00Z"}]

Must be a valid JSON array. Each object requires id (string), description (string), and submitted_at (ISO 8601 string). Empty array is allowed.

[CURRENT_TIMESTAMP]

The current system time used to calculate item age and trigger timeout warnings.

2025-03-24T09:30:00Z

Must be ISO 8601 UTC. Do not use the model's training cutoff date. Inject from application clock.

[TIMEOUT_THRESHOLD_HOURS]

Number of hours after which an unapproved item is considered overdue and triggers escalation language.

48

Must be a positive integer. Default to 48 if not specified. Controls the urgency of the output language.

[ESCALATION_CONTACTS]

List of roles or individuals to notify when items exceed the timeout threshold.

Optional. If null or empty, the prompt should not generate specific contact instructions. Validate as array of strings or null.

[DEPENDENCY_MAP]

Mapping of approval item IDs to the items or workflows they block, used to calculate downstream impact.

{"REQ-142":["DEPLOY-2025-04","MIGRATION-USER-V2"]}

Optional. If provided, must be a valid JSON object with item IDs as keys and arrays of blocked item IDs as values. If null, dependency analysis is skipped.

[PREVIOUS_REMINDER_COUNT]

Number of times the user has already been reminded about each pending item, used to adjust tone and urgency.

{"REQ-142":2,"REQ-138":0}

Optional. If provided, must be a JSON object mapping item IDs to non-negative integers. If null, assume zero previous reminders for all items.

[OUTPUT_FORMAT]

Specifies whether the output should be a structured JSON report or a natural-language summary for a user-facing message.

json

Must be one of 'json' or 'natural-language'. Default to 'json' if not provided. Controls the output schema applied by the prompt.

[APPROVAL_WORKFLOW_CONTEXT]

Brief description of the approval process and what the user needs to do to approve or reject items.

Approve by replying 'approved [REQ-ID]' or visiting the internal review dashboard at /approvals.

Optional but recommended. If null, the prompt should use generic approval language. Validate as string or null.

PROMPT PLAYBOOK

Implementation Harness Notes

How to wire the Pending Approval Tracking prompt into a stateful application with validation, retries, and escalation logic.

This prompt is designed to be called within a stateful application loop, not as a standalone chat interaction. The application must maintain a structured pending_approvals data store (a database table, a key-value store, or a serialized JSON object in session state) that the prompt reads from and writes to. The prompt's output should be parsed as a strict JSON list of approval items, each with an approval_id, status, age, dependencies, and escalation_triggered boolean. The application layer is responsible for merging this output back into the canonical state store, not the model. This separation ensures that the model's reasoning about timeouts and dependencies is advisory, while the actual state transitions and escalation actions (sending emails, pinging Slack, opening tickets) are executed deterministically by your code.

To wire this into a production workflow, implement a state reconciliation loop that runs on every user turn and on a scheduled tick for timeout detection. First, serialize the current pending_approvals list and the recent conversation turns into the prompt's [APPROVAL_STATE] and [CONVERSATION_CONTEXT] placeholders. After receiving the model's output, validate each item against a JSON schema that enforces required fields (approval_id, status, last_updated_timestamp) and allowed enum values for status (e.g., pending, approved, rejected, expired). Reject any item that references a non-existent approval_id or introduces a dependency cycle. For high-stakes workflows, add a human review gate before executing any escalation action: if the model sets escalation_triggered: true, queue the item for a human reviewer rather than automatically firing a notification. Log every state change with the previous state, new state, model's raw output, and the reviewer's decision for auditability.

Model choice matters here. Use a model with strong JSON mode and long-context handling (GPT-4o, Claude 3.5 Sonnet, or Gemini 1.5 Pro) because the prompt must process a potentially large list of approval items alongside conversation history. If your approval list exceeds ~50 items, implement pagination or chunking in the application layer: split the list into batches, process each batch through the prompt, and merge results. For retry logic, if validation fails (malformed JSON, missing fields, invalid state transitions), retry once with the validation error message injected into the prompt as additional [CONSTRAINTS]. If the retry also fails, log the failure, preserve the previous valid state, and alert the on-call channel. Do not let a model output error corrupt your canonical approval state. Finally, avoid using this prompt for real-time safety-critical approvals (medical device sign-offs, financial transaction authorization) where deterministic rule engines are required; this prompt is appropriate for business workflow approvals where the cost of a missed escalation is a delayed decision, not a safety incident.

IMPLEMENTATION TABLE

Expected Output Contract

Defines the structured output schema for the Pending Approval Tracking prompt. Use this contract to validate model responses before they enter downstream systems.

Field or ElementType or FormatRequiredValidation Rule

approval_items

Array of objects

Must be a non-null array; empty array is valid when no items are pending

approval_items[].id

String

Must be a unique, stable identifier within the session; regex: ^[a-zA-Z0-9_-]+$

approval_items[].description

String

Must be non-empty and under 500 characters; should summarize the item requiring approval

approval_items[].status

Enum: pending_approval | approved | rejected | expired

Must be one of the defined enum values; no other statuses allowed

approval_items[].requested_at

ISO 8601 datetime string

Must parse to a valid datetime; cannot be in the future relative to the current turn timestamp

approval_items[].age_hours

Number

Must be a non-negative float; calculated as the difference between current time and requested_at in hours

approval_items[].timeout_hours

Number or null

If provided, must be a positive float; null indicates no timeout is set

approval_items[].escalation_triggered

Boolean

Must be true if age_hours exceeds timeout_hours and status is pending_approval; otherwise false

PRACTICAL GUARDRAILS

Common Failure Modes

What breaks first in pending approval tracking and how to guard against it.

01

Approval Entity Drift

What to watch: The model loses track of which specific item is awaiting approval, conflating similar requests or merging distinct approval items into one. This happens most often when multiple items of the same type are pending simultaneously. Guardrail: Assign a unique, immutable approval_id to each item at creation time and require the model to reference it in every status update. Validate that the ID exists in the current pending set before accepting any state change.

02

Timeout and Staleness Blindness

What to watch: The assistant fails to detect that an approval request has exceeded its SLA or become irrelevant due to conversation progress. The item sits in the pending queue indefinitely, polluting context and blocking downstream workflows. Guardrail: Attach an expires_at timestamp and a staleness_policy to every approval item. Include explicit instructions to re-evaluate pending items against current conversation state on every turn and auto-escalate or retire items that exceed their time window.

03

Implicit Resolution Without Confirmation

What to watch: The model infers approval or rejection from ambiguous user language (e.g., 'sure, go ahead with the other stuff') and marks an item resolved without explicit confirmation. This creates audit gaps and incorrect state transitions. Guardrail: Require explicit confirmation language for any state change to approved or rejected. Implement a confirmation gate: when the model believes resolution has occurred, it must echo back the specific item and ask for a yes/no confirmation before updating state. Log all implicit inferences as unconfirmed for human review.

04

Dependency Chain Breakage

What to watch: Item B depends on approval of Item A, but the model approves B independently or fails to surface the dependency when A is rejected. This produces invalid workflow states where downstream items are approved without their prerequisites being satisfied. Guardrail: Model dependencies as a directed graph with explicit depends_on fields referencing approval IDs. Before any state transition, validate that all upstream dependencies are in the required state. Include a dependency check in the prompt's output schema that the harness verifies before accepting the state change.

05

Escalation Trigger Suppression

What to watch: The model recognizes an item is overdue but fails to generate the escalation output, either because the escalation instructions are buried in the prompt or because the model prioritizes conversational flow over operational triggers. Guardrail: Separate escalation logic into a dedicated output field that is always populated, even if empty. Use a post-processing validator that checks: if now > expires_at and status != 'escalated', flag as a missed escalation. Make escalation non-optional in the output schema.

06

Context Window Eviction of Pending Items

What to watch: As the conversation grows, older pending approval items fall out of the context window and the model forgets they exist. The assistant continues the conversation as if all items are resolved, leaving orphaned approvals. Guardrail: Maintain pending approval state outside the conversation context in application-level storage. Inject a structured pending_approvals summary into every turn's prompt, sorted by urgency. Include a count of total pending items so the model can detect if its injected list is incomplete. Prune resolved items aggressively to preserve context budget.

IMPLEMENTATION TABLE

Evaluation Rubric

Use this rubric to test the Pending Approval Tracking Prompt before shipping. Each criterion targets a specific failure mode common in approval-gated workflows. Run these tests against a golden dataset of conversations containing approval requests, timeouts, and dependencies.

CriterionPass StandardFailure SignalTest Method

Approval Item Detection

All explicit and implicit approval requests in [CONVERSATION_HISTORY] are captured in the output list with a unique ID.

Missing an approval request that a human reviewer identifies in the transcript. False positives on informational statements.

Run against 20 transcripts with known approval items. Require recall >= 0.95 and precision >= 0.90.

Status Classification Accuracy

Each item is correctly classified as pending, approved, rejected, or expired based on the conversation evidence.

An item marked pending when the transcript shows explicit approval. An item marked approved based on assumption rather than evidence.

Validate output against a labeled dataset where status is ground-truthed. Require exact match accuracy >= 0.98.

Timeout and Age Calculation

Age is calculated correctly from the approval request turn timestamp. Items exceeding [TIMEOUT_HOURS] are flagged for escalation.

Age is null or incorrect. An item past the timeout threshold is not flagged. Age calculation uses the wrong reference point.

Inject conversations with known timestamps. Assert age field matches expected delta. Assert escalation flag is true when age > [TIMEOUT_HOURS].

Dependency Mapping Completeness

All blocking relationships between items are captured. If item B cannot proceed until item A is approved, the dependency is recorded.

A dependency is missing, causing downstream systems to proceed without the required approval. Circular dependencies are reported.

Use dependency-injected test cases. Verify the output graph matches the expected dependency structure. Check for orphaned items.

Output Schema Compliance

Output is valid JSON matching the [OUTPUT_SCHEMA] exactly. All required fields are present and non-null where applicable.

JSON parse error. Missing required field. Extra fields not in schema. Wrong data type for a field.

Automated schema validation in CI. Assert JSON.parse succeeds. Assert each item passes JSON Schema validation against the defined contract.

Escalation Trigger Correctness

Items exceeding the timeout threshold have escalation_triggered set to true and include a recommended escalation reason.

An overdue item has escalation_triggered set to false. Escalation is triggered for an item that is already approved or rejected.

Set [TIMEOUT_HOURS] to a known value. Inject items with ages above and below the threshold. Assert boolean field matches expected value for each.

Idempotency Across Re-runs

Running the prompt twice on the same [CONVERSATION_HISTORY] produces the same set of items, IDs, and statuses.

Item IDs change between runs. Status flips without new evidence. Non-deterministic output for identical input.

Execute prompt 5 times on the same input. Assert output JSON is identical across all runs. Flag any variance for investigation.

Empty State Handling

When [CONVERSATION_HISTORY] contains no approval requests, the output is a valid empty list with no errors or hallucinated items.

Output contains fabricated approval items. Output is null or malformed instead of an empty array. Error message instead of valid JSON.

Pass a conversation with no approvals. Assert output is { "items": [] }. Run 10 times to check for non-deterministic hallucinations.

ADAPTATION OPTIONS

Adapt This Prompt

How to adapt

Start with the base prompt and a simple JSON schema for approval items. Use a single-turn test harness with synthetic conversation transcripts. Skip timeout logic and dependency mapping initially—focus on correct extraction of approval type, status, and blocking condition.

Strip the prompt to essentials:

  • [CONVERSATION_TRANSCRIPT]
  • [APPROVAL_ITEM_SCHEMA] with fields: item_id, description, status, requested_by, requested_at

Watch for

  • Confusing "mentioned" with "pending approval"—the model may flag every reference to approval without checking whether it's actually blocked
  • Missing implicit approvals buried in passive language ("once you sign off we'll proceed")
  • Over-counting items when the same approval is referenced across multiple turns
Prasad Kumkar

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.