Skip to content

docs/skills: split PR publication out and tighten the skill contracts - #69

Merged
greatbridf merged 3 commits into
masterfrom
skills
Nov 5, 2026
Merged

greatbridf merged 3 commits into
masterfrom
skills

Conversation

@greatbridf

@greatbridf greatbridf commented Nov 4, 2026 •

Copy link
Copy Markdown
Owner

Summary

Split PR publication out of fix-and-pr into a standalone create-pr skill,
made subagent delegation mandatory in both skills with preflight reserved to
the supervisor, corrected the Assisted-by: LLM disclosure rule to a
per-commit test, and trimmed the fix-and-pr reference library from twelve
numbered documents to seven, folding the removed content into the survivors.
The body contract no longer requires a Fixes #N or Refs #N line. Docs only:
19 markdown files changed under .agents/skills/, +755/-1374, no code.

Why

fix-and-pr required the whole intake, reproduction, fix, and verification
pipeline even when the only remaining work was pushing a verified branch and
opening a pull request, and it kept publication inside a single 191-line
reference document. The two halves also fail differently: a mis-scoped analysis
wastes effort, while a mis-scoped push publishes a mistake.

Delegation was advisory in practice. A step could be performed inline when that
looked cheaper, reviewer passes could be skipped, and a phase could clear its
gate on the supervisor reading the code. A self-certified gate is not evidence.

The trailer rule read as blanket repository policy and said nothing about what
a maintainer-only commit needs: Assisted-by: LLM was "mandatory in this
repository: all commits produced with agent assistance must disclose it". The
trailer marks a commit written with agent help, so a commit from the maintainer
alone carries nothing and must not be tagged retroactively.

What changed

  • New create-pr skill. Owns preflight, title and body, credential-safe
    push, gh pr create, and a read-back check. It refuses to edit code or
    force-push, merges only when asked, and sends an unverified or half-finished
    change back to authoring. A credential gate runs before anything else; the
    push goes over SSH, or through an askpass helper when HTTPS is unavoidable,
    so the token never reaches a URL, a file, a log, or a prompt. Title and body
    are written before the API call, and the created PR is read back and diffed
    against the local branch.
  • fix-and-pr reduced to intake through commit. Phase 5 is now the handoff
    to create-pr, a rule forbids pushing from the skill, and the document heading
    reads "Fix and Commit" while the directory keeps its name.
  • Mandatory delegation, with preflight reserved. The delegated set is named
    per skill instead of being summarised as "every phase": create-pr delegates
    phases 1-3, and fix-and-pr delegates the rest of intake and phases 1-4.
    Preflight is the supervisor's own work in both, with no subagent and no
    report file, because it is the decision to spend subagents or publish at all;
    fix-and-pr's phase 5 handoff is the supervisor's as well. Every other gate
    passes on the report its named subagent returns for the part it runs: no
    report, no gate. fix-and-pr's preflight fence also loses a build command,
    which belongs to scout and not to a supervisor forbidden to build. Where a
    step previously allowed an inline run or an optional reviewer, the text now
    requires the subagent and stops the workflow when none can be launched. Body
    drafting and review are delegated too, so the authoring skill no longer runs
    the push.
  • Issue links are conditional. Fixes #N and Refs #N were mandatory, so
    a change with no matching issue could not satisfy the body check this PR
    installs. The body worker now searches for an existing issue, cites it as
    Fixes or Refs when one genuinely matches, never invents a number, and
    records the search result; no match means no link line anywhere in the body.
    The local and read-back checks report the missing link and exit 0 instead of
    failing the PR.
  • Per-commit disclosure. Assisted-by: LLM goes on agent-written commits,
    immediately before Signed-off-by; maintainer-written commits stay untouched.
    Preflight and create-pr's stop conditions apply the same per-commit test.
    The PR body footer stays, because it discloses who drafted the description
    rather than who wrote the commits.
  • Consolidated references. Deleted 07-pr-submission, 08-failure-handling,
    09-analysis-template, 10-command-reference, and 11-prompt-hygiene. Roles,
    brief format, artifact layout, and stop conditions fold into
    00-operating-contract; the analysis template folds into 03-analysis; each
    command moves into the phase that uses it; credential rules fold into the
    publish document.

Verification

Docs-only diff: no build and no QEMU run were performed, because no code changed
and nothing in the diff is executable.

Checks recorded in the doc-integrity log at 7657fe85dd8f:

  • Dangling relative markdown links: none found.
  • Stale references to the deleted reference documents: none found.
  • Unconditional delegation claims: none found.
  • Mandatory issue-link claims: none found.
  • Build command on the supervisor inside a preflight fence: none found.
  • Unpaired markdown code fences: none found.
  • Every references/*.md named in a SKILL.md exists.
  • An issue-less body does not fail its own link check: the check reports
    no issue link.
  • git diff --check: clean, no whitespace errors reported.

Risks / notes

  • No functional risk: no code, build files, or configuration changed. The
    exposure is documentation drift, since the two skills share gate, report, and
    trailer vocabulary and must be edited together.
  • Publication now depends on the credential gate, so a run without a token stops
    instead of degrading into a push with inline credentials.
  • Notes outside this repository that reference the old 07–11 document numbers
    would no longer resolve; the integrity check found no such references inside
    the repo.

Assisted-by: LLM

`fix-and-pr` required the whole intake, reproduction, fix, and
verification pipeline even when the only remaining work was pushing a
verified branch and opening a pull request, and it kept publication
inside a single 191-line reference document. The two halves also fail
differently: a mis-scoped analysis wastes effort, while a mis-scoped
push publishes a mistake.

Add a standalone `create-pr` skill that owns publication: preflight,
credential handling, title and body, push, `gh pr create`, and read-back
validation. Preflight requires a clean tree, an intended commit range,
and correct disclosure trailers. Credentials go through SSH or an
askpass helper, so the token never reaches a URL, a file, or a log. Title,
body, and verification evidence are written to `pr-title.txt` and
`pr-body.md` before the API call, and the PR is diffed against the local
branch afterwards. The skill refuses to edit code, force-push, or merge,
and sends an unverified or half-finished change back to authoring.

Reduce `fix-and-pr` to intake through commit. Phase 5 becomes the
handoff, the publisher role and the `pr.md` artifact move to the new
skill, and rule 10 forbids pushing from it. The document heading reads
"Fix and Commit" while the directory keeps its name. Delete
`references/07-pr-submission.md` and renumber the supporting documents
to close the gap, since their content is rewritten rather than moved.

Make delegation mandatory in both skills instead of advisory. The gate
tables now name the subagent that executes each phase, every brief ends
with a report path under `reports/`, and a gate is passed by checking
that report, not by the supervisor reading the code itself. The
supervisor keeps the briefs, the commit, the base/head decision, and the
final diff. Where a step previously allowed "the supervisor may perform
it directly when cheaper", or marked reviewer passes as optional, the
text now requires the worker or reviewer run and stops the workflow when
no subagent can be launched, since a self-certified gate is not
evidence. Body drafting and body review are delegated as well, so the
publication skill no longer runs `git push` or `gh pr create` itself.

State the disclosure rule as it is meant: the `Assisted-by: LLM` trailer
marks a commit written with agent help, so a commit from the maintainer
alone carries nothing and must not be tagged retroactively. The old
wording read as a repository-wide requirement, which would have pushed
agents to tag human commits and to block publication of mixed history.
Apply the same per-commit test in preflight and in the failure table,
and keep the PR body footer, which discloses who drafted the
description rather than who wrote the commits.

Assisted-by: LLM
Signed-off-by: greatbridf <greatbridf@icloud.com>
`fix-and-pr` required the whole intake, reproduction, fix, and
verification pipeline even when the only remaining work was pushing a
verified branch and opening a pull request. Add a standalone `create-pr`
skill that owns publication: preflight, title and body, credential-safe
push, `gh pr create`, and a read-back check of the PR against the local
diff. It refuses to edit code, force-push, or merge, and sends an
unverified or half-finished change back to authoring.

Reduce `fix-and-pr` to intake through commit, with the phase-5 handoff
pointing at the new skill. Delete `references/07-pr-submission.md`.

Make delegation mandatory rather than advisory. Each gate now names the
subagent that executes the phase, every brief ends with a report path
under `reports/`, and a gate passes by checking that report instead of
the supervisor reading the code itself. Phases that could previously be
run inline when that looked cheaper now stop the workflow if no subagent
can be launched, since a self-certified gate is not evidence. Body
drafting and review are delegated too, so publication no longer runs the
push itself.

State the disclosure rule as it is meant: the `Assisted-by: LLM` trailer
marks a commit written with agent help, so a commit from the maintainer
alone carries nothing and must not be tagged retroactively.

Cut the reference libraries down to what a run actually needs. Fold the
failure table, brief format, and artifact layout into the operating
contract, the analysis template into the analysis document, the command
reference into the phase that uses each command, and the credential
rules into the publish document. Prose that restated an example now
states the rule once.

Assisted-by: LLM
Signed-off-by: greatbridf <greatbridf@icloud.com>
Both skills claimed every phase is delegated and then contradicted that
claim in their own gate tables, which name the supervisor for preflight
and for the final handoff. A reader of the skill body alone concluded the
opposite of what the tables and role contract required, and the wording
had already drifted twice between the two files.

State the split where it is read: preflight is the supervisor's own work
with no subagent and no report file, because it is the decision to spend
subagents or publish at all; the rest of intake and the following phases
are delegated. In `fix-and-pr`, preflight is a section of phase 0 rather
than the whole phase, so the build, branch, and issue capture stay
`scout`'s — the preflight fence loses the build command it had no
business running on a supervisor that must not build. Gate-report
sentences now cover only the part a subagent runs, so no phase is asked
for a report it does not produce.

The body contract made `Fixes #N`/`Refs #N` a requirement, which an
issue-less change cannot satisfy: the validation step would fail the very
PR that installed it. Search for a matching issue instead, cite it when
one genuinely matches, never invent a number, and record the search
result. The local and read-back checks report a missing link and exit 0
rather than failing.

Assisted-by: LLM
Signed-off-by: greatbridf <greatbridf@icloud.com>
@greatbridf greatbridf changed the title docs/skills: split PR publication into a create-pr skill docs/skills: split PR publication out and tighten the skill contracts Nov 5, 2026
@greatbridf
greatbridf merged commit 710c33b into master Nov 5, 2026
6 checks passed
@greatbridf
greatbridf deleted the skills branch November 5, 2026 16:38
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