From claude-code-config
Scaffolds a feature narrative document in an existing layer following the ULTRAPACK-style template with Design/Plan/Verify/Conclusion sections. Auto-allocates F-NNN IDs and updates layer README and feature_list.json.
How this skill is triggered — by the user, by Claude, or both
Slash command
/claude-code-config:feature-newsonnetThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Creates a feature document in an existing layer. The document follows
Creates a feature document in an existing layer. The document follows the ULTRAPACK-style narrative template (Design / Plan / Verify / Conclusion) extended with explicit cross-references to layer invariants and global principles.
/feature-new <layer> <slug> [--title "..."] [--branch <name>] [--id F-NNN]
<layer> -- existing layer name. Must be a directory under
docs/layers/. If missing, suggest /layer-new <layer> first.<slug> -- kebab-case feature identifier without the F-NNN-
prefix. Examples: api-key-rotation, audit-log,
dual-encryption.--title -- human-readable feature title. If omitted, derive from
slug by title-casing.--branch -- git branch name. If omitted, default to
feature/<slug>.--id -- override the auto-allocated F-NNN. Use only when
migrating a pre-existing feature with a known ID. Refuse if the ID
already exists in this layer.git rev-parse --show-toplevel.docs/layers/<layer>/ exists. If not, refuse with a
suggestion to run /layer-new <layer> first.docs/layers/<layer>/features/_FEATURE-TEMPLATE.md
exists. If not, copy from
<claude-code-skills-checkout>/templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE/features/_FEATURE-TEMPLATE.md.If --id was provided:
F-\d{3,}).docs/layers/<layer>/features/feat-<NNN>-*.md does not already
exist. Refuse if it does.If --id was NOT provided:
[a-z][a-z0-9-]*).f- or feat- (avoid double-prefix).feat-<NNN>-<slug>.md does not already exist.Source: docs/layers/<layer>/features/_FEATURE-TEMPLATE.md
Destination: docs/layers/<layer>/features/feat-<NNN>-<slug>.md
In the new file, replace placeholders:
| Placeholder | Replacement |
|---|---|
F-NNN: <feature title> | F-<NNN>: <title> |
**Layer:** [<layer-name>](../README.md) | **Layer:** [<layer>](../README.md) |
**Status:** design | leave as design |
**Branch:** feature/<slug> | use --branch value or default |
**Started:** YYYY-MM-DD | today's date |
**Owner:** <name> | infer from git config user.name, or leave placeholder |
Leave Design / Plan / Verify / Conclusion section bodies as template placeholders -- the user fills these.
In docs/layers/<layer>/README.md, find the ## Features in this layer table. Insert a new row at the bottom (sorted by F-NNN
ascending):
| F-<NNN> | <title> | design | YYYY-MM-DD | [feat-<NNN>-<slug>.md](features/feat-<NNN>-<slug>.md) |
If the table has only the placeholder rows from the template, replace them entirely with the real entry.
If <repo>/feature_list.json exists at repo root, parse it and
append a new feature entry:
{
"id": "F-<NNN>",
"name": "<title>",
"layer": "<layer>",
"doc": "docs/layers/<layer>/features/feat-<NNN>-<slug>.md",
"branch": "feature/<slug>",
"status": "not-started",
"dependencies": [],
"evidence": []
}
Important encoding rule (per
~/.claude/rules/api-utf8-posting.md): write the JSON file with
json.dump(data, f, ensure_ascii=False, indent=2) to preserve any
Cyrillic in titles.
Do NOT change existing entries.
If feature_list.json does not exist, do not auto-create it -- emit
a hint instead.
Print a summary:
Created: docs/layers/<layer>/features/feat-<NNN>-<slug>.md
Updated: docs/layers/<layer>/README.md (added F-<NNN> to features table)
Updated: feature_list.json (added F-<NNN>, status: not-started)
Suggested next steps:
1. Fill the Design section in feat-<NNN>-<slug>.md
- Approach (one paragraph)
- Invariants (IV-1, IV-2, ...)
- Rejected alternatives
2. When Design is reviewed, change Status: design -> planning and fill Plan
3. Create the git branch: git checkout -b feature/<slug>
templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE/features/_FEATURE-TEMPLATE.md -- the source templateTwo parallel state systems exist; you maintain both manually after this skill creates them. They serve different purposes:
Tracks where in the ULTRAPACK Design / Plan / Verify / Conclusion journey the feature is.
design --> planning --> executing --> reviewing --> done
\
--> blocked --> executing
Six states: design, planning, executing, reviewing, done,
blocked. Transitions are manual edits. Once done, the feature doc
is read-only history; further changes go into a superseding feature.
Tracks the machine-readable state used by build_kb_graph.py and validate_kb_links.py.
not-started --> in-progress --> done
\
--> blocked --> in-progress
Four states: not-started, in-progress, blocked, done. done is
one-way (no rollback; regression becomes a new feature) per
principle 27.
| Doc Status | feature_list.json status | Notes |
|---|---|---|
| design | not-started | newly created, no plan yet |
| planning | in-progress | plan being written |
| executing | in-progress | code being written |
| reviewing | in-progress | review/verify phase |
| blocked | blocked | identical |
| done | done | identical |
This skill creates the doc with Status: design AND the json entry
with status: "not-started". Subsequent transitions are manual --
update both files in lockstep, or use future /feature-done,
/feature-block skills (not yet implemented).
--id F-NNN explicitly so the
feature retains its prior ID in any links from PROBLEMS.md or
handoffs. The skill will not auto-detect existing IDs.api-utf8-posting.md, when writing the markdown file or
feature_list.json, always specify encoding="utf-8" explicitly to
avoid mojibake on Windows.| Symptom | Cause | Fix |
|---|---|---|
| "Layer does not exist" | docs/layers/<layer>/ missing | Run /layer-new <layer> first |
| F-NNN conflict | Allocator hit a manually-set ID | Pass --id F-MMM explicitly with the next free number |
feature_list.json parse error | Invalid JSON in file | Stop, surface the parse error. User fixes manually before retry |
| Template missing on this machine | Different host / fresh clone | Pull from public repo: gh api repos/AnastasiyaW/claude-code-config/contents/templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE/features/_FEATURE-TEMPLATE.md |
Cyrillic in title shows as ????? | File written without explicit utf-8 | Re-write the file with encoding="utf-8"; see ~/.claude/rules/api-utf8-posting.md |
This is a scaffolding skill: file copy + placeholder replacement + small JSON merge. Keep it deterministic. The Design / Plan / Verify sections of the produced document are meant for the user (or the session that invoked the skill) to fill -- this skill does not attempt to generate Design content from the title.
Auto-allocating F-NNN requires reading the full tree of
docs/layers/*/features/feat-*.md files; do this lazily and cache for
the duration of the skill invocation.
npx claudepluginhub anastasiyaw/claude-code-configScaffolds a new bounded-concern layer (security, data, ui, etc.) in a project's docs/layers/ tree following feature-layer architecture. Idempotent, uses kb-skeleton template.
Create, update, or fact-check Feature Design Docs that capture product design decisions for downstream code agents. Especially useful after vibe-coding sessions.
Manages a 4-phase feature development pipeline: research, implementation planning, progress tracking, and phased execution for major features. Supports status checks and next-step guidance via subcommands.