Skip to content

Correct the self-healing Router classification and its dead-zone reporting - #3441

Merged
pwizla merged 4 commits into
mainfrom
repo/self-healing-dead-zone-reporting
Sep 3, 2026
Merged

Correct the self-healing Router classification and its dead-zone reporting#3441
pwizla merged 4 commits into
mainfrom
repo/self-healing-dead-zone-reporting

Conversation

@pwizla

@pwizla pwizla commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator

This PR makes the docs self-healing workflow apply the micro/full rule itself instead of trusting what the Router claims, and splits the dead-zone reporting into the three situations it was conflating.

Whether a target is micro or full is mechanical: micro means every action is add_link, add_mention or add_tip. Haiku has got it wrong twice, in opposite directions. On 2026-06-20 (run 27857268241) it stamped micro on update_section targets then did nothing, so FULL=0 gated Sonnet out and both PRs were lost without a trace. On 2026-09-03 (run 33705096766) it stamped micro on add_section and update_section targets and drafted the sections itself, which its micro-edit procedure does not cover, and Sonnet was again never invoked.

  • a misclassified target with no doc PR is rewritten to full, so Sonnet picks it up
  • one that already has a doc PR is left alone, because rerouting would duplicate it, and is flagged as drafted beyond the micro scope
  • the Slack post and the run summary distinguish dropped, rerouted and overreach, so a run can no longer announce 2 doc PR(s) created and claimed but not delivered about the same two PRs
  • the payload handed to Sonnet is filtered to full targets without a doc PR, which the step comment already claimed while the code passed the whole file
  • the Router prompt resets to origin/main before creating each branch rather than after the PR, which is what made Document private field searchability default behavior #3440 carry Document Media Library right-click context menu #3439's commit, and it states that a micro-edit is a link, a mention or a tip

Replayed the new jq against the router results of run 33705096766: the real run reports 2 PRs created and 2 flagged for review with an empty Sonnet payload, the 2026-06-20 case reroutes both targets to Sonnet, and a genuine micro target with no PR is still reported as dropped. All 13 run blocks pass bash -n at each of the 4 commits.

One call for you: this touches .github/workflows/, so the workflow diff deserves a careful read rather than a skim.

pwizla and others added 4 commits September 3, 2026 11:38
Whether a doc target is `micro` or `full` is a mechanical rule: micro means
every target action is add_link, add_mention or add_tip. Haiku has now got it
wrong twice, in opposite directions, and both times the run ended green.

On 2026-06-20 (run 27857268241) it stamped `micro` on update_section targets
and then did nothing, so FULL=0 gated Sonnet out and both PRs were lost. On
2026-09-03 (run 33705096766) it stamped `micro` on add_section and
update_section targets and drafted whole sections itself, prose its micro-edit
procedure does not even cover, and Sonnet was again never invoked.

Apply the rule in the workflow rather than asking the model to honour it. A
misclassified target with no doc PR is rewritten to `full` so Sonnet picks it
up; one that already has a doc PR is left alone, since rerouting would
duplicate the PR, and flagged as drafted beyond the micro scope.

Report the three outcomes separately. Sharing one message is what made the
2026-09-03 Slack post announce "2 doc PR(s) created" and "claimed but not
delivered" about the very same two PRs.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The step comment claimed it passed "only full-complexity PRs" to Sonnet while
handing over the whole router results file, and the Drafter prompt filters on
`decision` alone. A run with both micro and full targets would therefore have
had Sonnet redraft the micro PRs Haiku had just opened.

Filter here rather than trusting the prompt, and exclude anything that already
carries a doc PR URL.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Resetting to origin/main at the end of each micro-edit iteration was not
enough. On 2026-09-03 the Router opened PR #3439, then ran `git checkout -b`
for the next PR while still on that branch, so PR #3440 carried #3439's commit
as well and touched a file unrelated to its own source PR.

Reset before creating the branch, so each branch is independent of whatever the
previous iteration left behind.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The complexity rule was stated once, as a definition, and Haiku twice decided
against it after reasoning correctly about the same targets in prose. Say
plainly that the classification comes from the action values alone, that one
add_section among ten add_link targets still makes the PR full, and that the
workflow now overwrites a wrong answer.

Add the matching hard stop to the rules list: a micro-edit is a link, a mention
or a tip, and anything needing a section stops at the routing decision.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@pwizla pwizla added pr: fix Used on the docs repo for anything that is not "new" or "updated" content: chore, typos, fixes, etc. source: repo PRs/issues not targeting a specific documentation but rather affecting the whole repo internal PRs created by the Strapi core team labels Sep 3, 2026
@pwizla pwizla self-assigned this Sep 3, 2026
@vercel

vercel Bot commented Sep 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
documentation Ready Ready Preview Sep 3, 2026 12:55pm UTC

Request Review

@pwizla pwizla added pr: chore and removed pr: fix Used on the docs repo for anything that is not "new" or "updated" content: chore, typos, fixes, etc. labels Sep 3, 2026
@pwizla

pwizla commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator Author

LGTM, let's try it with the next self-healing round tomorrow 👀

@pwizla
pwizla merged commit 7b5ced8 into main Sep 3, 2026
15 of 18 checks passed
@pwizla
pwizla deleted the repo/self-healing-dead-zone-reporting branch September 3, 2026 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal PRs created by the Strapi core team pr: chore source: repo PRs/issues not targeting a specific documentation but rather affecting the whole repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant