Token导航 LogoToken导航TokenDH.com
研究检索操作浏览器github未标认证来源可访问许可证需确认审计通过

docs-generator文档生成器

Agent Skill

用于辅助文档、README、Markdown、说明文和内容稿件的整理与改写。它适合让 Agent 提炼结构、补齐章节、统一术语、检查链接或把零散材料整理成可读文档。使用时应保留项目已有事实、命令和路径,不要把未确认的信息写成确定结论;涉及对外文案时,还需要控制语气,避免过度营销或夸大能力。

总安装

190

周安装

8

GitHub Stars

2

下载量

67
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:docs-generator(文档生成器)
来源仓库:https://github.com/ajianaz/skills-collection
仓库路径:skills/docs-generator
安装命令:
npx skills add https://github.com/ajianaz/skills-collection --skill docs-generator
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/ajianaz/skills-collection --skill docs-generator

简介

用于生成轻量级、面向 AI 的高效文档结构,减少 token 消耗。

  • 适用于 AGENTS.md 和 agent.d 格式的说明文自动生成与维护。
  • 采用 JIT 索引原则,仅提供路径和命令而非全文内容。
  • 安装方式:npx skills add https://github.com/ajianaz/skills-collection --skill docs-generator。
  • 子文件夹文档应包含更多细节,根目录文档保持简洁通用指引。

SKILL.md

Documentation Generator

Generate hierarchical documentation structures optimized for AI coding agents with minimal token usage. Supports AGENTS.md, agent.d, and custom documentation formats.

Core Principles

  1. Root documentation is LIGHTWEIGHT - Only universal guidance, links to sub-files (~100-200 lines max)
  2. Nearest-wins hierarchy - Agents read closest documentation to file being edited
  3. JIT indexing - Provide paths/globs/commands, NOT full content
  4. Token efficiency - Small, actionable guidance over encyclopedic docs
  5. Sub-folder files have MORE detail - Specific patterns, examples, commands
  6. Flexible output formats - Support for AGENTS.md, agent.d, and custom documentation types

Workflow

Phase 0: Document Type Confirmation

Before generating, confirm with user:

  1. Document format: AGENTS.md, agent.d, or custom name?
  2. Target audience: AI agents, developers, or both?
  3. Scope: Root only, sub-folders only, or full hierarchy?
  4. Special requirements: Any specific sections or patterns?

Phase 1: Repository Analysis

Analyze and report:

  1. Repository type: Monorepo, multi-package, or simple?
  2. Tech stack: Languages, frameworks, key tools
  3. Major directories needing own documentation:

- Apps (apps/web, apps/api, apps/mobile) - Services (services/auth, services/transcribe) - Packages (packages/ui, packages/shared) - Workers (workers/queue, workers/cron)

  1. Build system: pnpm/npm/yarn workspaces? Turborepo? Lerna?
  2. Testing setup: Jest, Vitest, Playwright, pytest?
  3. Key patterns: Organization, conventions, examples, anti-patterns

Present as structured map before generating files.

Phase 2: Root Documentation

Create lightweight root (~100-200 lines):

For AGENTS.md format:

# Project Name

## Project Snapshot
[3-5 lines: repo type, tech stack, note about sub-documentation files]

## Root Setup Commands
[5-10 lines: install, build all, typecheck all, test all]

## Universal Conventions
[5-10 lines: code style, commit format, branch strategy, PR requirements]

## Security & Secrets
[3-5 lines: never commit tokens, .env patterns, PII handling]

## JIT Index
### Package Structure
- Web UI: `apps/web/` -> [see apps/web/AGENTS.md](apps/web/AGENTS.md)
- API: `apps/api/` -> [see apps/api/AGENTS.md](apps/api/AGENTS.md)

### Quick Find Commands
- Search function: `rg -n "functionName" apps/** packages/**`
- Find component: `rg -n "export.*ComponentName" apps/web/src`
- Find API routes: `rg -n "export const (GET|POST)" apps/api`

## Definition of Done
[3-5 lines: what must pass before PR]

For agent.d format:

# Project Name

## project_snapshot
repo_type: "monorepo"
tech_stack: ["typescript", "react", "node"]
note: "See subdirectories for agent.d files"

## root_setup
install: "pnpm install"
build: "pnpm build"
test: "pnpm test"
typecheck: "pnpm typecheck"

## conventions
code_style: "prettier + eslint"
commit_format: "conventional"
branch_strategy: "gitflow"

## jit_index
packages = {
  web_ui = "apps/web/agent.d"
  api = "apps/api/agent.d"
}

## quick_find
search_function = "rg -n \"functionName\" apps/** packages/**"
find_component = "rg -n \"export.*ComponentName\" apps/web/src"
find_api = "rg -n \"export const (GET|POST)\" apps/api"

For Custom Documentation:

# Project Documentation

## Overview
[Brief project description and architecture]

## Getting Started
[Setup instructions for new developers]

## Architecture
[High-level system design and patterns]

## Development Guidelines
[Coding standards and best practices]

## Module Index
[Links to detailed documentation for each module]

Phase 3: Sub-Folder Documentation

For each major package, create detailed documentation:

AGENTS.md format:

# Package Name

## Package Identity
[2-3 lines: what it does, primary tech]

## Setup & Run
[5-10 lines: install, dev, build, test, lint commands]

## Patterns & Conventions
[10-20 lines - MOST IMPORTANT SECTION]
- File organization rules
- Naming conventions
- Examples with actual file paths:
  - DO: Use pattern from `src/components/Button.tsx`
  - DON'T: Class components like `src/legacy/OldButton.tsx`
  - Forms: Copy `src/components/forms/ContactForm.tsx`
  - API calls: See `src/hooks/useUser.ts`

## Key Files
[5-10 lines: important files to understand package]
- Auth: `src/auth/provider.tsx`
- API client: `src/lib/api.ts`
- Types: `src/types/index.ts`

## JIT Index Hints
[5-10 lines: search commands for this package]
- Find component: `rg -n "export function .*" src/components`
- Find hook: `rg -n "export const use" src/hooks`
- Find tests: `find . -name "*.test.ts"`

## Common Gotchas
[3-5 lines if applicable]
- "Auth requires NEXT_PUBLIC_ prefix for client-side"
- "Always use @/ imports for absolute paths"

## Pre-PR Checks
[2-3 lines: copy-paste command]
pnpm --filter @repo/web typecheck && pnpm --filter @repo/web test

agent.d format:

# Package Name

## package_identity
purpose = "React web application"
tech = ["react", "typescript", "tailwind"]

## setup
install = "pnpm install"
dev = "pnpm dev"
build = "pnpm build"
test = "pnpm test"
lint = "pnpm lint"

## patterns
file_organization = """
src/
  components/    # React components
  hooks/         # Custom hooks
  lib/           # Utilities
  types/         # TypeScript types
"""

naming = "PascalCase for components, camelCase for functions"

examples = [
  { do = "Use pattern from src/components/Button.tsx" }
  { dont = "Class components like src/legacy/OldButton.tsx" }
  { forms = "Copy src/components/forms/ContactForm.tsx" }
  { api = "See src/hooks/useUser.ts" }
]

## key_files
auth = "src/auth/provider.tsx"
api_client = "src/lib/api.ts"
types = "src/types/index.ts"

## jit_hints
find_component = "rg -n \"export function .*\" src/components"
find_hook = "rg -n \"export const use\" src/hooks"
find_tests = "find . -name \"*.test.ts\""

## gotchas
[
  "Auth requires NEXT_PUBLIC_ prefix for client-side"
  "Always use @/ imports for absolute paths"
]

## pre_pr_checks
command = "pnpm --filter @repo/web typecheck && pnpm --filter @repo/web test"

Phase 4: Special Templates

Design System / UI Package

## Design System
- Components: `packages/ui/src/components/**`
- Use design tokens from `packages/ui/src/tokens.ts`
- Component gallery: `pnpm --filter @repo/ui storybook`
- Examples:
  - Buttons: `packages/ui/src/components/Button/Button.tsx`
  - Forms: `packages/ui/src/components/Input/Input.tsx`

Database / Data Layer

## Database
- ORM: Prisma / Drizzle / TypeORM
- Schema: `prisma/schema.prisma`
- Migrations: `pnpm db:migrate`
- Connection: via `src/lib/db.ts` singleton
- NEVER run migrations in tests

API / Backend Service

## API Patterns
- REST routes: `src/routes/**/*.ts`
- Auth middleware: `src/middleware/auth.ts`
- Validation: Zod schemas in `src/schemas/**`
- Errors: `ApiError` from `src/lib/errors.ts`
- Example: `src/routes/users/get.ts`

Testing

## Testing
- Unit: `*.test.ts` colocated
- Integration: `tests/integration/**`
- E2E: `tests/e2e/**` (Playwright)
- Single test: `pnpm test -- path/to/file.test.ts`
- Mocks: `src/test/mocks/**`

Output Format

Provide files in order:

  1. Analysis Summary
  2. Root documentation (complete)
  3. Each Sub-Folder documentation (with file path)

Format:

---
File: `AGENTS.md` (root)
---
[content]

---
File: `apps/web/AGENTS.md`
---
[content]

Or for agent.d:

---
File: `agent.d` (root)
---
[content]

---
File: `apps/web/agent.d`
---
[content]

Or for custom documentation:

---
File: `README.dev.md` (root)
---
[content]

---
File: `apps/web/README.dev.md`
---
[content]

Quality Checklist

Before generating, verify:

  • Root documentation under 200 lines
  • Root links to all sub-documentation files
  • Each sub-file has concrete examples (actual paths)
  • Commands are copy-paste ready
  • No duplication between root and sub-files
  • JIT hints use actual patterns (ripgrep, find, glob)
  • Every "DO" has real file example
  • Every "DON'T" references real anti-pattern
  • Pre-PR checks are single commands
  • Document format matches user requirements
  • All requested sections are included

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

36.07%
按下载量换算24

Claude

29.07%
按下载量换算19

Cursor

19.36%
按下载量换算13

Gemini CLI

8.7%
按下载量换算6

安全审计

Gen Agent Trust Hub

通过

Snyk

通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills