From the-ai-brain
Re-sync all agent configs from brain.yaml and active-rules. Use when the user says "vault align", "sync configs", "regenerate configs", "update rules", "re-sync", "align vault", or when agent config files need to be regenerated after rule or structure changes.
How this skill is triggered — by the user, by Claude, or both
Slash command
/the-ai-brain:brain-vault-alignclaude-sonnet-4-6The summary Claude sees in its skill listing — used to decide when to auto-load this skill
<objective>
Read the following files:
brain.yaml -- master configurationMachine/Rules/active-rules.md -- current behavioral rulescore/brain-rules.md -- universal base rulesAnalyze actual vault usage patterns to detect conventions:
#project/name)?Compare active-rules.md against actual vault conventions:
Rules in active-rules.md that do not match actual vault behavior:
Conventions observed in the vault that are not captured in active-rules.md:
Machine/Memory/corrections.md not yet promoted to rulesDifferences between brain.yaml settings and actual practice:
preferences.wikilinks: true but files do not use wikilinksmemory.session_logs: true but no session logs existenabled: true but config files are missing or outdatedPresent a summary of drift findings and propose specific changes:
## Drift Report
### Rules to Update
1. Rule "{name}" -- actual practice differs: {description}
Proposed: {updated rule text}
### Rules to Add
1. New rule: "{name}" -- observed pattern: {description}
Proposed: {rule text}
### Rules to Remove
1. Rule "{name}" -- no longer applicable: {reason}
### No Changes Needed
{list rules that are aligned}
Ask for user approval before making any changes to active-rules.md.
If the user approves changes:
Machine/Rules/active-rules.md with approved changes.Machine/Rules/rule-changelog.md:
### {YYYY-MM-DD} -- Vault Alignment
- Updated: {rule name} -- {reason}
- Added: {rule name} -- {reason}
- Removed: {rule name} -- {reason}
For each agent marked enabled: true in brain.yaml:
Read the corresponding template from generators/templates/:
CLAUDE.md.tmplcursorrules.tmplgemini.md.tmplcodex.md.tmplRegenerate the config file by combining:
core/brain-rules.mdMachine/Rules/active-rules.mdWrite the regenerated config to the location specified in brain.yaml (agents.{name}.config_file).
If skills are enabled for an agent (agents.{name}.skills: true), ensure skill references are included in the config.
## Vault Alignment Complete
### Rules Updated
- {N} rules modified, {N} added, {N} removed
- Changelog updated: Machine/Rules/rule-changelog.md
### Configs Regenerated
- CLAUDE.md -- regenerated (Claude Code)
- .cursorrules -- regenerated (Cursor)
- {or "skipped -- agent not enabled"}
### Remaining Drift
- {any drift the user chose not to address}
- {or "Vault is fully aligned."}
- Never modify active-rules.md without explicit user approval.
- Always show proposed changes before applying them.
- Regenerated configs should be complete replacements, not patches.
- If a template file is missing for an enabled agent, warn the user rather than generating a config from scratch.
- Log all changes to rule-changelog.md for auditability.
- If brain.yaml has no agents enabled, skip config regeneration and inform the user.
- Preserve any manually-added sections in agent configs by checking for `` markers.
<success_criteria>
Guides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.
npx claudepluginhub cfircoo/the-ai-brain --plugin the-ai-brain