面向 GitHub 研发协作的 AI 工作台
将 Issue、Pull Request、CI、代码工作区与项目知识放进一个可追溯的协作流程。
Issue 工作台、PR 详情与 CI 失败详情。截图采自本地生产构建,页面使用项目内置演示数据。
本地演示会预置 course-demo/devflow-sample-api,你可以浏览 Issue、PR 和 CI 页面。演示不需要 GitHub Token 或 LLM Key;它使用 SQLite 和确定性 Embedding,不代表完整向量检索或模型生成效果。
环境: Windows PowerShell、Python 3.10+、Node.js 18.18+、uv 和 npm。
uv venv backend/.venv
uv pip install --python backend/.venv/Scripts/python.exe -r backend/requirements.txt
npm --prefix frontend ci
.\scripts\start_rag.ps1打开 http://127.0.0.1:3000。启动脚本会显示前后端进程号和停止命令;也可以用 -BackendPort、-FrontendPort 指定端口。
演示时可以依次查看:
- Issue:打开
#1 Login API returns 500 when token expires,查看状态、标签和描述。 - PR:打开
#8 Refactor GitHub sync service,查看变更文件和增删行数。 - CI:打开失败的
backend-test,查看 pytest 日志摘要。
| 场景 | ForgePilot 提供的能力 |
|---|---|
| Issue 分诊 | 分类、优先级、复杂度、重复候选、负责人建议和后续行动 |
| PR Review | 汇总 PR diff 与 Review 评论,整理变更、风险、检查项和测试建议 |
| CI 排障 | 结合失败步骤与日志定位原因,并关联 Issue、PR 和项目上下文 |
| 工程协作 | ChatAgent 通过工作区、记忆、RAG、MCP 与 Skills 调用专用工具和分析 Agent |
| 多 Agent 工作流 | Planner、专用 Agent、Observer 与综合阶段生成带证据的工作流结果 |
| 项目知识与代码 | 搜索项目文档和批准的长期记忆;代码与实时 GitHub 状态通过对应数据源查询 |
| 可审核操作 | 将 GitHub 写入操作整理为 ActionDraft,先由用户确认再执行 |
| 评测与回归 | 运行固定评测集,保存检索证据、工具轨迹、指标和诊断信息 |
本地演示适合浏览界面。连接真实 GitHub 仓库、启用模型分析或运行完整 RAG 时,按需提供对应服务和凭据。
-
复制配置模板,并编辑
.env:Copy-Item .env.example .envGITHUB_TOKEN用于访问 GitHub;LLM_API_KEY、LLM_BASE_URL和LLM_MODEL用于模型分析。完整 RAG 还需要配置 Embedding 与 Milvus。 -
创建本地环境并安装依赖:
uv venv backend/.venv uv pip install --python backend/.venv/Scripts/python.exe -r backend/requirements.txt # 使用本地 Qwen Embedding 时才需执行 uv pip install --python backend/.venv/Scripts/python.exe -r backend/requirements-local-embedding.txt npm --prefix frontend ci
若不使用本地 Qwen Embedding,请在
.env中配置受支持的 Embedding 服务。默认模型会在首次调用时下载。 -
启动数据库与向量服务:
docker compose up -d -
在第一个终端启动 API:
Set-Location backend .\.venv\Scripts\python.exe -m uvicorn app.main:app --reload
-
在第二个终端启动前端:
$env:NEXT_PUBLIC_API_BASE_URL = "http://localhost:8000" npm --prefix frontend run dev
前端地址为 http://localhost:3000,API 文档为 http://localhost:8000/docs。后端会从仓库根目录的 .env 读取配置;前端 API 地址通过 NEXT_PUBLIC_API_BASE_URL 设置。
flowchart LR
UI[Next.js 工作台] --> API[FastAPI]
API --> GH[GitHub API]
API --> DB[(PostgreSQL)]
API --> VDB[(Milvus)]
API --> LLM[OpenAI 兼容模型]
API --> CHAT[ChatAgent]
CHAT --> TOOLS[工作区 / MCP / Skills]
CHAT --> RAG[项目知识与记忆]
CHAT --> WF[WorkflowOrchestrator]
WF --> PLAN[Planner]
WF --> SPEC[Issue / PR / CI 专用 Agent]
WF --> OBS[Observer 与证据检查]
CHAT --> DRAFT[ActionDraft 人工确认]
- 截图与动图展示的是 ForgePilot 的真实界面,记录内容来自本地种子数据,不是实时 GitHub 仓库。
scripts/start_rag.ps1关闭 Milvus 并使用确定性 Embedding,适用于界面与结构化演示;完整向量检索需要按.env.example启动 PostgreSQL、etcd、MinIO 和 Milvus。- 模型分析需要配置 LLM;同步 GitHub 数据需要配置 GitHub 访问凭据。





