YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
Sovereign MCP
AI Infrastructure You Can Verify.
Every decision. Signed. Recorded. Provable.
Your Request
β
Sovereign Router
β
ββββββββΌβββββββ
β β β
Bedrock Groq Ollama
β β β
ββββββββΌβββββββ
β
ERE Verification
(deterministic gate)
β
Ed25519 Sign
β
WORM Receipt
(append-only)
β
Response
What It Does
Your AI provider can change pricing tomorrow, shut down your model, read every prompt, or refuse your workload. You have no recourse.
Sovereign MCP fixes this:
- Provider independent β Swap from Claude to Llama to Ollama with zero code changes. If one goes down, the next catches it automatically.
- Deterministically verified β Every output passes 5 verification gates before it ships. No stubs. No placeholders. No "TODO: implement."
- Cryptographically signed β Ed25519 signature on every response. Prove what the AI said, when, and to whom.
- Append-only audit trail β WORM-style receipts. Tamper-evident. Permanent. If it happened, you can prove it.
- Self-hosted β Runs on your hardware, your network, your rules. No cloud dependency required.
Quick Start
# stdio mode (Claude Code / VSCode)
node sovereign-mcp.mjs
# HTTP mode (BobIDE / Android / any client)
node sovereign-mcp.mjs --http
Configure providers in .env.local:
AWS_ACCESS_KEY_ID=your-key
AWS_SECRET_ACCESS_KEY=your-secret
AWS_REGION=us-east-1
BEDROCK_MODEL_ID=us.anthropic.claude-haiku-4-5-20251001-v1:0
GROQ_API_KEY=your-groq-key
OLLAMA_URL=http://localhost:11434
Any provider you don't configure is skipped. The router uses what's available.
Tools
| Tool | What it does |
|---|---|
compute_route |
Route queries through the best available provider with automatic failover |
ere_verify |
Deterministic 5-pass verification β catches stubs, placeholders, secrets, broken code |
magma_seal |
WORM-seal any content with verification hash + Ed25519 signature |
agent_dispatch |
Route tasks to specialized agents or registered proxy services |
magma_exec |
Execute composable instruction pipelines with Β§VERB:AGENT:ACTION{payload} syntax |
proxy_register |
Register external services as callable tools |
proxy_list |
List registered proxy integrations |
governor_pubkey |
Export Ed25519 public key for external signature verification |
Verification Gates (ERE)
Every output is checked by 5 deterministic passes before it leaves the system:
| Pass | What it catches |
|---|---|
| P1 | Empty or trivial responses |
| P2 | "Not implemented" stubs, TODO placeholders |
| P3 | Crypto operations in wrong language boundary |
| P4 | Hardcoded secrets, unauthorized AI dependencies |
| P5 | Structural integrity (unbalanced delimiters) |
If any pass fails, the output is BLOCKED. Not logged and forwarded β blocked. The gate is fail-closed.
Instruction Language (Magma)
Composable instructions with pipeline support:
Β§COMPUTE:FORGE:BUILD{query:"build a WORM handler in Rust"}
Pipeline β chain operations:
Β§QUERY:ORACLE:SEARCH{q:"find auth patterns"} >> Β§SEAL:SENTINEL:ANCHOR{data:_prev}
Verbs: COMPUTE (paid model) Β· QUERY (fast/free) Β· SEAL (sign + log) Β· DISPATCH (route to agent) Β· NULLIFY (void an action)
Every instruction is audit-logged with timestamp, executor, and signature.
Agent Routing
Define specialized agents with system prompts. Route tasks to the right expert:
const AGENT_PROMPTS = {
forge: "Production-grade builder. TypeScript, Rust, Haskell. Never stubs.",
oracle: "Knowledge graph. Citations. Never hallucinate sources.",
sentinel: "Zero-trust security. Hard verdicts: APPROVED or BLOCKED.",
vault: "Treasury. Basis points, yield curves, capital efficiency.",
}
Add your own. Remove ours. The architecture doesn't care what agents you define β it cares that their output is verified and signed.
Provider Cascade
1. Bedrock (sovereign, paid, AWS credentials)
β fails?
βΌ
2. Groq (fast, free tier)
β fails?
βΌ
3. Ollama (local, bare metal, zero cost)
β fails?
βΌ
Hard error β no silent degradation
No unverified fallback. No quiet failure. If all providers are down, you know immediately.
Integration
Claude Code / VSCode
Add to your .mcp.json:
{
"mcpServers": {
"sovereign": {
"command": "node",
"args": ["path/to/sovereign-mcp.mjs"]
}
}
}
HTTP Client (any language)
curl -X POST http://localhost:7071 \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"compute_route","arguments":{"agent":"forge","query":"build a REST API"}}}'
Verify Signatures Externally
import { verify } from 'crypto'
const pubkey = await fetch('http://localhost:7071', {
method: 'POST',
body: JSON.stringify({jsonrpc:'2.0',id:1,method:'tools/call',params:{name:'governor_pubkey',arguments:{}}})
}).then(r => r.json())
// Use pubkey to verify any response signature
Architecture
sovereign-mcp/
βββ sovereign-mcp.mjs Server (stdio + HTTP)
βββ .env.example Provider configuration template
βββ LICENSE [Your license here]
βββ README.md
Single file. No build step. No dependencies beyond @aws-sdk/client-bedrock-runtime (optional β only if you use Bedrock).
Who This Is For
- Teams that need to prove what their AI said and when
- Enterprises that can't send data to a third party
- Developers building multi-model systems that don't break when one provider goes down
- Anyone who thinks AI infrastructure should be auditable, not just "hopefully correct"
The Question
If your AI made a decision that cost you $10M, could you prove exactly what it said, when, and why?
If not, you don't have AI infrastructure. You have a hope and a prayer.
AI Infrastructure You Can Verify.
License
Functional Source License 1.1 β Ahmad Ali Parr / Bel Esprit D'Accord Trust
Change Date: 2030-07-24 Β· Change License: Apache 2.0
Use it. Build on it. Don't compete with it for 4 years.
SnapKitty Collective Β· 2026