From dev-tools
为 Claude Code 初始化项目协作骨架。当用户希望创建或补齐 CLAUDE.md 与 .claude,并生成 rules、memory、agents、hooks 配置的起始模板时使用。Codex 仅作为 Claude Code 临时调用的任务执行工具,本 skill 不生成 AGENTS.md、.codex 或 Codex agents。
How this skill is triggered — by the user, by Claude, or both
Slash command
/dev-tools:agent-initThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
用于为项目初始化轻量协作骨架。默认只初始化 **Claude Code 主工作流**。
agents/openai.yamlreferences/claude-code.mdscripts/init_agent.pytemplates/claude-code/entry-append.mdtemplates/claude-code/entry.mdtemplates/claude-code/settings.jsontemplates/common/agents/executor.mdtemplates/common/agents/planner.mdtemplates/common/agents/verifier.mdtemplates/common/docs-entry-append.mdtemplates/common/memory/corrections.mdtemplates/common/memory/index.mdtemplates/common/memory/learned-rules.mdtemplates/common/memory/observations.mdtemplates/common/memory/project-progress.mdtemplates/common/memory/session-brief.mdtemplates/common/rules/document-lifecycle.mdtemplates/common/rules/memory-write-policy.mdtemplates/common/rules/review-checklist.mdtemplates/common/rules/subagent-routing.md用于为项目初始化轻量协作骨架。默认只初始化 Claude Code 主工作流。
使用本 skill 的第一步必须检查当前执行环境。
agent-init 只支持在 Claude Code 中调用。当前执行环境不是 Claude Code,请切换到 Claude Code 后再执行初始化。
当前支持:
claude-code:生成 CLAUDE.md 与 .claude/执行初始化前,先读取对应参考文件:
references/claude-code.md期望参数:
initagent=claude-coderoot=<项目根目录>docs-profile=<none|engineering>当 docs-profile=engineering 时,额外初始化:
docs/
architectures/
plans/
tasks/
并补齐顶层入口文件中的文档治理规则,但不额外生成目录级 README.md。
Codex 只作为 Claude Code 在具体任务中临时调用的执行工具,不作为项目级协作骨架初始化目标。
AGENTS.md.codex/.codex/agentsCLAUDE.md.claude/.claude/
rules/
task-classification.md
document-lifecycle.md
memory-write-policy.md
subagent-routing.md
review-checklist.md
memory/
index.md
session-brief.md
project-progress.md
corrections.md
observations.md
learned-rules.md
agents/
planner.md
executor.md
verifier.md
Claude Code 使用 Markdown 格式,并且每个文件必须包含 YAML frontmatter(至少 name 与 description),以便 Claude Code 正确识别子代理:
.claude/agents/
planner.md
executor.md
verifier.md
Claude Code 配置在 .claude/settings.json(随仓库提交共享),hook 条目使用 hooks 数组结构:
.claude/settings.json
{
"hooks": {
"SessionStart": [
{
"hooks": [
{
"type": "command",
"command": "cat \"$(git rev-parse --show-toplevel)/.claude/memory/session-brief.md\""
}
]
}
]
}
}
rules/document-lifecycle.mdscripts/init_agent.py
agent 和 root 初始化对应的顶层入口文件与运行目录references/claude-code.md
npx claudepluginhub gfishlab/happy-claude-skills --plugin document-toolsGuides completion of development work by verifying tests, detecting environment, and presenting structured options for merge, PR, or cleanup.
Enforces test-driven development: write failing test first, then minimal code to pass. Use when implementing features or bugfixes.
Guides creation and editing of skills using test-driven development with pressure scenarios and subagents to verify agent compliance.