← 返回
开发者工具

Auto Doc AI

基于 AST 和 LLM 自动生成 Python 代码文档(Google Style docstring)。 自动分析代码结构,生成符合 Google Style 的 docstring。
基于 AST 和 LLM 自动生成 Python 代码文档(Google Style docstring)。 自动分析代码结构,生成符合 Google Style 的 docstring。
antonia-sz
开发者工具 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 505
下载
💾 4
安装
1
版本
#latest

概述

Auto Doc AI — 智能代码文档生成器

自动分析 Python 代码结构,生成符合 Google Style 的 docstring 文档。

功能特性

  • 🔍 基于 AST 解析代码结构
  • 🤖 智能函数/类/方法分析
  • 📝 生成 Google Style docstring
  • 📁 支持单文件或整个目录批量处理
  • 🔄 支持增量更新(跳过已有文档的函数)

使用方法

为单个文件生成文档

/generate-docs /path/to/your_script.py

为整个目录生成文档

/generate-docs /path/to/src/ --recursive

强制更新已有文档

/generate-docs /path/to/src/ --overwrite

预览模式(不写入文件)

/generate-docs /path/to/your_script.py --dry-run

生成的文档格式示例

def process_data(data, threshold=0.5):
    """处理输入数据并返回过滤后的结果。

    Args:
        data (list): 输入数据列表。
        threshold (float, optional): 过滤阈值,默认为 0.5。

    Returns:
        list: 过滤后的数据列表。

    Raises:
        ValueError: 如果数据格式无效。
    """
    pass

注意事项

  • 仅支持 Python 3.7+ 的文件
  • 建议先使用 --dry-run 预览生成的文档
  • 使用 --overwrite 会替换所有现有 docstring

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-31 08:41 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

developer-tools

CodeConductor.ai

larsonreever
AI驱动平台,提供快速全栈开发、智能体、工作流自动化及低代码AI集成的可扩展产品创建。
★ 68 📥 180,472
security-compliance

Frontend Design Pro — 专业前端设计规范

antonia-sz
前端设计质量提升 skill。让 AI 生成的 UI/前端代码更专业,避免常见设计反模式。 参考 impeccable 项目的设计语言规范,提供 audit/polish/critique 等设计审查命令。 触发词:/audit /poli
★ 17 📥 8,206
developer-tools

Gog

steipete
Google Workspace 命令行工具,支持 Gmail、日历、云端硬盘、通讯录、表格和文档。
★ 921 📥 185,925