About citecite-mcp
citecite-mcp is an MCP server for managing numbered citation markers in RAG output. It can add markers, locate them with positions, or remove them during post-processing.
Key features
- 01Insert numbered citation markers
- 02Parse markers with positions
- 03Strip citation markers
- 04Support insertion at an offset
Use cases
- 01Add source markers to generated RAG answers
- 02Extract citation positions for post-processing
- 03Remove markers before presenting text
MCP support
The MCP server exposes tools to insert, parse, and strip [N] citation markers in text.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
Tools
3Saved tool list · updated 2w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| at | enum | No | end | position |
| text | string | Yes | The text to annotate. |
| position | integer | No | Required when at='position'. Insertion offset in chars. |
| citations | array | Yes | Citations to insert. Each has an idx (the visible number) and an optional source_id (opaque key your RAG layer uses). |
Details
From the project README@mukundakatta/citecite-mcp
MCP server for RAG citation markers. Inject [N] markers into LLM output,
parse them back when post-processing, or strip them entirely.
Tools
inject_citations(text, citations, at?)— append[1] [2] [3]markers at the end of text, or insert at a position offset.parse_citations(text)— return every[N]found in source order with position, idx, and marker length.strip_citations(text)— remove every[N]marker.
Install — Claude Desktop
~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"citecite": {
"command": "npx",
"args": ["-y", "@mukundakatta/citecite-mcp"]
}
}
}
Install — Cursor / Cline / Windsurf / Zed
Same shape in each tool's MCP config. Transport is stdio over
npx -y @mukundakatta/citecite-mcp.
Use case
You ran a RAG pipeline. The LLM produced an answer. The retrieval layer told
you which source chunks were used. Now the LLM (a second pass, or the same
agent) needs to inject [1] [2] markers tied to those sources, or to parse
markers back out of an existing piece of text. That's what this is for.
License
MIT OR Apache-2.0.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.