Instructs AI agents on documentation standards for design docs, folder READMEs, source code interfaces, and test cases
Enforces documentation standards for design docs, folder READMEs, source code interfaces, and test cases.
/plugin marketplace add Synthesys-Lab/agentize/plugin install synthesys-lab-agentize@Synthesys-Lab/agentizeThis skill inherits all available tools. When active, it can use any tool Claude has access to.
README.mdThis skill instructs AI agents on how to maintain comprehensive documentation throughout the development lifecycle. It defines documentation standards that are enforced via pre-commit linting for structural requirements, while providing guidance on content quality and workflow integration.
Good documentation is:
This project maintains three levels of documentation:
docs/*) - Architecture and design decisionsREADME.md files) - Purpose and file organization.md companions to source files) - External and internal APIsLocation: docs/* directory
Purpose: Document architectural decisions, design rationale, and high-level project structure.
When to create/update:
Not enforced by linting: Creating design documents requires human judgment about what constitutes a "high-level design" versus implementation details.
Content guidelines:
Examples of good design documents:
docs/git-msg-tags.md - Documents commit message tag standardsdocs/developer.md - Developer workflow and contribution guidelinesdocs/options.md - SDK configuration options and usageWhen NOT to create design docs:
.md files instead)Requirement: Every folder (except hidden folders like .git) MUST have a README.md file.
Enforced by: Pre-commit linting (scripts/lint-documentation.sh)
Purpose: Document folder purpose and file organization so developers can quickly understand the codebase structure.
When to create:
Required content:
Examples of good folder README.md:
# Skills Directory
This directory contains all Claude Code skills that define AI agent behavior.
## Organization
Each skill is in its own subdirectory with a `SKILL.md` file:
- `commit-msg/` - Skill for creating meaningful git commits
- `fork-dev-branch/` - Skill for creating development branches
- `milestone/` - Skill for incremental implementation with milestone commits
## Adding New Skills
Create a new subdirectory and add a `SKILL.md` file with frontmatter defining
the skill name and description.
Format flexibility:
Requirement: Every source code file MUST have a corresponding .md file documenting its interfaces.
File types requiring documentation (enforced by linting):
*.py → *.md*.c, *.cpp, *.cxx, *.cc → *.mdEnforced by: Pre-commit linting (scripts/lint-documentation.sh)
Naming convention: Same prefix as source file
foo.py → foo.mdbar.cpp → bar.mdbaz.c → baz.mdRequired sections:
Document all interfaces exposed to external callers:
Document internal implementation details:
Example interface documentation:
# validate_target_dir.sh
Script for validating target directories before SDK initialization.
## External Interface
### Command-line usage
```bash
./validate_target_dir.sh <target_dir> <mode>
Parameters:
target_dir: Path to directory to validatemode: Either "init" or "update"Exit codes:
Output: Error messages to stderr listing validation failures
Validates that the target directory exists.
Validates that the user has write access to the directory.
Scans for files that would conflict with SDK initialization. Returns list of conflicting file paths.
Specific validation for "init" mode (directory must be empty or non-existent).
Specific validation for "update" mode (directory must have existing SDK structure).
**When implementation changes**:
- Update interface documentation to match
- During milestones, temporary doc-code mismatch is acceptable (see below)
- Before final delivery, all documentation must match implementation
## Test Documentation
**Requirement**: Every test case **MUST** have documentation explaining what it tests.
**Enforced by**: Pre-commit linting (`scripts/lint-documentation.sh`)
**Format options**:
1. **Inline comments** within the test file (preferred for simple tests)
2. **Companion `.md` file** (for complex test suites)
**Required content**:
- What is being tested (feature or behavior)
- Expected outcome
- Any setup or preconditions
**Example with inline comments**:
```bash
#!/bin/bash
# Test suite for documentation linting
# Tests that the linter correctly identifies missing documentation
set -e
# Test 1: Linter passes with complete documentation
# Expected: Exit code 0, no errors
test_complete_documentation() {
# Setup: Create temporary directory with all docs present
...
}
# Test 2: Linter fails when folder missing README.md
# Expected: Exit code 1, error message lists folder
test_missing_folder_readme() {
...
}
Example with companion .md file:
For test_documentation_lint.sh, create test_documentation_lint.md:
# Documentation Linter Test Suite
Tests for `scripts/lint-documentation.sh` to verify it correctly validates
documentation completeness.
## Test Cases
### test_complete_documentation
**Purpose**: Verify linter passes when all documentation is present
**Setup**: Temporary directory with source files and corresponding .md files
**Expected**: Exit code 0, no error output
### test_missing_folder_readme
**Purpose**: Verify linter catches folders without README.md
**Setup**: Create folder without README.md
**Expected**: Exit code 1, error message listing the folder
...
Linting check:
test_*.sh), linter checks for either:
# Test N: or # Test: or function comments.md file with same prefixThis project follows strict design-first test-driven development:
During milestone commits, documentation and code may be temporarily inconsistent:
Why this happens:
When it's acceptable:
N/M tests passedWhen it's NOT acceptable:
The documentation linter (scripts/lint-documentation.sh) runs as part of the
pre-commit hook and validates:
README.md.md filesBypassing the linter:
For milestone commits where documentation is complete but implementation is incomplete:
git commit --no-verify -m "milestone: ..."
The --no-verify flag bypasses all pre-commit hooks, including:
IMPORTANT: Only bypass for milestone commits on development branches. Never bypass for final delivery commits or commits to main branch.
Milestone progression example:
Milestone 1: Documentation complete (bypass linting OK)
- All .md files created and document final interfaces
- Implementation: 0% complete
- Tests: 0/10 passed (expected, no implementation yet)
- Commit with: --no-verify
Milestone 2: Partial implementation (bypass linting OK)
- Documentation: Still accurate for final state
- Implementation: 60% complete
- Tests: 6/10 passed
- Commit with: --no-verify
Delivery: All tests pass (NO bypass)
- Documentation: Matches implementation exactly
- Implementation: 100% complete
- Tests: 10/10 passed
- Commit without: --no-verify (linter must pass)
This documentation guideline integrates with other project skills:
plan-guideline skillWhen creating implementation plans, the plan-guideline skill references these
documentation standards:
.md files to create/updatemilestone skillThe milestone skill uses these guidelines for incremental development:
--no-verify bypass acceptable for milestone commitscommit-msg skillThe commit-msg skill considers documentation standards:
[docs] tagEnforced by linting (structural requirements):
README.md existence.md file correspondenceGuided by skill (content quality):
Workflow integration:
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.