FactAnchor-MCP
FactAnchor-MCP is a zero-cost, fully local MCP server that grounds AI assistants in real, fetched web text to reduce hallucinations.
Fetch verified web context (
fetch_verified_context): Search the web via free DuckDuckGo and scrape up to 5 real sources for any query, returning clean, LLM-optimized Markdown text.Enforce strict guardrails: Wrap fetched content in a prompt that forces the LLM to answer only from the verified sources — never from pre-trained knowledge.
Require source citation: Compel the AI to cite every claim in brackets (e.g.,
[Source: ...]) or state "I cannot find a verified source for this information." when no answer is found.Run fully locally: All processing happens on your machine via
stdiotransport — no cloud, no paid API keys, zero hosting cost.Auto-install browser: Automatically installs the Playwright Chromium browser on first launch for headless scraping — no manual setup required.
Configurable source count: Fetch 1–5 sources per query (default 3) via the
max_resultsparameter.Broad client compatibility: Works with any MCP-enabled client, including Claude Desktop, Cursor, VS Code, Claude Code, opencode, and Gemini CLI.
Allows fetching real web text via free DuckDuckGo search and page scraping to ground AI answers in verified sources.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@FactAnchor-MCPWhat is the latest update on the James Webb Space Telescope?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
🔗 FactAnchor-MCP
Reduce AI Hallucinations by up to ~80% (informal estimate) using Local Context Anchoring.
FactAnchor-MCP is a zero-cost, fully local Model Context Protocol server that grounds your AI assistant (Claude Desktop, Cursor, VS Code, Claude Code) in real, fetched web text — and forces it to answer only from that text.
💸 ₹0 Hosting Cost — runs entirely on your machine. No cloud, no paid API keys.
🛡️ Strict Guardrails — the LLM must cite sources or say "I cannot find a verified source for this information."
🔎 Free Web Fetching — uses DuckDuckGo's free search + page scraping (no Serper/Google keys).
🧠 Smart Chunking — BM25 semantic relevance scoring keeps only the most useful paragraphs.
💾 Persistent Cache — SQLite disk cache (
~/.factanchor/cache.db) survives server restarts.⚡ Zero-config setup —
pip install -e .+ connect your MCP client. Browser auto-installs on first start.
⭐ If FactAnchor-MCP helps you ship more reliable, hallucination-free AI, please consider starring the repository. It takes one click and helps more developers discover a truly zero-cost way to ground their agents. Thank you! 🙏
🚀 1-Minute Quick Start
Option A — Recommended (cross-platform, no path editing)
git clone https://github.com/Tausifonly001/FactAnchor-MCP.git
cd FactAnchor-MCP
pip install -e . # installs the `factanchor-mcp` commandThen add this to your claude_desktop_config.json (Settings → Developer → Edit Config):
{
"mcpServers": {
"FactAnchor-MCP": {
"command": "factanchor-mcp"
}
}
}Option B — Simple (use the script path directly)
git clone https://github.com/Tausifonly001/FactAnchor-MCP.git
cd FactAnchor-MCP
pip install -r requirements.txtAdd the absolute path to server.py:
{
"mcpServers": {
"FactAnchor-MCP": {
"command": "python",
"args": ["/absolute/path/to/FactAnchor-MCP/server.py"]
}
}
}Windows:
"C:\\Users\\you\\FactAnchor-MCP\\server.py"macOS / Linux:
"/Users/you/FactAnchor-MCP/server.py"or"/home/you/FactAnchor-MCP/server.py"
3. Restart your client
You'll now see the fetch_verified_context tool available. Ask a factual question and watch the assistant ground its answer in live, cited sources.
✅ Zero-config: on first launch, FactAnchor silently installs the Playwright Chromium browser in the background. No
crawl4ai-setupor manual browser commands required.💡 Want
uvinstead of pip?uv pip install -e .works identically, and thefactanchor-mcpcommand lands on your PATH.
Related MCP server: Grounded Code MCP
🧩 Supported Clients (drop-in configs)
FactAnchor-MCP is a standard MCP server, so it works with any MCP-compatible client. Below are ready-to-paste configs. Every client uses the same two shapes:
Option A (recommended):
"command": "factanchor-mcp"— needspip install -e .(so the command is on your PATH).Option B (path-based):
"command": "python"+"args": ["/abs/path/server.py"]— use this if thefactanchor-mcpcommand isn't found.
File: claude_desktop_config.json (Settings → Developer → Edit Config)
{
"mcpServers": {
"FactAnchor-MCP": { "command": "factanchor-mcp" }
}
}Restart Claude Desktop. Tool appears in the tools list.
File: .opencode.jsonc (project root)
{
"mcpServers": {
"FactAnchor-MCP": { "command": "factanchor-mcp" }
}
}Verify with /mcp — fetch_verified_context should be listed.
These are Claude-Code-style clients. Use a project .mcp.json:
{
"mcpServers": {
"FactAnchor-MCP": { "command": "factanchor-mcp" }
}
}Or add it from the CLI (runs the same server):
claude mcp add factanchor -- factanchor-mcp
# Kimi/Qwen/Cline equivalents use the same `mcp add` subcommandFile: ~/.cursor/mcp.json (global) or .cursor/mcp.json (project)
{
"mcpServers": {
"FactAnchor-MCP": { "command": "factanchor-mcp" }
}
}Enable it in Settings → MCP and restart Cursor.
File: .vscode/mcp.json (note: VS Code uses a "servers" key)
{
"servers": {
"FactAnchor-MCP": {
"type": "stdio",
"command": "factanchor-mcp"
}
}
}Open the Command Palette → MCP: List Servers to confirm it's connected.
File: .gemini/settings.json
{
"mcpServers": {
"FactAnchor-MCP": { "command": "factanchor-mcp" }
}
}Or: gemini mcp add factanchor -- factanchor-mcp
If the factanchor-mcp command isn't on your PATH, use the absolute path to server.py on every client above:
{
"mcpServers": {
"FactAnchor-MCP": {
"command": "python",
"args": ["/absolute/path/to/FactAnchor-MCP/server.py"]
}
}
}Per-OS path examples:
Windows:
"C:\\Users\\you\\FactAnchor-MCP\\server.py"macOS:
"/Users/you/FactAnchor-MCP/server.py"Linux:
"/home/you/FactAnchor-MCP/server.py"
🛠️ How It Works
[Claude Desktop / Cursor / VS Code]
│ (Asks a factual query)
▼
[FactAnchor MCP Server]
│
├──► [Free DuckDuckGo Search] (URL Discovery)
│
├──► [Persistent Cache: ~/.factanchor/cache.db] (Fast Repeat Queries)
│
├──► [Crawl4AI in Isolated Subprocess] (Page Scraping)
│
├──► [BM25 Semantic Chunking] (Smart Paragraph Selection)
│
└──► [Strict Guardrail Injection] (Verified Context Block)
│
▼
[Assistant answers ONLY from verified context → ~0% Hallucination]Free Search —
fetch_verified_context(query)runs a free DuckDuckGo search to discover URLs. No API keys required.Persistent Caching — results are cached in
~/.factanchor/cache.db(SQLite) for 24 hours, so repeat queries return instantly even after server restarts.Page Scraping — Crawl4AI runs in an isolated subprocess (
crawl_worker.py) to scrape discovered URLs into clean, LLM-optimized Markdown (navbars, ads, and footers auto-stripped).Semantic Chunking — BM25 relevance scoring extracts only the paragraphs most relevant to your query, maximizing information density within the context window.
Guardrail Injection — the fetched text is wrapped in a strict directive (see
guardrail.py):Answer only from
<verified_context>.If unanswerable, reply exactly: "I cannot find a verified source for this information."
Cite every claim in brackets like
[Source: ...].Never fall back to pre-trained knowledge.
Local-Only — the server uses the
stdiotransport, so all processing stays on your machine.
📦 Project Structure
File | Purpose |
| The MCP server + |
| Headless-scrape worker (Crawl4AI) run in an isolated subprocess for robust MCP stdio. |
| Free DuckDuckGo search (no API keys required). |
| Persistent SQLite cache ( |
| BM25 relevance scoring to extract the most useful paragraphs. |
| The strict fact-anchoring prompt template. |
| Markdown cleaning + truncation for Crawl4AI output. |
| Packaging + |
| Dependencies ( |
| Copy-paste config snippet. |
🧰 Requirements
Python 3.10+
Internet access (for the free search/scrape)
🔧 Tool Reference
fetch_verified_context(query: str, max_results: int = 3) -> strParam | Default | Notes |
| — | The factual topic or question to ground. |
|
| Sources to pull (clamped 1–5). |
🐛 Troubleshooting
command not found: factanchor-mcp→ you used Option A but didn'tpip install -e ., or your venv isn't on PATH. Use Option B (script path) instead.Pages return only short snippets (first run) → Chromium is still installing in the background. Wait ~1–2 minutes and retry; subsequent runs are instant.
"Browser executable doesn't exist" on Linux → install OS deps once:
sudo playwright install-deps chromium(orsudo apt install libnss3 libatk-bridge2.0-0 libdrm2 libxkbcommon0 libgbm1 libasound2).Rate-limit system note from the tool → DuckDuckGo is throttling free search. Wait a few minutes and retry. The server never crashes; it returns a clean system note for the LLM.
Tool not appearing in client → restart the client fully after editing the config, and check its MCP/Developer panel for errors.
📈 Virality Strategy
Before vs After video (X/Twitter & LinkedIn): show the assistant hallucinating a fake npm feature, then enable FactAnchor-MCP and watch it correctly say "I cannot find a verified source for this information." Tag
@AnthropicAIwith#MCPand#AI.Open-source launch: submit to the official MCP servers list and
awesome-mcpcollections.
📊 Evaluation
The "~80%" figure is an informal estimate. A small, hand-runnable eval
set lives in eval/sample_queries.json — see
eval/README.md for how to reproduce it. Contributions of
more queries (or a CI assertion) are very welcome.
🤝 Contributing
See CONTRIBUTING.md. Keep it zero-cost and local-first.
📋 Success Metrics (v1.0)
⚠️ Honesty note: The "~80% reduction" is an informal estimate from manual testing against a small set of factual queries (see
eval/sample_queries.json) — it is not a benchmarked or statistically validated result. The guardrail is a prompt directive, not a hard infrastructure constraint, so an LLM can occasionally drift from it in long conversations. FactAnchor reduces hallucination but does not eliminate it; always verify critical claims against the cited sources.
🧪 Up to ~80% fewer made-up facts observed in informal test queries.
✅ <3 min user setup time (clone → install → config).
✅ ₹0.00 server maintenance bill.
📜 License
MIT © FactAnchor-MCP contributors.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Tools
Related MCP Servers
- AlicenseAqualityAmaintenanceA local-first, no-API-key MCP server that enables LLMs to search the web, fetch pages, and read documents using multiple engines and smart fallbacks.Last updated1031MIT
- Alicense-qualityBmaintenanceA local MCP server that gives AI coding assistants retrieval access to your personal knowledge base of books, standards, and docs, grounding their answers in sources you trust.Last updatedMIT
- Alicense-qualityAmaintenanceA read-only MCP server that gives AI agents the web as compact, ranked, verified evidence — no API keys, no cloud retrieval, all models local.Last updated301MIT
- Alicense-qualityAmaintenanceZero-auth multi-source research MCP server that enables web search, reading URLs, PDFs, GitHub repos, and querying Hacker News, Stack Overflow, Semantic Scholar, and YouTube transcripts without API keys.Last updated10Apache 2.0
Related MCP Connectors
Local-first RAG engine with MCP server for AI agent integration.
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Driflyte MCP server which lets AI assistants query topic-specific knowledge from web and GitHub.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Tausifonly001/FactAnchor-MCP'
If you have feedback or need assistance with the MCP directory API, please join our Discord server