ak-dev-write-spec

A staged documentation process for planning a change to Agent Kernel, a software project. It produces a design document, a detailed implementation specification, and an implementation plan in that order.

In plain words
What is it for?
Use it to create planning documents under docs/specs/ before implementing an Agent Kernel issue. The design is reviewed first, followed by the detailed specification and then the step-by-step plan.
Why use it?
It separates human review of the proposed design from detailed technical planning. This prevents extensive implementation details from being written for a design that may later change.

Skill for Claude CodeCodex

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/yaalalabs/agent-kernel/ak-dev-write-spec
Any agent
npx skills add yaalalabs/agent-kernel --skill ak-dev-write-spec
Clone the repo
git clone --depth 1 https://github.com/yaalalabs/agent-kernel

Made for: Claude Code, Codex.

Per session 143 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,145 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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 $0.00143 $0.05145
Opus 5 $0.00072 $0.02573
Sonnet 5 $0.00029 $0.01029
Haiku 4.5 $0.00014 $0.00515

Measured 2d ago against content hash 483dadb3ddc1, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

ak-dev-write-spec 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 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.

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.

.agents/skills/ak-dev-write-spec/SKILL.md · 316 lines

How it starts

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

Write a Spec for a Planned Change

Use this skill when asked to produce spec documents for Agent Kernel work before (or instead of) implementing it. A change is specified in three documents, written in strict order, all under docs/specs/<issue-number>-<short-title>/:

Stage File What it is Written when
1 design.md Concise, point-form, hierarchical requirements — what changes and why First, before anything else
2 spec.md Detailed design and implementation components, following the approved design Only after design.md has been reviewed and optimized through review cycles
3 plan.md Concise breakdown of the implementation into iterations/steps Only after both design.md and spec.md are done

Do not skip ahead. design.md is the document humans review — it must exist and survive its review cycles before effort goes into spec.md. Writing a detailed spec against an unreviewed design wastes the detail work when the design changes.

The same directory may optionally hold a research/ subfolder — the supporting investigation that informed the design (provider surveys, prior-art comparisons, benchmarks, spike notes). It is not a fourth stage and not required; see Optional: research/.

This skill is for writing these documents, not for implementing the change they describe.

Which Stage Are You In?

Route from what the requester asked for and what already exists in docs/specs/<issue-number>-<short-title>/:

  • No design.md yet, or the request is "write a spec/design for X" → Stage 1: write design.md and stop there.
  • design.md exists and the requester says it is reviewed/approved (or asks for the implementation spec) → Stage 2: write spec.md.
  • design.md and spec.md both exist and the requester asks for the plan/breakdown → Stage 3: write plan.md.
  • Asked to update an existing document → update that document; if the update changes requirements in design.md, flag that downstream spec.md/plan.md need re-alignment.
  • Asked to capture or record research — a provider survey, a prior-art comparison, a benchmark, a spike — → write it under research/ (optional; see Optional: research/). This can happen before design.md exists and does not, on its own, start Stage 1.

Read the full file on GitHub · 316 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 · 316 lines · 143 tokens per session scan A 483dadb3ddc1

Subscribe to this mod's changes

ak-dev-write-spec is a skill published in the GitHub repository yaalalabs/agent-kernel (145 stars, last pushed 5d ago), licensed Apache-2.0. It adds 143 tokens to every session and 5,145 once invoked, about $0.0007 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.