Claude-peers:讓多個 Claude Code 工作階段直接互相通訊,本機運行的 AI 協作團隊

ChainNewsAbmedia

一個名為 claude-peers-mcp 的開源專案在開發者社群引發廣泛討論。它讓多個 Claude Code 工作階段(session)能夠直接互相傳遞訊息、同步任務狀態,無需任何雲端服務或 API 中介層——整套系統完全在本機運行。

核心概念:AI 同事,不是 AI 工具

傳統的多代理系統需要一個「協調者(orchestrator)」統一調度各個 AI 代理。claude-peers 的做法截然不同——它讓每個 Claude Code 工作階段都成為平等的「同事」,彼此可以直接溝通,無需中央管理層。

實際場景範例:

Claude A(負責 poker-engine): “你在改哪些檔案?” Claude B(負責 frontend): “正在改 auth.ts + UI state” Claude A: “好,我避開 auth 邏輯”

不需要人工協調,AI 自己同步。

技術架構

本機 broker daemon(localhost:7899):作為訊息中繼站

SQLite peer registry:記錄所有活躍的 Claude 工作階段

每個 session 各自的 MCP server:提供工具介面

即時頻道推送訊息:零延遲通訊

自動 peer 探索:新工作階段自動加入網路

四個核心指令

list_peers

:找出所有活躍的 Claude 工作階段

send_message

:向另一個 Claude 發送訊息

set_summary

:描述自己目前的任務

check_messages

:手動查看收到的訊息

每個工作階段還會自動摘要自己的狀態,讓其他 Claude 能看到:當前工作目錄、git repo、目前任務、正在修改的檔案。

典型應用場景

一個 Claude 寫後端,另一個寫前端,自動避開衝突

一個 Claude 負責 debug,另一個同時進行重構

一個 Research Claude 收集資料,餵給 Builder Claude

大型專案拆分給多個 AI 工作者平行推進

限制與挑戰

社群也提出幾個實際問題:同時跑 5 個 Claude Code 工作階段會對本機硬體造成顯著負擔;當多個工作階段同時嘗試 npm install 或 git 操作時,需要額外的衝突解決機制;context 長度限制使得工作階段在長時間運行後可能失去同步。

不過從整體趨勢來看,這個工具代表的是更大的方向轉變:從「一個 AI 助理」進化到「AI 協作團隊」,而且全部運行在你的本機上,不需要雲端、沒有額外費用。

這篇文章 claude-peers:讓多個 Claude Code 工作階段直接互相通訊,本機運行的 AI 協作團隊 最早出現於 鏈新聞 ABMedia。

Disclaimer: The information on this page may come from third parties and does not represent the views or opinions of Gate. The content displayed on this page is for reference only and does not constitute any financial, investment, or legal advice. Gate does not guarantee the accuracy or completeness of the information and shall not be liable for any losses arising from the use of this information. Virtual asset investments carry high risks and are subject to significant price volatility. You may lose all of your invested principal. Please fully understand the relevant risks and make prudent decisions based on your own financial situation and risk tolerance. For details, please refer to Disclaimer.
Commento
0/400
Nessun commento