Token导航 LogoToken导航TokenDH.com
研究检索执行命令clawhub未标认证来源可访问clear审计提醒

doc-orchestrator文档协调员

Agent Skill

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

总安装

11,238

周安装

473

GitHub Stars

公开资料未说明

下载量

3,935
OpenClaw

安装说明

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

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

请帮我安装这个 Agent Skill:doc-orchestrator(文档协调员)
来源仓库:https://github.com/nicolayao/doc-orchestrator
安装命令:
openclaw skills install doc-orchestrator
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

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

ClawHubOpenClaw
openclaw skills install doc-orchestrator

简介

协调子代理完成多章节长文档的并行生成。

  • 适用于 PRD、研究报告与技术规格等大型项目。
  • 保持各章节风格一致性与逻辑连贯性。doc-orchestrator 属于研究检索类 Skill,可作为该场景下的辅助能力补充。
  • 通过 clawhub 安装,需定义清晰的章节分工策略。
  • 建议在复杂项目中启用以降低上下文断裂风险。

SKILL.md

name
doc-orchestrator
description
Orchestrate multi-chapter document generation using sub-agents. Use when producing long structured documents (PRDs, technical specs, research reports, design docs, worldbuilding) that exceed single-agent context limits. Handles dependency analysis, contract-first decomposition, serial/parallel scheduling, file isolation, state persistence, and consistency validation.

Doc Orchestrator

Generate long, multi-chapter documents by coordinating sub-agents with a contract-first, serial-then-parallel strategy and persistent orchestration state.

When This Applies

  • Document has 3+ chapters/sections with cross-references
  • Total expected output > 500 lines
  • Multiple sections share definitions (names, enums, constants, values)

Core Principles

  1. Contract First — Define all shared definitions before delegating
  2. File Isolation — Each sub-agent writes to its own file; main agent merges
  3. State Persistence — Write orchestration state to JSON so context compaction can't break the workflow

Workflow

Phase 1 — Analyze Dependencies

Build a dependency graph. For each pair ask: "Does chapter B need chapter A's output?"

Classify:

  • Contract — defines shared values (main agent writes directly)
  • Serial — has upstream dependency (spawn after dependency completes)
  • Parallel — no unresolved dependencies (run concurrently)

Optimize: if multiple chapters depend only on the contract, they can run in parallel.

Phase 2 — Initialize State File

Create {task-dir}/{TASK-ID}-orchestration.json:

{
  "document": "Document Title",
  "contract_file": "TASK-XXX-contract.md",
  "final_file": "TASK-XXX-final.md",
  "chapters": {
    "ch1": {"title": "Overview", "status": "done", "file": "TASK-XXX-contract.md", "deps": []},
    "ch2": {"title": "Characters", "status": "pending", "file": "TASK-XXX-ch2.md", "deps": ["ch1"]},
    "ch3": {"title": "Abilities", "status": "pending", "file": "TASK-XXX-ch3.md", "deps": ["ch1"]},
    "ch4": {"title": "Factions", "status": "pending", "file": "TASK-XXX-ch4.md", "deps": ["ch1", "ch2"]}
  }
}

Status values: pending | running | done | failed

Update this file after every state change. After context compaction, read this file to restore full state.

Phase 3 — Write the Contract

Main agent writes all contract chapters directly. Include a Global Conventions table:

## Global Conventions
| Item        | Value       | Referenced by  |
|-------------|-------------|----------------|
| Score range | 1-5 integer | ch5 API, ch6   |

This is the single source of truth.

Phase 4 — Execute (Serial + Parallel)

For each chapter whose deps are all done:

  1. Update state: "status": "running"
  2. Spawn sub-agent with the prompt template (see below)
  3. On completion: update state to "done"; check what new chapters are unblocked
  4. On failure: update state to "failed"; decide retry or main-agent fallback

Spawn all unblocked chapters in parallel. Wait for serial dependencies.

After context compaction: read the orchestration JSON to recover state, then continue.

Phase 5 — Merge & Validate

Concatenate files in chapter order. During merge:

  1. Strip duplicate document titles — Sub-agents often repeat the top-level # Document Title. Remove all occurrences except the one in the contract file:
   # Remove duplicate H1 titles during merge (keep only from contract)
   cat contract.md > final.md
   for f in ch2.md ch3.md ... ; do
     sed '/^# Document Title$/d' "$f" >> final.md
   done
  1. Run consistency checks:
   grep -n "conflicting_value" final.md
   grep -o "'[a-z_]*'" final.md | sort | uniq
  1. Fix any issues before delivering.

Sub-Agent Prompt Template

## Task: Write [Chapter Title] for [Document Name]

**Read first:** `path/to/contract.md`
Pay attention to Global Conventions table (section X.X).

**Write to:** `path/to/output-chN.md` (new file, do NOT modify other files)

**IMPORTANT formatting rules:**
- Do NOT include the document title (# Document Title) — it belongs only in the contract
- Start your file directly with the chapter heading (## Chapter N: Title)
- Do NOT repeat definitions from the contract; reference them

### Content requirements:
[chapter-specific requirements]

### Constraints (must match contract):
- [constraint 1]
- [constraint 2]

Anti-Patterns

Don'tDo Instead
Rely on context memory for orchestration statePersist state to JSON file
Let sub-agents write to the same fileEach writes own file; main agent merges
Skip formatting rules in promptExplicitly say "no document title, start with ## chapter heading"
Assume sub-agents won't hit content filtersHave fallback: main agent writes sensitive chapters directly
Skip consistency check after mergeAlways grep for known conflict patterns
Use bigger model to brute-force long outputSmaller model + smaller task > bigger model + huge task
Poll sub-agents in a loopUse push-based completion (auto-announce)

Decision Flowchart

Document request received
  |
  +-- < 500 lines expected? --> Write directly (no orchestration)
  |
  +-- 500-1500 lines, no cross-refs? --> Simple parallel (each chapter = own file)
  |
  +-- > 500 lines WITH cross-references?
       |
       1. Analyze dependency graph
       2. Create orchestration state JSON
       3. Main agent writes contract chapters
       4. Serial chain for dependent chapters
       5. Parallel burst for independent chapters
       6. Merge + strip duplicate titles + validate
       7. Deliver

Lessons from Real Usage

Test 1: PRD (9 chapters, technical)

MetricNaive Parallel (v1)Contract-First (v2)
Output1,405 lines3,055 lines
ConsistencyScore 1-5 vs 1-10 conflictZero conflicts
File integrityChapters overwrittenAll preserved
Rework4 chapters rewrittenNone

Test 2: Worldbuilding Bible (7 chapters, creative writing)

MetricResult
Output2,170 lines
ConsistencyZero conflicts (names, factions, abilities all matched)
Issues hitContent filter blocked ch5 twice; ch6 output wrong chapter content
RecoveryMain agent wrote ch5 directly; ch6 retried successfully
Duplicate titles4 of 6 sub-agent files repeated doc title (fixed in merge)

Key Takeaways

  • Content filters: Sensitive topics (war, conflict) may trigger model safety filters in sub-agents. Fallback: main agent writes those chapters, or rephrase with softer language
  • Wrong output: Sub-agents occasionally output content for the wrong chapter. Always verify file content, not just file existence
  • Title duplication: Sub-agents copy the document title from the contract file. Prompt template now explicitly forbids this; merge step strips duplicates as safety net

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

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

04

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

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

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

能力 4

补充不同宿主或平台的使用分布数据

能力 5

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

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

平台分布

OpenClaw

77.1%
按下载量换算3,034

安全审计

VirusTotal

可疑

ClawScan

通过

Static analysis

未展示

权限和风险

执行命令

安装流程涉及命令执行,可能通过 openclaw skills install doc-orchestrator 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

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

来源信息

继续浏览同类 Skills