Naming Conventions
Purpose
Define naming conventions for directories, files, and identifiers with these goals:
- Scriptability: scripts can locate files reliably with fewer branches
- Portability: cross OS/IDE moves should require zero or minimal renaming
- Readability: humans and LLMs can infer purpose and scope from names
When to use
Use the naming-conventions skill when:
- Creating new directories or files
- Naming skills, workflows, or commands
- Reviewing code for naming consistency
- Setting up CI checks for naming standards
- Scripts generating files (see Script Integration below)
Inputs
- The item to name (directory, file, skill, identifier)
- Context (SSOT content, provider stubs, general repo files)
Outputs
- Correctly named items following conventions
- Validation results for existing names
Steps
- Identify what you are naming (file, directory, module, component, hook, API surface, configuration key, or data entity).
- Choose the most relevant convention section below and follow the MUST rules first.
- Propose 2–3 candidates and select the one that matches existing local conventions and avoids ambiguous abbreviations.
- Apply the chosen name consistently across declarations and references (imports, exports, docs, and tests).
- Verify that the resulting names are searchable, unambiguous, and do not collide with existing names.
Script Integration (MUST)
Scripts that generate files MUST follow the naming conventions defined in the naming-conventions skill.
Requirements:
- Declare a reference to the naming-conventions skill in script header comments
- Generated file/directory names MUST use kebab-case
- Validate output names against convention rules before writing
Reference comment example:
/**
* @reference .ai/skills/standards/naming-conventions/SKILL.md
*/
Implementation guidance:
- Import or read the naming-conventions skill path when generating output paths
- Scripts under
.ai/scripts/ should programmatically validate generated names
- When scaffolding projects, apply kebab-case to all generated directories/files
Global Rules (MUST)
- Use kebab-case (lowercase + hyphens) by default:
skill-name, sync-skills
- Avoid spaces and special characters (except
.-prefixed directories)
- Recommended charset:
[a-z0-9-._]
- Directory names express "scope/role"; file names express "type/content"
- Avoid non-maintainable buckets like
misc/ or temp/
Directory Layout (MUST)
SSOT Root
- SSOT root is fixed:
.ai/
- SSOT subdirectories:
.ai/skills/ (skills and workflows live here)
.ai/scripts/ (maintenance scripts)
.ai/rules/ (if using rules)
Skill Entry Stubs
- Entry stub roots are fixed:
.codex/skills/
.claude/skills/
Notes:
- Stubs contain only
SKILL.md pointers back to .ai/skills/
- Do not edit stub directories directly; regenerate with
.ai/scripts/sync-skills.mjs
Other Top-Level Directories (Recommended)
docs/project/: project-specific documentation (requirements, blueprints)
scripts/: script entrypoints (cross-platform can share the same base name with different suffixes)
init/: bootstrap materials (if present)
Temporary Directory (MUST)
Use .ai/.tmp/ for temporary environments, caches, and generated intermediate files.
Rules:
- All temporary files MUST be placed under
.ai/.tmp/
- Do NOT create
temp/, tmp/, temporary/, or similar directories elsewhere
.ai/.tmp/ SHOULD be added to .gitignore
- Script-generated artifacts, build caches, and intermediate outputs go here
Usage examples:
.ai/.tmp/cache/ - cached data for scripts
.ai/.tmp/build/ - intermediate build outputs
.ai/.tmp/sandbox/ - temporary test environments
Cleanup:
- Scripts are responsible for cleaning up their own temporary files
- Stale files in
.ai/.tmp/ may be deleted without notice
Skill Naming (MUST)
Skill Directory
- Path:
.ai/skills/.../<skill-name>/SKILL.md (taxonomy directories are allowed)
<skill-name>: kebab-case; encode capability/domain/tool
- Avoid ambiguous names
Examples:
skill-creator
repo-init
doc-style-guide
Skill Name Field
- The
name in SKILL.md frontmatter MUST match the leaf directory name
- Use capability-oriented names (verb + domain/tool)
Supporting Files
- Use kebab-case or snake_case for filenames
- Allowed:
reference.md, examples.md, scripts/, templates/
- Forbidden:
resources/ subdirectory
Workflow Naming
- Workflows are stored as skills
- Name by intent/process:
refactor-planner, release-checklist
- Path:
.ai/skills/.../<workflow-name>/SKILL.md
Template Placeholder Conventions (MUST)
Use consistent placeholder formats in template files:
| Format |
Usage |
Example |
<placeholder> |
User-editable content (manual fill) |
<Task Title>, <One-sentence goal> |
{{variable}} |
Script-replaced variables (auto-generated) |
{{agent_id}}, {{timestamp}} |
$ENV_VAR |
Environment variable reference |
$DATABASE_URL, $API_KEY |
Rules:
<placeholder>: Angle brackets indicate the user must replace this content manually
{{variable}}: Double curly braces indicate scripts will substitute this value automatically
- Do NOT mix formats in the same context (e.g., don't use
<var> for script substitution)
- Template files SHOULD include comments explaining which placeholders are user-filled vs auto-replaced
Examples:
# User-filled template (roadmap.md)
## Goal
- <One-sentence goal statement>
# Script-generated template (verification-report.md)
- Agent ID: {{agent_id}}
- Generated: {{timestamp}}
Versioning and Changes (SHOULD)
- Prefer explicit version fields / change logs for SSOT content
- If the directory structure changes, update all of:
- Naming conventions documentation
- Path constants/mappings in
.ai/scripts/
- Usage examples in
README.md
Verification
Check naming compliance:
- All directories use kebab-case
- No spaces or special characters in names
- Skill
name field matches directory name
- No
resources/ directories under skills
Boundaries
- Do NOT use spaces in directory or file names
- Do NOT create
misc/, temp/, or similar catch-all directories
- Do NOT use uppercase in directory names (except for special files like
SKILL.md, README.md)
Included assets
None.
1---2name: naming-conventions3description: Apply consistent naming conventions for directories, files, and identifiers - covers kebab-case rules, SSOT layout, skill naming standards, and script-generated file paths (including temporary files under .ai/.tmp/).4---56# Naming Conventions78## Purpose910Define naming conventions for directories, files, and identifiers with these goals:11- **Scriptability**: scripts can locate files reliably with fewer branches12- **Portability**: cross OS/IDE moves should require zero or minimal renaming13- **Readability**: humans and LLMs can infer purpose and scope from names1415## When to use1617Use the naming-conventions skill when:18- Creating new directories or files19- Naming skills, workflows, or commands20- Reviewing code for naming consistency21- Setting up CI checks for naming standards22- **Scripts generating files** (see Script Integration below)2324## Inputs2526- The item to name (directory, file, skill, identifier)27- Context (SSOT content, provider stubs, general repo files)2829## Outputs3031- Correctly named items following conventions32- Validation results for existing names333435## Steps361. Identify what you are naming (file, directory, module, component, hook, API surface, configuration key, or data entity).372. Choose the most relevant convention section below and follow the MUST rules first.383. Propose 2–3 candidates and select the one that matches existing local conventions and avoids ambiguous abbreviations.394. Apply the chosen name consistently across declarations and references (imports, exports, docs, and tests).405. Verify that the resulting names are searchable, unambiguous, and do not collide with existing names.4142## Script Integration (MUST)4344Scripts that generate files MUST follow the naming conventions defined in the naming-conventions skill.4546**Requirements:**47- Declare a reference to the naming-conventions skill in script header comments48- Generated file/directory names MUST use kebab-case49- Validate output names against convention rules before writing5051**Reference comment example:**52```javascript53/**54 * @reference .ai/skills/standards/naming-conventions/SKILL.md55 */56```5758**Implementation guidance:**59- Import or read the naming-conventions skill path when generating output paths60- Scripts under `.ai/scripts/` should programmatically validate generated names61- When scaffolding projects, apply kebab-case to all generated directories/files6263## Global Rules (MUST)6465- Use **kebab-case** (lowercase + hyphens) by default: `skill-name`, `sync-skills`66- Avoid spaces and special characters (except `.`-prefixed directories)67- Recommended charset: `[a-z0-9-._]`68- Directory names express "scope/role"; file names express "type/content"69- Avoid non-maintainable buckets like `misc/` or `temp/`7071## Directory Layout (MUST)7273### SSOT Root7475- SSOT root is fixed: `.ai/`76- SSOT subdirectories:77 - `.ai/skills/` (skills and workflows live here)78 - `.ai/scripts/` (maintenance scripts)79 - `.ai/rules/` (if using rules)8081### Skill Entry Stubs8283- Entry stub roots are fixed:84 - `.codex/skills/`85 - `.claude/skills/`8687Notes:88- Stubs contain only `SKILL.md` pointers back to `.ai/skills/`89- Do not edit stub directories directly; regenerate with `.ai/scripts/sync-skills.mjs`9091### Other Top-Level Directories (Recommended)9293- `docs/project/`: project-specific documentation (requirements, blueprints)94- `scripts/`: script entrypoints (cross-platform can share the same base name with different suffixes)95- `init/`: bootstrap materials (if present)9697### Temporary Directory (MUST)9899Use `.ai/.tmp/` for temporary environments, caches, and generated intermediate files.100101**Rules:**102- All temporary files MUST be placed under `.ai/.tmp/`103- Do NOT create `temp/`, `tmp/`, `temporary/`, or similar directories elsewhere104- `.ai/.tmp/` SHOULD be added to `.gitignore`105- Script-generated artifacts, build caches, and intermediate outputs go here106107**Usage examples:**108- `.ai/.tmp/cache/` - cached data for scripts109- `.ai/.tmp/build/` - intermediate build outputs110- `.ai/.tmp/sandbox/` - temporary test environments111112**Cleanup:**113- Scripts are responsible for cleaning up their own temporary files114- Stale files in `.ai/.tmp/` may be deleted without notice115116## Skill Naming (MUST)117118### Skill Directory119120- Path: `.ai/skills/.../<skill-name>/SKILL.md` (taxonomy directories are allowed)121- `<skill-name>`: kebab-case; encode capability/domain/tool122- Avoid ambiguous names123124Examples:125- `skill-creator`126- `repo-init`127- `doc-style-guide`128129### Skill Name Field130131- The `name` in SKILL.md frontmatter MUST match the **leaf** directory name132- Use capability-oriented names (verb + domain/tool)133134### Supporting Files135136- Use kebab-case or snake_case for filenames137- Allowed: `reference.md`, `examples.md`, `scripts/`, `templates/`138- Forbidden: `resources/` subdirectory139140## Workflow Naming141142- Workflows are stored as skills143- Name by intent/process: `refactor-planner`, `release-checklist`144- Path: `.ai/skills/.../<workflow-name>/SKILL.md`145146## Template Placeholder Conventions (MUST)147148Use consistent placeholder formats in template files:149150| Format | Usage | Example |151|--------|-------|---------|152| `<placeholder>` | User-editable content (manual fill) | `<Task Title>`, `<One-sentence goal>` |153| `{{variable}}` | Script-replaced variables (auto-generated) | `{{agent_id}}`, `{{timestamp}}` |154| `$ENV_VAR` | Environment variable reference | `$DATABASE_URL`, `$API_KEY` |155156**Rules:**157- `<placeholder>`: Angle brackets indicate the user must replace this content manually158- `{{variable}}`: Double curly braces indicate scripts will substitute this value automatically159- Do NOT mix formats in the same context (e.g., don't use `<var>` for script substitution)160- Template files SHOULD include comments explaining which placeholders are user-filled vs auto-replaced161162**Examples:**163164```markdown165# User-filled template (roadmap.md)166## Goal167- <One-sentence goal statement>168169# Script-generated template (verification-report.md)170- Agent ID: {{agent_id}}171- Generated: {{timestamp}}172```173174## Versioning and Changes (SHOULD)175176- Prefer explicit version fields / change logs for SSOT content177- If the directory structure changes, update all of:178 - Naming conventions documentation179 - Path constants/mappings in `.ai/scripts/`180 - Usage examples in `README.md`181182## Verification183184Check naming compliance:185- All directories use kebab-case186- No spaces or special characters in names187- Skill `name` field matches directory name188- No `resources/` directories under skills189190## Boundaries191192- Do NOT use spaces in directory or file names193- Do NOT create `misc/`, `temp/`, or similar catch-all directories194- Do NOT use uppercase in directory names (except for special files like `SKILL.md`, `README.md`)195196## Included assets197198None.