Available now. The first paid PRISM API.
100 calls / month free with any signed-in account. Provision a key, copy the secret once, start verifying citations. Get an API key →
API reference · Live
Hallucination Guard API
Citation cross-walking for legal, financial, and insurance AI output. Inspect generated text for case citations, statute references, policy provisions, and reporter cites against user-supplied source material.
Powers the hosted Loss Run Analyzer and the citation-flagging path inside every Prism legal / financial / insurance module.
POST /v1/guard/verify-references
Request body
| Field | Type | Description |
|---|---|---|
| text | string | AI-generated text to inspect. Required. |
| sources | string[] | Source material the citations are cross-walked against. Required, non-empty. |
| domain | string | One of legal, financial, insurance, healthcare. Picks the right pattern set. |
| strict | boolean | Optional. Default false. When true, marks any case-name pattern not in sources as flagged even when partial-match heuristics would let it through. |
Sample request: JavaScript
import { Prism } from "@prism/sdk";
const prism = new Prism({ apiKey: process.env.PRISM_API_KEY });
const result = await prism.hallucinationGuard.check({
text: aiOutput,
sources: [intakeNotes, exhibitB],
domain: "legal",
});Sample request: Python
class="tk-kw">from prism class="tk-kw">import Prism
prism = Prism(api_key=os.environ[class="tk-str">"PRISM_API_KEY"])
result = prism.hallucination_guard.check(
text=ai_output,
sources=[intake_notes, exhibit_b],
domain=class="tk-str">"legal",
)Sample request: cURL
curl https://prism.zi-find.com/api/v1/guard/verify-references \
-H "Authorization: Bearer $PRISM_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "text": "...", "sources": ["..."], "domain": "legal" }'Response
{
"tk-key">"flagged_text": "Per Smith v. Jones, 142 F.3d 891 (9th Cir. 2018) [verify], the doctrine applies...",
"tk-key">"flags": [
{
"tk-key">"type": "case_citation",
"tk-key">"raw": "Smith v. Jones, 142 F.3d 891 (9th Cir. 2018)",
"tk-key">"offset_start": 4,
"tk-key">"offset_end": 47,
"tk-key">"in_sources": false
}
],
"tk-key">"risk_score": 0.72,
"tk-key">"domain": "legal",
"tk-key">"checked_at": "2026-04-29T14:01:22Z"
}Response fields
flagged_text: original text with[verify]markers inserted after every unverified citation. Idempotent: existing markers are not duplicated.flags[]: structured list.typeis one ofcase_citation / usc / cfr / section_ref / reporter;in_sourcesis whether the cross-walk found the citation in the supplied sources.risk_score: 0.0 to 1.0. Weighted by flag count and severity. Tune your threshold against your own tolerance.
Errors specific to this endpoint
422 domain_unsupported: see Errors reference.400 invalid_requestwithfield: "sources": sources must be a non-empty array.
Performance notes
Median latency is ~80ms for <5K-character inputs, scaling roughly linearly with text length. Source size has minor impact (matching is whitespace-insensitive but still O(n+m) on the haystack). For real-time UI integration, run on the server-side AI response before forwarding to the client.