Generate rich documentation with dynamic code snippets and execution checks.
Install
mkdir -p .claude/skills/hype && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/9608" && unzip -o skill.zip -d .claude/skills/hype && rm skill.zipInstalls to .claude/skills/hype
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Write and maintain documentation using the Hype content generation tool with dynamic code execution, snippets, and includesKey capabilities
- →Embed source code
- →Execute Go commands
- →Include documentation partials
How it works
It extends Markdown with tags to execute code and include snippets dynamically.
Inputs & outputs
When to use hype
- →Embed source code from files
- →Show live command output
- →Include documentation partials
About this skill
Hype Documentation Tool
Hype is a content generation tool that extends Markdown with dynamic features for creating rich, automated documentation that stays in sync with your code.
Core Principles
- Packages: Keep content in small, reusable units with relative links
- Reuse: Write documentation once, use everywhere (blog, book, README)
- Includes: Compose larger documents from smaller partials
- Validation: Verify code samples compile and run correctly
- Asset validation: Ensure local assets like images exist
Tag Reference
<code> - Display Source Code
Display source code from files with syntax highlighting.
<!-- Entire file -->
<code src="main.go"></code>
<!-- Named snippet -->
<code src="main.go" snippet="example"></code>
<!-- Alternative snippet syntax -->
<code src="main.go#example"></code>
<!-- Line range (0-indexed) -->
<code src="main.go" range="10:20"></code>
<!-- Override language -->
<code src="config.txt" language="yaml"></code>
<!-- Escape HTML entities -->
<code src="template.html" esc></code>
<go> - Execute Go Commands
Run Go commands and display output. Supports all go subcommands.
<!-- Run a Go file -->
<go run="main.go"></go>
<!-- Run with source directory -->
<go src="myapp" run="."></go>
<!-- Build and show output -->
<go build="."></go>
<!-- Run tests -->
<go test="-v ./..."></go>
<!-- Show documentation for a symbol -->
<go doc="fmt.Println"></go>
<!-- Cross-compilation -->
<go build="." goos="linux" goarch="amd64"></go>
<!-- With environment variables -->
<go run="main.go" environ="DEBUG=true,LOG_LEVEL=info"></go>
<!-- Show code then run it -->
<go src="examples" code="main.go" run="."></go>
<!-- Expected non-zero exit -->
<go run="fail.go" exit="1"></go>
<!-- Custom timeout -->
<go run="slow.go" timeout="60s"></go>
<cmd> - Execute Shell Commands
Run arbitrary shell commands and capture output.
<!-- Simple command -->
<cmd exec="echo Hello World"></cmd>
<!-- Command in a directory -->
<cmd exec="ls -la" src="mydir"></cmd>
<!-- Expect failure -->
<cmd exec="false" exit="1"></cmd>
<!-- Any non-zero exit -->
<cmd exec="might-fail" exit="-1"></cmd>
<!-- With environment -->
<cmd exec="printenv FOO" environ="FOO=bar"></cmd>
<!-- Custom timeout (default 30s) -->
<cmd exec="long-process" timeout="120s"></cmd>
<!-- Stabilize dynamic output for reproducible documentation -->
<!-- Without this, regenerating docs creates diffs even when code hasn't changed -->
<cmd exec="go version"
replace-1="go1\.\d+\.\d+"
replace-1-with="goX.X.X">
</cmd>
<!-- Multiple replacements for timestamps, versions, UUIDs -->
<!-- Essential for blogs and READMEs you regenerate regularly -->
<cmd exec="./build.sh"
replace-1="\d{4}-\d{2}-\d{2}"
replace-1-with="[DATE]"
replace-2="[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}"
replace-2-with="[UUID]">
</cmd>
<include> - Include Other Documents
Compose documents from partials.
<!-- Include another markdown file -->
<include src="docs/intro.md"></include>
<!-- Include from subdirectory -->
<include src="chapters/getting-started/index.md"></include>
Included files maintain their relative paths for assets and links.
<youtube> - Embed YouTube Videos
Embed YouTube videos in documentation.
<!-- Basic embed -->
<youtube id="dQw4w9WgXcQ"></youtube>
<!-- With custom title -->
<youtube id="dQw4w9WgXcQ" title="Introduction Video"></youtube>
The id must be exactly 11 alphanumeric characters (the video ID from YouTube URLs).
Mermaid Diagrams - ASCII Art Diagrams
Include Mermaid diagrams that render as ASCII art. Use standard fenced code blocks with the mermaid language:
```mermaid
graph LR
A[Start] --> B{Decision}
B -->|Yes| C[Action]
B -->|No| D[End]
```
This renders as ASCII art in both HTML and Markdown output:
┌──────────┐ ┌─────────────┐
│ A[Start] ├────►│ B{Decision} │
└──────────┘ └─────────────┘
Supported diagram types:
- Flowcharts/Graphs (
graph LR,graph TD,flowchart LR,flowchart TD) - Sequence diagrams (
sequenceDiagram)
Limitations: Subgraphs, class diagrams, state diagrams, Gantt charts, and pie charts are not supported.
Snippet System
Snippets let you extract specific portions of code files. Mark regions with comments:
Go, JavaScript, TypeScript
// snippet:example
func Example() {
fmt.Println("This is the snippet content")
}
// snippet:example
HTML, Markdown
<!-- snippet:header -->
<header>Navigation here</header>
<!-- snippet:header -->
Ruby, Shell, YAML
# snippet:config
database:
host: localhost
port: 5432
# snippet:config
Supported Extensions
| Extension | Comment Format |
|---|---|
.go | // snippet:name |
.js, .ts | // snippet:name |
.html, .md | <!-- snippet:name --> |
.rb | # snippet:name |
.sh | # snippet:name |
.yaml, .yml | # snippet:name |
.env, .envrc | # snippet:name |
CLI Commands
Export to Markdown
# Generate README from hype document
hype export -format=markdown -f hype.md > README.md
# Export with custom output
hype export -format=markdown -f docs/guide.md -o output.md
Export to HTML
# Export with default GitHub theme
hype export -format=html -f document.md > output.html
# Export with a specific theme
hype export -format=html -theme solarized-dark -f document.md -o output.html
# Use custom CSS
hype export -format=html -css ./my-styles.css -f document.md -o output.html
# Raw HTML without styling
hype export -format=html -no-css -f document.md
# List available themes
hype export -themes
Built-in Themes: github (default, auto light/dark), github-dark, solarized-light, solarized-dark, swiss, air, retro
| Flag | Description |
|---|---|
-theme <name> | Select a built-in theme (default: github) |
-css <path> | Use a custom CSS file (overrides -theme) |
-no-css | Output raw HTML without styling |
-themes | List available themes and exit |
Live Preview
Start a live preview server with automatic file watching and browser reload:
# Basic preview
hype preview -f hype.md
# Auto-open browser
hype preview -f hype.md -open
# Different port
hype preview -f hype.md -port 8080
# Watch directories (include . to watch source file location)
hype preview -f hype.md -w . -w ./src -w ./images
# Filter by extensions
hype preview -f hype.md -e md,html,go,png
# Include/exclude patterns
hype preview -f hype.md -i "**/*.md" -x "**/vendor/**"
# Use a theme
hype preview -f hype.md -theme solarized-dark
# List themes
hype preview -themes
| Flag | Alias | Default | Description |
|---|---|---|---|
-f | hype.md | Source file to preview | |
-port | 3000 | Server port | |
-w | -watch | Directories to watch (repeatable) | |
-e | -ext | File extensions to watch (comma-separated) | |
-i | -include | Glob patterns to include (repeatable) | |
-x | -exclude | Glob patterns to exclude (repeatable) | |
-d | -debounce | 300ms | Debounce delay before rebuild |
-v | -verbose | false | Log file changes |
-open | false | Auto-open browser | |
-theme | github | Preview theme | |
-css | Custom CSS file | ||
-themes | List themes and exit | ||
-timeout | 0 | Execution timeout |
Blog Generator
Create static blogs with code execution:
# Create new blog
hype blog init mysite
cd mysite
# Create article
hype blog new hello-world
# Build and serve
hype blog build
hype blog serve
# Live reload during development
hype blog serve --watch
# Theme management
hype blog theme list
hype blog theme add developer
Built-in Blog Themes: suspended (minimal), developer (terminal-style), cards (grid layout)
For full blog documentation, see blog/README.md.
Code Block Handling
Hype follows CommonMark semantics for code blocks:
Inline vs Block Code
- Inline code (single-line): Rendered with backticks
`code` - Block code (multi-line or with language attribute): Rendered as fenced code blocks
The routing happens at parse time based on content and attributes.
Showing Code Block Examples in Documentation
When you need to show fenced code block syntax as an example (like documenting how to use mermaid), use 4-space indentation in your source markdown:
```mermaid
graph LR
A --> B
```
Hype outputs this using tilde fences (~~~) to avoid conflicts with the backticks in the content:
~~~plain
```mermaid
graph LR
A --> B
```
This follows CommonMark best practice: tildes and backticks ignore each other, so a tilde fence can safely contain content with triple backticks.
### Inline Code with Backticks
For inline code containing backticks, Hype uses more backticks to escape:
| Content | Output |
|---------|--------|
| `var x = 1` | `` `var x = 1` `` |
| Use `` `fmt.Println` `` | ```` `` Use `fmt.Println` `` ```` |
| Has ``` `` ``` double | ````` ``` Has `` double ``` ````` |
## Best Practices
### Directory Structure
```
project/
├── .hype/
│ ├── hype.md # Main document
│ └── docs/
│ ├── intro.md
│ ├── examples/
│ │ ├── basic.go
│ │ └── advanced.go
│ └── images/
│ └── diagram.png
├── README.md # Generated output
└── src/
└── ...
```
### Document Organization
1. Use `<include>` to break large documents into manageable pieces
2. Keep code examples in dedicated directories near your documentation
3. Use snippets to show relevant portions of larger files
4. Set appropriate t
---
*Content truncated.*
When not to use it
- →Complex application logic
Prerequisites
Limitations
- →Limited to documentation generation
How it compares
It keeps documentation in sync with code through live execution and snippet extraction.
Compared to similar skills
hype side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| hype (this skill) | 0 | 6mo | Review | Intermediate |
| ml-paper-writing | 48 | 6mo | Review | Advanced |
| docs-review | 10 | 7mo | No flags | Beginner |
| claude-md-improver | 21 | 6mo | Review | Beginner |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
ml-paper-writing
davila7
Write publication-ready ML/AI papers for NeurIPS, ICML, ICLR, ACL, AAAI, COLM. Use when drafting papers from research repos, structuring arguments, verifying citations, or preparing camera-ready submissions. Includes LaTeX templates, reviewer guidelines, and citation verification workflows.
docs-review
metabase
Review documentation changes for compliance with the Metabase writing style guide. Use when reviewing pull requests, files, or diffs containing documentation markdown files.
claude-md-improver
anthropics
Audit and improve CLAUDE.md files in repositories. Use when user asks to check, audit, update, improve, or fix CLAUDE.md files. Scans for all CLAUDE.md files, evaluates quality against templates, outputs quality report, then makes targeted updates. Also use when the user mentions "CLAUDE.md maintenance" or "project memory optimization".
write-docs
tldraw
Writing SDK documentation for tldraw. Use when creating new documentation articles, updating existing docs, or when documentation writing guidance is needed. Applies to docs in apps/docs/content/.
update-docs
vercel
This skill should be used when the user asks to "update documentation for my changes", "check docs for this PR", "what docs need updating", "sync docs with code", "scaffold docs for this feature", "document this feature", "review docs completeness", "add docs for this change", "what documentation is affected", "docs impact", or mentions "docs/", "docs/01-app", "docs/02-pages", "MDX", "documentation update", "API reference", ".mdx files". Provides guided workflow for updating Next.js documentation based on code changes.
wiki-architect
microsoft
Analyzes code repositories and generates hierarchical documentation structures with onboarding guides. Use when the user wants to create a wiki, generate documentation, map a codebase structure, or understand a project's architecture at a high level.