code-documentation-doc-generate

You are a documentation expert specializing in creating comprehensive, maintainable documentation from code. Generate API docs, architecture diagrams, user guides, and technical references using AI-powered analysis and industry best practices.

31,392 stars
Complexity: easy

About this skill

This skill transforms your AI agent into a dedicated documentation expert, capable of generating comprehensive and maintainable technical documentation directly from code. Leveraging advanced AI analysis and industry best practices, it automates the creation of critical assets such as API documentation, architecture diagrams, user guides, and technical references. Designed as part of the "antigravity-awesome-skills" collection, this skill enhances an agent's ability to interpret code, understand underlying structures, and articulate complex concepts into clear, standardized documentation. It's ideal for streamlining documentation pipelines, ensuring consistency, and significantly reducing the manual effort typically involved in keeping documentation current and accurate. With over 29,000 stars on its host repository, it comes from a trusted source for high-quality AI agent skills.

Best use case

Automating the generation of various documentation types (API, architecture, user guides) from source code. Establishing standardized documentation practices across development teams. Building CI/CD pipelines that automatically update documentation alongside code changes. Accelerating the onboarding process for new developers by providing up-to-date documentation.

You are a documentation expert specializing in creating comprehensive, maintainable documentation from code. Generate API docs, architecture diagrams, user guides, and technical references using AI-powered analysis and industry best practices.

Comprehensive, well-structured, and consistent documentation across API endpoints, architectural components, and user-facing guides. Reduced manual documentation effort and faster time-to-documentation updates. Improved documentation quality and maintainability through AI-powered analysis and adherence to best practices. Standardized documentation outputs, fostering better understanding and collaboration within development teams. Automatically generated diagrams (e.g., Mermaid, PlantUML) that visually represent code architecture.

Practical example

Example input

{
  "skill_name": "code-documentation-doc-generate",
  "action": "generate_api_docs",
  "parameters": {
    "code_source": {
      "type": "github_repo",
      "url": "https://github.com/my-org/my-project",
      "path": "/src/api"
    },
    "output_format": "OpenAPI-YAML",
    "modules_to_focus": ["UserService", "ProductController"],
    "spec_version": "3.0.0"
  }
}

Example output

{
  "status": "success",
  "documentation_files": [
    {
      "filename": "openapi.yaml",
      "content": "openapi: 3.0.0\ninfo:\n  title: My Project API\n  version: 1.0.0\npaths:\n  /users:\n    get:\n      summary: Get all users\n      responses:\n        '200':\n          description: A list of users\n  /products:\n    post:\n      summary: Create a new product\n      requestBody:\n        required: true\n        content:\n          application/json:\n            schema:\n              $ref: '#/components/schemas/Product'\n",
      "format": "OpenAPI-YAML"
    },
    {
      "filename": "architecture_overview.md",
      "content": "# Architecture Overview\n\n```mermaid\ngraph TD\n    A[User] --> B(Frontend);\n    B --> C(Backend API Gateway);\n    C --> D{UserService};\n    C --> E{ProductService};\n    D --> F[Database];\n    E --> F;\n```\n\n## Technical Reference\n...\n",
      "format": "Markdown"
    }
  ],
  "message": "Documentation generated successfully."
}

When to use this skill

  • When you need to rapidly generate or update API specifications from code.
  • When your project requires clear architectural overviews or technical references that reflect the current codebase.
  • When aiming to standardize documentation format and quality across multiple projects.
  • When integrating documentation generation into an automated development workflow.

When not to use this skill

  • For highly conceptual, marketing, or non-technical content that requires creative storytelling or subjective interpretation beyond code analysis.
  • When the codebase is exceptionally poorly structured, undocumented, or uses obscure patterns that might confuse AI analysis, leading to inaccurate outputs.
  • For generating legal or compliance documents where human oversight and specialized expertise are paramount.
  • When sensitive code information requires handling by a strictly isolated or on-premises solution without external AI interaction.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/code-documentation-doc-generate/SKILL.md --create-dirs "https://raw.githubusercontent.com/sickn33/antigravity-awesome-skills/main/plugins/antigravity-awesome-skills-claude/skills/code-documentation-doc-generate/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/code-documentation-doc-generate/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How code-documentation-doc-generate Compares

Feature / Agentcode-documentation-doc-generateStandard Approach
Platform SupportClaudeLimited / Varies
Context Awareness High Baseline
Installation ComplexityeasyN/A

Frequently Asked Questions

What does this skill do?

You are a documentation expert specializing in creating comprehensive, maintainable documentation from code. Generate API docs, architecture diagrams, user guides, and technical references using AI-powered analysis and industry best practices.

Which AI agents support this skill?

This skill is designed for Claude.

How difficult is it to install?

The installation complexity is rated as easy. You can find the installation instructions above.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# Automated Documentation Generation

You are a documentation expert specializing in creating comprehensive, maintainable documentation from code. Generate API docs, architecture diagrams, user guides, and technical references using AI-powered analysis and industry best practices.

## Use this skill when

- Generating API, architecture, or user documentation from code
- Building documentation pipelines or automation
- Standardizing docs across a repository

## Do not use this skill when

- The project has no codebase or source of truth
- You only need ad-hoc explanations
- You cannot access code or requirements

## Context
The user needs automated documentation generation that extracts information from code, creates clear explanations, and maintains consistency across documentation types. Focus on creating living documentation that stays synchronized with code.

## Requirements
$ARGUMENTS

## Instructions

- Identify required doc types and target audiences.
- Extract information from code, configs, and comments.
- Generate docs with consistent terminology and structure.
- Add automation (linting, CI) and validate accuracy.
- If detailed examples are required, open `resources/implementation-playbook.md`.

## Safety

- Avoid exposing secrets, internal URLs, or sensitive data in docs.

## Output Format

- Documentation plan and artifacts to generate
- File paths and tooling configuration
- Assumptions, gaps, and follow-up tasks

## Resources

- `resources/implementation-playbook.md` for detailed examples and templates.

Related Skills

n8n-expression-syntax

31392
from sickn33/antigravity-awesome-skills

Validate n8n expression syntax and fix common errors. Use when writing n8n expressions, using {{}} syntax, accessing $json/$node variables, troubleshooting expression errors, or working with webhook data in workflows.

Developer ToolsClaude

mermaid-expert

31392
from sickn33/antigravity-awesome-skills

Create Mermaid diagrams for flowcharts, sequences, ERDs, and architectures. Masters syntax for all diagram types and styling.

Developer ToolsClaude

mcp-builder-ms

31392
from sickn33/antigravity-awesome-skills

Use this skill when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK).

Developer ToolsClaude

makepad-deployment

31392
from sickn33/antigravity-awesome-skills

CRITICAL: Use for Makepad packaging and deployment. Triggers on: deploy, package, APK, IPA, 打包, 部署, cargo-packager, cargo-makepad, WASM, Android, iOS, distribution, installer, .deb, .dmg, .nsis, GitHub Actions, CI, action, marketplace

Developer ToolsClaude

macos-menubar-tuist-app

31392
from sickn33/antigravity-awesome-skills

Build, refactor, or review SwiftUI macOS menubar apps that use Tuist.

Developer ToolsClaude

kaizen

31392
from sickn33/antigravity-awesome-skills

Guide for continuous improvement, error proofing, and standardization. Use this skill when the user wants to improve code quality, refactor, or discuss process improvements.

Developer ToolsClaude

issues

31392
from sickn33/antigravity-awesome-skills

Interact with GitHub issues - create, list, and view issues.

Developer ToolsClaude

hugging-face-tool-builder

31392
from sickn33/antigravity-awesome-skills

Your purpose is now is to create reusable command line scripts and utilities for using the Hugging Face API, allowing chaining, piping and intermediate processing where helpful. You can access the API directly, as well as use the hf command line tool.

Developer ToolsClaude

git-pushing

31392
from sickn33/antigravity-awesome-skills

Stage all changes, create a conventional commit, and push to the remote branch. Use when explicitly asks to push changes ("push this", "commit and push"), mentions saving work to remote ("save to github", "push to remote"), or completes a feature and wants to share it.

Developer ToolsClaude

git-hooks-automation

31392
from sickn33/antigravity-awesome-skills

Master Git hooks setup with Husky, lint-staged, pre-commit framework, and commitlint. Automate code quality gates, formatting, linting, and commit message enforcement before code reaches CI.

Developer ToolsClaude

gh-review-requests

31392
from sickn33/antigravity-awesome-skills

Fetch unread GitHub notifications for open PRs where review is requested from a specified team or opened by a team member. Use when asked to "find PRs I need to review", "show my review requests", "what needs my review", "fetch GitHub review requests", or "check team review queue".

Developer ToolsClaude

fp-types-ref

31392
from sickn33/antigravity-awesome-skills

Quick reference for fp-ts types. Use when user asks which type to use, needs Option/Either/Task decision help, or wants fp-ts imports.

Developer ToolsClaude