agent-contract

agent-contract is a skill for Claude Code from MichaelYcJo/SpecSeal. It costs 147 tokens per session (3,190 once invoked), scanned A, original, MIT.

A shared rulebook for agents created by the SpecSeal plugin. It defines common requirements for roles such as smith, warden, and scribe, while task-specific instructions remain in each agent's prompt.

In plain words
What is it for?
Use it when writing or maintaining SpecSeal agents, their orchestration procedures, and the contracts that govern their behavior.
Why use it?
It keeps essential rules consistent across all spawned agents instead of relying on each role or session to repeat them.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter.

Part of the specseal plugin — 23 skills, 3 agents, 3 hooks shipped together

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.

agentmods
npx agentmods add skills/michaelycjo/specseal/agent-contract
Any agent
npx skills add MichaelYcJo/SpecSeal --skill agent-contract
Clone the repo
git clone --depth 1 https://github.com/MichaelYcJo/SpecSeal

Made for: Claude Code.

Or install specseal, the plugin that ships this one along with the rest of its 23 skills, 3 agents, 3 hooks.

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 agent-contract

README.md
[![agentmods](https://agentmods.dev/badge/skills/michaelycjo/specseal/agent-contract.svg)](https://agentmods.dev/skills/michaelycjo/specseal/agent-contract)
Your own site
<a href="https://agentmods.dev/skills/michaelycjo/specseal/agent-contract"><img src="https://agentmods.dev/badge/skills/michaelycjo/specseal/agent-contract.svg" alt="Measured on agentmods" height="20"></a>
Per session 147 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,190 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
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.00147 $0.03190
Opus 5 $0.00073 $0.01595
Sonnet 5 $0.00029 $0.00638
Haiku 4.5 $0.00015 $0.00319

Measured 2d ago against content hash cb30b1f690c6, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

agent-contract scanned grade A with 1 finding 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 2d ago.

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.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

Prefer `subprocess.run(["git", "-C", d, "commit", …])` from a Python script:
skills/agent-contract/SKILL.md · 261 lines

How it starts

The opening of the file, as written. The whole thing — 261 lines — stays where its author put it; the contents beside it link to each section on GitHub.

agent-contract — what every agent this plugin spawns is bound by

You received this file at startup, before your first tool call, and nobody typed a command to send it. Its sections are the rules that are true of any agent — smith, warden, scribe, and whichever arrives next — and nothing here is one agent's own. A role's rules live in that role's definition, which is the file its author is already writing. A rule that belongs to one agent does not belong here, and a section that would need a per-role exception is a sign the rule is not universal.

Your spawn prompt carries what is specific to the round: the branch and the target SHA, what the diff contains, the acceptance criteria, the class to enumerate for this change, the corrections the orchestrator has to hand over. It does not carry these rules, and it never has to. A rule kept only in whoever last wrote a prompt goes missing without a trace, and it did: the exit-code rule below arrived at round 2 of one work item and round 1 ran without it, and the uv venv line arrived at round 3 after two rounds each rediscovered it. Nothing recorded either. This file is what ends that.

The procedures — implement, code-review, legacy-parity — say how a role does its work. This file says what binds regardless of which procedure is running, and it is the one a prompt can cite by number.

How the sections are numbered

A section number is never reused and never re-ordered. A prompt can say §3 is narrowed this round and a round record can be compared with another one six months later, which holds only while §3 still means what it meant. A rule that retires keeps its number, and its section becomes one line naming what replaced it. A new rule takes the next number, at the end.

§1 Read exit codes directly, never through a pipe

cmd >/dev/null 2>&1; echo $? — never cmd | tail; echo $?, which reports the pipe's status and is always 0.

Both forms are written out on purpose. The failure is a habit, so the right form has to be as easy to copy as the wrong one. An orchestrator that had put this line into every prompt it wrote then broke it itself and committed the wrong value.

Read the full file on GitHub · 261 lines

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. 2d ago First seen · 261 lines · 147 tokens per session scan A cb30b1f690c6

Subscribe to this mod's changes

agent-contract is a skill published in the GitHub repository MichaelYcJo/SpecSeal (1 stars, last pushed yesterday), licensed MIT. It adds 147 tokens to every session and 3,190 once invoked, about $0.0007 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

chat-pet-sprite-creation

Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.

microsoft/vscode · 53 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens

insight-error-page

Write or audit an insight-kind error page for the Next.js dev overlay. Use when creating a new errors/ .mdx page, auditing an existing one, or checking that a page matches the framework fix cards. Covers page structure, title alignment, FixCard cards with Copy prompt button, code snippets, terminology verification…

vercel/next.js · 83 tokens