Skip to content

[issue-3364][slice-3/3] PR D — Slim the skill (GATED... - #3574

Merged
jwbron merged 15 commits into
egg/issue-3364/workfrom
egg/issue-3364/slice-3
Jul 10, 2026
Merged

jwbron merged 15 commits into
egg/issue-3364/workfrom
egg/issue-3364/slice-3

Conversation

@james-in-a-box

Copy link
Copy Markdown
Contributor

Deletion / medium risk with a HARD internal gate (TASK-3-1 gates TASK-3-2 and TASK-3-3). TASK-3-1 (GATE, first): produce the coverage-map — for EACH of the five host-detector blocks in skills/sdlc/SKILL.md name the concrete overseer emitter (deterministic _broadcast_alert structural check OR the classifier action:{action} path) and the OVERSEER_ALERT subject the skill already surfaces; any block with NO confirmed emitter is raised as a HITL at point of discovery, NOT a silent delete. TASK-3-2 (after gate): delete the host-detector blocks + migration section + Overseer-Absent Fallback + Stuck-Rescue host trigger + short-flow Stall block, PRESERVING the Long-Running Implement Phase and Unresolved NACK AskUserQuestion render-on-alert flows and the user-initiated Rescue Steps 1-3. TASK-3-3 (after gate): remove overseer_owns_host_detection ENTIRELY (field in orchestrator/models/_config.py + both refs in orchestrator/routes/pipelines/_routes_status.py; grep-clean). Independent of slices 1 and 2 (disjoint files: slice 1 edits routes/pipelines/ init.py, this edits _routes_status.py — same package, different regions, flagged for merge-seam awareness).

Base PR: #3524

What's in this PR

Commits (15):

.egg-state/brc-history/3364-implement-slice-3.json      | 2814 +++++++++++++++++++++++++++++++++++
 .egg-state/brc-history/3364-implement-slice-3.md        | 2541 +++++++++++++++++++++++++++++++
 .egg-state/contracts/issue-3364.json                    |  223 ++-
 docs/architecture/orchestrator.md                       |    2 +-
 docs/architecture/overseer.md                           |    3 +-
 docs/guides/pipeline-health-monitoring.md               |   12 +-
 orchestrator/models/_config.py                          |   11 -
 orchestrator/routes/pipelines/_routes_status.py         |    3 -
 orchestrator/tests/test_config_overseer_flag_removed.py |   68 +
 orchestrator/tests/test_routes_status.py                |  101 ++
 sandbox/agent-config/rules/overseer.md                  |    4 +-
 skills/sdlc/SKILL.md                                    |  148 +-
 12 files changed, 5754 insertions(+), 176 deletions(-)

This slice

PR D — Slim the skill (GATED): coverage-map, then delete host detectors, then remove overseer_owns_host_detection

Files affected:

  • skills/sdlc/SKILL.md
  • orchestrator/models/_config.py
  • orchestrator/routes/pipelines/_routes_status.py
  • orchestrator/tests/test_config_overseer_flag_removed.py
  • orchestrator/tests/test_routes_status.py
Tasks (5) + acceptance criteria
  • task-3-1: GATE (hard predecessor of TASK-3-2 and TASK-3-3): produce the coverage-map. For EACH of the five host-detector blocks in skills/sdlc/SKILL.md (Stall detection ~637, Silent agent detection ~644, NACK escalation ~679, Long-Running Phase Detection ~722, and the host-side detection TRIGGER of Stuck Pipeline Rescue ~750) name the concrete overseer emitter (a deterministic _broadcast_alert(...) structural check in orchestrator/overseer/monitor/ OR the classifier/ adjudicator action:{action} path) and the OVERSEER_ALERT subject the skill ALREADY surfaces. Record the map in the PR body. This is REAL verification: the host vocab (agent-stall / agent-silent / agent-nack-unresolved / phase-long-running) exists in production only as a last-alert dedup map (shared/egg_overseer/state.py) and is otherwise produced by the overseer Haiku classifier (LLM path), while the live monitor emits a DIFFERENT deterministic vocab (post_consensus_stall / incomplete_consensus_stall / rerun_anomaly / status_inconsistency / hitl_propagation_failure / cross_phase_inconsistency / orchestrator_unreachable). Any block that maps to NO confirmed emitter is raised as a HITL via mcp__sdlc__register_open_question at the point of discovery (carrying the specific block + evidence) — NOT a silent delete into a dark gap.
    • Acceptance criteria: - AC-D6: every one of the five blocks is mapped to a named overseer emitter + the OVERSEER_ALERT subject the skill surfaces, recorded in the PR; any unmapped block is escalated as a HITL rather than deleted. No block is deleted without a confirmed emitter.
  • task-3-2: GATED on TASK-3-1. Delete from skills/sdlc/SKILL.md (detection/trigger prose ONLY): the "Host detector migration (issue Improve overseer escalation/issue opening behavior #1962)" section (~553), the "Overseer-Absent Fallback" (~573), the five host-side detector blocks — Stall (~637), Silent agent (~644), NACK escalation (~679), Long-Running Phase Detection (~722), the host-side detection TRIGGER of Stuck Pipeline Rescue (~750; workflow Steps 1-3 STAY) — and the short-flow Stall detection block (~1517). Drop the orphaned overseer_owns_host_detection State-tracking conditionals (571/716/718). PRESERVE (AC-D3, key regression surface): the Long-Running Implement Phase and Unresolved NACK AskUserQuestion render-on-alert flows must still fire on their OVERSEER_ALERTs.
    • Acceptance criteria: - AC-D1: listed sections/blocks deleted; Stuck Pipeline Rescue workflow Steps 1-3 retained (only its host-side trigger removed). - AC-D3: Long-Running Implement Phase and Unresolved NACK AskUserQuestion render-on-alert flows preserved and still fire on their OVERSEER_ALERT.
  • task-3-3: GATED on TASK-3-1. Remove overseer_owns_host_detection ENTIRELY (conclude the calibration window; do NOT flip the default): delete the Field at orchestrator/models/_config.py:388 and both getattr references at orchestrator/routes/pipelines/_routes_status.py:126-127. grep -rn overseer_owns_host_detection must be clean repo-wide (code + SKILL.md prose). Note: PR B (slice 1) also edits the routes/pipelines package (init.py allowlist) — a different region from this _routes_status.py edit, but flag the shared package for merge-seam awareness.
    • Acceptance criteria: - AC-D2: field + both route references removed; grep for overseer_owns_host_detection is clean repo-wide.
  • task-3-4: Verify the KEPT skill surface is intact (argument parsing/seed, pre-refine triage, submit, the Monitor wait-status loop with render + cursor threading, HITL decision brokering — phase_gate/choice/feedback, two-wave surfacing, cq-N/feedback-N — surfacing OVERSEER_ALERTs, and the user-initiated Stuck Pipeline Rescue workflow Steps 1-3), and add a short last-resort debugging section carrying the two thin backstop rules: (1) never blind-action a destructive recommendation — always route a destructive rec through AskUserQuestion; (2) TaskStop the Monitor before re-arming it.
    • Acceptance criteria: - AC-D4: all listed kept sections remain and are coherent post-deletion. - AC-D5: a short last-resort debugging section carries both backstop rules (destructive-rec-through-AskUserQuestion; TaskStop-before- Monitor-re-arm).
  • task-3-5: Verification for PR D: grep-clean for overseer_owns_host_detection and run_migrated_detectors and the removed detector headings; update/remove any orchestrator tests that reference the removed config field; confirm SKILL.md still renders and the preserved AskUserQuestion flows are structurally intact. make lint + make test green.
    • Acceptance criteria: - AC-D2 (grep-clean) confirmed; no dangling references; suite green.

Stack

egg-orchestrator and others added 15 commits July 6, 2026 23:05
…detection (#3364)

Coverage-map GATE (task-3-1, cq-4): 4/5 host detector blocks map to a
confirmed overseer OVERSEER_ALERT emitter the skill already surfaces
generically (Stall/NACK -> incomplete_consensus_stall; Silent agent ->
action:{action} via heartbeat_timeout; Stuck-Rescue trigger ->
post_consensus_stall). The 5th, Long-Running Phase Detection, maps to NO
emitter (phase-duration affordance, not an anomaly) -> per operator cq-4
it is RETAINED host-side.

SKILL.md (task-3-2): delete Host-detector-migration(#1962) section,
Overseer-Absent Fallback, Stall/Silent-agent/Post-nudge/State-tracking
host-detection blocks + short-flow Stall block; rewire the Unresolved-NACK
render-on-alert flow onto incomplete_consensus_stall and the
Stuck-Pipeline-Rescue trigger onto post_consensus_stall (Steps 1-3 kept,
AC-D1/D3); keep Long-Running Phase Detection (cq-4). Add last-resort
debugging section with the two backstop rules (AC-D5).

overseer_owns_host_detection removed (task-3-3, AC-D2): Field in
models/_config.py + both getattr refs in _routes_status.py, plus stale
flag prose in the coder-owned sandbox/agent-config/rules/overseer.md.
git grep clean on code + SKILL.md + rules. The 3 docs/ files that also
mention the flag are documenter-owned (restricted path for coder) and are
handed off to the documenter for the same scrub.

Tests: ruff clean; 211 orchestrator config/status/models tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Verification tests for AC-D2, closing task-3-5:

- test_config_overseer_flag_removed.py: the calibration flag is gone
  from PipelineConfig (field absent, no attr on a default instance),
  a stale persisted key is dropped not resurrected (extra='ignore'),
  and the retained overseer threshold knobs survive.
- test_routes_status.py: the GET /status config subset no longer
  advertises overseer_owns_host_detection but still surfaces the
  retained threshold knobs (drives the real route body, nothing
  mocks the subset itself).

Also verified out-of-band (grep-clean): overseer_owns_host_detection /
run_migrated_detectors clean across code + SKILL.md (remaining refs are
documenter-owned docs/); removed detector headings gone from SKILL.md;
preserved AskUserQuestion / Stuck-Pipeline-Rescue / OVERSEER_ALERT flows
and cq-4-retained Long-Running Phase Detection intact.

make lint + targeted suites green (180 tests).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The slice-3 code change removes overseer_owns_host_detection and the
host-side detector blocks from SKILL.md, concluding the #1962 calibration
window. Update the docs that still described the flag / migration as live
so AC-D2's repo-wide grep-clean of overseer_owns_host_detection and
run_migrated_detectors holds and no stale documentation ships:

- docs/architecture/orchestrator.md: reframe the migration paragraph as
  concluded; drop the calibration-flag / run_migrated_detectors narrative.
- docs/architecture/overseer.md: drop the flag reference from the
  legacy-LLM-monitor note.
- docs/guides/pipeline-health-monitoring.md: delete the config-table row
  for the removed flag; replace the calibration-window flag-semantics and
  overseer-unresponsive fallback prose with a 'migration concluded' note.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant