| name | project-capsule |
| description | Pack a directory or module into one markdown or YAML file. Unpack YAML or markdown back into a directory of code. Harvest fenced listings from a book, article, tutorial, or any doc into a YAML capsule, then export that capsule to disk. Generate a complete runnable companion project as FullContentYAML (Poetry, Task, pyenv) from chapter content. Use when the user says "import the login module to a single markdown file", pack/capture a folder, dump a slice of the repo, export yaml to a directory, harvest code examples from a blog post, or generate a book/article/tutorial example as yaml. Wraps create_project_markdown and yaml_project. Works on Claude Code, Grok Build, Codex, and Cursor.
|
| metadata | {"short-description":"Pack a module. Harvest a doc. Generate a runnable example."} |
Project Capsule
Capture just the slice you need — a module, a directory, or the listings
in a book / article / tutorial — into one markdown or YAML file. Reverse the
process to rebuild a directory. This skill installs and drives two Spillwave
tools:
You (the agent) parse natural language, install the tools if missing, resolve
the smallest path/regex that matches the request, then run the tool.
Non-negotiable
- Prefer a slice, never the whole repo, unless the user said "entire project"
- Respect
.gitignore and skip node_modules, .git, dist, build, venvs
- Markdown for LLM paste/context. YAML when they need round-trip (import + export)
- After packing, report path, file count, and byte size
- After unpacking, list written files. Never overwrite without saying so
- If tools are missing, install them, then run. Do not fake the output
- Write
.pmarkdownc/config.yml before markdown-packing a TS/React tree — stock
create_project_markdown does not include .tsx, .jsx, .md, or .json
Natural language → action
| User says | You do |
|---|
| import / pack / capture X to a markdown file | create-project-markdown [dir] --include <basename-regex> -o X.md |
| pack X as yaml / snapshot X | yaml-project generate full --project-dir <dir> --include <glob> --outfile X.yaml |
| export / apply / unpack this yaml into a directory | yaml-project apply create FILE.yaml --output-dir <dir> |
| extract / harvest listings from this book, article, tutorial | Parse fences → YAML capsule → optional apply. See from-document.md |
| generate a book / chapter / article / tutorial example | Follow from-document.md mode 2 → FullContentYAML → optional apply |
| dump this folder for the LLM | markdown unless they named yaml |
create-project-yaml is the same binary as yaml-project (wrapper vs poetry script).
The source document type does not matter. Book, article, tutorial, workshop
notes — if it has code listings (or teaches a topic that needs a companion
repo), this skill handles it.
Resolving "the login module"
- Search the workspace for paths matching
login (files and directories)
- Treat the containing directory of hits as the module (include siblings:
session.ts next to login.ts is in scope)
- create-project-markdown --include is a regex against the filename
basename, not the full path.
auth/login will not match login.ts.
Prefer create-project-markdown src/auth -o login.md, or
--include "login|session|password|types"
- yaml-project --include is a glob (
**/*login*) and --project-dir
slices a directory
- Confirm the file list in one line before writing if more than ~20 files
Install (once per machine)
See install.md. Short version: clone the markdown script (it has no
setup.py), pip/poetry-install yaml_project, put both on PATH.
Commands
Read commands.md for exact flags. Read formats.md for markdown/YAML shapes.
Read from-document.md for harvest vs generate from any document with listings.
Output you owe the user
## Capsule
- Action: pack | unpack | extract | book
- Format: markdown | yaml
- Scope: src/auth (login module)
- Output: login.md (12 files, 18.4 KB)
- Tool: create-project-markdown src/auth -o login.md