-
新增四份文档: - 27-e2e-task-execution-flow.md — 跨阶段总览:建公司 → 下达任务 → org graph 逐节点执行 → work graph 规划与循环 → 验收收敛。核心发现:这套流程 70-80% 已在 docs/prd/newfunction/_spec/ 里被完整设计(DevLoop 的 L1/L2/L3 三层循环、 BugTriager 四分类归因、分级预算熔断、contract_hash 闸门),DevLoop 实为本 架构唯一跑通的参考实现,通用引擎应从它抽象而来。 - 27-example-dev-company-walkthrough.md — 参考场景走查,把架构在一家具体公司 上跑一遍数(各阶段 JSON 形态、fan-out/fan-in 图、成本估算 ~44 次调用、 按阻塞程度排序的 8 个断点清单),作为实现靶子与端到端验收场景。 - 27-naming-conventions.md — 统一命名规范 {作用域}-{职能}。消歧三种 benchmark (skill- / agent- / task-);OKR 体系正名(goal → okr,第 1 层 Goal → Objective); 规划类统一为 orggraph-planning / workgraph-planning / brd-prd-sdd-planning。 - 27-p3-p4-work-graph-console.md — P3/P4 合并设计:Work Graph 执行引擎(支持 启动/下一步/暂停/停止/重试,手动与自动共用同一 advance 原语)+ 执行控制台页面。 重写 27-p2-org-graph.md 至 v0.4:Org Graph 从「静态汇报结构」重定位为 「company 级别生成的 workflow」,与 Work Graph 同构(condition/edge_kind 执行流边), 两层共用同一套 schema、执行引擎与画布组件。org_graph_edges 从未写入过数据, 可直接 DROP 重建,零迁移负担;hire() 不再需要 reportsTo(图整体规划整体写入), P2 对 company-service.js 的侵入缩至零。 同步修正总纲至 v0.3:Org Graph/Work Graph 术语定义、§3.1 架构图、§3.3 整节; 标注 P1 已实现(226489d);P6「DevLoop 收编」从「可选」改为「应前置」。 修正三处过期陈述:P1 已实现(非设计稿)、runProject 已完整实现(非 501)、 UnitsDAG.vue 已实现 Kahn 分波 DAG 渲染(画布应扩展而非重写)。 并记录一处待处理冲突:graph-service.js:44 已落地的全量唯一索引与 P2 需要的 部分唯一索引冲突,实现 T1 时必须先 DROP。 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> -
- New docs/README.md indexes the tree: done/ (shipped features + reference manuals), todo/ (current focus — Graph Agent architecture), todo/future/ (deprioritized roadmaps: FDE pipeline todo list, stale v1.1 milestones, harness engineering proposal — orthogonal to the Graph Agent work, not blocking it) - Move completed/reference docs into docs/done/ (LEMONBOSS-SYSTEM-DESIGN, architecture-v5, claude-code-cron, open-api-manual, qa_judge_req, task_timeline_design, user-guides/, system-design/01-26 minus the three moved to todo/future/) — verified against actual code (qa-judge template, Task Timeline route/service/view) before filing as done - Fix the two TOC links in LEMONBOSS-SYSTEM-DESIGN.md that would otherwise point at the old paths after the move - docs/todo/system-design/27-graph-agent-architecture.md: add the P2 Org Graph doc link in the roadmap table and 关联文档 section - Add docs/todo/system-design/27-p2-org-graph.md (P2 requirements & design, drafted in parallel while P0/P1 landed) Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
-
hire() now checks system_agents (source_kind='template') before provisioning a new company agent: if the role has a shared template row, skip copying agent.md and instead let AgentManager.getAgentConfig()/PromptBuilder.build() resolve the prompt from the shared legacy_path at call time, with per-company context assembled from a new company-context.md. Roles without a template row (including the 6 ids that exist in both system/agents/ and system/templates/, e.g. evolver-youtube-crawler) fall back to the existing full-copy behavior unchanged. - server/services/graph-service.js (new): lookupSharedAgentMd(), upsertOrgGraphNode() - server/services/company-service.js: hire() reference-mode branch, _provisionReferenceAgent() - server/src/core/agent-manager.js: getAgentConfig() resolves prompt/companyContextPath - server/src/core/prompt-builder.js: build() concatenates company-context.md - unit + integration tests covering all 6 acceptance criteria from docs/todo/system-design/27-p1-virtual-reference.md §6, including a regression test against the real idearun:evolver-youtube-crawler naming-collision case Full regression suite (587 tests) passes; independent adversarial review found 0 blocking/major issues. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
-
Adds server/services/graph-db.js (new data/graph.sqlite: system_agents, org_graph_nodes, org_graph_edges) and graph-seed-service.js, which scans system/agents/, system/templates/, and data/companies/*/company.json into seed rows without touching company-service.js's existing hire/copy path. Real repo data diverged from the design doc's original estimates (8 not 10 global agents; 39 not 34 template dirs; system/agents/ and system/templates/ turn out to share 6 ids describing the "same" agent from two different files) — documented in docs/todo/system-design/27-graph-agent-architecture.md section 7 for P1/P2 to resolve. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>