deepagents-architectur…
Guides architectural decisions for Deep Agents applications. Use when deciding between Deep Agents vs alternatives, choosing backend strategies, designing…
Generate first-draft technical documentation from code analysis
$ npx -y skills add existential-birds/beagle --skill draft-docs --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/draft-docsContext preview
The summary Claude sees to decide when to auto-load this skill.
Generate first-draft technical documentation from code analysis
name: draft-docs description: Generate first-draft technical documentation from code analysis disable-model-invocation: true
Generate Tutorial, How-To, Reference, or Explanation documentation drafts to `docs/drafts/` for review before publishing. These are the four [Diataxis](https://diataxis.fr/) types — see [docs-style/references/diataxis-compass.md](../docs-style/references/diataxis-compass.md) for the full type-selection procedure.
Invoke the **draft-docs** skill with a topic prompt, e.g. `draft-docs "Document the authentication middleware"`.
Before parsing input, gather project context:
# Check for existing docs structure ls -la docs/ 2>/dev/null || echo "No docs/ directory found" # Identify documentation framework ls docs/navigation.json docs/mint.json docs/docusaurus.config.js docs/mkdocs.yml 2>/dev/null | head -1 # Check for existing drafts ls docs/drafts/*.md 2>/dev/null || echo "No existing drafts" # Get recent code changes for context git diff --name-only $(git merge-base HEAD main)..HEAD 2>/dev/null | head -20
**Capture:**
Extract from the prompt:
1. **Topic:** What to document (e.g., "authentication middleware") 2. **Content type:** Detect from keywords:
| Keywords | Type | Skill | |----------|------|-------| | "tutorial", "learn", "getting started", "first", "onboarding", "introduction", "build a/your" | Tutorial | [tutorial-docs](../tutorial-docs/SKILL.md) | | "how to", "guide", "steps", "configure", "set up" | How-To | [howto-docs](../howto-docs/SKILL.md) | | "API", "reference", "parameters", "function", "endpoint" | Reference | [reference-docs](../reference-docs/SKILL.md) | | "why", "how does it work", "concept", "background", "rationale", "design decision", "architecture", "trade-offs" | Explanation | [explanation-docs](../explanation-docs/SKILL.md) |
These four types are the quadrants of the [Diátaxis](https://diataxis.fr/) framework — Tutorial (learning), How-To (task), Reference (information), and Explanation (understanding). Decide with the two compass questions — *action or cognition? acquisition or application?* — detailed in [docs-style/references/diataxis-compass.md](../docs-style/references/diataxis-compass.md). Two distinctions resolve most ambiguity:
If ambiguous, ask: "Should this be a Tutorial (learning by doing), a How-To guide (task completion), a Reference doc (technical lookup), or an Explanation (understanding the why behind a concept)?"
Always load both:
1. [docs-style](../docs-style/SKILL.md) - Core writing principles 2. Detected type skill:
Search the codebase for relevant code:
1. **Symbol search:** Find functions, classes, types matching the topic 2. **File search:** Locate related files by name patterns 3. **Reference search:** Find usage examples
Gather:
Apply the loaded skills to generate documentation:
**For Tutorial docs:**
**For Reference docs:**
**For How-To docs:**
**For Explanation docs:**
1. **Create output path:**
2. **Ensure directory exists:**
mkdir -p docs/drafts
3. **Write the draft fi
Image: NASA, Public Domain. Source Beagle is an Agent Skills marketplace: framework-aware code review, documentation, testing, architectural analysis, and git workflows for any compatible coding agent.
Repo: existential-birds/beagle
Guides architectural decisions for Deep Agents applications. Use when deciding between Deep Agents vs alternatives, choosing backend strategies, designing…
Reviews Deep Agents code for bugs, anti-patterns, and improvements. Use when reviewing code that uses create_deep_agent, backends, subagents, middleware, or…
Implements agents using Deep Agents. Use when building agents with create_deep_agent, configuring backends, defining subagents, adding middleware, or setting…
Guides architectural decisions for LangGraph applications. Use when deciding between LangGraph vs alternatives, choosing state management strategies, designing…
Reviews LangGraph code for bugs, anti-patterns, and improvements. Use when reviewing code that uses StateGraph, nodes, edges, checkpointing, or other LangGraph…
Implements stateful agent graphs using LangGraph. Use when building graphs, adding nodes/edges, defining state schemas, implementing checkpointing, handling…