From cai
Use when creating a custom domain agent. Triggers: 'cai-add-agent', 'agent 추가', 'domain agent', 'add agent', '에이전트 추가', '에이전트 생성'
How this skill is triggered — by the user, by Claude, or both
Slash command
/cai:cai-add-agentThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Creates a new project-specific agent definition file and optionally registers it in the rules file's agent routing trigger table.
Creates a new project-specific agent definition file and optionally registers it in the rules file's agent routing trigger table.
Collect the following (from conversation context or by asking the user):
| Field | Description | Required |
|---|---|---|
| Name | Agent identifier in kebab-case (e.g., payment-expert) | Yes |
| Role | What this agent does (1-2 sentences) | Yes |
| Trigger patterns | When should this agent be invoked | Yes |
| File areas | Which files/directories this agent is responsible for | Yes |
| Domain knowledge | Specialized knowledge this agent needs | No |
| Referenced specs | Context docs this agent should read | No |
Create .claude/agents/{name}.md following Interface Contract 0.3 format:
---
name: {name}
description: "{trigger description}"
model: inherit
---
# {Agent Display Name}
## Role & Scope
{Role description, available tools, authority boundaries}
## Inputs
{What this agent receives: file paths, previous agent outputs, etc.}
## Process
{Step-by-step work procedure}
## Domain Knowledge
{Agent-specific expertise relevant to its domain}
## Output Format
{Exact format of artifacts and where they are stored}
## Referenced Specs
{List of context docs this agent should read}
## Constraints
{What this agent must NOT do}
Ask the user: "Add this agent to the routing trigger table in cai.md?"
If yes, add a row to the PROJECT-SPECIFIC section of .claude/rules/cai.md:
<!-- PROJECT-SPECIFIC:START -->
## [PROJECT-SPECIFIC] Agent routing trigger table
| Trigger Pattern | Agent | Description |
|----------------|-------|-------------|
| {existing rows} |
| {new trigger pattern} | {agent-name} | {brief description} |
<!-- PROJECT-SPECIFIC:END -->
Present the generated agent file to the user for review. Write to disk only after approval.
This skill does not invoke other agents. It generates agent definition files directly.
| Artifact | Path | Format |
|---|---|---|
| Agent definition | .claude/agents/{name}.md | Markdown with YAML frontmatter (Interface Contract 0.3) |
| Trigger table row | .claude/rules/cai.md | Appended to PROJECT-SPECIFIC section |
| Error | Action |
|---|---|
| Agent with same name already exists | Ask user: update existing or choose a different name |
.claude/agents/ directory does not exist | Create it before writing |
| Rules file has no PROJECT-SPECIFIC section | Add the section markers and trigger table |
| User provides insufficient role description | Ask clarifying questions about the agent's purpose and scope |
Provides behavioral guidelines to reduce common LLM coding mistakes, focusing on simplicity, surgical changes, assumption surfacing, and verifiable success criteria.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub workingdanny911/cai --plugin cai