Skip to content

feat(plan): run the plan-review gate on every plan-mode entry path - #61

Merged
mbuckaway merged 2 commits into
fork/mainfrom
feat/plan-gate-reminders
Aug 15, 2026
Merged

feat(plan): run the plan-review gate on every plan-mode entry path#61
mbuckaway merged 2 commits into
fork/mainfrom
feat/plan-gate-reminders

Conversation

@mbuckaway

Copy link
Copy Markdown
Owner

Related Issue

No upstream issue — fork-only prompt change (tracked in fork/PATCHES.md).

Problem

The plan-review gate shipped in 0.36.0-MB.1.20 lives only in the EnterPlanMode tool-result message. Sessions entered via /plan, Shift-Tab, the --plan flag, default_plan_mode, or a resume never receive that message, so the gate never fires for them — plans produced on those entry paths go un-reviewed.

What changed

Prompt text in both engines (agent-core v1 and agent-core-v2); no tool-code change, no system-prompt change, EnterPlanMode message unchanged:

  • The plan-review gate is added to every plan-mode reminder variant (full / sparse / reentry + inline twins), using the exact wording already shipped in the EnterPlanMode message: before ExitPlanMode, check the plan-review skill is in the skill listing, run it once when available and the plan file lacks a ## Review Findings section, resolve every finding, and let the skill's close-out call ExitPlanMode (never call it twice).
  • Full and inline-full reminders gain the gate as a workflow step before Exit (renumbered); sparse/inline-sparse append the gate sentence; reentry/inline-reentry gain a gate step.
  • Tests updated for the new reminder text; token-count inline snapshots regenerated.

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked a related issue, or explained the problem above.
  • I have added tests that prove my feature works.
  • Ran gen-changesets skill, or this PR needs no changeset. (changeset added: .changeset/plan-gate-reminders.md)
  • Ran gen-docs skill, or this PR needs no doc update. (prompt behavior only; docs describe the tool, not the reminders)

The plan-review gate previously lived only in the EnterPlanMode tool-result message, so sessions entered via /plan, Shift-Tab, the --plan flag, default_plan_mode, or a resume never received it. The plan-mode reminders (full/sparse/reentry + inline twins, both engines) now carry the gate with the same wording as the EnterPlanMode message: before ExitPlanMode, run the plan-review skill once when it is available and the plan file lacks a `## Review Findings` section, resolve its findings, and let the skill's close-out call ExitPlanMode (never call it twice).

No tool-code or system-prompt changes; EnterPlanMode message unchanged. Tests updated for the new reminder text; token-count inline snapshots regenerated.
…terals

The gate step text used \' inside template literals, where apostrophes need no escape; ESLint no-useless-escape flagged three. Plain apostrophes now.
@mbuckaway
mbuckaway merged commit 35437a5 into fork/main Aug 15, 2026
11 checks passed
@mbuckaway
mbuckaway deleted the feat/plan-gate-reminders branch August 15, 2026 23:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant