craft-cli 0.7.0: faster reads and a portable skill library
craft-cli now keeps common reads close to the local Craft cache, bounds the output an agent needs, and reads published skills through an explicit collection workflow.
craft-cli 0.7.0 is out. Release on GitHub.
The release makes the common read path feel closer to a local Markdown folder while keeping Craft’s structure intact. On this Mac, a medium document measured 934 ms through the original API content-only path and 58 ms from Craft Desktop’s local cache. An identical Markdown file took 3 ms. The large-document comparison was 1,680 ms, 86 ms, and 4 ms respectively.
Warm filesystem medians on one Mac, fresh process per read. The original path used the API; the current path reads Desktop’s cache. Network and source selection explain most of the gain. Benchmark method and samples.
Read only what the agent needs
craft read and craft cat can now shape output at the command line:
craft read <id> --head 30
craft read <id> --lines 20:60
craft read <id> --outline
craft read <id> --budget 4000
craft cat <id1> <id2> --budget 8000These controls reduce the text sent into an agent’s context while preserving the source document. The full source is still retrieved before shaping. Local-capable reads use Craft Desktop’s read-only cache when available; API remains the fallback, and every write still goes through the API. When a caller needs immediate remote confirmation after a write, use --source api and account for Desktop’s sync lag.
Skills from a Craft collection
The new craft lib commands make a remote skill collection discoverable for agents:
craft lib list --collection COLLECTION_ID --profile PROFILE --json
craft lib get skill-name --collection COLLECTION_ID --profile PROFILE
craft lib export skill-name --collection COLLECTION_ID --profile PROFILE --out ./generated-skillslist returns metadata only, so an agent can choose by name, description, status, and tags before fetching one body. get selects an exact published skill. export produces one portable SKILL.md, adds its frontmatter, reports a SHA-256, and refuses to overwrite an existing skill directory. Drafts and legacy rows require explicit review flags.
The library supports a single-file skill made from text, code, and separator blocks. It does not package supporting files, install or execute a skill, synchronize it, or claim that every agent harness can load it. Register the exported directory through the target harness’s own documented skill path, then run that harness’s activation check.
Our principles are simple: aim to keep common local actions under 100 ms, preserve Craft’s document structures, and avoid duplicating the source of truth. Craft owns the cache and synchronization. The CLI works around those structures without modifying them or maintaining another content store. Optional skill export is a snapshot, not a second synchronized library.
Backlinks are now opt-in with --links, content-only API reads need one request, and multi-document cat shares one local reader.
Upgrade
cd ~/dev/tools/craft-cli
git pull
./install.sh
craft source auto
craft doctor --json