Docy
Overview
Keep policy and reference docs small, named, and injectable. For coding-related
tasks, start by loading the baseline rules from ./references/core/, then return to
this skill only when the task needs additional targeted guidance. Use the bundled
docy CLI to print a doc into the active context with inject or to install a
durable managed rule block into AGENTS.md with install.
Doc Layout
All managed docs live under ./references/ and follow this layout:
./references/
# language specific
- lang/
# always be injected
- core/
# frameworks/dependencies
- vendor/
# special topics
- ref/
- commit-messages.md: Repo-aware commit message drafting; inspect local
history and mirror conventions before writing a subject line
- developer-docs.md: Developer documentation writing, editing, and review
guidance, including page patterns and an editorial checklist
- concise-instructions.md: Terse operator-facing instructions organized
around inputs, invocation, completion evidence, and recovery
- spec.md: Architecture and design specification writing, examples, and
review guidance
- openclaw-docs.md: OpenClaw-specific page taxonomy, heading, docs-index,
editing, and verification conventions layered on developer-docs
- execution-trace.md: How to write runtime-ordered execution trace docs
- no-back-compat.md: Hard-cut product policy; no backwards compatibility
- remove-feature.md: Feature removal hygiene; remove stale docs/tests and
record spec drift in changelog
Loading Rules
For coding-related tasks, use this loading order:
- At startup, inject every doc under
./references/core/. Treat these as the
default rule set, not an optional filter.
- After the core docs are loaded, add non-core docs selectively based on the task.
- Inject
./references/lang/<language>.md only when the task depends on
language-specific rules or idioms.
- Inject
./references/vendor/<dependency-or-framework>.md only when the task
depends on framework, library, or platform behavior.
- Inject
./references/ref/<topic>.md only for focused policies, constraints, or
one-off topics that should shape the solution. For example, inject
./references/ref/remove-feature.md before removing an existing feature.
CLI
Run the bundled CLI directly or put scripts/ on PATH.
docy inject core/main
docy inject ref/commit-messages
docy inject ref/developer-docs
docy inject ref/concise-instructions
docy inject ref/spec
docy inject ref/openclaw-docs
docy inject ref/no-back-compat
docy inject ref/remove-feature
docy inject ref/openclaw-agent-plugins
docy inject ref/execution-trace
docy inject vendor/lerna
docy install core/main
docy install ref/commit-messages
docy install ref/developer-docs
docy install ref/concise-instructions
docy install ref/spec
docy install ref/openclaw-docs
docy install ref/no-back-compat
docy install ref/remove-feature
docy install ref/openclaw-agent-plugins
docy install ref/execution-trace
docy install vendor/lerna
Command behavior:
inject: Discover Markdown files under ./references/ and print the selected
doc to stdout for immediate context injection.
install: Discover the same reference files and add or update the selected
doc as a managed block in the nearest AGENTS.md so the rule remains durable
for later sessions.
Available Docs
./references/core/main.md: Core documentation and technical-writing hygiene.
Always load it to keep adjacent durable docs synchronized and apply universal
rules for terminology, scope, examples, reviews, and diagrams.
./references/vendor/lerna.md: Modern Lerna operating guidance for agents. Use before changing, validating, or releasing code in a Lerna-managed monorepo.
./references/ref/commit-messages.md: Repo-aware commit message drafting. Use
before writing a commit message so the subject mirrors recent local history
instead of forcing one universal style.
./references/ref/developer-docs.md: Developer documentation guidance. Use
before creating, editing, or reviewing READMEs, quickstarts, guides, API, SDK,
CLI, testing, troubleshooting, architecture, or internals documentation.
./references/ref/concise-instructions.md: Concise instruction-document
guidance. Load it after ref/developer-docs when writing or compressing an
operator-facing runbook, setup guide, or command procedure.
./references/ref/spec.md: Design specification guidance. Use before creating,
editing, or reviewing architecture and design specifications so scope,
ownership, interfaces, examples, failure paths, and implementation detail stay
decision-complete without becoming implementation-exhaustive.
./references/ref/openclaw-docs.md: OpenClaw developer documentation overlay.
Load it after ref/developer-docs when creating, editing, or reviewing
OpenClaw topic pages, guides, references, or troubleshooting documentation.
./references/ref/python-preferred-modules.md: Python dependency preferences. Use before building runtime validation or CLI behavior from scratch in Python projects.
./references/ref/typescript-preferred-modules.md: TypeScript dependency preferences. Use before building runtime validation or CLI behavior from scratch in TypeScript projects.
./references/ref/openclaw-agent-plugins.md: OpenClaw plugin authoring guidance. Use before creating or expanding an OpenClaw plugin so capability ownership, entrypoint shape, SDK imports, and route/setup boundaries stay aligned with the architecture docs.
./references/ref/execution-trace.md: Execution trace writing guidance. Use before documenting initialization, startup, request, job, command, or other runtime flows where ordered control flow matters.
./references/ref/no-back-compat.md: Hard-cut product policy. Use before changing
codepaths that would otherwise introduce migrations, fallback behavior, adapters,
or other backwards-compatibility glue.
./references/ref/remove-feature.md: Feature removal hygiene. Use before deleting
or sunsetting an existing feature so docs, tests, and changelog entries stay
consistent while historical specs remain unchanged.
1---2name: docy3description: MANDATORY for every coding-related task, including developer docs. Invoke at session start and load core/main before analysis or edits; never defer until review.4---56# Docy78## Overview910Keep policy and reference docs small, named, and injectable. For coding-related11tasks, start by loading the baseline rules from `./references/core/`, then return to12this skill only when the task needs additional targeted guidance. Use the bundled13`docy` CLI to print a doc into the active context with `inject` or to install a14durable managed rule block into `AGENTS.md` with `install`.1516## Doc Layout1718All managed docs live under `./references/` and follow this layout:1920```sh21./references/22# language specific23- lang/24# always be injected25- core/26# frameworks/dependencies27- vendor/28# special topics29- ref/30 - commit-messages.md: Repo-aware commit message drafting; inspect local31 history and mirror conventions before writing a subject line32 - developer-docs.md: Developer documentation writing, editing, and review33 guidance, including page patterns and an editorial checklist34 - concise-instructions.md: Terse operator-facing instructions organized35 around inputs, invocation, completion evidence, and recovery36 - spec.md: Architecture and design specification writing, examples, and37 review guidance38 - openclaw-docs.md: OpenClaw-specific page taxonomy, heading, docs-index,39 editing, and verification conventions layered on developer-docs40 - execution-trace.md: How to write runtime-ordered execution trace docs41 - no-back-compat.md: Hard-cut product policy; no backwards compatibility42 - remove-feature.md: Feature removal hygiene; remove stale docs/tests and43 record spec drift in changelog44```4546## Loading Rules4748For coding-related tasks, use this loading order:49501. At startup, inject every doc under `./references/core/`. Treat these as the51 default rule set, not an optional filter.522. After the core docs are loaded, add non-core docs selectively based on the task.533. Inject `./references/lang/<language>.md` only when the task depends on54 language-specific rules or idioms.554. Inject `./references/vendor/<dependency-or-framework>.md` only when the task56 depends on framework, library, or platform behavior.575. Inject `./references/ref/<topic>.md` only for focused policies, constraints, or58 one-off topics that should shape the solution. For example, inject59 `./references/ref/remove-feature.md` before removing an existing feature.6061## CLI6263Run the bundled CLI directly or put `scripts/` on `PATH`.6465```bash66docy inject core/main67docy inject ref/commit-messages68docy inject ref/developer-docs69docy inject ref/concise-instructions70docy inject ref/spec71docy inject ref/openclaw-docs72docy inject ref/no-back-compat73docy inject ref/remove-feature74docy inject ref/openclaw-agent-plugins75docy inject ref/execution-trace76docy inject vendor/lerna7778docy install core/main79docy install ref/commit-messages80docy install ref/developer-docs81docy install ref/concise-instructions82docy install ref/spec83docy install ref/openclaw-docs84docy install ref/no-back-compat85docy install ref/remove-feature86docy install ref/openclaw-agent-plugins87docy install ref/execution-trace88docy install vendor/lerna89```9091Command behavior:9293- `inject`: Discover Markdown files under `./references/` and print the selected94 doc to stdout for immediate context injection.95- `install`: Discover the same reference files and add or update the selected96 doc as a managed block in the nearest `AGENTS.md` so the rule remains durable97 for later sessions.9899## Available Docs100101- `./references/core/main.md`: Core documentation and technical-writing hygiene.102 Always load it to keep adjacent durable docs synchronized and apply universal103 rules for terminology, scope, examples, reviews, and diagrams.104- `./references/vendor/lerna.md`: Modern Lerna operating guidance for agents. Use before changing, validating, or releasing code in a Lerna-managed monorepo.105- `./references/ref/commit-messages.md`: Repo-aware commit message drafting. Use106 before writing a commit message so the subject mirrors recent local history107 instead of forcing one universal style.108- `./references/ref/developer-docs.md`: Developer documentation guidance. Use109 before creating, editing, or reviewing READMEs, quickstarts, guides, API, SDK,110 CLI, testing, troubleshooting, architecture, or internals documentation.111- `./references/ref/concise-instructions.md`: Concise instruction-document112 guidance. Load it after `ref/developer-docs` when writing or compressing an113 operator-facing runbook, setup guide, or command procedure.114- `./references/ref/spec.md`: Design specification guidance. Use before creating,115 editing, or reviewing architecture and design specifications so scope,116 ownership, interfaces, examples, failure paths, and implementation detail stay117 decision-complete without becoming implementation-exhaustive.118- `./references/ref/openclaw-docs.md`: OpenClaw developer documentation overlay.119 Load it after `ref/developer-docs` when creating, editing, or reviewing120 OpenClaw topic pages, guides, references, or troubleshooting documentation.121- `./references/ref/python-preferred-modules.md`: Python dependency preferences. Use before building runtime validation or CLI behavior from scratch in Python projects.122- `./references/ref/typescript-preferred-modules.md`: TypeScript dependency preferences. Use before building runtime validation or CLI behavior from scratch in TypeScript projects.123- `./references/ref/openclaw-agent-plugins.md`: OpenClaw plugin authoring guidance. Use before creating or expanding an OpenClaw plugin so capability ownership, entrypoint shape, SDK imports, and route/setup boundaries stay aligned with the architecture docs.124- `./references/ref/execution-trace.md`: Execution trace writing guidance. Use before documenting initialization, startup, request, job, command, or other runtime flows where ordered control flow matters.125- `./references/ref/no-back-compat.md`: Hard-cut product policy. Use before changing126 codepaths that would otherwise introduce migrations, fallback behavior, adapters,127 or other backwards-compatibility glue.128- `./references/ref/remove-feature.md`: Feature removal hygiene. Use before deleting129 or sunsetting an existing feature so docs, tests, and changelog entries stay130 consistent while historical specs remain unchanged.