Skill 詳細

claude-code-mastery

Includes context-budget optimization but spans many unrelated Claude Code tasks.

一致度一致の可能性トークン最適化 向けにレビュー済み
出典borghei/claude-skills外部ソース
報告インストール数61人気度の参考値

使用前に確認

自動レビューは関連性のみを確認し、安全性や推奨を保証しません。使用前に出典の説明を読んでください。

保存された出典プレビュー

SKILL.md

これはレビュー時に保存された抜粋です。完全で最新の内容は外部ソースを確認してください。

---
name: claude-code-mastery
description: 
license: MIT
metadata:
  version: 1.1.0
  author: borghei
  category: engineering
  domain: development-tools
  updated: 2026-06-17
  tags: [claude-code, skill-authoring, subagents, hooks]
---
# Claude Code Mastery

Expert skill for Claude Code CLI -- CLAUDE.md optimization, skill authoring, subagent creation, hooks automation, and context engineering.

**Keywords:** claude-code, claude-cli, CLAUDE.md, skill-authoring, subagents, hooks, context-window, token-budget, MCP-servers, worktrees, permission-modes, prompt-engineering, context-engineering, slash-commands

## Core Capabilities

- **CLAUDE.md optimization** — audit, restructure, compress, and hierarchize config files for token efficiency.
- **Skill authoring** — scaffold and write discoverable skill packages with correct layout and frontmatter.
- **Subagent creation** — define scoped agents with `allowed-tools` and structured custom instructions.
- **Hooks automation** — wire `PreToolUse`/`PostToolUse`/`Stop` lifecycle scripts via `.claude/settings.json`.
- **Context engineering** — measure and manage the context-window token budget across a codebase.

## When to Use

- Authoring, structuring, or optimizing a CLAUDE.md file for any project.
- Scaffolding a new skill package or creating a Claude Code subagent.
- Configuring hooks for automated quality, security, or workflow steps.
- Auditing and reducing context-window consumption.

## Clarify First

Before scaffolding or optimizing, confirm these inputs. If any is unknown or vague, ASK — do not assume:

- [ ] **Which task** — scaffold a new skill, optimize a CLAUDE.md, create a subagent, or analyze context budget (selects `skill_scaffolder.py` vs `claudemd_optimizer.py` vs `context_analyzer.py`)
- [ ] **Target identity** — for a new skill: its name, domain, and one-line description; for optimization: the file or project path (the inputs the scripts require)
- [ ] **Token budget** — the target ceiling (sets `--token-limit` and what counts as over-budget)

Stop rule: ask only the 2-3 that most change the output. If the user says "just draft it," proceed and list your assumptions at the top of the artifact.

## Quick Start

```bash
# Scaffold a new skill package
python scripts/skill_scaffolder.py my-new-skill --domain engineering --description "Brief description"

# Analyze and optimize an existing CLAUDE.md
python scripts/claudemd_optimizer.py path/to/CLAUDE.md

# Estimate context window usage across a project
python scripts/context_analyzer.py /path/to/project

# All tools support JSON output
python scripts/claudemd_optimizer.py CLAUDE.md --json
```

## Tools

| Tool | Purpose | Command |
|------|---------|---------|
| `skill_scaffolder.py` | Scaffold a new skill package with correct structure + frontmatter | `python scripts/skill_scaffolder.py my-skill -d engineering --description "Does X"` |
| `claudemd_optimizer.py` | Score a CLAUDE.md for structure, tokens, and redundancy with recommendations | `python scripts/claudemd_optimizer.py CLAUDE.md --token-limit 4000` |
| `context_analyzer.py` | Estimate context-window consumption by file category with a budget breakdown | `python scripts/context_analyzer.py /path/to/project --max-depth 4` |

All tools support `--json`. See **[references/tool-reference.md](references/tool-reference.md)** for full parameter tables and output formats.

## References

Load the reference that matches the task — keep this file lean and pull detail on demand:

- **[references/workflows.md](references/workflows.md)** — the five numbered playbooks: optimize a CLAUDE.md, author a skill, create a subagent, configure hooks, and manage the context budget. Read when executing any of those tasks step-by-step.
- **[references/quick-reference.md](references/quick-reference.md)** — slash commands, permission modes, CLAUDE.md loading order, MCP servers, the troubleshooting table, and success criteria. Read for at-a-glance lookups or when debugging configuration.
- *
GitHub で全文を読む (外部ページ)
関連情報

関連する仕事