v0.21.0
Context-optimization release. Cuts the per-skill canopy tax from ~700 lines of always-loaded runtime spec to ~150–400 depending on feature usage. Fully backward-compatible — skills authored on prior versions continue to work without changes.
Added
- Sliced primitive spec.
skills/canopy-runtime/references/framework-ops.md(monolithic, 151 lines) is replaced by per-feature slice files underreferences/ops/:core.md—IF,ELSE_IF,ELSE,END,BREAK(always loaded)interaction.md—ASK,SHOW_PLANcontrol-flow.md—SWITCH,CASE,DEFAULT,FOR_EACHparallel.md—PARALLELsubagent.md— subagent dispatch (marker + bold call-site)explore.md—EXPLORE+## Agentsoft-compatverify.md—VERIFY_EXPECTEDreferences/ops.md— index pointing at the slices
- Per-skill
metadata.canopy-featuresmanifest. Skills declare which feature slices they use; the runtime loads only those (coreis implicit-always-loaded). Auto-generated by/canopy create/scaffold/improve/convert-to-canopy. Authors don't maintain it by hand. /canopy measure-context <skill>op (skills/canopy/references/ops/measure-context.md). Reports the line-count breakdown a skill costs to load — marker block + runtime baseline + manifest-driven slices + skill-local files. Highlights drift between the manifest and actual feature usage. Pure inspection; no mutations.- MEASURE_CONTEXT registered in operations dispatch + detection +
dispatch-schema.jsonenum. Trigger phrases include "measure context", "context size", "context cost", "manifest size".
Changed
- Slim marker block in
assets/constants/marker-block.md(and the byte-identical mirrors ininstall.sh build_marker_block()andinstall.ps1 Build-MarkerBlock). The block is now a 2-line trigger + pointer (~5 lines including markers) — down from ~30 lines. Pre-v0.21.0 markers inlined the full spec dump in every canopy-active project's ambient instructions; the new block defers all spec tocanopy-runtime/SKILL.md, loaded only when the runtime is engaged. canopy-runtime/SKILL.mddocuments the manifest-aware load procedure: read the skill's frontmatter, parsemetadata.canopy-features, loadcore.mdplus the listed slices. Manifest absent → load every slice (back-compat).runtime-claude.mdandruntime-copilot.mdreference the slice index instead of the deleted monolithicframework-ops.md. Cross-references updated throughout.skill-resources.mdtrimmed: subagent dispatch content moved toops/subagent.md. Adds a new section documenting the manifest.- Authoring agent ops updated for the manifest:
create.md— computes the manifest from the planned tree and emits it in produced SKILL.md frontmatter.scaffold.md— template includes the manifest stub.improve.md— audits skills for missing or drifted manifests; proposes additions/corrections in the decision table.validate.md— new check pass: manifest presence (warning), feature-vs-tree drift (warning),corelisted (warning), unknown values (warning).convert-to-canopy.md— emits the manifest in produced SKILL.md.
assets/constants/validate-checks.md— new "Warnings → manifest" section enumerating the four drift cases and the "manifest absent" warning.assets/templates/skill.md— template now includesmetadata.canopy-features: [interaction](the typical small-skill default).
Removed
skills/canopy-runtime/references/framework-ops.md— the monolithic primitive file is split acrossreferences/ops/<slice>.md. Skills that referenced it by path will need to update; this is rare in practice (the runtime resolves primitives by lookup, not by path)./canopy improvereports any stale path references.
Notes
- No new feature surface. All v0.20.1 features (subagent dispatch, PARALLEL, etc.) keep working unchanged. v0.21.0 only changes how the runtime spec is structured and loaded.
- Marker-block parity. Canonical,
install.sh,install.ps1all updated. The vscode extension'sMARKER_BLOCKconstant must follow in a sibling-repo PR. - Back-compat. Skills without a
canopy-featuresmanifest continue to run — the runtime falls back to load-everything./canopy validatewarns; never errors. Adoption is gradual. - Footprint estimate. A skill using
[interaction, verify]loads roughly 400 lines of runtime context (down from ~700). A skill using[parallel, subagent]loads ~470. A skill with[interaction, control-flow, parallel, subagent, explore, verify](full feature surface) loads ~770 — comparable to pre-v0.21.0.
Verifying this release
# Verify the signed tag (uses GitHub's pubkey for SSH/GPG signatures)
git verify-tag v0.21.0
# Verify SLSA build provenance for the install tarball
gh attestation verify canopy-0.21.0.tar.gz --owner kostiantyn-matsebora