# selfclow **Repository Path**: jiawy401/selfclow ## Basic Information - **Project Name**: selfclow - **Description**: 个人龙虾 - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-03-11 - **Last Updated**: 2026-03-11 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # SelfClow — AI Agent 协作平台 > DeepAgents + LangGraph + MCP + RAG + Web IDE 类似 Cursor Agent + OpenClaw + Devin-lite 的开源智能体协作系统。 ## 架构 ``` selfclow/ ├── agents/ │ ├── core/ │ │ ├── base_agent.py # ReAct Agent 基类(LLM + Tool 循环) │ │ └── agents.py # Orchestrator / Coder / Researcher / Reviewer / Executor │ └── graph.py # LangGraph 多智能体编排图 ├── mcp/ │ ├── hub.py # MCP Tool Hub(stdio transport) │ └── builtin_tools.py # 内置工具:文件/Shell/搜索/抓取 ├── rag/ │ └── knowledge_hub.py # 文档摄入 + 向量检索 + 上下文注入 ├── hub/ │ └── agent_hub.py # 会话管理 + Agent 生命周期 ├── api/ │ ├── main.py # FastAPI 入口 │ └── routers/ # sessions / tools / knowledge ├── ide/ # Next.js Web IDE │ └── src/ │ ├── app/ # 页面布局 │ ├── components/ # ChatPanel / TaskPanel / CodeEditor │ ├── hooks/useChat.ts # SSE 流式聊天 │ └── lib/store.ts # Zustand 全局状态 ├── shared/types.py # Pydantic 共享类型 ├── config.py # 配置(pydantic-settings) └── run.py # 一键启动 ``` ## 快速开始 ### 后端 ```bash cp .env.example .env # 填写 LLM_API_KEY pip install -r requirements.txt python run.py # http://localhost:8000 ``` ### 前端 IDE ```bash cd ide npm install npm run dev # http://localhost:3000 ``` ## 核心能力 | 模块 | 说明 | |------|------| | DeepAgents | 5 种专业 Agent,ReAct 循环,自动工具调用 | | LangGraph | 有向图编排,Orchestrator → 并行子任务 → 汇总 | | MCP Tool Hub | 统一工具注册,支持 stdio MCP Server + 本地函数 | | RAG | 文档摄入、余弦相似度检索、上下文自动注入 | | Web IDE | Monaco 编辑器 + SSE 流式聊天 + 任务看板 | ## 扩展 MCP Server 在 `.env` 中添加: ``` MCP_SERVERS=[{"name":"filesystem","command":["npx","-y","@modelcontextprotocol/server-filesystem","."]}] ```