get-tbd 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/dist/bin.mjs +653 -229
  2. package/dist/bin.mjs.map +1 -1
  3. package/dist/cli.mjs +644 -232
  4. package/dist/cli.mjs.map +1 -1
  5. package/dist/{config-BJz1m9eN.mjs → config-1ouUTKQr.mjs} +15 -4
  6. package/dist/config-1ouUTKQr.mjs.map +1 -0
  7. package/dist/{config-DlCUMyCG.mjs → config-YRRW9l89.mjs} +1 -1
  8. package/dist/docs/SKILL.md +8 -1
  9. package/dist/docs/guidelines/bun-monorepo-patterns.md +65 -66
  10. package/dist/docs/guidelines/cli-agent-skill-patterns.md +415 -169
  11. package/dist/docs/guidelines/common-doc-guidelines.md +2 -2
  12. package/dist/docs/guidelines/convex-limits-best-practices.md +39 -39
  13. package/dist/docs/guidelines/convex-rules.md +13 -13
  14. package/dist/docs/guidelines/electron-app-development-patterns.md +18 -18
  15. package/dist/docs/guidelines/error-handling-rules.md +3 -0
  16. package/dist/docs/guidelines/general-coding-rules.md +2 -1
  17. package/dist/docs/guidelines/general-comment-rules.md +3 -2
  18. package/dist/docs/guidelines/general-eng-agent-principles.md +126 -0
  19. package/dist/docs/guidelines/general-tdd-guidelines.md +10 -4
  20. package/dist/docs/guidelines/general-testing-rules.md +4 -0
  21. package/dist/docs/guidelines/golden-testing-guidelines.md +9 -9
  22. package/dist/docs/guidelines/pnpm-monorepo-patterns.md +49 -49
  23. package/dist/docs/guidelines/python-cli-patterns.md +5 -1
  24. package/dist/docs/guidelines/python-modern-guidelines.md +7 -4
  25. package/dist/docs/guidelines/python-rules.md +6 -0
  26. package/dist/docs/guidelines/release-notes-guidelines.md +18 -2
  27. package/dist/docs/guidelines/supply-chain-hardening.md +84 -29
  28. package/dist/docs/guidelines/tbd-sync-troubleshooting.md +27 -5
  29. package/dist/docs/guidelines/typescript-cli-tool-rules.md +18 -18
  30. package/dist/docs/guidelines/typescript-code-coverage.md +8 -6
  31. package/dist/docs/guidelines/typescript-rules.md +9 -11
  32. package/dist/docs/guidelines/typescript-sorting-patterns.md +1 -1
  33. package/dist/docs/guidelines/typescript-yaml-handling-rules.md +6 -6
  34. package/dist/docs/shortcuts/standard/new-shortcut.md +14 -0
  35. package/dist/docs/shortcuts/standard/setup-github-cli.md +4 -1
  36. package/dist/docs/shortcuts/system/shortcut-explanation.md +16 -1
  37. package/dist/docs/shortcuts/system/skill-baseline.md +8 -1
  38. package/dist/docs/tbd-design.md +43 -43
  39. package/dist/docs/tbd-docs.md +1 -1
  40. package/dist/docs/tbd-prime.md +3 -3
  41. package/dist/index.mjs +1 -1
  42. package/dist/{src-CtZIHxYM.mjs → src-DTyyuaG_.mjs} +2 -2
  43. package/dist/{src-CtZIHxYM.mjs.map → src-DTyyuaG_.mjs.map} +1 -1
  44. package/dist/tbd +653 -229
  45. package/package.json +1 -1
  46. package/dist/config-BJz1m9eN.mjs.map +0 -1
  47. package/dist/docs/guidelines/general-eng-assistant-rules.md +0 -59
@@ -1,35 +1,40 @@
1
1
  ---
2
- title: Agent Skills & CLI Integration Patterns
3
- description: How to write skills and agent-integrated CLIs that work across Claude Code, Codex, and the broader coding-agent ecosystem a simple baseline plus references for advanced, multi-subcommand tools
2
+ title: Agent Skills and CLI Integration Patterns
3
+ description: How to write skills and agent-integrated CLIs that work across Claude Code, Codex, and the broader coding-agent ecosystem—a simple baseline plus references for advanced, multi-subcommand tools
4
4
  author: Joshua Levy (github.com/jlevy) with LLM assistance
5
5
  ---
6
- # Agent Skills & CLI Integration Patterns
6
+ # Agent Skills and CLI Integration Patterns
7
7
 
8
- **Last Updated**: 2026-05-23 (research verified against primary sources May 2026)
8
+ **Last Updated**: 2026-06-04 (§4.6 adds the “attention routing” framing—the slopdocs vs.
9
+ hiding-details failure modes—as a contained section, and the §3.1 mechanism callback
10
+ points at it. Earlier 2026-06-02: §6.8 now covers Anthropic’s official and community
11
+ plugin marketplaces—the reviewed, gated submission channel—and the `/plugin` install
12
+ preview; verified against code.claude.com docs.
13
+ Earlier 2026-05-31: research verified against primary sources, added the L0–L3
14
+ integration ladder and §6.6.2 project-vs-global scope mechanics, informed by `qmd`)
9
15
 
10
16
  This guideline covers how to package a capability so AI coding agents can discover and
11
- use it well from a single-file skill up to a full CLI with many subcommands exposed as
12
- a skill. It is deliberately **not dogmatic**: most needs are met by a tiny `SKILL.md`,
13
- and the heavier patterns are opt-in for tools that genuinely need them.
17
+ use it well—from a single-file skill up to a full CLI with many subcommands exposed as a
18
+ skill. It is deliberately **not dogmatic**: most needs are met by a tiny `SKILL.md`, and
19
+ the heavier patterns are opt-in for tools that genuinely need them.
14
20
 
15
21
  The patterns draw on the current (May 2026) state of the ecosystem and on `tbd`’s own
16
22
  implementation, which serves as a reference for the advanced “CLI-as-skill” approach.
17
23
 
18
24
  **When to use this guideline**: when building or packaging anything an AI coding agent
19
- should use a prompt-only skill, a CLI tool, an MCP server, or a multi-agent
20
- integration and you want it to work across Claude Code, Codex, Cursor, Gemini CLI, and
25
+ should use—a prompt-only skill, a CLI tool, an MCP server, or a multi-agent
26
+ integration—and you want it to work across Claude Code, Codex, Cursor, Gemini CLI, and
21
27
  others without rewriting it per agent.
22
28
 
23
- > **The single most important shift since 2025**: skills and project instructions are
24
- > now **open standards**, not per-vendor formats.
25
- > `AGENTS.md` is governed under the Linux Foundation’s **Agentic AI Foundation (AAIF)**;
26
- > the **Agent Skills (`SKILL.md`)** format is an open standard published at
27
- > [agentskills.io](https://agentskills.io) and implemented by 20+ agents.
28
- > Write to the standard once; most agents pick it up for free.
29
+ Skills and project instructions are now **open standards**, not per-vendor formats.
30
+ `AGENTS.md` is governed under the Linux Foundation’s **Agentic AI Foundation (AAIF)**;
31
+ the **Agent Skills (`SKILL.md`)** format is an open standard published at
32
+ [agentskills.io](https://agentskills.io) and implemented by 20+ agents.
33
+ Write to the standard once; most agents pick it up for free.
29
34
 
30
35
  * * *
31
36
 
32
- ## 0. Start Here The Simple Baseline
37
+ ## 0. Start Here—The Simple Baseline
33
38
 
34
39
  Read this section first.
35
40
  For the large majority of cases, you are done after it.
@@ -55,24 +60,24 @@ description: >-
55
60
  Step-by-step instructions the agent should follow...
56
61
  ```
57
62
 
58
- That is the entire artifact no build step, no runtime, no dependencies.
63
+ That is the entire artifact—no build step, no runtime, no dependencies.
59
64
  This is the **Agent Skills open standard** ([agentskills.io](https://agentskills.io)),
60
65
  and the same folder works in Claude Code, Codex CLI, Gemini CLI, GitHub Copilot, Cursor,
61
66
  Windsurf, Cline, pi, and 20+ other tools.
62
67
  Garry Tan’s **gstack** (~97K stars) is 23 skills, each a plain `SKILL.md` and nothing
63
- more proof the baseline scales without custom tooling.
68
+ more—proof the baseline scales without custom tooling.
64
69
 
65
70
  **The only two things that matter for a basic skill:**
66
71
 
67
72
  1. A **`description`** that says *what it does* AND *when to use it* (this drives
68
- activation see §4.2).
73
+ activation—see §4.2).
69
74
  2. A **body under ~500 lines** of clear, imperative instructions.
70
75
 
71
76
  **Install it** by copying into a known directory, or with the cross-agent package
72
77
  manager:
73
78
 
74
79
  ```bash
75
- npx skills add owner/repo # Vercel's skills.sh ecosystem (symlinks, 27+ agents)
80
+ npx skills add owner/repo # Vercel's skills.sh ecosystem (symlinks, 50+ agents)
76
81
  # or commit it to a discovery directory:
77
82
  # .agents/skills/my-skill/SKILL.md (cross-agent: Codex, pi, others)
78
83
  # .claude/skills/my-skill/SKILL.md (Claude Code, project)
@@ -81,7 +86,7 @@ npx skills add owner/repo # Vercel's skills.sh ecosystem (symlinks, 27+ ag
81
86
 
82
87
  The `SKILL.md` folder is the portable **authoring** format; some agents add their own
83
88
  discovery paths (Codex/pi also read `.agents/skills/`) and their own **distribution**
84
- layers on top (Claude Code plugins, Codex plugins) see §5.
89
+ layers on top (Claude Code plugins, Codex plugins)—see §5.
85
90
 
86
91
  ### 0.2 If your capability is a CLI
87
92
 
@@ -94,11 +99,11 @@ So:
94
99
  2. Ship a **`SKILL.md`** (or an `AGENTS.md` snippet) that tells the agent the tool
95
100
  exists, what it’s for, and the handful of commands to run.
96
101
  Reference the CLI via a **pinned zero-install runner** (`npx`/`uvx <pkg>@<version>`)
97
- so it works even in ephemeral/cloud environments global install vs.
102
+ so it works even in ephemeral/cloud environments—global install vs.
98
103
  zero-install is its own design dimension (§6.7).
99
104
  3. That’s the baseline.
100
105
  Stop here unless you have many subcommands or need cross-session state, structured
101
- auth, or background services then see §6 (CLI-as-skill) and §7 (MCP).
106
+ auth, or background services—then see §6 (CLI-as-skill) and §7 (MCP).
102
107
 
103
108
  > **The skill points; the CLI documents.** A CLI’s `--help` (and per-command
104
109
  > `mycli <cmd> --help`) is the source of truth for flags, arguments, and exact command
@@ -120,16 +125,17 @@ So:
120
125
  (§7)
121
126
  - **Maximum reach across many agents** → layer them: AGENTS.md, SKILL.md, CLI, and MCP.
122
127
  (§1)
123
- - **Self-installs into agents & ships evolving skills?** that is the advanced Tier 2
124
- pattern (self-upgrade and format versioning); most tools are Tier 1: a pure skill run
125
- via a **pinned** `npx`/`uvx`. (§6.0)
128
+ - **Self-installs into agents?** climb the integration ladder (§6.0): L0 pure skill
129
+ L1 skill + pinned `npx`/`uvx` L2 self-install into skill dirs only (`qmd`) → L3 full
130
+ platform with managed `AGENTS.md`, hooks, and format versioning (`tbd`). Most tools
131
+ are L1; stop as low as you can.
126
132
 
127
133
  Everything below is reference material.
128
134
  You do not need most of it for most tools.
129
135
 
130
136
  * * *
131
137
 
132
- ## 1. The Layered Model — “Write Once, Integrate Many”
138
+ ## 1. The Layered Model—“Write Once, Integrate Many”
133
139
 
134
140
  There is no single integration surface that every agent uses, but the surfaces compose
135
141
  cleanly.
@@ -151,19 +157,19 @@ Add agent-specific files last, and only where they buy something.
151
157
 
152
158
  * * *
153
159
 
154
- ## 2. AGENTS.md The Universal Project Baseline
160
+ ## 2. AGENTS.md—The Universal Project Baseline
155
161
 
156
162
  `AGENTS.md` is a plain-Markdown file at the repo root that tells any agent how your
157
163
  project works: build commands, test commands, conventions, gotchas.
158
- It is **not** capability-specific think of it as the README written for agents.
164
+ It is **not** capability-specific—think of it as the README written for agents.
159
165
 
160
- **Governance & reach**: Originated by OpenAI (Aug 2025); since Dec 2025 stewarded by the
161
- **Agentic AI Foundation under the Linux Foundation** (co-founded by OpenAI, Anthropic,
162
- and Block; ~180 member orgs).
166
+ **Governance and reach**: Originated by OpenAI (Aug 2025); since Dec 2025 stewarded by
167
+ the **Agentic AI Foundation under the Linux Foundation** (co-founded by OpenAI,
168
+ Anthropic, and Block; ~180 member orgs).
163
169
  Used by **60,000+** open-source projects.
164
170
  Canonical spec: [agents.md](https://agents.md).
165
171
 
166
- **Discovery & precedence** vary by agent know your targets:
172
+ **Discovery and precedence** vary by agent—know your targets:
167
173
 
168
174
  - **Codex**: reads global `~/.codex/AGENTS.md` (or `AGENTS.override.md`), then walks
169
175
  from repo root down to the working directory, concatenating one file per directory
@@ -205,8 +211,8 @@ generated content without touching user-authored text:
205
211
  <!-- END MYCLI INTEGRATION -->
206
212
  ```
207
213
 
208
- Keep the begin/end marker *names* stable (`<!-- BEGIN MYCLI INTEGRATION`) match on
209
- that prefix so detection finds both legacy blocks (no `format=`, treated as `f01`) and
214
+ Keep the begin/end marker *names* stable (`<!-- BEGIN MYCLI INTEGRATION`)—match on that
215
+ prefix so detection finds both legacy blocks (no `format=`, treated as `f01`) and
210
216
  current ones. Only the `format=fNN` value changes when the block’s shape changes.
211
217
 
212
218
  * * *
@@ -237,7 +243,7 @@ Skills are loaded in three levels so they cost almost nothing until used:
237
243
  **Constraints that matter**: keep the body **under 500 lines**; keep reference files
238
244
  **one level deep** from `SKILL.md` (avoid `SKILL.md → a.md → b.md` chains); put bulky
239
245
  material (schemas, examples, scripts) in supporting files.
240
- Scripts execute *outside* the context window only their output costs tokens, which is
246
+ Scripts execute *outside* the context window—only their output costs tokens, which is
241
247
  why bundling a script can be far cheaper than inlining instructions.
242
248
 
243
249
  **For a CLI-backed skill, the CLI itself is the Level-3 layer.** Treat `mycli --help`,
@@ -250,6 +256,9 @@ The body names the capability and the command; the agent runs that command’s `
250
256
  `--list` when it needs the mechanics.
251
257
  This is progressive disclosure applied to a CLI: the tool documents itself, and the
252
258
  skill stays a thin pointer to it.
259
+ This is *attention routing* (§4.6) in mechanism form: each level keeps the agent aware
260
+ that more detail exists and routes to it, without pulling the detail itself up into
261
+ context before it is needed.
253
262
 
254
263
  ### 3.2 Bundled scripts and resources
255
264
 
@@ -299,12 +308,12 @@ specifically.
299
308
 
300
309
  ### 4.2 Description optimization (this is what makes skills activate)
301
310
 
302
- Activation is **pure LLM reasoning** — the model reads every installed skill’s `name` +
311
+ Activation is **pure LLM reasoning**—the model reads every installed skill’s `name` +
303
312
  `description` and decides what to invoke.
304
313
  There is no keyword matcher or embedding step.
305
314
  So the description is the single highest-leverage thing you write.
306
315
 
307
- **The two-part rule** — every description answers:
316
+ **The two-part rule**—every description answers:
308
317
 
309
318
  1. **What does it do?** (capabilities)
310
319
  2. **When should it be used?** (explicit triggers, in the user’s words)
@@ -324,13 +333,13 @@ description: >-
324
333
  the most important trigger keywords in the first ~50 characters (descriptions can be
325
334
  truncated in large collections); state both capability and trigger.
326
335
 
327
- **Activation reliability** (community 650-trial sandboxed eval directional, not
336
+ **Activation reliability** (community 650-trial sandboxed eval—directional, not
328
337
  official): vague descriptions ~20% → optimized “Use when…” descriptions ~50% → adding
329
338
  concrete examples ~72–90%. Two distinct failure modes to design against: *activation
330
- failure* (never invoked) and *execution failure* (invoked but steps skipped fix with
339
+ failure* (never invoked) and *execution failure* (invoked but steps skipped—fix with
331
340
  clearer, checklist-style instructions).
332
341
 
333
- ### 4.3 The description budget (changed in 2026 verify against your target)
342
+ ### 4.3 The description budget (changed in 2026—verify against your target)
334
343
 
335
344
  Earlier guidance cited a flat ~15K-character budget.
336
345
  **Claude Code’s current model is different**:
@@ -345,7 +354,7 @@ Earlier guidance cited a flat ~15K-character budget.
345
354
  `off` without editing the file; `/doctor` reports overflow.
346
355
 
347
356
  **Implication for tools that install many skills**: don’t. Use the **meta-skill
348
- pattern** (§6.2) one skill that exposes N resources via CLI subcommands consumes a
357
+ pattern** (§6.2)—one skill that exposes N resources via CLI subcommands consumes a
349
358
  single listing slot instead of N. This is the strongest architectural reason to prefer
350
359
  CLI-as-skill once you have more than a handful of capabilities.
351
360
 
@@ -354,9 +363,9 @@ CLI-as-skill once you have more than a handful of capabilities.
354
363
  Because activation is probabilistic (§4.2) and the body is executable influence, test
355
364
  it:
356
365
 
357
- - **Positive activation**: a few realistic prompts that *should* trigger the skill
358
- does the agent invoke it?
359
- - **Negative activation**: nearby prompts that should *not* trigger it no false fires?
366
+ - **Positive activation**: a few realistic prompts that *should* trigger the skill—does
367
+ the agent invoke it?
368
+ - **Negative activation**: nearby prompts that should *not* trigger it—no false fires?
360
369
  - **Explicit invocation**: `/skill-name` (or the agent equivalent) loads and runs
361
370
  cleanly.
362
371
  - **Sandbox / write-denial**: the skill (and any bundled script) degrades gracefully
@@ -378,6 +387,32 @@ it:
378
387
  - **Deprecation**: when removing or renaming a skill, leave a deprecation window with a
379
388
  pointer to the replacement; don’t silently delete an activation trigger users rely on.
380
389
 
390
+ ### 4.6 Attention routing—the idea behind this guide
391
+
392
+ Everything above is in service of one idea.
393
+ Route the agent’s attention through a pyramid of pointers: surface enough context around
394
+ each pointer to show what is relevant, pull detail up only where it helps, and keep the
395
+ upper levels lean.
396
+ The judgment at every step is **how much to copy into the skill versus
397
+ leave behind a link to the CLI**—which is why rules like **route, don’t restate** (§6.5)
398
+ and **the skill points; the CLI documents** (§0.2) exist.
399
+ There are two opposite failure modes:
400
+
401
+ - **Slopdocs** (*copying too much, or unthinkingly*)—help text, flag tables, and recipes
402
+ copied into the skill with no judgment about what level or form belongs where.
403
+ Deliberate, consistent copying is fine—the multi-agent mirror in §6.6 is exactly
404
+ that—but thoughtless copying bloats context and dilutes attention, and breeds
405
+ maintenance burden and inconsistencies that drift into real errors.
406
+ - **Hiding details** (*copying too little, or hiding details behind links too
407
+ dogmatically*)—pointing at the CLI or a reference without enough context to convey
408
+ what is there or why to look, so the agent never learns the capability is relevant.
409
+ Fix: pull up just enough—name each capability and the command that reaches it—so the
410
+ link is worth following.
411
+
412
+ Push the *mechanics* (flags, recipes) down into help pages or docs, but keep enough
413
+ *awareness* and *detail* up in the skill—each key capability described once, with the
414
+ command that reaches it—so the agent knows whether a pointer is worth following.
415
+
381
416
  * * *
382
417
 
383
418
  ## 5. Per-Agent Integration Reference
@@ -402,12 +437,12 @@ you care about.
402
437
  | **Goose** (Block) | `AGENTS.md` | Recipes; 70+ MCP extensions | Yes (deepest) | extension lifecycle | MCP (primary) |
403
438
  | **Zed** | `.rules` (reads `.cursorrules`, `CLAUDE.md`) | Rules Library | Yes (extensions) | — | MCP extension + `.rules` |
404
439
  | **Factory** | `AGENTS.md` + `.factory/droids/*.md` | Custom Droids (sub-agents) | Yes | Delegator loop | AGENTS.md + droid file |
405
- | **pi** | `AGENTS.md` / `CLAUDE.md`, `.pi/SYSTEM.md` | Agent Skills (`.pi/skills/`, `.agents/skills/`); TS extensions | **No (by design)** — use CLI+README or an extension | extension hooks | SKILL.md + CLI; extension for deep tool registration |
440
+ | **pi** | `AGENTS.md` / `CLAUDE.md`, `.pi/SYSTEM.md` | Agent Skills (`.pi/skills/`, `.agents/skills/`); TS extensions | **No (by design)**—use CLI+README or an extension | extension hooks | SKILL.md + CLI; extension for deep tool registration |
406
441
 
407
442
  **Notes on the minimal end (pi)**: pi (Mario Zechner’s `@mariozechner/pi-coding-agent`,
408
443
  ~44K stars) ships four tools (read/write/edit/bash) and treats context as a scarce
409
444
  budget. It reads `AGENTS.md`/`CLAUDE.md`, supports the Agent Skills standard, and
410
- **deliberately omits MCP** — its docs tell authors to “build CLI tools with READMEs” or
445
+ **deliberately omits MCP**—its docs tell authors to “build CLI tools with READMEs” or
411
446
  write a TypeScript extension (`pi.registerTool()` / `pi.registerCommand()`). This is a
412
447
  clean endorsement of the CLI-as-skill approach: a self-documenting CLI plus a `SKILL.md`
413
448
  is exactly what a minimal agent wants.
@@ -415,23 +450,23 @@ is exactly what a minimal agent wants.
415
450
  **Codex specifics** (it gained a real skill system in 2026): skills are `SKILL.md`
416
451
  folders with the same progressive disclosure.
417
452
  Verified against the Codex source (`codex-rs/core-skills/src/loader.rs`, tags
418
- `rust-v0.130.0`…`v0.133.0`): the loader scans several **scopes** — `Repo` (every
453
+ `rust-v0.130.0`…`v0.133.0`): the loader scans several **scopes**—`Repo` (every
419
454
  `<dir>/.agents/skills/` from the project root down to cwd), `User`
420
455
  (`$HOME/.agents/skills/`), `Admin`, plus plugin roots and `$CODEX_HOME/skills`. So a
421
456
  **plain repo-root `.agents/skills/<name>/SKILL.md` is read directly**, no manifest
422
457
  required. (The repo path is built by joining `.agents` and `skills` at runtime, so it
423
- does *not* appear as a contiguous `.agents/skills` literal in the binary a
458
+ does *not* appear as a contiguous `.agents/skills` literal in the binary—a
424
459
  `strings`-based inspection will miss it and see only `.agents/plugins/marketplace.json`;
425
460
  confirm against the source, not binary strings.)
426
461
  **Plugins** are an *additional* distribution layer (installable units bundling skills
427
- and MCP servers 90+ ship with Codex), declared in `.agents/plugins/marketplace.json`
428
- (also reads `.claude-plugin/marketplace.json`) useful for *publishing a bundle*, but
429
- not needed to make a repo-local skill load.
462
+ and MCP servers—90+ ship with Codex), declared in `.agents/plugins/marketplace.json`
463
+ (also reads `.claude-plugin/marketplace.json`)—useful for *publishing a bundle*, but not
464
+ needed to make a repo-local skill load.
430
465
  Codex skills may carry a richer **`agents/openai.yaml`** companion (e.g.
431
466
  `interface.display_name`, icons, `dependencies.tools[]`,
432
467
  `policy.allow_implicit_invocation`); map the portable
433
468
  `name`/`description`/`allowed-tools` onto it only when you specifically want that Codex
434
- polish it’s optional.
469
+ polish—it’s optional.
435
470
  An experimental, off-by-default **`external_migration`** feature can import `.claude/`
436
471
  config (hooks/MCP/skills) into `.codex/`; don’t depend on it yet, but expect the
437
472
  portable duplication to shrink if it stabilizes.
@@ -439,14 +474,14 @@ Operational config lives in `~/.codex/config.toml` (or trusted per-project
439
474
  `.codex/config.toml`): `model`, `approval_policy`
440
475
  (`untrusted`/`on-request`/`granular`/`never`), `sandbox_mode`
441
476
  (`read-only`/`workspace-write`/`danger-full-access`), and `[mcp_servers.*]`. A CLI your
442
- tool ships will run **inside Codex’s sandbox** — under `workspace-write`, writes are
477
+ tool ships will run **inside Codex’s sandbox**—under `workspace-write`, writes are
443
478
  limited to workspace roots and network is off unless explicitly enabled.
444
479
  Design your CLI to work read-only where possible and to fail with a clear message when
445
480
  sandboxed.
446
481
 
447
482
  * * *
448
483
 
449
- ## 6. CLI-as-Skill (Advanced) One Tool, Many Self-Injecting Commands
484
+ ## 6. CLI-as-Skill (Advanced)—One Tool, Many Self-Injecting Commands
450
485
 
451
486
  This is the pattern for a richer tool: a CLI that is itself a skill, exposing many
452
487
  capabilities as subcommands while costing a single description slot.
@@ -455,37 +490,58 @@ follows the same shape (subcommands, `AGENTS.md`, `--json`, and an optional MCP
455
490
 
456
491
  Use this when you have many capabilities, need cross-session state, or want a curated
457
492
  knowledge library the agent pulls from.
458
- For a single capability, the §0 baseline is better don’t reach for this prematurely.
493
+ For a single capability, the §0 baseline is better—don’t reach for this prematurely.
459
494
 
460
- ### 6.0 Two integration tiers pick the lighter one
495
+ ### 6.0 The integration ladder—pick the lowest rung that works
461
496
 
462
497
  Most tools should **not** self-install.
463
- Decide which tier you are before adding any setup machinery:
464
-
465
- - **Tier 1 — pure skill (the default for most tools).** Ship a `SKILL.md` (optionally an
466
- `AGENTS.md` snippet); users install it once (commit to `.agents/skills/`,
467
- `npx skills add`, or the Claude mirror).
468
- Invoke the tool through a **version-pinned** zero-install runner —
469
- `npx --yes pkg@<ver>`, `uvx --from pkg@<ver>`, or `pipx run pkg==<ver>` (§6.7). No
470
- hooks, no managed `AGENTS.md` block, no `setup` command, no format versioning.
498
+ Distribution complexity is a ladder, not a switch: each rung adds machinery (and
499
+ maintenance) over the one below, so climb only as far as the tool genuinely needs.
500
+ Four rungs, lightest first:
501
+
502
+ - **L0—pure prompt skill.** A `SKILL.md` and nothing else: no binary, no runtime, no
503
+ install command. The agent follows the body directly.
504
+ Garry Tan’s **gstack** (23 plain skills) is L0. Install by committing to a discovery
505
+ dir or `npx skills add`.
506
+ - **L1—skill + delegated CLI (zero-install).** Ship a `SKILL.md` that points at a CLI
507
+ invoked through a **version-pinned** zero-install runner—`npx --yes pkg@<ver>`,
508
+ `uvx --from pkg@<ver>`, or `pipx run pkg==<ver>` (§6.7). No install command, no
509
+ managed `AGENTS.md` block, no hooks, no format versioning.
510
+ The skill *delegates* execution to a package it never installs itself.
511
+ This is the default for most CLI-backed capabilities.
471
512
  Pinning the version here does **double duty**:
472
- - **Supply-chain control** — an unpinned runner (`npx pkg`, `uvx --from pkg`) silently
513
+ - **Supply-chain control**—an unpinned runner (`npx pkg`, `uvx --from pkg`) silently
473
514
  re-resolves to the latest published version on every run and bypasses any cool-off
474
515
  window. A pinned version is the artifact you actually vetted.
475
- - **Consistency control** — every teammate and every agent runs the *same* tool
476
- version, so skill behavior is reproducible across a team and across agents rather
477
- than drifting as upstream publishes new releases.
478
- - **Tier 2 self-installing CLI (advanced; the rest of §6).** A tool that writes its
479
- own integration files into multiple agents (`.agents/skills/`, `.claude/skills/`, a
480
- managed `AGENTS.md` block, hooks, `.codex/` config) **and** whose skill content
481
- evolves across releases.
482
- Take on this complexity only for a tool with many capabilities, cross-session state,
483
- or a curated knowledge library.
484
- The self-upgrade and format-versioning rules in §6.6 apply **only to this tier** — a
485
- pure skill never needs them.
486
-
487
- If in doubt, you are Tier 1. `tbd` is a Tier-2 reference implementation; most CLIs are
488
- not.
516
+ - **Consistency control**—every teammate and every agent runs the *same* tool version,
517
+ so skill behavior is reproducible across a team and across agents rather than
518
+ drifting as upstream publishes new releases.
519
+ - **L2—self-installing skill, discovery-dirs only.** The tool ships an `install` command
520
+ (with `--project`/`--global` scope—§6.6.2) that writes its `SKILL.md` into the
521
+ skill-discovery directories (`.agents/skills/<tool>/`, the `.claude/skills/` mirror)
522
+ and **stops there**: no managed `AGENTS.md` block, no hooks, no `prime`/`setup`
523
+ context machinery. Because it never touches a human-authored project-instruction file
524
+ and always full-overwrites its own generated skill, it does **not** need the §6.6
525
+ format-version / migration apparatus—a re-install is just a clean overwrite.
526
+ **`qmd`** (Tobi Lütke’s Markdown search tool) is the reference: `qmd skill install` /
527
+ `--global`, an embedded skill with a build-time drift test, a
528
+ `.claude-plugin/marketplace.json`, and an MCP server—all without writing to
529
+ `AGENTS.md` at all.
530
+ - **L3—full self-installing CLI platform.** Everything in L2 **plus** a managed
531
+ `AGENTS.md` block, lifecycle hooks (`SessionStart`/`PreCompact`), `prime` and `setup`
532
+ commands, format-versioned migration with a forward-compatibility guard (§6.6), and
533
+ usually a knowledge-injection meta-skill (§6.2) backed by a path-ordered DocCache
534
+ (§6.3). Take this on only for a tool with many capabilities, cross-session state, or a
535
+ curated knowledge library.
536
+ **`tbd`** is the reference implementation; **Beads/`bd`** follows the same shape.
537
+ Such platforms are typically **project-only and version-pinned per repo** (§6.6.2):
538
+ the tool is part of the project’s reproducible toolchain, so global scope is usually
539
+ not worth offering. `qmd` (L2) offers global/dual scope precisely because it is a
540
+ general-purpose utility that carries no per-project config.
541
+
542
+ The self-upgrade and format-versioning rules in §6.6 apply **only to L3**—L0–L2 never
543
+ need them. If in doubt, you are L1: `tbd` is an L3 reference implementation, `qmd` an L2
544
+ one, and most CLIs are neither.
489
545
 
490
546
  ### 6.1 Two kinds of commands
491
547
 
@@ -494,7 +550,7 @@ not.
494
550
  | **Action commands** | Perform operations | `create`, `close`, `sync` |
495
551
  | **Informational commands** | Output guidance for the agent to *follow* | `guidelines <name>`, `shortcut <name>`, `template <name>` |
496
552
 
497
- Informational commands don’t *do* anything they print instructions, best practices, or
553
+ Informational commands don’t *do* anything—they print instructions, best practices, or
498
554
  templates the agent reads and acts on.
499
555
  This is the mechanism behind tbd’s **knowledge-injection-via-subcommands**: rather than
500
556
  installing dozens of skills, tbd installs *one* meta-skill and exposes its entire
@@ -533,8 +589,8 @@ post-compaction contexts).
533
589
 
534
590
  ### 6.3 Resource directories: show the full command
535
591
 
536
- When listing resources, print the command to run, not just a name it removes a step
537
- for the agent.
592
+ When listing resources, print the command to run, not just a name—it removes a step for
593
+ the agent.
538
594
 
539
595
  ```markdown
540
596
  ## Available Shortcuts
@@ -563,7 +619,7 @@ Rules: reference commands **explicitly** (`mycli command arg`, never “see the
563
619
 
564
620
  ### 6.5 Making the CLI agent-friendly
565
621
 
566
- - **`--json` on every command** — one output path that renders human or machine output.
622
+ - **`--json` on every command**—one output path that renders human or machine output.
567
623
  - **`--brief`/`--quiet`** for constrained contexts and scripts.
568
624
  - **Idempotent `setup --auto`** (non-interactive) vs.
569
625
  `setup --interactive` for humans; never let an agent get stuck on a prompt.
@@ -604,13 +660,13 @@ their options) down into the tool.
604
660
  Adequate beats exhaustive: a short skill that reliably routes the agent to the right
605
661
  command beats a long one that mirrors the manual.
606
662
 
607
- ### 6.6 Distribution & multi-agent install
663
+ ### 6.6 Distribution and multi-agent install
608
664
 
609
665
  A CLI can install itself into multiple agents from one `setup` run.
610
666
  Use the portable Agent Skills location as the primary project skill surface and mirror
611
667
  only where a target agent requires it:
612
668
 
613
- - `.agents/skills/<tool>/SKILL.md` — the portable project skill.
669
+ - `.agents/skills/<tool>/SKILL.md`—the portable project skill.
614
670
  **Be precise about who reads this path natively vs.
615
671
  who reaches it via an installer**, rather than claiming a flat “all agents read it”:
616
672
  - **Scans repo-root `.agents/skills/` natively** (verified): **Codex** (source above)
@@ -619,17 +675,17 @@ only where a target agent requires it:
619
675
  - **Reached via the cross-agent installer**: `npx skills add` copies the same
620
676
  `SKILL.md` into `.agents/skills/` and **symlinks it into each agent’s own dir**
621
677
  (Cursor, Copilot, Cline, Amp, Windsurf, …). For those agents the *installer*, not
622
- the agent, is what binds `.agents/skills/` to their native location so “works with
678
+ the agent, is what binds `.agents/skills/` to their native location—so “works with
623
679
  Cursor/Copilot/…” means “via skills.sh”, not “Cursor scans `.agents/skills/`
624
680
  itself.”
625
- - **Claude Code does NOT scan `.agents/`** at all it reads only `.claude/skills/`
681
+ - **Claude Code does NOT scan `.agents/`** at all—it reads only `.claude/skills/`
626
682
  (next bullet), which is why the mirror is required, not optional.
627
683
  - When in doubt, verify against the agent’s source/docs before asserting native
628
684
  scanning.
629
- - `.claude/skills/<tool>/SKILL.md` — Claude Code compatibility mirror (required: Claude
685
+ - `.claude/skills/<tool>/SKILL.md`—Claude Code compatibility mirror (required: Claude
630
686
  Code reads only this path).
631
- - `AGENTS.md` — compact always-on project bootstrap, not a full copy of the skill.
632
- - `.codex/hooks.json` or `.codex/config.toml` — Codex lifecycle automation, not policy
687
+ - `AGENTS.md`—compact always-on project bootstrap, not a full copy of the skill.
688
+ - `.codex/hooks.json` or `.codex/config.toml`—Codex lifecycle automation, not policy
633
689
  text or skill content.
634
690
 
635
691
  tbd should write a CLI-managed `SKILL.md` to `.agents/skills/tbd/`, mirror it to
@@ -659,12 +715,19 @@ scripts/agent/<tool>-session.sh # shared hook script, referenced by both agents
659
715
  .claude/settings.json # Claude hook entry → same shared script
660
716
  ```
661
717
 
662
- Copy (don’t symlink) the `SKILL.md` payload to both skill paths — symlinks behave
663
- unevenly across Windows, sandboxes, and remote worktrees.
718
+ **Copy vs symlink the mirror.** Default to **copying** the `SKILL.md` payload to both
719
+ skill paths: a committed copy is browsable on GitHub/skills.sh and behaves predictably
720
+ across Windows, sandboxes, and remote worktrees, where symlinks do not.
721
+ A **symlink** of the Claude mirror onto the canonical `.agents/skills/<tool>/` is a
722
+ legitimate *single-machine* optimization—one source of truth, zero drift—and is what
723
+ `qmd` and the `npx skills add` installer do.
724
+ Reserve it for installs that stay on one developer’s machine; for anything committed or
725
+ shared across platforms, copy.
726
+ Whichever you pick, the two paths must carry identical content.
664
727
  Claude Code does **not** auto-load `AGENTS.md` (it reads `CLAUDE.md`), so a multi-agent
665
728
  project needs both.
666
729
 
667
- **File-ownership rules** — distinguish three categories:
730
+ **File-ownership rules**—distinguish three categories:
668
731
 
669
732
  - **Project instruction files** (`AGENTS.md`, `CLAUDE.md`): *commit these*. They hold
670
733
  human-authored project norms (§2). A CLI may own a **marker-bounded section** inside
@@ -685,30 +748,32 @@ project needs both.
685
748
  Con: not browsable in the repo, and no committed artifact to diff in review.
686
749
  With this mode a format-version stamp matters less (there is no committed artifact
687
750
  for an older tool to clobber).
688
- - **Source files** in the CLI package (header, baseline, brief): the canonical inputs —
689
- always version-controlled.
751
+ - **Source files** in the CLI package (header, baseline, brief): the canonical
752
+ inputs—always version-controlled.
690
753
 
691
754
  Make setup idempotent: dedupe hooks before merging, overwrite generated skills rather
692
755
  than patching them, update only the marked section of `AGENTS.md`, and clean up legacy
693
756
  files each run.
694
757
 
695
758
  **Generated output must be deterministic.** A given input state must always produce
696
- byte-identical output no timestamps, no random IDs, no machine-specific paths, no
759
+ byte-identical output—no timestamps, no random IDs, no machine-specific paths, no
697
760
  unstable ordering. This is what makes the artifact diff-stable, drift-testable, and safe
698
761
  to regenerate. It must also be stable under whatever formatter the repo runs (e.g. emit
699
- the managed block in the formatter’s canonical form sentence-aware line wrapping,
700
- correct quote style so a format pass is a no-op; and don’t emit a second YAML
762
+ the managed block in the formatter’s canonical form—sentence-aware line wrapping,
763
+ correct quote style—so a format pass is a no-op; and don’t emit a second YAML
701
764
  frontmatter block mid-document).
702
765
  Because Codex and Claude Code now share a hook event schema (§8), prefer **one shared
703
766
  script referenced by two thin per-agent configs**: keep the logic in a neutral location
704
767
  (e.g. `scripts/agent/<tool>-session.sh`) and reference it from both
705
768
  `.claude/settings.json` and the Codex `[hooks]`/`.codex/hooks.json` entry.
706
- Do not make Codex hooks call scripts stored under `.claude/` — that couples Codex setup
707
- to Claude setup. If a script must move out of `.claude/scripts/`, update the tbd-owned
708
- hook commands (or leave a wrapper) so existing Claude hooks keep working.
709
-
710
- **Upgrade existing installs deliberately (Tier 2 only).** A self-installing tool whose
711
- skill content evolves *will* leave older generated files in users’ repos.
769
+ Do not make Codex hooks call scripts stored under `.claude/`—that couples Codex setup to
770
+ Claude setup. If a script must move out of `.claude/scripts/`, update the tbd-owned hook
771
+ commands (or leave a wrapper) so existing Claude hooks keep working.
772
+
773
+ **Upgrade existing installs deliberately (L3 only).** A self-installing tool whose skill
774
+ content evolves *will* leave older generated files in users’ repos.
775
+ (An L2 tool that only writes discovery-dir skills can skip all of this: a re-install is
776
+ a clean full overwrite, with no managed `AGENTS.md` block or hooks to migrate.)
712
777
  Treat generated integration files like config migrations:
713
778
 
714
779
  Reserve an `fNN` **format bump** for changes big enough to need an explicit migration: a
@@ -726,11 +791,11 @@ it; it does not license the tool to mutate the repo on its own.
726
791
  (This is why a `SessionStart` hook should run a read-only `prime`, not `setup`.)
727
792
 
728
793
  - Version the generated surfaces with an `fNN` format code.
729
- Prefer **one format code for all the tool’s managed surfaces** — reuse the tool’s
794
+ Prefer **one format code for all the tool’s managed surfaces**—reuse the tool’s
730
795
  existing config/data-format version as the single source of truth (tbd stamps the
731
796
  AGENTS.md block with the same `tbd_format`, currently `f03`) rather than maintaining a
732
- parallel counter. Bump it when any managed surface config schema or a generated agent
733
- surface changes shape.
797
+ parallel counter. Bump it when any managed surface—config schema or a generated agent
798
+ surface—changes shape.
734
799
  - Stamp the format on the generated artifact itself: on the `AGENTS.md` begin-marker
735
800
  line (`<!-- BEGIN … format=fNN … -->`), the skill “DO NOT EDIT” marker, script
736
801
  headers, or an equivalent hook signature.
@@ -776,8 +841,9 @@ Recommended setup flags:
776
841
 
777
842
  Use a true tri-state: with no targeting flag a surface is detection-based; a positive
778
843
  flag forces it on (and suppresses auto-detection of untargeted surfaces); `--skip-*`
779
- forces it off. Avoid Commander’s `--no-<x>` for surfaces — it defaults the value to
780
- `true`, which would force-install on every run.
844
+ forces it off.
845
+ Avoid Commander’s `--no-<x>` for surfaces—it defaults the value to `true`,
846
+ which would force-install on every run.
781
847
  (`tbd` itself ships `--all`, `--claude`, `--codex`, `--skip-claude`, `--skip-codex`;
782
848
  `AGENTS.md` installs as part of the Codex surface.)
783
849
 
@@ -785,13 +851,16 @@ Keep project-local setup separate from global/user setup.
785
851
  Writing `~/.codex/AGENTS.md`, `~/.agents/skills/`, or `~/.claude/skills/` should be an
786
852
  explicit global install command or documented manual step, not something `setup --auto`
787
853
  does silently.
854
+ For a tool that genuinely needs **both** scopes (a general-purpose writing
855
+ tool, linter, or formatter—most CLIs are project-only and can ignore this), §6.6.2
856
+ codifies the concrete flag mechanics and guard rails.
788
857
 
789
858
  #### 6.6.1 Extensible skill registries (let other packages contribute skills)
790
859
 
791
860
  A single bundled skill is enough for most tools.
792
861
  But when a tool is a **platform** that other packages extend, don’t hard-code its skill
793
- list expose a **registry** so any installed package can contribute a skill that the
794
- CLI discovers at runtime.
862
+ list—expose a **registry** so any installed package can contribute a skill that the CLI
863
+ discovers at runtime.
795
864
 
796
865
  The clean implementation is the host language’s plugin mechanism:
797
866
 
@@ -807,11 +876,129 @@ The clean implementation is the host language’s plugin mechanism:
807
876
 
808
877
  Keep each registered skill a **spec** (name, two-part description, `allowed-tools`, a
809
878
  baseline source, and an optional dynamic catalog function) and run them all through the
810
- **same** `compose` and `--install` path, so every skill first-party or third-party
811
- gets identical frontmatter, the `DO NOT EDIT`/format marker, and deterministic output.
879
+ **same** `compose` and `--install` path, so every skill—first-party or third-party—gets
880
+ identical frontmatter, the `DO NOT EDIT`/format marker, and deterministic output.
812
881
  This keeps the “one tool, many self-injecting commands” model open for extension without
813
882
  the core tool taking a dependency on every plugin.
814
883
 
884
+ #### 6.6.2 Install scope: project-pinned, global, or both
885
+
886
+ **First decide which scopes the tool should even offer—most tools should not offer all
887
+ three.** The deciding factor is whether the tool is *customized per install*; a
888
+ secondary one is whether the user wants it as an explicit dependency of each repo.
889
+
890
+ - **Customized per install → project install, version-pinned, single scope (preferred;
891
+ consider discouraging global).** If the tool carries per-project configuration or
892
+ defines how *this* repo is built, tracked, or reviewed, install it into the project
893
+ and pin its version there, so the whole team and every agent get identical behavior
894
+ and different projects can pin different versions independently.
895
+ For such a tool a global install is usually not worth supporting—and can be worth
896
+ actively discouraging—because a per-project install is almost always preferable.
897
+ **`tbd` is deliberately here**: pinned per project and configured per repo
898
+ (`.tbd/config.yml`, the issue prefix), so a global cross-repo install would be an
899
+ anti-pattern, not a missing feature.
900
+ This is the §6.0 “consistency control” argument taken to its conclusion.
901
+ - **Not customized (a general utility) → dual-scope, for flexibility.** When there is no
902
+ per-project configuration to anchor the tool, offering *both* `--project` and
903
+ `--global` simply lets the user decide where it lives—global so it is available
904
+ everywhere with no explicit repo dependency, or project-local when they do want it
905
+ pinned. **`qmd` is here**: a Markdown search tool pointed at arbitrary collections,
906
+ useful across repos and configured per invocation.
907
+ - **Global-only → rare, but conceivable.** Reserve it for a genuine *user-level
908
+ preference* that applies across all of a user’s projects and that the user would
909
+ rarely want committed into any single repo.
910
+ Most tools are not this; do not default to global-only.
911
+
912
+ The `--project`/`--global` mechanics below apply to any tool that offers global or
913
+ dual-scope installs.
914
+ §6.6 states the principle (project-local and global must be kept separate; global must
915
+ be explicit); this codifies it.
916
+ The model to copy is **`git config`**: implicit scope when it is unambiguous, a hard
917
+ error when it is not.
918
+
919
+ **Explicit scope flags.**
920
+
921
+ ```
922
+ mycli install [--project | --global] [--surfaces=LIST | per-agent flags]
923
+ [--dir DIR] [--no-repo-check] [--pin VERSION]
924
+ ```
925
+
926
+ - `--project` → project-local install (the canonical `.agents/skills/<tool>/` plus the
927
+ Claude mirror, under the repo).
928
+ - `--global` → user-global install under `$HOME` (`~/.agents/skills/`,
929
+ `~/.claude/skills/`).
930
+ - Mutually exclusive: `--project ↔ --global`, and `--global ↔ --dir`.
931
+
932
+ **Implicit-when-unambiguous, error-when-not** (the `git config` rule).
933
+ Resolve scope *before* writing anything:
934
+
935
+ | Situation | Behavior |
936
+ | --- | --- |
937
+ | cwd is inside a git repo and not `$HOME` | implicit `--project` |
938
+ | cwd is `$HOME` or the filesystem root | **error**: ambiguous; pass `--project` or `--global` |
939
+ | cwd is not in a git repo | **error**: ambiguous; pass `--project --no-repo-check` or `--global` |
940
+ | explicit `--project` / `--global` given | honor it (subject to the `$HOME` refusal below) |
941
+
942
+ This removes the footgun where `cd ~ && mycli install` silently writes into the user’s
943
+ global agent surfaces and changes every project’s behavior.
944
+ Warning *after* the write (what some tools do—and `qmd`, which simply defaults to cwd
945
+ with no guard at all, does not warn) is too late; refuse *before* it.
946
+
947
+ **`$HOME` is always refused in `--project` mode**—even with `--no-repo-check`,
948
+ `--project --dir ~` is an error, because that is exactly what `--global` is for.
949
+ Name the right flag in the message:
950
+
951
+ ```
952
+ mycli install --project: refusing to install into /Users/me (home directory).
953
+ That would write to your global agent surfaces. Use --global for a user-wide install.
954
+ ```
955
+
956
+ **Print the resolved target before writing**, so the user can ctrl-c if it is wrong:
957
+
958
+ ```
959
+ Installing mycli skills (project mode) into: /Users/me/myrepo
960
+ surfaces: portable, claude
961
+ ```
962
+
963
+ (Printing the scope *after* the write—as `qmd` does—is weaker: the damage is already
964
+ done.)
965
+
966
+ **Surface selection—match the vocabulary to the surface count.** There is no single
967
+ right answer; pick by how many surfaces you have and expect to add:
968
+
969
+ - **Two or three surfaces** → terse per-agent / boolean flags read best.
970
+ `qmd` (canonical skill dir + Claude mirror) uses a single
971
+ `--skip-claude`/`--no-claude` toggle; `tbd` uses `--all` / `--claude` / `--codex` /
972
+ `--skip-<surface>`.
973
+ - **Three or more surfaces, or you expect to add agents** → a `--surfaces=<comma-list>`
974
+ selector with an `all` alias (`--surfaces=portable,claude,agents-md,all`) scales
975
+ better: adding `gemini-md` or `cursor-rules` later is a no-op for the CLI shape, with
976
+ no flag soup. The selector vocabulary lives only in the CLI—the artifact’s identity is
977
+ clear from its location (a `SKILL.md` under a skill dir, or the BEGIN/END-bounded
978
+ block in `AGENTS.md`), so no in-file `surface=` tag is needed beyond the load-bearing
979
+ `format=fNN`.
980
+
981
+ Either way, use a true tri-state (detection-based when unflagged; positive flag forces
982
+ on and suppresses auto-detection; skip forces off) and avoid Commander’s `--no-<x>` for
983
+ surfaces, which defaults the value to `true` (§6.6).
984
+
985
+ **Global mode skips global `AGENTS.md` by default.** `AGENTS.md` loads on every turn;
986
+ skills are progressive-disclosure (~100 tokens until invoked).
987
+ Writing a global block to `~/.codex/AGENTS.md` would tax every session in every project,
988
+ so global install should populate only the skill-discovery dirs.
989
+ `--global --surfaces=agents-md` should **error** with a clear “we don’t support this”
990
+ message rather than silently do it.
991
+ (`qmd` validates this from the lighter end—it writes no `AGENTS.md` block in *any*
992
+ scope.)
993
+
994
+ **Cross-scope coexistence is the supported pattern, not a conflict.** Having a skill
995
+ installed both globally and per-project is a feature: **project scope shadows user
996
+ scope**, exactly like `git config`, shell `$PATH`, npm, and Python site-packages, and
997
+ matching the path-ordered DocCache in §6.3. Codex documents the same precedence in its
998
+ loader (`Repo` > `User` > `Admin`), and Claude Code ships `.claude/skills/` and
999
+ `~/.claude/skills/` as deliberately separate discovery paths.
1000
+ Don’t treat a dual install as something to detect and de-duplicate.
1001
+
815
1002
  ### 6.7 Making the CLI available: global install vs. zero-install
816
1003
 
817
1004
  A separate design dimension from §6.6 (how the CLI installs *itself into agents*) is how
@@ -828,13 +1015,13 @@ Decide this explicitly and state the chosen invocation in `SKILL.md`/`AGENTS.md`
828
1015
 
829
1016
  **Trade-offs**
830
1017
 
831
- - **Global install** — *Pros*: fastest invocation (no per-call resolution), works
832
- offline, and version is managed by the project (lockfile / `package.json` / `uv` tool
1018
+ - **Global install**—*Pros*: fastest invocation (no per-call resolution), works offline,
1019
+ and version is managed by the project (lockfile / `package.json` / `uv` tool
833
1020
  manifest), so it’s auditable and reproducible.
834
- *Cons*: it’s a stateful prerequisite in ephemeral or cloud environments the global
835
- bin doesn’t persist, so the CLI can be **missing at session start** unless you
836
- bootstrap it.
837
- - **Zero-install** — *Pros*: works in any environment with no setup; nothing to persist;
1021
+ *Cons*: it’s a stateful prerequisite—in ephemeral or cloud environments the global bin
1022
+ doesn’t persist, so the CLI can be **missing at session start** unless you bootstrap
1023
+ it.
1024
+ - **Zero-install**—*Pros*: works in any environment with no setup; nothing to persist;
838
1025
  ideal default for portability.
839
1026
  *Cons*: cold-start download/cache cost on first call (uvx cold ≈ 1s, cached ≈ tens of
840
1027
  ms; npx similar), needs network, and an **unpinned** invocation (`npx pkg`, `uvx pkg`)
@@ -849,7 +1036,7 @@ will fail on a fresh cloud session.
849
1036
 
850
1037
  **Pin the version (security).** Whichever you choose, the skill’s referenced invocation
851
1038
  should pin a version so the agent can’t silently run a newer (possibly compromised)
852
- release the §9 / 14-day-package-age rule applied to the runner itself:
1039
+ release—the §9 / 14-day-package-age rule applied to the runner itself:
853
1040
 
854
1041
  ```bash
855
1042
  uvx mytool@1.4.2 ... # not `uvx mytool`
@@ -884,7 +1071,7 @@ See `tbd guidelines supply-chain-hardening` for the cross-ecosystem policy.
884
1071
  Astral’s `uv`, Rust-fast, no Python prereq) or `pipx run <pkg>==<ver>`; persistent via
885
1072
  `uv tool install` / `pipx install`. `uvx` reuses a persistent install if one exists.
886
1073
  - **Go**: `go run <module>@<ver>` (compiles on the fly) or `go install`.
887
- - **Rust**: no first-class zero-install runner ship **prebuilt binaries** (GitHub
1074
+ - **Rust**: no first-class zero-install runner—ship **prebuilt binaries** (GitHub
888
1075
  releases and a `curl … | sh` installer) or `cargo binstall`; `cargo install` compiles.
889
1076
  - **Cross-language**: a prebuilt binary and install script, or a container image (Docker
890
1077
  is emerging as the production-grade distribution for MCP servers).
@@ -899,30 +1086,76 @@ configs; **CLIs** like Beads offer `brew` / `npm -g` / `curl` installers, while
899
1086
  **global install and a `SessionStart` bootstrap** as the optimization for persistent
900
1087
  environments where the project wants lockfile-managed versions and warm-start speed.
901
1088
 
902
- ### 6.8 Publishing & discovery make the skill installable
1089
+ ### 6.8 Publishing and discovery—make the skill installable
903
1090
 
904
- Most “skill registries” (May 2026) are **GitHub-repo discoverers, not gated app
905
- stores**. You don’t submit a form; you put a spec-compliant `SKILL.md` in a public repo
1091
+ Most “skill registries” (mid-2026) are **GitHub-repo discoverers, not gated app
1092
+ stores**: you don’t submit a form, you put a spec-compliant `SKILL.md` in a public repo
906
1093
  and the ecosystem finds it.
1094
+ The exception is **Anthropic’s own plugin marketplaces**, which *are* a reviewed,
1095
+ curated channel with a real submission and security-screening flow (below)—so the
1096
+ landscape is now a spectrum from passive scrapers to a gated store, not one shape.
907
1097
  The landscape worth targeting:
908
1098
 
909
- - **`skills.sh` / `npx skills add <owner/repo>`** (Vercel) the cross-agent “npm for
1099
+ - **`skills.sh` / `npx skills add <owner/repo>`** (Vercel)—the cross-agent “npm for
910
1100
  skills”: one command installs into `.agents/skills/` and symlinks per agent (Claude
911
1101
  Code, Codex, Cursor, Copilot, Gemini, …). No review; ranked by install telemetry.
912
1102
  **This is the highest-leverage target** and needs zero extra infra.
913
1103
  - **GitHub-scraping indexers** (SkillsMP ~800k skills, ClaudeSkills.info, LobeHub,
914
- claudemarketplaces.com) auto-list public repos that contain a `SKILL.md` (often
915
- gated on ≥2 stars). You get listed for free just by being public and discoverable.
916
- - **Plugin marketplaces** — `.claude-plugin/marketplace.json` (Claude Code, the official
917
- Anthropic channel) and `.agents/plugins/marketplace.json` (Codex; Codex reads both).
1104
+ claudemarketplaces.com)—auto-list public repos that contain a `SKILL.md` (often gated
1105
+ on ≥2 stars). You get listed for free just by being public and discoverable.
1106
+ - **Self-hosted plugin marketplaces**—`.claude-plugin/marketplace.json` (Claude Code)
1107
+ and `.agents/plugins/marketplace.json` (Codex; Codex reads both).
918
1108
  These are *plugin* channels: bundles of skills, MCP servers, hooks, and commands.
919
- They are **only for publishing a bundle** — a repo-local skill already loads from
1109
+ They are **only for publishing a bundle**—a repo-local skill already loads from
920
1110
  `.claude/skills/` (Claude Code) and `.agents/skills/` (Codex) **without any
921
1111
  manifest**, so don’t add one just to be discovered.
1112
+ Users add yours with `/plugin marketplace add <owner/repo>` and install with
1113
+ `/plugin install <name>@<marketplace>`; it is not centrally indexed unless you also
1114
+ list on the community marketplace (next bullet).
922
1115
  If you *do* emit a `marketplace.json` / `.codex-plugin/plugin.json`, treat it like any
923
1116
  generated artifact (§6.6): point it at the same generated `SKILL.md` payload (no body
924
1117
  duplication), mark it `DO NOT EDIT`, make it deterministic so re-install is a no-op,
925
1118
  and pick the same commit-vs-gitignore mode as the skill it references.
1119
+ - **Anthropic’s official and community marketplaces**—the one genuinely *gated* channel,
1120
+ and the only place a third party gets a reviewed, security-scanned listing.
1121
+ Two catalogs ship with Claude Code:
1122
+ - **`claude-plugins-official`**—auto-available in every session (catalog at
1123
+ `claude.com/plugins`); curated by Anthropic, inclusion **at its discretion, not
1124
+ self-serve**. Install: `/plugin install <name>@claude-plugins-official`.
1125
+ - **`anthropics/claude-plugins-community`** (install name `claude-community`)—a
1126
+ **read-only nightly mirror of Anthropic’s internal review pipeline**. Third-party
1127
+ plugins that pass **automated validation + security screening** get listed, each
1128
+ **pinned to a commit SHA**. Users add it manually
1129
+ (`/plugin marketplace add anthropics/claude-plugins-community`) then
1130
+ `/plugin install <name>@claude-community`. **Submitting**: do *not* open a PR
1131
+ against the repo—they are auto-closed.
1132
+ Submit through the in-app form / `clau.de/plugin-directory-submission` and let the
1133
+ scan and approval run (the in-app forms feed the *community* marketplace, never the
1134
+ official one). This is the channel that buys **trust and discoverability inside
1135
+ Claude Code**: current `/plugin` install views show a **Context cost** estimate
1136
+ (per-turn token cost; v2.1.143+), a **Last updated** date (v2.1.144+), and a **Will
1137
+ install** breakdown (commands, agents, skills, hooks, MCP/LSP; v2.1.145+) before the
1138
+ user commits—best-in-class informed consent.
1139
+ Worth it for a tool you want broadly adopted; still optional, since a repo-local
1140
+ skill loads with none of it.
1141
+
1142
+ **Channels at a glance** (generic; verify specifics against current docs—this space
1143
+ moves fast). The rows run from lowest effort/reach to highest trust, and they
1144
+ **compose**: a single public repo can satisfy every row at once.
1145
+
1146
+ | Channel | User install | Discovery & reach | Trust & security | Versioning | Publish / submit |
1147
+ | --- | --- | --- | --- | --- | --- |
1148
+ | **Documented install** (README + optional installer) | A few manual steps, or one command if you ship `mytool install` | None beyond the repo’s own stars/SEO | Fully manual—user reads the source before running | Whatever your docs pin; manual re-pull | Push the repo and write the README |
1149
+ | **`npx skills add`** (skills.sh, Vercel) | `npx skills add <owner/repo>`—one command, 50+ agents, symlink or copy | High and **cross-agent**; `npx skills find`, ranked by install telemetry | Runs the `skills` CLI + your repo; review the `SKILL.md`, pin to a ref | Tracks the repo/ref; `npx skills update`; no semver | Put `skills/<name>/SKILL.md` in a public repo—auto-works. [skills.sh](https://skills.sh) · [vercel-labs/skills](https://github.com/vercel-labs/skills) |
1150
+ | **GitHub-scraping indexers** (SkillsMP, claudemarketplaces, LobeHub…) | They hand you one of the other commands | Highest *passive* top-of-funnel; free; often gated on ≥2 stars | Mostly unvetted link directories; you don’t control the listing | Inherits the underlying method | Automatic once public—no action. e.g. [claudemarketplaces.com](https://claudemarketplaces.com) |
1151
+ | **Self-hosted plugin marketplace** (Claude Code / Codex) | `/plugin marketplace add <owner/repo>`, then `/plugin install <name>@<mp>` (or the `/plugin` UI) | Inside Claude Code once added; **not** centrally indexed | Your repo’s trust only; install preview shows exactly what loads | **Best**—`version` field + SHA pin + auto-update toggle | Add `.claude-plugin/marketplace.json`. [Docs](https://code.claude.com/docs/en/plugin-marketplaces) |
1152
+ | **Anthropic official / community marketplace** | Official: auto-available (`<name>@claude-plugins-official`). Community: add `anthropics/claude-plugins-community`, then `<name>@claude-community` | Highest inside Claude Code (Discover tab, `claude.com/plugins`) | **Best**—reviewed, security-screened, SHA-pinned, install preview | SHA-pinned in the catalog; nightly-mirror updates | Official: not self-serve (Anthropic’s discretion). Community: submit at [clau.de/plugin-directory-submission](https://clau.de/plugin-directory-submission) (no PRs—auto-closed). [Docs](https://code.claude.com/docs/en/discover-plugins) |
1153
+
1154
+ **Takeaway**: for broad cross-agent reach at near-zero effort, ship a valid `SKILL.md`
1155
+ and lean on `npx skills add` plus the scrapers; for the highest trust and
1156
+ discoverability *inside Claude Code*, additionally submit to the community marketplace.
1157
+ Reserve a self-hosted marketplace for a private/team channel or to bundle hooks, agents,
1158
+ and MCP servers alongside the skill.
926
1159
 
927
1160
  **The simplest publishable structure** (works for all of the above at once):
928
1161
 
@@ -935,11 +1168,11 @@ your-repo/
935
1168
 
936
1169
  `skills/<name>/SKILL.md` at the repo root is the universal discovery location
937
1170
  (`npx skills add`, the indexers, and agent installers all scan it).
938
- That’s the whole publishing step push it public.
1171
+ That’s the whole publishing step—push it public.
939
1172
 
940
1173
  **For a CLI-backed skill** (the §6 pattern), one extra rule matters: a registry installs
941
1174
  **only the Markdown**, never your binary.
942
- So the published `SKILL.md` must **bootstrap its own CLI** — lead with a pinned install
1175
+ So the published `SKILL.md` must **bootstrap its own CLI**—lead with a pinned install
943
1176
  line (`npm i -g <pkg>@<ver>` / `uvx --from <pkg>@<ver>`) and a one-time `setup`, and
944
1177
  have commands degrade with a clear “install the CLI first” message.
945
1178
  Treat the registry copy as a **landing page that installs the engine**, not the engine
@@ -949,13 +1182,13 @@ pushing.
949
1182
 
950
1183
  `tbd` does exactly this: `skills/tbd/SKILL.md` is generated at build time from the same
951
1184
  baseline, carries `name: tbd` and a trigger-rich description, and opens with the
952
- `npm install -g get-tbd` and `tbd setup --auto` bootstrap so
953
- `npx skills add jlevy/tbd` gives an agent a working landing page, and `tbd setup` then
954
- upgrades it to the full multi-agent install (§6.6).
1185
+ `npm install -g get-tbd` and `tbd setup --auto` bootstrap—so `npx skills add jlevy/tbd`
1186
+ gives an agent a working landing page, and `tbd setup` then upgrades it to the full
1187
+ multi-agent install (§6.6).
955
1188
 
956
1189
  * * *
957
1190
 
958
- ## 7. CLI vs MCP vs Skill Choosing the Surface
1191
+ ## 7. CLI vs MCP vs Skill—Choosing the Surface
959
1192
 
960
1193
  These are complementary, not competing.
961
1194
  Pick by need:
@@ -969,25 +1202,25 @@ Pick by need:
969
1202
 
970
1203
  **Why CLI usually wins when one exists**: benchmarks (2026) put a CLI at ~100% task
971
1204
  reliability and ~1.3K–8.7K tokens, vs.
972
- MCP at ~72% reliability and ~32K–82K tokens roughly **17× cheaper** at scale because
1205
+ MCP at ~72% reliability and ~32K–82K tokens—roughly **17× cheaper** at scale—because
973
1206
  LLMs already know common CLI usage and no tool schema is injected.
974
1207
  Use MCP when there’s no CLI to lean on or you need its auth/permission machinery.
975
1208
 
976
- **MCP current state (May 2026)**: governed by AAIF/Linux Foundation; two transports —
977
- **stdio** (local) and **Streamable HTTP** (remote; replaced legacy SSE in the Nov 2025
978
- spec, supports OAuth 2.1 + PKCE). Primitives: **tools**, **resources**, **prompts**.
979
- Security is a real concern (a scan found 492 public servers with no auth) — authenticate
980
- every request, scope every tool call, validate inputs, never pass tokens between
981
- servers.
1209
+ **MCP current state (May 2026)**: governed by AAIF/Linux Foundation; two
1210
+ transports—**stdio** (local) and **Streamable HTTP** (remote; replaced legacy SSE in the
1211
+ Nov 2025 spec, supports OAuth 2.1 + PKCE). Primitives: **tools**, **resources**,
1212
+ **prompts**. Security is a real concern (a scan found 492 public servers with no
1213
+ auth)—authenticate every request, scope every tool call, validate inputs, never pass
1214
+ tokens between servers.
982
1215
 
983
1216
  **Code execution with MCP** ("Code Mode"): instead of exposing many MCP tools as direct
984
1217
  calls (each ~550–1,400 tokens of schema), let the agent write code against a compact
985
- tool API in a sandbox reported 78–99% token reduction.
1218
+ tool API in a sandbox—reported 78–99% token reduction.
986
1219
  Worth it when an MCP server exposes *many* tools; overkill for one.
987
1220
 
988
1221
  * * *
989
1222
 
990
- ## 8. Hooks & Lifecycle (Cross-Agent)
1223
+ ## 8. Hooks and Lifecycle (Cross-Agent)
991
1224
 
992
1225
  Hooks let a tool inject context or enforce invariants automatically.
993
1226
  Support varies:
@@ -1002,7 +1235,7 @@ Support varies:
1002
1235
  via exit code 2), **Gemini CLI** (~12), and **opencode** (25+, with tool interception)
1003
1236
  all have lifecycle hooks.
1004
1237
  - **Codex** (as of May 2026) ships a **Claude-style hooks engine that uses the same
1005
- event schema as Claude Code** — `SessionStart`, `PreCompact`/`PostCompact`,
1238
+ event schema as Claude Code**—`SessionStart`, `PreCompact`/`PostCompact`,
1006
1239
  `PreToolUse`/`PostToolUse`, `UserPromptSubmit`, `Stop`,
1007
1240
  `SubagentStart`/`SubagentStop`, and `PermissionRequest`. Hooks load from `hooks.json`
1008
1241
  **or an inline `[hooks]` table in `config.toml`** next to an active config layer
@@ -1018,7 +1251,7 @@ Support varies:
1018
1251
  **Common, portable use**: a `SessionStart` hook that runs your CLI’s `prime`/`skill`
1019
1252
  command to restore workflow context; a `PreCompact` hook that re-injects a brief
1020
1253
  (`skill --brief`) before the window is trimmed.
1021
- Keep injected context small it competes with everything else.
1254
+ Keep injected context small—it competes with everything else.
1022
1255
 
1023
1256
  ```jsonc
1024
1257
  // Claude Code ~/.claude/settings.json
@@ -1032,7 +1265,7 @@ Keep injected context small — it competes with everything else.
1032
1265
 
1033
1266
  * * *
1034
1267
 
1035
- ## 9. Security & Supply Chain (Don’t Skip This)
1268
+ ## 9. Security and Supply Chain (Don’t Skip This)
1036
1269
 
1037
1270
  Skills and instruction files are **executable influence** on an agent, which makes them
1038
1271
  an attack surface. Treat them with the same care as dependencies.
@@ -1044,11 +1277,11 @@ an attack surface. Treat them with the same care as dependencies.
1044
1277
  input**.
1045
1278
  - **Never put secrets in skill/instruction files or tool output.** `AGENTS.md`,
1046
1279
  `SKILL.md`, bundled scripts, and anything a command prints get loaded into agent
1047
- context (and often committed) keep credentials, tokens, and keys out of them; read
1280
+ context (and often committed)—keep credentials, tokens, and keys out of them; read
1048
1281
  secrets from the environment at runtime instead.
1049
1282
  - **Vet third-party skills before install.** Prefer sources that scan (skills.sh runs
1050
1283
  Snyk on every install).
1051
- Read the body and any bundled scripts review them like dependency code.
1284
+ Read the body and any bundled scripts—review them like dependency code.
1052
1285
  Pin to a commit, not a moving tag.
1053
1286
  - **Scope tools tightly.** Use `allowed-tools` to grant the minimum (e.g.,
1054
1287
  `Bash(mycli:*)` not blanket `Bash`). Prefer `disable-model-invocation` for
@@ -1059,35 +1292,34 @@ an attack surface. Treat them with the same care as dependencies.
1059
1292
  denied.
1060
1293
  - **Apply the same currency discipline** you use for packages: if your skill ships a
1061
1294
  script with dependencies, the project’s supply-chain rules (e.g., the 14-day
1062
- package-age rule) apply and a skill that references a zero-install runner must pin
1063
- the version (§6.7), since unpinned `npx`/`uvx` bypasses the cool-off.
1295
+ package-age rule) apply—and a skill that references a zero-install runner must pin the
1296
+ version (§6.7), since unpinned `npx`/`uvx` bypasses the cool-off.
1064
1297
  See `tbd guidelines supply-chain-hardening` for the cross-ecosystem policy, or
1065
1298
  `tbd guidelines bun-monorepo-patterns` / `pnpm-monorepo-patterns` for monorepo
1066
1299
  specifics.
1067
1300
 
1068
1301
  * * *
1069
1302
 
1070
- ## 10. Emerging & Forward-Looking (Know It Exists)
1303
+ ## 10. Emerging and Forward-Looking (Know It Exists)
1071
1304
 
1072
1305
  You usually don’t need these to ship a skill, but they shape where the ecosystem is
1073
1306
  going:
1074
1307
 
1075
- - **ACP (Agent Client Protocol)** — Zed’s “LSP for agents” (JSON-RPC over stdio); 25+
1308
+ - **ACP (Agent Client Protocol)**—Zed’s “LSP for agents” (JSON-RPC over stdio); 25+
1076
1309
  agents (Claude Code, Codex, Gemini CLI, opencode) and editors (Zed, JetBrains, Kiro).
1077
1310
  Complements MCP (editor↔agent, while MCP is agent↔tools).
1078
1311
  Your agent runtime speaks it; a skill author doesn’t implement it.
1079
- - **A2A (Agent2Agent)** — Google/Linux Foundation, v1.0, 150+ orgs; for enterprise
1312
+ - **A2A (Agent2Agent)**—Google/Linux Foundation, v1.0, 150+ orgs; for enterprise
1080
1313
  agent-to-agent delegation, not skill authoring.
1081
1314
  Ignore unless you build autonomous multi-agent systems.
1082
- - **Codex App-Server** — JSON-RPC (Thread/Turn/Item) decoupling Codex logic from client
1315
+ - **Codex App-Server**—JSON-RPC (Thread/Turn/Item) decoupling Codex logic from client
1083
1316
  surfaces; relevant only for Codex-specific integration surfaces.
1084
- - **Plugin marketplaces & `npx skills`** — distribution is consolidating: Claude Code
1317
+ - **Plugin marketplaces & `npx skills`**—distribution is consolidating: Claude Code
1085
1318
  plugin marketplaces (official and community), Codex plugins, and Vercel’s
1086
1319
  `npx skills add` over the skills.sh directory (cross-agent symlinks).
1087
- - **Routines / scheduled agents, background monitors, `/run` & `/verify` skills** —
1088
- newer Claude Code capabilities for autonomous, event-triggered, and app-verifying
1089
- workflows (confirm GA vs.
1090
- preview for your version before relying on them).
1320
+ - **Routines / scheduled agents, background monitors, `/run` & `/verify` skills**—newer
1321
+ Claude Code capabilities for autonomous, event-triggered, and app-verifying workflows
1322
+ (confirm GA vs. preview for your version before relying on them).
1091
1323
 
1092
1324
  * * *
1093
1325
 
@@ -1101,7 +1333,7 @@ going:
1101
1333
  - Have a CLI → make it agent-friendly (`--json`, idempotent, actionable errors) and
1102
1334
  point a `SKILL.md` at it.
1103
1335
 
1104
- **Descriptions & disclosure**
1336
+ **Descriptions and disclosure**
1105
1337
 
1106
1338
  - Two-part rule: *what it does* + *when to use it*; third person; front-load keywords.
1107
1339
  - Progressive disclosure: metadata → body → supporting files; bundle scripts
@@ -1109,19 +1341,21 @@ going:
1109
1341
  - Route, don’t restate: name each capability and the command to run; let the CLI’s
1110
1342
  `--help` and informational subcommands hold the flags and recipes.
1111
1343
  Carry the focused context an agent needs to judge that the tool is relevant, but don’t
1112
- blindly copy help into the skill; that wastes context and goes stale (§3.1, §6.5).
1344
+ blindly copy help into the skill; that wastes context and goes stale (§3.1, §6.5). The
1345
+ two failure modes: **slopdocs** (copying too much or unthinkingly) and **hiding
1346
+ details** (copying too little—content hidden behind links the agent won’t follow).
1113
1347
  - Respect the budget; verify the current model for your target agent (Claude Code ≈ 1%
1114
1348
  of context window, not a flat char count).
1115
1349
 
1116
1350
  **Scale up only when needed**
1117
1351
 
1118
- - Many capabilities → meta-skill + informational, self-injecting subcommands (one
1352
+ - Many capabilities → meta-skill and informational, self-injecting subcommands (one
1119
1353
  listing slot, unbounded resources).
1120
1354
  This is tbd’s validated approach.
1121
1355
  - Path-ordered resource cache for project/user shadowing; generate `--list` dynamically.
1122
1356
  - Context-injection loop with explicit `cli command arg` references; depth ≤ 3.
1123
1357
 
1124
- **Reach & surface**
1358
+ **Reach and surface**
1125
1359
 
1126
1360
  - Layer for reach: `AGENTS.md` + `SKILL.md` + CLI + (MCP if no CLI fits).
1127
1361
  - Prefer CLI over MCP when a CLI exists (cheaper, more reliable); use MCP for
@@ -1147,6 +1381,9 @@ going:
1147
1381
  - [ ] Body carries the essential context to judge whether the tool is relevant and to
1148
1382
  name each key use case, but routes to `mycli <cmd> --help` or `--list` for flags and
1149
1383
  recipes instead of copying help wholesale
1384
+ - [ ] No **slopdocs** (help, flags, or recipes copied in unthinkingly) and no **hiding
1385
+ details** (capabilities behind bare links with too little context to show they are
1386
+ worth following)
1150
1387
  - [ ] Third-person description, trigger keywords front-loaded
1151
1388
  - [ ] Installable via commit to `.agents/skills/`, Claude mirror at `.claude/skills/`,
1152
1389
  and/or `npx skills add`
@@ -1187,7 +1424,7 @@ going:
1187
1424
 
1188
1425
  ## References
1189
1426
 
1190
- ### Open standards & governance
1427
+ ### Open standards and governance
1191
1428
 
1192
1429
  - Agent Skills standard: https://agentskills.io (spec:
1193
1430
  https://agentskills.io/specification)
@@ -1225,7 +1462,7 @@ going:
1225
1462
  - Amp: https://ampcode.com/manual
1226
1463
  - pi: https://github.com/badlogic/pi-mono
1227
1464
 
1228
- ### MCP & protocols
1465
+ ### MCP and protocols
1229
1466
 
1230
1467
  - 2026 MCP roadmap: https://blog.modelcontextprotocol.io/posts/2026-mcp-roadmap/
1231
1468
  - Code execution with MCP: https://www.anthropic.com/engineering/code-execution-with-mcp
@@ -1234,14 +1471,23 @@ going:
1234
1471
  - A2A:
1235
1472
  https://www.linuxfoundation.org/press/a2a-protocol-surpasses-150-organizations-lands-in-major-cloud-platforms-and-sees-enterprise-production-use-in-first-year
1236
1473
 
1237
- ### Distribution & ecosystem
1474
+ ### Distribution and ecosystem
1238
1475
 
1239
1476
  - Vercel skills / skills.sh:
1240
1477
  https://vercel.com/changelog/introducing-skills-the-open-agent-skills-ecosystem
1241
1478
  - npx skills: https://github.com/vercel-labs/skills
1242
1479
  - Anthropic skills (examples): https://github.com/anthropics/skills
1480
+ - Discover and install plugins (official + community marketplaces, `/plugin` install
1481
+ preview): https://code.claude.com/docs/en/discover-plugins
1482
+ - Create and distribute a plugin marketplace:
1483
+ https://code.claude.com/docs/en/plugin-marketplaces
1484
+ - Community marketplace + submission flow:
1485
+ https://github.com/anthropics/claude-plugins-community (submit via
1486
+ https://clau.de/plugin-directory-submission)
1243
1487
  - gstack: https://github.com/garrytan/gstack
1244
1488
  - Beads (bd): https://github.com/gastownhall/beads
1489
+ - qmd (L2 reference: self-installing skill, discovery-dirs only, CLI + MCP + plugin):
1490
+ https://github.com/tobi/qmd
1245
1491
 
1246
1492
  ### Security
1247
1493