Skip to main content

Skills in CLAUDE.md

Benchmarked against: Anthropic — Using Skills with the API Architecture: CLAUDE.md references → Rules enforce → Skills execute

Skills integrate with SuperPortia's configuration through three touchpoints: CLAUDE.md, hooks, and rules.


The three-layer integration

LayerRoleExample
CLAUDE.mdReferences skills, defines when to suggest"Use /66s-review for major decisions"
RulesDefine trigger conditions, behavioral constraints"Cost awareness applies to all engine choices"
SkillsDetailed execution procedures"Step 1: Apply White Hat analysis..."

How CLAUDE.md references skills

CLAUDE.md is lean — it doesn't contain skill details, just pointers:

## Pre-Flight Check (30 seconds before any non-trivial task)
3D scoring 0-6: Blast Radius × Knowledge Freshness × Reversibility.
Full SOP: bulletin board + Cloud UB ub-a0914abf17a7

The Pre-Flight Check details are in UB, not in CLAUDE.md. If a full skill were needed, it would be loaded on demand.


Hook integration

Hooks can trigger skill-adjacent behavior:

HookTriggerAction
SessionStartNew sessionInjects heartbeat, timestamp, mailbox status
PreToolUseBefore tool callsCan gate skill invocation
PostToolUseAfter tool callsCan log skill results

Example: SessionStart hook

# .claude/hooks/session-start.sh
echo "⏰ $(TZ='Asia/Taipei' date '+%Y-%m-%d %H:%M') (Taipei)"
# Hook output injected into context — not a skill, but skill-like

Rule → skill escalation

Some rules point to skills for complex procedures:

Rule saysSkill provides
"Run Pre-Flight Check before non-trivial tasks"PFC 3D scoring procedure
"Major decisions require systematic review"/66s-review full Six Hats analysis
"Cost awareness applies to all engine choices"/brain_lite emergency downshift

Auto-discovery

Claude Code automatically discovers skills from the .claude/skills/ directory:

  1. Scans for directories in .claude/skills/
  2. Each directory with a prompt.md becomes a skill
  3. Directory name = command name (e.g., 66s-review/66s-review)
  4. Skills appear in the skills list automatically

No manual registration needed in CLAUDE.md.


Best practices

PracticeWhy
CLAUDE.md mentions when to use skillsAgents know skills exist
Rules define triggers, skills define proceduresClean separation
Skills reference rules, not vice versaRules stay lean
Skills don't duplicate rule contentAvoid inconsistency

PageRelationship
Skills OverviewFull skills reference
CLAUDE.md + PDPD architecture
Creating a SkillHow to build