이 문서는 cbr command surface와 human/JSON output semantics를 정의합니다. 설치와 scheduler 설정은 operator-installation.md를 참고하십시오.
실운용에서 중앙 queue가 커지면 full transcript를 읽기 전에 저비용 triage가 가능해야 함.
구현:
cbr list는 실행 대기 task와 검토 대기 task를 기본 표시합니다.cbr list --all은 accepted/archived까지 포함한 전체 목록을 표시합니다.cbr summary TASK_ID는last_result.summary, changed files, verification, last_error를 transcript보다 짧게 보여줍니다.- failed/blocked task와 completed rejected/needs_followup task에는
resolution을 기록해wont_fix,superseded,manual,smoke,duplicate같은 운영 결정을 남길 수 있습니다.
계획:
cbr list --verbose는 summary의 핵심 정보를 목록 화면에 압축해서 보여줄 수 있습니다.- 오래된
accepted/archivedtask와 로그는 추후cbr prune으로 정리할 수 있게 합니다. - 초기
cbr prune은 dry-run report를 기본값으로 두고, 명시적인--apply가 있을 때만 삭제합니다.
cbr completion zsh|bash는 optional completion extra가 제공하는 shell 등록
script를 stdout으로 출력합니다. 이 command는 config를 load하지 않고 shell rc,
completion directory, queue, runtime state를 수정하지 않습니다. 등록 뒤 정적
command/subcommand/option/choice completion은 config 없이 동작합니다. 동적
task_id completion은 normal config discovery로 queue를 read-only 조회하며,
실패하면 shell 입력에 오류를 출력하지 않고 task 후보만 빈 목록으로 반환합니다.
Zsh는 task ID · 상태 · 짧은 제목 설명을 표시할 수 있고 Bash는 task ID를
completion value로 사용합니다. Worktree task 후보는 command와 공유하는
mutation-free state gate를 사용하며, command 실행 시 live Git/worktree state를
다시 검증합니다. enqueue --command 뒤의 argparse.REMAINDER 구간에서는 CBR
option completion을 중단합니다.
cbr orchestration plan --manifest PATH [--json]은 fixed orchestration-intake-v1 JSON manifest만 검증해 orchestration-plan-v1을 만드는 deterministic read-only planner입니다. Summary text는 opaque display context이며 surface selection은 validated enum fields와 issuer-supplied preference order만 사용합니다. 이 command는 CBR config를 load하지 않고 queue/event/state/config file을 읽거나 쓰지 않으며 adapter 호출, thread 생성, dispatch를 하지 않습니다. Invalid manifest는 fixed orchestration-plan-error-v1 JSON을 stdout에 출력하고 exit 2를 반환하며 valid ready, needs_user_decision, blocked plan은 exit 0입니다. 이 manifest-only command에는 global --config를 사용할 수 없습니다.
cbr orchestration selection-preview --manifest PATH --source-contract-digest DIGEST [--policy-revision REVISION] [--selected-surface SURFACE] [--override PATH] --evaluated-at TIMESTAMP [--json]은 exact manifest digest와 D1 plan에 bind된 deterministic orchestration-selection-preview-v1을 만듭니다. Config와 runtime state를 읽지 않으며 candidate/eligibility/recommendation을 새로 분류하지 않습니다. would_warn은 advisory evidence일 뿐 warning을 emit하지 않습니다. cbr [--config CONFIG] orchestration selection-record --manifest PATH --preview PATH (--dry-run | --apply) [--confirm-decision-id DIGEST] [--json]은 supplied manifest의 canonical D1 output과 preview를 다시 대조한 뒤 dry-run에서 상태만 읽고, explicit apply와 exact confirmation일 때만 owner-only private immutable receipt와 sanitized orchestration_selection_recorded event를 기록합니다. 이 경로는 queue task, dispatch, enqueue, provider 호출, routing/default policy를 변경하지 않습니다.
cbr [--config CONFIG] orchestration selection-funnel --manifest PATH --execution-envelope PRIVATE_PATH --selection-receipt PRIVATE_PATH [--json]은 source-bound immutable selection receipt를 canonical manifest/D1과 다시 검증하고 durable_eligible -> planned -> selected projection을 만듭니다. Exact selected cbr_batch만 recomputed dispatch identity의 immutable receipt와 canonical task를 join해 admitted -> completed -> accepted -> applied -> parent_attention_recorded를 판정합니다. Non-CBR downstream은 trusted adapter가 없으므로 unknown이고, non-worktree acceptance는 literal apply evidence가 아니므로 applied=not_applicable입니다. Parent-attention record는 collection/root completion이 아닙니다. Command는 lock, directory, queue/task/receipt/event/outbox/state를 생성·수정하지 않고 dispatch/enqueue/subprocess worker/provider 호출이나 routing policy mutation을 수행하지 않습니다.
cbr orchestration goal-reconcile --goal-manifest PATH [--evidence PATH] [--json]은 strict public-safe source-goal-manifest-v1의 exact (goal_id, revision, manifest_digest) binding에 대한 deterministic goal-reconciliation-report-v1만 만듭니다. Optional evidence는 validated CBR selection-funnel projection만 허용하며 각 row의 executable contract digest가 manifest node와 funnel source contract digest에 정확히 일치해야 합니다. Non-CBR evidence는 unknown으로 남깁니다. contract binding, selection, admission, execution, review, apply, attention recorded/delivered/acknowledged, parent collection, source disposition을 분리합니다. terminal_candidate는 advisory이고 Package 1에서는 false이며, mutation과 모든 authority claim은 false입니다. 이 command는 config/runtime/source를 읽거나 쓰지 않고 dispatch, delivery, ack, apply, collection, source disposition, completion을 수행하지 않습니다.
cbr orchestration goal-explain --goal-manifest PATH --reconciliation-report PATH [--json]은 validated source-goal-manifest-v1과 bound goal-reconciliation-report-v1을 검증해 deterministic read-only goal-explain-view-v1을 만듭니다. Exact (goal_id, revision, manifest_digest, report_digest) binding과 node 구성/순서를 재검증하고, 11개 lifecycle 축과 노드 순서를 보존하며, next decision을 resolve_input_conflict -> collect_parent_attention -> record_source_disposition -> consider_dependency_advance -> review_terminal_candidate -> await_trusted_evidence -> none 순으로 결정합니다. Generic unknown은 explicit allowlisted conflict와 구분됩니다. Wall clock, file mtime, private path, runtime-current 의존성을 배제하여 동일 입력에 대해 byte-equivalent canonical JSON과 같은 view_digest를 반환합니다. Malformed/private/unbound 입력은 exit 2와 sanitized goal-explain-error-v1으로 fail closed됩니다. 이 command는 config/runtime/queue/source를 읽거나 쓰지 않고 mutation 및 routing/selection/completion 권한 주장을 거부합니다.
cbr [--config CONFIG] orchestration dispatch-cbr --manifest MANIFEST --execution-envelope PRIVATE_PATH (--dry-run | --apply) [--confirm-request-id REQUEST_ID] [--json]은 recomputed D1 plan이 exact cbr_batch를 선택한 경우에만 Codex queue task를 명시적으로 dispatch합니다. --dry-run은 read-only preview이고 confirmation을 거부합니다. --apply는 request id exact confirmation과 authority/config/pause/identity gate를 통과해야 하며 deterministic task id와 immutable receipt로 retry/crash recovery 중 duplicate admission을 막습니다. Capacity pressure와 not-ready dependency는 advisory이고 pause, missing/self dependency, unknown pool, isolation mismatch, identity conflict는 blocking입니다. Receipt는 queue admission만 증명하며 execution, review, completion, parent-attention delivery/ack를 증명하지 않습니다. Private prompt, cwd, parent ref, envelope path, command, credential은 preview/receipt/error output에 포함되지 않습니다.
cbr [--config CONFIG] orchestration reconcile-shadow --policy PRIVATE_PATH --trigger PRIVATE_PATH --manifest MANIFEST --execution-envelope PRIVATE_PATH [--json]은 D3-0 guarded orchestration bundle을 read-only로 검증합니다. Exact versioned policy/trigger schema, explicit opt-in, source/policy/request/execution/idempotency binding, fixed five-success evidence floor, zero conflict/violation, project/repository/work/authority/mutation/isolation/verification/capacity allowlist, D1 exact cbr_batch, D2 preview를 순서대로 확인합니다. Report는 queue admission, execution, review, apply, attention delivery, acknowledgement, source disposition을 별도 상태로 표시합니다. activation_mode=guarded, corrupted attention state, identity drift, insufficient evidence, forbidden scope는 fail-closed blocker입니다. 이 command는 queue lock, directory/task/receipt/event/outbox/state 생성, trigger/subprocess/adapter 호출, receipt/outbox repair, coordination mutation을 수행하지 않으며 mutation.allowed=false, mutation.applied=false를 유지합니다.
cbr [--config CONFIG] orchestration publish-local-ingress --bundle PRIVATE_PATH (--dry-run | --apply) [--confirm-source-event-id EVENT_ID] [--json]은 exact orchestration-local-ingress-v1을 CBR-owned private ingress에 publish합니다. Producer는 cbr-local-operator-ingress/cbr-local-ingress-v1으로 고정되고 source는 operator, work는 dependency 없는 objective verification, mutation은 read_only, policy scope는 request와 일치하는 singleton allowlist로 제한됩니다. Event window는 future skew 5분, lifetime 24시간 이내이며 만료된 record는 거부됩니다. Apply는 exact event confirmation, private directory/file identity, atomic exclusive create를 요구합니다. Matching retry는 같은 record를 반환하고 divergent duplicate는 conflict입니다. 이 command는 queue task/receipt/event/outbox를 만들거나 dispatch, trigger, subprocess, adapter를 호출하지 않습니다.
cbr [--config CONFIG] orchestration reconcile-local-shadow --source-event-id EVENT_ID (--dry-run | --apply) [--confirm-source-event-id EVENT_ID] [--json]은 published local ingress를 exact derived trigger로 D3-0 shadow reconciliation합니다. Dry-run은 read-only입니다. Apply는 exact confirmation 뒤 sanitized orchestration-reconciliation-state-v1만 atomic update하며 observation count와 admission/execution/review/apply/attention/source-disposition 축을 보존합니다. Guarded dispatch, repair, delivery, acknowledgement, disposition write, coordination mutation은 수행하지 않습니다. Blocked shadow도 관찰 state로 기록할 수 있지만 admission eligibility나 policy authority로 승격되지 않습니다.
cbr [--config CONFIG] orchestration consume-local-ingress --source-event-id EVENT_ID (--dry-run | --apply) [--confirm-source-event-id EVENT_ID] [--json]은 exact guarded D3-1 event 하나만 기존 D2 admission으로 전달합니다. Apply는 exact confirmation, matching shadow observation, private 120초 lease, 최대 3회 attempt를 요구합니다. lock_busy와 runner_paused만 30초/120초 backoff로 retry하며, crash 후에는 deterministic D2 task/receipt로 복구합니다. Terminal 결과는 immutable local orchestration-source-disposition-v1으로 기록됩니다. 이 command는 ingress scan, launchd/config 변경, same-call execution, external delivery, coordination mutation을 수행하지 않으며 disposition/receipt를 completion 증거로 해석하지 않습니다.
초기 CLI:
cbr enqueue --cwd /repo --prompt-file prompt.md
cbr enqueue --cwd /repo --prompt "작업 지시문"
cbr enqueue --cwd /repo --project project-id --category implementation --label queue --created-by operator --prompt-file prompt.md
cbr enqueue --cwd /repo --reasoning-depth low --cost-sensitivity high --prompt-file prompt.md
cbr enqueue --cwd /repo --routing-size small --routing-risk low --verification-scope unit --verification-scope docs --prompt-file prompt.md
cbr enqueue --cwd /repo --backend shell --command-json '["python3", "-m", "pytest", "tests/test_smoke.py"]'
cbr enqueue --cwd /repo --backend external-json-command --prompt-file task.md --command-json '["./tools/cbr-json-wrapper"]'
cbr enqueue --cwd /repo --prompt-file prompt.md --evidence-source-json source.json
cbr list
cbr list --project project-id
cbr list --project-root /repo
cbr list --cwd /repo
cbr list --category implementation
cbr list --label queue
cbr list --verbose
cbr list --graph
cbr list --demo
cbr list --demo --graph
cbr run-next
cbr run-loop --json
cbr show TASK_ID
cbr summary TASK_ID
cbr execution-plan TASK_ID
cbr routing-report --project project-id --json
cbr execution-report --project project-id --json
cbr routing-policy-candidates --project project-id --json
cbr decision-cards --project project-id --json
cbr logs TASK_ID
cbr transcript TASK_ID
cbr archive TASK_ID
cbr accept TASK_ID --reason "verified"
cbr reject TASK_ID --reason "missing tests"
cbr resolve TASK_ID --resolution manual --reason "handled outside cbr"
cbr list --all
cbr list --unreviewed
cbr list --needs-review
cbr rate-limits
cbr parent-attention list --json
cbr parent-attention deliver EVENT_ID --json
cbr parent-attention ack EVENT_ID --json
cbr cooldown show
cbr cooldown set 7:6
cbr cooldown set "6/22 7:06"
cbr cooldown set +2h30m
cbr cooldown clear
cbr pause show
cbr pause set --reason "operator maintenance window"
cbr pause clear
cbr events
cbr events --task-id TASK_ID --limit 20
cbr events --json
cbr dashboard
cbr dashboard --host 127.0.0.1 --port 8765
cbr doctor
cbr doctor --json
cbr maintenance direct-worktrees --dry-run
cbr maintenance direct-worktrees --repo-root path/to/repo --dry-run --json
cbr maintenance direct-worktrees --apply
cbr maintenance direct-worktrees --json
cbr prune
cbr prune --older-than-days 60 --json
cbr prune --apply
cbr prune --notifier-cursor-state path/to/notify-state.json
cbr retention-inventory
cbr retention-inventory --proposal-age-days 60 --json
cbr retention compact --inventory-report PATH --task-id TASK_ID --json
cbr retention compact --inventory-report PATH --task-id TASK_ID --apply --confirm-operation-id ID --json공통 option:
--config path/to/config.jsoncbr enqueue --backend external-json-command requires --command-json or final-position --command. The command must be an argv list; cbr does not evaluate shell strings. The runner appends the wrapped cbr prompt as the command's final argv argument and expects stdout to contain one final JSON object with task_id, status, summary, changed_files, and verification.
cbr enqueue --evidence-source-json PATH admits a Codex task with the exact
machine-readable {kind,id,revision} source required by the automatic Chamber
evidence contract. The source is stored immutable and is
never derived from prompt text, current directory, terminal state, or a latest-task
heuristic. A source-bearing task fails closed before native launch unless the
configured execution_evidence_adapter is present. Tasks without this option keep
the ordinary execution-only path.
cbr execution-plan TASK_ID는 canonical task와 current config에서
gateway-neutral-execution-plan-v1을 계산해 canonical JSON만 stdout에 출력하는
read-only projection입니다. Exact execution target과 delegation task revision에
bind된 target/config/command digest, backend, timeout, output contract, sanitized
environment/config-mutation/process policy와 availability reason code만 포함합니다.
Legacy task나 missing/unknown policy metadata는 execution behavior를 추측하지 않고
availability.status=unavailable로 표시합니다. 이 command는 raw argv, prompt,
environment value, credential reference/value, cwd/private/log path,
session/thread/account identity, provider response를 출력하지 않으며 worker subprocess,
provider/API/credential access, queue/config/event/state write를 수행하지 않습니다.
세부 계약은 Gateway-neutral execution plan을
참고하십시오.
cbr enqueue --delegation-contract-json OBJECT accepts one complete canonical
cbr-execution-delegation-contract-v1 JSON object in the first atomic task
write. The task id binding must match. The field is immutable after enqueue;
the flag cannot add or replace a contract on an existing task.
--model-requirement-json은 complete requirement v2 JSON을 semantic default 없이 검증합니다. Issuer-owned revision_id, 여섯 quality axis의 score/confidence/anchor/evidence codes, hard constraints, utility preferences를 canonical task에 저장합니다. 기존 per-dimension flags는 compatibility surface로 남아 deterministic legacy-derived v2 revision을 만들며 exact v2 cohort에는 포함되지 않습니다. --routing-override-json은 single-task override를 검증·저장하지만 D2 전에는 selection에 적용하지 않습니다.
config 탐색 순서:
--config명시값CBR_CONFIG환경 변수$XDG_CONFIG_HOME/codex-batch-runner/config.jsonXDG_CONFIG_HOME이 없으면$HOME/.config/codex-batch-runner/config.json
먼저 선택된 path가 missing, unreadable, invalid JSON, non-object이면 lower tier로 fallback하지 않고 실패합니다. Discovery는 config/runtime directory를 만들거나 cwd-local config를 찾지 않습니다. 자동화와 launchd에서는 명시적 absolute --config를 권장하며 interactive operator는 XDG 또는 CBR_CONFIG를 사용할 수 있습니다.
cbr launchd plan --label LABEL --executable ABS_PATH --working-directory ABS_PATH --stdout-path ABS_PATH --stderr-path ABS_PATH --environment-path PATH_VALUE --start-interval-seconds SECONDS [--existing-plist PATH] [--json]은 managed LaunchAgent의 intended plist를 렌더링하는 read-only command입니다. Config path/source는 normal config discovery에서 주입하며 operator가 별도로 override할 수 없습니다. --existing-plist가 있을 때만 해당 regular/readable file을 읽어 not_installed, managed_ok, drifted, foreign_conflict, unhealthy를 분류합니다. Human/JSON output은 status, action, reason, digest, sanitized config provenance/path, intended plist를 포함합니다. foreign_conflict와 unhealthy는 blocked action 및 exit status 2를 반환합니다. Command에는 mutation flag가 없고 plist write, launchctl, install/update/uninstall, foreign plist adoption을 수행하지 않습니다.
cbr launchd install은 plan의 rendering input에 --destination ABS_PATH --user-domain gui/UID [--dry-run | --apply] [--confirm-label LABEL] [--json]을 더합니다. 기본 mode는 dry-run입니다. Apply는 --apply와 exact label confirmation을 모두 요구하며, Darwin non-root current user, exact gui/UID, resolved config identity, exact HOME/Library/LaunchAgents/LABEL.plist destination, existing LaunchAgents directory를 검증한 뒤에만 가능합니다. Absent destination은 install, same owned digest는 no-op, owned drift는 update이며 foreign/malformed/symlink/non-regular/oversized destination은 blocked입니다. Update는 same-directory unique backup, exact gui/UID/LABEL service-target bootout, atomic replace, absolute-path bootstrap 순서이고 실패하면 old bytes restore와 re-bootstrap을 시도합니다. Bootstrap은 호출 직전에 destination identity를 재검증하고 undocumented /dev/fd 경로를 사용하지 않습니다.
cbr launchd uninstall --label LABEL --destination ABS_PATH --user-domain gui/UID [--dry-run | --apply] [--confirm-label LABEL] [--json]은 exact owned label/config identity만 제거 대상으로 인정합니다. Apply는 plist path가 아닌 exact gui/UID/LABEL service target으로 먼저 bootout하고, 성공한 경우에만 plist를 same-directory recoverable backup으로 atomic move합니다. Bootout 실패 시 plist는 유지됩니다. planned, noop, applied는 exit 0, failed와 completed rollback인 recovered는 exit 1, blocked와 incomplete rollback인 recovery_required는 exit 2입니다. Lifecycle result는 raw subprocess output이나 intended plist body를 포함하지 않습니다.
Lifecycle operation의 supported namespace threat model은 accidental/non-adversarial concurrency입니다. Identity 변화는 탐지하고 rollback은 관찰된 identity를 다시 확인한 뒤 best-effort로 수행합니다. Active same-UID adversarial namespace mutation은 지원하지 않으며 strict protection에는 protected directory 또는 privileged helper가 필요합니다. JSON은 namespace_concurrency object, human output은 namespace_concurrency_supported, namespace_concurrency_behavior, namespace_concurrency_unsupported, strict_protection_requires로 이 계약을 표시합니다.
enqueue --title은 list scanability를 위한 사람이 붙이는 짧은 제목입니다. 보통 4-8 words 정도의 action + object + short qualifier 형태를 쓰되, 글자 수 목표를 맞추려고 늘리지 않습니다. 같은 list에서 충분히 구분될 정도면 되고 전역 고유성은 필요하지 않습니다. Canonical identifier는 task id입니다. Full prompt 첫 문장, 긴 배경 설명, private detail, raw path, session/thread id, runtime/log 내용은 title에 넣지 않습니다. 저장 및 표시 title은 whitespace를 한 칸으로 접고 80자에서 deterministic ellipsis 처리합니다. --title이 없으면 prompt의 첫 non-empty line을 같은 규칙으로 fallback 표시하고, 그것도 없으면 task id를 표시합니다.
cbr status [--json]는 Codex나 운영 자동화가 cbr를 실행 표면으로 쓸지 판단하기 위한 lightweight read-only preflight입니다. state처럼 raw runner state만 출력하지 않고, runner pause, global cooldown, reviewer Codex cooldown, active lock, queue admissible count, review backlog, accepted-but-unapplied worktree count를 한 report로 요약합니다. JSON의 admission.status는 available, paused, cooldown, locked 중 하나이며, can_enqueue, can_run_next, can_start_cbr_execution, blocked_reasons, recommended_action을 함께 제공합니다. queue.capacity.capacity_pools는 configured pool마다 max_running, running, remaining, blocked, blocker_reason을 표시하며, 기존 running_by_pool도 호환성을 위해 유지합니다. Human output도 같은 pool별 local admission 상태를 별도 표로 표시합니다. 이 값은 cbr scheduler의 local capacity일 뿐 provider quota를 나타내거나 capacity pool 이름에서 provider quota를 추론하지 않습니다. 이 명령은 runner를 실행하지 않고, lock을 획득하지 않고, queue/state/event 파일이나 디렉터리를 생성하지 않으며, post-mutation trigger를 실행하지 않습니다.
cbr provider-resource-report [--snapshot-json PATH] [--mapping-json PATH] [--policy-json PATH] [--snapshot-command-json JSON_ARGV] [--codex-cached-json PATH] [--codex-cached-command-json JSON_ARGV] [--include-antigravity-unavailable] [--adapter-timeout SECONDS] [--max-age-seconds SECONDS] [--evaluated-at ISO_TIME] [--json]는 local scheduler capacity와 provider resource evidence를 분리해 표시하는 read-only advisory입니다. Snapshot과 mapping v1 compatibility contract는 기존 provider-resource-report-v1 shape를 유지합니다. Mapping v2 또는 admission policy v1을 제공하면 provider-resource-report-v2로 source-attested identity, exact scope/producer revision, accepted event-time provenance와 policy timing을 검증한 authority_preview를 추가하지만 scheduling activation은 하지 않습니다. Current codex-session-rollout-v2 cached projection은 client_event_at, timestamp provenance와 source adapter revision을 보존하고 missing/malformed event time에는 다른 clock으로 fallback하지 않습니다. Legacy shape는 file-mtime confidence의 advisory compatibility로만 남습니다. 두 shape 모두 unknown quota identity이므로 authority preview에서 거부됩니다. Antigravity는 quota/reset source가 생길 때까지 resource_capability_unavailable만 보고합니다. Adapter는 bounded argv list로만 실행되고 raw command/stdout/stderr를 report에 복사하지 않습니다. --max-age-seconds는 v1 advisory freshness 전용이며 authority timing이나 global usage-admission threshold를 대체하지 않습니다. 이 명령은 queue, cooldown, wake, target selector, routing policy, config를 변경하지 않습니다. 상세 계약은 provider resource report를 참조합니다.
cbr provider-resource-simulate --request-json PATH --snapshot-json PATH [--snapshot-json PATH ...] --mapping-json PATH --policy-json PATH [--evaluated-at ISO_TIME] [--json]는 D2-A selected exact-target resource decision과 alternative exact-target을 preview합니다. Request v1은 selected target, immutable requirement v2 revision, explicit global gate result를 포함합니다. Simulator는 existing selector hard constraint와 quality floor를 모든 alternative에 다시 적용하고, source-attested mapping/snapshot/policy authority가 성립한 target에만 allow, defer, covered_by_global, evidence_only recommendation을 계산합니다. Reset grace와 freshness 값은 admission policy revision에서만 읽으며 CLI default나 global usage-admission config를 재사용하지 않습니다. Global terminal gate는 target evaluation보다 우선하고 covering reset은 duplicate wake 없이 covered_by_global로 표시합니다. Unknown, stale, invalid, unavailable, missing, ambiguous evidence는 selected execution을 유지하는 evidence_only이며 defer를 만들지 않습니다. JSON/human output의 canonical resource, decision, wake key와 wake time은 preview일 뿐 queue, state, event, cooldown, wake, config, routing policy를 변경하거나 automatic substitution/D2-B activation을 수행하지 않습니다.
cbr execution-target-selector-decision-envelope --request-json PATH --json은 strict execution-target-selector-decision-envelope-request-v1에서 report-only selector envelope를 build하고 standalone replay 검증합니다. Canonical routing_override 또는 source-attested authoritative absence를 task/attempt/scope/selector revision과 unchanged ordering-v1 baseline에 exact-bind합니다. --config를 거부하고 runner state, queue, task evidence를 읽거나 변경하지 않으며 runtime selector/dispatch/reservation을 호출하지 않습니다.
cbr capacity-reservation-feedback-simulate --request-json PATH --json은 strict capacity-reservation-feedback-simulation-request-v1을 standalone reconstructed report로 preview합니다. Embedded mapping v2, admission policy v1, complete unchanged target-ordering activation report, exactly one current selector decision envelope, canonical typed gate state/decisions, source-attested currentness, reservation/feedback/recovery/retry evidence bodies와 exact digest, parsed earliest expiry, append-only lineage, strict bool/int types를 검증합니다. Absence는 ordering-v1 target, preference/pin은 exact override target, preference fallback은 immutable automatic baseline target을 사용합니다. Invalid/unavailable/missing/stale/conflicting binding은 Branch 3A에서 fail closed합니다. --config는 거부되며 runner state를 읽거나 변경하지 않습니다. Provider 호출, capacity reservation, half-open activation, task retry, cooldown/dependency/resume/routing policy 변경도 수행하지 않습니다.
cbr list 기본 출력은 운영자가 신경 써야 할 task 중심으로 유지합니다. archived, completed accepted and applied worktree task, non-worktree completed + accepted, resolution이 기록된 task, discard cleanup이 완료된 rejected worktree task는 기본 출력에서 숨기고, completed + unreviewed/rejected/needs_followup과 accepted-but-unapplied worktree task는 표시합니다. 전체 조회가 필요하면 --all을 사용합니다. failed task는 한 줄짜리 last_error 요약을 함께 표시합니다.
사람이 읽는 기본 cbr list 출력은 header가 있는 compact list입니다. Wide table의 첫 줄은 [M], TITLE, STATUS, DETAIL을 표시합니다. [M]는 model requirement marker를 표시하고, TITLE은 marker를 제외한 task title만 표시합니다. 표시 task는 project별 [project-id] section 아래에 묶고, 각 item row에는 project id와 task id를 반복하지 않습니다. parent_task_id, subtask_for, root_task_id, blocking_subtask_ids로 parent/root 관계가 확인되면 child task의 TITLE cell에 ├─/└─ tree connector를 붙여 parent 아래에 표시합니다. Color-enabled 출력에서는 child connector와 child title을 dim 처리합니다. 기본 list에서 parent/root task가 표시되면 자체 상태만으로는 숨겨질 completed accepted subtask도 그 parent/root 아래에 함께 표시합니다. --needs-review처럼 source task를 좁히는 human filter를 사용해도 parent/root task가 표시되면 숨겨질 subtask는 같은 parent/root 아래에 다시 포함됩니다. TITLE과 DETAIL은 terminal width 안에서 wrap 또는 ellipsis 처리되고, 산출된 최소 table width가 terminal width보다 크면 table 대신 project section과 [M]:, TITLE:, STATUS:, DETAIL: block layout을 사용합니다. --json과 --verbose는 이 narrow block layout 영향을 받지 않습니다. STATUS는 compact phase+kind 토큰이며, 예시는 --success, ##dep, ??review, ++followup, ++apply, ..new, ..resume, ||cooldown, ||capacity입니다. RAW_STATUS는 task JSON의 raw status로, blocked_dependency, needs_followup, awaiting_review, review_rejected, accepted_unapplied, discarded 같은 legacy/effective/debug 문자열은 JSON/RAW_STATUS에서 확인할 수 있는 내부 참조값입니다. Capacity 때문에 admission되지 않는 runnable task는 raw status를 바꾸지 않고 DETAIL에 capacity blocked: ... reason을 표시합니다. DETAIL은 dependency readiness, cooldown/resume timing, capacity blocker, failed error, resolution, review state, startup stall evidence, running runtime/progress, completed elapsed/duration, blocking subtask aggregate timing, non-default scheduling metadata를 사람이 읽는 segment로 표시합니다. 완료되어 현재 dependency readiness 정책상 만족된 dependency도 기본 출력에서 숨기지 않습니다. 색이 꺼진 출력에서는 만족된 dependency를 [N] dependency title (done)처럼 최소 텍스트로 표시하고, 색이 켜진 출력에서는 dim style로 표시합니다. 아직 만족되지 않은 dependency는 [N] dependency title (blocked), [N] dependency title (not_accepted), [N] dependency title (not_applied), missing dependency: dep-id (missing)처럼 DETAIL에서 직접 구분합니다. needs_resume task는 cooldown 중이면 resume in 12m (14:32), 바로 실행 가능하면 resume ready를 표시합니다. running task는 running for 12m 또는 running for 1h 04m처럼 started_at 기준 경과 시간을 표시하고, progress metadata가 있으면 last event 35s ago 또는 no progress 9m 같은 최근 활동 상태를 함께 표시합니다. 초 단위는 1분 미만 elapsed/age에만 표시합니다. 완료됐지만 review/apply 등 후속 조치가 남아 list에 보이는 task는 completed 8m ago와 duration 21m 같은 timing segment를 표시할 수 있습니다. Parent/root task에 active blocking subtask가 있으면 parent DETAIL은 subtask count와 함께 failed/blocked, running, review 대기 중 가장 actionable한 aggregate timing 하나를 표시하고, child row는 자기 own timing을 표시합니다. 자동화나 스크립트는 human list 형식에 의존하지 말고 raw task status를 유지하는 --json을 사용해야 합니다.
cbr list --graph는 기본 compact list와 분리된 human dependency graph를 출력합니다. --graph는 현재 목록 대상의 non-interactive 스냅샷 렌더러로, 노드 선택/펼치기/검색/필터 네비게이션 같은 대화형 상호작용은 제공하지 않습니다. Project section 아래에서 source task는 한 번씩 * status title graph node로 표시합니다. depends_on 관계는 dependency task를 dependent task 아래의 child/detail row로 복제하지 않고, source node 사이의 git-style diagonal/vertical rail로 연결합니다. 선형 chain은 * ... A, |, * ... B, |, * ... C처럼 한 레인으로 렌더링되어 fan-in을 표시하지 않습니다. 다수의 dependency가 하나의 task로 모이면 * ... dependency A, | * ... dependency B, \\|, * ... dependent처럼 join 형태를 유지합니다. ├─/└─ tree connector는 parent/subtask 관계에만 사용하며, subtask row는 source * 없이 parent 아래에 ├─ status title 또는 └─ status title로 표시합니다. Graph mode는 사람이 dependency shape를 직관적으로 보는 view이므로 task id, attempts, note는 출력하지 않습니다. Source task status는 기본 list와 같은 effective status와 color policy를 사용합니다. Color-enabled graph output은 glyph grid에 붙은 metadata로 색을 정합니다. Task node glyph *는 node identity metadata를 갖고 해당 task의 node color를 사용합니다. Line glyph |, \\, /는 lane/stroke identity metadata를 갖고, 이어지는 lane은 보통 그 lane을 시작한 source task의 node color를 유지합니다. Layout은 서로 독립인 lane 두 개가 같은 cell을 차지하는 true crossing을 피해야 하며, future layout에서 crossing이 필요해지면 한 glyph에 두 lane color를 인코딩하지 말고 row/column을 추가해 피합니다. Color는 보조 시각 정보이므로 --color=never ASCII 출력은 같은 graph/tree 의미를 유지합니다. Dependency task title은 dependency라는 이유만으로 dim 처리하지 않습니다. 반면 subtask title과 subtask tree glyph는 dim/tree style을 사용하며 dependency lane color와 분리합니다. 좁은 terminal에서는 graph/tree prefix와 status label 영역을 유지하고 title만 continuation line으로 wrap합니다. Parent title wrap은 pending subtask tree rail을 label gap에 유지하고, last-child subtask title wrap은 vertical tree rail을 유지하지 않으며, non-last child wrap은 tree rail을 유지합니다. Dependency source continuation은 | | 같은 visible rail을 보존합니다. --graph는 human renderer만 바꾸고, --json과 함께 사용하면 graph-specific JSON schema를 만들지 않고 기존 raw task JSON 배열을 그대로 출력합니다. --watch --graph는 같은 graph renderer를 반복 갱신합니다.
cbr list --demo는 실제 queue나 runner state를 읽거나 쓰지 않고 in-memory synthetic task set을 기존 list renderer에 통과시킵니다. 기본 compact list, --graph, --verbose, --color, narrow layout, --json renderer를 작업이 없는 환경에서도 확인하기 위한 sample surface입니다. Demo JSON task에는 "demo": true가 포함됩니다.
Human compact table은 model requirement marker를 [M] column에 표시합니다. --graph와 DETAIL dependency segment처럼 별도 marker column이 없는 human renderer는 title 앞에 marker를 붙여 [N] dependency title (done) 또는 * ..new/..resume [D] title 형태로 표시합니다. 낮은 reasoning depth와 높은 cost sensitivity 조합은 [S], 높은 reasoning 또는 tool reliability 요구는 [D], 그 외는 [N]을 사용합니다. Color-enabled 출력에서는 marker 자체에도 marker 색을 적용합니다. 이 marker는 ASCII만 사용합니다.
Review와 resolution metadata도 effective STATUS 토큰에 반영합니다. completed + unreviewed는 ??review로 표시합니다. completed + needs_followup은 ++followup으로, accepted-but-unapplied worktree task는 ++apply로 표시합니다. 완료되었으나 폐기/거절/해결된 결과는 --resolved, --success 계열로 정리되며, 내부적으로는 resolved, discarded, review_rejected, review_failed, needs_followup, accepted_unapplied 같은 legacy/raw 이름이 사용될 수 있습니다. discarded row는 --all에서 DETAIL에 rejected; discarded; not applied를 표시하며, RAW_STATUS에서 review_status, raw status, legacy status를 함께 확인할 수 있습니다. Startup stall evidence는 현재 재시도 대상이면 retry evidence로, 이미 완료되었거나 해결된 task이면 history로 DETAIL에 표시해 과거 이력이 현재 장애처럼 보이지 않게 합니다.
cbr list human 출력은 optional color를 지원합니다. --color=auto|always|never 중 하나를 사용할 수 있으며 기본값은 auto입니다. auto는 stdout이 TTY이고 NO_COLOR가 없을 때만 색을 켭니다. always는 색을 강제로 켜고 never는 항상 끕니다. Color-enabled 출력에서는 project section header를 muted background stripe로 표시하고 terminal width를 알 수 있으면 줄 끝까지 채웁니다. DETAIL의 dependency blocker label은 dependency task의 effective status style을 사용합니다. 만족된 dependency는 color-enabled 출력에서 dim style로 표시해 inactive dependency임을 구분합니다. Missing dependency는 special danger style을 사용합니다. Completed-but-unaccepted dependency는 color-enabled 출력과 color-off 출력 모두 dependency title에 (not_accepted) suffix를 유지합니다. STATUS는 color-enabled human output에서 foreground 색만이 아니라 background가 있는 label 형태로 표시합니다. 색상 그룹은 compact 토큰의 phase/kind 조합을 기준으로 적용되며, 상태 라벨의 내부명은 RAW_STATUS/JSON에서 확인할 수 있습니다. 알려지지 않은 future/external status도 plain text로 떨어지지 않고 neutral background label로 표시합니다. 색은 보조 시각 정보이며 색이 꺼져도 같은 정보를 텍스트로 읽을 수 있어야 합니다. --json 출력에는 ANSI code를 포함하지 않습니다.
cbr list --verbose는 사람용 table에 RAW_STATUS, LAST_RESULT, LAST_RUN, LAST_ERROR, PROVENANCE, NEXT 열을 추가합니다. RAW_STATUS는 task JSON에 저장된 원래 status를 표시해 effective STATUS와 구분합니다. LAST_RESULT는 last_result.status, last_result.summary, optional commits/push_status, task git_status의 한 줄 요약을, LAST_RUN은 last_run.command_kind, returncode, duration_seconds를, LAST_ERROR는 last_error의 한 줄 요약을 표시합니다. PROVENANCE는 queue_surface, selected_surface, worker, planned_model, actual_model, reasoning, rationale 레이블을 한 줄로 표시합니다. Queue membership은 queue_surface=cbr_batch만 증명합니다. Package 1은 선택 영수증을 스캔하지 않으므로 selected_surface=unknown을 유지하고, exact selection은 cbr orchestration selection-funnel에서 확인해야 합니다. worker, planned_model, rationale=execution_target:...은 execution-report의 처리된 run 파생값을 재사용하며 실행 전에는 unknown/unavailable입니다. actual_model은 accepted execution evidence에서만, reasoning은 exact execution-evidence-v3 identity에서만 표시합니다. Malformed evidence나 bounded identifier 검증에 실패한 값은 echo하지 않고 unknown/unavailable로 표시합니다. NEXT는 기존 상태/의존성/subtask/검토/적용 projection을 follow/summary, review-next --dry-run, worktree apply TASK_ID --dry-run, resolve command family 같은 다음 단계 힌트로 변환한 advisory이며 action이나 완료 증거가 아닙니다. 누락된 값은 -, unknown 또는 unavailable로 표시하고 transcript 또는 raw JSONL 내용은 출력하지 않습니다. Human 출력은 canonical evidence가 아니며 별도 digest나 시간 의미를 만들지 않습니다. 좁은 terminal에서는 verbose table을 label-preserving block layout으로 wrap합니다. --json을 함께 사용하면 verbose 열을 만들지 않고 기존 JSON task 배열을 그대로 출력합니다.
cbr list --unreviewed는 completed + unreviewed task만 표시함. cbr list --needs-review는 completed + unreviewed/rejected/needs_followup task를 표시하되, discard cleanup이 완료된 rejected worktree task는 이미 닫힌 결과로 보고 제외함.
cbr archive TASK_ID는 task 파일을 삭제하지 않고 status=archived, previous_status, archived_at을 기록함.
Successful queue mutations run the optional post_mutation_trigger_command after durable writes. This includes enqueue, accept, reject, resolve, archive, cooldown clear, pause clear, and successful apply-plan --apply mutations. enqueue is refused while runner pause is active, so it does not write a task or run the trigger during a maintenance pause. After run-next processes one task and releases the runner lock, it may run the same wake-up hook when eligible follow-up work remains and neither global cooldown nor runner pause is active. For auto-review acceptance or bounded auto-fix enqueue, eligible follow-up work includes newly runnable implementation work, the newly created fix task, and another immediately actionable auto-review candidate. Read-only commands, apply-plan dry-runs, cooldown show, cooldown set, pause show, pause set, refused enqueue, empty/cooldown/paused run-next exits, and mutation-free auto-review outcomes do not run the trigger. run-loop suppresses these per-iteration post-run wake hooks because the same process claims eligible follow-up work on the next loop iteration.
cbr summary TASK_ID는 task metadata, dependency blocked 상태, dependency blocker reason, last_result.summary, optional commits/push_status, changed files, verification, task git_status, last_error, next_prompt, log path를 transcript보다 짧은 Markdown 형식으로 표시합니다.
cbr routing-report [--project PROJECT_ID] [--category CATEGORY] [--label LABEL] [--execution-evidence-json PATH] [--json]는 queue의 routing outcome/cost 신호를 read-only diagnostics로 출력합니다. 집계 그룹에는 model requirement, model selection rule, category/label, experiment, experiment lane family, routing_size/risk, verification scope, routing decision tuple, low-cost candidate 신호, provider resource evidence가 포함되며 accepted/needs-fix/rejected rate, reviewer decision, auto-fix frequency, attempts/run, duration 기반 cost proxy가 함께 표시됩니다. evaluation_diagnostics.task_buckets에는 static threshold-only advisory도 포함됩니다. 기준은 min_accepted_count=5, min_first_pass_accept_rate=0.90, max_needs_fix_or_rejected_rate=0.05이고 status는 insufficient_sample, below_threshold, reviewable 중 하나입니다. evaluation_diagnostics.probe_lanes는 existing routing_experiment 값을 baseline, probe, guard, manual, unspecified, other lane family로 분류해 task bucket과 requirement별 lane outcome을 보여주는 read-only diagnostic입니다. 이 advisory는 이미 있는 evaluation evidence만 요약하며 routing/model policy mutation 또는 apply 동작을 수행하지 않습니다. provider resource evidence는 현재 Codex provider 불확실성을 provider_id=codex, quota_boundary=unknown, sharing_assumption=not_independent로 드러내는 advisory signal이며, local capacity_pool, worker/reviewer role, legacy profile name에서 provider quota bucket을 추론하지 않습니다. 보고 결과는 요구 벡터와 selection rule 후보를 가늠하기 위한 운영 증거일 뿐, 정책을 자동 변경하지 않습니다.
cbr recommend-routing --task-bucket KEY --execution-surface SURFACE --semantic-complexity VALUE --failure-cost VALUE --objective-verification VALUE --expected-context CONTEXT_CONTRACT_VERSION --interaction-need VALUE --usage-pressure VALUE [--available-model MODEL] [--routing-cost-evidence-json PATH] [--json]는 하나의 작업 요청을 대상으로 deterministic advisory를 반환합니다. Queue의 exact routing-cost-evidence-v2와 optional sanitized supplemental records만 recommendation 후보로 사용하고 v1/v2 execution, CLI-default, legacy, automatic/override, integrity-adverse 또는 contract-version mismatch cohort는 합치지 않습니다. CBR worker와 user-owned thread를 포함한 서로 다른 execution surface도 합산하지 않습니다. expected-context는 record의 context contract version과 exact match해야 하며, high semantic complexity/failure cost는 objective+semantic verified cohort를 요구하고 interaction need가 있으면 evidence가 부족한 것으로 처리합니다. Usage pressure는 quality gate를 낮추지 않으며 high/critical이면 provider-attributed usage를 요구합니다. Output separates exact model, reasoning_effort, and rationale; all xhigh reasoning evidence is excluded from candidates and cannot be inherited. Current routing-cost contracts have component token usage but no normalized pricing/cost field, so the command preserves component vectors and attribution confidence but returns status=insufficient with static operator_baseline fallback instead of inventing a scalar cross-model ranking. Invalid comparison contracts return an explicit insufficient reason such as no_matching_exact_v3_cohort or non_comparable_or_sparse_cohort. This command does not create threads, enqueue work, call Codex, mutate routing policy/config, or apply a recommendation.
cbr execution-report [--project PROJECT_ID] [--project-root PATH] [--category CATEGORY] [--label LABEL] [--limit N] [--include-archived] [--json]는 enqueue 시점의 의도 대신 실제 처리된 task run만 요약하는 read-only report입니다. 각 row는 task title, status/review status, started/finished time, queue wait, duration, execution backend, capacity pool, worker family, return code, timeout 여부, model source/selection rule/execution target, resolved worker target/model group, external worker --model-group, result count, token usage를 포함합니다. preexecution_delegation은 immutable admission과 exact-target receipt/pre-worker ordering을 표시합니다. Receipt만 durable하게 남고 worker가 시작되지 않은 crash state는 --purpose diagnostic|audit에 insufficient로 보이며 routing evidence로 승격되지 않습니다. natural_execution_attestation은 append-only natural objective, natural boundary, provider observation, synthetic boundary를 분리해 표시하는 additive report-only field이며 live routing이나 promotion authority를 만들지 않습니다. Codex run의 token usage는 configured log_dir 내부 attempt JSONL에서 최신 usage object를 읽어 input_tokens, cached_input_tokens, uncached_input_tokens, output_tokens, reasoning_output_tokens, known_total_tokens로 표시합니다. Shell backend는 token_usage_source=token_free이고, external-json-command/Antigravity처럼 usage가 노출되지 않는 backend는 token_usage_source=unavailable입니다. summary.model_measurements는 canonical queue의 exact execution-evidence-v3만 target/model/reasoning/automatic-or-override 단위로 집계하고, integrity/attestation, execution cohort와 version strata, review evidence 가용성, model-quality/token-cost comparable run 수, token component totals, completed/censored latency, timeout/failure evidence를 함께 표시합니다. Review quality는 review record의 bound execution_cohort_id가 현재 execution cohort와 일치하고 execution/review comparability와 integrity가 모두 통과한 run만 셉니다. review.strata는 task bucket, review policy/rubric, acceptance method, reviewer provenance/execution cohort, selection lane, reasoning effort, identity attestation과 execution contract versions를 드러내며, 두 모델에 공통 stratum이 없으면 cross-model 상태는 insufficient로 유지됩니다. v2/legacy/non-exact row는 non_exact_run_count로만 분리하며 exact target 집계에 섞지 않습니다. cross_model_quality_status는 evidence 부족, common-stratum 부족 또는 descriptive-only 상태를 명시하고 capability posterior나 cross-model 우열을 추론하지 않습니다. 이 report는 raw prompt, transcript/log body, full command argv, session/thread id, raw log path를 출력하지 않고 task JSON/event log/review status 또는 routing policy를 변경하지 않습니다.
--purpose diagnostic|audit은
summary.scoped_readonly_certification에 receipt-bound
scoped-readonly-certification-report-bundle-v1을 추가합니다. 기본 routing
purpose는 빈 scoped bundle만 반환하며 이 advisory를 routing/selection 입력으로
사용하지 않습니다.
cbr routing-policy-candidates [--project PROJECT_ID] [--category CATEGORY] [--label LABEL] [--execution-evidence-json PATH] [--include-non-reviewable] [--json]는 routing-report의 existing evaluation diagnostics task bucket advisory를 policy-change candidate surface로 재표시합니다. 기본 출력은 threshold_advisory_status=reviewable bucket만 candidates로 내보내며 각 entry는 candidate_id, task_bucket_key, evidence counts/rates, advisory status/reasons, fixed thresholds, recommended_next_step=operator_review, read_only=true, mutation_allowed=false를 포함합니다. decision_cards는 실행 후보 보고 상태와 사용자 결정 상태를 별도 축으로 표시하며, reviewable bucket은 user_decision_status=decision_required, non-reviewable bucket은 user_decision_status=not_ready로 표시합니다. --include-non-reviewable은 insufficient_sample/below_threshold bucket을 non_reviewable_buckets와 observation decision card에 함께 표시하고 blocked_reason, rejection_reasons, next step을 드러내며, human output은 recommendation/blocker summary groups를 표 위에 표시합니다. 이 명령은 candidate를 승인하지 않고, model/routing/provider config를 쓰지 않으며, task JSON/event log/review status를 변경하지 않습니다.
cbr decision-cards [--project PROJECT_ID] [--category CATEGORY] [--label LABEL] [--execution-evidence-json PATH] [--include-observations] [--source SOURCE] [--decision-axis AXIS] [--user-decision-status STATUS] [--json]는 현재 config의 policy-proposals execution-target-freshness decision cards와 routing-policy-candidates decision cards를 하나의 read-only inventory로 모읍니다. 기본 출력은 decision_required와 approval_blocked처럼 사용자가 볼 필요가 있는 카드만 포함하고, --include-observations를 붙이면 routing not_ready 관찰 카드도 함께 포함합니다. --source는 policy-proposals execution-target-freshness 또는 routing-policy-candidates를 받는 repeatable allowlist filter입니다. --decision-axis는 execution_target_freshness 또는 routing_policy_change를 받는 repeatable allowlist filter입니다. --user-decision-status는 repeatable allowlist filter이며 decision_required, approval_blocked, decision_pending, approved, not_approved, not_ready, invalid 중 하나를 받습니다. JSON에는 inventory generated_at, 각 source report의 generated timestamp/read-only metadata, summary.by_source, summary.by_recommendation, summary.by_blocked_reason, summary.next_action이 포함됩니다. summary.next_action은 카드가 없거나 모든 카드가 terminal approved/not_approved 상태이면 none, invalid 카드가 있으면 fix_invalid_decision_cards, actionable decision_required/approval_blocked/decision_pending 카드가 있으면 review_decision_cards, 그 외 not_ready 관찰 카드가 있으면 continue_observing입니다. Human open_decisions는 summary.next_action이 fix_invalid_decision_cards 또는 review_decision_cards일 때만 present입니다. Human output도 recommendation/blocker summary groups, per-card BLOCKED, next action hint를 표시합니다. 이 명령은 하위 report builder를 읽기 전용으로 호출하며 approval, apply, model/routing/provider config write, task/event/runtime mutation을 수행하지 않습니다.
cbr watching-report [--project PROJECT_ID] [--category CATEGORY] [--label LABEL] [--execution-evidence-json PATH] [--include-archived] [--json]는 queue, review/apply, worktree lifecycle, cooldown/rate-limit, routing policy observation evidence를 read-only area report로 모읍니다. 각 area는 evidence_status를 action_required, ready_for_close_review, continue_observing, no_evidence 중 하나로 표시하고, operator-facing operator_next_action과 compact signal list를 제공합니다. 명시적 resolution이 기록된 failed/blocked task와 discard cleanup이 완료된 rejected worktree result는 이미 닫힌 결과이므로 action-required blocker나 review backlog로 다시 세지 않습니다. needs_followup은 discard cleanup만으로 후속 책임이 사라지지 않으며 resolution이 없으면 기존 status/doctor/review-next와 같이 review backlog로 유지합니다. summary.next_action은 action-required area가 있으면 resolve_action_required, 닫을지 검토할 evidence가 있으면 review_close_candidates, 아직 부족하면 continue_observing, 아무 evidence가 없으면 none입니다. 이 report는 operator의 external watching/task dashboard를 자동으로 변경하지 않으며, task JSON, event log, review status, policy/config를 쓰지 않습니다.
--execution-evidence-json PATH는 repeatable option입니다. JSON object, {"records": [...]} object, 또는 object list를 받을 수 있으며 current public record kind는 legacy codex_subagent_execution, execution_evidence_v2, exact-target execution_evidence_v3, review_outcome_evidence_v1입니다. Legacy, v2, v3 cohort는 서로 합치지 않습니다. 이 record는 queue task로 등록되지 않고 execution_evidence_rows에만 나타납니다. task_count, task_rows, queue task group 집계는 변하지 않습니다. review_outcome_evidence_v1은 execution evidence를 재작성하지 않고 review outcome history만 supplemental row에 붙입니다. Evaluation diagnostics는 acceptance method를 cross-method aggregate하지 않고, exact review-outcome stratum별 worker anchor semantic-review coverage와 quality exclusion을 표시합니다. 입력 파일에는 structured metadata와 sanitized last_run/last_result/review outcome만 넣고 raw prompt, transcript/log body, session id, thread id, credential, private absolute path를 넣지 않습니다.
cbr routing-eval-report --json은 bounded row-level evaluation data와 함께 evaluation_diagnostics.probe_lanes와 execution_evidence_diagnostics.probe_lanes를 출력합니다. Queue task diagnostics는 evaluation_rows에서만 계산하고, supplemental diagnostics는 execution_evidence_rows에서만 계산합니다. 두 diagnostics 모두 read_only=true, mutation_allowed=false이며, baseline/probe/guard/manual/unspecified/other lane family, raw experiment, task bucket lane, model requirement lane별 outcome을 표시합니다.
Producer-facing examples are subagent-execution-evidence.example.json, execution-evidence-v2.example.json, and review-outcome-evidence-v1.example.json. Detailed contracts are in execution.md and review.md.
운영자용 범위/제외:
- 보여줌: model requirement/selection rule별 outcome/cost 집계, category/label-by outcome/cost 집계, low-cost 후보 힌트, reviewer decision와 auto-fix 빈도, stale sample 요약.
- 의도적 제외: raw prompt, full transcript/JSONL, per-task full body output, Codex 재호출/실행 계획/patch 제안 같은 auto action.
- 보장: task JSON/event log/review status 미변경, Codex/reviewer Codex 미호출, 기존
routing-report자체는 advisory read-only.
cbr review-bundle TASK_ID는 현재 대화 context 없이 task 결과를 재검토하기 위한 read-only bundle을 stdout에 생성합니다. 기본 출력은 Markdown-like human report이고, --json은 같은 정보를 structured JSON으로 출력합니다. 포함 정보는 task metadata, sanitized prompt excerpt, status/review/resolution, dependencies와 blockers, last_result, last_run, worktree/follow-up linkage, changed files, verification, last_error, relevant log paths, completion-time task_git_status_snapshot, review-time task execution repository state, review-time main repository state, inferable commit information, safely scoped commit 또는 working tree diff/stat, public/private safety policy입니다. JSON compatibility를 위해 legacy git_status와 git_repository aliases도 유지합니다. current_git_repository는 gate가 검사하는 task execution repository를 나타내며, worktree-backed task에서는 current_main_repository와 current_task_worktree_repository도 별도로 표시합니다. commit hash를 명확히 하나로 추론할 수 있으면 해당 commit의 subject/stat/diff를 포함하고, 추론이 여러 개이거나 모호하면 diff를 생략하고 ambiguity를 보고합니다. commit을 추론할 수 없고 task execution repository의 working tree가 dirty이면 working tree diff/stat만 포함합니다. repository가 아니거나 git metadata를 읽을 수 없으면 fallback warning을 보고합니다. 원본 JSONL transcript 내용은 기본적으로 포함하지 않고, 명령은 Codex 호출, enqueue, accept/reject, task state 변경을 수행하지 않습니다.
cbr review-next와 cbr review-next --dry-run은 status=completed이고 review_status가 unreviewed, rejected, needs_followup인 task 중 가장 오래된 항목 하나를 선택해 concise review report를 출력합니다. 선택 기준 timestamp는 completed_at, fallback으로 updated_at, created_at, id를 사용합니다. --project, --project-root, --category, --label은 list와 같은 metadata fallback 규칙으로 후보를 좁힙니다. --json은 human report와 같은 정보를 structured JSON으로 출력합니다.
review-next report는 selected 여부, candidate count, task id, review status, dependency summary, review bundle 핵심 요약, mechanical gates를 포함합니다. Gate는 task status completed, final result status completed, last_error 없음, verification list 존재, changed_files list 존재, dependency ready, current git working tree clean, current unpushed commit 없음, task metadata/review bundle에서 감지 가능한 공개/비공개 안전 위반 없음 여부를 확인합니다. no_unpushed_commits detail은 current state와 task snapshot을 구분해 예를 들어 current_has_unpushed=False; snapshot_has_unpushed=True처럼 표시합니다. Current repository inspection에서 unpushed 상태를 확인할 수 있으면 task git_status snapshot의 old ahead/push 정보는 authoritative gate result로 사용하지 않습니다. Dependency summary는 config의 dependency_requires_accepted_review 적용 여부와 blocker reason(not_completed, not_accepted)을 포함합니다. 저장된 reviewer result가 needs_fix이면 report-only auto-fix planner도 함께 출력하며, 자동 fix task를 만들 수 있는지와 skip reason 또는 sanitized fix task draft를 보고합니다. Dry-run 명령은 read-only이며 task JSON, review_status, event log, post-mutation trigger를 변경하지 않고, follow-up task를 enqueue하지 않으며, Codex 또는 reviewer Codex를 호출하지 않습니다.
review-next --apply는 같은 report/gate 계산을 runner queue lock 아래에서 수행합니다. --mechanical-auto-accept, --reviewer-codex, config auto_review_mechanical_accept=true, config auto_review_codex_enabled=true 중 어떤 명시 opt-in도 없으면 task를 변경하지 않고 structured output의 auto_review.decision=needs_human으로 보고합니다. 모든 gate가 통과하면 적용 직전에 task updated_at, last_result, repository head/dirty/ahead 상태, inferred commit 정보가 gate 계산 시점과 같은지 다시 확인합니다. Stale state이면 accept/reject를 적용하지 않습니다. Completion-time task git_status snapshot의 old push/ahead 정보만으로 stale state가 되지는 않습니다. Gate 실패, stale state, lock busy 상태는 reviewer Codex 호출 없이 보고됩니다. Reviewer Codex는 auto_review_codex_enabled=false와 auto_review_codex_max_calls_per_run=0이 기본값인 별도 선택 경로입니다.
review-next --apply --reviewer-codex는 config의 reviewer call limit, global/reviewer cooldown, bundle/diff size limit을 통과한 경우에만 reviewer Codex를 한 번 호출합니다. Reviewer 입력은 sanitized review bundle로 제한하고 task 실행 raw log, session id, thread id, private queue contents를 전달하지 않습니다. Reviewer 응답은 decision schema를 엄격하게 검증합니다. pass + confidence=high + error finding 없음 + required human check 없음 + mechanical/stale-state 재확인 통과인 경우에만 review_status=accepted로 바꿉니다. needs_fix는 accept하지 않습니다. auto_review_codex_max_fix_loops_per_task >= 1, reviewer auto_fix_allowed=true, confidence=high, auto_fix_risk=low, non-empty suggested_fix_prompt, repeated finding 없음, fresh state 재확인이 모두 통과하면 별도 fix subtask를 enqueue합니다. 그 외 needs_fix, needs_human, failed_review, invalid schema, rate-limit은 accept하지 않고 sanitized reviewer summary/evidence와 skip reason을 task metadata와 event log에 기록합니다. Rate-limit은 reviewer 전용 cooldown을 설정하며 같은 invocation에서 retry하지 않습니다.
run-next의 sequential auto-review phase는 config auto_review_mechanical_accept=true 또는 auto_review_codex_enabled=true일 때만 켜집니다. Runner는 같은 queue lock 보유 상태에서 completed review candidate 한 건에 대한 apply logic을 먼저 호출합니다. 한 번의 run-next invocation은 auto-review accept, reviewer Codex 검토 호출, 또는 구현 task 실행 중 하나만 처리합니다. run-next --json은 항상 기존 outcome shape의 JSON object 하나만 출력합니다. Gate 실패나 human review가 필요한 상태처럼 task를 변경하지 않고 reviewer Codex도 호출하지 않는 후보는 starvation guard에 따라 해당 invocation에서 runnable/needs_resume 구현 task 선택으로 넘어갈 수 있습니다. 이 규칙은 오래된 비실행 가능 review candidate 하나가 runnable 구현 작업을 계속 막지 않도록 하기 위한 transient skip이며, manual review-next 선택 순서나 task JSON의 review 상태를 변경하지 않습니다. Auto-review accept가 dependency policy상 blocked된 child task를 runnable하게 만들거나 다음 자동 검토 후보가 gate, cooldown, reviewer backoff, size limit 조건상 즉시 처리 가능한 상태로 남아 있으면 lock 해제 뒤 기존 post-run trigger 조건으로 scheduler wake-up hook을 실행할 수 있습니다. 같은 기준으로 구현 task를 완료한 직후에도 runnable follow-up 구현 작업이 없더라도 즉시 actionable auto-review 후보가 남아 있으면 wake hook을 실행할 수 있습니다. Mutation 없는 auto-review skip은 trigger를 실행하지 않습니다. 별도로 global runner pause가 active이면 run-next는 queue lock 아래에서 stale running recovery만 수행하고 paused outcome으로 종료합니다. 이때 새 implementation task, reviewer Codex call, bounded auto-fix enqueue를 시작하지 않으며, 기존 live Codex child를 강제로 종료하지도 않습니다.
cbr run-loop은 launchd/operator single-worker용 command입니다. 각 iteration은 config를 다시 로드한 뒤 run-next와 같은 one-shot path를 호출하므로 pause, cooldown, lock, capacity, dependency, task cooldown, worktree, review gate를 우회하지 않습니다. run-next one-shot의 post-run wake hook은 loop iteration 안에서 실행하지 않습니다. --json 출력은 iteration마다 기존 run-next outcome shape의 compact JSON object 한 줄을 쓰는 JSONL입니다. Loop는 empty, paused, cooldown, locked, review_needed, stale_finalization처럼 다음 work가 actionable하지 않은 outcome에서 멈춥니다. Progress outcome이 계속 나오더라도 runaway를 막기 위해 --max-iterations safety fuse가 있으며 기본값은 100입니다. 이 값은 correctness 조건이 아니라 비정상 반복에 대한 운영 guard이므로 큰 queue를 한 scheduler tick에서 더 오래 drain하려면 높일 수 있습니다.
runner는 Codex task를 claim할 때 해당 attempt log path를 먼저 task metadata에 등록합니다. 첫 session/thread event와 meaningful progress가 도착하면 queue lock 아래에서 같은 active_run_id의 최신 running task를 다시 읽어 session_id, thread_id, bounded last_progress timestamp/count metadata만 atomic merge합니다. 이 live update는 raw event, prompt, transcript를 task status surface에 복사하지 않고, 다른 task/result/review field를 stale snapshot으로 덮어쓰지 않습니다. 이후 각 Codex 호출이 끝나면 task에 last_run metadata를 저장합니다. 필드는 command_kind, returncode, started_at, finished_at, duration_seconds, resume_id_used, log_path입니다. Watchdog이 Codex child를 종료한 경우 watchdog_reason도 포함합니다. task-level counters로 run_count, resume_count, rate_limit_count, failure_count도 유지합니다.
정상 final JSON 응답을 받은 뒤 runner는 실제 실행 cwd에서 네트워크를 사용하지 않는 local Git inspection을 시도할 수 있습니다. worktree_mode=disabled에서는 task cwd, worktree_mode=task에서는 task worktree가 inspection 대상입니다. repository이면 git_status에 branch, upstream, comparison_ref, ahead, behind, has_unpushed, dirty, unpushed_commits, warnings, inspected_at을 저장합니다. 비교 기준은 configured upstream을 우선하고, 없으면 local origin/<branch> 또는 origin/main ref를 사용합니다. runner는 push를 수행하지 않으며, 이 metadata는 운영자가 남은 push 작업을 판단하기 위한 보고용입니다.
cbr follow TASK_ID는 저장 중인 attempt JSONL을 read-only polling으로 관찰하는 operator view입니다. --lines N은 처음 표시할 기존 JSONL line 수를 제한하고, --poll-interval SECONDS는 새 log path와 append된 event 확인 주기를 정합니다. 출력은 compact human stream이며 assistant message, command start/finish, command exit code, final JSON, turn.failed/error/rate-limit marker 요약을 포함합니다. 사용자 prompt, session/thread id, obvious secret, credential, token, personal user path는 transcript/review sanitization pattern으로 redacted됩니다. task가 running이 아니고 더 읽을 새 이벤트가 없으면 종료합니다. 이 명령은 task JSON, runner state, event log, post-mutation trigger를 변경하지 않고 Codex를 호출하지 않습니다.
cbr transcript TASK_ID는 저장된 cbr JSONL 로그와, session_id 또는 thread_id로 찾을 수 있는 Codex 원본 세션 로그에서 주요 대화, tool 호출, patch, final/error event를 사람이 읽기 좋은 형태로 재구성함. 실행 중 task는 아직 log_paths metadata가 없더라도 configured task log directory의 attempt-*.jsonl을 read-only fallback으로 찾음. --raw는 원본 JSONL을 출력함.
cbr accept TASK_ID는 completed task에만 review_status=accepted를 기록함. Worktree-backed task에서는 branch/worktree linkage를 human output에 표시하고 같은 queue lock 안에서 post-accept apply path를 시도함. Fast-forward apply가 가능하면 main에 반영하고 apply metadata를 기록함. Clean stale-base rebase는 re-review로 되돌리고, stale-base conflict는 bounded worktree_conflict_fix subtask를 enqueue함. cbr reject TASK_ID는 review_status=rejected를 기록하고, --follow-up을 붙이면 review_status=needs_followup을 기록함. Reject는 운영자가 비정상 실행 결과나 후속 처리 필요성을 표시할 수 있도록 non-completed task에서도 허용함. reject --follow-up은 새 task를 생성하지 않고 원 task branch/worktree를 가리키는 review_follow_up metadata를 기록함.
cbr resolve TASK_ID --resolution VALUE는 failed, blocked_user, 또는 completed + rejected/needs_followup task에 운영상 처리 결정을 기록합니다. 허용값은 wont_fix, superseded, manual, smoke, duplicate입니다. resolution이 있는 task는 기본 cbr list와 review-next 후보에서 제외되고, cbr list --all 또는 cbr summary TASK_ID에서 확인합니다.
cbr rate-limits는 저장된 sanitized rate-limit evidence event를 조회함. --json을 붙이면 evidence JSON 배열을 출력함.
cbr cooldown show는 runner state의 global_cooldown_until, 활성 여부, approximate remaining duration을 표시합니다. cbr cooldown clear는 global_cooldown_until을 null로 지우고, 즉시 실행 가능한 작업이 있을 수 있으므로 post-mutation trigger를 실행합니다. Set/clear는 작은 sanitized cooldown_updated audit event를 기록합니다.
cbr cooldown set VALUE는 운영자가 알고 있는 다음 usage/rate-limit reset 시각을 기존 state mechanism의 global_cooldown_until에 기록합니다. 입력은 local timezone 기준으로 해석하며, 저장값은 interpreted_reset_at + 60 seconds입니다. 이 safety offset은 reset 직전 재시도를 피하기 위한 고정 기본값입니다. 출력은 원본 입력, zero-padded local interpreted_reset_at, 실제 저장되는 effective_cooldown_until, 그리고 현재 시각 기준 duration을 표시해 잘못 입력한 시간을 운영자가 바로 확인할 수 있게 합니다.
cbr pause show는 runner state의 runner_pause.active, reason, paused_at, paused_by를 표시합니다. cbr pause set --reason TEXT는 expiry 없는 global queue admission pause를 설정합니다. 활성화되면 enqueue는 task를 쓰지 않고 cbr is currently unavailable 오류로 종료하며, run-next/run-loop은 새 implementation task, reviewer Codex call, bounded auto-fix enqueue를 시작하지 않습니다. 이 state는 global_cooldown_until과 별개이며 rate-limit cooldown semantics를 재사용하지 않습니다. 또한 apply-plan이 task에 기록할 수 있는 task-level status=paused와도 다른 control-plane 상태입니다. Pause set은 runner를 깨우지 않습니다. cbr pause clear는 pause state를 기본값으로 되돌리고, runnable task 또는 review candidate가 다시 처리 가능해질 수 있으므로 post-mutation trigger를 실행합니다. Set/clear는 작은 sanitized runner_pause_updated audit event를 기록하며, state와 event에는 공개 가능한 짧은 reason과 operator id만 저장합니다.
지원 형식은 자연어 parser 없이 제한된 형식만 허용합니다. Time-only 형식은 H:M, HH:M, H:MM, HH:MM이며 오늘 해당 local clock time이 미래이면 오늘, 이미 지났으면 내일로 해석합니다. Date-time 형식은 slash M/D H:M, MM/DD HH:MM, dash M-D H:M, MM-DD HH:MM, year date YYYY-MM-DD H:M 또는 YYYY-MM-DD HH:MM을 지원합니다. Slash date는 항상 month/day이며 day/month로 해석하지 않습니다. Timezone이 포함된 ISO datetime은 정확한 advanced input으로 허용합니다. Relative duration은 +90m, +2h30m, +1d3h처럼 day/hour/minute 조합을 지원합니다. Hour는 0..23, minute은 0..59만 허용합니다. 명시적 date-time이 과거이면 다음 해로 roll forward하지 않고 오류로 종료하며, 해석된 reset 시각이 현재보다 7일을 초과해 먼 경우에도 오류로 종료합니다.
cbr events는 append-only event log에서 최근 event를 조회함. 기본 출력은 human-readable table이고, --json은 event object 배열을 출력함. --task-id로 특정 task event만 필터링할 수 있고 --limit으로 최대 출력 개수를 제한함.
cbr prune --notifier-cursor-state PATH는 local notifier cursor state를 read-only로 확인한 뒤 old event JSONL deletion safety에 반영합니다. Cursor v1의 canonical identity는 current_event_file + current_byte_offset이며, last_processed_event_id와 timestamp field는 optional checkpoint metadata입니다. Cursor state가 missing, malformed, unreadable이거나 configured event_dir 밖의 event file을 가리키면 event pruning은 skipped warning으로 block됩니다. Cursor가 현재 event file을 fully processed 하지 않았으면 해당 file은 삭제되지 않습니다. Core runner에는 external notifier adapter, Telegram token/chat id, ack/snooze/mute schema가 없고, adapter state/config는 public repository 밖의 local/private opt-in surface로 둡니다.
cbr retention-inventory는 canonical task, referenced log, event file을 읽어
retention-inventory-report-v1 sanitized projection을 출력합니다. 기본 호출은
age eligibility를 부여하지 않습니다. --proposal-age-days 60 같은 값은
report-only proposal input이며 TTL 채택이나 apply authority가 아닙니다. 이 명령에는
apply mode가 없고 canonical task JSON을 항상 protected로 표시합니다. 상세 계약은
Report-only retention inventory를 참고하십시오.
cbr retention compact --inventory-report PATH --task-id TASK_ID는 fresh unfiltered
inventory snapshot과 live task/event/cursor scope를 검증하는 dry-run이 기본입니다.
--apply는 dry-run이 출력한 exact --confirm-operation-id를 추가로 요구하며 queue
lock 아래에서 immutable compact bundle, logical non-deleting tombstone, lookup-only
restore index entry, transaction journal을 순서대로 atomic write합니다. 동일 snapshot
operation은 중복 생성하지 않고 bundle-only/prepared partial transaction을 재개합니다.
Canonical task/log/event를 삭제·이동·변경하지 않으며 raw log/transcript restore를
지원한다고 주장하지 않습니다. Operation id는 exact inventory
report/preview/scope/cursor/proposal-age approval에 bind되고, apply 전 기존 restore
index 전체의 bundle/journal 참조 무결성과 selected task의 acknowledged
parent-attention 상태를 다시 검증합니다. 상세 계약은 Retention inventory and
additive compact records를 참고하십시오.
cbr dashboard는 local read-only operator overview HTTP server를 실행합니다. 기본 bind는 127.0.0.1:8765이며 --host, --port로 변경할 수 있습니다. Browser를 자동으로 열지 않고, 인증/token 설정을 추가하지 않으며, queue/task/review/event/state를 변경하는 route를 제공하지 않습니다.
Routes:
GET /: dense operator dashboard HTML. 첫 화면은 queue overview(total, active, runnable, needs resume, capacity/running), review-needed backlog, accepted-unapplied, failed/blocked/usage exhausted, running/stale progress, cooldown/rate-limit, recent sanitized events, index warning을 보여줍니다.GET /api/dashboard: 같은 sanitized read model JSON. HTML은 이 contract를 재사용하며 raw queue/log file을 직접 우회해서 읽지 않습니다.HEAD /,HEAD /api/dashboard: read-only health/header check.POST,PUT,PATCH,DELETE:405와 read-only error를 반환합니다.
Dashboard action affordance는 mutation button/form이 아니라 CLI command hint만 표시합니다. 예시는 cbr list --needs-review, cbr review-next --dry-run, cbr worktree apply TASK_ID --dry-run, cbr events --limit 10, cbr index rebuild --dry-run처럼 운영자가 terminal에서 별도 실행할 수 있는 명령입니다.
Privacy limits: dashboard data는 build_dashboard_overview(config)의 sanitized output만 렌더링합니다. Raw prompt, full log/transcript, session/thread id, credential/token-like value, private worktree/local path, unsanitized event payload는 HTML/API에 포함하지 않습니다. Recent events table은 event type, occurred_at, task id, project id만 표시합니다.
Index warning behavior: SQLite read index가 없거나 schema mismatch, stale source count, unreadable DB처럼 usable하지 않으면 warning을 화면 상단에 계속 표시하고 canonical fallback summary를 사용합니다. 운영자는 cbr index rebuild --dry-run으로 rebuild impact를 먼저 확인할 수 있습니다.
cbr maintenance direct-worktrees는 cbr task metadata가 없는 direct operator git worktree를 audit하거나 보수적으로 정리합니다. Target repository는 기본적으로 command를 실행한 current working directory의 git root입니다. --repo-root PATH를 주면 해당 path의 git root를 target repository로 사용합니다. Queue lock, event log, configured task worktree_root 같은 runtime path는 계속 --config의 cbr config에서 가져옵니다. Discovery는 target repository에서 git worktree list --porcelain로 등록된 worktree만 사용하며, filesystem glob scan은 하지 않습니다. Main worktree와 configured worktree_root 아래 task worktree는 제외합니다.
worktree_mode=task에서 repository root에 tracked .cbr.toml이 있으면 worktree prepare와 run-next는 project-declared reusable pool을 사용합니다. copy path는 canonical checkout에서 lease마다 refresh하고, retain path만 lease 사이에 보존하며, repeated [[worktree.prepare]] argv를 순서대로 실행합니다. 설정이 없으면 기존 disposable task worktree를 사용합니다. 파일이 untracked이거나 invalid하면 fallback하지 않고 prepare를 거부합니다. worktree cleanup --apply는 pooled task의 branch lease를 해제하고 directory를 idle slot으로 돌려놓지만 task branch와 review/apply metadata는 기존 정책대로 보존합니다. doctor의 worktree.pool은 local pool state의 total/idle/leased count를 read-only로 표시합니다.
cbr worktree hibernation-plan [TASK_ID] [--project PROJECT_ID] [--json]는 canonical task metadata, local Git branch/head, worktree registry를 대조해 branch-only review, hibernation, reattach, resume compatibility를 reason code로 분리하는 deterministic read-only report입니다. Missing path는 intentional hibernation으로 추론하지 않으며, needs_resume는 같은 retained cwd가 없으면 incompatible입니다. Intentional worktree-hibernation-v1 metadata와 exact checkpoint가 확인된 task만 reattach-compatible로 표시합니다. Plan에는 --apply mode가 없고 worktree/branch/pool/task/event/config mutation을 하지 않으며 raw absolute path 대신 opaque repository ref만 출력합니다.
cbr worktree reconciliation-plan [TASK_ID] [--project PROJECT_ID] [--json]는 canonical task result/review/apply/worktree metadata, resolved base/checkpoint/observed branch head와 ancestry, Git worktree registry, existing hibernation/cleanup/branch-prune/conflict-fix/pool evidence를 sanitized source snapshot과 digest로 묶는 deterministic report-only command입니다. Action class는 no_action, manual_review, exact_repair_candidate, unrecoverable_without_owner_decision으로 고정됩니다. Exact candidate는 complete mutation provenance, resolved ancestor base, retained branch/checkpoint match, execution_applied_at, accepted+applied terminal cleanup receipt, current apply-target containment이 독립적으로 확인되고 유일한 inconsistency가 execution_worktree_status일 때만 enum-level retained|recovery_required -> cleaned delta를 표시합니다. Pooled candidate는 canonical task/branch/slot/policy와 local pool-state observation이 exact하게 일치하는 released lease receipt가 추가로 필요하며 leased/missing/conflicting evidence는 manual입니다. Pooled terminal cleanup 뒤 보존되는 idle slot directory와 Git registry entry는 observed slot path의 opaque binding과 일치하고 task branch registry entry가 없을 때만 current입니다. Valid cleaned rows는 exact branch-prune receipt로 branch가 이미 없거나 exact conflict-fix apply linkage 때문에 applied head가 parent checkpoint와 달라도 no_action입니다. Offline validator는 bound observation의 internal relationship과 derived reconciliation/cleanup/provenance/containment/pool/action projection을 다시 계산합니다. 이 표시는 repair authority가 아니며 command에는 --apply mode, queue/task/event/config mutation, worktree/pool/branch action, cleanup/GC/TTL/migration/backfill/archive/worker/hook 동작이 없습니다. Missing path alone은 lifecycle 또는 disposition evidence가 아닙니다. 자세한 contract는 Legacy worktree reconciliation plan을 참고하십시오.
cbr worktree reconciliation-repair TASK_ID --approved-source-digest DIGEST [--apply] [--json]는 단일 C1 exact_repair_candidate의 exact metadata repair입니다. 기본은 dry-run이고 apply는 canonical queue lock 소유권, requested task document id, live C1 source/action 재계산, approved digest match, exact task-document CAS를 요구합니다. Prepared audit를 durable append한 뒤에도 Git branch/registry/pool을 포함한 full C1 source를 다시 계산하고 통과한 경우에만 task를 씁니다. 허용된 task delta는 execution_worktree_status=retained|recovery_required -> cleaned 하나뿐이며 updated_at, result/review/resolution/archive와 나머지 metadata는 유지합니다. Same-directory atomic task replace 전후의 sanitized task_mutated prepared/committed audit phase가 exact preimage/postimage digest를 bind합니다. Audit은 configured event_dir/worktree-reconciliation-repair-v1/ 아래 opaque per-task .audit 파일 하나에 append하며 exact repair/recovery validator만 deterministic path로 발견합니다. Date-file cursor/deletion contract가 이 증거를 안전하게 관리하지 못하므로 일반 event iteration, index, notifier, prune, retention inventory/compaction에서는 제외합니다. Event directory/namespace/final file은 no-follow dirfd로 열고 device/inode binding과 single-link regular-file 조건을 append 전후에 재검증하며, symlink/non-directory/swap 또는 필요한 primitive 부재는 path fallback 없이 task mutation 전에 fail closed합니다. Strict read는 malformed/torn/unreadable/noncanonical/duplicate/out-of-order history를 fail closed합니다. Task write failure는 retryable하고 event byte를 남기지 않은 committed audit failure는 다음 exact retry에서 task를 다시 쓰지 않고 복구되며, fully committed invocation은 no-op입니다. Newline 없는 partial committed append는 자동 절단하지 않고 task postimage를 유지한 채 수동 audit 복구 전까지 fail closed합니다. Stale/drift/dirty/active/resumable/missing/ambiguous/pool-conflict evidence는 task mutation 전에 reject됩니다. POSIX에서는 file/directory fsync를 사용하며 required secure directory primitives가 없는 플랫폼에서는 apply가 fail closed하고 Windows directory-fsync/power-loss durability는 검증되지 않았습니다. Worktree, branch, Git registry, pool, cleanup/GC/TTL/migration/review/resolution/archive는 변경하지 않습니다.
cbr worktree hibernate TASK_ID --dry-run|--apply [--json]는 단일 completed task의 retained worktree만 대상으로 합니다. Queue lock 아래에서 clean worktree, exact base/branch/checkpoint, reconstructable branch-only review unit, scoped mutation provenance, pooled lease consistency를 다시 확인합니다. Apply는 먼저 recovery_required guard를 저장한 다음 disposable worktree를 제거하거나 pooled lease를 해제하고, 성공 시 execution_worktree_status=hibernated와 worktree-hibernation-v1 intent를 저장합니다. Branch/checkpoint와 task result/review disposition은 바꾸지 않습니다.
cbr worktree reattach TASK_ID --dry-run|--apply [--json]는 위 command가 만든 intentional hibernation만 받습니다. Exact branch/base/checkpoint, 다른 worktree checkout 부재, pooled preparation-policy fingerprint를 확인하고 disposable worktree 또는 compatible pool slot에 기존 branch를 연결합니다. 성공 상태는 retained이며 worker를 실행하지 않습니다. Partial Git/pool failure는 recovery_required로 남고, missing path/legacy metadata/active task/needs_resume/bulk/automatic hook/TTL/GC/branch deletion/migration/repair는 지원하지 않습니다.
초기 allowlist는 local branch codex/*와 current repository의 sibling path 중 basename이 <repo-name>-로 시작하는 worktree로 제한합니다. Allowlist 밖 branch/path는 삭제 대상이 아니며 blocked/refused candidate로 보고합니다. Allowlisted candidate는 current target branch 기준 merged 여부와 worktree dirty 여부로 merged+clean, merged+dirty, unmerged+clean, unmerged+dirty 중 하나로 분류합니다. merged+clean만 cleanup eligible입니다.
--dry-run은 eligible과 blocked/refused candidate를 compact human output 또는 structured JSON으로 보고하고 mutation하지 않습니다. --apply는 runner lock 아래에서 git worktree registry와 candidate state를 다시 읽은 뒤, 여전히 eligible인 candidate에만 git worktree remove <path>와 git branch -d <branch>를 실행합니다. Force remove/delete는 지원하지 않으며 fetch, pull, push, rebase, merge, cherry-pick도 실행하지 않습니다. Worktree removal이 성공했지만 local branch deletion이 실패하면 partial result로 보고하고 git branch -D로 재시도하지 않습니다. Apply 시 event log에는 branch, sanitized display path, head, classification, target, removal/deletion booleans, blockers만 기록합니다.
cbr doctor는 저비용 health check임. resolved queue_dir, log_dir, event_dir, lock_file, state_file 경로, runtime directory 접근 가능 여부, configured Codex executable path, resolved Codex executable path, executable availability, bounded configured executable --version output, model selection rule 이름과 allowlisted override key, execution target freshness 상태와 stale warning, decision-card count/source/recommendation/blocker summary, decision-card next action hint, global cooldown, runner pause, active lock age/pid/liveness, needs-review completed task 수, runnable task 수, cooldown task 수, startup/no-progress stall evidence, resolved failed/blocked task 수, resolved completed-review task 수, status별 task 수, mechanical auto-review enable 상태, reviewable completed task 수를 표시함. Human tasks는 operator-actionable count를 먼저 표시한 뒤 raw by_status inventory를 표시하고, Human checks는 ok/warning/error count와 warning/error detail 중심으로 요약하고, capacity는 running/admissible/blocked/over-capacity summary와 compact pool summary 중심으로 표시하며, 전체 check/capacity detail은 --json output에 유지합니다. Version 확인은 configured executable에 --version만 붙여 짧은 timeout으로 실행하며, codex exec를 호출하지 않음. Version command 실패, 빈 output, timeout은 warning으로 보고하고 doctor 실패로 취급하지 않으며, warning message는 wrapper가 설정된 경우에도 실제 configured executable 이름을 기준으로 표시합니다. configured/current project root가 git repository 안에 있으면 branch, dirty status, upstream 또는 local origin/main 대비 ahead/behind count도 표시함. worktree.task_branches JSON section과 human task_branches subsection은 task worktree branch lifecycle을 read-only로 표시합니다. 여기에는 task id, local branch name/existence/head, retained/cleaned/pruned metadata, apply/cleanup/prune status, path existence boolean, and locally known/configured remote task branch refs가 포함됩니다. Human output은 task branch total/displayed/omitted count를 표시하고 상세 행은 처음 20개로 제한하며, JSON output은 전체 worktree.task_branches를 유지합니다. git check는 local repository metadata만 읽고 fetch/pull/push 같은 network operation을 실행하지 않음. git executable 없음, git repository 아님, upstream 없음, remote ref 조회 불가 같은 상태는 warning으로 보고하고 doctor 실패로 취급하지 않음. --json을 붙이면 같은 정보를 JSON으로 출력함. error check가 있으면 non-zero로 종료하고 warning은 종료 코드에 영향을 주지 않음.
cbr worktree discard-stale-applied TASK_ID --dry-run|--apply --resolution superseded|wont_fix|duplicate|manual --reason REASON은 retained worktree task의 execution_apply_status=applied metadata가 현재 apply target에 포함되지 않는 stale state일 때만 사용합니다. --dry-run은 stale applied metadata와 eligibility만 보고합니다. --apply는 worktree나 branch를 삭제하지 않고, stale applied metadata를 execution_stale_applied_discard에 보존한 뒤 task를 review_status=rejected, resolution=<resolution>, execution_apply_status=discarded 상태로 전환해 기존 discard cleanup path가 처리할 수 있게 합니다. 이후 운영자는 cbr worktree cleanup TASK_ID --dry-run으로 discard cleanup 가능 여부를 다시 확인하고, 적합하면 --apply로 worktree만 제거합니다. Branch pruning policy는 바뀌지 않으며 discard-cleaned branch는 evidence로 보존됩니다.
cbr archive TASK_ID --check는 mutation 없이 terminal archive consistency를 검사합니다.
실제 cbr archive TASK_ID도 같은 gate를 강제하며 active status, 미종결 review/resolution,
active review/fix chain, retained worktree, unreleased pool lease가 있으면 거부합니다.
cbr execution-report의 기본 --purpose routing은 model-quality comparable evidence만
표시합니다. Legacy 운영 진단은 --purpose diagnostic, archived retained evidence까지
보는 감사 조회는 --purpose audit을 사용합니다.
cbr prune은 오래된 safe runtime log와 cursor-safe event file만 삭제하며 canonical task
JSON은 별도 deletion/cold-storage 정책이 없으므로 blocked/skipped 상태로 보존합니다.
cbr policy-proposals execution-target-freshness는 configured execution_targets의 freshness metadata를 읽고 read-only policy proposal report를 생성합니다. 이 command는 apply mode, config rewrite, task mutation, model replacement, rule replacement를 지원하지 않습니다. JSON report는 schema_version, kind, proposal_class, mode, generated_at, mutation, summary, items, proposals, decision_cards, warnings, errors를 포함합니다. Fresh target은 items에만 표시되고 proposal을 만들지 않으며, stale 또는 missing freshness metadata target만 proposals에 review_execution_target_freshness 또는 add_execution_target_freshness_metadata action으로 표시됩니다. decision_cards는 실행 보고 상태와 사용자 결정 상태를 분리해 표시합니다. Normal execution target freshness proposal은 user_decision_status=decision_required이고, direct model pin migration proposal은 user_decision_status=approval_blocked로 표시됩니다. default_execution_config 또는 model_selection_rules의 direct model pin은 raw model value 없이 target_kind=direct_model_pin item으로 표시되고, migrate_direct_model_pin_to_execution_target read-only proposal로만 노출됩니다. Direct model pin proposal은 local config freshness apply 대상이 아니며, model/rule 변경에는 별도 operator decision이 필요합니다.
cbr policy-proposals direct-model-pin-migration은 default_execution_config와 model_selection_rules에서 execution_target 대신 model을 직접 고정한 항목만 필터링해 별도 read-only migration proposal report를 생성합니다. JSON report는 proposal_class=direct_model_pin_migration을 사용하고, raw model value 없이 target path, sanitized selection refs, draft_execution_target_migration_proposal action, approval_blocked decision card, direct_model_pin_requires_separate_migration_approval blocker를 표시합니다. 이 command는 report-only surface이며 preview, approval-template, guarded apply, config rewrite, model replacement, rule replacement, routing/provider 변경, task/event/runtime mutation을 수행하지 않습니다.
cbr policy-proposals preview PROPOSAL_JSON은 기존 policy_proposal_report JSON을 읽어 read-only preview report 또는 human summary로 렌더링합니다. 현재 지원 proposal class는 execution_target_freshness뿐이며, preview item은 target, recommended_action, would_change: none, apply_ready: false, blocked_reason: preview_only_no_apply_target을 표시합니다. Preview decision_cards는 같은 사용자 결정 축을 유지하되 preview-only apply block reason도 함께 표시합니다. 이 command도 config rewrite, task mutation, model replacement, rule replacement, apply를 수행하지 않습니다.
cbr policy-proposals approval-template PREVIEW_JSON은 기존 policy_proposal_preview JSON을 읽어 사람이 편집할 수 있는 approval template를 stdout으로 렌더링합니다. Template는 source_preview_sha256, 각 approval의 source_item_sha256, proposal_id, target, recommended_action, approved: false, reviewer, reviewed_at, decision_note를 포함합니다. decision_cards는 각 approval entry를 user_decision_status=decision_pending으로 표시해 approval file 편집이 사용자 결정 축임을 분리합니다. 이 command는 approval file을 저장하지 않고, config rewrite, task mutation, model replacement, rule replacement, apply도 수행하지 않습니다.
cbr policy-proposals validate-approval APPROVAL_JSON --preview PREVIEW_JSON은 사람이 편집한 approval JSON을 source preview JSON과 대조합니다. Validator는 approval/preview schema, source_preview_sha256, 각 approval의 source_item_sha256, approved item의 reviewer, ISO datetime reviewed_at, decision_note를 검사하고 policy_proposal_approval_validation report를 출력합니다. Validation decision_cards는 승인된 항목을 user_decision_status=approved, 승인되지 않은 항목을 not_approved, 검증 오류 항목을 invalid로 표시합니다. 이 command는 approval/config/task를 변경하지 않고 apply도 수행하지 않습니다.
cbr policy-proposals apply APPROVAL_JSON --preview PREVIEW_JSON --config-target CONFIG_JSON --dry-run|--apply [--approve] --json은 승인된 execution_target_freshness proposal을 명시적인 local/private config JSON에만 guarded apply합니다. --dry-run은 config를 바꾸지 않고 approval 재검증, config-target eligibility, freshness before/after snapshot, compact diff metadata를 출력합니다. JSON mutation.approve_flag는 approval file의 item-level approved가 아니라 CLI --approve guard flag 사용 여부를 뜻합니다. Human output은 source_preview_sha256, config target sha256_before/sha256_after, item별 reviewer/reviewed_at, nested approval validation errors도 표시해 apply summary와 audit payload를 대조할 수 있게 합니다. --apply는 --approve 없이는 실패하며, approval/preview hash, approved item metadata, proposal id/target/action/class, 현재 config freshness 상태를 다시 확인한 뒤 execution_targets.<alias>.freshness metadata만 갱신합니다. Repo public source/docs/examples/tests 경로, repo runtime state 경로, missing/unparseable/dirty config, unsupported proposal class/action/schema/target path, missing target은 거부됩니다. Apply 성공 시 sanitized policy_proposal_applied event payload에는 hashes, proposal id, target alias, changed freshness keys만 남기고 raw paths, logs, prompts, decision note body는 넣지 않습니다.
Runner lock recovery treats a lock as recoverable immediately when metadata contains a pid for the same hostname and that pid is no longer alive. Unknown host, missing/invalid pid, invalid metadata, and cross-host locks fall back to the age-based stale threshold.
Doctor는 기본적으로 Codex application bundle 안의 별도 executable과 configured CLI를 비교하지 않음. macOS나 특정 app install layout을 가정하지 않기 위함임. 운영자가 app-bundled CLI와 standalone CLI 차이를 확인해야 하는 환경에서는 별도 수동 조사로 처리함. Routine doctor는 대형 binary hash를 계산하지 않음. Hash는 향후 --verbose 또는 deep diagnostic check에서 명시적으로 요청할 때만 고려함.