fix(splitting): remove PR-creation references from prompt template#1383
Open
aaight wants to merge 1 commit into
Open
fix(splitting): remove PR-creation references from prompt template#1383aaight wants to merge 1 commit into
aaight wants to merge 1 commit into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
nhopeatall
approved these changes
May 19, 2026
Collaborator
nhopeatall
left a comment
There was a problem hiding this comment.
LGTM - the splitting prompt now grounds the summary step in CreateWorkItem story URLs without removing the intentional PR sizing heuristic. I verified the focused prompt regression test plus the existing capability/profile guards locally.
🕵️ codex · gpt-5.5 · run details
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes MNG-1084.
The splitting agent has PM-only capabilities (no
scm:pr) — it never openspull requests. But the prompt template's Step 6 told the agent to "post
summary comment ... once you've confirmed PR creation" and to use "real and
confirmed PR numbers and URLs - see output from CreatePR". That wording was
left over from a copy/paste with the implementation prompt and contradicted
the agent's actual capability contract, leading to confused output on
real splitting runs.
Changes
src/agents/prompts/templates/splitting.eta— replaced the twoaction-oriented PR-creation references in Step 6 with wording grounded in
the splitting workflow's actual side-effects (story work items returned by
CreateWorkItem). Story sizing language ("One PR, one day" heuristic andthe
- **S**mall - One PR, one day...INVEST bullet) is intentionallypreserved because it describes target story size, not an action the agent
should perform.
tests/unit/agents/prompts.test.ts— added two narrow regressiontests:
CreatePR,confirmed PR creation, orreal and confirmed PR numbers,and does still contain
CreateWorkItem,Stories Created,[Story Title](URL), andURLs returned by`CreateWorkItem`.so a future cleanup pass cannot strip it accidentally.
Out of scope
src/agents/definitions/splitting.yaml— capabilitiesalready correctly omit
scm:prand the existingagent-profiles.test.ts > splitting includes file editing but not CreatePRtest continues to pass.
src/gadgets/session/core/finish.tsor backend PR-validationcode — splitting remains a no-PR workflow by capability/agent contract.
README.mdanddocs/architecture/04-agent-system.mdalready correctly describe splitting as creating smaller work items with
fs, session, pmcapabilities.contain stale copy; operators with overrides will need to update those
separately.
Test plan
npx vitest run --project unit-core tests/unit/agents/prompts.test.ts— 129 pass (added 2)npx vitest run tests/unit/backends/agent-profiles.test.ts— 56 pass; the existingsplitting includes file editing but not CreatePRinvariant still passesnpx vitest run --project unit-core tests/unit/agents/capabilities/resolver.test.ts— 37 passnpx vitest run --project unit-core tests/unit/agents/— all 802 agent unit tests passnpm run typecheck— cleannpx biome checkon the two touched files — clean🕵️ claude-code · claude-opus-4-7 · run details