plan(006): define minimal agentic control architecture - #68
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 10 included reviews per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe PR adds a complete implementation plan for a single-process, local-first Agentic control plane. It defines runtime integrations, identity and persistence models, delegation controls, Git review handling, testing requirements, and implementation gates. ChangesAgentic Control Plane Plan
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to This PR adds a plan only and does not change runtime behavior, dependencies, data, or deployment configuration; no actionable merge-blocking risk remains beyond normal checks and review. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
TheHalfMoon
left a comment
There was a problem hiding this comment.
AUTHOR PLAN / ARCHITECTURE / CORRECTNESS / SAFETY / PONYTAIL REVIEW
Exact candidate: c8392aa6862b5674b1e691c2f7f6fdb7efd05eb6
Exact base: c321d510463b207cd515ed391a47d4fb454fbe07
VERDICT: AUTHOR_PLAN_REVIEW_PASS / PONYTAIL_PLAN_PASS_WITH_EXPLICIT_YAGNI_DECISIONS.
No material author finding.
Architecture checks:
- the Plan reuses the existing one-package/one-process architecture, existing
workspaces, SQLite/WAL Store, system Git,executions, candidate verification tables, process ownership semantics, and simple CLI dispatch rather than creating a second control plane; - canonical workstream/task, Winds session, and runtime-native session are separate identities; runtime/model identity is also kept separate;
- canonical context is a deterministic projection of bounded typed facts/references, not a transcript database/vector store/memory service;
- canonical Winds sessions are not incorrectly modelled as
executions; actual runtime activity may later use the existing execution ledger plus typed child records; - candidate verification remains in the existing
candidate_runs/evidence model and cannot be promoted by agent status; - the authority evaluator is planned as a pure deterministic decision function before live execution; protected policy remains outside ordinary governed worktree content;
- policy intent and actual enforcement remain separate, with
WINDS_ENFORCEDforbidden where a runtime can bypass Winds mediation; - process/native IDs are never sufficient live ownership after Winds restart; existing ownership-loss discipline is preserved.
Live-control evidence checks against current official sources:
- Codex first concrete control path is the official App Server JSONL/stdio surface with initialize, durable thread create/resume/fork, structured turn/item events, and server approval requests. The Plan deliberately calls it vendor-specific JSON-RPC-like/JSONL and does not introduce a generic JSON-RPC framework;
- Claude Code first path uses the official local structured CLI (
--print, JSON/stream-json, exact--resume <session-id>). Recency-based--continueis explicitly rejected as Winds canonical identity, and--dangerously-skip-permissionsis prohibited; - Claude is intentionally Planner/read-plan oriented in the first live skeleton if stronger non-interactive mediation cannot be proven without excluded surfaces. The Plan does not force feature parity between heterogeneous runtimes;
- ACP v1/schema-v1.20.0/SDK 2.0.0 remains the canonical pin, but the Plan defers the crate until an actual selected runtime requires ACP. This removes an otherwise unused dependency;
- MCP, hosted Managed Agents, remote execution, network listeners, daemon/IPC, recursive fleets, plugin marketplaces, custom renderers, SQL Studio, and LLM Observatory remain outside the first program.
Ponytail challenge of the 841-line document:
- length is mostly acceptance/security reasoning and ordered implementation constraints, not 841 lines of invented component surface;
- proposed module/table names are explicitly conceptual and tasks may create them only when a proven slice requires them;
- the Plan avoids a generic
AgentRuntimetrait and instead requires closed Codex/Claude enum/match dispatch unless a third real runtime proves a shared seam; - identity/context/authority phases add no new dependency and require fixture-only proof before real agent execution;
- ACP, async runtime, HTTP client, JSON-RPC library, policy engine, vector DB, embedding/tokenization, fuzzy matcher, process supervisor, and second event/persistence systems are explicitly rejected unless later evidence requires them;
- P2 findability is deferred until the P1 loop is proven;
- no live-agent 100-cycle soak is invented; deterministic fixture/protocol repetition precedes any bounded live repetition.
One important planning conclusion: the first live differentiated path may legitimately be asymmetric — Claude Planner with weaker/agent-native read-plan enforcement and Codex App Server Worker with structured approvals — because the Plan requires truthful enforcement labels rather than pretending both runtimes expose identical controls.
This is author-side evidence and MUST NOT count as the independent reviewer pass.
|
@coderabbitai review Please review exact current head |
PR Summary by QodoSpec 006 Plan: Minimal agentic terminal/local delegation control architecture
AI Description
Diagram
High-Level Assessment
Files changed (1)
|
🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
base="c321d510463b207cd515ed391a47d4fb454fbe07"
head="c8392aa6862b5674b1e691c2f7f6fdb7efd05eb6"
echo "== Verify commits and ancestry =="
git show -s --format='%H%n%P%n%s' "$base"
git show -s --format='%H%n%P%n%s' "$head"
git merge-base --is-ancestor "$base" "$head" && echo "base-is-ancestor=yes"
echo "== Changed paths and diff stat =="
git diff --stat "$base" "$head"
git diff --name-status "$base" "$head"
echo "== Locate Spec 006 files =="
fd -t f . specs | rg '006-agentic-terminal-local-delegation-control-plane|(^|/)spec\.md$|(^|/)plan\.md$' || true
echo "== Outline candidate Markdown files =="
ast-grep outline specs/006-agentic-terminal-local-delegation-control-plane --items all 2>/dev/null || true
echo "== New plan with line numbers =="
git show "$head:specs/006-agentic-terminal-local-delegation-control-plane/plan.md" | nl -ba
echo "== Other files in Spec 006 at base and head =="
git ls-tree -r --name-only "$base" specs/006-agentic-terminal-local-delegation-control-plane 2>/dev/null || true
git ls-tree -r --name-only "$head" specs/006-agentic-terminal-local-delegation-control-plane 2>/dev/null || trueLength of output: 2650 🏁 Script executed: #!/bin/bash
set -euo pipefail
plan="specs/006-agentic-terminal-local-delegation-control-plane/plan.md"
spec="specs/006-agentic-terminal-local-delegation-control-plane/spec.md"
print_numbered() {
local file="$1"
local start="$2"
local end="$3"
echo "== ${file}: lines ${start}-${end} =="
sed -n "${start},${end}p" "$file" | awk -v n="$start" '{ printf "%5d\t%s\n", n++, $0 }'
}
echo "== Plan headings =="
awk '/^#{1,6} / { printf "%5d\t%s\n", NR, $0 }' "$plan"
echo "== Specification headings =="
awk '/^#{1,6} / { printf "%5d\t%s\n", NR, $0 }' "$spec"
echo "== Plan key-term occurrences with context =="
rg -n -i -C 2 \
'Codex|Claude|ACP|MCP|App Server|JSONL|JSON-RPC|--continue|--resume|dangerously-skip-permissions|authority|delegat|enforc|sandbox|worktree|Store|SQLite|table|module|schema|migration|runtime|session|context capsule|execution|verification|candidate|human' \
"$plan"
print_numbered "$plan" 1 220
print_numbered "$plan" 221 440
print_numbered "$plan" 441 660
print_numbered "$plan" 661 900
echo "== Complete canonical specification =="
awk '{ printf "%5d\t%s\n", NR, $0 }' "$spec"Length of output: 144329 🤖 web_search executed:
Length of output: 20298 🤖 web_search executed:
Length of output: 20639 🏁 Script executed: #!/bin/bash
set -euo pipefail
base="c321d510463b207cd515ed391a47d4fb454fbe07"
echo "== Baseline top-level Rust file map =="
git ls-tree -r --name-only "$base" | rg '(^|/)(main|store|domain|execution|cli_workspace|git)\.rs$|^src/git/' || true
echo "== Baseline persistence and ownership symbols =="
git grep -n -E \
'CREATE TABLE (workspaces|executions|execution_events|candidate_runs|evidence_reports|promotions|events)|OwnershipLost|enum ExecutionStatus|enum ExecutionKind|struct Store' \
"$base" -- 'src/**/*.rs' ':!target' || true
echo "== Baseline verification CLI and worktree symbols =="
git grep -n -E \
'winds verify|verify|worktree|candidate_runs|evidence_reports|promotions' \
"$base" -- 'src/**/*.rs' ':!target' | head -n 240 || true
echo "== ACP audit file referenced by the spec =="
git ls-tree -r --name-only "$base" | rg 'agent-client-protocol-v1-sdk-2\.0\.0-entry-audit\.md$' || true
git show "$base:docs/provenance/agent-client-protocol-v1-sdk-2.0.0-entry-audit.md" 2>/dev/null | sed -n '1,260p' || trueLength of output: 8201
I found no other material issue in the requested areas.
|
Code Review by Qodo
1.
|
TheHalfMoon
left a comment
There was a problem hiding this comment.
AUTHOR PLAN RE-REVIEW — EXACT REPAIRED HEAD
Exact candidate: 2925f772096b649ba154c35ab9d8a8536c232256
Exact base: c321d510463b207cd515ed391a47d4fb454fbe07
VERDICT: AUTHOR_PLAN_REVIEW_PASS / PONYTAIL_PLAN_PASS_AFTER_REPAIR.
The prior c8392aa... evidence is historical only and is not counted for this head.
Verified on the repaired candidate:
- diff remains exactly one Plan file; no Tasks, source, tests, dependency/lockfile, migration, workflow semantics, runtime execution, model/provider call, MCP, daemon/IPC, or remote control is introduced;
- CodeRabbit's material Codex handshake finding is repaired explicitly in both protocol facts and the future lifecycle:
initializerequest -> successful response ->initializednotification -> only then thread/other methods; - the Plan was compressed from 841 to 691 lines while preserving the same accepted architecture/security boundaries; no extra correction artifact or abstraction was added;
- one package/process and reuse of existing Store/system-Git/execution/candidate-verification/process-ownership semantics remain the architectural baseline;
- workstream/task, Winds session, runtime-native session, runtime, and model identities remain distinct;
- context remains a deterministic bounded projection rather than a transcript/vector-memory store;
- authority evaluation remains pure and separate from actual enforcement;
WINDS_ENFORCEDremains forbidden where the runtime can bypass Winds mediation; - Codex uses the official App Server structured local path; Claude uses its official structured CLI with exact resume only, no recency-based canonical continuation, and no dangerous permission bypass;
- ACP remains pinned but its crate remains deferred until a concrete ACP-speaking path requires it and passes a fresh dependency audit;
- MCP, daemon/IPC, remote execution, generic runtime/plugin framework, recursive fleet, custom renderer, SQL Studio, LLM Observatory, automatic winner, and silent landing remain excluded;
- fixture-only identity/discovery/context/authority phases remain before any real Agent process or prompt;
- the Plan-to-Tasks gate still requires Tasks to name the exact first real Codex/prompt task and exact first real Claude/prompt task.
Ponytail result: replacing the 841-line version with the tighter 691-line version is preferable to appending a corrective addendum. No further module/table/dependency can be removed from the planning contract without dropping a canonical Spec 006 requirement or an explicit security/continuity gate.
This is author-side evidence and MUST NOT count as the independent reviewer pass.
TheHalfMoon
left a comment
There was a problem hiding this comment.
AUTHOR PLAN FINAL RE-REVIEW — EXACT FINAL CANDIDATE
Exact candidate: a337e93000f3c38a875d81dd5943620e59806d69
Exact base: c321d510463b207cd515ed391a47d4fb454fbe07
VERDICT: AUTHOR_PLAN_REVIEW_PASS / PONYTAIL_PLAN_PASS_AFTER_FINAL_REPAIR.
All earlier author evidence is historical only for prior heads.
Verified on this exact final candidate:
- diff remains exactly one Plan file; no Tasks, source/runtime code, tests, dependency/lockfile, migration, workflow-semantic change, agent execution, prompt/model/provider call, ACP dependency, MCP, daemon/IPC, or remote execution is introduced;
- CodeRabbit's Codex App Server handshake finding is repaired explicitly:
initializerequest -> successful response ->initializednotification -> only then thread/other methods; - Qodo's cross-workspace consistency finding is repaired by structural simplification:
winds_sessionsno longer duplicatesworkspace_id; workspace ownership is derived throughwinds_sessions.workstream_id -> workstreams.workspace_id, eliminating the inconsistent pair rather than adding a redundant composite relationship; - Qodo independently resolved its own material thread after the repair;
- the Plan is reduced to 568 lines relative to canonical base while retaining all load-bearing Spec 006 acceptance/security boundaries;
- one Rust package/process and reuse of existing Store/SQLite WAL, system Git, execution ledger, candidate verification, ownership-loss semantics, and CLI remain the baseline;
- workstream/task, Winds session, runtime-native session, runtime, and model identities remain distinct;
- context remains a deterministic bounded projection, not a transcript/vector-memory system;
- authority evaluation remains pure and separate from actual enforcement;
WINDS_ENFORCEDis forbidden where the runtime can bypass Winds mediation; - Codex uses the current official App Server local structured path; Claude uses the official structured CLI with exact resume only, no recency-based canonical continuation, and no dangerous permission bypass;
- ACP remains pinned but the crate remains deferred until a concrete selected runtime actually requires it and passes a fresh dependency audit;
- fixture-only identity/discovery/context/authority work remains ordered before any real Agent process or prompt;
- MCP, daemon/IPC, remote execution, plugin framework, recursive fleets, custom renderer, SQL Studio, LLM Observatory, automatic winner, and silent landing remain excluded.
Ponytail result: no remaining proposed table/module/dependency should be removed from the Plan without dropping a canonical Spec 006 requirement or explicit safety/continuity gate. The cross-workspace repair reduces duplicated state rather than adding machinery.
This is author-side evidence and MUST NOT count as the independent reviewer pass.
Status
READY TO MERGE / PLAN-ONLY — TASKS AND IMPLEMENTATION REMAIN BLOCKED
This PR adds the formal Spec 006 implementation Plan after canonical specification PR #67.
Canonical base:
c321d510463b207cd515ed391a47d4fb454fbe07Final exact candidate:
a337e93000f3c38a875d81dd5943620e59806d69Final candidate tree:
d30b617e7cf038c91d5cdbff03f73142ebe07609Exact scope
One new file only:
specs/006-agentic-terminal-local-delegation-control-plane/plan.mdRelative to canonical base:
+568/-0, ahead 3, behind 0.No
tasks.md, source/runtime code, tests,Cargo.toml,Cargo.lock, migration, workflow-semantic change, agent execution, prompt/model/provider call, ACP dependency, MCP, daemon/IPC, or remote execution is present.Accepted architecture
winds_sessionsreferencesworkstreamsand does not duplicateworkspace_id; workspace ownership is derived throughworkstream_id -> workstreams.workspace_id, eliminating cross-workspace session/workstream mismatch by construction;WINDS_ENFORCEDis forbidden where a runtime can bypass Winds mediation;Runtime decisions
Codex
Use the official local App Server path only when a later exact Task authorizes live execution. Required handshake is explicit:
initialize request -> successful initialize response -> initialized notification -> only then thread/other methodsUse bounded vendor-specific JSONL/stdio messages with existing
serde/serde_jsonunless implementation evidence proves otherwise. Do not scrape the TUI.Claude Code
Use the official local structured CLI path first. Exact native resume may use
--resume <session-id>only when the binding is proven. Recency-based--continueis never canonical Winds continuity.--dangerously-skip-permissionsis prohibited. First live Claude role remains Planner/read-plan oriented unless a later exact Task proves stronger safe mediation.ACP
The canonical ACP v1/schema-v1.20.0/Rust SDK 2.0.0 pin remains valid, but no ACP crate is landed by this Plan. A future accepted Task may add it only if a selected runtime path actually requires ACP and after a fresh exact dependency/license/MSRV/platform audit. MCP remains out.
Exact-head acceptance evidence
For exact final candidate
a337e93000f3c38a875d81dd5943620e59806d69:quality #636/ run32424475529= SUCCESSAUTHOR_PLAN_REVIEW_PASSPONYTAIL_PLAN_PASS_AFTER_FINAL_REPAIR2925f772...and reported no actionable comments after the Codex handshake repairHistorical prior-head reviews are not counted as exact-final author evidence except as part of the explicitly described independent review stack. The Qodo resolution reaches the final exact head.
Explicit non-authorization
Accepting this Plan authorizes only creation/review of a separate
tasks.md. It does not authorize implementation, migrations, dependencies, agent launch, prompts, model/provider calls, ACP transport, MCP, daemon/IPC, remote execution, or automatic landing.Merge guard
Merge only if:
main == c321d510463b207cd515ed391a47d4fb454fbe07;a337e93000f3c38a875d81dd5943620e59806d69;plan.md;quality #636remains SUCCESS on that head;Use expected-head guard
a337e93000f3c38a875d81dd5943620e59806d69.