Ensure CLAUDE.md mirrors constitution sections per explicit mapping. Use when synchronizing CLAUDE.md with constitution, validating alignment, or when you see "CLAUDE.md sync", "agent instructions", or need to propagate constitution changes to CLAUDE.md.
Synchronizes CLAUDE.md with constitution sections using explicit mapping rules and validation.
/plugin marketplace add deepeshBodh/human-in-loop/plugin install deepeshbodh-humaninloop-plugins-humaninloop@deepeshBodh/human-in-loopThis skill inherits all available tools. When active, it can use any tool Claude has access to.
SECTION-TEMPLATES.mdSYNC-PATTERNS.mdEnsure CLAUDE.md (the primary AI agent instruction file) remains synchronized with the constitution. CLAUDE.md serves a different audience (AI agents) than the constitution (human governance), so synchronization is selective—specific sections map with explicit sync rules.
┌─────────────────────────────────────────────────────────────────┐
│ TWO AUDIENCES │
├────────────────────────────┬────────────────────────────────────┤
│ CONSTITUTION │ CLAUDE.MD │
├────────────────────────────┼────────────────────────────────────┤
│ Audience: Humans │ Audience: AI Agents │
│ Purpose: Governance │ Purpose: Runtime Instructions │
│ Format: Detailed │ Format: Actionable │
│ Contains: Rationale │ Contains: Rules + Commands │
│ Updated: Deliberately │ Updated: Must track constitution │
└────────────────────────────┴────────────────────────────────────┘
If CLAUDE.md diverges from the constitution, AI agents operate with outdated or incorrect guidance, undermining governance.
The following sections MUST be synchronized:
| Constitution Section | CLAUDE.md Section | Sync Rule |
|---|---|---|
| Core Principles | Principles Summary | MUST list all principles with enforcement keywords |
| Technology Stack | Technical Stack | MUST match exactly (table format) |
| Quality Gates | Quality Gates | MUST match exactly (table format) |
| Governance | Development Workflow | MUST include versioning rules and commit conventions |
| Project Structure | Project Structure | MUST match if present in constitution |
| Layer Import Rules | Architecture | MUST replicate dependency rules |
Two primary sync rules govern how content transfers:
MUST list all with enforcement: Principles are summarized but preserve enforcement keywords, metrics, and thresholds. Rationale is omitted.
MUST match exactly: Tables are copied directly with no summarization.
See SECTION-TEMPLATES.md for detailed templates and examples for each sync rule.
The sync process follows six steps:
See SYNC-PATTERNS.md for detailed process steps, validation checklists, and conflict resolution.
CLAUDE.md should include these sections for proper sync:
See SECTION-TEMPLATES.md for the complete structure template.
CLAUDE.md synchronization MUST occur when:
Before completing synchronization, verify:
See SYNC-PATTERNS.md for the complete validation checklist.
When syncing, use this commit format:
docs: sync CLAUDE.md with constitution vX.Y.Z
- Updated Principles Summary (added Principle VII)
- Updated Quality Gates (coverage 70% -> 80%)
- Version aligned to X.Y.Z
| Anti-Pattern | Problem |
|---|---|
| Full duplication | CLAUDE.md becomes constitution copy |
| Stale sync | CLAUDE.md lags behind constitution |
| Missing version | No version tracking in CLAUDE.md |
| Partial sync | Some sections synced, others not |
| Summary drift | Summarization loses enforcement |
See SYNC-PATTERNS.md for detailed anti-patterns and fixes.
This skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.