generate-claude-component

generate-claude-component is a command for Claude Code from dykyi-roman/awesome-claude-code. It costs 29 tokens per session (2,274 once invoked), scanned A, original, MIT.

An interactive wizard for creating Claude Code extensions such as commands, agents, skills, hooks, rules, and plugins. It helps define new reusable behavior for Claude Code.

In plain words
What is it for?
Use it to discover which component fits a goal, then create items such as a formatting command, a security-audit agent, a syntax-checking hook, or a distributable plugin.
Why use it?
It turns the process of extending an AI coding tool into a guided task instead of requiring you to design every component from scratch.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: model in frontmatter; reads .claude/ paths; mentions CLAUDE.md.

Part of the acc plugin — 101 skills, 26 commands, 68 agents, 1 hook shipped together

Good fit Use it to discover which component fits a goal, then create items such as a formatting command, a security-audit agent, a syntax-checking hook, or a distributable plugin.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/dykyi-roman/awesome-claude-code/generate-claude-component
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.

Clone the repo
git clone --depth 1 https://github.com/dykyi-roman/awesome-claude-code

Made for: Claude Code.

Or install acc, the plugin that ships this one along with the rest of its 101 skills, 26 commands, 68 agents, 1 hook.

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 generate-claude-component

README.md
[![agentmods](https://agentmods.dev/badge/commands/dykyi-roman/awesome-claude-code/generate-claude-component.svg)](https://agentmods.dev/commands/dykyi-roman/awesome-claude-code/generate-claude-component)
Your own site
<a href="https://agentmods.dev/commands/dykyi-roman/awesome-claude-code/generate-claude-component"><img src="https://agentmods.dev/badge/commands/dykyi-roman/awesome-claude-code/generate-claude-component.svg" alt="Measured on agentmods" height="20"></a>
Per session 29 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,274 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00029 $0.02274
Opus 5 $0.00015 $0.01137
Sonnet 5 $0.00006 $0.00455
Haiku 4.5 $0.00003 $0.00227

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

Security

Grade A, and why

generate-claude-component 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.

commands/generate-claude-component.md · 245 lines

How it starts

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

Claude Code Creator

You are a master of creating Claude Code components.

Input Parsing

Parse $ARGUMENTS to extract component type and optional meta-instructions:

Format: [component-type] [-- <meta-instructions>]

Examples:
- /acc:generate-claude-component
- /acc:generate-claude-component command
- /acc:generate-claude-component agent -- for DDD auditing
- /acc:generate-claude-component skill -- generates Value Objects
- /acc:generate-claude-component ? -- I want to auto-format code
- /acc:generate-claude-component ? -- need a security audit
- /acc:generate-claude-component hook -- validate PHP syntax before Write tool
- /acc:generate-claude-component rule -- domain layer must be pure
- /acc:generate-claude-component plugin -- package DDD tools for distribution

Parsing rules:

  1. Split $ARGUMENTS by -- (space-dash-dash-space)
  2. First part = component type (optional: command/agent/skill/hook/rule/plugin/?)
  3. Second part = meta-instructions (optional, hints about purpose)

Discovery mode (?): If first part is ?, enter discovery mode:

  • Analyze meta-instructions to understand user's goal
  • Recommend best component type with reasoning
  • Show plan before proceeding

If component type provided (not ?), skip Step 0-1 and go directly to Step 2. If meta-instructions provided, use them to guide questions in Step 2.

Process

Step 0: Discovery Mode (if ? provided)

If user passed ? as component type:

  1. Analyze the goal from meta-instructions:

    • What problem needs solving?
    • Is it automation, audit, generation, or workflow?
    • Does it need separate context (agent) or just instructions (skill)?
    • Should it trigger automatically (hook) or manually (command)?
    • Is it project-wide instruction (rule) or distributable package (plugin)?
  2. Recommend component type with reasoning:

    Goal Pattern Recommended Reason
    "automatically when..." / "on save" / "before commit" Hook Triggered by events, zero context cost
    "check/audit/validate/analyze" Command + Agent Complex analysis needs separate context
    "generate/create/write" Command + Agent + Skills Generation workflow
    "instructions/reference/knowledge" Skill Reusable knowledge
    "simple workflow/quick action" Command Single saved prompt
    "always follow these rules" / "project standard" Rule Always in system prompt
    "share with team" / "distribute" / "package" Plugin Namespaced, installable
    "external API/tool integration" MCP config Standardized protocol

Read the full file on GitHub · 245 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 · 245 lines · 0 tokens per session scan A 85bdda7ccc8d

Subscribe to this mod's changes

generate-claude-component is a command published in the GitHub repository dykyi-roman/awesome-claude-code (96 stars, last pushed 23d ago), licensed MIT. It adds 29 tokens to every session and 2,274 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-09-03.