feat(queen): draft a Boundary from the paths an issue already names - #4637
Merged
Merged
Conversation
The tick read 648 candidates today and chose none -- refusal="nothing to choose" -- with twelve lanes free. An issue without a `## Boundary` gives the Queen nothing to reserve, so no bee can own its files and it is skipped every round. `needs_boundary.py` labelled the set: 553 open issues, ~87% of the board. That is the ceiling on the swarm, and worker capacity does not move it. Of the 553, 238 already name a concrete path in their title or body and 103 name a `.t27`. For those the boundary is not missing information, only unwritten. This reads the paths and prints a draft, ranking a `.t27` first, a path in the title over one in the body, and a `docs/` path last and marked -- a document is quoted far more often than it is edited. It never edits an issue. A wrong boundary is worse than a missing one: it reserves files the work does not own and blocks whatever really owns them until the claim expires. `--as-comment` posts a comment, which the Queen does not read, so a draft cannot make an issue dispatchable by accident. Closes #4636 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Contributor
Contributor
|
📓 NotebookLM Notebook linked to this PR
This notebook contains session context, decisions, and artifacts for this work. |
Everything here is something the first live run broke on. **A full page of issues arrives truncated.** `json.load` straight off the socket died with `IncompleteRead` two thirds of the way through. GitHub sends these chunked and the bodies are long - a spec issue carries its whole brief. Four pages read in a row, measured: `per_page=100` gave 1 ok and 3 failures, `per_page=50` gave 3 and 1, `per_page=30` gave 4 and 0. Retrying did not help because the same page truncated again; fewer rows per response is the fix. The body is now read to bytes before parsing, so a short read is an error that can be asked again rather than a parse that dies half way. **Seven pages could not hold 553 issues** at any page size worth using. The loop now walks until the pages run out, with a cap that says so if it bites. **`--limit` cut the issue list before anything was drafted**, so `--limit 1` meant "look at one issue" and, on a board where most issues name nothing, printed nothing at all. On a tool whose output is drafts, a limit counts drafts. **A re-run posted a second comment everywhere it had already been.** That is not acceptable in a tool that writes to a hundred issues: one 502 makes a retry necessary, and a retry must be silent where it has already spoken. It now recognises its own preface and leaves those alone - and a failed post is collected and reported instead of ending the run, so the remaining issues still get their draft. **`--specs-only`** for the subset law L0 names, and the one where a draft is least likely to be wrong: a `.t27` path in an issue about a spec is the file it changes, not a file it mentions. Run over the board: 103 of the 553 labelled issues name a `.t27`, and all 103 now carry a draft. A fourth run posts nothing. Closes #4636 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Contributor
|
📓 NotebookLM Notebook linked to this PR
This notebook contains session context, decisions, and artifacts for this work. |
Contributor
PR DashboardGenerated at: 2026-09-23 13:58:33 UTC
Summary
Seal Status
|
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.
Closes #4636
The ceiling nobody was looking at
648 candidates, none chosen, twelve lanes free. An issue with no
## Boundarygives the Queen nothing to reserve, so no bee can own its files and it is skipped every round — forever.needs_boundary.pylabelled the set: 553 open issues, about 87% of the board. Worker capacity does not move that number; only boundaries do.What the 553 actually contain
.t27specdocs/citation238 (43%) already say which files they are about. For those the boundary is not missing information — it is unwritten information, and a tool can write the first draft.
How it ranks
.t27first: the specs are what this project is, and law L0 names themdocs/last, and marked: a document is quoted far more often than it is edited. Spec render-job-run and morph-images-generate: a delivery that fails must not report delivered #4122 and Spec payment-ai-server-process: claim-invoice compare-and-set and amount check #4115 both namedocs/audit/inngest-improvement-plan-2026-09-13.md— the thing they cite, not the thing they change. The draft says so inline:What it refuses to do, and why that is the point
It never edits an issue body. A wrong boundary is worse than a missing one: it reserves files the work does not own and blocks whatever really owns them until the claim expires. So it prints a proposal and stops.
--as-commentposts the draft as a comment — and the Queen reads the body, not comments. A draft therefore cannot make an issue dispatchable by accident; a person has to move it across, which is exactly the review step this needs.Checked
Five cases, including the one that matters for false positives: prose containing
a/band1/2yields no paths, because a slash is not a path. A live anonymous dry-run over the labelled issues produced thedocs/marker shown above on #4122 and #4115.🤖 Generated with Claude Code