Why it matters

Ungrounded responses erode trust. Grounding is table stakes for RAG. Understanding shapes user-facing apps.

Advertisement

The architecture

Retrieved documents include IDs.

Prompt tells LLM to cite sources per claim.

Response includes citation markers.

RAG grounding patternRetrieve with IDseach doc identifiedPrompt for citationscite claim → sourceRender with linksclickable sourcesStructured output (JSON with citations) more reliable than prose citations
Grounding flow.
Advertisement

How it works end to end

Structured output: prompt LLM to return JSON with claims + citations. Easier to parse and render.

Verification: check LLM cited actual retrieved content, not hallucinated.

UI: render as footnotes or inline links.