All solutions
SOPs & regional addendaUpdated 2026-12-03

How do I stop a RAG chatbot from citing old handbooks instead of regional policy addenda?

Direct answer

Stop RAG chatbots from citing outdated handbooks or broad base policies by storing explicit override and supersession edges rather than relying on vector similarity alone. Mackerel resolves override chains deterministically and returns separate governing, overridden, and superseded arrays in one API response.

Why standard retrieval breaks here

  • Global policies are longer and richer in keywords than terse regional addenda, causing similarity search to rank the wrong document #1.
  • Retired 2024 handbooks remain indexed alongside 2026 updates, creating contradictions inside the LLM context window.
  • Prompting an LLM to 'pick the newest or most specific chunk' fails unpredictably across multi-hop exceptions.

How Mackerel solves it

Explicit overrides edges

Link each regional addendum, contractor rule, or Enterprise rider directly to the base rule_key it overrides.

Hard superseded_by exclusions

Retired clauses are never promoted to governing; they appear only in superseded for audit transparency.

Auditable hop trace

Every response includes trace.hops showing the exact path from base policy to active addendum.

Upsert an addendum that overrides a base policy

curl -X POST https://api.runmackerel.com/v1/corpora/acme_security/rules \
  -H "Authorization: Bearer $MACKEREL_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "rule_key": "sec-1-gov",
    "source": "FedRAMP Addendum",
    "section": "§1(a) GovCloud SSH",
    "text": "GovCloud production SSH is prohibited; use recorded bastion sessions.",
    "effective": "2026-06-01",
    "acl": ["security"],
    "overrides": ["sec-1"]
  }'

Custom corpora and rule graph ingestion are included on all plans ($0.50 free credits to start; $2.00 per 1,000 Flash searches).

Frequently asked questions

Can a single rule override multiple base rules?
Yes. The overrides field accepts an array of base rule_key identifiers, and Mackerel resolves multi-hop chains from the base rule to the narrowest matching leaf.
Get startedRead the quickstartNew workspaces start with $0.50 in free credits. No card required.