MCP Server for QWED Verification — Bring deterministic verification to Claude Desktop, VS Code, and any MCP-compatible AI assistant.
📚 Full Documentation: docs.qwedai.com/mcp
pip install qwed-mcp| OS | Path |
|---|---|
| Windows | %APPDATA%\Claude\claude_desktop_config.json |
| macOS | ~/Library/Application Support/Claude/claude_desktop_config.json |
| Linux | ~/.config/Claude/claude_desktop_config.json |
macOS/Linux:
{
"mcpServers": {
"qwed-verification": {
"command": "qwed-mcp"
}
}
}Windows (use python -m):
{
"mcpServers": {
"qwed-verification": {
"command": "python",
"args": ["-m", "qwed_mcp.server"]
}
}
}Quit completely (system tray → Quit) and reopen.
Ask Claude:
"Verify the derivative of x³ equals 3x² using verify_math"
| Tool | Engine | Use Case |
|---|---|---|
verify_math |
SymPy | Verify calculations, derivatives, integrals |
verify_logic |
Z3 Solver | Prove logical arguments, validate reasoning |
verify_code |
AST Analysis | Detect security vulnerabilities |
verify_sql |
Pattern Matching | SQL injection detection |
A bank says: "Invest $10,000 at 7.5% compounded quarterly for 5 years = $14,356.29"
Use verify_math to check using A = P(1 + r/n)^(nt)
Verify: ₹10,00,000 loan at 9% for 5 years = EMI of ₹20,758
Use the EMI formula: EMI = P × r × (1+r)^n / ((1+r)^n - 1)
Use verify_logic:
Premises: "All mammals are warm-blooded", "Dolphins are mammals"
Conclusion: "Dolphins are warm-blooded"
Use verify_code to check this for security issues:
def run_command(cmd):
os.system(cmd)
return eval(get_response())
Use verify_sql to check:
SELECT * FROM accounts WHERE user_id = '1' OR '1'='1'
┌───────────────────────────────────────────┐
│ Claude Desktop / VS Code │
│ (MCP Client) │
└─────────────────┬─────────────────────────┘
│ MCP Protocol (JSON-RPC)
▼
┌───────────────────────────────────────────┐
│ QWED-MCP Server │
├───────────────────────────────────────────┤
│ verify_math() → SymPy (symbolic math) │
│ verify_logic() → Z3 SMT Solver │
│ verify_code() → Python AST Analysis │
│ verify_sql() → Regex Pattern Match │
└───────────────────────────────────────────┘
| Without QWED-MCP | With QWED-MCP |
|---|---|
| LLM calculates → 95% correct | verify_math() → 100% correct |
| LLM writes SQL → might inject | verify_sql() → injection detected |
| LLM reasons → might be wrong | verify_logic() → formally proven |
| LLM codes → might be unsafe | verify_code() → security checked |
- MCP Server that adds verification tools to Claude Desktop and VS Code
- Deterministic — uses SymPy (math), Z3 (logic), AST (code) for exact verification
- Open source — works with any MCP-compatible AI assistant
- A safety layer — catches LLM hallucinations in real-time
A replacement for Claude— it enhances Claude with verification toolsA chatbot— it's a backend server that Claude callsInternet-connected— all verification happens locallyA fine-tuned model— uses symbolic engines, not ML
Think of QWED-MCP as giving Claude a "calculator" for math and a "theorem prover" for logic.
Claude reasons. QWED-MCP verifies.
| Aspect | Other MCP Servers | QWED-MCP |
|---|---|---|
| Purpose | Connect to APIs, databases, files | Verify LLM outputs |
| Approach | Fetch external data | Compute deterministic proofs |
| Engines | API wrappers | SymPy, Z3, AST analyzers |
| Accuracy | Depends on data source | 100% mathematically proven |
| Offline | Often need internet | Fully local, no APIs |
┌───────────────────┐ ┌─────────────────┐ ┌──────────────────┐
│ Claude │ ──► │ QWED-MCP │ ──► │ Verified Answer │
│ "What's d/dx x³?" │ │ verify_math() │ │ "3x²" ✓ │
└───────────────────┘ └─────────────────┘ └──────────────────┘
All verification happens locally. Nothing is sent to external servers.
| Concern | QWED-MCP Approach |
|---|---|
| Data Transmission | ❌ No external API calls |
| Storage | ❌ Nothing logged or stored |
| Dependencies | ✅ Local engines (SymPy, Z3) |
| Code Analysis | ✅ Your code never leaves your machine |
Perfect for:
- Enterprises with strict security policies
- Air-gapped development environments
- Sensitive code review workflows
Is QWED-MCP free?
Yes! Open source under Apache 2.0. Use it commercially, modify it, distribute it.
Does it work with VS Code Copilot?
QWED-MCP works with any MCP-compatible client. VS Code with Claude extension supports MCP, so yes!
Do I need an API key?
No. QWED-MCP runs entirely locally. No API keys, no cloud calls.
What's the difference between this and QWED-Core?
QWED-Core is the Python library. QWED-MCP wraps it as an MCP server so Claude can use it as a tool.
Can I add my own verification tools?
Yes! The server is extensible. Fork it and add your custom @mcp.tool() functions.
-
verify_math— SymPy symbolic math -
verify_logic— Z3 SMT solver -
verify_code— Python AST security analysis -
verify_sql— SQL injection detection - Claude Desktop integration
- Windows/macOS/Linux support
-
verify_json— JSON Schema validation tool -
verify_finance— NPV/IRR/amortization tool - Cursor IDE integration guide
-
verify_legal— Deadline and liability verification -
verify_statistics— Hypothesis test validation - SSE (Server-Sent Events) transport for web UIs
- TypeScript implementation
See the examples/ folder for:
- Python client usage
- Sample verification scripts
- Integration examples
# Clone
git clone https://github.com/QWED-AI/qwed-mcp.git
cd qwed-mcp
# Install with dev dependencies
pip install -e ".[dev]"
# Run tests
pytest tests/ -v
# Format code
black src/| Resource | Link |
|---|---|
| Full Docs | docs.qwedai.com/mcp |
| Tools Reference | docs.qwedai.com/mcp/tools |
| Examples | docs.qwedai.com/mcp/examples |
| Troubleshooting | docs.qwedai.com/mcp/troubleshooting |
| MCP Protocol | modelcontextprotocol.io |
- QWED Core — github.com/QWED-AI/qwed-verification
- QWED-UCP — github.com/QWED-AI/qwed-ucp
- QWED Open Responses — github.com/QWED-AI/qwed-open-responses
Apache 2.0 — See LICENSE
Built by QWED AI
Making AI outputs trustworthy through formal verification