Inferensys

Prompt

Refusal with Evidence Request Prompt for Follow-Up Retrieval

A practical prompt playbook for using Refusal with Evidence Request Prompt for Follow-Up Retrieval in production AI workflows.
Wide-angle shot of a modern WeWork open floor plan with creative walls covered in AI system architecture diagrams, product team collaborating in standing desk area with industrial lighting.
PROMPT PLAYBOOK

When to Use This Prompt

Defines the ideal system architecture, user, and failure conditions for deploying the Refusal with Evidence Request Prompt.

This prompt is designed for agent-based Retrieval-Augmented Generation (RAG) systems that possess a critical capability: the ability to perform follow-up retrieval. In a standard RAG setup, an initial search yields insufficient evidence, and the model either hallucinates an answer or delivers a dead-end refusal. This prompt transforms that failure state into a recovery path. Instead of a simple 'I don't know,' the model outputs a structured refusal containing specific, actionable retrieval queries designed to find the missing evidence. The primary job-to-be-done is to bridge the gap between a failed initial search and a successful subsequent one, enabling a multi-step agent to self-correct its knowledge state.

You should use this prompt when your system architecture includes a search tool available in a subsequent agent step and you need the model to articulate exactly what evidence would resolve the gap. The ideal user is an AI engineer or RAG pipeline architect building a system where an orchestrating agent can parse the model's structured refusal, execute the suggested queries against a database or API, and feed the new results back into the context window for a second answer attempt. This pattern is particularly valuable in research assistants, legal document review, and complex customer support systems where the cost of a wrong answer is high, but the cost of a second retrieval loop is acceptable. Do not use this prompt for static Q&A systems with no retrieval capability, single-shot answer generation where no tool is available, or when you need a final answer rather than a retrieval plan. In those cases, a standard evidence insufficiency refusal or a calibrated uncertainty expression would be more appropriate.

Before implementing, verify that your agent harness can parse the structured output from this prompt and has a reliable search function to call. A common failure mode is generating excellent retrieval queries that the downstream search system cannot parse or execute, leading to a second failure. Ensure your search tool's capabilities and query syntax are clearly described in the prompt's [TOOLS] section. The next step is to pair this prompt with an evaluation rubric that checks not just for valid JSON, but for the actionability and precision of the suggested retrieval queries.

PRACTICAL GUARDRAILS

Use Case Fit

Where the Refusal with Evidence Request prompt adds value and where it introduces risk. This prompt is designed for agent-based RAG systems that can act on structured evidence requests, not for static chatbots or one-shot answer generation.

01

Good Fit: Agentic RAG with Tool Access

Use when: your system can receive a structured evidence request, execute a follow-up search or API call, and feed results back into the generation loop. Guardrail: ensure the evidence request schema matches your retrieval tool's input contract exactly.

02

Bad Fit: One-Shot Answer Generation

Avoid when: the model cannot trigger additional retrieval or the user expects a final answer in a single turn. Guardrail: use a static refusal or evidence insufficiency prompt instead; do not promise follow-up capability the system lacks.

03

Required Input: Retrieval Tool Schema

What to watch: the prompt must know the exact query format, filters, and metadata fields the downstream search tool accepts. Guardrail: provide the tool's input schema as part of [TOOL_SCHEMA] and validate generated queries against it before execution.

04

Required Input: Evidence Gap Analysis

What to watch: the refusal must specify what evidence is missing, not just that evidence is insufficient. Guardrail: include a structured gap description in the prompt output schema so downstream retrieval targets the right information.

05

Operational Risk: Retrieval Loop Exhaustion

Risk: the agent may request evidence repeatedly without converging, burning tokens and latency. Guardrail: enforce a maximum retry count and escalate to human review or final refusal after the limit is reached.

06

Operational Risk: Overly Broad Evidence Requests

Risk: the model generates vague or overly broad follow-up queries that return irrelevant results. Guardrail: include specificity constraints in the prompt and validate that generated queries contain concrete entities, date ranges, or domain terms before execution.

PROMPT PLAYBOOK

Copy-Ready Prompt Template

A reusable system prompt that refuses to answer when evidence is insufficient and outputs structured retrieval queries for the missing information.

This template instructs the model to act as a strict grounding gate. Instead of guessing or producing a low-confidence answer, the model must refuse and articulate exactly what evidence would change its decision. The output is a machine-readable refusal payload containing one or more retrieval queries designed for a downstream search tool. This pattern is essential for agent-based RAG systems where a follow-up retrieval loop can resolve the gap before the user sees a response.

text
You are an evidence-grounded assistant in a retrieval-augmented system. Your primary directive is to answer only when the provided evidence is sufficient. If the evidence is insufficient, you must refuse to answer and instead produce a structured request for the missing evidence.

## INPUT
- User Query: [USER_QUERY]
- Retrieved Evidence Passages: [RETRIEVED_EVIDENCE]
- Evidence Sufficiency Threshold: [SUFFICIENCY_THRESHOLD]

## BEHAVIOR RULES
1. Analyze whether the retrieved evidence fully, partially, or does not support an answer to the user query.
2. If the evidence is sufficient (meets or exceeds the threshold), answer the query using only the provided evidence. Cite specific passages.
3. If the evidence is insufficient, do not answer the query. Do not speculate, infer beyond the text, or use internal knowledge.
4. When refusing, output a JSON object following the schema below. The `evidence_requests` array must contain one or more specific, actionable retrieval queries that would fill the identified gaps.

## OUTPUT SCHEMA (when refusing)
{
  "status": "refused",
  "rationale": "String explaining why the provided evidence is insufficient.",
  "missing_information": ["List of specific facts or data points needed."],
  "evidence_requests": [
    {
      "query": "A self-contained search query for a vector or keyword store.",
      "expected_content": "Description of the document type or passage that would satisfy this request.",
      "priority": "critical | high | medium"
    }
  ]
}

## CONSTRAINTS
- Never invent citations or fabricate source details.
- If the user query is ambiguous, request clarification as an `evidence_request` rather than guessing intent.
- The `evidence_requests` must be executable by a search system without further user input.

To adapt this template, replace the bracketed placeholders with your application's runtime variables. [USER_QUERY] is the raw input. [RETRIEVED_EVIDENCE] should be a pre-formatted string of your top-k passages, including source identifiers. [SUFFICIENCY_THRESHOLD] can be a qualitative label (e.g., 'high') or a numerical score if your pipeline produces one. The output schema is designed for direct consumption by a retrieval tool dispatcher. If your system uses function calling, map the evidence_requests array directly to a search tool's arguments. For high-stakes domains, add a [RISK_LEVEL] parameter that adjusts the threshold dynamically—critical applications should refuse more aggressively. Always log the rationale and missing_information fields for offline evaluation of your retrieval pipeline's coverage gaps.

Before deploying, validate that the model reliably outputs valid JSON under the refusal path. Common failure modes include the model answering despite insufficient evidence (false negative on refusal) or generating vague evidence requests like 'more information about the topic.' Use a structured output API or a retry parser to enforce the schema. Pair this prompt with an evaluator that checks whether the generated evidence_requests would actually retrieve the missing facts if executed against your knowledge base.

IMPLEMENTATION TABLE

Prompt Variables

Required inputs for the Refusal with Evidence Request prompt. Each variable must be populated before the prompt is assembled and sent to the model. Missing or malformed variables will cause the prompt to produce generic refusals instead of actionable evidence requests.

PlaceholderPurposeExampleValidation Notes

[USER_QUERY]

The original user question that could not be answered from available evidence

What is the tensile strength of alloy X-17 at 600°C?

Must be non-empty string. Check for injection patterns before passing. Truncate if longer than 2000 characters.

[RETRIEVED_EVIDENCE]

The full set of passages returned by the retrieval system, including source metadata

Passage 1 (source: mat-spec-2024.pdf, §3.2): Alloy X-17 exhibits...

Must be a list of objects with text and source fields. Empty list triggers retrieval-failure path. Validate source field is present for each passage.

[EVIDENCE_SUFFICIENCY_THRESHOLD]

The minimum confidence score required before the system attempts an answer instead of refusing

0.7

Float between 0.0 and 1.0. Values below 0.5 produce excessive refusals. Values above 0.95 produce risky answers. Default 0.7 if not specified.

[RETRIEVAL_TOOL_SCHEMA]

The function or tool definition the model should use to format its evidence request

{"name": "search_knowledge_base", "parameters": {"query": "string", "filters": {"domain": "string"}}}

Must be valid JSON matching the downstream search tool's expected schema. Validate against tool contract before prompt assembly. Missing schema causes unstructured evidence requests.

[MAX_RETRIEVAL_QUERIES]

Upper bound on how many follow-up retrieval queries the model can request in one refusal response

3

Integer between 1 and 10. Lower values prevent query explosion. Higher values risk noisy retrieval. Default 3. Enforce at application layer as well as prompt constraint.

[DOMAIN_TAXONOMY]

Controlled vocabulary of domains, source types, or knowledge areas the retrieval system can target

["materials science", "mechanical engineering", "thermal analysis", "failure modes"]

Must be a list of strings matching the retrieval system's filterable categories. Null allowed if no domain filtering exists. Validate each entry against the live taxonomy to prevent hallucinated filter values.

[REFUSAL_TONE]

Style directive controlling the refusal's voice and user-facing language

professional_and_helpful

Must be one of: professional_and_helpful, direct_and_technical, empathetic_and_supportive, clinical_and_neutral. Default professional_and_helpful. Invalid values cause tone drift in production.

[OUTPUT_SCHEMA]

The expected JSON structure for the refusal response including evidence request fields

{"decision": "refuse", "rationale": "string", "missing_evidence": [{"description": "string", "retrieval_query": "string", "required_domain": "string"}]}

Must be valid JSON Schema or example structure. Validate that downstream consumers can parse this exact shape. Schema mismatch causes integration failures.

PROMPT PLAYBOOK

Implementation Harness Notes

How to wire the Refusal with Evidence Request prompt into an agent loop or RAG pipeline for follow-up retrieval.

This prompt is designed as a decision node within an agentic RAG loop, not a terminal response. Its primary output is a structured refusal that includes actionable evidence requests—formatted as retrieval queries or source descriptions—that a downstream search tool can consume. The implementation harness must treat the model's output as a machine-readable instruction, not just a user-facing message. The core integration pattern is: (1) initial retrieval attempt, (2) evidence sufficiency check, (3) if insufficient, invoke this prompt to generate targeted retrieval requests, (4) execute those requests via your search infrastructure, and (5) re-enter the answer generation flow with the expanded evidence set.

To wire this into an application, wrap the prompt in a function that accepts the original user query, the set of retrieved passages, and a configurable sufficiency threshold. The model's response should be parsed into a strict JSON schema containing a refusal_message (for user display or logging) and an evidence_requests array of objects, each with a query string and an optional source_description field. Implement a validator that rejects responses where evidence_requests is empty or contains queries that are trivial reformulations of the original user input—this prevents infinite loops. Log every refusal event with the original query, retrieved passages, generated evidence requests, and the validator result for debugging retrieval gaps.

For retry logic, set a maximum of two follow-up retrieval rounds before escalating to a terminal refusal or human review. After each round, re-run evidence sufficiency scoring. If the new evidence still falls below threshold, invoke this prompt again but include the history of prior retrieval attempts and their results in the [CONTEXT] placeholder to prevent repeated ineffective queries. In high-stakes domains such as healthcare or legal, always route terminal refusals to a human review queue with the full audit trail. Avoid using this prompt for queries where the knowledge base is known to be sparse—pre-filter with an answerability classifier to reduce unnecessary retrieval loops and latency.

IMPLEMENTATION TABLE

Expected Output Contract

Schema and validation rules for the refusal-with-evidence-request response. Each field is designed for downstream consumption by a retrieval tool or agent orchestrator.

Field or ElementType or FormatRequiredValidation Rule

refusal_statement

string

Must contain a clear statement that the question cannot be answered with current evidence. Must not contain speculative or hallucinated content. Length between 20 and 500 characters.

evidence_gaps

array of objects

Array must contain 1-5 gap objects. Each gap must have a 'description' (string) and 'required_evidence_type' (string). Array must not be empty.

evidence_gaps[].description

string

Must describe what specific information is missing. Must reference the original query context. Must not be a generic statement like 'more information needed'. Length between 10 and 300 characters.

evidence_gaps[].required_evidence_type

string

Must specify the type of evidence needed (e.g., 'clinical trial results', 'financial statement', 'technical specification'). Must be specific enough to guide retrieval. Must not be 'any' or 'more data'.

retrieval_queries

array of strings

Array must contain 1-5 search query strings derived from evidence gaps. Each query must be a well-formed search string suitable for a vector or keyword retrieval system. Array must not be empty.

retrieval_queries[]

string

Each query must be between 5 and 200 characters. Must contain domain-relevant terms from the original query. Must not be identical to the original user query. Must be actionable by a search system.

confidence_assessment

object

Must contain 'current_confidence' (number 0.0-1.0) and 'confidence_with_evidence' (number 0.0-1.0). current_confidence must be less than or equal to 0.4. confidence_with_evidence must be greater than current_confidence.

escalation_recommendation

string

If present, must be one of: 'retry_retrieval', 'expand_search_sources', 'request_human_review', 'close_as_unanswerable'. Must align with confidence_assessment values. Null allowed.

PRACTICAL GUARDRAILS

Common Failure Modes

When a model refuses to answer and requests follow-up evidence, several failure modes can degrade the user experience or break the downstream retrieval loop. These are the most common issues and how to guard against them.

01

Vague Evidence Requests

What to watch: The model produces a generic refusal like 'I need more information' without specifying what evidence would resolve the gap. Downstream retrieval tools receive no actionable query. Guardrail: Require the output schema to include a structured evidence_request field with specific search queries, required document types, or explicit information needs that a retriever can act on.

02

Hallucinated Source Descriptions

What to watch: The model invents plausible-sounding but non-existent documents, authors, or data sources in its evidence request, leading retrieval tools to search for phantom references. Guardrail: Constrain the prompt to request evidence by information need (e.g., 'Q3 revenue breakdown by region') rather than by document title, and validate that requested sources exist in the knowledge base before re-querying.

03

False Abstention on Answerable Questions

What to watch: The model refuses to answer and requests evidence even when sufficient context is already present in the prompt, causing unnecessary retrieval loops and latency. Guardrail: Include an explicit pre-refusal check instruction: 'First, verify that the provided context is truly insufficient. If the answer is already supported, answer directly. Only refuse if evidence is missing after this check.'

04

Overconfident Refusal Rationale

What to watch: The refusal explanation states definitively that 'no evidence exists' rather than acknowledging the limits of the current retrieval set. This misleads users and downstream systems. Guardrail: Calibrate the refusal language to reference the provided or retrieved context specifically: 'The provided sources do not contain...' rather than 'No information is available.'

05

Retrieval Loop Exhaustion

What to watch: The model repeatedly requests evidence, each time receiving new context but still refusing, creating an infinite agent loop that burns tokens and latency budget. Guardrail: Implement a retry budget in the application layer. After N retrieval attempts, force a final response (answer with caveats or escalate to a human). Track retrieval_attempt_count in the agent state.

06

Evidence Request Drift

What to watch: Each successive refusal shifts the evidence request slightly, chasing tangential information rather than focusing on the original gap. The retrieval loop loses coherence. Guardrail: Include the original user query and the initial gap assessment in every retry prompt. Instruct the model to refine its request rather than replace it, maintaining traceability to the root question.

IMPLEMENTATION TABLE

Evaluation Rubric

Criteria for evaluating the quality of a refusal with evidence request before shipping to production. Each row defines a pass standard, a failure signal, and a concrete test method.

CriterionPass StandardFailure SignalTest Method

Refusal Decision Accuracy

Refusal is triggered only when provided evidence is insufficient to answer the query. No refusal when evidence is sufficient.

False refusal on answerable queries or failure to refuse when evidence is missing.

Run against a golden dataset of 50 queries with pre-labeled evidence sufficiency. Measure precision and recall of the refusal decision.

Evidence Request Actionability

The output contains at least one retrieval query or source description that, if executed, would plausibly return the missing evidence.

Evidence request is generic (e.g., 'more information'), empty, or describes evidence already present in the context.

LLM-as-judge evaluation: prompt a separate model to rate if the requested evidence is specific and not already provided. Pass threshold: 4/5 average score.

Gap Explanation Grounding

The explanation of what evidence is missing is directly traceable to a gap in the provided context, not a hallucinated deficiency.

The refusal claims a source is missing a fact that the source actually contains, or invents a gap not present in the retrieval set.

Manual review of 20 samples. For each, verify the stated gap against the provided context. Target: 0% hallucinated gap rate.

Output Schema Compliance

The response strictly follows the defined [OUTPUT_SCHEMA] with all required fields present and correctly typed.

Missing required fields, extra untyped fields, or malformed JSON that fails schema validation.

Automated schema validation in CI/CD pipeline. Parse the output with the target schema and assert no validation errors.

Tone and User Trust

The refusal is polite, helpful, and avoids language that erodes trust (e.g., 'I don't know' without context, or defensive phrasing).

Dismissive, overly apologetic, or robotic tone that degrades user experience.

A/B test with 5 human evaluators rating tone on a 1-5 Likert scale. Pass threshold: average score >= 4.0.

Retrieval Query Format Validity

Generated retrieval queries are syntactically valid for the target search system (e.g., no empty strings, valid filter syntax).

Queries that cause search system errors, return zero results due to syntax issues, or contain unresolved placeholders.

Execute generated queries against the search API in a sandbox. Assert HTTP 200 and non-empty results for at least 80% of queries.

Latency Budget Adherence

The refusal with evidence request is generated within the defined latency budget (e.g., p95 < 2 seconds).

p95 latency exceeds the budget, causing timeout or user-perceived slowness.

Load test with 100 concurrent requests. Measure p95 end-to-end latency and assert it is below the defined threshold.

Over-Refusal Rate

The system refuses only when evidence is genuinely insufficient. Over-refusal rate is below the defined threshold (e.g., < 5%).

The system refuses on queries that a human judge determines are answerable from the provided context.

Run against a dataset of 200 queries with borderline evidence. Calculate the percentage of false refusals and assert it is below the threshold.

ADAPTATION OPTIONS

Adapt This Prompt

How to adapt

Start with the base refusal template and a simple evidence-gap detection step. Use a single LLM call that receives the user query and retrieved passages, then outputs a structured refusal with evidence requests if the passages are insufficient. Keep the output schema minimal: refusal_reason, missing_evidence_description, and suggested_retrieval_queries as a string array.

code
You are an evidence-grounded assistant. Given the user query and retrieved passages below, determine if the evidence is sufficient to answer. If NOT sufficient, produce a refusal that explains what evidence is missing and generate 1-3 retrieval queries that would fill the gap.

User Query: [QUERY]
Retrieved Passages: [PASSAGES]

Output JSON with keys: refusal_reason, missing_evidence_description, suggested_retrieval_queries

Watch for

  • The model generating retrieval queries that are too vague to be useful (e.g., "more information about the topic")
  • Refusal triggering when evidence is actually sufficient but scattered across passages
  • Missing validation that suggested queries are syntactically valid for your search backend
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.