A CLI that scaffolds a design engine for AI coding assistants. Run it in any project to generate a structured Claude Code configuration that teaches Claude how to work within your design system.
your-project/
├── CLAUDE.md # Project-level rules for Claude
├── .claude/
│ ├── rules/
│ │ ├── design-tokens.md # Token authority and ban list
│ │ ├── component-naming.md # Naming conventions
│ │ └── spacing-layout.md # Spacing and layout constraints
│ ├── memory/
│ │ └── design-decisions.md # Design decision log (optional)
│ └── hooks/
│ └── pre-tool-use.sh # Pre-write validation hook (optional)
└── src/styles/tokens.css # Design tokens (CSS custom properties)
All files are tailored to the design preset you select during setup.
npm install -g claytoneOr run directly with npx:
npx claytone initNavigate to your project root and run:
claytone initYou'll be prompted for:
- Project name — defaults to the current directory name
- Design preset — the design system to base your guardrails on (e.g. Notion)
- Memory files — whether to scaffold a design decisions log
- Hooks — whether to include a Claude Code pre-tool-use hook stub
To skip prompts and use defaults:
claytone init --yesEach preset encodes a real, tested design system as Claude Code guardrails — tokens, rules, and philosophy all in one.
| Preset | Description |
|---|---|
| Linear | Inter type, dark surfaces, indigo-purple accent, 4px grid, sidebar-driven |
| Notion | Inter type, warm near-black palette, 4px grid, minimal decoration |
| Vercel | Geist type, high-contrast monochrome, 8px grid, technical precision |
# Install dependencies
npm install
# Build
npm run build
# Build in watch mode
npm run dev
# Type check
npm run typecheck
# Test locally
npm link
claytone initsrc/
├── cli.ts # Binary entry — Commander program root
├── commands/init.ts # init command handler
├── prompts/ # @clack/prompts interactive flow
├── generators/ # File writers (orchestrator + per-output generators)
├── templates/ # Markdown/shell template files
│ ├── claude-md.md # CLAUDE.md template ({{projectName}}, {{presetSection}}, …)
│ ├── rules/ # Base rule files (static markdown)
│ ├── memory/ # Design decisions log template
│ └── hooks/ # Hook stub
├── presets/ # One directory per preset (notion, vercel, …)
│ └── <name>/
│ ├── index.ts # Assembles PresetDefinition from files
│ ├── tokens.css # CSS custom properties
│ ├── claude-md-section.md
│ └── augmentations/ # Preset-specific rule additions
├── types/index.ts # ProjectConfig and PresetDefinition interfaces
└── utils/ # fs helpers, logger, interpolate, load-template
- Create
src/presets/<name>/withtokens.css,claude-md-section.md, and anyaugmentations/*.md - Create
src/presets/<name>/index.tsthat assembles aPresetDefinitionusingloadTemplate() - Register it in
src/presets/index.ts