{"uid":"cap_erXK-ME6Y-RroqdI1Xv__","slug":"fahce-claim-verification-and-repair-25a89b4b","name":"FAHCE Claim Verification and Repair","description":"Review claims against evidence, resolve contradictions, and get a bounded repair plan with FAHCE.","url":"https://fahce.kinganlogic.com/api/v1/verify?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","required":["schema","evidence","candidate_output"],"properties":{"schema":{"type":"string"},"evidence":{"type":"array"},"expected_output":{"type":"string","description":"Optional response-contract and repair-target context for all operations, including Diagnose. Supported response-format directives (for example, Return JSON) and implemented explicit constraints can affect the diagnosis. Ordinary matching or mismatching factual text is not compared for string equality and is not a trusted answer oracle or supporting evidence; supply independent evidence for factual claims."},"candidate_output":{"type":"string","description":"The exact candidate output to diagnose or verify. Never use payment evidence as semantic evidence."}}},"responseSchema":{"type":"object","required":["schema","operation","request_id","input_hash","diagnosis","repair","verification","billing","receipt","next_safe_action"],"properties":{"repair":{"anyOf":[{"type":"object","required":["plan","treatment","proposed_output","status"],"properties":{"plan":{"type":"object","required":["required","bounded_steps","authority_note"],"properties":{"required":{"type":"boolean"},"validated_ir":{"type":"object"},"bounded_steps":{"type":"array","items":{"type":"object","required":["step","boundary"],"properties":{"step":{"type":"string"},"boundary":{"type":"string"}},"additionalProperties":false}},"authority_note":{"type":"string"},"claim_corrections":{"type":"array","items":{"type":"object"}}}},"status":{"const":"PROPOSED_NOT_EXECUTED"},"treatment":{"type":["object","null"]},"proposed_output":{"type":["string","null"]}},"additionalProperties":false},{"type":"null"}]},"schema":{"const":"FAHCE_MACHINE_RESPONSE_V1"},"billing":{"type":"object","required":["billable","free_retry","reason","determination_status"],"properties":{"reason":{"type":["string","null"]},"billable":{"type":"boolean"},"free_retry":{"type":"boolean"},"determination_status":{"enum":["DETERMINATION_COMPLETE","DETERMINATION_COMPLETE_NEGATIVE","DETERMINATION_NOT_PRODUCED"]}}},"binding":{"type":"object","required":["actor_id","tenant_id","nonce","idempotency_key"],"properties":{"nonce":{"type":"string"},"actor_id":{"type":"string"},"tenant_id":{"type":"string"},"tenant_model":{"enum":["PILOT_USER_ISOLATION","PAYMENT_CONTEXT_ISOLATION"],"description":"Cloudflare wallet-only purchases use PAYMENT_CONTEXT_ISOLATION: one authorization-bound principal, no human account privileges. Legacy key calls use PILOT_USER_ISOLATION."},"credential_id":{"type":["string","null"],"description":"Null for wallet-only Cloudflare machine purchases. A credential exists only for legacy key-backed calls; it is never a prerequisite for an ordinary paid buyer."},"idempotency_key":{"type":"string"},"operation_scope":{"enum":["machine:diagnose","machine:repair","machine:verify","machine:repair-bundle"],"type":"string"},"payment_context_hash":{"type":["string","null"]}}},"receipt":{"type":"object","required":["case_id","run_id","input_hash","result_hash","hash_scheme","provider","model","engine_version","created_at","response_hash_scheme","response_hash","payment_status","payment_receipt","settled_price_atomic_units"],"properties":{"model":{"type":"string"},"run_id":{"type":"string","format":"uuid"},"case_id":{"type":"string","format":"uuid"},"provider":{"type":"string"},"created_at":{"type":"string","format":"date-time"},"input_hash":{"type":"string","pattern":"^[a-f0-9]{64}$"},"hash_scheme":{"enum":["SHA256_CANONICAL_JSON_RESULT_WITH_EMPTY_RESULT_HASH_V1","SHA256_SORTED_JSON_RESULT_WITH_EMPTY_RESULT_HASH_V2"]},"result_hash":{"type":"string","pattern":"^[a-f0-9]{64}$"},"response_hash":{"type":"string","pattern":"^[a-f0-9]{64}$"},"engine_version":{"type":"string"},"payment_status":{"enum":["PILOT_KEY_NO_PAYMENT","AUTHORIZED_PENDING_GATEWAY_SETTLEMENT"]},"payment_receipt":{"type":"null","description":"Immutable origin receipt; separate gateway PAYMENT-RESPONSE is retained by the buyer."},"response_hash_scheme":{"enum":["SHA256_JSON_RESPONSE_WITH_EMPTY_RESPONSE_HASH_V1","SHA256_SORTED_JSON_RESPONSE_WITH_EMPTY_RESPONSE_HASH_V2"]},"settled_price_atomic_units":{"type":"null","description":"Origin has no confirmed gateway settlement amount. Financial confirmation is recorded separately; the original response remains immutable and settlement is never inferred."}},"additionalProperties":false},"authority":{"type":"object","properties":{"payment_approval":{"type":"string"},"integrity_support":{"type":"string"},"external_verification":{"const":"NOT_ESTABLISHED"},"permission_to_execute":{"const":"NOT_GRANTED"}}},"diagnosis":{"type":"object","required":["state","claims","contradictions","missing_evidence","missing_evidence_details","claim_ceiling"],"properties":{"state":{"enum":["HOLD","BLOCK","QUARANTINE","REPAIR_REQUIRED","CLEAR_WITH_CEILING"]},"claims":{"type":"array","items":{"type":"object","required":["id","claim","source","support","evidence_refs"],"properties":{"id":{"type":"string"},"claim":{"type":"string"},"review":{"type":"object"},"source":{"type":"string"},"support":{"enum":["SUPPORTED","UNSUPPORTED","CONTRADICTED","UNVERIFIED"]},"evidence_refs":{"type":"array","items":{"type":"string"}}},"additionalProperties":false}},"hold_reason":{"type":"object"},"claim_ceiling":{"type":"string"},"contradictions":{"type":"array","items":{"type":"object","required":["id","claim_id","reason","evidence_refs"],"properties":{"id":{"type":"string"},"reason":{"type":"string"},"claim_id":{"type":"string"},"evidence_refs":{"type":"array","items":{"type":"string"}}},"additionalProperties":false}},"missing_evidence":{"type":"array","items":{"type":"string"}},"evidence_coverage":{"type":"array","items":{"type":"object","required":["item_id","status","available_characters","inspected_characters","reasons"],"properties":{"status":{"enum":["INSPECTED","PARTIAL","OMITTED"]},"item_id":{"type":"string"},"reasons":{"type":"array","items":{"type":"string"}},"byte_inspection":{"enum":["INSPECTED","OMITTED"],"description":"Source bytes inspected; this does not establish semantic interpretation of every field."},"semantic_fields":{"type":"array","items":{"type":"object","required":["ref","source_location","subject","context","field","value","semantic_status","reason","relevant_to_claim"],"properties":{"ref":{"type":"string"},"field":{"type":"string"},"value":{},"reason":{"type":["string","null"]},"context":{"type":"object","additionalProperties":{"type":"string"}},"subject":{"type":"string"},"semantic_status":{"enum":["INTERPRETED","UNINTERPRETED"]},"source_location":{"type":"object","properties":{"line":{"type":["integer","null"]},"json_pointer":{"type":"string"}}},"relevant_to_claim":{"type":"boolean"}}}},"available_characters":{"type":"integer","minimum":0},"inspected_characters":{"type":"integer","minimum":0}}}},"missing_evidence_details":{"type":"array","items":{"type":"object","required":["scope","family","requirement"],"properties":{"scope":{"enum":["CLAIM","CASE"]},"family":{"type":"string"},"claim_id":{"type":"string"},"requirement":{"type":"string"}},"additionalProperties":false}}},"additionalProperties":false},"operation":{"enum":["diagnose","repair","verify","repair-bundle"]},"input_hash":{"type":"string","pattern":"^[a-f0-9]{64}$"},"request_id":{"type":"string","format":"uuid","description":"Determination UUID, identical to receipt.case_id and receipt.run_id. Use this UUID as receipt_id in GET /api/v1/receipts/{receipt_id}. Error-envelope request_id is a separate HTTP trace; use its receipt_id when present."},"verification":{"type":"object","required":["verified","scope","external_execution_verified"],"properties":{"scope":{"type":"string"},"verified":{"type":"boolean"},"external_execution_verified":{"const":false}},"additionalProperties":false},"execution_state":{"type":"object","properties":{"notes":{"type":"string"},"action_details":{"type":"array","items":{"type":"object"}},"claimed_execution":{"enum":["ASSERTED","NOT_ASSERTED"]},"provable_execution":{"enum":["NOT_PROVEN","PARTIALLY_PROVEN"]},"action_classification":{"type":"array","items":{"enum":["PERMISSION","APPROVAL","INTENT","REQUESTED_ACTION","QUEUED_ACTION","ATTEMPTED_ACTION","FAILED_ACTION","NONEXECUTION","REVERSED_ACTION","CLAIMED_COMPLETED_ACTION"]}}}},"next_safe_action":{"type":"object","required":["action","reason"],"properties":{"action":{"type":"string"},"reason":{"type":"string"}},"additionalProperties":false},"evidence_provenance":{"type":"array","items":{"type":"object","required":["id","item_id","sha256","source_label","trust"],"properties":{"id":{"type":"string"},"trust":{"const":"CALLER_SUPPLIED_NOT_AUTHENTICATED_SOURCE"},"sha256":{"type":"string"},"item_id":{"type":"string"},"source_label":{"type":"string"}}}}},"additionalProperties":false},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.15","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.15/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.15","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.15","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_vfGAIr0atf71NhWYTB9HO","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.15","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Checks a candidate output against provided evidence, diagnoses contradictions, and returns a bounded step-by-step repair plan","exampleAgentPrompt":"Can you check this draft answer against these three source documents I've uploaded and tell me which claims are unsupported or contradicted — and give me a step-by-step plan to fix them?","exampleUseCases":[{"title":"Hallucination check on RAG output","prompt":"I used a retrieval-augmented pipeline to answer a customer's medical question and I'm not sure the response is fully grounded — here are the source chunks and the generated answer, can you diagnose any contradictions and propose a corrected version?"},{"title":"Legal brief factual accuracy review","prompt":"Here's a draft legal brief and the case documents it's supposed to reference — can you find any claims in the brief that contradict the evidence and give me a bounded list of fixes I need to make?"},{"title":"Research summary validation","prompt":"I wrote a summary of these five research papers and I want to make sure I didn't misrepresent any findings — please check every claim in my summary against the paper excerpts I'm providing and tell me exactly what needs to be corrected."}],"resultDescription":"A structured FAHCE_MACHINE_RESPONSE_V1 object containing: a diagnosis of which claims pass or fail against evidence, a repair plan with bounded numbered steps and authority notes, a proposed corrected output string, billing determination (billable/free-retry), a cryptographic receipt, and a recommended next safe action for the calling agent.","failureModes":["Missing required fields (schema, evidence, or candidate_output) returns a 4xx validation error","Evidence array is empty or too sparse to ground any claims — diagnosis may return low-confidence or indeterminate result","candidate_output is extremely long and may hit token or processing limits","Payment not received or x402 flow incomplete — request rejected before processing","Contradictory evidence supplied by caller yields ambiguous repair plan","Idempotency key collision returns cached prior result rather than re-processing"],"whenToPreferThis":"Choose FAHCE when you need evidence-grounded verification with an actionable, bounded repair plan rather than a simple similarity score or binary pass/fail. It is especially valuable when your pipeline produces LLM-generated text that must be audited against specific source documents before delivery, or when downstream consumers require a traceable correction audit trail. Prefer it over generic LLM self-critique loops because it grounds diagnosis in caller-supplied evidence, returns a structured machine-readable response, and provides a billing receipt suitable for automated cost accounting.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-15T12:30:02.813Z","isFirstParty":false,"canonicalSlug":"fahce-claim-verification-and-repair-25a89b4b"}