Documentation creation, editing, and review with CLEO style guide compliance. Coordinates specialized skills for lookup, writing, and review. Use when creating or updating documentation files, consolidating scattered documentation, or validating documentation against style standards. Triggers on documentation tasks, doc update requests, or style guide compliance checks.
Protocol: @src/protocols/implementation.md Type: Context Injection (cleo-subagent) Version: 3.0.0
Context injection for documentation tasks spawned via cleo-subagent. Orchestrates documentation workflows by coordinating specialized skills for lookup, writing, and review.
| Skill | Purpose | Invoke When |
|---|---|---|
ct-docs-lookup | Query existing docs, find references | Discovery phase, checking what exists |
ct-docs-write | Create/edit docs with CLEO style | Writing or updating content |
ct-docs-review | Check compliance with style guide | Quality validation before completion |
BEFORE creating ANY new file, you MUST:
1. Search for existing documentation on the topic
2. Identify the canonical location for this information
3. UPDATE the existing file instead of creating a new one
4. Only create new files when NO suitable location exists
Before writing anything, discover what exists:
# List documentation structure
Glob: pattern="docs/**/*.md"
# Search for existing content on topic
Grep: pattern="{TOPIC_KEYWORDS}" path="docs/"
# Check for related files
Grep: pattern="{RELATED_TERMS}" path="docs/" output_mode="files_with_matches"
Invoke /ct-docs-lookup for deeper documentation research.
| Question | Action |
|---|---|
| Does a doc file for this topic exist? | UPDATE that file |
| Is the info scattered across files? | CONSOLIDATE into canonical location |
| Is there a related doc that should include this? | ADD section to that file |
| Is this truly new with no home? | CREATE minimal new file |
Invoke /ct-docs-write for content creation.
For EXISTING files:
For CONSOLIDATION:
For NEW files (last resort):
Invoke /ct-docs-review for quality validation.
Checklist:
Before completing, verify:
@skills/_shared/task-system-integration.md
# 1. Read task details
cleo show {TASK_ID}
# 2. Start task
cleo start {TASK_ID}
# 3. Execute documentation workflow (phases 1-4)
# 4. Complete task when done
cleo complete {TASK_ID}
# 5. Link research if applicable
cleo research link {TASK_ID} {RESEARCH_ID}
@skills/_shared/subagent-protocol-base.md
{{OUTPUT_DIR}}/{{MANIFEST_PATH}}Write to {{OUTPUT_DIR}}/:
# Documentation Update: {TITLE}
**Date**: {DATE} | **Agent**: ct-documentor | **Status**: complete
---
## Summary
{What was updated and why}
## Changes Made
### File: {path/to/file.md}
- {Change 1}
- {Change 2}
## Files NOT Created (Avoided Duplication)
- {Considered creating X but updated Y instead}
- {Found existing coverage in Z}
## Verification
- [ ] Changes don't duplicate existing content
- [ ] Cross-references updated
- [ ] Examples tested
- [ ] Style guide compliance verified via ct-docs-review
Append ONE line to {{MANIFEST_PATH}}:
{"id":"docs-{TOPIC}-{DATE}","file":"{DATE}_docs-{TOPIC}.md","title":"Documentation Update: {TITLE}","date":"{DATE}","status":"complete","agent_type":"documentation","topics":["documentation","{topic}"],"key_findings":["Updated {file} with {change}","Consolidated {topic} docs into {canonical-location}","Avoided duplication by updating existing {file}"],"actionable":false,"needs_followup":[],"linked_tasks":["{TASK_ID}"]}
/ct-docs-write invoked for content creation/ct-docs-review invoked for quality validationcleo complete