fix(explore): name the propose workflow at every handoff - #1788
fix(explore): name the propose workflow at every handoff#1788clay-good wants to merge 3 commits into
Conversation
Explore mode refuses to implement, but nowhere named the workflow that turns the discussion into a change. The refusal, the "flow into a proposal" ending, the closing summary, and the do-not-implement guardrail all described the next step as prose. With no named exit, agents answered the discovery questions and then started writing code (#869). All four handoff points now point at `/opsx:propose`, written in the canonical `/opsx:<id>` form so each tool renders the invocation it actually registers. Skill and command bodies are patched together, the skills.sh mirror is regenerated, and parity hashes are refreshed. Closes #869 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Included review availability: Your plan provides up to 10 included reviews per hour; 4 remain after this review. 📝 WalkthroughWalkthroughExplore guidance now names the proposal workflow at implementation and discovery handoff points. Templates, generated skill content, tests, parity hashes, and the patch changeset were updated. ChangesExplore proposal handoff
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to The change updates Explore handoff guidance to direct users toward proposal creation before implementation. No concrete merge-blocking risk is currently identified. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 3 files. (1 skipped: 1 unsupported.)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
No PR-relevant drift confirmed.
|
The capture path let explore scaffold a change and write artifacts, then said nothing about what came next. An agent holding a fresh proposal inside explore mode has an obvious wrong next move, and it is the one #869 reported. The capture now ends by naming `/opsx:propose` for the remaining planning artifacts and `/opsx:apply` for implementation, and says plainly that capturing artifacts is not permission to implement them. Widen the rendering guard to walk the real registries instead of a hand-picked few: every registered command adapter and every entry in AI_TOOLS must rewrite every canonical reference in both bodies, with no `/opsx:` form surviving on any skills surface. A new adapter or a changed invocation shape now fails here rather than shipping a command nobody answers to. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Status
Ready for review. Two commits. Full suite: 4,429 passing; the only 2 failures (
artifact-workflowCursor-skills,config-profileinteractive apply) reproduce on unmodifiedmainwith this branch's files reverted.What was wrong
Explore mode refuses to implement. It never said what to do instead.
The docs already promise the handoff.
docs/explore.mdopens with "When the picture is clear, it hands off to/opsx:propose", diagramsexplore ──► propose ──► apply ──► archive, anddocs/commands.mdshows a worked example ending in "Run /opsx:propose add-jwt-auth to begin." The template implemented none of it. Every place the skill and command pointed past themselves was prose:Every other workflow template names its handoff —
propose→/opsx:apply,new→/opsx:continue,ff→/opsx:apply. Explore was the one workflow that said "stop" without saying "go here", so/opsx:explorehad no exit an agent could take. Two reporters in #869 hit the predictable result through GitHub Copilot: the agent ran discovery, answered the questions, then went straight to implementing, skipping change creation entirely.The capture path is the sharper half. Explore can scaffold a change and write artifacts in a confirmed scope, and then the guidance simply ended. An agent holding a fresh proposal, still inside explore mode, with nothing named next, has one obvious wrong move — the one the issue reported.
How it was fixed
Five handoff points now name the workflow:
/opsx:propose, which turns the discussion into a change. The work happens from that change, never from explore mode."/opsx:proposeand this becomes a change."/opsx:propose"/opsx:proposeturns the discussion into a change, and the work happens there."/opsx:proposewrites the remaining planning artifacts, and/opsx:applyimplements the change once tasks exist. Capturing artifacts is never permission to implement them."Both references are written in the canonical
/opsx:<id>form, so the existing per-tool transformers render the invocation each tool actually registers. No new mechanism:proposeandapplyare bothCORE_WORKFLOWSmembers, and this is the same cross-workflow reference patternonboard,propose,ff, andnewalready use (68 existing instances).Skill and command bodies are patched together (both carry the text), the
skills/mirror is regenerated withnpm run generate:skills, and parity hashes are refreshed withscripts/regen-parity-hashes.mjs.Proof it works
Eight new tests in
test/core/templates/explore.test.ts, each asserted against both delivery surfaces. All 8 fail on unmodifiedmain(8 failed | 25 passed) and pass here.Content assertions cover each of the five handoff points and assert the old prose is gone.
Rendering assertions walk the real registries rather than a hand-picked few, so a new adapter or a changed invocation shape cannot quietly leave explore advertising a command nobody answers to (the #727 / #1307 failure mode):
CommandAdapterRegistry.getAll()(30 of them) must rewrite every canonical reference to that adapter's own spelling — counted, not substring-matched, so a partial rewrite failsAI_TOOLSmust do the same on the skills surface, with no/opsx:form of any kind surviving.agentsrendering is asserted separatelyVerified against real installs, not just transformers.
openspec initin a scratch repo produces, in the explore skill and command:/opsx:propose/opsx-propose@prefix@opsx-propose(×4)/skill:/skill:openspec-propose(×5).agents$openspec-propose (Codex) or /openspec-propose (other agents)No residual
opsx:proposein any generated file.test/core/templates/andtest/core/command-generation/are green at 1,326/1,326; lint andtsc --noEmitclean.Notes
proposeandapplyare named, neverffornew. Both named workflows are inCORE_WORKFLOWS;ffandneware not installed on the core profile, so naming them would advertise workflows most projects do not have.openspec/specs/capability covering the explore skill (unlikeopsx-onboard-skill,opsx-verify-skill,opsx-archive-skill), so no spec delta accompanies this. Worth filing separately if explore's contract should be specified.optionalWorkflow(). It does not touchexplore.tstoday because explore had no cross-workflow references before this. Whichever of the two lands second should wrap these two new references so a custom profile that installsexplorewithoutproposeorapplydrops them.Closes #869
🤖 Generated with Claude Code
Summary by CodeRabbit