Repository navigation
refactor: define agent steps as yaml list - #974
Merged
Merged
Conversation
Refactor the automation prompt generator so each agent's numbered steps are authored as an ordered `steps:` list in agents.yaml, with step numbers assigned automatically by list position. This removes the manual `commit_step_number` / `pr_step_number` / hardcoded "STEP N" strings inside the review_steps blob that had to be renumbered by hand whenever a step was inserted or reordered. Step kinds: - install: toolchain install block (title from YAML, body from `toolchain`) - verify: CI-equivalent verify block; `verify_extras` adds extra bullets - commit: app-signed commit instructions (scaffolded) - pr: open-PR instructions (scaffolded) - note: verbatim preamble, no "STEP N — " prefix, no number consumed - (none): plain step; `body` is the full text rendered after "STEP N — " template.md.tmpl is now thin scaffolding around four pre-rendered, auto-numbered blocks (, , , ). The shared scaffold (frontmatter, intro, scope, open-PR guard, formatting gate, completion note, constraints, self-improvement) stays in the template. The generated agent.md files are byte-identical to the previous state (`go run ./hack/automations -check` is clean, 0 diff vs the prior generated output), so this is a pure generator refactor with no prompt changes and no cloud re-sync required. Verified: go test ./hack/automations ok, -check exit 0, golangci-lint 0 issues, -sync -dry-run reports 14/14 up to date. This PR was created by an AI agent as part of an automated templating refactor.
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 22 |
| Duplication | 0 |
AI Reviewer: run a review on demand. To trigger the first review automatically, go to your organization or repository integration settings. AI can make mistakes. Always validate suggestions.
TIP This summary will be updated as you push new changes.
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.
Refactor the automation prompt generator so each agent's numbered steps are
authored as an ordered
steps:list in agents.yaml, with step numbers assignedautomatically by list position. This removes the manual
commit_step_number/pr_step_number/ hardcoded "STEP N" strings inside the review_steps blob thathad to be renumbered by hand whenever a step was inserted or reordered.
Step kinds:
toolchain)verify_extrasadds extra bulletsbodyis the full text rendered after "STEP N — "template.md.tmpl is now thin scaffolding around four pre-rendered, auto-numbered
blocks ({{.InstallStep}}, {{.ReviewSteps}}, {{.CommitStep}}, {{.PRStep}}). The
shared scaffold (frontmatter, intro, scope, open-PR guard, formatting gate,
completion note, constraints, self-improvement) stays in the template.
The generated agent.md files are byte-identical to the previous state
(
go run ./hack/automations -checkis clean, 0 diff vs the prior generatedoutput), so this is a pure generator refactor with no prompt changes and no
cloud re-sync required.
Verified: go test ./hack/automations ok, -check exit 0, golangci-lint 0 issues,
-sync -dry-run reports 14/14 up to date.
This PR was created by an AI agent as part of an automated templating refactor.