Claude Synod Debate

Claude Synod Debate enables multi-agent deliberation for improved decision-making.

<div align="center"> <!-- Hero Banner --> <img src="assets/synod-banner.jpeg" alt="SYNOD - Multi-Agent Deliberation System" width="100%"/> <br/> <!-- Tagline -->

When one AI isn't enough, convene the council.

<br/> <!-- Status Badges --> <p> <a href="#-60-second-setup"><img src="https://img.shields.io/badge/⚑_Quick_Start-60s-F97316?style=flat-square" alt="Quick Start"/></a> <a href="https://arxiv.org/abs/2309.13007"><img src="https://img.shields.io/badge/πŸ“š_Research-5_Papers-8B5CF6?style=flat-square" alt="Research"/></a> <a href="LICENSE"><img src="https://img.shields.io/badge/πŸ“œ_License-MIT-22C55E?style=flat-square" alt="License"/></a> <a href="https://github.com/quantsquirrel/claude-synod-debate"><img src="https://img.shields.io/github/stars/quantsquirrel/claude-synod-debate?style=flat-square&logo=github" alt="Stars"/></a> </p> <!-- Language Toggle -->

English Β· ν•œκ΅­μ–΄

</div> <br/> <div align="center">

πŸ˜΅β€πŸ’« Single LLMs are overconfident Β β†’Β  βš”οΈ Make them debate Β β†’Β  βœ… Better decisions

</div> <br/>
<div align="center">

🎭 THE THREE ACTS

Every deliberation follows the same dramatic structure

</div> <br/>
%%{init: {'theme': 'dark', 'themeVariables': { 'primaryColor': '#1e3a5f', 'secondaryColor': '#4a1d1d', 'tertiaryColor': '#1a3d1a'}}}%%
flowchart TB
    subgraph ACT1["🎬 ACT I · SOLVE"]
        G1["πŸ”΅ Gemini β†’ Solution A"]
        O1["🟒 OpenAI β†’ Solution B"]
    end

    subgraph ACT2["βš”οΈ ACT II Β· CRITIQUE"]
        G2["πŸ”΅ Gemini attacks B"]
        O2["🟒 OpenAI attacks A"]
    end

    subgraph ACT3["βš–οΈ ACT III Β· VERDICT"]
        C["🟠 Claude β†’ Final Answer"]
    end

    ACT1 --> ACT2 --> ACT3

    style ACT1 fill:#1e3a5f,stroke:#3b82f6,stroke-width:2px,color:#fff
    style ACT2 fill:#4a1d1d,stroke:#ef4444,stroke-width:2px,color:#fff
    style ACT3 fill:#1a3d1a,stroke:#22c55e,stroke-width:2px,color:#fff
<div align="center">
ActWhat HappensWhy It Matters
IIndependent solutions emergeNo groupthink β€” maximum diversity
IICross-examination beginsWeaknesses exposed β€” biases challenged
IIIAdversarial refinementBest ideas survive scrutiny
</div> <br/>
<div align="center">

⚑ 60-SECOND SETUP

</div>
# 1️⃣ Clone the repo
git clone https://github.com/quantsquirrel/claude-synod-debate.git
cd claude-synod-debate

# 2️⃣ Set your API keys (one-time)
export GEMINI_API_KEY="your-gemini-key"
export OPENAI_API_KEY="your-openai-key"

# 3️⃣ Run setup (installs deps, configures CLI tools, tests models)
/synod-setup

# 4️⃣ Summon the council
/synod review Is this authentication flow secure?
<div align="center">

That's it. The council convenes automatically.

<br/> <img src="https://capsule-render.vercel.app/api?type=rect&color=gradient&customColorList=12,14,25&height=2" width="50%"/> </div> <br/>
<div align="center">

πŸ”§ INITIAL SETUP TEST

Verify your models work before deliberating

</div> <br/>
/synod-setup
<div align="center">
CheckWhat It Does
CLIVerifies all 7 provider CLIs exist
API KeysChecks all provider API keys
Response TimeTests each model with 120s timeout
ClassificationLabels models: βœ“ Recommended / βœ“ Usable / ⚠ Slow / βœ— Failed
</div> <br/> <details> <summary><b>πŸ“‹ Sample Output</b></summary> <br/>
[Synod Setup] 초기 섀정을 μ‹œμž‘ν•©λ‹ˆλ‹€...

Step 0/4: Python μ˜μ‘΄μ„± 확인
  βœ“ google-genai μ„€μΉ˜λ¨
  βœ“ openai μ„€μΉ˜λ¨
  βœ“ httpx μ„€μΉ˜λ¨

Step 1/4: CLI 도ꡬ 확인
  βœ“ gemini-3.py
  βœ“ openai-cli.py

Step 2/4: API ν‚€ 확인
  βœ“ GOOGLE_API_KEY (섀정됨)
  βœ“ OPENAI_API_KEY (섀정됨)

Step 3/4: MCP λΌμš°νŒ… ν˜Έν™˜μ„± 확인
  βœ“ MCP λΌμš°νŒ… 미감지

Step 4/4: λͺ¨λΈ 응닡 μ‹œκ°„ μΈ‘μ • (νƒ€μž„μ•„μ›ƒ: 120초)

Provider    Model              Latency    Status
───────────────────────────────────────────────
gemini      flash              3.2초      βœ“ ꢌμž₯
gemini      pro                12.4초     βœ“ μ‚¬μš© κ°€λŠ₯
openai      gpt4o              2.8초      βœ“ ꢌμž₯
openai      o3                 45.2초     ⚠ 느림

[μ™„λ£Œ] 4/4 λͺ¨λΈ μ‚¬μš© κ°€λŠ₯
Synodλ₯Ό μ‚¬μš©ν•  μ€€λΉ„κ°€ λ˜μ—ˆμŠ΅λ‹ˆλ‹€!
</details> <br/>
<div align="center">

πŸ€– SUPPORTED PROVIDERS

v3.0: Now supporting 7 AI providers

</div> <br/> <div align="center">
ProviderCLIBest ForStatus
πŸ”΅ Geminigemini-3Default debater, thinking modesRequired
🟒 OpenAIopenai-cliDefault debater, o3 reasoningRequired
🟣 DeepSeekdeepseek-cliMath, reasoning (R1)Optional
⚑ Groqgroq-cliUltra-fast inference (LPU)Optional
🌐 OpenRouteropenrouter-cliMulti-model fallbackRecommended
πŸ”Ά Grokgrok-cli2M context windowOpt-in
🟠 Mistralmistral-cliCode, European deploymentOpt-in
</div> <br/> <details> <summary><b>πŸ”‘ Extended Provider Setup</b></summary> <br/>
# Optional: Add more providers to your council
export DEEPSEEK_API_KEY="your-deepseek-key"   # DeepSeek R1
export GROQ_API_KEY="your-groq-key"           # Groq LPU
export OPENROUTER_API_KEY="your-openrouter-key" # OpenRouter (Recommended)

# Opt-in Providers (requires explicit activation)
# Grok (2M context window)
export SYNOD_ENABLE_GROK=1
export XAI_API_KEY="your-xai-key"

# Mistral (code specialization)
export SYNOD_ENABLE_MISTRAL=1
export MISTRAL_API_KEY="your-mistral-key"
</details> <br/>
<div align="center">

🎯 FIVE MODES OF DELIBERATION

Choose your council configuration

</div> <br/> <div align="center">
ModeSummon When...Configuration
πŸ”reviewAnalyzing code, security, PRsGemini Flash βš”οΈ GPT-4o
πŸ—οΈdesignArchitecting systemsGemini Pro βš”οΈ GPT-4o
πŸ›debugHunting elusive bugsGemini Flash βš”οΈ GPT-4o
πŸ’‘ideaBrainstorming solutionsGemini Pro βš”οΈ GPT-4o
🌐generalEverything elseGemini Flash βš”οΈ GPT-4o
</div> <br/> <details> <summary><b>πŸ“ Example Commands</b></summary> <br/>
# Code review
/synod review "Is this recursive function O(n) or O(nΒ²)?"

# System design
/synod design "Design a rate limiter for 10M requests/day"

# Debugging
/synod debug "Why does this only fail on Tuesdays?"

# Brainstorming
/synod idea "How do we reduce checkout abandonment?"
</details> <br/>
<div align="center">

πŸ“œ ACADEMIC FOUNDATION

Not just another wrapper β€” peer-reviewed deliberation protocols

</div> <br/> <div align="center">
ProtocolSourceWhat Synod Implements
ReConcileACL 20243-round convergence (>95% quality gains)
AgentsCourtarXiv 2024Judge/Defense/Prosecutor structure
ConfMADarXiv 2025Confidence-aware soft defer
Free-MADResearchAnti-conformity instructions
SIDResearchSelf-signals driven confidence
</div> <br/> <details> <summary><b>πŸ“Š The Trust Equation</b></summary> <br/>

Synod calculates trust using the CortexDebate formula:

                Credibility Γ— Reliability Γ— Intimacy
Trust Score = ────────────────────────────────────────
                      Self-Orientation
FactorMeasuresRange
CEvidence quality0–1
RLogical consistency0–1
IProblem relevance0–1
SBias level (lower = better)0.1–1

Interpretation:

  • T β‰₯ 1.5 β†’ Primary source (high trust)
  • T β‰₯ 1.0 β†’ Reliable input
  • T β‰₯ 0.5 β†’ Consider with caution
  • T < 0.5 β†’ Excluded from synthesis
</details> <br/>
<div align="center">

πŸ“¦ INSTALLATION

</div> <details> <summary><b>πŸš€ Quick Installation (Recommended)</b></summary> <br/>
# Clone the repo
git clone https://github.com/quantsquirrel/claude-synod-debate.git
cd claude-synod-debate

# Set API keys
export GEMINI_API_KEY="your-gemini-key"
export OPENAI_API_KEY="your-openai-key"

# Run setup inside Claude Code (auto-installs Python deps, creates CLI wrappers, tests models)
/synod-setup

Skills auto-load from plugin.json when you open Claude Code inside this directory. /synod-setup handles the rest: Python dependencies (google-genai, openai, httpx), CLI tool wrappers in ~/.synod/bin/, API key validation, and model connectivity testing.

</details> <details> <summary><b>πŸ”§ Manual Installation (without Claude Code)</b></summary> <br/>
git clone https://github.com/quantsquirrel/claude-synod-debate.git
cd claude-synod-debate
pip install google-genai openai httpx

# Create CLI wrappers and test models
python3 tools/synod-setup.py
</details> <details> <summary><b>βš™οΈ Configuration</b></summary> <br/>
# Required
export GEMINI_API_KEY="your-gemini-key"
export OPENAI_API_KEY="your-openai-key"

# Optional
export SYNOD_SESSION_DIR="~/.synod/sessions"
export SYNOD_RETENTION_DAYS=30
</details> <br/>
<div align="center">

πŸ”’ COMPATIBILITY

</div> <br/> <div align="center">
EnvironmentStatusNotes
bashβœ…Fully supported
zshβœ…Fully supported (v3.0.1+)
MCP Pluginsβœ…Guard directives prevent routing interception
OMC (oh-my-claudecode)βœ…CODEX-ROUTING opt-out built-in
</div> <br/> <details> <summary><b>πŸ›‘οΈ MCP Routing Protection</b></summary> <br/>

Synod executes external models (Gemini, OpenAI) exclusively via CLI tools (gemini-3, openai-cli). If your environment includes MCP routing plugins that redirect model calls through ask_codex or ask_gemini, Synod's built-in defense-in-depth guards prevent interception:

  1. allowed-tools frontmatter β€” Schema-level restriction excludes MCP tools
  2. Markdown directives β€” Explicit prohibition in skill entry point and Phase 0/1
  3. Automated tests β€” CI validates guard presence against configuration drift

No additional configuration needed β€” protection is automatic.

</details> <br/>
<div align="center">

πŸ—ΊοΈ ROADMAP

</div>
  • MCP Server β€” Native Claude Code integration
  • VS Code Extension β€” GUI for debate visualization
  • Knowledge Base β€” Learning from debate history
  • Web Dashboard β€” Real-time debate monitoring
  • More LLMs β€” Llama, Mistral, Claude variants v3.0: 7 providers supported!
<br/>
<div align="center">

🀝 JOIN THE COUNCIL

Issues Β· Discussions Β· Contributing

<br/> <details> <summary><b>πŸ“– Citation</b></summary>
@software{synod2026,
  title   = {Synod: Multi-Agent Deliberation for Claude Code},
  author  = {quantsquirrel},
  year    = {2026},
  url     = {https://github.com/quantsquirrel/claude-synod-debate}
}
</details> <br/>

MIT License Β· Copyright Β© 2026 quantsquirrel

Built on the shoulders of<br/> ReConcile Β· AgentsCourt Β· ConfMAD Β· Free-MAD Β· SID

<br/>

"In the multitude of counselors there is safety." β€” Proverbs 11:14

</div>