Llmdoc — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited Llmdoc (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
MCP server with RAG (BM25) for llms.txt documentation. Provides semantic search across documentation sources with automatic background refresh.
fast_mcp:https://... for easy filtering~/.claude/claude_code_config.json):{
"mcpServers": {
"llmdoc": {
"command": "uvx",
"args": ["llmdoc"],
"env": {
"LLMDOC_SOURCES": "fast_mcp:https://gofastmcp.com/llms.txt"
}
}
}
}llms.txt is a specification for providing LLM-friendly documentation. Websites add a /llms.txt markdown file to their root directory containing curated, concise content optimized for AI consumption. LLMDoc indexes these files and their linked documents to enable semantic search.
Example sources:
# Run directly with uvx (no install needed)
uvx llmdoc
# Or install with uv
uv tool install llmdoc
# Or install with pip
pip install llmdoc
# Or install with pipx
pipx install llmdocSources can be specified in two formats:
name:url - e.g., fast_mcp:https://gofastmcp.com/llms.txtNamed sources allow you to filter search results by source name.
# Comma-separated list of sources (named or unnamed)
export LLMDOC_SOURCES="fast_mcp:https://gofastmcp.com/llms.txt,pydantic_ai:https://ai.pydantic.dev/llms.txt"
# Optional: Custom database path (default: ~/.llmdoc/index.db)
export LLMDOC_DB_PATH="/path/to/index.db"
# Optional: Refresh interval in hours (default: 6)
export LLMDOC_REFRESH_INTERVAL="6"
# Optional: Max concurrent document fetches (default: 5)
export LLMDOC_MAX_CONCURRENT="5"
# Optional: Skip refresh on startup (default: false)
export LLMDOC_SKIP_STARTUP_REFRESH="true"
# Optional: Disable FTS indexing and use pure BM25 (default: true)
export LLMDOC_ENABLE_FTS="false"Create llmdoc.json in the working directory:
{
"sources": [
"fast_mcp:https://gofastmcp.com/llms.txt",
"pydantic_ai:https://ai.pydantic.dev/llms.txt"
],
"db_path": "~/.llmdoc/index.db",
"refresh_interval_hours": 6,
"max_concurrent_fetches": 5,
"skip_startup_refresh": false,
"enable_fts": true
}Or with explicit name/url objects:
{
"sources": [
{"name": "fast_mcp", "url": "https://gofastmcp.com/llms.txt"},
{"name": "pydantic_ai", "url": "https://ai.pydantic.dev/llms.txt"}
]
}LLMDoc uses stdio transport and is designed to be launched by MCP clients. Configure it in your MCP client (see below), and the client will start the server automatically.
For manual testing:
# Using uvx
uvx llmdoc
# Or as module
python -m llmdocsearch_docs(query, limit, source) - Search documentation and return relevant passages with source URLs. Optional source parameter filters by source name (e.g., fast_mcp)get_doc(url, offset, limit) - Get document content with pagination support for large documents. Parameters: offset (default: 0) start position in bytes, limit (default: 50000, max: 100000) max bytes per call. Returns pagination metadata (has_more, total_length)get_doc_excerpt(url, query, max_chunks, context_chars) - Get relevant excerpts from a large document matching a querylist_sources() - List all configured documentation sources with statisticsrefresh_sources() - Manually trigger a refresh of all documentationdoc://sources - Returns JSON with configured sources list and refresh intervalAdd to ~/.claude/claude_code_config.json:
{
"mcpServers": {
"llmdoc": {
"command": "uvx",
"args": ["llmdoc"],
"env": {
"LLMDOC_SOURCES": "fast_mcp:https://gofastmcp.com/llms.txt,pydantic_ai:https://ai.pydantic.dev/llms.txt"
}
}
}
}Add to your MCP client's configuration file:
{
"mcpServers": {
"llmdoc": {
"command": "uvx",
"args": ["llmdoc"],
"env": {
"LLMDOC_SOURCES": "fast_mcp:https://gofastmcp.com/llms.txt"
}
}
}
}Once configured, the LLM can use these tools:
User: How do I create a tool in FastMCP?
LLM: [calls search_docs("create tool FastMCP")]
Result:
[
{
"title": "Tools",
"snippet": "Creating a tool is as simple as decorating a Python function with @mcp.tool...",
"url": "https://gofastmcp.com/servers/tools.md",
"source": "fast_mcp",
"source_url": "https://gofastmcp.com/llms.txt",
"score": 12.5
}
]You can filter results to a specific documentation source:
User: How do I create an agent in PydanticAI?
LLM: [calls search_docs("create agent", source="pydantic_ai")]
Result:
[
{
"title": "Agents",
"snippet": "Agents are the primary interface for interacting with LLMs in PydanticAI...",
"url": "https://ai.pydantic.dev/agents.md",
"source": "pydantic_ai",
"source_url": "https://ai.pydantic.dev/llms.txt",
"score": 10.2
}
]Use get_doc to retrieve document content (supports pagination for large documents):
LLM: [calls get_doc("https://ai.pydantic.dev/agents.md")]
Result:
{
"title": "Agents",
"content": "# Agents\n\nAgents are the primary interface for interacting with LLMs in PydanticAI...",
"url": "https://ai.pydantic.dev/agents.md",
"source": "pydantic_ai",
"source_url": "https://ai.pydantic.dev/llms.txt",
"offset": 0,
"length": 5432,
"total_length": 5432,
"has_more": false
}+------------------+
| MCP Client |
| (Claude, Cursor) |
+--------+---------+
| stdio
v
+------------------+ +------------------+ +------------------+
| FastMCP Server |---->| Document Store |<----|Document Fetcher |
| | | (DuckDB) | | (async HTTP) |
| - search_docs | | | | |
| - get_doc | | - Persistence | | - llms.txt parse |
| - list_sources | | - Deduplication | | - HTML→Markdown |
| - refresh | | - Change detect | | - Concurrent |
+--------+---------+ +------------------+ +------------------+
|
v
+------------------+
| BM25 Index |
| (in-memory) |
| |
| - Chunking |
| - Tokenization |
| - Scoring |
+------------------+LLMDoc fetches documentation from llms.txt sources, stores it in DuckDB, and provides fast BM25 search through the MCP protocol.
When configured with documentation sources, LLMDoc:
Documents are processed for efficient search:
LLMDoc uses a hybrid two-stage retrieval approach:
Stage 1 - DuckDB FTS (Recall):
Stage 2 - Python BM25 (Precision):
LLMDoc automatically keeps documentation up-to-date:
LLMDoc combines DuckDB's native FTS with Python BM25 for optimal search quality:
Stage 1 - DuckDB FTS:
Stage 2 - Python BM25:
rank_bm25 librarythreading.RLock()Documents are chunked using a multi-level approach:
\n\n).!? followed by whitespaceConfiguration:
chunk_size: 500 characters (default)chunk_overlap: 100 characters (default)DuckDB stores documents and chunks:
CREATE TABLE documents (
id INTEGER PRIMARY KEY,
source_name TEXT NOT NULL, -- e.g., 'fast_mcp'
source_url TEXT NOT NULL, -- llms.txt URL
doc_url TEXT NOT NULL UNIQUE, -- document URL
title TEXT,
content TEXT NOT NULL,
content_hash TEXT NOT NULL, -- SHA256 for change detection
updated_at TIMESTAMP NOT NULL
)
CREATE TABLE chunks (
id INTEGER PRIMARY KEY,
doc_id INTEGER NOT NULL, -- references documents.id
content TEXT NOT NULL, -- chunk text for FTS indexing
start_pos INTEGER NOT NULL, -- position in original document
end_pos INTEGER NOT NULL
)FTS index on chunks table with Porter stemmer for hybrid search.
LLMDoc supports multiple concurrent instances:
Document fetching uses asyncio.Semaphore to limit concurrent HTTP requests (default: 5).
Two stopword lists are used:
MIT License - see LICENSE file.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.