Inferensys

Prompt

Evidence Matching with Null Evidence Handling Prompt

A practical prompt playbook for using Evidence Matching with Null Evidence Handling Prompt 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

Use this prompt when your retrieval pipeline can return zero results and you need a reliable, machine-readable 'no evidence found' signal instead of a hallucinated match or silent failure.

This prompt is designed for verification pipeline operators and RAG system builders who must handle empty retrieval results gracefully. In production systems, a search for supporting evidence can return zero documents, yet standard evidence-matching prompts often fabricate support when given empty context—producing hallucinated citations, invented quotes, or overconfident confirmations. This prompt explicitly instructs the model to detect null evidence conditions, produce a structured 'no evidence found' output, document the search query that failed, and suggest alternative queries for downstream retry logic. The primary job-to-be-done is preventing silent failures in automated verification pipelines where a missing result could otherwise be misinterpreted as a positive match.

The ideal user is a developer or pipeline operator integrating this prompt into a retrieval-augmented verification system. Required context includes the original claim being verified, the search query that was executed, and the empty or insufficient result set. You should not use this prompt when you already have evidence to evaluate—standard evidence-matching prompts handle that case. You should also avoid this prompt when the retrieval system itself is unreliable or when the cost of a false negative (missing real evidence) is higher than the cost of a false positive (hallucinated match). In high-stakes domains such as healthcare, legal, or financial verification, always route null-evidence outputs to human review rather than treating them as definitive negative findings.

Before deploying this prompt, ensure your retrieval pipeline can reliably distinguish between 'no results found' and 'results found but filtered out by relevance thresholds.' The prompt expects an explicit empty-context signal—passing near-empty or low-quality results as if they were null will produce misleading outputs. Wire this prompt into your application with a pre-check: if the retriever returns zero results or all results fall below your relevance threshold, invoke this prompt; otherwise, use your standard evidence-matching prompt. Log every null-evidence invocation with the original claim, the failed query, and the suggested alternatives to build a query-improvement feedback loop over time.

PRACTICAL GUARDRAILS

Use Case Fit

Where the Evidence Matching with Null Evidence Handling Prompt delivers value and where it introduces risk.

01

Good Fit: Automated RAG Pipelines

Use when: integrating into an automated retrieval-augmented generation pipeline where a silent 'no results' response would be treated as a factual answer. Guardrail: The prompt's explicit NO_EVIDENCE_FOUND signal allows the application layer to branch logic, preventing hallucinated answers from empty retrieval sets.

02

Bad Fit: Open-Ended Creative Writing

Avoid when: the task requires speculative generation, brainstorming, or creative synthesis where strict evidence grounding is not required. Guardrail: Applying this prompt to creative tasks will result in excessive false-positive null reports. Route creative tasks to a standard generation prompt without evidence constraints.

03

Required Input: Structured Query Log

Risk: Without the original search query and retrieval metadata, the model cannot diagnose why evidence is missing. Guardrail: Always pass the exact query string, the retrieval source identifier, and the number of results returned as part of the [CONTEXT] block to enable accurate alternative query suggestions.

04

Operational Risk: Infinite Retry Loops

Risk: A naive implementation might feed the prompt's suggested alternative queries directly back into the same failed retrieval system, causing an infinite loop. Guardrail: Implement a maximum retry depth (e.g., 2 hops) in the application harness. If null evidence persists after retries, escalate to a human review queue or a fallback model.

05

Good Fit: Compliance Audit Trails

What to watch: Auditors need proof that a claim was checked, not just that it's unsupported. Guardrail: The structured null_evidence_report output, including the search_attempted and alternative_queries fields, serves as a verifiable audit artifact proving due diligence was performed rather than the check being skipped.

06

Bad Fit: Real-Time Chat with Low Latency Budgets

Avoid when: the user expects an immediate conversational answer and the retrieval store is known to be sparse. Guardrail: The structured null-handling output adds latency and breaks conversational flow. In low-latency chat, use a faster binary classifier to decide whether to invoke this heavy verification prompt or fall back to a generic 'I don't know' response.

PROMPT PLAYBOOK

Copy-Ready Prompt Template

A production-ready template for matching claims to evidence with explicit null-evidence handling, preventing silent failures in automated verification pipelines.

This template is designed for automated fact-checking and RAG verification pipelines where the retrieval step may return zero results. Unlike standard evidence-matching prompts that assume evidence exists, this template requires the model to explicitly document when no evidence is found, including the search queries used and suggested alternative queries. This prevents the model from hallucinating evidence or silently marking claims as unverified without explanation. Use this template when you need auditable, traceable null-evidence handling in production systems.

text
You are an evidence matching system. Your task is to match each provided claim against the provided evidence set and produce a structured output. If no evidence is found for a claim, you must explicitly document this rather than remaining silent.

## INPUT

**Claims to verify:**
[CLAIMS]

**Evidence set:**
[EVIDENCE]

**Search queries used to retrieve evidence:**
[SEARCH_QUERIES]

## OUTPUT SCHEMA

Return a JSON object with the following structure:

```json
{
  "claim_matches": [
    {
      "claim_id": "string",
      "claim_text": "string",
      "match_status": "supported | contradicted | insufficient | no_evidence_found",
      "matched_evidence": [
        {
          "evidence_id": "string",
          "evidence_text": "string",
          "relevance_score": 0.0-1.0,
          "match_type": "direct_quote | paraphrase | inference",
          "relationship": "supports | contradicts | partially_supports"
        }
      ],
      "null_evidence_handling": {
        "is_null_result": true/false,
        "search_queries_used": ["string"],
        "reason_no_evidence": "no_results_returned | results_irrelevant | insufficient_coverage",
        "suggested_alternative_queries": ["string"],
        "evidence_gap_description": "string"
      },
      "confidence": 0.0-1.0,
      "requires_human_review": true/false
    }
  ],
  "summary": {
    "total_claims": 0,
    "supported": 0,
    "contradicted": 0,
    "insufficient": 0,
    "no_evidence_found": 0,
    "null_result_rate": 0.0
  }
}

CONSTRAINTS

  1. Null evidence is a valid output. If the evidence set is empty or contains no relevant passages, set match_status to no_evidence_found and populate the null_evidence_handling block completely.
  2. Document search queries. Always include the search queries that were used. If none were provided, note this in reason_no_evidence.
  3. Suggest alternatives. When no evidence is found, propose at least one alternative search query that might surface relevant evidence.
  4. Never fabricate evidence. If you cannot find supporting or contradicting evidence, do not invent it. Use the no_evidence_found status.
  5. Distinguish insufficient from no evidence. Use insufficient when evidence exists but is too weak, partial, or ambiguous to confirm or refute the claim. Use no_evidence_found when the evidence set contains nothing relevant.
  6. Flag for human review when confidence is below [CONFIDENCE_THRESHOLD] or when claims are high-risk per [RISK_LEVEL].
  7. Preserve claim IDs. Match the claim_id exactly as provided in the input.

EXAMPLES

Example 1: Evidence found Input claim: "The company reported $2.3B in revenue for Q3 2024." Evidence: "Q3 2024 earnings release shows total revenue of $2.3 billion, up 12% YoY." Output: match_status: "supported", matched_evidence with direct_quote, confidence: 0.95

Example 2: No evidence found Input claim: "The CEO announced a new AI division in January 2025." Evidence: [empty set] Search queries used: ["CEO AI division announcement January 2025", "new AI division company name 2025"] Output: match_status: "no_evidence_found", null_evidence_handling.is_null_result: true, suggested_alternative_queries: ["company name AI division press release 2025", "CEO strategic initiatives 2025"]

Example 3: Insufficient evidence Input claim: "The product launch will increase market share by 15%." Evidence: "Company press release mentions product launch planned for Q2 but does not include market share projections." Output: match_status: "insufficient", confidence: 0.2, requires_human_review: true

Before deploying this template, replace the square-bracket placeholders with your actual data. [CLAIMS] should be a JSON array of claim objects with claim_id and claim_text fields. [EVIDENCE] should be a JSON array of evidence objects with evidence_id and evidence_text fields. [SEARCH_QUERIES] should be an array of strings representing the queries used to retrieve the evidence. Set [CONFIDENCE_THRESHOLD] to a numeric value between 0 and 1 (e.g., 0.7) below which claims are flagged for human review. Set [RISK_LEVEL] to low, medium, or high to adjust the sensitivity of the human review flagging. For high-risk domains such as healthcare, legal, or financial verification, always require human review for no_evidence_found and insufficient statuses regardless of confidence score.

After adapting the template, validate the output against the JSON schema before allowing it to proceed downstream. Common failure modes include the model omitting the null_evidence_handling block when evidence is missing, fabricating plausible-sounding evidence when the evidence set is empty, or conflating insufficient with no_evidence_found. Run eval tests with deliberately empty evidence sets to confirm the model produces explicit null-evidence outputs rather than hallucinating. For production pipelines, log every instance where null_evidence_handling.is_null_result is true and monitor the null_result_rate in the summary to detect retrieval failures early.

IMPLEMENTATION TABLE

Prompt Variables

Required inputs for the Evidence Matching with Null Evidence Handling Prompt. Each variable must be populated before the prompt is assembled and sent. Validation notes describe how to check the input at the application layer before the model call.

PlaceholderPurposeExampleValidation Notes

[CLAIM]

The factual assertion to verify against available evidence

The Acme 3000 processor achieves 4.2 TFLOPS in FP16

Must be a single atomic claim. Reject if input contains multiple claims, hedging language that makes verification impossible, or exceeds 500 characters

[EVIDENCE_SET]

Retrieved documents, passages, or source records to search for supporting or contradicting evidence

JSON array of objects with source_id, text, publication_date, and authority_score fields

Must be valid JSON. Reject if empty array is passed without explicit null-evidence handling flag set to true. Validate that each record has a non-empty text field

[NULL_EVIDENCE_FLAG]

Explicit boolean signaling that the retrieval system returned zero results

Must be true or false. When true, [EVIDENCE_SET] must be an empty array. When false, [EVIDENCE_SET] must contain at least one record. Mismatch triggers application-layer rejection before prompt assembly

[SEARCH_QUERY_USED]

The exact query string sent to the retrieval system that produced the evidence set or empty result

Acme 3000 FP16 TFLOPS benchmark specification

Required when [NULL_EVIDENCE_FLAG] is true. Must be a non-empty string. Log this value alongside the prompt for debugging retrieval gaps

[OUTPUT_SCHEMA]

The expected JSON structure for the verification result including null-evidence fields

See output contract: requires claim_id, match_status, evidence_links, null_evidence_handling object

Validate that schema includes null_evidence_handling fields: search_query_documented, alternative_queries_suggested, retrieval_debug_info. Reject schemas missing these fields for null-evidence workflows

[DOMAIN]

The knowledge domain of the claim, used to calibrate evidence sufficiency thresholds and suggest alternative queries

semiconductor_benchmarks

Must match an allowed domain enum value. Used to select domain-specific alternative query templates and authority weighting rules. Null allowed if domain is unknown

[CONFIDENCE_THRESHOLD]

Minimum confidence score required to auto-verify a claim without human review

0.85

Must be a float between 0.0 and 1.0. Claims scoring below this threshold route to human review. Set to 0.0 to route all claims to human review. Set to 1.0 to require perfect confidence for auto-verification

PROMPT PLAYBOOK

Implementation Harness Notes

How to wire the Evidence Matching with Null Evidence Handling prompt into a production verification pipeline with validation, retries, and observability.

This prompt is designed for a critical failure mode in automated RAG and fact-checking pipelines: the silent empty result. When a retrieval step returns zero documents, many prompts will hallucinate evidence or produce a generic 'I don't know' without documenting the failed query. This harness ensures that null-evidence states are captured as structured, auditable outputs that downstream systems can act on—whether that means escalating for human review, triggering alternative retrieval strategies, or logging the gap for index improvement.

To wire this prompt into an application, place it immediately after a retrieval step that may return an empty result set. The application should check the number of retrieved documents or the search API response code. If the count is zero, inject the original query into the [SEARCH_QUERY] placeholder and the claim into [CLAIM]. The [RETRIEVAL_SOURCE] field should identify which index, database, or API was queried. The model should be instructed to return a strict JSON schema with fields for evidence_status (must be no_evidence_found), search_query_documentation, and suggested_alternative_queries. Validate the output against this schema immediately. If evidence_status is anything other than no_evidence_found, treat it as a hallucination and retry with a stronger constraint in the system prompt, or escalate to a human operator. Log every null-evidence event with the query, the source, the timestamp, and the suggested alternatives for later retrieval pipeline analysis.

Model choice matters here. Use a model with strong instruction-following for structured output, such as GPT-4o, Claude 3.5 Sonnet, or a fine-tuned variant. Avoid smaller models that may ignore the null-evidence constraint and confabulate a match. Set temperature to 0 for deterministic behavior. Implement a retry budget of no more than 2 attempts; if the model still fails to produce a valid no_evidence_found status, route the claim to a human review queue with the full context. For high-stakes domains like healthcare or legal review, always require human sign-off on null-evidence findings before they are used to update a knowledge base or close a verification task. Wire the suggested_alternative_queries output directly into a secondary retrieval step to attempt evidence discovery through reformulated searches before finalizing the null result.

IMPLEMENTATION TABLE

Expected Output Contract

Fields, types, and validation rules for the Evidence Matching with Null Evidence Handling prompt output. Use this contract to parse, validate, and route the model response before downstream consumption.

Field or ElementType or FormatRequiredValidation Rule

verification_id

string (UUID v4)

Must match the [VERIFICATION_ID] input exactly. Reject if missing or mismatched.

claim_text

string

Must be a non-empty string matching one of the claims in [CLAIMS_LIST]. Reject if truncated or altered.

evidence_status

enum: 'evidence_found' | 'no_evidence_found' | 'search_error'

Must be exactly one of the three enum values. Reject any other string.

matched_evidence

array of objects or null

Required when evidence_status is 'evidence_found'. Must be null when evidence_status is 'no_evidence_found' or 'search_error'. Each object must contain 'source_id', 'quote', and 'match_type' fields.

matched_evidence[].source_id

string

true (when matched_evidence is present)

Must correspond to a valid source identifier from [SOURCE_MAP]. Reject unknown source_ids.

matched_evidence[].quote

string

true (when matched_evidence is present)

Must be a non-empty string. Should be a direct excerpt from the referenced source. Flag for human review if quote length exceeds 500 characters.

matched_evidence[].match_type

enum: 'supports' | 'contradicts' | 'partially_supports'

true (when matched_evidence is present)

Must be exactly one of the three enum values. Reject any other string.

search_queries_used

array of strings

Must contain at least one non-empty string representing the search query executed. Required even when evidence_status is 'no_evidence_found' to document retrieval attempt.

alternative_queries_suggested

array of strings or null

Required when evidence_status is 'no_evidence_found'. Must contain 1-3 alternative search query strings. Must be null when evidence_status is 'evidence_found'.

null_evidence_rationale

string or null

Required when evidence_status is 'no_evidence_found'. Must explain why no evidence was found (e.g., 'zero results returned', 'all results irrelevant'). Must be null when evidence_status is 'evidence_found'.

confidence_score

number (0.0 to 1.0)

Must be a float between 0.0 and 1.0 inclusive. Score of 0.0 indicates no confidence in the evidence match. Flag for human review if confidence_score < [CONFIDENCE_THRESHOLD].

requires_human_review

boolean

Must be true if confidence_score < [CONFIDENCE_THRESHOLD] or evidence_status is 'search_error'. Must be false otherwise.

PRACTICAL GUARDRAILS

Common Failure Modes

Evidence matching with null results breaks silently in production. These are the most common failure modes and how to prevent them before they corrupt downstream pipelines.

01

Silent Null Passing as Evidence

What to watch: The model receives zero search results but fabricates plausible-sounding evidence instead of reporting the null condition. This is the most dangerous failure mode because downstream systems treat fabricated text as verified evidence. Guardrail: Require an explicit evidence_found: false boolean field in the output schema and validate it before any downstream processing. If the field is missing or true but the evidence array is empty, reject the response and retry with stronger null-handling instructions.

02

Search Query Omission in Null Reports

What to watch: The model correctly identifies no evidence but fails to document which search queries were attempted. This makes debugging impossible—you cannot tell whether the null result came from a bad query, an empty index, or a retrieval pipeline failure. Guardrail: Require a search_queries_attempted array in every null-evidence output. Validate that it is non-empty and contains the actual query strings used. Log these queries alongside the null result for retrieval pipeline observability.

03

Overconfident Null Without Alternative Queries

What to watch: The model reports 'no evidence found' but provides no suggested alternative queries. This treats a retrieval gap as a definitive absence of evidence rather than a possible search strategy failure. Guardrail: Require a suggested_alternative_queries field with at least one reformulated query. Validate that alternatives differ meaningfully from the original queries—exact duplicates indicate the model is not actually reasoning about retrieval strategy.

04

Null Result Collapse Across Multiple Claims

What to watch: When processing multiple claims in a batch, the model collapses all null results into a single generic 'no evidence found' statement without per-claim granularity. This makes it impossible to route individual claims for human review or alternative retrieval. Guardrail: Structure the output schema to require per-claim null reporting. Each claim must have its own evidence_status, search_queries_attempted, and suggested_alternative_queries. Validate that the number of claim entries matches the input claim count.

05

Null Confused with Negative Evidence

What to watch: The model conflates 'no evidence found' with 'evidence contradicts the claim.' A null result means the retrieval returned nothing; a contradiction means evidence was found that disputes the claim. Conflating these produces false contradiction flags. Guardrail: Use distinct output labels: evidence_status must be one of supported, contradicted, insufficient, or no_results. Validate that no_results outputs never contain evidence excerpts or contradiction reasoning. Train evaluators to flag any no_results response that includes evidence content.

06

Retry Loop Exhaustion Without Escalation

What to watch: The system retries null results with alternative queries but never escalates when retries also return empty. This creates infinite loops or silent drops where claims disappear from the verification pipeline. Guardrail: Implement a retry budget with a hard maximum of 2-3 query reformulation attempts per claim. After exhaustion, route the claim to a human review queue with the full query history and null documentation attached. Log exhaustion events as a retrieval pipeline health metric.

IMPLEMENTATION TABLE

Evaluation Rubric

Use this rubric to test the Evidence Matching with Null Evidence Handling Prompt before shipping. Each criterion targets a specific failure mode in automated pipelines where silent null handling breaks downstream processes.

CriterionPass StandardFailure SignalTest Method

Null Evidence Output Structure

Output contains explicit 'no_evidence_found: true' field when no sources match

Output returns empty array, null, or generic 'no results' string without structured null flag

Run prompt with 5 queries known to return zero results; validate JSON schema for null-evidence fields

Search Query Documentation

Original search query and any applied filters are preserved in output under [SEARCH_QUERY] field

Output omits the query that produced zero results, making debugging impossible

Parse output for query field presence; verify query matches input exactly including any metadata filters

Alternative Query Suggestions

Output includes 2-5 specific, reformulated search queries in [ALTERNATIVE_QUERIES] array when no evidence found

Output returns empty suggestions, generic suggestions, or suggestions identical to original query

Check array length >= 2; verify each suggestion differs from original query by at least one substantive term change

No Hallucinated Evidence

Zero evidence items appear in output when retrieval returns empty; no fabricated quotes or source identifiers

Output contains any evidence object, quote, or source reference despite null retrieval results

Scan all evidence fields for non-null values; verify source identifiers do not resolve to real documents in test corpus

Confidence Score for Null Case

Output includes [CONFIDENCE] score explicitly set to 0 or 'none' when no evidence found

Output returns confidence > 0 or omits confidence field entirely for null-evidence case

Assert confidence field exists and value is 0, 0.0, or 'none'; reject any positive confidence on null evidence

Failure Mode Classification

Output classifies the null result type: 'no_indexed_sources', 'query_mismatch', or 'information_gap' in [NULL_REASON] field

Output provides no classification or uses generic 'not found' without diagnostic category

Validate [NULL_REASON] is one of the three enumerated values; reject free-text without classification

Downstream Pipeline Compatibility

Output schema is identical for evidence-found and null-evidence cases; only evidence array is empty

Output changes structure between success and null cases, breaking JSON parsers in automated pipelines

Run same JSON Schema validator against both success and null outputs; assert structural equivalence except evidence array length

Retry Guidance

Output includes [RETRY_INSTRUCTIONS] with specific parameter changes when null reason is 'query_mismatch'

Output suggests retry with no parameter changes or omits retry guidance entirely

Check retry field presence when null_reason is query_mismatch; verify suggested changes are actionable parameter modifications

ADAPTATION OPTIONS

Adapt This Prompt

How to adapt

Start with the base prompt and a small set of test claims where you know some have zero evidence. Remove strict output schema requirements initially—just ask for a structured summary with evidence_found, search_queries_used, and alternative_queries fields. Use a single model call without retries.

code
For the claim: [CLAIM]
Search results returned: [SEARCH_RESULTS]

If no results were found, state that explicitly and suggest 2 alternative search queries.

Watch for

  • Model inventing evidence when [SEARCH_RESULTS] is empty or an empty list string
  • Skipping the alternative_queries field when evidence is absent
  • Conflating 'no results' with 'results that don't support the claim'
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.