Browser AI Debate MCP
Integrates with Gemini Web to allow AI debate by sending questions, receiving answers, and facilitating multi-round discussions through browser automation.
Integrates with ChatGPT Web to allow AI debate by sending questions, receiving answers, and facilitating multi-round discussions through browser automation.
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., "@Browser AI Debate MCPDebate the pros and cons of using TypeScript for a large project"
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.
Browser AI Debate MCP
A Model Context Protocol (MCP) server that runs a structured multi-round debate between ChatGPT Web and Gemini Web by operating both in the same Chrome browser via CDP (Chrome DevTools Protocol). No API keys, no external APIs, no OpenAI/Gemini SDKs — pure browser automation.
What It Does
Opens ChatGPT Web and Gemini Web in the same Chrome browser session
Sends the same question to both models independently (Phase 1)
Makes each model critique the other's answer (Phase 2)
Asks each to revise based on the critique (Phase 3)
Asks ChatGPT (default) to integrate both into a final conclusion (Phase 4)
Asks Gemini to audit the conclusion (Phase 4b)
Returns a structured JSON result with confidence score, rationale, and per-provider status
Related MCP server: gemini-skill
Important
Operates by controlling a browser via CDP, not by calling APIs
Non-official: Uses the same approach as ChatGPT Web. UI changes can break selectors.
Requires a logged-in Chrome session for both ChatGPT and Gemini
No API keys needed — just a logged-in browser
Chrome profile is NOT stored in Git (
.browser-ai-profile/is gitignored)Independent of
chatgpt-web-url-mcp— this is a separate project
Prerequisites
Node.js 20+
Google Chrome (desktop)
Playwright (bundled with package)
Setup
git clone https://github.com/kaenozu/browser-ai-debate-mcp.git
cd browser-ai-debate-mcp
npm install
npm run buildChrome Preparation
Option A: Login to user-owned Chrome (recommended)
Log into ChatGPT and Gemini in your existing Chrome browser normally.
Option B: CDP connection to user-owned Chrome
Open Chrome with remote debugging enabled:
chrome://inspect/#remote-debuggingEnable "Discover network targets"
Set environment variable:
set BROWSER_AI_CDP_URL=http://127.0.0.1:9222
Option C: Auto-launch dedicated Chrome
If no Chrome is running with CDP, the server can auto-launch a dedicated Chrome.
The profile is stored in .browser-ai-profile/ (gitignored).
To pre-launch:
npm run loginThis opens a new Chrome window. Log in, then close Chrome. The profile is saved.
Then for CDP mode:
npm run chrome:debugMCP Client Configuration
{
"mcpServers": {
"browser-ai-debate": {
"command": "node",
"args": ["dist/index.js"],
"env": {
"BROWSER_AI_PROFILE_DIR": "C:/path/to/profile"
}
}
}
}browser_ai_debate Tool
Input
{
"question": "Why is not swallowing exceptions important in TypeScript?",
"context": "We have 70 source files and 23 with try-catch that swallows errors",
"decisionCriteria": ["code reliability", "debuggability", "user experience", "maintainability"],
"maxRounds": 3,
"timeoutMs": 900000
}Field | Required | Default | Description |
| Yes | — | The debate question (max 100,000 chars) |
| No | — | Additional context |
| No | — | Evaluation criteria (array of strings) |
| No | 3 | 1-5, rounds beyond default will not run |
| No | 900000 | Total timeout (min 30,000) |
| No | — | Per-provider timeout |
| No | true | Include full conversation transcript |
| No | "chatgpt" | Which provider makes the final decision |
Output
{
"status": "consensus",
"conclusion": "...",
"confidence": 0.85,
"rationale": ["reason 1", "reason 2"],
"agreements": [],
"disagreements": [],
"remainingRisks": [],
"nextActions": [],
"chatgptConversationUrl": "https://chatgpt.com/c/...",
"geminiConversationUrl": "https://gemini.google.com/app/...",
"providers": {
"chatgpt": { "completed": true, "partial": false },
"gemini": { "completed": true, "partial": false }
},
"rounds": [],
"audit": {},
"durationMs": 0
}Status Values
consensus— Both models agreedecision— Clear recommendation madedisagreement— Models differpartial— One or both providers incomplete/failedfailed— Both providers failed
Timeout and Partial Results
timeoutMscovers the entire debate, including queue wait timeEach provider has an individual timeout (default: total timeout / 4, max 120s per provider)
If one provider fails, the other's result is returned with
status: "partial"A partial result clearly indicates which provider failed and which succeeded
No result is hidden — partial is never treated as complete
Security Notes
Chrome profile is NOT committed to Git —
.browser-ai-profile/is gitignoredNo API keys are stored or used
No credentials are logged (URLs are redacted)
User-owned Chrome is never terminated
Auto-started Chrome (a dedicated profile) is cleaned up on shutdown
Conversation URLs and content are not logged externally
Troubleshooting
DOM selectors changed by UI update
ChatGPT or Gemini updated their web UI, causing selectors to fail.
Solutions:
Clear
.browser-ai-profile/and re-loginUse
npm run chrome:debugwith a fresh CDP connectionFile an issue with the specific page elements that changed
CDP connection fails
Run
npm run chrome:debugto start a dedicated Chrome with CDPOr ensure your user Chrome has remote debugging enabled
Check that port 9222 is available
"AUTH_REQUIRED" error
The browser session has expired. Re-login to ChatGPT and/or Gemini, then retry.
Windows Execution
# Install
npm install
npm run build
# ChatGPT only
npm run inspector -- --prompt "TypeScript で例外を握りつぶさない設計が重要な理由を3点で説明してください"
# Full debate via MCP client
# See MCP configuration aboveOpenCode MCP Registration
{
"mcpServers": {
"browser-ai-debate": {
"command": "cmd",
"args": ["/c", "node", "C:/path/to/browser-ai-debate-mcp/dist/index.js"],
"env": {
"BROWSER_AI_CDP_URL": "http://127.0.0.1:9222"
}
}
}
}Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Tools
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/kaenozu/browser-ai-debate-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server