Borrowing it
Nothing to install: this file belongs to ZhangHanDong/agent-spec. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/ZhangHanDong/agent-spec/main/.claude/skills/agent-spec-authoring/SKILL.mdgit clone --depth 1 https://github.com/ZhangHanDong/agent-specWrote 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.
[](https://agentmods.dev/skills/zhanghandong/agent-spec/agent-spec-authoring)<a href="https://agentmods.dev/skills/zhanghandong/agent-spec/agent-spec-authoring"><img src="https://agentmods.dev/badge/skills/zhanghandong/agent-spec/agent-spec-authoring/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.
<a href="https://agentmods.dev/skills/zhanghandong/agent-spec/agent-spec-authoring"><img src="https://agentmods.dev/badge/skills/zhanghandong/agent-spec/agent-spec-authoring.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector warn
SkillSpector: 1 finding, up to high
These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →
- high Memory Poisoning · line 149 Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.Fix: Protect agent memory and state from modification by untrusted content. Use read-only memory for critical instructions and validate all state changes.
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00172 | $0.04303 |
| Opus 5 | $0.00086 | $0.02152 |
| Sonnet 5 | $0.00034 | $0.00861 |
| Haiku 4.5 | $0.00017 | $0.00430 |
Grade A, and why
agent-spec-authoring 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 10d 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.
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.
How it starts
The opening of the file, as written. The whole thing — 452 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Agent Spec Authoring
Version: 3.2.0 | Last Updated: 2026-03-19
You are an expert at writing agent-spec Task Contracts. Help users by:
- Creating specs: Scaffold new
.spec.mdfiles with correct structure (.specalso supported) - Editing specs: Improve intent, constraints, boundaries, scenarios
- Writing scenarios: BDD-style with proper test selectors and step tables
- Debugging specs: Fix lint warnings, improve quality scores
- Self-hosting: Maintain specs for the agent-spec project itself
IMPORTANT: CLI Prerequisite Check
Before running any agent-spec command, Claude MUST check:
command -v agent-spec || cargo install agent-spec
If agent-spec is not installed, inform the user:
agent-specCLI not found. Install with:cargo install agent-spec
Core Philosophy
A Contract is not a vague Issue — it's a precise specification that shifts the review point:
Traditional: Human reviews 500 lines of code diff (slow, error-prone)
agent-spec: Human writes 50-80 lines of Contract (fast, high-value)
Machine verifies code against Contract (deterministic)
Writing a Contract is the highest-value human activity in the agent-spec workflow. You're defining "what is correct" — the machine handles "is the code correct".
Quick Reference
| Section | Chinese Header | English Header | Purpose |
|---|---|---|---|
| Intent | ## 意图 |
## Intent |
What to do and why |
| Constraints | ## 约束 |
## Constraints |
Must / Must NOT rules |
| Decisions | ## 已定决策 / ## 决策 |
## Decisions |
Fixed technical choices |
| Boundaries | ## 边界 |
## Boundaries |
Allowed / Forbidden / Out-of-scope |
| Acceptance Criteria | ## 验收标准 / ## 完成条件 |
## Acceptance Criteria / ## Completion Criteria |
BDD scenarios |
| Out of Scope | ## 排除范围 |
## Out of Scope |
Explicitly excluded items |
Hard Syntax Rules
- Use exactly one supported section header per line. Good:
## Intentor## 意图. Bad:## Intent / 意图. - Write scenarios as bare DSL lines under the acceptance section. Good:
Scenario:/场景:. The parser accepts Markdown-heading forms like### Scenario:for compatibility, but authoring should avoid emitting them by default. - Do not invent extra top-level sections such as
## Architecture,## Milestones, or## Qualityinside a task spec. Put that information intoIntent,Decisions,Boundaries, or an external document. - After drafting or editing a spec, always run
agent-spec parse <spec>and thenagent-spec lint <spec> --min-score 0.7.
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.
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.
- 10d ago First seen · 452 lines · 172 tokens per session scan A c447e62667a7
agent-spec-authoring is a skill published in the GitHub repository ZhangHanDong/agent-spec (454 stars, last pushed 11d ago), licensed MIT. It adds 172 tokens to every session and 4,303 once invoked, about $0.0009 per session on Opus 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.
Other skills, from other repositories
comet-native
A workflow for managing Native changes in Comet, where requirements, progress, and acceptance results are saved in project files. It uses the Comet command-line runtime to move through defined work stages.
subagent-driven-development
Use when executing implementation plans with independent tasks in the current session.
comet
Comet — OpenSpec + Superpowers dual-star development workflow. Start with /comet for automatic phase detection and dispatch to subcommands. Five phases: open → design → build → verify → archive.
comet-design
A workflow guide for turning an existing software change into a detailed technical design document. It builds on earlier proposal and design files and defines implementation risks, tests, and edge cases.
comet-hotfix
A quick workflow for fixing an existing bug in Comet, a tool that manages structured code changes. It moves through opening the change, building, checking, and archiving it.
comet-verify
A workflow for verifying a Comet change after its coding tasks are complete. Comet is a tool that tracks structured software changes through stages.