IAF Agent Bridge

io.github.francescoveryra-dotv1.0.1更新于 Oct 3, 2026

MCP server that sends work to Cursor Agent over ACP and returns the session id needed to continue.

已验证STDIO仅桌面AI & MLDeveloper Tools

概览

AI 生成的概览

让 Codex、Claude Code 等 stdio MCP 主机把编码工作交给本机 Cursor Agent,并继续同一个会话。

功能
该桥接把 MCP 主机的提示词通过 ACP 转发给本机 Cursor Agent,并返回继续同一 Cursor 会话所需的 session id。工具包括 delegate(发送提示词并等待该轮 Cursor 工作结束)、cancel(停止进行中的一轮,会话仍可恢复)和 doctor(检查 Node、桥接、Cursor CLI 与登录状态)。监督方主机读取 Cursor 的回复,再决定继续、完成还是标记受阻。
适用场景
适合让 MCP 主机充当监督者、由 Cursor Agent 在代码仓库中执行实现工作的场景,包括需要在同一个 Cursor 会话中多轮继续的任务。不要把它装进 Cursor 正在编辑的仓库的 Cursor MCP 配置中,这种自循环会被拒绝。
运行要求
需要 Node.js 20 或更高版本(测试套件需要 22)、PATH 中名为 agent 的 Cursor CLI,以及在该机器上完成 agent login。它以 stdio 在本机运行,通常通过 npx -y [email protected] 启动,不需要 OpenAI API key。仅支持桌面端。
安装前请注意
该桥接可以要求 Cursor 编辑你指定的工作区并在其中运行命令,因此可能修改或删除文件并执行代码。默认会拒绝 force-push、改写历史、破坏性 SQL、项目外删除和暂存密钥,但设置 IAF_PERMISSION_MODE=allow-all 会取消这些保护。安装前请阅读安全文档。

安装

在 SourceWeft 中

  1. 打开 控制台中的 IAF Agent Bridge,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

IAF Agent Bridge

MCP server that lets Codex, Claude Code, or another stdio host send work to Cursor Agent and continue the same Cursor session until the requested work is done.

The bridge carries the prompt, the session, and Cursor's reply. The supervisor decides what happens next. Cursor does the implementation.

delegate returns only after that Cursor turn is finished. A message that says the work is complete does not end the call while Cursor is still running tools, sub-agents, or a follow-up. Cursor keeps control of that internal work. The supervisor sees one result, then chooses CONTINUE, COMPLETE, or BLOCKED.

Status: npm [email protected] is the current public package. GitHub Release v1.0.2 matches it. v1.0.1 and v1.0.0 remain published. The Official MCP Registry entry is io.github.francescoveryra-dot/iaf-agent-bridge version 1.0.2.

[CI] [npm] [GitHub Release] [License: MIT] [Node]

Supervisor (Codex, Claude Code, or another MCP host)        |        | MCP over stdio        vIAF Agent Bridge        |        | ACP over stdio        vCursor Agent        |        vYour repository

Cursor Agent is the only production executor. Codex and Claude Code are supervisors. Do not install this server into the Cursor MCP config of a repository that Cursor itself is editing. That loop is refused.

What you can do

  • Start a Cursor session from an MCP host and resume it with sessionId.
  • Let ordinary development continue without approving every tool call.
  • Reject force-push, history rewrite, destructive SQL, deletes outside the project, and secret staging unless you explicitly set IAF_PERMISSION_MODE=allow-all.
  • Use a Master Prompt when the repository has one. A repository without one works normally.

Prerequisites

  • Node.js 20 or newer. Running the test suite needs Node.js 22.
  • The Cursor CLI on your PATH as agent.
  • agent login completed on that machine.

No OpenAI API key is required.

Install

ChannelStatusHow
npmAVAILABLEnpx -y [email protected]
Official MCP RegistryAVAILABLEio.github.francescoveryra-dot/iaf-agent-bridge 1.0.2
Cursor pluginDIRECT INSTALL AVAILABLEagent plugin marketplace add https://github.com/francescoveryra-dot/IAF-Agent-Bridge.git
Cursor MarketplaceSUBMITTED — PENDING REVIEWNot a public install yet. Direct install remains agent plugin marketplace add https://github.com/francescoveryra-dot/IAF-Agent-Bridge.git.
Claude CodeDIRECT INSTALL AVAILABLEclaude plugin marketplace add francescoveryra-dot/IAF-Agent-Bridge then claude plugin install iaf-agent-bridge@iaf-agent-bridge
GitHub Copilot CLIDIRECT INSTALL AVAILABLEcopilot plugin marketplace add francescoveryra-dot/IAF-Agent-Bridge then copilot plugin install iaf-agent-bridge@iaf-agent-bridge
Codex / ChatGPT GitHub pluginDIRECT INSTALL AVAILABLEcodex plugin marketplace add https://github.com/francescoveryra-dot/IAF-Agent-Bridge.git --ref main then codex plugin add iaf-agent-bridge@iaf-agent-bridge
OpenAI plugin directoryNOT APPLICABLE for this local serverThe public directory reviews a hosted HTTPS MCP endpoint. This bridge runs on your machine and talks to your local Cursor CLI.
VS Code MCP galleryNOT LISTEDVS Code browses the GitHub MCP registry. This server is in the Official MCP Registry and is not in that gallery. Add it with npx -y iaf-agent-bridge.

Manual MCP configuration remains the fallback. See docs/installation.md and docs/hosts.md.

Quick start

shell
git clone https://github.com/francescoveryra-dot/IAF-Agent-Bridge.gitcd IAF-Agent-Bridgenpm installnpm run buildnode dist/cli.js doctor

doctor should show the Cursor executable and Authenticated: true. It does not print your account.

Point an MCP host at the published package:

text
command: npxargs:    ["-y", "[email protected]"]

A source checkout can use node and dist/cli.js after npm run build. Then ask the supervisor to implement the work with Cursor and to call delegate again with the returned sessionId while requested work remains.

Install by host

HostHowDetail
CodexPlugin manifest in this repo, or config.tomldocs/hosts.md
Claude Codeclaude mcp add or the plugin in .claude-plugin/docs/hosts.md
CursorPlugin manifest for marketplace submission. Do not use it to delegate from Cursor to Cursor.docs/marketplaces.md
Any stdio MCP clientnode + dist/cli.jsdocs/installation.md

npm install (npx -y iaf-agent-bridge) installs 1.0.2. See docs/installation.md and docs/release.md.

Tools

ToolUse
delegateSend a prompt. Pass sessionId to continue the same Cursor conversation.
cancelStop an in-flight turn. The session can still be resumed.
doctorCheck Node, the bridge, the Cursor CLI, and authentication.

Example follow-up: the first delegate returns "sessionId": "...". The next call uses that id and a prompt that names what is still missing.

How the supervisor should behave

Read result as if you had pasted Cursor's reply into the conversation. Then choose one state:

  • CONTINUE when requested work remains and Cursor can still do it. This is the normal result. Plans, TODOs, mocks, and missing layers are CONTINUE.
  • COMPLETE when the requested work is actually present.
  • BLOCKED only for a real external decision, secret, or irreversible authorization.

The bridge does not demand a new lint run, end-to-end suite, or coverage gate after every turn. Details: docs/supervisor-loop.md.

If the repository contains MASTER_PROMPT.md or the other project files listed in docs/supervisor-loop.md, the first result names them. If it does not, nothing is created.

Configuration and troubleshooting

Environment variables: docs/configuration.md.

If doctor says Cursor was not found, install the CLI and open a new shell. If it says not authenticated, run agent login. More cases: docs/troubleshooting.md.

Security

The bridge can ask Cursor to edit the workspace you name and to run commands there. Read SECURITY.md and docs/security-model.md.

Report vulnerabilities privately: Security advisories. Do not open a public issue that contains a token, a credential, or a working exploit.

Contributing

CONTRIBUTING.md. Issues and pull requests are welcome. Support routes are in SUPPORT.md.

License

MIT. See LICENSE.

来源:README.md,提交 49b258e

工具

0
工具元数据尚未被收录。

版本历史

1
  1. v1.0.1最新Oct 3, 2026