Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions README.ko.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@

<p align="center">
<a href="https://github.com/lidge-jun/codexclaw/actions/workflows/ci.yml"><img src="https://github.com/lidge-jun/codexclaw/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
<img src="https://img.shields.io/badge/tests-2%2C793_passing-brightgreen" alt="2,793 tests passing">
<img src="https://img.shields.io/badge/tests-2%2C821_passing-brightgreen" alt="2,821 tests passing">
<img src="https://img.shields.io/badge/skills-29-blue" alt="29 skills">
<img src="https://img.shields.io/badge/hooks-24-blue" alt="24 hooks">
<img src="https://img.shields.io/badge/hooks-25-blue" alt="25 hooks">
<a href="https://lidge-jun.github.io/codexclaw/"><img src="https://img.shields.io/badge/docs-codexclaw-black" alt="Documentation"></a>
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-green" alt="MIT"></a>
</p>
Expand All @@ -28,7 +28,7 @@ codexclaw는 Codex 런타임을 체계적인 개발 환경으로 바꾼다. 별

## 주요 기능

**Dev Skill Family** — 표준 부모 스킬(`dev`)이 관리하는 12개 작업 영역별 라우터(`dev-architecture`, `dev-backend`, `dev-frontend`, `dev-testing`, `dev-security`, `dev-debugging`, `dev-data`, `dev-devops`, `dev-code-reviewer`, `dev-scaffolding`, `dev-visualizer`, `dev-uiux-design`)로 구성된다. 모든 라우터는 부모 스킬의 규칙 등급, 검증 게이트, 안전 규칙을 물려받는다. 고유 규칙 ID는 155개다.
**Dev Skill Family** — 표준 부모 스킬(`dev`)이 관리하는 12개 작업 영역별 라우터(`dev-architecture`, `dev-backend`, `dev-frontend`, `dev-testing`, `dev-security`, `dev-debugging`, `dev-data`, `dev-devops`, `dev-code-reviewer`, `dev-scaffolding`, `dev-diagram-viewer`, `dev-uiux-design`)로 구성된다. 모든 라우터는 부모 스킬의 규칙 등급, 검증 게이트, 안전 규칙을 물려받는다. 고유 규칙 ID는 155개다.

**PABCD Workflow** — Plan / Audit / Build / Check / Done을 증명 기반 전환 게이트가 있는 파일 기반 FSM으로 구현했다. `cxc orchestrate` 명령으로 단계를 진행하며, 각 전환에는 구조화된 근거가 붙는다. 영속적인 goalplan 원장이 여러 사이클에 걸쳐 작업 단계, 성공 기준, 수집한 증거를 추적한다.

Expand Down Expand Up @@ -212,7 +212,7 @@ _PATH 수준 `cxc` 진입점(`bin/codexclaw.mjs` + `cli/` 워크스페이스)은
| DevOps / infra | `dev-devops` | `dev-security` for credentials |
| Scaffolding | `dev-scaffolding` | `dev-architecture` for boundaries |
| Code review | `dev-code-reviewer` | `dev-security` + `dev-testing` |
| Diagrams | `dev-visualizer` | — |
| Diagrams | `dev-diagram-viewer` | — |

각 라우터는 필요할 때만 불러오는 자체 모듈형 참고 자료를 갖추고 있으며, 부모 스킬의 검증 게이트, 규칙 등급, 안전 규칙을 물려받는다.

Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@

<p align="center">
<a href="https://github.com/lidge-jun/codexclaw/actions/workflows/ci.yml"><img src="https://github.com/lidge-jun/codexclaw/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
<img src="https://img.shields.io/badge/tests-2%2C793_passing-brightgreen" alt="2,793 tests passing">
<img src="https://img.shields.io/badge/tests-2%2C821_passing-brightgreen" alt="2,821 tests passing">
<img src="https://img.shields.io/badge/skills-29-blue" alt="29 skills">
<img src="https://img.shields.io/badge/hooks-24-blue" alt="24 hooks">
<img src="https://img.shields.io/badge/hooks-25-blue" alt="25 hooks">
<a href="https://lidge-jun.github.io/codexclaw/"><img src="https://img.shields.io/badge/docs-codexclaw-black" alt="Documentation"></a>
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-green" alt="MIT"></a>
</p>
Expand All @@ -28,7 +28,7 @@ codexclaw turns the Codex runtime into a disciplined development environment. It

## Features

**Dev Skill Family** — 12 surface-specific routers (`dev-architecture`, `dev-backend`, `dev-frontend`, `dev-testing`, `dev-security`, `dev-debugging`, `dev-data`, `dev-devops`, `dev-code-reviewer`, `dev-scaffolding`, `dev-visualizer`, `dev-uiux-design`) governed by a canonical parent (`dev`). Every router inherits the parent's rule classes, verification gate, and safety rules. 155 unique rule IDs across the family.
**Dev Skill Family** — 12 surface-specific routers (`dev-architecture`, `dev-backend`, `dev-frontend`, `dev-testing`, `dev-security`, `dev-debugging`, `dev-data`, `dev-devops`, `dev-code-reviewer`, `dev-scaffolding`, `dev-diagram-viewer`, `dev-uiux-design`) governed by a canonical parent (`dev`). Every router inherits the parent's rule classes, verification gate, and safety rules. 155 unique rule IDs across the family.

**PABCD Workflow** — Plan / Audit / Build / Check / Done, implemented as a file-backed FSM with attestation-gated transitions. Phases advance through `cxc orchestrate` commands; each transition carries structured evidence. A durable goalplan ledger tracks work phases, success criteria, and captured proof across multiple cycles.

Expand Down Expand Up @@ -222,7 +222,7 @@ Every coding task is classified (C0-C5) before process depth is chosen. The pare
| DevOps / infra | `dev-devops` | `dev-security` for credentials |
| Scaffolding | `dev-scaffolding` | `dev-architecture` for boundaries |
| Code review | `dev-code-reviewer` | `dev-security` + `dev-testing` |
| Diagrams, visual documents, HTML/SVG reports and PDF composition | `dev-visualizer` | Available document-format owner for export |
| Diagrams, visual documents, HTML/SVG reports and PDF composition | `dev-diagram-viewer` | Available document-format owner for export |

Each router carries its own modular references (loaded on demand, never preloaded) and inherits the parent's verification gate, rule classes, and safety rules.

Expand Down
8 changes: 4 additions & 4 deletions README.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@

<p align="center">
<a href="https://github.com/lidge-jun/codexclaw/actions/workflows/ci.yml"><img src="https://github.com/lidge-jun/codexclaw/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
<img src="https://img.shields.io/badge/tests-2%2C793_passing-brightgreen" alt="2,793 tests passing">
<img src="https://img.shields.io/badge/tests-2%2C821_passing-brightgreen" alt="2,821 tests passing">
<img src="https://img.shields.io/badge/skills-29-blue" alt="29 skills">
<img src="https://img.shields.io/badge/hooks-24-blue" alt="24 hooks">
<img src="https://img.shields.io/badge/hooks-25-blue" alt="25 hooks">
<a href="https://lidge-jun.github.io/codexclaw/"><img src="https://img.shields.io/badge/docs-codexclaw-black" alt="Documentation"></a>
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-green" alt="MIT"></a>
</p>
Expand All @@ -28,7 +28,7 @@ codexclaw 将 Codex 运行时转变为规范化的开发环境。它不提供独

## 功能

**Dev Skill Family** — 由规范父级 `dev` 统一管理的 12 个特定领域路由器(`dev-architecture`、`dev-backend`、`dev-frontend`、`dev-testing`、`dev-security`、`dev-debugging`、`dev-data`、`dev-devops`、`dev-code-reviewer`、`dev-scaffolding`、`dev-visualizer`、`dev-uiux-design`)。所有路由器都继承父级的规则分类、验证门和安全规则。共包含 155 个唯一规则 ID。
**Dev Skill Family** — 由规范父级 `dev` 统一管理的 12 个特定领域路由器(`dev-architecture`、`dev-backend`、`dev-frontend`、`dev-testing`、`dev-security`、`dev-debugging`、`dev-data`、`dev-devops`、`dev-code-reviewer`、`dev-scaffolding`、`dev-diagram-viewer`、`dev-uiux-design`)。所有路由器都继承父级的规则分类、验证门和安全规则。共包含 155 个唯一规则 ID。

**PABCD Workflow** — Plan / Audit / Build / Check / Done,基于文件驱动的 FSM 实现,并通过证明材料控制阶段转换。各阶段通过 `cxc orchestrate` 命令推进,每次转换都携带结构化证据。持久化 goalplan 账本可跨多个周期跟踪工作阶段、成功标准和已收集的证据。

Expand Down Expand Up @@ -211,7 +211,7 @@ _PATH 级 `cxc` 入口(`bin/codexclaw.mjs` + `cli/` 工作区)位于仓库
| DevOps / infra | `dev-devops` | `dev-security` for credentials |
| Scaffolding | `dev-scaffolding` | `dev-architecture` for boundaries |
| Code review | `dev-code-reviewer` | `dev-security` + `dev-testing` |
| Diagrams | `dev-visualizer` | — |
| Diagrams | `dev-diagram-viewer` | — |

每个路由器都有独立的模块化参考资料,仅在需要时加载,不会预加载;同时继承父级的验证门、规则分类和安全规则。

Expand Down
4 changes: 3 additions & 1 deletion bin/codexclaw.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,9 @@ function runPabcdState(args) {

/** Delegate to the compiled subagent-config CLI. argv: ["subagents", ...rest]. */
function runSubagents(args) {
const res = spawnSync(process.execPath, [subagentConfigCli, ...args], { stdio: "inherit" });
const dispatch = args[1] === "dispatch";
const entry = dispatch ? subagentConfigCli.replace(/cli\.js$/, "fallback-dispatch-cli.js") : subagentConfigCli;
const res = spawnSync(process.execPath, [entry, ...(dispatch ? args.slice(2) : args)], { stdio: "inherit" });
return typeof res.status === "number" ? res.status : 1;
}

Expand Down
24 changes: 24 additions & 0 deletions devlog/_fin/260909_subagent_first_fallback/000_plan.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Per-role first fallback

All three subagent roles gain an optional first fallback from the existing catalog. Exhaustion returns work to the main agent; independent review remains outstanding. Existing global/project role inheritance and primary selections remain intact.

Loop: satisfy-spec, C3 feature with careful persistent-dispatch boundary validation. Trigger: Jun requested implementation with cxc-loop. Goal: configurable, executable primary -> fallback -> main-direct decision chain. Non-goals: round robin, OCX settings changes, installs, paid probes, push/merge/deploy. Stop: all criteria verified and cycle closed. Evidence: this unit and session goalplan. Outcome: DONE only with passing checks; missing host delivery is reported as a limitation, not automatic execution proof. Escalation: main reclaims failed delegated slices; scope changes amend this plan first. No user token/time cap; bounded local commands only.

One integrated PABCD cycle covers this feature. Main owns dispatch lifecycle and integration; executor owns configuration and GUI with disjoint files after audit. Existing module homes are reused: subagent-config/src, subagent-config/test, gui/src/pages, gui/test. No AGENTS.md or POLICY.md was present in this checkout. Baseline is local origin/dev 6e97e73, adopted in the current managed worktree; no remote mutation.

Verification: `CODEXCLAW_HOME=/tmp/cxc-first-fallback/empty-home node --test --test-concurrency=1 'plugins/codexclaw/components/subagent-config/test/*.test.ts'` reads the exact module tests: baseline 228 passed, exit 0. Unisolated invocation had 11 global-config contamination failures. Build via package script compiles src recursively into dist and checks manifest. GUI interaction will be rendered after implementation; it has not yet been verified.

See 010_implementation.md for field chain and failure activation cases. Architecture/SoT updates: docs-site/src/content/docs/guides/subagents.md and skills/pabcd/references/delegation.md.

## Progress
A: Inspector returned GO-WITH-FIXES (4 blockers). All accepted: parent SessionStart affordance, canonical native-string decoder with unknown-error stop, OCX rewrite limits, and exact model duplicate semantics. B started with persisted A>B near-pass attestation. Main owns dispatch code and executor owns settings/UI. Initial dispatch tests: 4 pass, 5 failures awaiting the independent store fallback implementation; not a final verification result. GUI baseline tsc exited 0. Offline npm ci used the existing lockfile and completed without changing dependencies.

B ownership adjustment: executor implemented the store contract; remaining CLI/MCP/GUI work is reclaimed by main to remove the serial integration wait. Executor was asked to stop outside store and return current edits before main touches its previous write scope. This is a handoff, not evidence of agent failure. Main dispatch tests reached 14/14 and targeted strict tsc passed after the store became available. Code reviewer Auditor returned PASS for the dispatch scope; its nonblocking startup/null-tool-ID/root notes were folded into code/tests.

C review repair: Critic found the new SessionStart hook missing from generated inventory, README badges/prose and one hardcoded hook-count assertion. Accepted: the initial 304-test selection omitted inventory/gate/hook-e2e tests, so its green receipt did not cover the added manifest entry's full publication chain. No conflict with feature logic; regenerate inventory from the manifest, update the independent expected hook count, and broaden verification to these three suites. This is the first repair of this finding. Also clarify report attemptId and conservative stale-lock recovery in delegation docs. Screenshots and API/CLI evidence at 93c02c6 remain valid for unchanged feature code.

Inventory repair verification exposed two more assumptions in the same publication chain: hook-e2e expects the repository's `hook <event>` entrypoint convention, and its inventory negative fixture used the old 23-count badge as its replacement target. Accepted both: use the conventional hook command (and test that exact CLI argv), and make the negative fixture corrupt any numeric hook badge to zero before checking restoration from the inventory. Repair subset now passes 54/54. Runtime fallback selection, UI and provider behavior are unchanged by this repair.

## D — local completion

The integrated cycle closed to IDLE after final code commit `83b06c4`. All recorded criteria are met: per-role fallback settings and scopes, managed dispatch, synthetic failure activation, browser/CLI QA, and packaging consistency. Final independent review: PASS. No implementation work remains in this local scope. Installed plugin/settings, live provider failure behavior, publication and deployment were not changed or claimed. See `011_verification.md` for the evidence layers and limitations.
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Local boundary evidence

- Catalog /home/jun/.codex/opencodex-catalog.json contains xai/grok-4.6 and cursor/grok-4.6. No provider request made.
- OCX src/lib/errors.ts:180 classifies structured error codes; upstream-retry.ts owns provider retries.
- OCX src/codex/subagent-model-fallback.ts:535,617,657 already resolves global/per-primary fallback and rewrites thread_spawn requests before provider routing. CXC will not mutate that configuration. Requested candidate is not proof of actual route; preserve actual model as unknown absent observed metadata.
- CXC components/pabcd-state/src/hook.ts:1889 documents incomplete/truncated PostToolUse error visibility. No verified PostToolUseFailure surface is available.
- CXC spawn-attach-hook.ts:926 returns an updated input envelope; it does not invoke native tools.
- Native host metadata exposes spawn_agent returning agent_id, and wait_agent returning errored:string or completed:string|null. No structured provider error field is promised. Parse only a complete JSON error envelope, never guess a code from arbitrary prose; unknown errors return reconcile/stop rather than blindly rotate.
- Scout independently inspected OCX and CXC source and recommended managed start/report with native main-owned calls. Runtime role observed in child turn_context: gpt-5.6-luna high. Reviewer route observed: anthropic/claude-opus-5 xhigh. Exact actual downstream route remains unverified.
Loading
Loading