CClaude Code Catalog
All Skills

Auto Doc Generator

DocumentationBeginner

Analyzes specified code files or modules to auto-generate documentation including function signatures, parameter descriptions, return values, and usage examples.

Trigger/docs [file]
Frequency1-2x/week

Open source maintainer behind on documentation? Run /docs src/utils to auto-generate from signatures to examples

DocumentationAutomationReadability

How It Works

Run /docs [file]
Phase 1: 3 analyses in parallel
sig-parse
Parse signatures
type-extract
Extract type info
usage-find
Collect usage patterns
Generate markdown docs
Parameter table + return values + usage examples

Skill Code

# Doc Generator Skill ## Trigger: /docs [file or directory] When invoked: 1. Analyze target code: - Exported functions/classes - Parameter types and defaults - Return types - Usage patterns in codebase 2. Generate documentation: - Function signatures with descriptions - Parameter table with types and defaults - Return value description - Usage examples from actual codebase 3. Format: ## functionName(params) Description of what this function does. ### Parameters | Name | Type | Default | Description | |--------|--------|---------|--------------| | param1 | string | - | What it does | ### Returns `ReturnType` — Description ### Example ```typescript const result = functionName("input"); ```

Copy and paste into your CLAUDE.md to start using immediately.

How Auto Doc Generator Works

Doc Generator reads your source code files, extracts function signatures, class structures, and inline comments, then produces formatted API documentation with parameter descriptions, return types, and usage examples.

When to Use Auto Doc Generator

Invaluable when you need to document an existing codebase that has grown without documentation — it understands code intent from implementation patterns and generates docs that actually help users of your API.

Key Strengths

  • Extracts documentation from code structure, not just comments
  • Generates usage examples based on actual function signatures
  • Supports multiple output formats (Markdown, JSDoc, etc.)
  • Keeps docs in sync with code changes on each run

Popular in Other Categories