Claude Desktop Integration
Connect arifOS to Claude Desktop via the Model Context Protocol (MCP) for local constitutional AI governance.
Overviewโ
Claude Desktop supports MCP servers through STDIO transport for local execution. This integration allows Claude to access arifOS's 13 Constitutional Floors and Trinity governance engines directly on your machine.
- Claude Desktop installed (macOS or Windows)
- Python 3.12+ with
pip - arifOS package:
pip install arifos
Quick Installโ
Option 1: FastMCP CLI (Recommended)โ
If you have fastmcp installed globally:
fastmcp install claude-desktop arifos
Option 2: Manual Configurationโ
Add arifOS to Claude Desktop's MCP configuration:
macOS:
~/Library/Application\ Support/Claude/claude_desktop_config.json
Windows:
%APPDATA%\Claude\claude_desktop_config.json
Configuration:
{
"mcpServers": {
"arifOS": {
"command": "python",
"args": ["-m", "arifos_aaa_mcp", "stdio"],
"env": {
"ARIFOS_GOVERNANCE_SECRET": "your-secret-key",
"JINA_API_KEY": "your-jina-key",
"PERPLEXITY_API_KEY": "your-perplexity-key",
"BRAVE_API_KEY": "your-brave-key"
}
}
}
}
Claude Desktop runs in an isolated environment. You must explicitly pass all environment variables your server needs:
ARIFOS_GOVERNANCE_SECRETโ Required for governance token signingJINA_API_KEYโ For Jina Reader search (recommended)PERPLEXITY_API_KEYโ For Perplexity search fallbackBRAVE_API_KEYโ For Brave search fallback
Installation with Dependenciesโ
If you need additional Python packages for your use case:
{
"mcpServers": {
"arifOS": {
"command": "uv",
"args": [
"run",
"--with", "arifos",
"--with", "sentence-transformers",
"python", "-m", "arifos_aaa_mcp", "stdio"
],
"env": {
"ARIFOS_GOVERNANCE_SECRET": "your-secret-key",
"ARIFOS_ML_FLOORS": "1"
}
}
}
}
Verify Installationโ
- Restart Claude Desktop completely
- Look for the hammer icon (๐จ) in the bottom-left of the input box
- Click it to see available arifOS tools:
anchor_sessionโ Start constitutional sessionreason_mindโ Execute reasoning with governancesearch_realityโ Web search with F2 Truth verificationeureka_forgeโ Execute commands with risk classification- ... and 9 more tools
Usage Examplesโ
Constitutional Web Searchโ
Ask Claude:
"Search for recent advances in quantum computing and verify the facts with arifOS"
Claude will:
- Call
search_realityvia arifOS - Jina Reader extracts clean Markdown from web results
- F2 Truth floor validates evidence quality
- Results wrapped in F12 Defense envelope
Risk-Classified Command Executionโ
Ask Claude:
"List all files in my home directory"
Claude will:
- Call
eureka_forgewith commandls ~ - Risk classified as LOW (read-only)
- Executes immediately with audit logging
Ask Claude:
"Delete all files in /tmp"
Claude will:
- Call
eureka_forgewith commandrm -rf /tmp/* - Risk classified as CRITICAL (destructive)
- 888_HOLD triggered โ Requires human confirmation
- Must call
confirm_dangerous=Truewith explicit intent
Constitutional Guaranteesโ
When using arifOS through Claude Desktop, every action is governed by:
| Floor | Guarantee |
|---|---|
| F1 Amanah | All actions are reversible and auditable |
| F2 Truth | Web grounding with ฯโฅ0.99 evidence threshold |
| F4 Clarity | Output must reduce information entropy (ฮS โค 0) |
| F7 Humility | Explicit uncertainty markers when ฯ < 0.99 |
| F12 Defense | External content wrapped in untrusted envelope |
| F13 Sovereignty | Human has final veto on all critical actions |
Troubleshootingโ
"Server not found" or hammer icon missingโ
- Check configuration file syntax (valid JSON)
- Ensure
pythonis in your PATH - Try full path to Python executable
- Restart Claude Desktop completely
"NO_API_KEY" in search resultsโ
Add search API keys to environment:
"env": {
"JINA_API_KEY": "jina_...",
"PERPLEXITY_API_KEY": "pplx_...",
"BRAVE_API_KEY": "BSA..."
}
Get free API keys:
- Jina Reader: https://jina.ai (10M free tokens)
- Perplexity: https://perplexity.ai
- Brave: https://brave.com/search/api
Governance token errorsโ
ARIFOS_GOVERNANCE_SECRET is required for:
seal_vaulttool- Critical action confirmation
Generate a secret:
openssl rand -hex 32
Advanced: Remote Server via Proxyโ
If you want to connect to a remote arifOS server:
- Create a proxy server locally:
from fastmcp.server import create_proxy
proxy = create_proxy(
"https://arifosmcp.arif-fazil.com/sse",
name="arifOS Remote"
)
if __name__ == "__main__":
proxy.run() # STDIO for Claude Desktop
- Install the proxy in Claude Desktop
Next Stepsโ
- MCP Server Overview โ Understand the 13 tools
- Governance โ Learn the 13 Constitutional Floors
- API Reference โ Complete tool documentation
Ditempa Bukan Diberi โ Forged, Not Given