grounded-citations

Ground answers and documents in numbered citations backed by a verifiable source ledger.

Updated Aug 21, 2026
One-click install
npx skills add https://github.com/ewtodd/son-of-anton --skill grounded-citations-ewtodd
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: grounded-citations
Source: https://github.com/ewtodd/son-of-anton/tree/main/skills/research/grounded-citations
Command: npx skills add https://github.com/ewtodd/son-of-anton --skill grounded-citations-ewtodd

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve? AI-generated answers and reports often contain hallucinated URLs or citations reconstructed from memory, making claims impossible to verify. This Skill eliminates that failure mode by having a ledger script own the URL-to-number mapping, so the model only ever emits small integer ids it was handed at retrieval time. ## Core Features & Use Cases - Citation Ledger: Register sources at retrieval time with sources.py add or ingest; ids are stable, idempotent, and URL-normalized, then rendered mechanically into a Sources block (markdown, plain, footnotes, bibtex, or evidence styles). - Fact-Checking Mode: Attach verbatim quotes to each source (rejected unless they literally appear in the fetched page text), flag unsourced claims with [unverified], and gate delivery with verify --evidence --min-coverage. - Draft Verification: verify catches unknown citation ids, Sources blocks that disagree with the ledger, thin citation coverage, and over-cited sentences before delivery. - Use Case: While writing a market research brief, register every page fetched via web search, cite claims inline as [1][2], then run render --cited-in brief.md and verify brief.md --min-coverage 0.5 so every factual sentence traces to a real retrieved URL. ## Quick Start Ask the agent to research a topic using web search, register each retrieved source in the citation ledger, and write a cited answer ending with a rendered Sources list.

Frequently Asked Questions about grounded-citations

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add verifiable citations to AI-generated answers?▼

Register each retrieved URL with the ledger script using `sources.py add`, which returns a stable numeric id. Cite those ids inline while drafting, then generate the Sources block with `sources.py render --cited-in` so URLs come from the ledger, never from memory.

How do I fact-check an AI-written report against its sources?▼

Attach verbatim quotes to each source with `sources.py quote <id> --text ... --from page.txt`; quotes are rejected unless they literally appear in the fetched page text. Then run `verify --evidence --min-coverage 0.5` to fail any draft whose cited sources carry no evidence.

Does the citation ledger work with docx, PDF, and slides?▼

Yes. The ledger is format-agnostic: render styles cover markdown, plain text, footnotes, bibtex, and evidence blocks. The references guide maps each output target — Word footnotes, LaTeX endnotes or BibTeX, a Sources slide in decks, and per-page lists in wikis.

What Python dependencies does the citation ledger script need?▼

None beyond the standard library. `sources.py` is stdlib-only Python 3 and works with any retrieval source — web_search, web_extract, browser navigation, curl, or CLI tools — since it only manages the URL-to-id mapping and verification.

Why does citation verification fail on my draft?▼

Verification fails when a draft cites ids not in the ledger, when the Sources block URLs disagree with the ledger, or when coverage falls below the `--min-coverage` threshold. Fix by re-running `render --replace-in` instead of hand-editing the Sources block.

When should I skip inline citations?▼

Skip citations when retrieval is incidental — quick syntax lookups mid-coding, casual conversation, or creative writing. The skill targets answers and documents that rest on fetched information the reader may want to check.