This prompt is for verification engineers, data analysts, and AI pipeline builders who need to programmatically validate claims about confidence intervals, margins of error, and uncertainty quantification. Use it when a source document, report, or model output asserts an interval estimate and you must verify that the confidence level, construction method, and interpretation are internally consistent and mathematically sound. The primary job-to-be-done is automated audit: you have a stated claim (e.g., 'the 95% confidence interval is 48% to 52%') and supporting evidence (sample size, standard error, distribution assumptions), and you need a structured verdict on whether the claim holds up against that evidence.
Prompt
Confidence Interval and Margin of Error Verification Prompt

When to Use This Prompt
Defines the ideal user, required inputs, and operational boundaries for the Confidence Interval and Margin of Error Verification Prompt.
This prompt is not a general statistics tutor. It assumes you already have the claimed interval, the claimed confidence level, and the underlying sample data or summary statistics. It does not compute intervals from raw data; it verifies whether a stated interval aligns with the evidence provided. Common triggers include audit workflows checking survey methodology, automated fact-checking of research claims, and QA pipelines for AI-generated statistical summaries. The prompt works best when you can supply the original claim verbatim, the numerical evidence, and the expected confidence level—without these three inputs, verification quality degrades sharply.
Do not use this prompt when you need to calculate a confidence interval from scratch, when the underlying data distribution is unknown and must be inferred, or when the claim involves Bayesian credible intervals without a specified prior. It is also unsuitable for verifying prediction intervals, tolerance intervals, or bootstrap intervals unless you explicitly adapt the [CONSTRAINTS] block to specify the interval type. For high-stakes domains like clinical trial reporting or regulatory filings, always route the prompt output through human review and cross-reference against the original statistical software output rather than treating the model's verification as authoritative.
Use Case Fit
Where the Confidence Interval and Margin of Error Verification Prompt works, where it fails, and the operational prerequisites for production use.
Good Fit: Statistical Reporting QA
Use when: you need to verify that a reported confidence interval matches the underlying data, sample size, and stated confidence level. Guardrail: Always provide the raw summary statistics (n, mean, SD) alongside the claim so the model can recompute rather than guess.
Bad Fit: Raw Data Exploration
Avoid when: you expect the model to compute intervals directly from large raw datasets. LLMs are not statistical packages. Guardrail: Pre-compute summary statistics in your application code (Python, R, SQL) and pass only the aggregates to the prompt for verification and interpretation checks.
Required Inputs
What you must provide: the claimed interval bounds, the stated confidence level, the sample size, the point estimate, and either the standard error or standard deviation. Guardrail: If any of these fields are missing, the prompt should return an insufficient_data status rather than hallucinating a verification result.
Operational Risk: Interval Type Confusion
What to watch: the model may conflate confidence intervals, prediction intervals, credible intervals, and tolerance intervals. Guardrail: Include an explicit interval_type field in your input schema and instruct the model to flag mismatches between the stated type and the construction method before verifying the numbers.
Operational Risk: Asymmetric Interval Blindness
What to watch: many verification prompts assume symmetric intervals (point estimate ± margin). For proportions near 0 or 1, odds ratios, or bootstrap intervals, this assumption breaks. Guardrail: Add a pre-check step that asks the model to classify the interval as symmetric or asymmetric before applying tolerance windows, and route asymmetric cases to a specialized verification path.
Production Harness Requirement
What to watch: standalone prompt evaluation misses cumulative drift across batch verification runs. Guardrail: Log every verification result with the computed margin of error, the tolerance window used, and the pass/fail decision. Run periodic calibration checks against a golden set of manually verified intervals to detect model drift or tolerance creep.
Copy-Ready Prompt Template
A ready-to-adapt prompt for verifying confidence interval and margin of error claims against source data and methodological standards.
This prompt template provides a structured verification harness for checking claims about confidence intervals, margins of error, and uncertainty quantification. It is designed to be copied directly into your verification pipeline, with square-bracket placeholders that you replace with the specific claim, source data, and evaluation parameters before sending to the model. The template enforces a rigorous output schema that separates interval construction verification from interpretation correctness, ensuring your verification results are machine-readable and auditable.
textYou are a statistical verification specialist. Your task is to verify a claim about a confidence interval or margin of error against provided source data and methodological context. ## CLAIM TO VERIFY [CLAIM_TEXT] ## SOURCE DATA [DATA_TABLE_OR_SUMMARY_STATISTICS] ## METHODOLOGICAL CONTEXT - Sample size: [SAMPLE_SIZE] - Sampling method: [SAMPLING_METHOD] - Confidence level claimed: [CONFIDENCE_LEVEL] - Population parameter estimated: [PARAMETER_TYPE] - Interval type (confidence, prediction, tolerance): [INTERVAL_TYPE] - Distribution assumptions: [DISTRIBUTION_ASSUMPTIONS] ## VERIFICATION INSTRUCTIONS 1. Recalculate the interval using the provided data and standard formulas appropriate for the stated sampling method and distribution assumptions. 2. Compare the recalculated interval to the claimed interval. Apply a tolerance of [TOLERANCE] for rounding differences. 3. Verify that the confidence level interpretation is correct: a [CONFIDENCE_LEVEL]% confidence interval means that if the sampling procedure were repeated many times, approximately [CONFIDENCE_LEVEL]% of the constructed intervals would contain the true population parameter. 4. Check for common errors: confusion between confidence and prediction intervals, asymmetric interval mishandling, incorrect standard error calculation, and misinterpretation of the interval as a probability statement about the parameter. 5. Flag any unsupported assumptions or missing methodological details that prevent full verification. ## OUTPUT SCHEMA Return a JSON object with this exact structure: { "verification_result": "VERIFIED" | "UNVERIFIED" | "CONTRADICTED" | "INSUFFICIENT_EVIDENCE", "recalculated_interval": { "lower_bound": number | null, "upper_bound": number | null, "margin_of_error": number | null }, "claimed_interval": { "lower_bound": number | null, "upper_bound": number | null, "margin_of_error": number | null }, "interval_match": boolean | null, "confidence_level_verified": boolean, "interpretation_errors": [ { "error_type": "CONFIDENCE_PREDICTION_CONFUSION" | "PROBABILITY_MISINTERPRETATION" | "ASYMMETRIC_INTERVAL_ERROR" | "SE_CALCULATION_ERROR" | "OTHER", "description": "string", "severity": "CRITICAL" | "MAJOR" | "MINOR" } ], "assumption_violations": ["string"], "missing_information": ["string"], "verification_notes": "string" } ## CONSTRAINTS - Do not invent data or assumptions. If information is missing, mark the claim as INSUFFICIENT_EVIDENCE and list what is needed. - Use standard statistical formulas. Document which formula you applied in verification_notes. - If the interval type is asymmetric (e.g., bootstrap percentile intervals), note this in verification_notes and explain how the comparison was performed. - For survey-based claims, check whether the margin of error accounts for design effects if the sampling method is complex.
To adapt this template for your verification pipeline, replace each square-bracket placeholder with concrete values from the claim you are checking. The [DATA_TABLE_OR_SUMMARY_STATISTICS] placeholder should contain the raw or summary data needed for recalculation—this could be a CSV snippet, a table of summary statistics, or a structured description of the data. The [TOLERANCE] value should reflect your acceptable rounding error (typically 0.01 for percentages or a small fraction of the standard error). If your verification workflow involves multiple claims, wrap this prompt in a batch processing loop that iterates over claims and collects structured outputs for downstream aggregation.
Before deploying this prompt in production, test it against known-good and known-bad interval claims to calibrate the tolerance window and verify that the model correctly distinguishes between confidence, prediction, and tolerance intervals. Pay particular attention to asymmetric interval handling—many models default to symmetric interval assumptions and will misclassify valid bootstrap or profile likelihood intervals as errors. If your use case involves regulated reporting (e.g., clinical trial results, official statistics), always route UNVERIFIED and CONTRADICTED results to a human reviewer with the full verification payload attached.
Prompt Variables
Required and optional inputs for the Confidence Interval and Margin of Error Verification Prompt. Validate each placeholder before execution to prevent silent failures in interval construction checks and interpretation verification.
| Placeholder | Purpose | Example | Validation Notes |
|---|---|---|---|
[CLAIM_TEXT] | The full text of the statistical claim to verify, including the interval estimate and any stated confidence level | "The survey found 52% approval with a margin of error of ±3.2 percentage points at the 95% confidence level" | Must contain an interval or margin of error statement. Parse check: extract numeric bounds and stated confidence level. Fail if no interval or margin is present. |
[SOURCE_DATA] | The underlying data or methodology description used to construct the interval, including sample size, point estimate, and standard error if available | n=1,204; p̂=0.52; SE=0.0163; design effect=1.2 | Must include sample size at minimum. Null allowed if verifying from methodology description only. Validate that sample size is positive integer. Flag if standard error is missing when verifying calculation correctness. |
[CONFIDENCE_LEVEL_CLAIMED] | The confidence level stated in the claim, extracted as a numeric value between 0 and 1 or 0 and 100 | 0.95 | Must be numeric and between 0 and 1 (or 0 and 100 if percentage). Parse check: normalize to decimal. Fail if confidence level is missing from claim or ambiguous. Flag if common misinterpretations detected such as 95% stated as 0.95 in percentage context. |
[INTERVAL_TYPE] | The type of interval being verified: confidence interval, prediction interval, credible interval, or tolerance interval | confidence | Must be one of: confidence, prediction, credible, tolerance. Parse check: enum validation. Fail if type cannot be determined from claim context. This field drives the interpretation verification logic and method appropriateness checks. |
[METHOD_DESCRIPTION] | Description of how the interval was constructed, including distribution assumptions, formula used, and any corrections applied | Wald interval with finite population correction, normal approximation assumed | Null allowed if method is not disclosed. If provided, validate against known interval construction methods. Flag if method is inconsistent with interval type or data characteristics such as Wald interval used with small sample size or extreme proportions. |
[TOLERANCE_BOUNDS] | Acceptable tolerance for numerical verification of interval endpoints, expressed as absolute or relative margin | absolute=0.005, relative=0.001 | Must specify at least one tolerance type with numeric value. Default to absolute=0.001 if not provided. Validate that tolerance is appropriate for the precision of the claim. Flag if tolerance is too tight for the data precision or too loose to detect meaningful errors. |
[ADDITIONAL_CONTEXT] | Supplementary information about the claim source, domain conventions, or special verification requirements | Political polling with stratified random sample, AAPOR standards apply, asymmetric interval expected for proportions near 0 or 1 | Null allowed. If provided, use to adjust verification criteria and interpretation checks. Validate that context is relevant to the claim domain. Flag if context contradicts the stated methodology or interval type. |
Implementation Harness Notes
How to wire the Confidence Interval and Margin of Error Verification Prompt into a production verification pipeline with validation, logging, and human review routing.
This prompt is designed to be called as a verification step after claim extraction, not as a standalone user-facing chatbot. Wrap it in a function that validates inputs before sending, parses the JSON output, and routes failures to human review. The function should accept a claim object containing the claim text, the reported interval bounds, the stated confidence level, the sample size if available, and any source context. Before calling the model, validate that the claim text is non-empty, the interval bounds are numeric and ordered (lower < upper), and the confidence level is between 0 and 1. Reject malformed inputs at the application layer rather than relying on the model to catch them.
For batch verification pipelines, run this prompt per claim and aggregate results into a verification report. Set temperature to 0 for deterministic outputs. Use structured output mode if your model provider supports it; otherwise, append a strict JSON schema instruction to the prompt. Log every verification result with the claim ID, timestamp, model version, and raw response for audit trails. If the model returns verification_status: insufficient_data, do not retry with the same inputs; escalate to a human analyst with the claim source text and available evidence packaged together. Retries are only appropriate for transient model errors, not for insufficient-evidence outcomes.
When integrating with upstream claim extraction, ensure the claim object includes the original source text span so the verification prompt can check whether the interval was reported as symmetric or asymmetric, whether the confidence level was explicitly stated, and whether the claim confuses confidence intervals with prediction intervals. Downstream, route verification_status: verified claims to automated reporting, verification_status: contradicted claims to a contradiction resolution queue, and verification_status: insufficient_data claims to human review with a pre-populated review packet containing the claim, source text, and any evidence snippets retrieved. Avoid building automated retry loops around insufficient-data outcomes; they waste tokens and delay human review.
Expected Output Contract
Validation rules for the structured verification result returned by the Confidence Interval and Margin of Error Verification Prompt. Use this contract to parse, validate, and route the model response in your application harness.
| Field or Element | Type or Format | Required | Validation Rule |
|---|---|---|---|
verification_id | string (UUID) | Must parse as valid UUID v4. Reject if missing or malformed. | |
claim_summary | string | Must be non-empty and contain the original interval estimate claim. Length 10-500 characters. | |
confidence_level_claimed | number or null | If present, must be a float between 0 and 100. If the claim does not state a level, value must be null. Reject negative values or values over 100. | |
interval_type_detected | enum string | Must be one of: 'confidence_interval', 'prediction_interval', 'credible_interval', 'margin_of_error', 'unspecified'. Reject any other value. | |
interval_bounds | object | Must contain 'lower' (number) and 'upper' (number) with lower < upper. If the claim is one-sided, the missing bound must be null. Reject if both bounds are null. | |
methodology_check | object | Must contain 'method_stated' (boolean) and 'method_plausible' (boolean or null). If method_stated is false, method_plausible must be null. Reject if method_plausible is not null when method_stated is false. | |
interpretation_issues | array of strings | Must be a JSON array. Allowed values: 'confidence_level_misinterpretation', 'prediction_interval_confusion', 'asymmetric_interval_ignored', 'margin_of_error_misuse', 'none'. Reject if array contains unrecognized strings. | |
verification_verdict | enum string | Must be one of: 'consistent', 'inconsistent', 'unverifiable'. Reject any other value. If 'unverifiable', the evidence_summary field must explain why. | |
evidence_summary | string | Must be non-empty. If verdict is 'unverifiable', must contain an explicit reason. Length 20-1000 characters. Reject if empty or only whitespace. | |
requires_human_review | boolean | Must be true if verdict is 'inconsistent' or 'unverifiable', or if interpretation_issues contains any value other than 'none'. Reject if false when these conditions are met. |
Common Failure Modes
Confidence interval and margin of error verification breaks in predictable ways. These are the most common failure modes and how to guard against them before they reach a human reviewer or downstream system.
Confidence Level Confusion
What to watch: The model treats a 90% confidence interval as interchangeable with a 95% interval, or misinterprets the confidence level as the probability that a specific interval contains the true value. Guardrail: Explicitly require the model to state the confidence level used, verify it matches the source claim, and flag any mismatch. Include a schema field for confidence_level and validate it against the claim before accepting the output.
Symmetric Interval Assumption on Asymmetric Data
What to watch: The model applies a symmetric margin of error to a proportion near 0 or 1, or to skewed distributions where a symmetric interval is inappropriate. This produces nonsensical bounds like negative proportions or impossible values. Guardrail: Add a constraint requiring the model to check boundary validity. If the interval crosses an impossible threshold, flag it and request an asymmetric method such as Wilson score or Clopper-Pearson.
Confidence Interval vs Prediction Interval Swap
What to watch: The model confuses a confidence interval for a mean with a prediction interval for an individual observation, producing intervals that are far too narrow for the claim being verified. Guardrail: Include a required classification step in the prompt that forces the model to identify whether the claim refers to a population parameter or an individual prediction before selecting the verification method.
Margin of Error Without Sample Size
What to watch: The model accepts or calculates a margin of error without checking whether the sample size is reported and sufficient. Small samples produce wide intervals that make the claim effectively meaningless. Guardrail: Require the model to extract or request the sample size. If absent, mark the claim as insufficient_information rather than attempting verification. Add a minimum sample size threshold in the eval harness.
Overlooking Survey Design Effects
What to watch: The model calculates a margin of error using simple random sampling formulas when the source used clustering, stratification, or weighting, producing intervals that are artificially narrow. Guardrail: Prompt the model to check for design effect language in the source. If complex survey methods are mentioned but no design effect is reported, flag the interval as potentially underestimated and request the design effect or effective sample size.
Multiple Comparison Inflation
What to watch: The model verifies individual confidence intervals across many subgroups or endpoints without adjusting for multiplicity, leading to false confidence that all intervals are simultaneously valid. Guardrail: When the claim involves multiple intervals, require the model to note whether a multiplicity correction was applied. If not, add a caveat that the familywise error rate is inflated and flag for human review if the number of comparisons exceeds a threshold.
Evaluation Rubric
How to test output quality before shipping. Run these checks against a golden dataset of 20-30 known claims with verified outcomes.
| Criterion | Pass Standard | Failure Signal | Test Method |
|---|---|---|---|
Confidence Level Match | Reported confidence level matches the stated level in the claim (e.g., 95% CI is verified as 95%) | Output reports a different confidence level than the claim specifies, or fails to identify the stated level | Parse output.confidence_level; assert equality with golden_dataset.expected_confidence_level |
Interval Boundary Accuracy | Lower and upper bounds match golden dataset values within a tolerance of ±0.5% of the interval width | Bound values deviate beyond tolerance, or interval direction is inverted (lower > upper) | Compute abs(output.lower_bound - expected.lower_bound) / (expected.upper_bound - expected.lower_bound); assert < 0.005 |
Margin of Error Calculation | Margin of error equals (upper_bound - lower_bound) / 2 within ±0.1% of the point estimate scale | Calculated margin of error differs from expected by more than tolerance, or formula is applied incorrectly for asymmetric intervals | Calculate output.margin_of_error; assert abs(output.margin_of_error - expected.margin_of_error) / expected.point_estimate < 0.001 |
Interval Type Classification | Correctly classifies interval as confidence, prediction, credible, or tolerance interval | Misclassifies interval type (e.g., labels a prediction interval as a confidence interval) | Assert output.interval_type equals golden_dataset.expected_interval_type |
Asymmetric Interval Handling | For asymmetric intervals, reports both bounds without forcing symmetry and notes asymmetry in interpretation field | Forces symmetric margin of error on an asymmetric interval, or fails to flag the asymmetry | Check output.is_asymmetric is true when expected; assert output.interpretation_notes contains 'asymmetric' |
Methodology Identification | Identifies the interval construction method (Wald, bootstrap, Bayesian credible, etc.) when source context provides it | Omits method when source context includes it, or hallucinates a method not present in source | Assert output.method in golden_dataset.expected_methods; assert output.method_source is 'provided_context' or 'unknown' |
Interpretation Correctness | Interpretation text correctly explains what the interval represents without probability-of-truth language for frequentist intervals | Uses 'probability the true value is in the interval' for a frequentist confidence interval, or misstates what the interval contains | LLM-as-judge eval: prompt with rubric checking for correct frequentist vs Bayesian interpretation language; assert score >= 4/5 |
Sample Size Adequacy Flag | Flags when sample size is too small for the interval method used (e.g., n<30 for normal approximation) | Fails to flag small sample when method assumptions require larger n, or flags adequate samples incorrectly | Assert output.sample_size_adequate equals golden_dataset.expected_sample_size_adequate |
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 model call and manual review of outputs. Focus on getting the structure right before adding validation layers.
- Remove strict output schema requirements; accept free-text or loosely structured JSON.
- Replace [EVIDENCE_SOURCES] with a single pasted document.
- Skip the [TOLERANCE_WINDOW] parameter and ask the model to flag obvious mismatches.
- Use a lightweight prompt: "Given this claim and this source data, does the confidence interval or margin of error appear correctly constructed and interpreted?"
Watch for
- The model accepting the claim's interval without checking the underlying method.
- Confusion between confidence level (e.g., 95%) and the interval width.
- No distinction between confidence intervals and prediction intervals.
- Overly verbose explanations that bury the verification result.

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