Loading...
Loading...
Compare original and translation side by side
orca-workflowharness/scripts/orca-graph.pyfdk/tools/graph-viz.pyfdk/tools/graph-atlas.pyllmwiki/graph/https://github.com/Rheinmir/orca-graph~/.orca-graph/repo/curl -fsSL https://raw.githubusercontent.com/Rheinmir/orca-graph/main/install.sh | bash~/.orca-graph/bin/orca-graphorca-workflowdepsgraph.jsonharness/scripts/orca-graph.pyfdk/tools/graph-viz.pyfdk/tools/graph-atlas.pyllmwiki/graph/https://github.com/Rheinmir/orca-graph~/.orca-graph/repo/curl -fsSL https://raw.githubusercontent.com/Rheinmir/orca-graph/main/install.sh | bash~/.orca-graph/bin/orca-graphorca-issue/propose/planevals/vt-matrix.jsonout_of_scoperun --strictgraph.jsonorca-issue/propose/planevals/vt-matrix.jsonout_of_scoperun --strictPLAN.md → build → graph.json (cache) + events.jsonl (nguồn chân lý, append-only) → ask (5 câu hỏi) → next/lock/set/run theo lớp topo → verify (+ qc) → audit → graph-viz / graph-atlas / control-roomproposed → ready (mọi deps xong) → locked → dispatched → done | done_unverified | failed | unknownblockedstateverifiedfreshstale--if-revunknownfaileddoneqc**QC:**spec_hashverifyverifyby != "reconcile"emit()runset doneemit()donedone_unverifiedreconcileready**QC:**PLAN.md → build → graph.json(cache)+ events.jsonl(唯一真实来源,append-only)→ ask(5 个问题)→ 按拓扑层执行 next/lock/set/run → verify(+ qc)→ audit → graph-viz / graph-atlas / control-roomproposed → ready(所有 deps 完成)→ locked → dispatched → done | done_unverified | failed | unknownblockedstateverifiedfreshstale--if-revunknownfaileddoneqc**QC:**verifyspec_hashverifyemit()by != "reconcile"runset doneemit()donedone_unverifiedreconcilereadydone_unverified**QC:**| Field | Required? | Ý nghĩa | |
|---|---|---|---|
| In | | có | ≥ 3 task; dòng |
| In | lý do cạnh | nên có | |
| In | claim tài nguyên | khi dùng chung | |
| In | store | không | mặc định |
| In | | không | gắn graph con vào node graph mẹ |
| In | agent + lệnh agent | khi dispatch | tên agent cho |
| Out | | có | graph + state bền |
| Out | output | có | cycle, deps suy luận ( |
| Out | answer có nhãn + nguồn | khi model trả lời | chấm theo rubric 1 / 0 / 0.3 / 0.5 / bịa 0 |
| Out | HTML graph + atlas 2D + | có | 2 file python vẽ + generator control-room |
| Out | | khi kết | kết quả mở lại từng nguồn, bịa = 0 |
| Field | Required? | 含义 | |
|---|---|---|---|
| 输入 | | 是 | ≥ 3 个 task;包含 |
| 输入 | 边的原因 | 建议提供 | |
| 输入 | 资源 claim | 存在共享时 | |
| 输入 | store | 否 | 默认 |
| 输入 | | 否 | 将子 graph 挂载到父 graph 的 node 上 |
| 输入 | agent + agent 命令 | dispatch 时 | agent 名称用于 |
| 输出 | | 是 | graph + 持久化 state |
| 输出 | | 是 | cycle、推断出的 deps( |
| 输出 | 带标签和来源的 answer | model 回答时 | 按 rubric 评分:1/0/0.3/0.5/捏造为 0 |
| 输出 | HTML graph + 2D atlas + | 是 | 2 个 Python 绘图文件 + control-room generator |
| 输出 | | 结束时 | 重新打开每个来源进行核对,捏造数 = 0 |
run --strictblockedanswerkhông-biếtgợi-ý**Depends:**events.jsonlgraph.jsonbuild**Resources:**lock**Depends:**audit-edgesEDGE_UNJUSTIFIEDadd-nodeplan_version + 1graph.jsonrun --strictblockedanswerkhông-biếtgợi-ý**Depends:**events.jsonlgraph.jsonbuild**Resources:**lock**Depends:**audit-edgesEDGE_UNJUSTIFIEDadd-nodeplan_version + 1graph.jsonplan/propose/planorca-issuecheck-cyclesgợi-ýblockedunknownfailedreconcilekhông-biếtplan/propose/planorca-issuecheck-cyclesgợi-ýblockedunknownfailedreconcilekhông-biết| Step | Type | Inputs | Action | Outputs/exit | Failure/next |
|---|---|---|---|---|---|
| W01 | deterministic | repo có harness | Bước 0: pre-work sweep | sweep xong | không harness → bỏ |
| W02 | judgment | PLAN | Bước 1: PLAN có chưa; chưa → skill | PLAN.md | thiếu Depends → tool suy, nhãn gợi-ý |
| W03 | deterministic | PLAN.md | Bước 2: | graph.json + cảnh báo cycle, xung đột file | xung đột → thêm Depends hoặc chấp nhận có lý do |
| W03b | deterministic | graph.json | Bước 2b: | bảng finding (chỉ đọc) | |
| W04 | judgment | graph | Bước 3: 5 câu hỏi bằng | answer có nhãn | không nguồn → không-biết |
| W05 | effect | graph.json | Bước 4: vẽ | HTML + gate | kind lạ → B06 |
| W06 | effect | graph đã duyệt | Bước 5: vòng | node done | lease hết → B05 |
| W07 | deterministic | graph xong | Bước 6: | audit-log + atlas | bịa > 0 → báo |
pull-gate-sweep.shplan/plan**Depends:** Task 1, Task 3**Verify:** <lệnh rc 0>gợi-ýpython3 harness/scripts/orca-graph.py build <PLAN.md>ask <id> needsask <id> parallelask <id> deps <n>ask <id> why <n>ask <id> relatedansweranswer <id> <n> --q why --label chắc|gợi-ý|không-biết --score S --evidence file:path:line edge:a->b event:<op_key> absence:<lệnh> --text "..."gợi-ýkhông-biếtchắcpython3 fdk/tools/graph-viz.py llmwiki/graph/<id>.graph.jsongate-create**Kind:** build|test|fix|research|docs|design|review|security|infra|data|migrate|deploy|release|cleanup|integration|wikibuildengine/kind-glyphs.json~/.orca-graph/repo/engine/kind~/.orca-graph/kind-glyphs.local.json/raise-issuekind-glyphs.jsonnextnext <id> # node ready = chạy song song NGAY; blocked = HITL, KHÔNG dispatch headless
lock <id> <n> --by <agent> # O_EXCL + lease (mặc định 90 phút); heartbeat <id> <n> khi chờ lâu
set <id> <n> dispatched --op-key <uuid> # rồi orca orchestration dispatch --task … --inject (brief NGUYÊN VĂN từ PLAN)
set <id> <n> done --gen <gen> --op-key <uuid> # gen lấy từ output lệnh dispatched; gen cũ → STALE, không publishnextunknownreconcile <id> <n>sync-orca <id> --runaudit <id>audit-log.jsonlgraph-atlas.py llmwiki/graph/| Step | Type | Inputs | Action | Outputs/exit | Failure/next |
|---|---|---|---|---|---|
| W01 | 确定性 | 存在 harness 的 repo | 步骤 0:执行 pre-work sweep | sweep 完成 | 没有 harness → 跳过 |
| W02 | 判断 | PLAN | 步骤 1:检查是否存在 PLAN;不存在 → skill | PLAN.md | 缺少 Depends → tool 推断,标签为 gợi-ý |
| W03 | 确定性 | PLAN.md | 步骤 2: | graph.json + cycle、文件冲突警告 | 冲突 → 添加 Depends 或接受有充分理由的冲突 |
| W03b | 确定性 | graph.json | 步骤 2b: | finding 表格(只读) | |
| W04 | 判断 | graph | 步骤 3:先使用 | 带标签的 answer | 没有来源 → không-biết |
| W05 | 执行 | graph.json | 步骤 4:绘制 | HTML + gate | 未知 kind → B06 |
| W06 | 执行 | 已审批的 graph | 步骤 5:循环 | node done | lease 过期 → B05 |
| W07 | 确定性 | 已完成的 graph | 步骤 6: | audit-log + atlas | 捏造数 > 0 → 报告 |
pull-gate-sweep.shplan/plan**Depends:** Task 1, Task 3**Verify:** <rc 0 命令>gợi-ýpython3 harness/scripts/orca-graph.py build <PLAN.md>ask <id> needsask <id> parallelask <id> deps <n>ask <id> why <n>ask <id> relatedansweranswer <id> <n> --q why --label chắc|gợi-ý|không-biết --score S --evidence file:path:line edge:a->b event:<op_key> absence:<lệnh> --text "..."gợi-ýkhông-biếtchắcpython3 fdk/tools/graph-viz.py llmwiki/graph/<id>.graph.jsongate-create**Kind:** build|test|fix|research|docs|design|review|security|infra|data|migrate|deploy|release|cleanup|integration|wikibuildengine/kind-glyphs.json~/.orca-graph/repo/engine/kind~/.orca-graph/kind-glyphs.local.json/raise-issuekind-glyphs.jsonnextundefinedAgent 超过 lease 仍无响应 → `next` 自动将 node 推进到 `unknown` → `reconcile <id> <n>`(运行 verify),然后才能重新 lock。最多 3 次 attempt。
如需 mirror 到 Orca ledger:`sync-orca <id> --run`(单向;Orca ledger 是 runtime-global,并带有项目标记)。
6. **结束:** `audit <id>`(重新打开每个来源;捏造数 = 0;写入 `audit-log.jsonl`)→ 运行 `graph-atlas.py llmwiki/graph/` 重新生成 atlas → 如果发现流程问题,则更新 problem-tree。| ID | Kind | Guard | Hành vi | Skip / failure | Rejoin |
|---|---|---|---|---|---|
| B01 | user_optional | việc cần tách graph con dưới một node | | vượt depth 6 hoặc 20 node → tool từ chối | W03 |
| B02 | conditional_required | | | kết quả plan_version cũ → STALE | W06 |
| B03 | user_optional | user muốn dừng / tiếp / huỷ | | | W06 |
| B04 | capability_optional | muốn một lệnh thay 4 lệnh gõ tay | | node thiếu verify → từ chối headless | W06 |
| B05 | recovery | agent im lặng quá lease | | tối đa 3 attempt rồi failed | W06 |
| B06 | conditional_required | | tool sinh glyph tạm vào | không tự thêm vào sổ mặc định | W05 |
| B07 | user_optional | muốn mirror sang sổ Orca | | — | W06 |
| B09 | user_optional | user yêu cầu thêm việc / "vẽ thêm node" khi graph đã có | | sinh cycle / > 20 node / dep lạ → tool từ chối, PLAN nguyên vẹn | W05 |
| B10 | recovery | | node khác đang giữ claim xung đột → làm node ready khác trước, | không tự | W06 |
| B08 | conditional_required | node khai | chạy QC độc lập sau verify rc 0; fail → | không khai → hành vi cũ | W06 |
| ID | Kind | Guard | 行为 | Skip / failure | Rejoin |
|---|---|---|---|---|---|
| B01 | user_optional | 需要将工作拆分到某个 node 下的子 graph | | 超过 depth 6 或 20 个 node → tool 拒绝 | W03 |
| B02 | conditional_required | 对已有 graph 重新 | | 旧 plan_version 的结果 → STALE | W06 |
| B03 | user_optional | 用户希望暂停/继续/取消 | | | W06 |
| B04 | capability_optional | 希望用一条命令代替 4 条手动命令 | | node 缺少 verify → headless 拒绝 | W06 |
| B05 | recovery | agent 超过 lease 仍无响应 | | 最多 3 次 attempt,之后标记 failed | W06 |
| B06 | conditional_required | | tool 生成临时 glyph 并写入 | 不得自行添加到默认 ledger | W05 |
| B07 | user_optional | 希望 mirror 到 Orca ledger | | — | W06 |
| B09 | user_optional | graph 已存在时,用户要求添加工作/“再画一个 node” | | 产生 cycle/超过 20 个 node/未知 dep → tool 拒绝,PLAN 保持不变 | W05 |
| B10 | recovery | | 其他 node 正持有冲突 claim → 先执行另一个 ready node,通过 | 不得自行 | W06 |
| B08 | conditional_required | node 声明了 | verify rc=0 后运行独立 QC;失败 → | 未声明 → 保持旧行为 | W06 |
doneverifycheck-cycleslintbuild --strictauditgợi-ýblockednextdonecheck-cycleslintbuild --strictauditgợi-ýblockednextbuildask t2 parallelnextlock --byset done --genauditsrc/api.tsbuild**Depends:** Task 2unknownreconcileanswer … --label không-biếtchắcbuildask t2 parallelnextlock --byset done --genauditsrc/api.tsbuild**Depends:** Task 2unknownreconcileanswer … --label không-biếtchắcbuild <PLAN> --parent <gid>/<node>child_graphdone_unverifiedblockedblocked**Depends:** other-graph/t3check-cycles [dir]a/t2 → b/t3 → a/t2lint <id>build --strictbuild <PLAN> --parent <gid>/<node>child_graphdone_unverifiedblockedblocked**Depends:** other-graph/t3check-cycles [dir]a/t2 → b/t3 → a/t2lint <id>build --strict—Task 1 và Task 2<gid>/<tid>build,;**Depends:** Task 1 (data), other-graph/t3 (control)preferencespec_hashaudit-edges <id> [--json] [--strict]EDGE_UNJUSTIFIEDEDGE_INFERREDPREFERENCE_REMOVABLEPREFERENCE_HAS_HIDDEN_CONSTRAINT--strictEDGE_UNJUSTIFIEDlockexclusivecapacity:Nsharedsharedsharedlocknextunlockunknownbuildℹ … cùng claimask <id> waitingdatagateresourcequeuecontrolretrynonenextask parallelTask 1 和 Task 2<gid>/<tid>build,;**Depends:** Task 1 (data), other-graph/t3 (control)preferencespec_hashaudit-edges <id> [--json] [--strict]EDGE_UNJUSTIFIEDEDGE_INFERREDPREFERENCE_REMOVABLEPREFERENCE_HAS_HIDDEN_CONSTRAINTEDGE_UNJUSTIFIED--strictlockexclusivecapacity:Nsharedsharedsharedexclusivelocknextunlockunknownbuildℹ … cùng claimask <id> waitingdatagateresourcequeuecontrolretrynonenextask parallelreconcile-items --expected A,B,C --verdicts rows.jsonl [--universe N]supported|refuted|inconclusiveitem_id{A,A,B}verdict: nullstatuserrored_idsCONFLICTING_OUTCOME--allow-emptycoverageunknown/tc-rundry-streak --prev N --complete 0|1 --new Ncost-envelope <id> [--reviewers N] [--max-attempts N]max_callsexpectedreconcile-items --expected A,B,C --verdicts rows.jsonl [--universe N]item_id{A,A,B}verdict: nullstatuserrored_idsCONFLICTING_OUTCOME--allow-emptycoverageunknown/tc-rundry-streak --prev N --complete 0|1 --new Ncost-envelope <id> [--reviewers N] [--max-attempts N]max_callsexpectedbuildplan_version + 1superseded[]spec_hashfresh=staleset done --plan-version Nrunplan_versionreadyadd-node--blockslocked|dispatchedbuild--blocks t5--parentbuildplan_version + 1superseded[]spec_hashfresh=staleset done --plan-version Nrunplan_versionreadyadd-node--blockslocked|dispatchedbuild--blocks t5--parentcontrol <id> pause|resume|cancel|statuspause_requestedpausedlocked|dispatchednextlockactivecancelledbuild --max-parallel Nlockcontrol <id> pause|resume|cancel|statuslocked|dispatchedpause_requestedpausednextlockcancelledbuild --max-parallel Nlockrun <id> <node> [--hb 15] [--lease-sec 60] [--strict] -- <lệnh agent>donefailedverify--allow-unverified~/.orca-graph/registry.jsonORCA_GRAPH_NO_DAEMON=1ORCA_GRAPH_HOMErunfilesnotedone--strictgit checkout.graph.json.events.jsonl.locks/watch [--once] [--interval 5] [--idle-sec 600]daemon.lockunknownfdk/tools/build-control-room.pyllmwiki/html/control-room.htmlrundoneverify**Verify:**run <id> <node> [--hb 15] [--lease-sec 60] [--strict] -- <agent 命令>donefailed--allow-unverified~/.orca-graph/registry.jsonORCA_GRAPH_NO_DAEMON=1ORCA_GRAPH_HOMErunfilesdonenote--strictgit checkout.graph.json.events.jsonl.locks/watch [--once] [--interval 5] [--idle-sec 600]daemon.lockunknownfdk/tools/build-control-room.pyllmwiki/html/control-room.htmlrundoneverify**Verify:**/orca-graphaskanswerauditbuildrelated/orca-graphaskanswerauditbuildrelated