Provides platform-specific code review rules focusing on Manifest configuration, permissions, ProGuard, lifecycle violations, and context leaks.
Provides platform-specific code review rules focusing on async misuse, setState patterns, dispose() methods, BuildContext in async operations, and Riverpod memory leaks.
Reads uncommitted git diffs to provide code review analysis and severity scoring (P0/P1/P2) across multiple AI agents.
Provides platform-specific code review rules focusing on plist configuration, ATS, keychain, signing, main thread UI violations, and retain cycles.
Uses the OpenAI API through the Codex CLI to provide AI-powered code review and participate in multi-agent debates for code analysis and planning.
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., "@Debate Agent MCPreview the latest commit for security issues"
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.
Debate Agent MCP
EXPERIMENTAL: This project is in active development. APIs and features may change without notice. Use at your own risk in production environments.
A multi-agent debate framework for code review and debate planning with P0/P1/P2 severity scoring.
Architecture Overview
How It Works
No Authentication Required
The MCP itself requires no API keys or authentication. It orchestrates your locally installed CLI tools:
Execution Flow
360 Debate Feature (v2.0)
The 360 Debate feature provides multi-turn cross-review with confidence scoring. It supports two modes:
Mode | Description | Output |
review | P0/P1/P2 code review findings |
|
plan | Implementation planning with consensus |
|
360 Debate Pipeline
Review Mode Example
Plan Mode Example
Mode Comparison
Aspect | Review Mode | Plan Mode |
Purpose | Find bugs, security issues | Plan implementation approach |
Scoring | P0/P1/P2 severity (max 134 pts) | Clarity + Consensus (0-100) |
Output | Findings with fix suggestions | Implementation steps with phases |
Winner | Highest severity score | Highest consensus + clarity |
Final Result | Merged P0/P1/P2 findings | Merged implementation plan |
MD File |
|
|
Benefits of 360 Debate:
Eliminate hallucinated findings (validated by multiple agents)
Catch missed issues (one agent finds what another missed)
Build confidence scores (80% threshold ensures agreement)
Reduce false positives (adversarial review catches incorrect assessments)
Comprehensive report in
.debate/directory
Packages
Package | Description | Install |
Core logic (framework-agnostic) |
| |
MCP server for CLI users |
| |
VS Code extension | Install from marketplace |
Quick Start
Prerequisites
You must have the agent CLIs installed and authenticated:
For CLI Users
For Claude Code
For SDK Users
MCP Tools
Tool | Description |
| List all configured agents |
| Read uncommitted git diff |
| Run a single agent with prompt |
| Multi-agent P0/P1/P2 code review (single round) |
| Create structured debate plan |
| 360 multi-round debate with modes: |
Configuration
Create debate-agent.config.json in your project root:
Severity Levels
Level | Criteria |
P0 | Breaking defects, crashes, data loss, security/privacy problems, build blockers |
P1 | Likely bugs/regressions, incorrect logic, missing error-handling, missing tests |
P2 | Minor correctness issues, small logic gaps, non-blocking test gaps |
Defined in: packages/core/src/prompts/review-template.ts
Platform-Specific Rules
Platform | Focus Areas |
flutter | Async misuse, setState, dispose(), BuildContext in async, Riverpod leaks |
android | Manifest, permissions, ProGuard, lifecycle violations, context leaks |
ios | plist, ATS, keychain, signing, main thread UI, retain cycles |
backend | DTO mismatch, HTTP codes, SQL injection, auth flaws, rate limiting |
general | Null pointers, resource leaks, race conditions, XSS, input validation |
Defined in: packages/core/src/prompts/platform-rules.ts
Scoring System
The scoring is deterministic (no AI) - pure rule-based evaluation:
Criteria | Points | Max |
P0 Finding | +15 | 45 |
P1 Finding | +8 | 32 |
P2 Finding | +3 | 12 |
False Positive | -10 | -30 |
Concrete Fix | +5 | 25 |
File Accuracy | +2 | 10 |
Clarity | 0-10 | 10 |
Maximum possible score: 134 Minimum possible score: -30
Defined in: packages/core/src/engine/judge.ts
Debate Modes
Mode | Description |
adversarial | Agents challenge each other's positions |
consensus | Agents work to find common ground |
collaborative | Agents build on each other's ideas |
Project Structure
Integration
Claude Desktop
Claude CLI
VS Code / Cursor
Install the VS Code extension - it auto-configures MCP.
Development
Known Limitations
Experimental: APIs may change without notice
Local CLIs required: You must have
claudeandcodexCLIs installed and authenticatedTimeout risks: Long diffs may cause agent timeouts (default 180s)
No streaming: Currently waits for full response before processing
Minimum 2 agents: 360 debate requires at least 2 agents for cross-review
Contributing
Contributions welcome! Please open an issue first to discuss proposed changes.
License
MIT