pr-shepherd-contract

pr-shepherd-contract is a skill for Claude Code, Codex from sonichi/sutando. It costs 53 tokens per session (446 once invoked), scanned A, original, MIT.

A GitHub-specific contract for waiting on a pull request event, such as a merge or closure, and resuming the work later. A pull request is a proposed code change submitted for review.

In plain words
What is it for?
Observing a pull request, identifying the author of its latest non-merge commit, and saving or resuming the waiting task under a workspace.
Why use it?
It preserves what the task is waiting for and who is responsible, even if another process continues it later.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Observing a pull request, identifying the author of its latest non-merge commit, and saving or resuming the waiting task under a workspace.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/sonichi/sutando/pr-shepherd-contract
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add sonichi/sutando --skill pr-shepherd-contract
Clone the repo
git clone --depth 1 https://github.com/sonichi/sutando

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pr-shepherd-contract

README.md
[![agentmods](https://agentmods.dev/badge/skills/sonichi/sutando/pr-shepherd-contract/github.svg)](https://agentmods.dev/skills/sonichi/sutando/pr-shepherd-contract)
Your own site
<a href="https://agentmods.dev/skills/sonichi/sutando/pr-shepherd-contract"><img src="https://agentmods.dev/badge/skills/sonichi/sutando/pr-shepherd-contract/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for pr-shepherd-contract

Your own site · 80×15
<a href="https://agentmods.dev/skills/sonichi/sutando/pr-shepherd-contract"><img src="https://agentmods.dev/badge/skills/sonichi/sutando/pr-shepherd-contract.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 446 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00053 $0.00446
Opus 5.5 $0.00021 $0.00178
Sonnet 5.5 $0.00011 $0.00089
Haiku 4.5 $0.00005 $0.00045

Measured 3mo ago against content hash cb506c9d4b61, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

pr-shepherd-contract scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3mo ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/shepherd_github.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/pr-shepherd-contract/SKILL.md · 43 lines

What it actually says

PR Shepherd Contract (GitHub adapter)

The GitHub binding for the provider-neutral shepherd contract (src/shepherd_contract.py). The contract defines WHAT a shepherd task is responsible for and WHICH observed events count; this skill supplies the GitHub-specific half:

  • Observation — observe(repo, number) reads live PR state via the GitHub CLI (gh api) and emits one ObservedEvent (merged / closed unmerged / updated).
  • Actor resolution — resolve_actor(repo, number) uses the last non-merge commit's author email (git.commit_author_email), not the account login, because several actors can push under one login.
  • Persistence — save(task_id, scope, state) / load(task_id) / resume(task_id) keep the durable contract record under <workspace>/state/shepherd/, create-or-advance only (never rebind), so a different process can pick the objective up later.

Usage

Import from the skill's scripts directory (the module bootstraps src/ onto sys.path itself):

import sys, pathlib
sys.path.insert(0, str(repo_root / "skills" / "pr-shepherd-contract" / "scripts"))
import shepherd_github as g

scope = g.scope_for("owner/repo", 123, g.resolve_actor("owner/repo", 123))
g.save("task-abc", scope, "waiting", "shepherding PR 123")
# ... later, any process:
state, why = g.resume("task-abc")

Tests: tests/shepherd-github-durability.test.py, tests/shepherd-github-integrity.test.py (contract policy itself: tests/shepherd-contract-admission.test.py).

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3mo ago First seen · 43 lines · 53 tokens per session scan A cb506c9d4b61

Subscribe to this mod's changes

pr-shepherd-contract is a skill published in the GitHub repository sonichi/sutando (413 stars, last pushed today), licensed MIT. It adds 53 tokens to every session and 446 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

pr-shepherd-contract compared with skills from other repositories

pr-shepherd-contract next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
pr-shepherd-contractsonichi/sutandoSkill413todayMITA53Claude Code, Codex
gmailvellum-ai/vellum-assistantSkill1.5k6d agoMITA20Claude Code, Codex
app-buildervellum-ai/vellum-assistantSkill1.5k6d agoMITA162Claude Code, Codex
assistant-migrationvellum-ai/vellum-assistantSkill1.5k6d agoMITA90Claude Code, Codex
guardian-verify-setupvellum-ai/vellum-assistantSkill1.5k6d agoMITA26Claude Code, Codex
stripe-link-walletvellum-ai/vellum-assistantSkill1.5k6d agoMITA52Claude Code, Codex
vellum-memory-v2-migrationvellum-ai/vellum-assistantSkill1.5k6d agoMITA34Claude Code, Codex