layer-detector

layer-detector is a skill for Claude Code, Codex from jhlee0409/claude-plugins. It costs 14 tokens per session (2,257 once invoked), scanned A, original, MIT.

A project-analysis tool that detects Feature-Sliced Design layers in a source directory. Feature-Sliced Design is a way to organize application code into layers such as shared utilities, entities, features, pages, and app setup.

In plain words
What is it for?
Finding standard FSD layer folders, analyzing their hierarchy, and supporting project initialization or architecture analysis.
Why use it?
It shows whether the project follows that layer structure and uses the correct source directory. It also reports an error when the expected source directory cannot be found.

Skill for Claude CodeCodex

Part of the fsdarch plugin — 4 skills, 6 commands 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/jhlee0409/claude-plugins/layer-detector
Any agent
npx skills add jhlee0409/claude-plugins --skill layer-detector
Clone the repo
git clone --depth 1 https://github.com/jhlee0409/claude-plugins

Made for: Claude Code, Codex.

Or install fsdarch, the plugin that ships this one along with the rest of its 4 skills, 6 commands.

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 layer-detector

README.md
[![agentmods](https://agentmods.dev/badge/skills/jhlee0409/claude-plugins/layer-detector.svg)](https://agentmods.dev/skills/jhlee0409/claude-plugins/layer-detector)
Your own site
<a href="https://agentmods.dev/skills/jhlee0409/claude-plugins/layer-detector"><img src="https://agentmods.dev/badge/skills/jhlee0409/claude-plugins/layer-detector.svg" alt="Measured on agentmods" height="20"></a>
Per session 14 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,257 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.00014 $0.02257
Opus 5 $0.00007 $0.01128
Sonnet 5 $0.00003 $0.00451
Haiku 4.5 $0.00001 $0.00226

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

Security

Grade A, and why

layer-detector 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 4d 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.

plugins/fsd-architect/skills/layer-detector/SKILL.md · 337 lines

How it starts

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

Layer Detector Skill

FSD 레이어 구조를 감지하고 분석합니다.

WHEN TO USE

This skill is invoked by:

  • /fsdarch:init - Initial project setup
  • /fsdarch:analyze - Project analysis

EXECUTION INSTRUCTIONS

Step 1: Find Source Directory

Action: Determine the source directory path

1. Check if srcDir is passed as parameter
   → If yes, use it directly

2. If no parameter, read .fsd-architect.json
   → Use Read tool to get srcDir field
   → Default to "src/" if not specified

3. Verify directory exists:
   → Use Glob: "{srcDir}/"
   → If no match, return error E101

Glob command:

Glob: "src/"
# Or if config specifies different path:
Glob: "{config.srcDir}/"

Step 2: Detect Layers

Action: Scan for FSD layer directories

Standard FSD layers (in hierarchy order):

1. shared   (lowest - utilities, ui kit, api clients)
2. entities (domain models and business entities)
3. features (user interactions and business logic)
4. widgets  (composite UI blocks)
5. pages    (route-level compositions) → "views" in Next.js
6. app      (highest - app initialization) → "core" in Next.js

Glob commands to execute (in parallel):

For standard projects:

Glob: "{srcDir}/app/"
Glob: "{srcDir}/pages/"
Glob: "{srcDir}/widgets/"
Glob: "{srcDir}/features/"
Glob: "{srcDir}/entities/"
Glob: "{srcDir}/shared/"

For Next.js projects (layer aliases):

Glob: "{srcDir}/core/"       # app → core
Glob: "{srcDir}/views/"      # pages → views
Glob: "{srcDir}/widgets/"
Glob: "{srcDir}/features/"
Glob: "{srcDir}/entities/"
Glob: "{srcDir}/shared/"

Layer alias mapping (user-configurable):

// Layer aliases are stored in .fsd-architect.json
// Users can customize these during /fsdarch:init

interface LayerAliases {
  app: string;    // 'app', 'core', '_app', 'application', etc.
  pages: string;  // 'pages', 'views', '_pages', 'screens', etc.
}

// Common presets:
const LAYER_ALIAS_PRESETS = {
  standard: { app: 'app', pages: 'pages' },
  nextjs_recommended: { app: 'core', pages: 'views' },
  nextjs_underscore: { app: '_app', pages: '_pages' },
  nextjs_verbose: { app: 'application', pages: 'screens' }
};

// Read from config:
function getLayerPath(layer: string, config: Config): string {
  if (config.layerAliases && config.layerAliases[layer]) {
    return config.layerAliases[layer];
  }
  return layer; // default: use layer name as-is
}

Read the full file on GitHub · 337 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. 4d ago First seen · 337 lines · 14 tokens per session scan A fa235ca9e48b

Subscribe to this mod's changes

layer-detector is a skill published in the GitHub repository jhlee0409/claude-plugins (4 stars, last pushed 7mo ago), licensed MIT. It adds 14 tokens to every session and 2,257 once invoked, about $0.0001 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-31.

Related

Other skills, from other repositories

datamodel-code-generator

Use this skill when the user wants Python data models, Pydantic models, dataclasses, TypedDicts, msgspec structs, or type-safe Python classes generated from OpenAPI, AsyncAPI, JSON Schema, GraphQL, JSON/YAML/CSV sample data, MCP tool schemas, Protocol Buffers, XML Schema, Apache Avro, or existing Python model objects.…

koxudaxi/datamodel-code-generator · 147 tokens

preserved_skill

previous skill.

koxudaxi/datamodel-code-generator · 0 tokens

performing-api-fuzzing-with-restler

Uses Microsoft RESTler to perform stateful REST API fuzzing by automatically generating and executing test sequences that exercise API endpoints, discover producer-consumer dependencies between requests, and find security and reliability bugs. The tester compiles an OpenAPI specification into a RESTler fuzzing…

xalgorix/xalgorix · 123 tokens

ideogram-ultra

Build Ideogram 4 (Ideogram Ultra) txt2img and img2img workflows with the local open-weights model, dual conditional/unconditional models with DualModelGuider, Qwen3-VL text encoder, and structured JSON ("compositional deconstruction") prompts for strong text rendering and layout control.

artokun/comfyui-mcp · 68 tokens

model-compatibility

Model family compatibility matrix covering loaders, resolutions, samplers, CFG, VAE, ControlNet, and LoRA compatibility for SD 1.5, SDXL, Flux, SD3, and video models.

artokun/comfyui-mcp · 47 tokens

flux-txt2img

Build Flux txt2img workflows with Flux.1 Dev (SRPO), Flux 2 Klein 9B, Turbo LoRAs, FluxGuidance, and DualCLIPLoader patterns.

artokun/comfyui-mcp · 44 tokens