AgentSkillsCN

planner-output-templates

为文档结构文件制定输出模板与格式化规则,明确四部分结构(拟议根目录、站点地图、页面规划、导航规则)、前言元数据规范,以及确认信息。适用于生成文档结构输出时使用。

SKILL.md
--- frontmatter
name: planner-output-templates
description: Output templates and formatting rules for documentation structure files. Defines the four-section format (Proposed Root, Sitemap, Page Plan, Navigation Rules), front matter schema, and confirmation messages. Use when generating documentation structure output.
user-invocable: false

Planner Output Templates

Templates and formatting rules for documentation structure files generated by the deepwiki-planner agent.

Output File Structure

The documentation structure file contains four sections with front matter:

markdown
---
title: Documentation Structure for [Project Name]
generated_at: [ISO timestamp]
commit: [hash if available]
completeness_score: [X]%
total_pages: [count]
---

## 1) Proposed Root
[Content]

## 2) Sitemap (Tree Structure)
[Content]

## 3) Page Plan
[Content]

## 4) Navigation Rules
[Content]

---
Analysis Completeness: [X]%
Missing Sections: [List if any]
Total Pages: [count]

Section 1: Proposed Root

State the root folder path, naming conventions, and versioning rules.

Template:

markdown
## 1) Proposed Root

**Root folder:** `wiki/` (or project convention)

**Naming conventions:**
- Folders: `kebab-case`
- Pages: `kebab-case.md`
- Rule: `<area>-<topic>.md` or `<domain>-<feature>.md`

**Version stamp rule:**
Include in front matter of all pages:
```yaml
---
title: Page Title
generated_at: [ISO timestamp]
commit: [hash if available]
---

Rationale: [Explain based on repo size, maturity, team size]

code

---

## Section 2: Sitemap (ASCII Tree)

Create directory structure using the selected pattern (horizontal, vertical, or hybrid).

**Template:**
```markdown
## 2) Sitemap (Tree Structure)

**Pattern:** [Selected pattern with rationale]

\`\`\`
wiki/
├── README.md
├── overview/
│   ├── system-overview.md
│   ├── technology-stack.md
│   └── glossary.md
├── architecture/
│   ├── system-architecture.md
│   └── patterns.md
├── [domain]/
├── workflows/
├── deployment/
├── security/
├── quality/
└── development/
\`\`\`

**Total pages:** [count]
**Estimated scope:** [Small/Medium/Large]

ASCII Tree Characters:

  • ├── for items with siblings below
  • └── for last item in a directory
  • for vertical continuation
  • Indent nested items with 4 spaces

Section 3: Page Plan (File-by-File)

For each page in the sitemap, define its purpose, sections, diagrams, and source files.

Template:

markdown
## 3) Page Plan

### [Section Name]

#### Page: `path/to/page.md`

**Purpose:** [1-2 sentences: what this page covers and why it matters]

**Required sections:**
- Section 1: [Description]
- Section 2: [Description]
- Code examples: Yes/No
- Tables: Yes/No

**Required diagrams:**
- [c4-context | c4-container | c4-component | sequence | deployment | dfd | activity | class | integration | network]

**Relevant source files:**
- `src/path/to/file.ts` — [Why relevant]
- `src/path/**/*.ts` — [Pattern/folder relevance]

Page Plan Guidelines:

  • Group pages by their parent folder/section
  • Every page must have a clear, non-vague purpose
  • Every page must link to at least one relevant source file
  • Diagrams should match page content (don't specify diagrams that aren't needed)

Section 4: Navigation Rules

Define how pages interconnect and organize.

Template:

markdown
## 4) Navigation Rules

### Index/Hub Page (`README.md`)

**Layout:**

DeepWiki: [System Name]

Quick Navigation:

code

### Breadcrumb Navigation

All pages include: `Home > [Folder] > [Page]`

Example:
```markdown
*[Home](../README.md) > [Architecture](./README.md) > System Architecture*

# System Architecture
...

Module/Service Naming Convention

Folder names match analyzer module/service names (in kebab-case). Each folder gets README.md with overview, then sub-pages for details.

Cross-References

Always link to related pages using relative paths: [text](../../path/to/page.md)

Versioning & History

Include "Last Updated" in front matter: last_updated: [ISO timestamp]

code

---

## Confirmation Message

After successfully generating the structure file:

✓ Documentation structure generated File: {wiki_location}/.temp/documentation_structure.md Analysis completeness: [X]% Total pages: [count]

Ready for todo list creation and content generation.

code

---

## Error Message Templates

**Incomplete analysis:**

⚠️ HALT: Codebase analysis incomplete ([X]% completeness). Missing critical sections:

  • [List missing areas]

Please review codebase or provide additional context.

code

**Cannot parse codebase:**

ERROR: Cannot read codebase at {path}

  • Verify path exists and is readable
  • Check for permission issues
code

**Ambiguous module naming:**

⚠️ CLARIFY: Found inconsistent module naming. Recommend using kebab-case throughout: user-auth-service

code

---

**Version:** 1.0
**Last Updated:** 2026-01-22