技能 documentation-generator
📝

documentation-generator

安全 🌐 網路存取📁 檔案系統存取⚙️ 外部命令

為程式碼生成文件

編寫文件需要大量時間且經常被忽視。此技能可自動建立 JSDoc、docstrings、README 檔案以及跨多種程式語言的 API 文件。

支援: Claude Codex Code(CC)
📊 70 充足
1

下載技能 ZIP

2

在 Claude 中上傳

前往 設定 → 功能 → 技能 → 上傳技能

3

開啟並開始使用

測試它

正在使用「documentation-generator」。 Document this function: function calculateTotal(basePrice, taxRate, discount = 0)

預期結果:

  • 生成帶有 @param、@returns 和 @throws 標籤的 JSDoc 註解
  • 包含所有參數的型別資訊
  • 新增顯示輸入和輸出的使用範例
  • 記錄錯誤條件

正在使用「documentation-generator」。 Create a README for my CLI tool

預期結果:

  • 包含功能列表的完整專案概述
  • npm 使用者的安裝說明
  • 帶有命令語法的使用範例
  • 記錄所有命令的 API 參考章節

安全審計

安全
v5 • 1/16/2026

This is a pure prompt-based skill containing only documentation generation instructions for AI assistants. The static scanner flagged metadata fields (source URLs, content hashes), markdown code examples (backticks in code fences), and documentation keywords as security issues. All 30 findings are false positives - no executable code, network calls, command execution, or file system access exists in this skill.

2
已掃描檔案
354
分析行數
3
發現項
5
審計總數
審計者: claude 查看審計歷史 →

品質評分

38
架構
100
可維護性
87
內容
31
社群
100
安全
83
規範符合性

你能建構什麼

為現有程式碼庫建立文件

為舊專案中未記錄的函式和方法新增全面的文件

建立專案文件

為公開儲存庫生成 README 檔案、API 參考和貢獻指南

標準化文件格式

確保專案中多種程式語言的文件風格一致

試試這些提示

基本文件
Use the documentation-generator skill to generate JSDoc comments for the following JavaScript file:
指定格式的文件
@documentation-generator --format google-style Generate Python docstrings for this function with type hints and examples:
僅生成 README
@documentation-generator --readme-only Create a complete README.md for my project including features, installation, usage, and API reference:
多語言專案
Use documentation-generator to document all functions in the src/utils/ directory. Apply appropriate format based on file extension (JSDoc for .js/.ts, Google style for .py, Rustdoc for .rs):

最佳實務

  • 提供完整的函式簽章和參數型別以獲得準確的文件
  • 分享有關邊界情況和效能考量的相關上下文
  • 請求使用您現有的風格撰寫文件以保持程式碼庫的一致性

避免

  • 為沒有註解或結構不清晰的程式碼請求文件
  • 生成文件後未審查業務邏輯的準確性
  • 使用此技能覆蓋精心撰寫的自訂文件

常見問題

支援哪些程式語言?
JavaScript/TypeScript (JSDoc)、Python (Google、NumPy、Sphinx 風格)、Rust (Rustdoc)、Java (Javadoc) 和 Go (GoDoc)。
此技能可以修改我的原始檔案嗎?
不會。此技能生成您可以複製和貼上的文件文字。它沒有檔案系統存取權限。
此技能如何知道我專案的文件風格?
它預設使用每種語言的標準慣例。請指定您偏好的風格或分享現有文件作為參考。
我的程式碼資料安全嗎?
是的。此技能只處理您在對話中明確分享的程式碼。不會儲存或傳送到外部服務。
為什麼文件看起來與我現有的程式碼不同?
此技能使用每種語言的標準格式。請提供您專案風格的範例或要求特定格式。
這與 IDE 程式碼補全有何不同?
此技能生成包含範例和上下文的全面文件。IDE 程式碼補全通常只新增基本簽章。

開發者詳情

檔案結構

📄 SKILL.md