π± oss β Claude Code Plugin¶
OSS workflow plugin for Python/ML open-source projects. Four agents (two user-facing, two internal pipeline) and five slash-command skills: issue analysis, parallel code review, PR resolution, release artifacts/readiness, and post-install rule setup.
Changelog records version-by-version changes, including the plugin's earlier directory history.
Works standalone β
foundrynot required. Without it, agent dispatches fall back togeneral-purposewith role descriptions and less specialization. Installingfoundryunlocks the specialized agent roster.
Core guarantees
- Public actions stay maintainer-owned: replies, merges, pushes, tags, and releases are drafted or prepared here, never posted or published automatically.
- Review reports carry the full reviewed PR commit SHA and separate source judgment from verification readiness.
- Review β fix loops keep fixing feasible authorized findings while the weighted score decreases, and print the cumulative old/new progress table after each validated round. Completion prompts ask only for a missing decision or authorization.
- Concrete gates for fresh scope, paid execution, sensitive or destructive actions, and remote changes always remain in force.
π Contents
π€ What is oss?¶
oss = Claude Code plugin for Python/ML open-source maintainers. Five slash-command skills β analyse, review, resolve, release, and setup β plus four agents for contributor communication, CI health, and vitality data collection/scoring. It covers recurring maintainer work: triaging GitHub threads, multi-perspective PR review, organizing review feedback into fixes, and preparing release artifacts with readiness checks.
π― Why oss?¶
Maintaining OSS = three competing demands: review code carefully (catch regressions), respond to contributors fast (keep engaged), ship releases confidently (users upgrade). Each = context-switch tax. oss targets that tax:
- Less review context switching.
/oss:reviewclassifies the PR, runs relevant review dimensions in parallel, and writes a ranked report. The default fan-out is capped at four scope-selected dimensions;--fullruns every dimension selected by scope. An optional Codex integration can add a co-review, and missing optional agents fall back gracefully. - Contributors get a usable response draft. The
--replyflag drafts a welcoming comment in project voice, citing project conventions. The draft is written for maintainer review; the plugin does not post it. - Review feedback becomes traceable action items.
/oss:resolvereads live PR comments, a saved review report, or both; deduplicates sources; resolves conflicts semantically; and implements selected items with[resolve No.N]attribution, using isolated worktrees for specialist batches. - Release communication stays grounded in the diff.
/oss:releaseclassifies changes, checks documentation/version consistency, writes release notes and optional changelog/summary/migration artifacts, credits human and automated contributors distinctly, and audits readiness. It does not edit package versions, create tags, or publish packages. - Triage with structure.
/oss:analyse vitalityproduces a repo vitality scorecard with duplicate issue clustering and stale-PR detection. A specific thread becomes a structured summary with next actions.
Contributor credits combine Git authors/coauthors with verified in-range PR authors, including PR-only authors lost from squash metadata. Identity reconciliation uses verified login/email links, never name similarity; missing PR identity or range evidence remains a coverage warning. Bots share one automated-contributions line.
π¦ Install¶
After installation, run /oss:setup once to link this plugin's rules into ~/.claude/rules/; use /oss:setup --approve for the non-interactive path. Re-run it after an upgrade. In this repository, make sync-claude invokes that setup path for managed installs.
Recommended setup:
oss requires Claude Code, Python 3.10+, and an authenticated GitHub CLI (gh auth login) for GitHub-backed workflows. The plugin can run without foundry, but agent calls then use general-purpose fallbacks with lower specialization.
Optional integrations (unlock extra capabilities inside oss skills):
| Plugin | What it unlocks |
|---|---|
foundry |
Specialized review and implementation agents instead of general-purpose fallbacks |
bridge@borda-ai-rig |
Optional Codex co-review in /oss:review and Codex action-item dispatch in /oss:resolve; a CodeQL alert a dispatched item links is fetched by the calling session and sent to Codex |
codemap-py |
rdep_count in /oss:review risk assessment; stale-symbol detection in /oss:analyse triage; Open-PR Overlap + Structural Constraints in /oss:analyse vitality |
All oss skills degrade gracefully when optional plugins are absent β reduced capability, not broken commands. Install the optional pieces only if you need them:
For local-file review, install develop and use /develop:review (requires develop plugin); /oss:review is for GitHub pull requests.
Note: Skills always use the
oss:prefix:/oss:analyse,/oss:review,/oss:resolve,/oss:release, and/oss:setup.
Upgrade¶
Uninstall¶
Uninstall leaves the
~/.claude/rules/oss-*.mdsymlinks behind (see /oss:setup); delete them by hand.
β‘ Quick start¶
# Morning: understand what needs attention
/oss:analyse vitality
# Review top PR and draft a contributor-facing response
/oss:review 55 --reply
# Apply selected review feedback
/oss:resolve 55 report
# Prepare release artifacts
/oss:release prepare v2.1.0
π§ Skills reference¶
/oss:analyse¶
Issue/discussion reproduction requires the parent to show the exact snippet and command, then obtain approval; the snippet is scanned first and runs through the PR-code guard (disposable copy, sandbox, cleared environment), and running without a sandbox is the user's explicit choice. PR analysis always refreshes general conversation, review bodies and inline comments. Discussion fetching merges both pagination levels with 200-comment/200-total-reply caps and explicitly reports incomplete evidence.
Analyse GitHub threads + repo vitality + release evolution. Accepts issue/PR number, keyword vitality, keyword ecosystem, keyword evolution, or path to saved report file.
Execution architecture β animated diagram of fans, joins and gates.
Purpose: Structured actionable summary of any GitHub thread, or broad view of open work. No need to read every comment yourself. The run ends with the report and a plain-text Next: list of suggested commands (for a PR: /oss:review, /oss:resolve, a reply draft); it never asks a follow-up question. Every thread report header carries a bare Link: URL (issue, PR or discussion), so the delivered header table is clickable.
Auto-invokes when: user gives GitHub issue/PR number (#N) or github.com URL + asks analyze/summarize/triage; user asks "is this repo healthy" or vitality stats; user asks which release introduced the features that later releases fixed, or for a fix-lineage / feature burn-up chart.
Invocation:
/oss:analyse 123 # issue, PR, or discussion by number
/oss:analyse vitality # repo vitality: 9-axis health scorecard, duplicate clustering, raw data JSONL
/oss:analyse vitality --quick # fast daily scorecard: core scoring only, skips codex + adversarial passes
/oss:analyse ecosystem # dependency health, upstream compatibility
/oss:analyse evolution # feature Γ fix lineage across releases of this repo (asks for the release scope)
/oss:analyse evolution owner/repo v1.0.0->v2.0.0 # another repo, explicit range
/oss:analyse path/to/report.md # re-analyse a saved report
Flags:
| Flag | Effect |
|---|---|
--reply |
Draft contributor-facing response after analysis (routed through oss:shepherd for voice consistency) |
--quick |
Vitality only: fast daily scorecard β skips Codex independent review + adversarial rework loop, reduces to 4 spawns. Full (reviewed) mode = default; confidence is lower in quick mode |
--full |
Evolution only: rebuild the scan store from scratch; keeps the clone, your overrides.csv and saved LLM verdicts |
--break-lock |
Evolution only: remove a store lock the run cannot prove stale (another host, or native Windows), after you confirm |
--adjudicate |
Evolution only: let an LLM decide fix rows whose evidence is ambiguous; off by default until the Phase 0 evaluation shows it helps |
--bug-labels "<a,b>" |
Evolution only: replace the default bug label set (bug, type: bug, kind/bug, type/bug) for the open-bugs line |
--tag-prefix "<p>" |
Evolution only: scan one package of a monorepo whose tags carry a prefix (pkg-v1.2.0 β pkg-v); the package gets its own store and report |
--keep "<items>" |
Append quoted string to compaction contract's preserve: line β items survive auto-compact mid-run (advanced; long multi-agent sessions) |
The shared parser used by analyse, review, and resolve recognizes flag names case-insensitively across whitespace separators. Quoted text stays data, and a standalone -- ends flag detection. Helper callers must put a literal -- before the raw argument blob. Contract cleanup refuses linked or out-of-project state directories before deleting anything.
What it does:
- Thread number: fetches issue/PR, reads all comments, classifies thread type (bug report, feature request, question, duplicate, stale), produces a structured summary: what asked, current state, action needed from you, and β with
--replyβ a draft response. - With a codemap index, symbols/modules named in the thread are existence-checked; identifiers that no longer resolve flag the issue as referencing stale code (with a likely rename target when codemap suggests one).
- PR mode leads with a vitality verdict β is the PR's intent still aligned with the current codebase and worth pushing forward β built for long-stale PRs where the base drifted.
bin/pr_drift.pymeasures last-push age, commits the base gained, and which touched files changed or vanished on base since the merge base.- The verdict is
ALIVE,REVIVE-MINOR,REVIVE-MAJOR(push forward only with named rework),SUPERSEDED,OBSOLETEorUNCLEAR, each citing its evidence. - A fresh, undrifted PR gets a one-line
ALIVE. SUPERSEDEDandOBSOLETEverdicts offer a close-with-thanks reply instead of review.
- PR mode reads review bodies and inline code comments, expands findings a bot collapsed into a
<details>block, and merges the same finding when it recurs across review rounds. - The duplicate search works in steps:
- It reads a 400-character body snippet of every candidate, so a duplicate call rests on the reported failure rather than title words.
- It then fetches the full thread of up to 3 candidates to confirm each: the potential duplicates first, then numbers cited in the thread, then the closest related candidates in the same component, which are promoted when their body or comments show the same failure or root cause.
- An unconfirmed one is marked
(snippet only)with "verify, then close".
- Choosing the canonical:
- The canonical is the item a maintainer named, else the strongest failure match, the analysed item included.
- Candidates whose fetched bodies or comments establish the same root cause are an equal match, and closer symptom wording never makes one stronger.
- At an equal match a candidate that itself defers to another issue loses; when two or more potential duplicates are all unconfirmed, no canonical is named until the fetch confirms one.
- Listing:
- Once the canonical is determined and two or more potential duplicates remain, only the canonical (or the next-ranked candidate by the same order when the canonical is the analysed item) stays under Potential Duplicates.
- Every other one, including a candidate whose fetched comments defer to another report, moves under Related as itself a duplicate of the canonical, with an action to close against it and
(snippet only)where applicable. - When the canonical is undetermined, every potential duplicate stays listed.
- A number cited in the thread but absent from the search results is listed as related and unverified until its fetched body shows the same failure.
vitality: pulls open issues + PRs, scores the repo across 9 axes (Axes 1β8 plus Axis 9 Trajectory), clusters duplicates, flags threads stale beyond the project threshold, and gives a prioritised triage list with a weighted Health Score % (π’ β₯ 70%, π‘ 40β69.9%, π΄ < 40%) and one Top Risk axis. All raw API data is saved to a JSONL file beside the report.- When the bridge reports a Codex quota stop, the run makes no further Codex review call.
- The adversarial rework passes continue with the challenger alone, and the report says Codex was blocked by quota rather than timed out.
- The same holds when the challenger reports that its own Codex cross-check stopped on quota: later passes skip both the Codex review and the challenger's cross-check.
- With a codemap index the report gains an Open-PR Overlap note (pairwise changed-file overlap plus per-PR notes for PRs touching a high-coupling module) and a Structural Constraints block (highest-blast-radius modules, collision/degraded/stale index signals).
- Every codemap signal is optional β no index or plugin absent β GitHub-only behavior, gap flagged inline, never blocks.
evolution: traces which features each fix repairs and which release introduced them.- It reads the changelog ("Added", "Changed", "Fixed" sections; conventional-commit fallback for releases without one).
- It links entries to commits (SHA, PR, closing issue, then a low-confidence text match).
- It blames the lines each fix changed (SZZ, source files only).
- The result is a feature Γ fix association matrix with a soft view (each fix sums to 1, for release totals) and a binary view (one fix can repair several features; only blame, changelog-text, LLM or manual evidence counts as a link, while symbol, file and inherited overlap stay in the soft view).
- The report shows a fix-flow Sankey and release heatmap coloured by origin age (previous release, 2β5 back, legacy), the most-fixed features, a burn-up of features, fixes and approximate open bugs, a same-cycle panel for bugs fixed before they shipped, and every fix it could not place (
unlinked,unattributable,timed_out,unadjudicated,unknown). - All charts are inline SVG in one self-contained HTML file; no CDN, no script. A Markdown report with static SVGs sits beside it.
- Results live in a durable store,
.evolution/<host>/<owner>/<repo>/, outside every TTL sweep. A rerun resumes an interrupted scan, adds new releases, and rescores from stored evidence without blaming again. Correct any cell inoverrides.csv(fix_id,column_id,assert|deny,note); corrections survive reruns and--full. - Scoring weights stay provisional until they are checked against hand-labelled fixes with
bin/evolution_eval.py; the report says so while they are. - With
--adjudicate, a model settles rows the scores leave ambiguous. It names a feature only when blame backs it: a blamed commit in that feature's footprint, a link inherited through an earlier fix, or, for an add-only fix, a blamed context line; otherwise it answers unknown.bin/evolution_scan.py render-requestwrites such a request from fix specs, for replaying one by hand.
Sample vitality scorecard (terminal output):
# Repo Vitality β example/mylib
**Skill:** oss:analyse v0.7.0 Β· **Generated:** 2026-05-11T10-00-00Z
---
## Executive Summary
Project is in healthy condition (73%) with strong CI/CD and documentation.
Bus factor of 2 is the primary risk. Dependency update config absent.
**Health Score:** 73% π’ Β· 5 healthy Β· 4 warning Β· 0 critical Β· 0 unavailable (βͺ)
**Top Risk:** Axis 3 Contributor health (conf 0.90) β bus factor = 2, one departure stalls merges
---
| # | Axis | Score | Status | Key Signal |
|---|----------------------|--------|--------|--------------------------------------|
| 1 | Responsiveness | 10.0 | π’ | median issue 1.2d, PR 0.8d; 94% β€7d |
| 2 | Maintenance activity | 10.0 | π’ | last commit 3d, 18 commits/30d |
| 3 | Contributor health | 6.0 | π‘ | bus factor 2, retention 67% |
| 4 | Issue & PR health | 5.0 | π‘ | stale 18%, close 0.71, review 62% |
| 5 | CI/CD & code quality | 10.0 | π’ | 5/5 checks, CI pass 95% |
| 6 | Documentation | 7.0 | π’ | 7/9 checkpoints |
| 7 | Governance | 8.0 | π’ | 6/7 files, active maint 3/3 |
| 8 | Security posture | 5.0 | π‘ | dep-config: no, alerts: 403 |
| 9 | Trajectory | 5.0 | π‘ | pool -40%, TTM 2d->3d, P90 45d, dep 12% |
| | **Total Score** | **73%** | | |
Output locations:
- Thread analysis:
.reports/analyse/thread/ - Vitality report:
.reports/analyse/vitality/ - Ecosystem report:
.reports/analyse/ecosystem/ - Evolution report:
.reports/analyse/evolution/<host>-<owner>-<repo>-<date>/(report.md,report.html, SVGs); scan store:.evolution/<host>/<owner>/<repo>/(never auto-deleted)
GitHub API responses are cached in .cache/gh/ by number and date (30-day TTL) β repeated calls on the same thread are fast.
/oss:review¶
PR review freezes the full PR-head SHA for source reads. Targeted execution requires a clean checkout at that SHA and the foreground parent's approval of the exact command and project environment; a matching HEAD alone never grants consent. --worktree uses a detached PR-head checkout, reports its path and SHA, and keeps it before follow-up. QA/security coverage stays pinned except for docs-only review.
Reviews assess material improvement claims against revision-bound tests or measurements, distinguish supplied evidence from independent reproduction, and treat unresolved shared-hardware noise as inconclusive rather than proof of a gain or regression.
Scope-aware parallel review of a GitHub PR. Input is a PR number or a saved review report for reply drafting.
Execution architecture β animated diagram of fans, joins and gates.
Purpose: Review architecture, tests, performance, docs, linting, and security in parallel. Produce a ranked findings report and, optionally, a welcoming contributor comment. The report header carries a bare Link: to the PR, so the delivered header table is clickable.
Invocation:
/oss:review 55 # scope-aware review β saves findings report
/oss:review 55 --reply # review + draft contributor-facing comment
Local files or current git diff without PR β use
/develop:reviewfromdevelopplugin.
Report contents
- Aggregate prose summary, verdict, confidence and detailed findings.
- Header table adds
Reviewers: Software engineer [3], QA specialist [2], Documentation reviewer [1].Each rating sits in square brackets after the role name; skipped roles are omitted. - Rating legend: 1 = Approve Β· 2 = Minor changes Β· 3 = Major revision Β· 4 = Insufficient, but a good initiative Β· 5 = Block. Ratings are the actual reviewers' scoped judgments, never an averaged verdict.
- The findings overview has an
Authorcolumn listing all contributors to each deduplicated finding. - Reviewer names and finding authors show roles only, without execution-origin labels.
- Terminal rejection reports
Not assessedwhen no source review ran. - Every candidate is validated before publication; only confirmed findings become automatic
/oss:resolveitems. Open concerns are kept inreview-validation.json. - Minor changes include bounded, low-impact correctness, test and compatibility fixes with localized repair and verification.
- Major revision requires evidenced material behavioral impact or substantial repair, even if a serious defect needs only a small patch.
- The verdict cites final finding IDs, impact and repair scope; finding counts, CI status and reviewer votes do not set it automatically.
- Required fixes remain actionable under Minor, and no unresolved required source change normally means source approval with readiness reported separately.
- Documentation-only corrections and missing or additional tests normally remain Minor unless concrete material consequences or a substantially incomplete required deliverable justify more; missing tests alone do not establish a production bug.
- These factors inform one combined judgment: high-impact findings can control the verdict and are never diluted by minor items.
- Use the strongest confirmed consequence as the baseline, account for proven joint effects, and keep severity, source disposition and verification separate.
- Missing tests no longer receive an automatic High rating; numeric topic discounts require independent calibration before they can determine verdicts.
How the pipeline works
- Scope detection (
git diff --stat) β exits only if no Python or doc files changed. - Acceptance gate β Stage 1 (reject, terminal) then Stage 2 (block, non-terminal); reads the PR description before any agent spawns; CI never stops the review. Criteria: "Review stages" below.
- Optional Codex co-review β runs when
bridge@borda-ai-rigis installed and enabled; otherwise skipped. - When the acceptance gate's challenger reports that its own Codex cross-check stopped on quota, this run skips the co-review and the report says why.
- After that stop, or when the co-review itself stops on a Codex quota incident recorded by the bridge, the challengers that verify critical findings run without their Codex cross-check.
- Parallel review dimensions β reviewers share the frozen PR metadata, diff and initial check results.
- Scope selects spawn units; paired dimensions share one agent (performance + architecture in one opus spawn, docs + lint in one sonnet spawn). Each writes its own finding file and confidence block.
- Default ranks units under a cap;
qa-specialistis pinned outside the cap (security scan runs on every code PR).--fullruns every unit selected by scope. A unit whose territory holds a changed changelog or migration guide, a CI workflow file or a stated performance claim is promoted into a slot ahead of the others, inside the same cap. A promoted unit that still finds no slot makes Readiness incomplete, and every unit that did not run is named in the report as an unreviewed dimension. - The sw-engineer reviewer first asks whether the PR is behavior the package is meant to have, judged against README/docs, public API, tests, CHANGELOG and CONTRIBUTING/ADRs at the PR base; PR title, body and commits count as unverified claims. The report summary opens with
Intended behavior: yes/partly/no/undetermined; contradictions, undeclared or unimplemented behavior changes and out-of-scope behavior areintent:findings, for every change type. - FEATURE/MIXED scope adds a blind-solve pass outside the cap: one isolated agent sketches its own blueprint from the PR title/body/linked issues without seeing the diff. The report's
### Design Divergencesection lists where the PR diverges from it, flagging divergences the agent may have lacked context for as questions. - Review continues with pending or failing CI. At consolidation, a read-only refresh picks up user reruns on the reviewed commit. The report shows the latest status, or why it was unavailable, alongside the source verdict. When the refresh cannot read the reviewed commit's checks, a failure seen there earlier in the run still sets
Gate: REVIEW_V1_BLOCK. The same happens when the earlier result could not be recorded, so an unrecorded failure never reads as a pass; the CI status names the missing record. With codemap,rdep_count > 20flags a high-risk change. - Reviewer environment. Gated tests use a private environment outside the checkout, with only eligible base-declared packages installed as official-index wheels. Planning checks project, workspace, lockfile and selected-interpreter installer settings. Added packages, direct references and unapproved routing stay with the PR-code gate and appear in the receipt. Cached environments must match the Python that selected them. Partial installs retain available packages and retry missing ones. The report gives install failure causes and one
Environment:line with the actual host facts. Cleanup covers only marked, unlocked environments unused for at least seven days. - Author claims. The review extracts separate measured effects from PR prose and tables, and the perf reviewer lists the claim IDs a benchmark covers. Base and head run from detached checkouts pinned to the exact revisions under the existing PR-code decision. Results compare the relative effect on this host and report spread, execution tier and completed rounds. Unparsed claims and measures without matching samples stay visible with their cause. A claim requiring an unavailable OS, architecture or accelerator names that exact class.
- Impact depth. With codemap enabled and a codemap-py that provides
codemap-py context, impact comes from a per-head index of the reviewed commit outside every checkout; older codemap-py versions keep the previous working-tree query only when the checkout is exactly the reviewed head, and otherwise report the impact as unknown. When impact cannot be determined, theImpact:line says why (for exampleimpact unknown: index stale) and the review keeps its full specialist lineup. - Report confidence is the median of the reviewers' scores, capped by named coverage gaps: Readiness incomplete 0.70, blocked 0.80, PR code not executed 0.80, a unit dropped by the cap 0.85. The Codex co-review carries a score only when its reply reports one; otherwise the report names the bridge's own code (for example
peer-unavailablewhen the bridge plugin is absent). The reviewer host's operating system and a missing Python package are never recorded as gaps; an absent hardware class such as CUDA is named exactly. - The sw-engineer architecture reviewer and the linked-issue analysis agent spawn at high effort: the agent's default is extra-high, and both only read and judge. Challenger, performance, qa and verifier spawns keep their own defaults.
- Consolidation β the selected consolidator merges findings into a ranked report. A sw-engineer consolidator (code PRs) spawns on sonnet at high effort and is re-spawned once on opus at high effort if the publication gate (or, in a fill-gaps run, the carry check) rejects its report; doc-scribe and qa-specialist consolidators keep their defaults.
--replyβoss:shepherddrafts the contributor-facing comment from the consolidated report (written to.temp/; you post it).
Before the final follow-up gate the skill refreshes its compaction contract and prints a /compact hint, so a long wait can be spent compacted; resolve later reads the report file, not the transcript. If /oss:resolve for the same PR is already running in the session, the gate is skipped and the suggestion is printed as plain text. After a rejection, the gate offers the report's drafted close reply instead of /oss:resolve, which refuses a rejected head; you post the reply yourself.
Without foundry, selected dimensions fall back to general-purpose agents with role descriptions β functional, but less specialized.
Review stages (acceptance gate). The report's Gate: header has two states beyond PASS. Reject is terminal (skips every tier, no agent spawned); block is not (the full fan-out still runs and the report surfaces the fixable gap up front). Test: could revising the code, not the goal, resolve this? Yes β block. No β reject. The header's three axes are independent: Gate is the CI merge gate (or a premise rejection), Outcome is the source judgment, and Readiness is the verification state. A fixed Axes: line after the legend says so in every report, and modes/verdict-states.md lists the valid and impossible combinations.
Stage 1 β Reject (terminal, 8 grounds)¶
Aligned with close-without-merge practice in K8s/CPython/Rust/Django contributing docs. Every ground needs affirmative evidence, never suspicion alone.
| Ground | Test |
|---|---|
REJECT_GOAL |
Stated goal factually/technically wrong regardless of diff quality β e.g. "raise this [0,1]-bounded metric above 1.0". Disagreeing with the approach is a normal review finding, not this. |
REJECT_CONDUCT |
By-design adversarial/malicious contribution or Code of Conduct violation. Confirmed via a shared foundry:challenger check before rejecting β accidental (or confidence \<0.7) falls through as a normal finding. |
REJECT_SCOPE |
Out of project scope / against roadmap. Evidence: a wontfix/invalid/declined/out-of-scope label already applied, or an explicit "out of scope" statement in CONTRIBUTING.md/an ADR the PR directly matches. |
REJECT_LICENSE |
Incompatible license copied in, or plagiarized source with no right to submit it. Not the same as a missing CLA/DCO signature (Stage 2, fixable). Confirmed via the same shared foundry:challenger check as conduct. |
REJECT_DUPLICATE |
The merged closer already delivers the proposed behavior. The report links the issue and earlier PR, explains the overlap and any material difference, and drafts a close recommendation. |
REJECT_REVERTED |
Reintroduces a previously reverted change without addressing why it was reverted. Evidence: a matching revert commit exists and the PR body doesn't reference or address it. |
REJECT_SPAM |
Spam/low-effort/AI-slop β no real change, hacktoberfest-farming pattern. Needs both a trivially low-value diff and a generic/templated description β either alone isn't enough. |
REJECT_PHILOSOPHY |
Contradicts a documented design principle, not just a style preference β e.g. adding a GUI to a project whose docs state "CLI-only by design". Requires a citable doc line. |
Stage 2 β Block (non-terminal, full review still runs)¶
Default [blocking] tag per finding category β judgment still required, not automatic:
| Category | Default | Nuance |
|---|---|---|
| CI red / failing check | blocking | A failing required check, or any failing check when none is required (the CI gate rule). A flaky failure counts until rerun. |
| Missing test coverage for new/changed logic | blocking | β |
| Accidental security bug (careless, not by-design) | blocking | By-design version is Stage 1 REJECT_CONDUCT, not this. |
| Breaking API change, no deprecation/migration path | blocking | β |
| Missing docs for new/changed public behavior | blocking | Missing CHANGELOG entry alone is not blocking β can land in a follow-up (/oss:release). |
| Perf regression | contextual | Bad when a regression vs recent releases has no offsetting reason; not blocking when it is the cost of fixing a correctness bug. |
| Merge conflicts | not blocking | /oss:resolve's job β review doesn't gate on it. |
| Incomplete implementation (TODOs in changed paths, missing error handling) | blocking | β |
| Missing CLA/DCO signature | blocking, only if the project requires one | Check first β CLA-assistant/DCO-check bot status, or a signing mandate in CONTRIBUTING.md. No such requirement β not applicable. |
Typical scenarios:
| PR type | Agents that run | Skipped |
|---|---|---|
| Docs-only (.md, .rst) | doc-scribe, plus challenge/Codex when enabled/available | Code, test, performance, architecture dimensions |
| Docs + CI/CD | oss:cicd-steward, doc-scribe, plus challenge/Codex when enabled/available | Code, test, performance, architecture dimensions |
| Tests only | qa-specialist, linting-expert | Other dimensions |
| GitHub Actions only | oss:cicd-steward, sw-engineer, plus challenge/Codex when enabled/available | Test, performance, architecture, docs dimensions |
| Annotation-only Python | linting-expert | Other dimensions |
| Notebook/manifest/config only | code lineup (qa-specialist kept) | Units ruled out by scope |
| Code PR | Pinned qa-specialist + top three ranked units, promoted units first (--full removes the cap) |
Units ruled out by scope or the default cap |
Review depth follows the code path, not the diff size. A few lines in a private helper on the main feature path can break the main user story. With codemap, the review traces every changed function's transitive callers and sets an Impact: tier in the report header.
FULLβ the change reaches a public function outside tests and leaf modules such as visualization, plotting, examples or docs.LIGHTβ it stays off that path. Only aLIGHTfix may skip the performance and architecture dimensions.- Without codemap, or when impact cannot be traced, the tier is
FULL. The challenger, Codex and the pinned qa-specialist run at either tier; the orchestrator never reviews code alone.
A missing package is closed, not documented. When a reviewer needs to run a claim and the PR's declared dependency (for example a raised pyproject.toml floor) is absent or at the wrong version locally, the review unpacks the matching wheels into a run-local overlay directory and runs the targeted tests against it, instead of reporting "not installed".
- Only a package the base branch already declares qualifies, with the plain version range the PR gives it. A package the PR newly adds is reported as a
new dependencyfinding; a direct reference, URL or path becomes anon-index dependency referencefinding and is never fetched. - A name routed to a private or other non-default index (via
[tool.uv.sources], a non-explicit[[tool.uv.index]], requirements index options, aPipfilesource, a lock-file registry, or youruv/pip index environment variables and config files), or whose routing cannot be determined, is never fetched and keeps the gapnon-default index dependency <name>. Your index settings are never stripped to reach the public index. - A wheel-only dry-run on the default index checks support first; nothing is built from source, and the project environment must be identical before and after.
- Downloading the wheels and running the tests are separate commands, each behind its own permission prompt, so approving a download never approves running PR code.
- The report's
Review Confidencesection records each overlay run (package, version, wheel, declaringfile:line, fetch and run commands, result) or the concrete reason it could not run.
Fork PR execution. If the scan reports risk none for the exact PR head, review shows the scan summary and runs needed checks without asking, in the guard's disposable copy with a cleared environment and no sandbox. Findings, unavailable scans or a head mismatch keep the question, which opens with one plain sentence on why the code is not treated as safe, with Run in sandbox first.
Output locations:
- Per-agent handover files (intermediate):
.temp/review/<timestamp>/ - Consolidated report:
.reports/review/pr-<N>/run-<NNN>/review-report.md - Code safety record for
/oss:resolve:code-safety.jsonbeside the report records the scanned PR head, the scan verdict and risk level (orsame-repo/ not scanned), so resolve can tell whether the same head was already scanned clean. It is evidence only and never approves running code. - Structured findings for
/oss:resolve:findings.jsonlbeside the report β one record per finding with a stable id (section slug plus a hash of file and title, so it survives line drift), the reviewer's evidence file and any verifier verdict - Reply draft (with
--reply):.temp/output-reply-<PR#>-<date>.md
Flags:
| Flag | Effect |
|---|---|
--reply |
After consolidation, oss:shepherd drafts a welcoming two-part PR comment (positive framing first, then specific actionable asks) |
--no-challenge |
Skip the adversarial challenge pass |
--sandbox |
Enforce the sandbox for every run of fork-PR code: no unsandboxed run and no Run without sandbox option, no question while the scan's risk level is none or borderline, and a host without a sandbox reports an execution gap |
--codemap / --no-codemap |
Require or disable codemap structural context; default is automatic when available |
--full |
Run every dimension selected by scope instead of the default cap |
--fill-gaps <report> with --roles "<a,b>" and/or --candidates "<ids>" |
Re-run only the named reviewer roles and candidate checks of a prior run whose PR head is unchanged; everything else is carried into a new run that must pass the publication gate. Unknown ids, a moved head, or a failing carried record stop with ! BLOCKED |
--worktree |
Opt-in. Review in an isolated git worktree (base: HEAD) so no dimension agent can mutate main sources. Report is written to the main tree. PR-review mode only (not --reply/direct-report). Leaked-worktree cleanup is offered only if creating its own worktree still fails after one retry, and nothing is deleted without asking |
--keep "<items>" |
Append quoted string to compaction contract's preserve: line β items survive auto-compact mid-run (advanced; long multi-agent sessions) |
! BREAKING β `--semble` is gone from `/oss:review`. The semble semantic-search companion is no longer consulted by any review agent; passing the flag now trips the unknown-flag prompt. Measured on the blast-radius benchmark, semble lost to both the plain and codemap arms on cost, input tokens, and recall, so the companion carried cost without evidence of value.
Fix: drop `--semble` from saved invocations; codemap structural context (`--codemap` / default auto-detect) covers the importer lookups the companion used to supplement.
Existing-report guard. Review and resolve use only released reports. A newer pending or refused publication is shown separately from the last usable review. Reusing a publication shows the original verdict, findings and confidence. An explicit resume continues the original pending run at its saved checkpoint. A direct report path can draft a reply from a validated publication, including a terminal premise rejection. If the PR moved, a reply names the reviewed commit and current unreviewed head. A fresh review reads all available pages of discussion, including inline comments, even on an unchanged commit.
/oss:resolve¶
Preflight fetches origin without pulling or merging the caller's branch. Checkout verifies both the expected branch and exact PR-head OID. Fork heads named like the upstream default use a local pr-<N>-<head> alias, with an explicit remote-head refspec handed to the user for manual push. Closed/non-editable PRs stop before checkout. Stage mode and detached recovery preserve pending work. Repository hooks follow the local Git setup: with no installed hook, or with installed hooks whose in-tree inputs (hook scripts, .husky, .githooks, .pre-commit-config.*, package.json) the PR leaves identical to its base, nothing is asked; when the PR changes a hook input, or the base cannot be compared, the parent shows the exact commands/configuration and records per-run approval, and the answer can be remembered per repository (an approval bound to those exact hook bytes, or a never-run policy, stored in the Git common directory); approved formatter failures retry once only within selected worktree and index paths.
Apply review findings to codebase. Reads live PR comments, a saved review report, or both β deduplicates, resolves conflicts, implements fixes.
Execution architecture β animated diagram of fans, joins and gates.
Purpose: Close the gap between "reviewer said X" and "X in code." One command: open findings β committed fixes. The final report prints a bare Link: to the PR under its heading.
Reject-gate interlock: if the newest /oss:review report for this PR carries Gate: REJECT_<GROUND> (any of the 8 grounds above), resolve refuses to start unless the PR's head commit has changed since that review β a rejected premise isn't something a code fix resolves. Gate: BLOCK (e.g. red CI) and everything else proceed normally.
Invocation:
/oss:resolve 55 # pr mode β apply fixes from live GitHub PR comments
/oss:resolve report # report mode β apply fixes from the saved /oss:review report
/oss:resolve 55 report # pr + report mode β both sources, deduplicated (`report 55` works too)
/oss:resolve # review-handoff mode β picks up from the last /oss:review run
Source modes:
| Arguments | Mode | Source | When to use |
|---|---|---|---|
55 (PR number) |
pr | Live GitHub PR comments | Apply feedback posted directly on GitHub |
report |
report | Saved /oss:review findings file |
Apply findings from last review run |
55 report |
pr + report | Both, aggregated | Full close β deduplicates across both inputs |
| (none) | review-handoff | Review-handoff | Continues directly from last /oss:review run this session |
Report handling
- Report source is PR-scoped. The newest report for this PR is located once and reused, so two PRs under review can never mix findings. When no readable report exists, resolve asks before producing one β continue without report findings, stop with the
/oss:review <PR#>command printed, or abort. It never silently falls back to GitHub comments only and never starts a review fan-out itself. - Discovery looks in
.reports/review/pr-*/run-*/review-report.md(and the legacy.reports/review/*/review-report.md). A Codex-native report (.reports/codex/review/*/review-notes.md) is detected and refused with an explicit message so a blocking finding never goes unactioned; pass the PR number explicitly instead. - Verdicts: report
Outcome:isAPPROVE,MINOR_EDITS,MAJOR_REVISION,INSUFFICIENT_BUT_PROMISING,REJECTor literalnull(archived reports withNEEDS_WORKorREQUEST_CHANGESare still read), optionally preceded by its verdict symbol. Intake tolerates case and word-separator variations; missing verdicts, placeholders and glued suffixes keep the report incomplete. - Findings are reused, not re-derived. With
findings.jsonlbeside the report, resolve loads it directly; older reports are parsed once into the same shape. Merging never renumbers: GitHub items keep ids1..G, unmatched review findings are appended fromG+1. A terse GitHub comment at the samefile:lineas a review finding (or judged the same target) inherits that finding's full text and evidence; a short comment no finding covers is reassessed from scratch. - Intake gate: a report that fails intake is never repaired in place. Resolve prints a graded gap table and asks whether to proceed with the valid parts (only when no gap is critical), rerun review for selected gaps (
/oss:review <N> --fill-gaps <report> --roles β¦ --candidates β¦), rerun in full, or abort. - Evidenced later fixes complete their selected tasks without a new commit; unverified items remain pending obligations.
- Execution approvals are decided early and asked up front, last. For a PR, the sandbox question for fork-PR code and the repository-hook question (when the PR changes hook inputs) are decided right after checkout and asked at the selection gate, after scope, commit mode, grouping, dispatch and push, so the rest of the run needs no one at the keyboard (
reportmode with a PR number asks them at the Step 8 prelude instead, because its selection gate comes before the checkout). One case asks again mid-run: when the base merge or later work touches a dependency manifest the guard refuses the first test as stale, and the PR-code question is asked once more at the then-current commit; a second refusal at the same commit is reported as tests not run. Before every merge commit resolve refreshes the hook approval it made itself; a hook approval you gave that no longer matches the merged files is dropped, the merge commits with hooks disabled and the report names it under Repository hooks. When the last gate call has no free slot they share one extra call right after it. Every answer, "Do not run" included, is recorded so a later pass never overrides it. - A clean scan skips the question; resolve's runs stay in the sandbox. If
code-safety.jsonbeside the report records the same head with risknone, this run's own scan of that head also finds nothing and the host has a usable sandbox, resolve binds the sandbox without asking. Resolve merges the base and edits files before it tests, so what runs is not the scanned head, and only/oss:review, which runs the scanned head itself, runs a clean scan without the sandbox. The final report'sPR code:line says so, with the head. The scan is a static heuristic, so any finding, a moved head, a missing record or a host without a sandbox asks, with the sandbox as the first answer. When the base merge makes an earlier sandbox approval stale, a clean rescan of the merged commit renews it without asking again; an earlier unsandboxed answer, any finding or a host without a sandbox asks as before.
How it works β three phases:
- Intelligence gathering β
bin/fetch_pr_intel.pyfetches the full PR thread (conversation comments, reviews, inline comments with resolved-thread flags, commits, linked issues) into one deduplicated file without a model. A Haiku subagent then classifies each finding; the orchestrator reads a compact classified table. - Conflict resolution β merge conflicts are resolved semantically (read intent from both sides; never mechanical "take ours"/"take theirs"). Checkout and the trial merge start in the same turn as the intelligence subagent; conflict resolution is dispatched right after you answer, beside the first challenge wave. While files conflict, challengers read from the pinned PR head. Over 20 conflicted files β abort and report.
- Action item implementation β three-phase parallel dispatch:
- Challenge (read-only, grouped by domain, all groups concurrent): each challenger reads the reviewer's evidence file before the code. A finding the review's independent verifier already confirmed is not re-proven unless the PR head moved since the review. Challengers take at most 12 items each.
- Implementation (grouped by specialist:
sw-engineer,qa-specialist,doc-scribe,linting-expert,perf-optimizer,solution-architect): each group runs in its own isolatedgit worktreepinned to the PR head, at most 5 items per agent (8 with per-specialist dispatch).sw-engineergroups whose highest effort is high or medium (no extra-high-effort item) run on the sonnet model; medium-only groups are included deliberately, since that work is smaller, never harder. Those groups also pass their own effort level at spawn, because the agent's default is extra-high; an extra-high group passes none.- A single file with more items than the cap runs as a chain of agents, each building on the previous one's commits.
- Two grouping tiebreaks cut merge conflicts: a file-ownership tiebreak gives every contested file to one specialist, and a soft import-coupling merge keeps a rename and its callers in one worktree.
- Merge-back: the orchestrator cherry-picks every item's commit onto the PR branch sequentially, most-central group first. Conflicts that slip through use the same semantic resolution as step 2. A branch mutex blocks a second concurrent resolve run, and a HEAD fingerprint flags any external write that lands mid-flight.
- Items of medium/high effort touching a single file with a code, test, docs, style, config, or CI change may instead route through
bridge:implementone at a time from a clean worktree;--agent <name>overrides routing.- When the bridge reports that Codex is out of credits or over its usage limit (a quota stop recorded in the bridge's incident file, not just the reply wording), no further item goes to Codex in that run.
- That item and every later one run through the specialists instead, and the final report says Codex was blocked by quota.
- A challenger that reports its own Codex cross-check stopped on quota has the same effect: no further item goes to Codex, and later challengers skip their cross-check.
- A bare review comment passed to
/oss:resolvefollows the same rule: the comment goes to the matching specialist and the Codex review loop stops. - Rate limits and model-capacity stops keep the earlier handling.
- A commit carries the Codex co-author trailer only when it includes an item Codex implemented; items the specialists finished, including those after a quota stop, never add it.
- Per-item verdicts and
[resolve No.N]attribution remain. Every selected item runs in one pass, so a large selection never needs a rerun. After a review report is consumed, each finding's outcome (fixed,self-resolved,rejected,skipped,pending) is appended toresolution.jsonlbeside it, and a later/oss:reviewof the PR re-checks earlier fixes and rejected findings.
Item selection. Between gathering and implementation, resolve lists every pending item as a plain #<id> [<type>] <summary> line in the bulk question's text, most severe first, within a 1,500-character budget.
- Past the budget it lists the top items, pending counts by type and the path of the run's
action-items-table.md; closed items are named by count. - The full table is written before the call and printed once as the last text of the message that issues the picker.
- Every selection call opens with the bulk-action page:
+All [req],+All [suggest],ALL (req + suggest),Skip all. To pick items yourself, tick them on the item pages; a bulk choice adds to your ticks and never discards them (Skip allapplies only when you tick nothing). - Items are split into checkbox questions of two or three items each; past 18 items per-item checkboxes are replaced by the saved table plus the bulk, commit, grouping and dispatch questions. Resolved/addressed IDs can be typed explicitly in the bulk menu.
- Commit mode and (for "By topic group") the grouping strategy β by change domain, by file, by specialist, or your own
<id>=<topic>labels β ride in the same call. Topic-group commits get Conventional Commits subjects. - Report mode uses the same selection and commit-mode gate before checkout or implementation.
Dispatch granularity (asked at the same gate):
| Choice | Effect |
|---|---|
Auto (default) |
Pool-capped waves, at most 5 items per agent |
Sequential |
One worktree at a time |
Per specialist |
Up to 8 items per agent, so most specialists get a single worktree (a specialist with more than 8 is still split) |
Custom |
Asks again at the Phase 1 β Phase 2 boundary, showing the formed groups |
The answer changes wave width and sub-group size only β specialist routing and the grouping tiebreaks are unaffected.
Tests run where they pay off.
- Implementation and QA agents run only tests covering their changed files (codemap test-impact when available, name/import heuristics otherwise).
- The repository's full-suite command runs in the background at the end of the lint/QA gate β once when it passes, again after each fix (within the gate's 3-iteration cap) β so a green full suite is the last test evidence before push. It is skipped when every item was lint/typo class, and when the run edited only user documentation (
.md/.rst, not skills, agents, rules or prompts) β QA is skipped too and the report notesfull test suite not run β documentation-only changeas a zero-weight confidence gap./oss:reviewnotes the same gap on Docs-only PRs. - Every resolve cycle closes with parallel
foundry:linting-expert+foundry:qa-specialistpasses before the final report.
Fewer turns while it runs. Progress tasks ride along with real work, git state is read with one git_state_snapshot.py call, and background agents are never polled: each spawn gets a deadline, and an agent that stops without its deliverable is reported as timed out immediately.
Almost everything is asked up front. The gate also asks whether you intend to push after lint/QA passes and whether to open the PR in the browser afterwards. After you answer, conflict commit, implementation and lint/QA proceed without another question, so you can walk away.
- Before pushing, resolve asks you to confirm with the diff stat and commit count in front of you β unless you chose "don't push".
- The target branch is merged early and re-checked before lint/QA and before the push confirmation; if it advanced, resolve re-merges it (up to 2 times) and offers a re-sync before pushing.
- Separate push approval binds the checkout HEAD, branch and configured remote to one push. Decline cancels only that pending question in the current session, and resolve retires pending run-push approvals after recording delivery.
- A push you did not authorize never happens. A rejected (non-fast-forward) or blocked push is not retried or forced. With no upstream tracking, resolve hands you the exact command instead.
- The final reply shows the PR number and canonical link beside delivery. A successful push is verified against the PR head. For skipped, blocked or rejected pushes, the report checks remote history, uses recorded pull intervals to exclude incoming commits, and marks incomplete history inconclusive. A rejected remote push includes Git's error and the resulting confidence gap. A skipped push records your decision.
- From the lint and QA gate onward, each run keeps an incomplete
resolve-report.mduntil the final report replaces it. The final report gives the reasons recovery work was kept and only offers force deletion after branch ancestry or landed tree content is proven. Unproven branches get inspection guidance. Worktrees get removal commands only when their tips have an independent surviving ref. Items requiring a GitHub write come with commands for your approval. - Resolve switches back to your starting branch only after a successful push; otherwise it stays on the PR branch holding the commits.
Reuse after /oss:review. The blast-radius check reuses per-module codemap answers review already computed. Reuse is fail-closed: the answer must match the current index commit, scan time and file stamp; otherwise (or with no review artifact or no codemap plugin) the module is queried live β no behaviour change.
Severity β triage type mapping (report mode):
| Review severity | Section | Resolve type |
|---|---|---|
| any severity | ### [blocking] Critical |
[req] |
| CRITICAL | any | [req] |
| HIGH | any | [req] |
| MEDIUM | Architecture, Performance, API Design (code-related) | [req] |
| MEDIUM | Test Coverage, Documentation, Static Analysis, Codex Co-Review | [suggest] |
| LOW | all other sections | [suggest] β one row per finding the report prints, never dropped |
[req] items apply by default on bulk-action; [suggest] items need explicit selection. Security findings inherit severity from /oss:review (hardcoded secrets β CRITICAL, dep CVEs β HIGH) β there is no separate security category. LOW findings are never clustered; root-cause-merged rows fold into the survivor's item.
Guard rails:
- Any number of selected items dispatches in one pass β no cap question, no rerun for a remainder.
- Challengers take at most 12 items each, all in parallel waves.
- Implementation agents take at most 5 items each (8 with per-specialist dispatch) in pool-capped waves; sequential dispatch runs one worktree at a time, and a single file with more items than the cap runs as a serial chain of agents.
- With more than 50 pending items, the bulk-action question's text warns that selecting more than 50 means one long run, so you see it while choosing; when more than 50 were selected, the final report repeats it in one line.
- No dispatch silently drops a selected item
- More than 20 conflicted files β aborts, reports; you review manually
- Git push requires explicit confirmation before executing
- Core invariant: uses
git merge, nevergit rebaseβ preserves history
Flags:
| Flag | Effect |
|---|---|
--worktree |
Opt-in. Wrap the whole run in an isolated git worktree (base: HEAD) entered before gh pr checkout, so the checkout, per-specialist worktrees, and cherry-picks never touch your main tree/branch. Commits push to the fork only after explicit confirmation |
--no-challenge |
Skip per-item challenge validation |
--sandbox |
Enforce the sandbox for every run of fork-PR code: no Run without sandbox option, no question while the scan's risk level is none or borderline, and a host without a sandbox reports the tests as not run |
--agent <name> |
Select the implementation/intelligence agent instead of the default Codex path |
--codemap / --no-codemap |
Require or disable codemap structural context; default is automatic when available |
--keep "<items>" |
Append quoted string to compaction contract's preserve: line β items survive auto-compact mid-run (advanced; long multi-agent sessions) |
Output location: .reports/resolve/<timestamp>/
/oss:release¶
Release communication and readiness pipeline with four modes: notes, prepare, audit, and demo.
Execution architecture β animated diagram of fans, joins and gates.
Purpose: Prepare release artifacts from a verified change range and audit readiness before a human tags or publishes the release.
Invocation:
/oss:release notes v1.2->HEAD # release notes from range
/oss:release notes --changelog # notes + CHANGELOG.md entry
/oss:release notes --summary # notes + internal summary
/oss:release notes v1.2->v2.0 --migration # notes + migration guide
/oss:release notes --changelog --summary --migration # all four outputs
/oss:release notes --append # integrate newly-landed commits into existing artifacts
/oss:release prepare v2.1.0 # full pipeline: audit β all artifacts
/oss:release audit # readiness check; does not tag or publish
/oss:release demo # story-telling notebook for the release
/oss:release demo v1.2->v2.0 # demo scoped to explicit range
Range notation: v1->v2 (e.g. v1.2->v2.0). Omit range β defaults to last-tag..HEAD. When newer stable tags exist off the branch's ancestry (patch releases cut from a maintenance branch such as release/latest), commits they already shipped are detected by patch equivalence and left out of notes, counts, contributors and breaking-change checks; commits matched only by PR number are kept and flagged for verification. Pre-release tags (rcN, devN, alphaN, betaN) are excluded from tag detection automatically.
PR discovery recovery uses UTC-bounded search dates. Capped or failed recovery remains a visible Confidence Gap for notes and prepare; associated PRs missing from the bounded list have their bodies fetched before classification. Promoted breaking changes require an inline waiver approval before downstream artifacts are written.
Modes and flags:
| Mode / Flag | What it produces |
|---|---|
notes |
Release notes (DRAFT.md, ending with a drafted-by line unless AI_RIG_FOOTER=off); add flags for extra outputs |
--changelog |
CHANGELOG.md entry (no shepherd review) |
--summary |
Internal summary saved to .temp/ |
--migration |
Migration guide for breaking, deprecated and removed items, each with a before/after snippet, saved to .temp/ (shepherd review) |
--append |
Rerun the pipeline scoped to newly-landed commits; integrate results into existing artifacts instead of a full regenerate |
prepare |
Full pipeline: audit β project CHANGELOG.md entry plus HIGHLIGHTS.md, MIGRATION.md, SUMMARY.md, DRAFT.md (ending with a drafted-by line), demo.py (closing drafted-by cell), and waived-changes.md under releases/<version>/; stops after the changelog if any doc still reads as unreleased |
audit |
Readiness checklist: tests green, changelog present, version bumped, no uncommitted changes, no docs still calling shipped work unreleased (blocker), doc proportionality for new features, no blocking upstream /oss:review verdict, changelog scope check, Codex adversarial pass (if codex plugin installed) |
demo |
Story-telling jupytext notebook (demo.py) highlighting the most significant contributions, following the repo-wide notebook standard in skills/_shared/notebook-style.md; ends with a drafted-by cell unless AI_RIG_FOOTER=off |
What each mode does:
| Primitive | notes |
prepare |
audit |
demo |
|---|---|---|---|---|
| Read git log + PRs | full | diff | full | full |
| Classify changes | β | β | - | β |
| Explore codebase | full | diff | full | diff |
| Shepherd voice review | β | β | - | - |
| DRAFT.md | write | write | - | - |
| CHANGELOG.md | --changelog |
write | - | - |
| SUMMARY.md | --summary |
write | - | - |
| MIGRATION.md | --migration |
writeΒΉ | - | - |
| HIGHLIGHTS.md | - | write | - | - |
| waived-changes.md | - | write | - | - |
| demo.py | - | writeΒ² | - | writeΒ² |
| Release mode (informational, never blocking) | - | β | β | - |
| Working tree | - | β | β | - |
| CI status | - | β | β | - |
| Open issues / PRs | - | β | β | - |
| Docs alignment | - | diff | full | - |
| Version consistency | - | β | β | - |
| CVEs | - | β | β | - |
| Upstream review verdict | - | β | β | - |
| Codex adversarial pass | - | β | β | - |
Flag mark = output produced only when flag passed. ΒΉ Full guide when breaking changes detected; single-line stub otherwise. Β² Jupytext percent-format Python script with # %% code cells and # %% [markdown] narrative cells; self-contained with references to additional resources.
Boundaries
- The skill does not choose or write a package version, create a git tag, or upload to PyPI/another registry; perform those project-specific steps yourself after reviewing the artifacts.
- Version consistency is checked in every flow.
notesalso classifies public breaking changes when codemap evidence is available; delegatedprepareandaudituse their gather classification without a codemap pass. - Each release invocation pins its published baseline, including the maintenance-line tag when applicable, for classification, migration examples and the final review. Breaking changes require verified prior public behavior and evidence it stopped working. Removal also requires published deprecation evidence. An unresolved baseline leaves Before claims unverified and without snippets. Skipping a needed Truth check lowers confidence.
- Shepherd review applies to release notes and migration guides; CHANGELOG entries and summaries are written directly.
Breaking-change classification in notes mode (codemap-gated):
- After the truth check, each diff-derived public symbol runs through
fn-rdeps --exclude-tests. A caller outside the symbol's top-level package proposes a move to β οΈ Breaking Changes, with external call sites as evidence. - The proposal needs a separate baseline check and item approval before the category or migration guide changes. Symbols with only same-package callers keep their human label.
- Requires a codemap v3 index β no index skips the phase. Partial coverage (
query_complete:false) is labeled possibly incomplete, never treated as exhaustive.
CHANGELOG section ordering (strict, enforced):
Deprecation tracking: uses pyDeprecate for the deprecation lifecycle. Migration guides include a before/after table with argument mapping for all renamed/removed parameters.
Waived changes. Every β οΈ Breaking Changes / β Removed / rename claim is checked against $LAST_TAG (the last published tag). A claim found to never have shipped under the claimed name is dropped from the public artifacts and logged instead β never silently discarded.
- Reclassified or removed Breaking claims, and codemap promotions from Added/Changed to Breaking, need item-by-item approval before artifacts are written.
- A valid β Removed claim stays when the old name existed at
$LAST_TAGand is absent atHEAD. - Python truth checks need the claim's exact module path; unknown paths, class methods, unmatched or unsupported forms stay inconclusive until source review.
- Each invocation gets its own
.temp/release-waived-<branch>-<date>-<suffix>ledger.preparerequires it and checks its claim count against the gather result before producingreleases/<version>/waived-changes.md; other modes leave the ledger in.temp/.
--append assumes an earlier notes run already produced DRAFT.md (and CHANGELOG.md/SUMMARY.md/MIGRATION.md when their flags were used) and reruns the pipeline for only the commits landed since then, tracked by a per-branch marker under .temp/release-state-v2/<branch-key>/.
- Results merge (never overwrite) into every existing artifact: DRAFT.md's Summary/Spotlights/Migration-guide/Notable-changes/Contributors, plus root-level
SUMMARY.md/MIGRATION.mdwhen their flags are set. A collapse guard fails closed (exit 1) against an accidental whole-file wipe. - Purely additive β except when a commit reverts or materially changes something a prior cycle wrote: that stale entry is struck or superseded, never left beside a contradicting new one. A genuine
git revertis resolved deterministically from a per-branch, patch-id-keyed provenance store (survives rewords, rebases and cherry-picks); a pivot with no revert commit relies on semantic judgment. - After merging, a re-validation pass re-runs the truth check, highlight ranking, migration-doc and docs validation against the final merged content.
- Routine
--appendadds increment bullets to DRAFT.md's Summary (and a paragraph to internal SUMMARY.md), re-folds the Summary to the top five wins with a one-lineNew since last draftpointer, and re-derives the release-wide upgrade-call line. - With no marker and no legacy state, the default
$LAST_TAG..HEADrange and a full overwrite establish a new baseline. An ambiguous legacy marker, provenance file, or journal stopsnotesand--appendbefore writes; migration needs an explicit decision and preserves the legacy bytes.
Notes publication safety
- Plain
notesandnotes --appendfreeze the checked-out branch, HEAD, range endpoints and local tag refs at gather. State is keyed by the exact raw branch ref and its SHA-256, so refs that once shared a slug have separate state. A tag change anywhere in the local repository requires a fresh gather. - Edits go to candidate copies of DRAFT.md, the changelog, provenance and the range marker; the flow seals the candidate bytes and repeats the full truth gate on the sealed set before publishing. A source change before staging or publishing stops publication; one during promotion triggers rollback to the exact original bytes.
- A per-branch journal resumes an interrupted multi-file promotion. An unknown live edit blocks recovery instead of being overwritten.
- Publication across files is not atomic: interruption can leave partial files with a pending journal. The marker publishes last, so a successful retry cannot repeat the same Summary increment.
- On POSIX, staged candidates, originals and each live replacement are synced before the journal is removed. Native Windows has no portable directory sync, so recovery from a host crash there is not guaranteed; ordinary interruption recovery still applies.
Output location: releases/<version>/ for prepare artifacts (the project CHANGELOG.md is updated at its discovered path and linked from the release directory); .temp/ for individual modes and demo on non-release branches. Prepare checks the selected release paths before delegated changelog editing and rechecks them before publication; linked source artifacts and linked append markers stop before writes.
/oss:setup¶
Purpose: Deliver this plugin's rules/*.md into Claude's user-level rule namespace. Maintenance command, not part of any OSS workflow.
When to use: after installing oss on a new machine, or after upgrading it. make sync-claude runs it automatically for every installed managed plugin that ships a setup skill, so a normal sync needs no manual step.
Invocation:
/oss:setup # interactive β asks before replacing anything it does not own
/oss:setup --approve # non-interactive β used by make sync-claude
- Each rule installs as a symlink at
~/.claude/rules/oss-<source-name>.md. Theoss-prefix keeps the flat rule namespace collision-free. - Before installing any link, setup checks every source rule: at most 1 MiB, valid UTF-8, no ASCII control characters except tabs and line endings, a
#Markdown heading, and closed frontmatter when present. Invalid content returns a codedRULE_*error with exit 1; no rule is installed or pruned. This structural check does not authenticate arbitrary prose. - Only one quality-gates variant is installed, at
oss-quality-gates.md: when a foundry-ownedfoundry-quality-gates.mdis already delivered it linksrules/quality-gates-delta.md(review-loop scope and output-routing only, shared obligations read from foundry's copy); otherwise it links the completerules/quality-gates.md, so a standalone install loses no rule. - Only links this plugin provably owns are replaced or removed. A real file, a link into another marketplace, a source checkout, or a dotfiles tree is reported as a conflict and left alone unless you approve replacing it.
Uninstall leaves rule links behind. Claude Code runs no cleanup hook on uninstall, so
~/.claude/rules/oss-*.mdsurvives bothclaude plugin uninstallandmake clear-all. Delete those symlinks by hand β once the plugin cache version is gone they dangle.
π€ Agents reference¶
| Agent | Model | Purpose |
|---|---|---|
oss:shepherd |
sonnet | Contributor reply drafts, triage recommendations, release coordination; triage reports β /oss:analyse |
oss:cicd-steward |
sonnet | GitHub Actions health: CI failures, build times, caching, SHA pinning, flaky tests |
oss:gh-scraper |
haiku | Internal: fetches raw GitHub data for /oss:analyse vitality |
oss:repo-warden |
haiku | Internal: scores vitality axis groups from the scraped data |
gh-scraper¶
Role: Raw GitHub data fetcher for /oss:analyse vitality. Fetches all GitHub API data (REST + GraphQL) in two sequential groups with parallel calls inside each and writes the raw JSONL consumed by oss:repo-warden. Reads GH_OWNER, GH_REPO and DATA_FILE from the caller's analyse-gh-owner, analyse-gh-repo and vitality-data-file session sentinels, never prompt assignments. Internal β spawned by vitality Step 1 only.
Model: haiku (mechanical data collection; every fetch, the assembly and the coverage check are bin/ scripts it runs verbatim)
What gh-scraper does:
- Runs all independent fetches in parallel (Group 1), then Group 2 on the repository's real default branch: README, CONTRIBUTING and SECURITY (root,
.github/ordocs/), the changelog's dated headings, workflow files, CODEOWNERS, branch protection flag and CI runs. - Scopes lists to what scoring reads: closed issues and PRs since the 30-day cutoff (truncated lists are flagged as lower bounds; GitHub search returns at most 1000 issues), one page of 100 completed default-branch CI runs, and the
archivedflag. - Assembles
raw-data-{owner}-{repo}-{date}.jsonlwith one record per dataset, truncation flags,"403"for unreadable security alerts and202_pendingfor contributor stats GitHub is still computing (no retry). Admin-only branch protection is expected to be absent and never lowers confidence. - Checks the file against the expected dataset list: a missing required dataset returns
status: "partial"withmissing_requiredand confidence capped at 0.70.
What gh-scraper does NOT do:
- Non-fetch requests run no commands and return only the error envelope. Missing, empty or unsubstituted
GH_OWNER,GH_REPOorDATA_FILEsentinel values return only the setup error envelope before authentication, API calls or output writes. - Axis scoring β
oss:repo-warden - Report generation, terminal output, adversarial review β
oss:analyse vitalitySteps 4β7 - Direct user invocation β always spawned by the vitality skill
repo-warden¶
Role: Axis scorer for /oss:analyse vitality. Reads pre-fetched raw JSONL from oss:gh-scraper, scores its assigned group of vitality axes per the scoring rubric, and writes a partial scores JSON for assembly. Spawned 3Γ in parallel by vitality Step 2 β not for direct user invocation.
Model: haiku (copies the extractor-computed band, score and confidence, then writes the signal and notes)
What repo-warden does:
- Scores one literal prompt
AXIS_GROUP(A: Axes 1,2,5,6 / B: Axes 4,7,8 / C: Axes 3,9). ReadsDATA_FILE,GH_OWNER,GH_REPOand the group'sPARTIAL_FILEfrom the caller'svitality-data-file,vitality-gh-owner,vitality-gh-repoandvitality-partial-a/b/csession sentinels; prompt assignments never override these values. - Extracts metrics with
vitality_extract.py(counts, dates, presence flags, ratios, bot filtering, and a met / unmet / indeterminate state per checkpoint). The extractor also computes each axis's band, in-band score and confidence, which repo-warden copies β two scorer models on the same data report the same numbers. It never opens the multi-megabyte JSONL directly. - Checkpoint axes score strictly: an unconfirmable checkpoint counts as unmet and its upper bound goes in the notes. Band-only axes put a boundary value in the better band, compared on unrounded metrics. Axis 9 (Trajectory) is capped at the band maximum in π‘/π΄ (π‘ 6, π΄ 3).
- CI test-step and security-scan detection counts only recognised test runners/scanners (tox, nox, hatch, npm/yarn/pnpm test,
python -m unittest,make test; zizmor, osv-scanner, gitleaks, trufflehog, pip-audit and similar) β never lint, docs, typing, build, publish or report environments. - The Axis 2 β abandonment override needs an archived repository or an explicit discontinuation statement about the repository itself (README banner, description, or the repo name as sentence subject) β never a bare keyword or a statement about something else (a branch, module, feature or flag).
- Axis 8 without Dependabot alert access: partial score from config signals, capped at the π‘ maximum 6, confidence 0.4. Axis 3 without contributor stats: bus factor = distinct non-bot
commits_50authors capped at 3, confidence 0.5. - Writes
partial-{group}-{owner}-{repo}-{ts}.jsonfor vitality Step 3 assembly.
What repo-warden does NOT do:
- Off-shape requests (missing or unsubstituted literal
AXIS_GROUP=A|B|C, missing/empty/unsubstituted session inputs, or thevitality-data-filesentinel not naming an existing raw JSONL) stop with only adeclinedenvelope and the reason; vitality surfaces it and stops before assembly - Raw data fetching β
oss:gh-scraper - Report generation, terminal output, adversarial review β
oss:analyse vitalitySteps 4β7 - Direct user invocation β always spawned by the vitality skill
oss:shepherd¶
Role: Public voice of the project. Owns all external-facing communication β PR replies, issue responses, release notes, changelog entries, migration guides. Never writes implementation code. When severity tiers overlap, picks the lower tier and names the trigger that would raise it.
Model: sonnet
Tools: includes Skill, used to invoke the humanizer skill; drafts stay draft-only and any GitHub write needs the user's gh-write approval.
When to use shepherd directly:
use shepherd to draft a response for issue #88, citing the contributing guide
use shepherd to review this changelog entry for tone before I post it
use shepherd to write a migration guide for the v3.0 breaking changes
What shepherd does:
- Triage recommendations: Classifies issues into seven archetypes (bug confirmed, feature request, question/support, duplicate, stale, out of scope, breaking change), drafts a response fitting each; thread triage reports and conversation analysis route to
/oss:analyse - Close-scenario replies: Seven close archetypes β fixed in release, fixed on
develop, superseded by architecture change, external/wrong repo, self-resolved/stale, keep open + relabel, superseded PR - PR review response: Drafts from a supplied
/oss:analysethread report or/oss:reviewreport, preserving findings and uncertainty. Two-part format β leads with what is genuinely good, then specific actionable asks with line references; never adversarial. Without a report, returns only the normal envelope withstatus: "blocked"and a one-line reason naming the report needed; never asks a prose question or drafts code-level feedback. - SemVer validation: Uses the supplied report for PR feedback, flags an incorrect bump type and breaking changes in a report block β code diff review routes to
/oss:review; the invoking skill or human decides whether to act before release - Release pipeline: Writes release notes, changelog entries, migration guides in consistent project voice
- Deprecation lifecycle: Works with
pyDeprecate; tracks deprecated APIs, writes migration guides, flags deprecation β warning β removal timeline violations
What shepherd does NOT do:
- Inline docstrings or API reference docs β use
foundry:doc-scribe - CI pipeline configuration or GitHub Actions YAML structure for publish/release workflows β use
oss:cicd-steward - Implementation code of any kind
Voice principles: lead with what's good; treat contributors as partners, never supplicants; cite specific conventions (contributing guide, coding style) when asking for changes; never adversarial or dismissive of effort.
oss:cicd-steward¶
Role: GitHub Actions health specialist. Owns CI configuration quality: workflow topology, runner strategy, caching, branch protections, flaky test detection. Reports ubuntu-latest drift only when the prompt names runner reproducibility.
Model: Sonnet (fast iteration on workflow YAML)
When to use cicd-steward directly:
use cicd-steward to reduce the build time in .github/workflows/ci.yml
use cicd-steward to diagnose the failing test matrix on PR #72
use cicd-steward to add SHA pinning to all actions in the workflow
What cicd-steward does:
- Diagnoses CI failures by failure type (linting, type errors, test failures, import errors, timeouts, OOM)
- Audits GitHub Actions workflow files for antipatterns (unpinned actions, missing concurrency groups, broken caching, wrong parallelism)
- Optimises build time toward targets: unit tests < 5 min, full CI < 15 min
- Enforces cache hit rate > 80% using
astral-sh/setup-uvwithuv.lock-keyed caching - Detects + quarantines flaky tests (target: 0% flakiness)
- Configures test matrices, reusable workflows, nightly upstream CI, performance regression benchmarks
SHA pinning enforcement (flagged as primary findings):
| Severity | Pattern | Example |
|---|---|---|
| Critical | Branch/named refs | uses: actions/checkout@main |
| High | Mutable version tags | uses: actions/checkout@v4 |
| Compliant | Full 40-char SHA | uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 |
Short SHAs (fewer than 40 hex chars) are treated as unpinned β they can collide and are not cryptographically safe.
What cicd-steward does NOT do:
- ruff/mypy rule selection or
.pre-commit-config.yamlauthoring β usefoundry:linting-expert(IS for CI workflow steps that invoke pre-commit, e.g.pre-commit/action@SHA) - PyPI release management, release notes, CHANGELOG entries, contributor communication β use
oss:shepherd - PyPI project registration, OIDC trusted publisher setup on pypi.org dashboard, GitHub environment configuration β use
oss:shepherd
Health targets:
| Metric | Target |
|---|---|
| Main branch | Green 100% of the time |
| Unit test suite | < 5 minutes |
| Full CI | < 15 minutes |
| Cache hit rate | > 80% |
| Flaky tests | 0% β any flaky test is quarantined immediately |
βοΈ Configuration¶
The blueprint and sentinel classifiers treat command-table names inside fixed ordinary quoted search operands as inert data. Command substitutions, variable writes and existing arithmetic-expression refusals remain checked. JavaScript classifiers also reject executing Git configuration and environment overrides consistently with the Python manifest generator. The sentinel module retains its narrower command whitelist. Blueprint matching preserves whitespace and literal hashes inside quoted values, including multiline values. A change in that data follows normal permission checks.
oss needs no required configuration β it reads project structure automatically.
PR-code execution safety: running a contributor's tests, hooks or an issue author's snippet is execution of untrusted code. /oss:review, /oss:resolve and the /oss:analyse reproduction step run it through bin/untrusted_code_guard.py:
- Scan and show evidence: the guard lists the files a test run loads on its own, scans what the contribution changed (credential reads, secret environment, exfiltration endpoints, dynamic execution, persistence, destructive commands, agent-instruction edits, hidden Unicode, files no rule can read) and reports dependency provenance. The user sees the evidence and risk level (
none,borderline,high,likely-malicious). Apip installhint inside a Python message or docstring is data, not a finding. Review skips the question after a clean scan of the exact PR head and then binds that exact head, so the guard refuses a run once the tree has moved or gained files; the record notes the run as automatic. Resolve also requires a clean review record for that head. The scan is a static heuristic. - Same-repo PRs skip the gate (resolve and review): when the PR's head branch lives in the repository itself (
isCrossRepositoryfalse, not a fork),/oss:resolveand/oss:reviewneither scan nor ask, and run tests directly in the checkout. A fork PR, or an unknown value, keeps the full gate. A/oss:resolverun with no PR (a report or comment run) runs its tests directly too, but only when the checked-out branch tracksoriginthrough a branch ref; a branch with no upstream (for example one fetched by hand from a pull ref), a fork branch left checked out by an earlier run, a detached HEAD or an unreadable answer keeps the gate. - Trust model: files the base ref already contains, and packages the base ref declares and the official index supplies, are trusted by name. Added packages, direct URL/VCS/path references, index overrides, lookalike names and changed lockfiles or
setup.pyare reported. - Contained run: the command runs in a disposable copy of the working tree with an environment allowlist and a temporary home. Where the host can start one (
sandbox-execon macOS,bwrapon Linux) the sandbox denies the network, confines writes to the copy and hides the real home except the interpreter and tools. Run without sandbox is offered beside the sandbox and Do not run on every question in/oss:review,/oss:resolveand the/oss:analysereproduction step (after a clean scan of the exact head, review applies it without asking, limited to that exact head; resolve then only skips its question and keeps the sandbox); it keeps the disposable copy and the cleared environment but drops containment, and is recorded as--tier env-only --decision unsandboxed. Without containment, code that was chosen to run, by the user or by a clean scan, can also rewrite this run's local state files (the clause and the same-repo answer), so the choice is only as safe as the PR. The Linux tier is covered by argument-construction tests only; it has not been run on a Linux host by this plugin's tests. - Limits: the command's output returns to the agent, so a secret the code can read can still leave through it. macOS system services other than the keychain daemons stay reachable. A suite that opens a loopback socket (
pytest-rerunfailures) fails inside the sandbox unless-p no:xdistis added or the parent re-asks with--allow-loopback(macOS only).
Model and cost: analyse, review, resolve and release carry no model: pin and run on the session model. A pin on an inline skill swaps the model for one turn and back, which rewrites the whole cached prompt prefix twice β measured at about $1.4 to $1.5 per /oss:resolve run in an Opus session. Start these sessions on Sonnet for the cheap path; an Opus session now saves about $0.4 per resolve run and keeps Opus quality. Measure a skill with /foundry:audit --efficiency.
GitHub authentication: skills use the gh CLI. Run gh auth login once if not already.
Permission manifests: .claude-plugin/permissions-allow.json lists the tool calls the skills expect to be pre-approved; .claude-plugin/permissions-deny.json lists operations that stay denied no matter how broad the allow list becomes.
- Deny covers destructive shell and git commands (
rm -rf,sudo,ssh,chmod 777, force-push,claude --dangerously-skip-permissions) and thecurlwrite verbs the broadBash(curl:*)allowance would otherwise reach. Deny entries are prefix matches, so they stop the documented command forms rather than every possible flag ordering. /oss:setup(Step 5) merges both files into~/.claude/settings.jsonadditively and idempotently.- It also removes allow entries earlier oss versions shipped (listed in
.claude-plugin/permissions-allow-retired.json, applied through--drop-allow-file):Bash(gh api repos/*:*),Bash(uv pip install:*);- the broad
Bash(claude:*),Bash(find:*),Bash(node:*),Bash(sed:*)andBash(eval:*); - the former PR-number
sed -nEgrant whose regex*read as wildcards (bin/extract_review_pr.pyreplaces it).
- Retirement matches exact rule text, so an identical user-authored entry is removed too.
- Every other existing allow and deny entry is preserved.
- No shipped allow entry matches
uv pip install,uv run --with,pip installorpip download, so the review's dependency overlay downloads each reach their own permission prompt.
Git/GitHub permissions
- oss ships no git/gh guard; the guard ships only in
foundry(requiresfoundryplugin). - The OSS allow list omits
Bash(gh api repos/*),Bash(gh api graphql:*),Bash(git branch:*)andBash(git tag:*), so a fresh standalone install leaves API writes and local branch/tag deletion to normal permission handling. - Existing settings keep these four allow entries after an upgrade:
/oss:setuppreserves them because foundry also ships them. - Without foundry, remove those entries from your settings to restore normal prompts for these operations.
- Stale gh deny entries from older versions are scrubbed only by
/foundry:setup(requiresfoundryplugin).
Codemap behaviour:
- Structural queries need the
codemap-pyplugin; an unavailable CLI or local contract falls back to plain file reads. Codemap index-gate guidance ships inside oss itself. - Missing or stale index preparation follows the active provider contract automatically by default; explicit
LAZY_CODEMAP(confirm-first) andSCAN_NO_AUTOBUILD=1(frozen index) preferences stay controlling. - Review and resolve reuse a prior fresh, matching structural answer instead of re-querying. Source and test-quality review is still always performed.
--no-codemapdisables structural lookup but keeps heuristic test plans and required verification.
Optional plugin integrations are detected automatically at runtime. Install any from Install β skills use them next invocation, no config changes.
Rules ship in rules/ and are linked into ~/.claude/rules/ by /oss:setup:
| Rule | Purpose |
|---|---|
quality-gates.md |
Complete quality gates (evidence, confidence, review loop, output routing); installed standalone |
quality-gates-delta.md |
Review-loop scope and output routing only; installed when foundry's quality gates are present |
_full/adversarial-loop.md |
Detailed review β fix loop procedure the quality gates require |
Progress tables come only from the ledger helper and include reconciliation of previous dispositions and current carried, repeat-route and new findings for all tiers and security. Old means a known invariant, including closed history, rather than only previous-row carryover. Reviews run before a ledger are disclosed as pre-ledger prose, never invented table rows. Repeated review/fix requests, a second independent review of the same change, or a repeated skill review/fix cycle activate the full loop before the next reviewer dispatch, with its stop rules and user-set round budget.
Hooks register automatically from hooks/hooks.json when the plugin is enabled β no settings.json edits needed.
Executable helper blocks resolve and export PLUGIN_ROOT before calling python "$PLUGIN_ROOT/bin/<script>.py". Loaders render the plain bootstrap token in modes and templates to the validated owning-plugin path. The blueprint hook checks the bound source template and exact rendered command; altered commands still use normal permission checks, and deny rules remain effective. Run these examples from a host-substituted or loader-rendered copy; an ordinary shell does not supply the bootstrap token.
- Each hook runs
nodefrom PATH, then/opt/homebrew/bin/nodeor/usr/local/bin/node; when none exists, the hooks skip without blocking and oneSessionStartcheck reports once per session that they are inactive. - The plugin's
bin/python(native Windowsbin/python.cmd) probes for a Python 3.10+ runtime before executing a workload; an eligible systempythontakes precedence, and a missing runtime produces a clear diagnostic.
| Hook | Event | Purpose |
|---|---|---|
agent-router.js |
PreToolUse (Agent) |
Reroutes Agent() calls when the requested agent is not installed: exact β semantic match β general-purpose |
allow-dispatch.js |
PreToolUse (Bash) |
Sole Bash auto-allow hook; asks the two decision modules below and emits the first allow, with an audit record |
blueprint-allow.js |
decision module of allow-dispatch.js |
Allows verbatim bash blocks shipped in this plugin's skills (exact match against its blueprint manifest) |
sentinel-read-allow.js |
decision module of allow-dispatch.js |
Allows pre-canned sentinel-read and $(date +FMT) idioms in read-only commands, so no "Contains expansion" prompt |
audit-close.js |
PostToolUse, PostToolUseFailure, session start/end |
Records Bash completions in the auto-allow audit log |
audit-log.js |
shared module | Append-only record writer behind the audit hooks; RIG_AUDIT=0 disables writing |
write-guard.js |
PreToolUse (Edit, Write, NotebookEdit) |
Confirms writes to untracked protected files (CLAUDE.md/AGENTS.md, .claude/settings*.json, .pre-commit-config.yaml, pyproject.toml) |
stale-plugin-check.js |
SessionStart |
Warns when the session runs a replaced oss version and asks whether to restart or continue |
enforce-review-header.js |
PreToolUse/PostToolUse (AskUserQuestion), Stop |
Holds the review follow-up until the report exists and its header table is shown |
enforce-analyse-header.js |
PreToolUse/PostToolUse (AskUserQuestion), Stop |
Stop only for /oss:analyse: its final reply must carry the matching header table |
enforce-resolve-table.js |
PreToolUse (AskUserQuestion) |
Blocks the resolve bulk picker until it lists every pending item (or top items plus counts and table path) |
report-header-table.js |
shared module | Matches workflow questions and report headers for the two header gates |
Cache location: .cache/gh/ at project root. Cached responses: 30-day TTL. Force a fresh fetch by deleting the relevant cache file or the whole .cache/gh/ directory.
Artifact directories created by oss skills (all gitignored):
| Directory | Created by | Contents |
|---|---|---|
.reports/analyse/ |
/oss:analyse |
Thread, vitality, ecosystem reports |
.temp/review/ |
/oss:review |
Per-agent handover files (intermediate, per-run) |
.reports/resolve/ |
/oss:resolve |
Resolve run outputs |
.temp/ |
All skills | Long-form output files |
.cache/gh/ |
/oss:analyse |
GitHub API response cache |
releases/<version>/ |
/oss:release prepare |
Release artefacts |
Auto-allow audit log. allow-dispatch.js and audit-close.js append one JSON line each per Bash call to ~/.claude/logs/audit/ (one file per session, plus _no-session.jsonl for calls without a session id). A record names the deciding plugin and hook, the effective decision and its lane, and both decision modules' verdicts. Command text is never written β only a digest. With several plugins installed each writes its own rows, so one call yields one row per plugin.
PLUGIN_ROOT=$(python "${CLAUDE_PLUGIN_ROOT}/bin/resolve_plugin_root.py" --plugin-name oss) || exit $?; export PLUGIN_ROOT
python "$PLUGIN_ROOT/bin/verify_blueprint_audit.py" verify
python "$PLUGIN_ROOT/bin/verify_blueprint_audit.py" prune --older-than 30 --dry-run
verifyexits 1 only when a record's own hash fails; torn framing from concurrent appends and every classification are warnings.record_hashdetects a record changed after writing; it is not tamper-evidence. A call that ran never establishes that a human approved it.pruneis the only component that deletes log files, is never run by a hook, and nothing schedules it.RIG_AUDIT=0disables audit writing without changing any permission decision.
Records follow the twelve mandatory fields of "Agent Audit Trail: A Standard Logging Format for Autonomous AI Systems", an active individual-submission Internet-Draft that is not endorsed by the IETF and has no standing in its standards process.
Deliberate deviations: outcome adds pending; trust_level is plugin/unknown; agent_id is <plugin>/<hook>; session_id is the host's id verbatim; parent_record_id and prev_hash are always null because the log is not chained.
π§° Bin helper inventory¶
The plugin ships 68 deterministic helpers in bin/. They are installed workflow support, not additional slash-command skills: the skills own orchestration, the helpers handle bounded parsing, evidence collection, path resolution, scoring, and artifact preparation. Only the groups matter at user level:
| Group | What the helpers cover | Examples |
|---|---|---|
| Analysis and vitality | GitHub data fetching, vitality assembly/scoring, thread-type and PR-scope classification, codemap detection and batching | fetch_gh_data_group1.py, assemble_vitality_scores.py, classify_pr_scope.py |
| Review and resolve | PR intel fetch, finding ids, action-item merge, commits, fork/remote handling, test planning, grouped-commit replay, end-of-run remote and leftover checks, report stub, worktree cleanup, git state | fetch_pr_intel.py, merge_action_items.py, resolve_test_plan.py, git_state_snapshot.py, resolve_group_replay.py, resolve_remote_state.py, resolve_leftovers.py, resolve_report_stub.py |
| Release and install | Range/contributor extraction, release directory and marker handling, audit evidence, unreleased-leftover doc scan, rule-link install, permission merge | release_append_publish.py, run_audit_checks.py, scan_unreleased_leftovers.py, sync_rules.py |
| Loop and session support | Review β fix loop ledgers, append-only ledgers, compaction contracts, agent deadline checks, auto-allow audit verification | adversarial_loop.py, append_ledger.py, agent_watch.py, verify_blueprint_audit.py |
| Untrusted code | Contributor-code scan, approval binding and the contained runner for PR tests and issue snippets | untrusted_code_guard.py |
π Troubleshooting¶
/oss:review skips Tier 2 agents
Review dimensions are scope-selected and the default fan-out is capped. Install foundry for specialized agents; otherwise the selected work uses general-purpose fallbacks. Install bridge@borda-ai-rig only if you want optional Codex co-review.
A question is blocked with "oss:review report gate"
The gate holds only the owning workflow's follow-up until its report and matching current-turn header table are verified. Diagnostic/recovery questions remain available. Finish the producer, print the required current output, then retry the follow-up.
/oss:review uses general-purpose agents instead of specialist agents
foundry plugin not installed or not detected. Install: claude plugin install foundry@borda-ai-rig. All skills degrade gracefully to general-purpose agents when foundry is absent.
/oss:resolve pauses mid-run asking for confirmation
It should not on the normal path: every decision (items, commit mode, grouping, dispatch width, push intent, post-PR action) is asked at the item-selection gate, and the push itself is confirmed at the end unless you chose "don't push". A later question means one of:
- you chose
Customdispatch (group preview); - an item's status could not be confirmed;
- you left the push question unanswered at the gate;
- the recorded push answer or typed labels were lost (for example after resuming in a fresh session).
A git push permission prompt or push-guard message comes from your harness or another plugin, not from resolve.
/oss:resolve aborts with "too many conflicted files"
More than 20 files have semantic conflicts. Resolve aborts rather than guessing intent at scale. Review the conflict list in the output, resolve the most complex manually, then re-run resolve on the remainder.
/oss:release reports a version or release-state problem
The readiness audit found a version-consistency or release-state gap. Review the audit table, update the project manifest/changelog as appropriate, and re-run /oss:release audit [version]; this skill does not edit package versions for you.
/oss:analyse returns stale data
Cached GitHub API responses are served from .cache/gh/. Delete the cache file for the thread number, or clear .cache/gh/, for a fresh fetch.
Skills not found after install
Run claude plugin install oss@borda-ai-rig again, then /reload-plugins in Claude Code.
π Related articles¶
- How I Streamlined OSS Maintenance With AI β Guardrails, Speed, and a Shepherd's Touch (CodeX, Jun 2026): specialist agents for triage, review, and release, with every output human-gated.
- The Open-Source Shepherd: Why Your Best Work Is Building a Project That Doesn't Need You (CodeX, Jun 2026): growing contributors and shared ownership in open-source projects.
π Contributing / feedback¶
oss is part of the Borda-AI-Rig plugin suite. Contribute or report issues:
- Bugs and feature requests: open an issue in the Borda-AI-Rig repository
- Plugin authoring rules: see
plugins/CLAUDE.mdβ file layout, naming conventions, cross-plugin references, README sync requirements, versioning policy - Voice and tone: all contributor-facing text follows the same principles as
oss:shepherdβ welcoming, specific, treats contributors as partners
Contributing or want internals? See DEVELOPMENT.md.
Editing oss skills or agents β update this README before commit (changed trigger, scope, NOT-for, or hook behaviour; added/removed agent or skill). Unsynced change = incomplete.