grounded-citations

Generates numbered inline citations and verified Sources blocks from a URL ledger.

Updated Aug 19, 2026
One-click install
npx skills add https://github.com/swcstudiospace/aimeecodes --skill grounded-citations-swcstudiospace
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: grounded-citations
Source: https://github.com/swcstudiospace/aimeecodes/tree/main/.aimee/skills/grounded-citations
Command: npx skills add https://github.com/swcstudiospace/aimeecodes --skill grounded-citations-swcstudiospace

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve? AI-generated answers and documents often contain hallucinated or unverifiable citations because URLs are reconstructed from memory. This Skill eliminates that risk by assigning each retrieved source a stable numeric id in a persistent ledger, so the model only ever emits integers it was handed and the URL mapping is rendered mechanically. ## Core Features & Use Cases - Citation Ledger: Registers URLs at retrieval time with idempotent, normalized ids, and renders Sources blocks in markdown, plain, footnote, BibTeX, or evidence styles. - Fact-Checking Mode: Attaches verbatim quotes to sources (rejected unless they literally appear in the fetched page text), flags model-knowledge claims as [unverified], and enforces an evidence gate during verification. - Draft Verification: Checks drafts for unknown citation ids, mismatched Sources blocks, and minimum citation coverage thresholds before delivery. - Use Case: While writing a research brief, register each fetched page with the ledger, cite claims inline as [1][2], then run verify to confirm every citation resolves and the Sources block matches the ledger before sending the report. ## Quick Start Ask the agent to research a topic using web search, register each 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 sources.py ledger at fetch time, which returns a stable numeric id. Cite claims inline with those ids, then render the Sources block mechanically so URLs are never typed from memory.

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

Attach verbatim quotes to each source using the quote command, which rejects any text not literally present in the fetched page. Then run verify with the evidence flag to fail drafts whose cited sources carry no supporting quote.

Does the citation ledger work with any web retrieval tool?▼

Yes, the ledger accepts URLs from web_search, web_extract, browser navigation, curl, or any CLI. The ingest subcommand can also parse URLs directly from JSON tool output.

What citation formats can the Sources block be rendered in?▼

The render command supports markdown, plain, footnotes, bibtex, and evidence styles. This covers chat answers, LaTeX reports, Word documents, slide decks, and research paper bibliographies.

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 citation coverage falls below the set threshold. Re-run render to regenerate the block instead of hand-editing it.

When should inline citations be skipped?▼

Skip citations when retrieval is incidental, such as quick syntax lookups mid-coding, casual conversation, or creative writing. The skill targets deliverables where readers need to check the provenance of outside facts.