feat: CEO Phase 1 — weekly board digest (convention opt-in via .agent/ceo.md) #246
No reviewers
Labels
No labels
Agent
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No assignees
2 participants
Notifications
Total time spent: 17 minutes 43 seconds
Due date
igor
17 minutes 43 seconds
No due date set.
Dependencies
No dependencies set
Reference
joshtronic/igor!246
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/ceo"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What this is
CEO Phase 1 — a weekly harness pass that, for each repo carrying a root
.agent/ceo.mdmandate, reads the mandate + gathers that repo's week and emails a strategic board digest assessing progress against the mandate's ranked priorities. Convention opt-in: the mandate's mere presence opts a repo in (like logwatch'ssystemd/and the review's merge), and the mandate itself is the model's system prompt. Read-only — it reports, it does not act. The agency (issue-filing, steering, mandate redlines) is the mandate's own roadmap for later phases ("start tight, loosen as trust earns it").Phased on this trunk
0805f3b) —lib/ceo.shread side:.agent/ceo.mdopt-in detection + the weekly activity gather (PRs merged / issues opened+closed / open Agent queue). Proven live against porksicle.c665806) — the pass:bin/lib/ceo-digest-directive.md(the CEO-persona prompt) +do_ceo_tick(model call → parse → email, per-repo.ceoweekly slot), cascade-wired after sports, below the health gate.e45d584) — CLAUDE.md docs.Live-validated — the actual digest it produced
Ran the full pipeline against
porksicle.com(gather → mandate →claude_call→ parse). Real output:It found the real miss on its own, flagged the right win, set a priority-derived theme, and made board-level asks — a CEO digest, not a changelog.
Notes
OUTCOMElabel (email-only, like sports) →check-syncgreen;bash -nclean.CEO_RECIPIENTS(optional, falls back toSEO_PRIMARY_EMAIL); needs SMTP2GO. No recipient or no.agent/ceo.mdrepo → clean no-op. The HTML email reuses the proven sports renderer.Phase 2+ (the CEO's actual authority) lands as deliberate, human-gated follow-ups.
🤖 Review —
REQUEST_CHANGES(automated)CI for
e45d5845: pendingSummary: Adds a weekly, convention-opt-in (
.agent/ceo.md) "CEO board digest" — a read-only model pass that gathers a repo's week and emails a strategic digest. Code is well-structured, scoped, and read-only with limited blast radius. But it ships ~200 lines of new parsing/rendering/state logic with zero tests, and CI is pending so I can't confirm the branch is green. Both block APPROVE.Blocking
lib/ceo.shintroduces several pure, directly-testable functions —ceo_parse_response(sentinel parsing + blank-collapsing awk),ceo_render_html(markdown→HTML),ceo_week_done/ceo_mark_week_done(state round-trip), and theceo_gather_weekjq filters — and the diff adds no test for any of them. The author states these "mirrorsports-digest.sh"; if that mirror has unit tests, this needs the parallel set, and if it doesn't, say so explicitly. "Live-validated against porksicle" is a one-shot manual run, not a regression guard. Add tests for at leastceo_parse_response(happy path, missing===BODY===, empty body, missingSUBJECT:) and the state functions.pending. I cannot confirmbash -n/check-syncare actually green — the description asserts it but the objective signal isn't there yet. Hold until CI reportssuccess; afailurehere would be a hard block.Correctness / robustness notes (worth fixing while reworking)
bin/tick.shdo_ceo_tickreads<<<"$ANALYSIS_REPOS_JSON"with a bare expansion (no${...:-}). If this harness runs underset -uand that global is ever unset when the cascade reaches the CEO tick, the whole tick aborts. Confirm it's guaranteed-set by this point (sports presumably relies on the same global), or guard it.lib/ceo.shmandate double-fetch:ceo_repo_has_mandatedoes a GET, thenceo_read_mandatedoes a second identical GET, then you check[ -n "$mandate" ]. The existence check is redundant — reading and testing non-empty already covers opt-in. Minor, but it's an extra API round-trip per repo per tick.ceo_mark_week_done: onjqfailure themktempfile is never cleaned up (&& mvshort-circuits, temp leaks). Low impact but trivially fixed with a trap orrm -ffallback.date +%G-W%Vwhile the gather window usesdate -u -d '7 days ago'. Around week/timezone boundaries these can disagree. Cosmetic for a digest, but flagging.Security
.agent/ceo.mdmandate is fetched from a repo and fed as the model's north-star prompt. A hostile/compromised repo could steer digest content. Phase 1 is read-only (email-only, no issue-filing/steering), so blast radius is bounded to email text — acceptable here, but this surface widens materially in the "later phases" the description previews, and should be re-reviewed then. Note for the human, not a block.reponame interpolated into_fjURLs.Scope / checklist
Scope is clean and matches the three-phase framing (lib read-side, the pass + directive, CLAUDE.md docs). The narrative "checklist" items I can verify against the diff (P1/P2/P3 contents, cascade placement after sports/below health gate) all check out. The live-digest output and
bash -n/check-syncgreen claims are unverifiable from here — the latter is exactly what pending CI needs to confirm.Bottom line: add tests for the new functions and let CI go green; the rest are minor cleanups.
Independent review by the harness on
claude-opus-4-8. The human reviewer is requested once Igor has reviewed; a human still merges.🤖 Review —
COMMENT(automated)CI for
639d2889: successSummary: Adds CEO Phase 1 — a weekly, read-only board digest for any repo carrying a root
.agent/ceo.md(lib/ceo.sh+do_ceo_tick+ directive + unit tests + docs). Well-structured, CI green, no workflow files touched, noOUTCOMElabel. The pure-function logic is genuinely tested. My reservation is that the integration path is unverifiable from the diff and untested, so I can't reach a confident APPROVE — handing to the human.Why not APPROVE (unverifiable integration points):
do_ceo_tickitself has no test coverage —test-ceo.shexercises only the pure helpers (ceo_parse_response,ceo_render_html, state round-trip,ceo_gather_weekwith a stubbed_fj). The orchestration —claude_call "$AGENT_MODEL" "ceo-digest" 8000 ...arg order,email_send "$subject" "$html" "$body" "$recipients"arg order, and the<<<"$ANALYSIS_REPOS_JSON"line-by-linejq -r '.full_name'(assumes JSON-lines, not a JSON array) — can't be confirmed from the diff. IfANALYSIS_REPOS_JSONis actually a JSON array, the per-linejqwould silently produce nothing and the tick would no-op. Please confirm these match the sports/logwatch precedents they claim to mirror.do_ceo_tickafterdo_sports_tick, but the health gate itself isn't in the diff. Trusting the claim; a human can eyeball placement.Concrete findings (worth fixing, none hard-blocking):
lib/ceo.shceo_gather_weekheader comment claims it gathers "commits to the default branch" — the implementation gathers no commits (only PRs, issues, Agent queue). Misleading comment; trim it.bin/tick.shline. "$AGENT_HOME/lib/ceo.sh"is missing the# shellcheck source=lib/ceo.shdirective that the adjacentespn.sh/sports-digest.shsources carry. Won't fail the check-sync CI step, butmake lint(shellcheck) will likely emit SC1091. Add for consistency.Minor / non-blocking:
ceo_render_htmlis a copy of the sports renderer rather than a shared function ("same renderer" per the comment) — link-substitution doesn't sanitizejavascript:hrefs, but the audience is the operator's own inbox and the inputs are operator-controlled repos, so low risk. Same posture as the existing sports digest.ceo_read_mandate→claude_call). That's prompt-injection-by-design, but Phase 1 is strictly read-only (email only), so blast radius is a weird email. Acceptable for this phase; flag if Phase 2 grants write authority.Honesty check: The phase breakdown (P1 read side, P2 pass+directive, P3 docs) all map to real hunks.
check-sync.shnow discovering/runningbin/test-*.shis a sensible, in-scope addition to make the new tests gate in CI. No fabricated claims spotted; the live-validation output is plausible but unverifiable on my end.Bottom line: No hard defect, CI green, scope is honest — but the untested
do_ceo_tickintegration and a couple of unverifiable call signatures keep me from APPROVE. A human should sanity-check theclaude_call/email_sendarg orders and theANALYSIS_REPOS_JSONformat against their existing tick conventions before merge.Independent review by the harness on
claude-opus-4-8. The human reviewer is requested once Igor has reviewed; a human still merges.