Scaffold a new layer in a project's docs/layers/ tree following the feature-layer architecture (principle 28).

MITAuto-check passedDevelopment

Install Layer New

skills CLI
$ npx skills add AnastasiyaW/codex-claude-code-config --skill layer-new -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install AnastasiyaW/codex-claude-code-config layer-new --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/AnastasiyaW/codex-claude-code-config.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/architecture/layer-new .claude/skills/layer-new && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
layer-new
GitHub stars
154
Token cost
~1.8k tokens
SKILL.md length
728 words
Files
1
Skills in repo
50
Repo updated
First seen
Licence
MIT

At a glance

Scaffold a new layer in a project's docs/layers/ tree following the feature-layer architecture (principle 28).

  • Works in 7 steps: Verify environment → Validate layer name → Copy the template → …
  • : create a new layer
  • SKILL.md covers When to use, When NOT to use, Arguments and Direction (what to do, in order), plus 4 more sections
  • Calls git, gh and python; reaches github.com

What it does

Layer New is an agent skill from AnastasiyaW/codex-claude-code-config. Scaffold a new layer in a project's docs/layers/ tree following the feature-layer architecture (principle 28). A layer is a bounded concern (security, data, ui, infrastructure, domain) with its own invariants, decisions, gotchas, patterns, and feature narratives. Use when: "create a new layer", "add security layer", "scaffold layer", "start tracking <concern separately", "/layer-new", "add bounded concern". Operates on the kb-skeleton structure; idempotent -- will not overwrite existing layers. Do NOT use to…

Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development. It works with Git. The repository describes itself as: Claude Code, Codex, and multi-agent configuration system: principles, hooks, skills, and workflow patterns for AI-assisted development. The licence is MIT.

When your agent uses it

  • : create a new layer
  • Add security layer
  • Start tracking <concern separately
  • Add bounded concern

Example prompts

  • “create a new layer”
  • “add security layer”
  • “scaffold layer”
  • “/layer-new”

Requirements

  • Python 3

Workflow steps

7 steps, taken from the step headings in SKILL.md.

  1. Verify environment
  2. Validate layer name
  3. Copy the template
  4. Fill placeholders
  5. Register the layer
  6. Wire to project state
  7. Confirm and suggest next step

What it can do on your machine

Read from SKILL.md and the folder at commit 67709af. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git
    • gh
    • python

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • github.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Layer New loads about 1.8k tokens when it runs. Until then it costs about 168 tokens; SKILL.md has 728 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~168
When it runs · the whole SKILL.md, loaded when a task matches
~1.8k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from AnastasiyaW/codex-claude-code-config at commit 67709af, republished under its MIT licence (© AnastasiyaW). 728 words, ~1,810 tokens.

Download SKILL.mdSave it as .claude/skills/layer-new/SKILL.md (or your agent's skills folder).
name
layer-new
description
Scaffold a new layer in a project's docs/layers/ tree following the feature-layer architecture (principle 28). A layer is a bounded concern (security, data, ui, infrastructure, domain) with its own invariants, decisions, gotchas, patterns, and feature narratives. Use when: "create a new layer", "add security layer", "scaffold layer", "start tracking <concern> separately", "/layer-new", "add bounded concern". Operates on the kb-skeleton structure; idempotent -- will not overwrite existing layers. Do NOT use to scaffold an individual feature narrative inside an existing layer; use /feature-new for that (a layer is the container, not the per-feature doc).
user-invocable
true
model
sonnet

/layer-new -- scaffold a project layer

Creates docs/layers/<layer-name>/ with the full template structure defined by principle 28.

When to use

  • Starting to track a new bounded concern in a long-running project
  • Refactoring sprawling cross-cutting code into a documented layer
  • Onboarding a new team member who needs the layer map

When NOT to use

  • One-off scripts or pet projects with <5 features (overhead not justified)
  • Layer name describes a directory (src is not a layer)
  • The "layer" is actually one feature in disguise -- use /feature-new inside an existing layer instead

Arguments

/layer-new <layer-name> [--purpose "..."] [--principles P-NN,P-MM]
  • <layer-name> -- kebab-case, single word preferred. Examples: security, data, image-processing, observability.
  • --purpose -- one-sentence purpose. If omitted, prompt the user.
  • --principles -- comma-separated Tier 1 principle IDs that govern this layer (e.g. P-02,P-21). If omitted, leave placeholder in README.

Direction (what to do, in order)

Step 1 -- Verify environment

Check the current working directory:

  1. Is it a git repository? Run git rev-parse --show-toplevel. If not, ask the user whether to initialize one (offer git init + private GitHub repo per global rule).
  2. Does docs/ exist? If not, create it.
  3. Does docs/layers/README.md exist? If not, copy from <claude-code-skills-checkout>/templates/kb-skeleton/docs/layers/README.md.
  4. Check if docs/layers/<layer-name>/ already exists. If yes, stop with a message -- do not overwrite. Suggest /feature-new <layer> <slug> instead.
Step 2 -- Validate layer name
  • Must be lowercase kebab-case ([a-z][a-z0-9-]*).
  • Must not start with _ (reserved for templates).
  • Must not be a generic file-system name (src, tests, docs, build).
  • If invalid, refuse with a clear message and a suggested fix.
Step 3 -- Copy the template

Source: <claude-code-skills-checkout>/templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE/

Destination: <repo>/docs/layers/<layer-name>/

Copy the entire directory tree. Preserve subdirectory structure (kb/ and features/). Result:

docs/layers/<layer-name>/
├── README.md
├── history.md
├── kb/
│   ├── invariants.md
│   ├── decisions.md
│   ├── gotchas.md
│   └── patterns.md
└── features/
    └── _FEATURE-TEMPLATE.md
Step 4 -- Fill placeholders

In every file under the new layer, replace:

  • <layer-name> -> the actual layer name
  • <Layer name> -> Title Case of the layer name (e.g. "Security", "Image Processing")

In README.md specifically:

  • **Purpose:** <one sentence...> -> the --purpose argument value, or prompt the user
  • ## Governing principles list -> populate from --principles arg, or leave the placeholder bullets in place for the user to fill

In history.md:

  • Insert a "Layer created" entry at the top with today's date (YYYY-MM-DD) and the originating reason. Prompt the user for the reason if not provided.
Step 5 -- Register the layer

Update docs/layers/README.md:

  • Add a row to the ## Layer index table: | <layer-name> | <purpose> | active |
  • If a cross-layer Mermaid graph exists, add a node for the new layer with no edges (user will add edges as dependencies form).
Step 6 -- Wire to project state

If the project has feature_list.json at repo root, leave it alone -- features get added by /feature-new. Do not edit feature_list.json from this skill.

If the project has AGENTS.md, suggest (but do not auto-edit) adding the new layer to the "Source-of-truth docs" table if multiple layers exist.

Show full SKILL.md (281 more words)Show less
Step 7 -- Confirm and suggest next step

Print a summary:

Layer created: docs/layers/<layer-name>/
Files: 1 README, 1 history, 4 kb/, 1 feature template

Suggested next steps:
1. Fill governing principles in docs/layers/<layer-name>/README.md
2. Write the first feature: /feature-new <layer-name> <slug>
3. Add the first invariant when it earns its place

Blueprints (files this skill writes from)

  • templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE/ -- the source tree to copy
  • templates/kb-skeleton/docs/layers/README.md -- the layers index template (used only if missing)

Gotchas

  • Renaming a layer is not idempotent. If the user runs /layer-new wrong-name then realizes they wanted right-name, manually rename the directory and update references. This skill does NOT detect or fix duplicates.
  • Layer name collision with existing directories. If docs/<layer-name>/ exists at the docs/ root (not under docs/layers/), refuse and ask the user which they want -- there is no automatic merge.
  • Templates may have moved. If the template path <claude-code-skills-checkout>/templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE/ does not exist (e.g. user is on a different machine), fall back to reading from https://github.com/AnastasiyaW/claude-code-config/tree/main/templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE via gh api.
  • Encoding boundary. When writing files with Cyrillic content, follow the global rule from ~/.claude/rules/api-utf8-posting.md -- always specify encoding="utf-8" explicitly.

Troubleshooting

SymptomCauseFix
"Layer already exists"Directory docs/layers/<name>/ presentUse /feature-new to add to it, or pick a different name
Template files missingPath moved or different machinePull templates from public repo via gh api repos/AnastasiyaW/claude-code-config/contents/templates/kb-skeleton/docs/layers/_LAYER-TEMPLATE
Layers README not updateddocs/layers/README.md had no ## Layer index tableOpen file manually, add table per the kb-skeleton template
Validator warns about layervalidate_kb_links.py flagged broken linkLayer is fine; broken link is in a feature doc inside it. Run python scripts/build_kb_graph.py from the project root for the full health report.

Implementation note

The bulk of the work is file copy + placeholder replacement. No dynamic logic is needed; the template files do all the structural heavy lifting. Keep this skill deterministic and idempotent -- it must be safe to invoke twice on the same layer (second call should be a no-op with a clear message).

© AnastasiyaW, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/architecture/layer-new of AnastasiyaW/codex-claude-code-config.

Open the folder on GitHubat commit 67709af

Compare with similar skills

Layer New next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Layer New compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Layer New this skillAnastasiyaW/codex-claude-code-config154—~1.8kAutomated safety check: PassMIT
Finishing a Development Branchobra/superpowers297k5 repos~1.9kAutomated safety check: PassMIT
Code Review ChecklistshareAI-lab/learn-claude-code78k4 repos~1.1kAutomated safety check: PassMIT
Code Design Rationale Investigatorcursor/plugins11k9 repos~2.6kAutomated safety check: PassNone
Contributor-First PR MergeHKUDS/OpenHarness16k1 repos~847Automated safety check: PassMIT
Finishing A Development Branchfarm-fe/farm5.6k34 repos~1.8kAutomated safety check: PassMIT

Similar skills

  • Walks the last step of a branch: confirm tests pass, detect the git environment, ask how to integrate, carry out your choice and clean up the worktree.

    297k GitHub starsUsed in 5 repos~1.9k tokens
    DevelopmentAuto-check passed
  • Code Review Checklist

    shareAI-lab/learn-claude-code

    Reviews code against a five-part checklist covering security, correctness, performance, maintainability and testing, and reports findings in a fixed format.

    78k GitHub starsUsed in 4 repos~1.1k tokens
    DevelopmentAuto-check passed
  • Official

    Digs into why code is shaped the way it is by checking git history, pull requests and connected tools in parallel, then reporting a cited read on the tradeoffs.

    11k GitHub starsUsed in 9 repos~2.6k tokens
    DevelopmentAuto-check passed
  • Merges external GitHub pull requests while keeping the original author credited, and fixes conflicts after the merge instead of rewriting the contribution.

    16k GitHub starsUsed in 1 repo~847 tokens
    DevelopmentAuto-check passed
  • A skill your agent uses when implementation is complete, all tests pass, and you need to decide how to integrate the work - guides completion of development work by presenting structured options for…

    5.6k GitHub starsUsed in 34 repos~1.8k tokens
    DevelopmentAuto-check passed
  • Moves a package from another TryGhost repository into Ghost as an internal workspace package while keeping its Git history, with checkpoints for the steps that need an administrator.

    56k GitHub stars~3.8k tokensUpdated today
    DevelopmentAuto-check passed

More from AnastasiyaW/codex-claude-code-config

All 50 skills in this repo
  • Bug Reproducer

    AnastasiyaW/codex-claude-code-config

    Find likely software bugs in a codebase, rank concrete bug candidates, and prove or reject them with focused regression tests before proposing a fix.

    154 GitHub stars~4.1k tokensUpdated yesterday
    Auto-check passed
  • Motion Framer

    AnastasiyaW/codex-claude-code-config

    A skill your agent uses when implementing Motion or Framer Motion in React/JavaScript: interactive UI components, micro-interactions, gestures, layout or page transitions, and scroll-based animation.

    154 GitHub starsUsed in 1 repo~5.2k tokens
    Auto-check passed
  • Proof Verify

    AnastasiyaW/codex-claude-code-config

    Plan-based verification - freeze acceptance criteria before building, then verify after with an independent fresh-context agent (the builder must not verify their own work).

    154 GitHub stars~2.6k tokensUpdated yesterday
    Auto-check passed
  • Workflow Orchestration

    AnastasiyaW/codex-claude-code-config

    Написание и запуск Claude Code dynamic workflows (JS-оркестратор субагентов).

    154 GitHub stars~3.8k tokensUpdated yesterday
    Auto-check passed
  • Notebooklm Grounded Research

    AnastasiyaW/codex-claude-code-config

    A skill your agent uses when: NotebookLM, notebooklm MCP, large documentation sets, courses, books, papers, or citation-backed research are mentioned.

    154 GitHub stars~2.4k tokensUpdated yesterday
    Auto-check: warnings
  • Deepseek Provider Contract

    AnastasiyaW/codex-claude-code-config

    Validate a proposed DeepSeek API integration before any key or project context is sent: check thinking-mode tool-call history, strict-schema assumptions, bounded output, and provider data boundaries.

    154 GitHub stars~1.2k tokensUpdated yesterday
    Auto-check passed

Works with

Categories

Questions about Layer New

What does Layer New do?

Scaffold a new layer in a project's docs/layers/ tree following the feature-layer architecture (principle 28). Layer New is an agent skill from AnastasiyaW/codex-claude-code-config. Scaffold a new layer in a project's docs/layers/ tree following the feature-layer architecture (principle 28).

When should I use Layer New?

Layer New fits situations like: : create a new layer; add security layer; start tracking <concern separately; add bounded concern.

How do I install Layer New in Claude Code?

Run `npx skills add AnastasiyaW/codex-claude-code-config --skill layer-new -a claude-code`. Or copy the skill folder (skills/architecture/layer-new in AnastasiyaW/codex-claude-code-config) into .claude/skills/layer-new in your project. Claude Code loads it when a task matches its description.

How do I install Layer New in Codex?

Run `npx skills add AnastasiyaW/codex-claude-code-config --skill layer-new -a codex`. Or copy the skill folder (skills/architecture/layer-new in AnastasiyaW/codex-claude-code-config) into .agents/skills/layer-new in your project. Codex loads it when a task matches its description.

Can I use Layer New in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add AnastasiyaW/codex-claude-code-config --skill layer-new -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/layer-new, .gemini/skills/layer-new, .github/skills/layer-new and .opencode/skills/layer-new in your project.

What does Layer New need to run?

Going by SKILL.md and its folder, Layer New needs the command-line tools its instructions call (git, gh and python). Our summary lists: Python 3.

Does Layer New access the network?

SKILL.md names 1 domain. In commands or code: github.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.

Is Layer New safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Layer New use?

Layer New is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Layer New use?

About 1.8k tokens (SKILL.md is roughly 7.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Layer New?

Skills that share tags, products or a category with Layer New: Finishing a Development Branch (obra/superpowers, 297k stars), Code Review Checklist (shareAI-lab/learn-claude-code, 78k stars), Code Design Rationale Investigator (cursor/plugins, 11k stars) and Contributor-First PR Merge (HKUDS/OpenHarness, 16k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Layer New?

AnastasiyaW (a GitHub user) maintains it in AnastasiyaW/codex-claude-code-config, which has 154 GitHub stars. The repository holds 50 skills in this directory. The repository was last updated on October 9, 2026.

Source: AnastasiyaW/codex-claude-code-config on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.