gemini-agent-bridge
v0.1.2MCP server enabling Gemini (Mac app, CLI, Antigravity) to orchestrate local AI coding agents (pi, opencode) in isolated worktrees and review, revise, verify…
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
list_agents List Available Coding Agents
Inspect installed local AI coding agents (pi, opencode), their resolved binary paths, versions, capabilities, and optionally available models.
| Parameter | Type | Description |
|---|---|---|
includeModels | boolean | Also probe available model lists for detected agents (slower). |
doctor Diagnose Runtime & Sandbox Readiness
Run inside the MCP server's live process/sandbox to verify Node, Git, pi, opencode, state directory permissions, and optional target workspace access.
| Parameter | Type | Description |
|---|---|---|
workspace | string | Optional workspace path to test read/write allowlist and git status. |
dispatch_task Dispatch Task to Coding Agent
Assign a coding or analysis task to a local agent (pi or opencode) inside an isolated workspace (git worktree by default). Returns a deliverable packet if completed within waitSeconds, or a taskId to poll via wait_task.
| Parameter | Type | Description |
|---|---|---|
prompt * | string | Detailed task prompt for the agent. |
workspace * | string | Absolute or ~-prefixed path to the target project. |
acceptanceCriteria | array | Checklist of acceptance criteria to evaluate during review. |
agent | string | Target agent: "pi" or "opencode". |
agentProfile | string | Optional agent profile (e.g. OpenCode "build"|"plan", or pi "readonly"|"no-bash"). |
baseRef | string | Optional git ref/commit/branch to branch worktree from (defaults to HEAD). |
interactionPolicy | string | How to handle agent dialogs: "ask_orchestrator" (default), "auto_approve", or "deny_interactive". |
model | string | Optional model override for the chosen agent. |
thinking | string | Optional thinking level for pi (off, minimal, low, medium, high, xhigh, max). |
timeoutSeconds | integer | Overall execution timeout in seconds (30..3600, default 900). |
title | string | Short human-readable task title. |
verifyCommands | array | Shell commands run deterministically after the agent finishes (e.g. `npm test`). |
waitSeconds | integer | Seconds to wait for immediate completion (0..120, default 10). |
workspaceMode | string | Isolation mode: "worktree" (default for git), "staging" (for non-git <=50MB), "direct" (fast metadata snapshots for large dirs), or "readonly". |
wait_task Wait for Running Task
Long-poll a running task up to waitSeconds (max 120s) while streaming progress notifications. Returns immediately when the task reaches awaiting_review, needs_input, failed, or cancelled.
| Parameter | Type | Description |
|---|---|---|
taskId * | string | Task ID returned by dispatch_task. |
waitSeconds | integer | Max seconds to wait in this call (0..120, default 20). |
steer_task Steer or Follow-up Running Task
Send mid-flight steering or queued follow-up instructions to a running task (mode: "steer" or "follow_up").
| Parameter | Type | Description |
|---|---|---|
message * | string | New instruction or course correction. |
taskId * | string | |
mode | string | "steer" redirects immediately; "follow_up" runs after current turn. |
respond_task_input Respond to Agent Dialog Input
Answer a pending interactive prompt (status=needs_input, e.g. pi extension select/confirm/input dialog) so the task can resume.
| Parameter | Type | Description |
|---|---|---|
taskId * | string | |
cancelled | boolean | Set true to cancel/dismiss the dialog. |
confirmed | boolean | For confirm dialogs: true or false. |
requestId | string | Pending requestId (defaults to the active pendingInput.requestId). |
value | string | For select/input/editor dialogs: chosen or entered string. |
cancel_task Cancel Running Task
Gracefully abort a running task and optionally discard its isolated worktree/staging workspace.
| Parameter | Type | Description |
|---|---|---|
taskId * | string | |
cleanupWorktree | boolean | If true, also remove the isolated worktree/branch immediately. |
list_tasks List Director Tasks
List persisted tasks across sessions with status, agent, round count, and workspace info.
| Parameter | Type | Description |
|---|---|---|
agent | string | |
limit | integer | |
status | string | |
workspace | string |
get_task_deliverable Get Task Deliverable Packet
Retrieve the structured review packet for a task: summary, changed files, verification results, usage/cost, pending inputs, and recommended next actions.
| Parameter | Type | Description |
|---|---|---|
taskId * | string |
get_task_diff Inspect Task Diff
View unified diff patches (including newly created files) or file stats inside the task's isolated workspace, supporting path filters and line pagination.
| Parameter | Type | Description |
|---|---|---|
taskId * | string | |
maxLines | integer | Maximum patch lines to return (default 400). |
mode | string | Defaults to "patch". |
offset | integer | Starting patch line offset (default 0). |
paths | array | Optional subset of relative file paths. |
read_task_file Read File in Task Workspace
Read a line range of any file inside the task's isolated workspace to inspect full context during code review.
| Parameter | Type | Description |
|---|---|---|
path * | string | Relative path inside the isolated workspace. |
taskId * | string | |
endLine | integer | 1-based end line (default 250). |
startLine | integer | 1-based start line (default 1). |
get_task_logs Read Task Event Logs
Inspect normalized execution events (tool calls, errors, retries, status updates) recorded for a task.
| Parameter | Type | Description |
|---|---|---|
taskId * | string | |
eventTypes | array | Filter by event types. |
offset | integer | Pagination offset when tail is omitted. |
tail | integer | Return the last N events. |
verify_task Run Verification Commands in Task Workspace
Execute deterministic shell checks (tests, typecheck, lint) inside the task's isolated workspace and attach results to the deliverable.
| Parameter | Type | Description |
|---|---|---|
commands * | array | Commands to run sequentially. |
taskId * | string |
request_changes Reject Deliverable & Request Revision
Send review feedback and optional file/line comments back into the same isolated workspace & agent session for Round N+1 revision.
| Parameter | Type | Description |
|---|---|---|
feedback * | string | Clear explanation of what needs to be fixed or improved. |
taskId * | string | |
comments | array | |
verifyCommands | array | Optional updated verification commands for this revision round. |
waitSeconds | integer |
approve_task Approve & Land Task Deliverable
Approve a reviewed task (status=awaiting_review) and cleanly land its changes into the main workspace (default: apply_patch with conflict pre-check).
| Parameter | Type | Description |
|---|---|---|
taskId * | string | |
cleanupWorktree | boolean | Whether to remove the isolated worktree/staging directory after landing (default true). |
commitMessage | string | Commit message when using a commit/merge strategy. |
mergeStrategy | string | "apply_patch" (default), "merge_commit", "squash_merge", "fast_forward", or "keep_branch". |
reject_task Reject & Discard Task
Reject a task deliverable and safely delete its isolated worktree/staging directory and temporary branch without touching the main workspace.
| Parameter | Type | Description |
|---|---|---|
taskId * | string | |
reason | string | Optional reason for rejecting the deliverable. |