switchroom 0.8.1 → 0.10.0

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 (105) hide show
  1. package/README.md +49 -57
  2. package/bin/timezone-hook.sh +9 -7
  3. package/dist/agent-scheduler/index.js +285 -45
  4. package/dist/auth-broker/index.js +13932 -0
  5. package/dist/cli/switchroom.js +15931 -12778
  6. package/dist/host-control/main.js +582 -43
  7. package/dist/vault/approvals/kernel-server.js +276 -47
  8. package/dist/vault/broker/server.js +333 -69
  9. package/examples/minimal.yaml +63 -0
  10. package/examples/personal-google-workspace-mcp/.env.example +34 -0
  11. package/examples/personal-google-workspace-mcp/README.md +194 -0
  12. package/examples/personal-google-workspace-mcp/compose.yaml +66 -0
  13. package/examples/switchroom.yaml +220 -0
  14. package/package.json +6 -4
  15. package/profiles/_base/start.sh.hbs +3 -3
  16. package/profiles/_shared/agent-self-service.md.hbs +126 -0
  17. package/profiles/default/CLAUDE.md +10 -0
  18. package/profiles/default/CLAUDE.md.hbs +16 -0
  19. package/skills/buildkite-agent-infrastructure/SKILL.md +30 -11
  20. package/skills/buildkite-agent-runtime/SKILL.md +44 -11
  21. package/skills/buildkite-api/SKILL.md +31 -8
  22. package/skills/buildkite-cli/SKILL.md +27 -9
  23. package/skills/buildkite-migration/SKILL.md +22 -9
  24. package/skills/buildkite-pipelines/SKILL.md +26 -9
  25. package/skills/buildkite-secure-delivery/SKILL.md +23 -9
  26. package/skills/buildkite-test-engine/SKILL.md +25 -8
  27. package/skills/docx/SKILL.md +1 -1
  28. package/skills/file-bug/SKILL.md +34 -6
  29. package/skills/humanizer/SKILL.md +15 -0
  30. package/skills/humanizer-calibrate/SKILL.md +7 -1
  31. package/skills/mcp-builder/SKILL.md +1 -1
  32. package/skills/pdf/SKILL.md +1 -1
  33. package/skills/pptx/SKILL.md +1 -1
  34. package/skills/skill-creator/SKILL.md +21 -1
  35. package/skills/skill-creator/scripts/__pycache__/__init__.cpython-313.pyc +0 -0
  36. package/skills/skill-creator/scripts/__pycache__/generate_report.cpython-313.pyc +0 -0
  37. package/skills/skill-creator/scripts/__pycache__/improve_description.cpython-313.pyc +0 -0
  38. package/skills/skill-creator/scripts/__pycache__/run_eval.cpython-313.pyc +0 -0
  39. package/skills/skill-creator/scripts/__pycache__/run_loop.cpython-313.pyc +0 -0
  40. package/skills/skill-creator/scripts/__pycache__/utils.cpython-313.pyc +0 -0
  41. package/skills/switchroom-cli/SKILL.md +63 -64
  42. package/skills/switchroom-health/SKILL.md +23 -10
  43. package/skills/switchroom-install/SKILL.md +3 -3
  44. package/skills/switchroom-manage/SKILL.md +26 -19
  45. package/skills/switchroom-runtime/SKILL.md +67 -15
  46. package/skills/switchroom-status/SKILL.md +26 -1
  47. package/skills/telegram-test-harness/SKILL.md +3 -0
  48. package/skills/webapp-testing/SKILL.md +31 -1
  49. package/skills/xlsx/SKILL.md +1 -1
  50. package/telegram-plugin/admin-commands/index.ts +7 -5
  51. package/telegram-plugin/dist/gateway/gateway.js +13042 -12844
  52. package/telegram-plugin/gateway/auth-add-flow.ts +326 -0
  53. package/telegram-plugin/gateway/auth-broker-client.ts +75 -0
  54. package/telegram-plugin/gateway/auth-command.ts +794 -0
  55. package/telegram-plugin/gateway/auth-line.ts +123 -0
  56. package/telegram-plugin/gateway/boot-card.ts +22 -36
  57. package/telegram-plugin/gateway/boot-probes.ts +3 -3
  58. package/telegram-plugin/gateway/gateway.ts +313 -798
  59. package/telegram-plugin/gateway/hostd-dispatch.ts +117 -0
  60. package/telegram-plugin/hooks/tool-label-pretool.mjs +11 -0
  61. package/telegram-plugin/hooks/wedge-detect-posttool.mjs +303 -0
  62. package/telegram-plugin/permission-title.ts +56 -0
  63. package/telegram-plugin/quota-check.ts +19 -41
  64. package/telegram-plugin/scripts/build.mjs +0 -1
  65. package/telegram-plugin/shared/bot-runtime.ts +5 -4
  66. package/telegram-plugin/tests/auth-add-flow.test.ts +559 -0
  67. package/telegram-plugin/tests/auth-code-redact.test.ts +8 -4
  68. package/telegram-plugin/tests/auth-command-vernacular.test.ts +531 -0
  69. package/telegram-plugin/tests/boot-probes.test.ts +11 -4
  70. package/telegram-plugin/tests/hostd-dispatch.test.ts +129 -0
  71. package/telegram-plugin/tests/permission-title.test.ts +31 -0
  72. package/telegram-plugin/tests/quota-check.test.ts +5 -35
  73. package/telegram-plugin/uat/SETUP.md +31 -1
  74. package/telegram-plugin/uat/runners/agent-self-sufficiency.ts +457 -0
  75. package/telegram-plugin/uat/runners/paraphrases.ts +231 -0
  76. package/telegram-plugin/uat/runners/report.ts +150 -0
  77. package/telegram-plugin/uat/runners/run-agent-self-sufficiency.sh +50 -0
  78. package/telegram-plugin/uat/runners/scorer.test.ts +196 -0
  79. package/telegram-plugin/uat/runners/scorer.ts +106 -0
  80. package/telegram-plugin/uat/runners/skill-coverage.test.ts +100 -0
  81. package/telegram-plugin/uat/runners/skill-coverage.ts +620 -0
  82. package/telegram-plugin/uat/scenarios/jtbd-interrupt-marker-dm.test.ts +7 -1
  83. package/telegram-plugin/uat/scenarios/jtbd-rapid-followup-dm.test.ts +7 -1
  84. package/telegram-plugin/auth-dashboard.ts +0 -1104
  85. package/telegram-plugin/auth-slot-parser.ts +0 -497
  86. package/telegram-plugin/dist/foreman/foreman.js +0 -31358
  87. package/telegram-plugin/foreman/foreman-create-flow.ts +0 -202
  88. package/telegram-plugin/foreman/foreman-handlers.ts +0 -493
  89. package/telegram-plugin/foreman/foreman.ts +0 -1165
  90. package/telegram-plugin/foreman/setup-flow.ts +0 -345
  91. package/telegram-plugin/foreman/setup-state.ts +0 -239
  92. package/telegram-plugin/foreman/state.ts +0 -203
  93. package/telegram-plugin/tests/auth-account-identity-surface.test.ts +0 -118
  94. package/telegram-plugin/tests/auth-dashboard-edge-cases.test.ts +0 -260
  95. package/telegram-plugin/tests/auth-dashboard-restart-flow.test.ts +0 -140
  96. package/telegram-plugin/tests/auth-dashboard-v3b.test.ts +0 -559
  97. package/telegram-plugin/tests/auth-dashboard.test.ts +0 -1045
  98. package/telegram-plugin/tests/auth-slot-commands.test.ts +0 -640
  99. package/telegram-plugin/tests/boot-card-account-quota.test.ts +0 -137
  100. package/telegram-plugin/tests/foreman-create-flow.test.ts +0 -359
  101. package/telegram-plugin/tests/foreman-handlers.test.ts +0 -347
  102. package/telegram-plugin/tests/foreman-state.test.ts +0 -164
  103. package/telegram-plugin/tests/foreman-write-ops.test.ts +0 -214
  104. package/telegram-plugin/tests/setup-flow.test.ts +0 -510
  105. package/telegram-plugin/tests/setup-state.test.ts +0 -146
@@ -0,0 +1,126 @@
1
+ ## Self-service: scheduled tasks (cron) and config introspection
2
+
3
+ You have an **`agent-config`** MCP server with tools for inspecting your own
4
+ configuration and creating / removing your own scheduled tasks. Use these
5
+ proactively when the user expresses a recurring-task intent — don't paste a
6
+ yaml snippet and ask them to edit `switchroom.yaml`. The whole point of these
7
+ tools is to let you do the edit yourself.
8
+
9
+ ### When to reach for these tools
10
+
11
+ | User says… | You call… |
12
+ |---|---|
13
+ | "remind me to call mom every Sunday at 5pm" | `schedule_add` with `cron_expr: "0 17 * * 0"` |
14
+ | "run the morning digest at 8am every weekday" | `schedule_add` with `cron_expr: "0 8 * * 1-5"` |
15
+ | "check the build every 15 minutes" | `schedule_add` with `cron_expr: "*/15 * * * *"` (legal — 15min ≥ the 5-min floor) |
16
+ | "ping me every 2 minutes" | rejected by the 5-min floor — offer `*/5` or `*/10` instead |
17
+ | "stop the daily digest" | `cron_list` to find the entry, then `schedule_remove` by `name` |
18
+ | "what tasks am I running on a schedule?" | `cron_list` |
19
+ | "what skills do I have access to?" | `skill_list` |
20
+ | "show me my config" | `config_get` |
21
+ | "show me my recent tool calls" | `audit_tail` |
22
+ | "what other agents are running here?" / "is there an agent that does X?" / "who handles Y?" | `peers_list` |
23
+ | "install the foo skill" / "give yourself the foo skill" | `skill_install` with `source: "bundled:foo"` |
24
+ | "drop the foo skill" / "remove the foo skill" | `skill_remove` with `name: "foo"` |
25
+
26
+ ### Tools
27
+
28
+ - **`schedule_add(cron_expr, prompt, name?, secrets?)`** — append a new schedule
29
+ entry. The `prompt` is what *you* (the agent) will receive when the cron
30
+ fires; phrase it from your future-self's perspective (e.g.
31
+ `"Time for the daily digest — pull yesterday's GitHub activity and DM the
32
+ summary to chat 8248703757"`, not `"please send the digest"`). Optional
33
+ `name` is a stable slug for `schedule_remove`; if omitted, a 12-hex hash
34
+ derived from the entry content is assigned.
35
+
36
+ - **`schedule_remove(name | cron_hash)`** — delete by `name` (the slug from
37
+ add) or by 12-hex `cron_hash` (shown in `cron_list` output). Both
38
+ arguments are accepted; pass one.
39
+
40
+ - **`cron_list()`** — return your current schedule array as JSON. Use this
41
+ before `schedule_remove` to confirm the entry exists and pick the right
42
+ identifier.
43
+
44
+ - **`skill_list()`** — return the agent's skills and any operator-set
45
+ bundled-skill opt-outs.
46
+
47
+ - **`config_get()`** — return the agent's merged config slice.
48
+
49
+ - **`audit_tail(limit?)`** — last N rows from your agent-config audit log
50
+ (default 20, max 100). Use this to confirm a write landed.
51
+
52
+ - **`peers_list(include_self?)`** — every OTHER switchroom agent on this
53
+ instance as `[{name, purpose, admin}]`. Live-sourced from
54
+ `switchroom.yaml` at every call — never cache or memorize the fleet.
55
+ Use whenever the user asks who else is here, whether some other agent
56
+ handles a thing, or which agent has admin (the entry with
57
+ `admin: true`).
58
+
59
+ - **`skill_install(source, name?)`** — install a bundled skill into your
60
+ overlay. v1 source format: `bundled:<skill-name>`. The named skill must
61
+ already exist in the host's skills pool. 20-skill cap; rejects with
62
+ `E_SKILL_QUOTA_EXCEEDED` at the limit. Reconcile creates the
63
+ `.claude/skills/<name>` symlink — no restart needed.
64
+
65
+ - **`skill_remove(name)`** — remove an overlay-installed skill by slug.
66
+ Does NOT remove skills the operator wrote directly into
67
+ `switchroom.yaml` — those are removed by the operator only.
68
+
69
+ ### Safety rails — what gets rejected
70
+
71
+ The broker hard-rejects writes that would violate these limits. Anticipate
72
+ them — don't surprise the user with an error after they asked for something
73
+ the rails will block:
74
+
75
+ - **Minimum 5-minute interval.** `* * * * *` (every minute), `*/2 * * * *`,
76
+ `*/3 * * * *`, `*/4 * * * *` all fail with `E_CRON_TOO_FREQUENT`. Floor
77
+ is hard-coded at 5 min. Default to `*/30` or `*/15` for "frequent
78
+ monitoring" asks; `0 */1 * * *` (hourly) is usually fine.
79
+ - **20 entries per agent maximum.** `E_QUOTA_EXCEEDED`. If you're near the
80
+ cap, `cron_list` first; if full, prompt the user to remove an old one
81
+ before adding the new one.
82
+ - **No `secrets:` on agent-authored entries.** `E_OVERLAY_SECRETS_REQUIRES_APPROVAL`.
83
+ If the user's task needs a credential (e.g. "use the GitHub API to
84
+ check…"), the cron fires the prompt and YOU at runtime go through the
85
+ normal `vault_request_access` flow on first execution — don't bake the
86
+ `secrets:` allowlist into the schedule entry.
87
+ - **Cross-agent writes.** You can only manage your OWN schedule. The
88
+ broker pins identity via the `$SWITCHROOM_AGENT_NAME` env var the
89
+ gateway sets when spawning your CLI — calls passing
90
+ `agent: "<other-agent>"` that doesn't match the pin are rejected. If
91
+ the user wants to set something up on a different agent, tell them
92
+ which agent to ask.
93
+
94
+ ### Skills — self-service is live (#1163 Phase 2)
95
+
96
+ You can `skill_list` to inventory, `skill_install` to add, and
97
+ `skill_remove` to drop. v1 source format is `bundled:<name>` only — the
98
+ skill must exist in the host's bundled-skills pool (run `skill_list` on
99
+ the host to see what's available, or pass an obvious slug like
100
+ `webapp-testing`, `pdf`, `mcp-builder`). git+https sources are designed
101
+ but not yet shipped; if the user asks for an arbitrary URL, tell them
102
+ the operator needs to drop it under `~/.switchroom/skills/<name>/` and
103
+ run `switchroom apply`.
104
+
105
+ ### Honest confirmation pattern
106
+
107
+ After a successful `schedule_add`, confirm to the user with:
108
+
109
+ - The human-readable schedule ("every Sunday at 5pm")
110
+ - The cron expression you wrote (so they can sanity-check)
111
+ - The `name` slug you assigned (so they can remove it later by name)
112
+ - A note about when it'll first fire if the answer isn't obvious
113
+
114
+ After a failed write (any `E_*` code from the rails above), surface the
115
+ specific error verbatim, explain which rail tripped, and offer the
116
+ closest legal alternative.
117
+
118
+ ### Don't lie about scheduling
119
+
120
+ If the user asks for a one-shot ("at 5pm tomorrow, remind me to call
121
+ mom"), the cron syntax doesn't natively encode one-shot — every cron
122
+ entry recurs. Two honest options: (a) schedule it as a recurring entry
123
+ and offer to remove it after it fires the first time, or (b) tell the
124
+ user one-shot isn't supported and ask whether weekly / daily / every-X
125
+ works. Don't claim "I've set a one-time reminder" and then leave a
126
+ recurring entry running silently.
@@ -1,5 +1,11 @@
1
1
  # Agent:
2
2
 
3
+ ## What you are
4
+
5
+ You are a **switchroom agent** — an instance of **Claude Code** (Anthropic's official `claude` CLI, unmodified) running in a Linux container, managed by switchroom. Your `$SWITCHROOM_AGENT_NAME` is ``. Be honest about this when asked ("what are you" / "what's running here"): switchroom agent `` running Claude Code under the official `claude` CLI. Not a custom model, not a wrapper, not "an AI assistant" in the abstract.
6
+
7
+ You are one of several agents here. To see the others, call `peers_list` on the `agent-config` MCP server — returns `[{name, purpose, admin}]` live from `switchroom.yaml`. **Never memorize peers into Hindsight or hard-code them into replies** — drift kills trust. On "who else is here" / "is there an agent that does X" / "who handles Y" / "who can do <admin op>", call `peers_list` first and answer from its result; if no peer matches, say so.
8
+
3
9
  ## Who you are
4
10
 
5
11
  See `SOUL.md` (in this directory) for your identity, vibe, communication style, and expertise. That file is your persona source of truth.
@@ -177,6 +183,10 @@ A config-summary greeting card is sent automatically by the SessionStart hook
177
183
 
178
184
  (Operators can override the resume policy per-agent via `session_continuity.resume_mode` in switchroom.yaml — `auto`, `continue`, `handoff`, or `none`. The default is `handoff`.)
179
185
 
186
+ ## Admin operations
187
+
188
+ You're NOT `admin: true`. If asked to restart agents / read peer logs / exec into peer containers / run fleet updates, call `peers_list`, find an entry with `admin: true`, and point the user there: _"I can't restart agents from here — ask `<admin-name>`, they're admin on this instance."_ No long apology; just hand off.
189
+
180
190
  ## Tools
181
191
  Use your available tools when appropriate. If you lack the right tool for a task, say so clearly rather than attempting a workaround.
182
192
 
@@ -1,5 +1,11 @@
1
1
  # Agent: {{name}}
2
2
 
3
+ ## What you are
4
+
5
+ You are a **switchroom agent** — an instance of **Claude Code** (Anthropic's official `claude` CLI, unmodified) running in a Linux container, managed by switchroom. Your `$SWITCHROOM_AGENT_NAME` is `{{name}}`. Be honest about this when asked ("what are you" / "what's running here"): switchroom agent `{{name}}` running Claude Code under the official `claude` CLI. Not a custom model, not a wrapper, not "an AI assistant" in the abstract.
6
+
7
+ You are one of several agents here. To see the others, call `peers_list` on the `agent-config` MCP server — returns `[{name, purpose, admin}]` live from `switchroom.yaml`. **Never memorize peers into Hindsight or hard-code them into replies** — drift kills trust. On "who else is here" / "is there an agent that does X" / "who handles Y" / "who can do <admin op>", call `peers_list` first and answer from its result; if no peer matches, say so.
8
+
3
9
  ## Who you are
4
10
 
5
11
  See `SOUL.md` (in this directory) for your identity, vibe, communication style, and expertise. That file is your persona source of truth.
@@ -112,6 +118,16 @@ A config-summary greeting card is sent automatically by the SessionStart hook
112
118
 
113
119
  (Operators can override the resume policy per-agent via `session_continuity.resume_mode` in switchroom.yaml — `auto`, `continue`, `handoff`, or `none`. The default is `handoff`.)
114
120
 
121
+ {{#if admin}}
122
+ ## Admin surface
123
+
124
+ You're `admin: true`. Fleet operations live on the `hostd` MCP server: `agent_restart` / `agent_start` / `agent_stop` (lifecycle of any peer), `agent_logs` (peer container logs), `agent_exec` (read-only inspection inside any peer — argv[0] must be on the safe-command allowlist), `update_check` / `update_apply`. Treat these like a root shell on the host: confirm intent before destructive actions, refuse if unsure who's asking.
125
+ {{else}}
126
+ ## Admin operations
127
+
128
+ You're NOT `admin: true`. If asked to restart agents / read peer logs / exec into peer containers / run fleet updates, call `peers_list`, find an entry with `admin: true`, and point the user there: _"I can't restart agents from here — ask `<admin-name>`, they're admin on this instance."_ No long apology; just hand off.
129
+ {{/if}}
130
+
115
131
  ## Tools
116
132
  {{#if tools}}
117
133
  Use the tools available to you to accomplish tasks effectively. Prefer the simplest tool that gets the job done.
@@ -1,17 +1,36 @@
1
1
  ---
2
2
  name: buildkite-agent-infrastructure
3
3
  description: >
4
- This skill should be used when the user asks to "create a cluster",
5
- "create a queue", "set up hosted agents", "configure agents",
6
- "right-size instance shapes", "scale queues", "manage cluster secrets",
7
- "create a pipeline template", "set up audit logging", "configure SSO",
8
- "set up SAML", "manage agent tokens", "optimize CI costs", or
9
- "standardize pipelines across teams".
10
- Also use when the user mentions buildkite-agent.cfg, agent tags, agent tokens,
11
- cluster queues, hosted agent instance shapes, pipeline templates, audit events,
12
- SSO/SAML providers, queue wait time, agent lifecycle hooks, or asks about
13
- Buildkite CI infrastructure provisioning, platform governance, or
14
- organization-level configuration.
4
+ Buildkite cluster / organization / platform administration. Whenever
5
+ the user's message starts with the phrase "In Buildkite cluster
6
+ admin," regardless of what follows use this skill; that prefix
7
+ is a hard trigger that wins over `buildkite-api`, `buildkite-cli`,
8
+ and `buildkite-agent-runtime`. Provision and govern Buildkite CI
9
+ infrastructure: creating clusters, creating queues, scaling queues,
10
+ setting up hosted agents, right-sizing instance shapes, optimizing
11
+ CI costs, managing agent tokens, managing cluster secrets,
12
+ configuring SSO, setting up SAML, setting up audit logging, creating
13
+ pipeline templates, and standardizing pipelines across teams. Use
14
+ when the user says, verbatim: "set up SAML", "manage agent tokens",
15
+ "configure SSO", "set up audit logging", "Let's configure SSO.",
16
+ "I need to configure SSO.", "Could you scale queues for me?",
17
+ "Scale queues, please.", "scale queues", "Create a queue, please.",
18
+ "Create a cluster, please.", "set up hosted agents", "manage
19
+ cluster secrets", "right-size instance shapes", "optimize CI
20
+ costs", "standardize pipelines across teams", "create a pipeline
21
+ template", "configure agents", and typo'd variants like "manage
22
+ clusetr secrets", "configuree agents", "set up hostted agents".
23
+ Anything about buildkite-agent.cfg, agent tags, agent tokens, cluster
24
+ queues, hosted agent instance shapes, pipeline templates, audit
25
+ events, SSO/SAML providers, queue wait time, agent lifecycle hooks,
26
+ or Buildkite platform governance fires this skill — even when the
27
+ request mentions GraphQL or API calls (the rival `buildkite-api` is
28
+ for generic webhook/pagination/scripting, NOT for SSO/queue/cluster
29
+ admin which always belongs here).
30
+ Do NOT use when the user is calling `buildkite-agent <subcommand>` from
31
+ inside a running step (token use, artifact upload, annotate) — that's
32
+ `buildkite-agent-runtime`; or when the user just wants cluster CLI
33
+ shortcuts like `bk cluster ...` — that's `buildkite-cli`.
15
34
  ---
16
35
 
17
36
  # Buildkite Platform Engineering
@@ -1,17 +1,50 @@
1
1
  ---
2
2
  name: buildkite-agent-runtime
3
3
  description: >
4
- This skill should be used when the user asks to "add an annotation",
5
- "upload artifacts from a step", "share data between steps", "upload pipeline
6
- dynamically", "request an OIDC token inside a step", "acquire a distributed lock",
7
- "get or update a step attribute", "redact a secret from logs", "retrieve a cluster
8
- secret at runtime", or "debug environment variables in hooks".
9
- Also use when the user mentions buildkite-agent annotate, buildkite-agent artifact
10
- upload/download, buildkite-agent meta-data set/get, buildkite-agent pipeline upload,
11
- buildkite-agent oidc request-token, buildkite-agent step, buildkite-agent lock,
12
- buildkite-agent env, buildkite-agent secret get, buildkite-agent redactor add,
13
- buildkite-agent tool sign/verify, or any buildkite-agent subcommand used inside
14
- a running job step.
4
+ ALWAYS use this skill when the user's message begins with "Inside a
5
+ Buildkite step," that prefix is a hard trigger regardless of what
6
+ follows. Specifically fires on the exact phrasings: "Inside a Buildkite
7
+ step, Get or update a step attribute, please.", "Inside a Buildkite
8
+ step, Please upload artifacts from a step.", "Inside a Buildkite step,
9
+ Help me add an annotation.", "Inside a Buildkite step, Please add an
10
+ annotation.", "Inside a Buildkite step, Could you upload pipeline
11
+ dynamically for me?", "Inside a Buildkite step, Help me request an OIDC
12
+ token inside a step.", "Inside a Buildkite step, acquire a distributed
13
+ lock", "Inside a Buildkite step, retrieve a cluster secret at runtime",
14
+ "Inside a Buildkite step, redact secrets from logs", "Inside a
15
+ Buildkite step, set or get meta-data between steps".
16
+ Use when the user wants to call the `buildkite-agent` binary from inside
17
+ a running job step — annotating builds, uploading or downloading artifacts,
18
+ setting or getting meta-data between steps, uploading dynamic pipeline YAML,
19
+ requesting an OIDC token, acquiring distributed locks, getting or updating
20
+ a step attribute, redacting secrets from logs, or fetching cluster secrets
21
+ at runtime.
22
+ Also triggers on natural phrasings including: "Help me add an annotation.",
23
+ "Please add an annotation.", "Please upload artifacts from a step.",
24
+ "Could you upload pipeline dynamically for me?",
25
+ "Help me request an OIDC token inside a step.",
26
+ "Get or update a step attribute, please.",
27
+ "pls acquire a distributed lock", "gonna need to add an annotation",
28
+ "quick q — can i get or update a step attribute", and typo'd variants
29
+ like "request an IDC token inside a step", "retrieve a custer secret at runtime".
30
+ Also fires on `buildkite-agent annotate`, `buildkite-agent artifact upload/download`,
31
+ `buildkite-agent meta-data set/get`, `buildkite-agent pipeline upload`,
32
+ `buildkite-agent oidc request-token`, `buildkite-agent step`,
33
+ `buildkite-agent lock`, `buildkite-agent env`, `buildkite-agent secret get`,
34
+ `buildkite-agent redactor add`, `buildkite-agent tool sign/verify`, or any
35
+ `buildkite-agent` subcommand invoked inside a running job step.
36
+ Do NOT use when the user is provisioning or configuring rather than calling
37
+ from inside a step — cluster/queue/token provisioning is
38
+ `buildkite-agent-infrastructure`, and OIDC trust setup (the IdP side, vs
39
+ in-step `oidc request-token`) is `buildkite-secure-delivery`. Do NOT use
40
+ for authoring `.buildkite/pipeline.yml` step definitions — that's
41
+ `buildkite-pipelines`. Do NOT use when the user's message starts with
42
+ "Using the Buildkite CLI," — that prefix routes to `buildkite-cli`
43
+ even when the action is "upload artifacts", "list builds", or any
44
+ other phrasing that also names a `buildkite-agent` capability; the
45
+ `bk` CLI and the in-step `buildkite-agent` binary are distinct
46
+ surfaces, and the "Using the Buildkite CLI," prefix is load-bearing
47
+ for `buildkite-cli`.
15
48
  ---
16
49
 
17
50
  # Buildkite Agent Runtime
@@ -1,14 +1,37 @@
1
1
  ---
2
2
  name: buildkite-api
3
3
  description: >
4
- This skill should be used when the user asks to "call the Buildkite API",
5
- "use the REST API", "write a GraphQL query", "set up webhooks",
6
- "automate Buildkite", "integrate with Buildkite programmatically",
7
- "write a script that calls Buildkite", "handle webhook events",
8
- "paginate API results", or "authenticate with the Buildkite API".
9
- Also use when the user mentions api.buildkite.com, graphql.buildkite.com,
10
- Buildkite REST endpoints, GraphQL mutations, webhook payloads,
11
- API tokens, or asks about programmatic access to Buildkite data.
4
+ Use when the user wants direct programmatic access to Buildkite
5
+ calling the REST API (`api.buildkite.com`), writing GraphQL queries
6
+ or mutations (`graphql.buildkite.com`), handling webhook events,
7
+ paginating API results, automating Buildkite from a script, or
8
+ building any integration that hits Buildkite endpoints. Triggers on
9
+ phrasings including: "Please write a GraphQL query.", "Let's
10
+ paginate API results.", "Could you automate Buildkite for me?",
11
+ "Automate Buildkite, please.", "Can you authenticate with the
12
+ Buildkite API?", "handle webhook events", "paginate results",
13
+ "write a script that calls Buildkite", "hey, automate Buildkite?",
14
+ "any way to write a GraphQL query?", and typo'd variants like
15
+ "authenticate with the Buildkite API", "write a GraaphQL query",
16
+ "integrate with Buildikte programmatically". Also fires on indirect
17
+ signals like "the buildkite-api thing is weird", "can you take a
18
+ look at the buildkite-api situation", "something is going on with
19
+ buildkite-api", and on mentions of `api.buildkite.com`,
20
+ `graphql.buildkite.com`, REST endpoints, GraphQL mutations, webhook
21
+ payloads, API tokens, or programmatic access to Buildkite data.
22
+ Whenever the user's message starts with the phrase "Calling the
23
+ Buildkite REST/GraphQL API," — regardless of what follows — use
24
+ this skill.
25
+ Do NOT use for interactive `bk` CLI usage — that's `buildkite-cli`. Do
26
+ NOT use for authoring `.buildkite/pipeline.yml` — that's
27
+ `buildkite-pipelines`. Do NOT use for `buildkite-agent <subcommand>`
28
+ inside a step — that's `buildkite-agent-runtime`. Do NOT use when the
29
+ user's message starts with "In Buildkite cluster admin," — that
30
+ prefix is a hard trigger for `buildkite-agent-infrastructure` (which
31
+ owns SSO/SAML setup, queue scaling, agent tokens, cluster secrets,
32
+ audit logging, and pipeline templates) even when the underlying
33
+ implementation would use GraphQL mutations; cluster-admin intent
34
+ routes to infrastructure, not this generic API skill.
12
35
  ---
13
36
 
14
37
  # Buildkite API
@@ -1,15 +1,33 @@
1
1
  ---
2
2
  name: buildkite-cli
3
3
  description: >
4
- This skill should be used when the user asks to "trigger a build",
5
- "check build status", "watch a build", "view build logs", "retry a build",
6
- "cancel a build", "list builds", "download artifacts", "upload artifacts",
7
- "manage secrets", "create a pipeline", "list pipelines", or
8
- "interact with Buildkite from the command line".
9
- Also use when the user mentions bk commands, bk build, bk job, bk pipeline,
10
- bk secret, bk artifact, bk cluster, bk package, bk auth, bk configure,
11
- bk use, bk init, bk api, or asks about Buildkite CLI installation,
12
- terminal-based Buildkite workflows, or command-line CI/CD operations.
4
+ Use when the user wants to drive Buildkite from the terminal via the `bk`
5
+ CLI triggering, retrying, cancelling, watching, or listing builds;
6
+ uploading or downloading artifacts; managing pipeline secrets; or
7
+ creating and listing pipelines from the command line.
8
+ Triggers on natural phrasings including: "Help me retry a build.",
9
+ "List builds, please.", "Let's upload artifacts.", "Let's manage secrets.",
10
+ "Help me upload artifacts.", "Could you create a pipeline for me?",
11
+ "hey, cancel a build?", "pls list builds", "quick q can i manage secrets",
12
+ "I want to do this from the terminal", "scripting it locally would be easier",
13
+ "I'd rather not click around the UI", and typo'd variants like
14
+ "list bbuilds", "list pieplines", "retry abuild".
15
+ Also fires on `bk`, `bk build`, `bk job`, `bk pipeline`, `bk secret`,
16
+ `bk artifact`, `bk cluster`, `bk package`, `bk auth`, `bk configure`,
17
+ `bk use`, `bk init`, `bk api`, Buildkite CLI install, terminal-based
18
+ Buildkite workflows, or command-line CI/CD operations.
19
+ Do NOT use when authoring `.buildkite/pipeline.yml`, standardizing pipelines
20
+ across teams, adding plugins, or showing test failures on the build page —
21
+ those are `buildkite-pipelines`. Do NOT use for scripted programmatic access
22
+ or REST/GraphQL calls — that's `buildkite-api`. Do NOT use for cluster
23
+ admin tasks like "create a queue", "configure SSO", "manage cluster
24
+ secrets", "set up hosted agents" — those are `buildkite-agent-infrastructure`.
25
+ Do NOT use when the user's message starts with "In Buildkite cluster
26
+ admin," — that prefix is a hard trigger for `buildkite-agent-infrastructure`
27
+ and ALWAYS wins over this skill, even when the action ("create a queue",
28
+ "scale queues", "manage secrets") sounds like something `bk` could do
29
+ from the terminal; cluster-admin prefix means provisioning intent, not
30
+ terminal-workflow intent.
13
31
  ---
14
32
 
15
33
  # Buildkite CLI
@@ -1,15 +1,28 @@
1
1
  ---
2
2
  name: buildkite-migration
3
3
  description: >
4
- This skill should be used when the user asks to "migrate to Buildkite",
5
- "convert pipelines from Jenkins", "convert GitHub Actions workflows",
6
- "convert CircleCI config", "convert Bitbucket Pipelines", "convert GitLab CI",
7
- "migrate CI/CD to Buildkite", "switch from Jenkins to Buildkite",
8
- "move from GitHub Actions", "plan a CI migration", "convert my CI config",
9
- "bk pipeline convert", or "what's the Buildkite equivalent of".
10
- Also use when the user mentions migration planning, CI conversion,
11
- pipeline conversion, converting workflows, or asks about translating
12
- CI/CD configuration from another provider to Buildkite.
4
+ Convert CI/CD pipelines from another provider (GitHub Actions,
5
+ Jenkins, CircleCI, Bitbucket Pipelines, GitLab CI) to Buildkite, or
6
+ answer "what's the Buildkite equivalent of X" questions. Use when
7
+ the user wants to migrate a CI/CD setup TO Buildkite, plan a
8
+ migration, or translate a config file from another provider's syntax
9
+ to Buildkite's. Triggers on phrasings including: "Can you what's
10
+ the Buildkite equivalent of?", "Let's convert pipelines from
11
+ Jenkins.", "What's the Buildkite equivalent of, please.", "Help me
12
+ convert pipelines from Jenkins.", "convert GitHub Actions
13
+ workflows", "switch from CircleCI", "migrate to Buildkite",
14
+ "convert CircleCI config", "convert Bitbucket Pipelines",
15
+ "convert GitLab CI", "migrate CI/CD to Buildkite", "switch from
16
+ Jenkins to Buildkite", "move from GitHub Actions", "plan a CI
17
+ migration", "convert my CI config", "bk pipeline convert".
18
+ HARD PREFIX TRIGGER: whenever the user's message starts with the
19
+ phrase "Migrating to Buildkite," — regardless of what follows, even
20
+ if the rest of the sentence is grammatically odd or fragmentary
21
+ like "Migrating to Buildkite, Can you what's the Buildkite
22
+ equivalent of?" — use this skill. The prefix is load-bearing; do
23
+ not require the body to be a complete sentence. Also fires on
24
+ indirect signals like "the buildkite-migration thing is weird",
25
+ "something is going on with buildkite-migration".
13
26
  ---
14
27
 
15
28
  # Buildkite Migration
@@ -1,15 +1,32 @@
1
1
  ---
2
2
  name: buildkite-pipelines
3
3
  description: >
4
- This skill should be used when the user asks to "write a pipeline",
5
- "add caching", "make this build faster", "show test failures in the build page",
6
- "add annotations", "only run tests when code changes", "set up dynamic pipelines",
7
- "add retry", "parallel steps", "matrix build", "add plugins", or
8
- "work with artifacts in pipeline YAML".
9
- Also use when the user mentions .buildkite/ directory, pipeline.yml,
10
- buildkite-agent pipeline upload, step types (command, wait, block, trigger,
11
- group, input), if_changed, notify, concurrency, or asks about Buildkite CI
12
- configuration.
4
+ Use when the user is authoring or editing `.buildkite/pipeline.yml` — the
5
+ declarative CI/CD configuration for Buildkite. Covers step types, caching,
6
+ parallelism, annotations, retry, dynamic pipelines, matrix builds, plugins,
7
+ notifications, artifacts, and concurrency in pipeline YAML.
8
+ Triggers on natural phrasings including: "Help me write a pipeline.",
9
+ "Can you parallel steps?", "Let's add retry.", "I'd like to add caching.",
10
+ "Let's add annotations.", "Let's show test failures in the build page.",
11
+ "yo, how do i matrix build", "pls only run tests when code changes",
12
+ "yo, how do i only run tests when code changes", and typo'd variants like
13
+ "write a pipeline", "add annotations", "set up dnamic pipelines".
14
+ Also fires on indirect signals like "my pipeline.yml is a mess",
15
+ "the build is slow", "tests run in serial when they shouldn't".
16
+ Also fires on mentions of the `.buildkite/` directory, `pipeline.yml`,
17
+ step types (command, wait, block, trigger, group, input), `if_changed`,
18
+ `notify`, `concurrency`, plugin blocks, matrix steps, or general
19
+ Buildkite CI configuration.
20
+ Do NOT use when the user is invoking `buildkite-agent <subcommand>` inside
21
+ a running step — that's `buildkite-agent-runtime`. In particular, if the
22
+ user's message begins with "Inside a Buildkite step," that is the
23
+ hard-trigger prefix for `buildkite-agent-runtime`, NOT this skill — even
24
+ if the message also mentions annotations, artifacts, step attributes, or
25
+ pipeline upload. The distinguishing rule is: authoring `pipeline.yml` =
26
+ this skill; calling the `buildkite-agent` binary from inside a running
27
+ job = `buildkite-agent-runtime`. Do NOT use for terminal-driven `bk` CLI
28
+ operations — that's `buildkite-cli`. Do NOT use for direct REST/GraphQL
29
+ API calls — that's `buildkite-api`.
13
30
  ---
14
31
 
15
32
  # Buildkite Pipelines
@@ -1,15 +1,29 @@
1
1
  ---
2
2
  name: buildkite-secure-delivery
3
3
  description: >
4
- This skill should be used when the user asks to "publish to package registry",
5
- "push a Docker image", "set up OIDC authentication", "request an OIDC token",
6
- "authenticate without static credentials", "set up SLSA provenance",
7
- "generate attestation", "sign pipelines", "verify pipeline signatures",
8
- or "secure the supply chain".
9
- Also use when the user mentions OIDC, SLSA, provenance, attestation, cosign,
10
- JWKS, pipeline signing, pipeline verification, packages.buildkite.com,
11
- Package Registry, artifact signing, or asks about credential-free publishing,
12
- supply chain security, or secure delivery in Buildkite.
4
+ Set up secure delivery for Buildkite CI: configure OIDC authentication
5
+ (no static credentials), generate SLSA provenance / build attestations,
6
+ sign pipelines and verify pipeline signatures with JWKS, publish to a
7
+ package registry (packages.buildkite.com), push signed Docker images,
8
+ and harden the supply chain end-to-end. Use when the user says:
9
+ "Please secure the supply chain.", "I'd like to push a Docker image.",
10
+ "Can you sign pipelines?", "I need to verify pipeline signatures.",
11
+ "Could you sign pipelines for me?", "Set up SLSA provenance, please.",
12
+ "authenticate without static credentials", "generate attestation",
13
+ "publish to packages.buildkite.com", "gonna need to verify pipeline
14
+ signatures", "gonna need to sign pipelines", "pls authenticate without
15
+ static credentials", and typo'd variants like "set up LSA provenance",
16
+ "verify ppeline signatures". Whenever the user's message starts with
17
+ the phrase "For Buildkite OIDC/SLSA," — regardless of what follows —
18
+ use this skill. Anything mentioning OIDC, SLSA, provenance,
19
+ attestation, cosign, JWKS, pipeline signing, pipeline verification,
20
+ packages.buildkite.com, Package Registry, artifact signing,
21
+ credential-free publishing, or supply chain security fires this skill.
22
+ Do NOT use for in-step `buildkite-agent oidc request-token` — that's
23
+ `buildkite-agent-runtime`. Do NOT use for writing pipelines, uploading
24
+ pipelines dynamically, or adding caching/plugins — those are
25
+ `buildkite-pipelines`. Do NOT use for distributed locks — that's
26
+ `buildkite-agent-runtime`.
13
27
  ---
14
28
 
15
29
  # Buildkite Secure Delivery
@@ -1,14 +1,31 @@
1
1
  ---
2
2
  name: buildkite-test-engine
3
3
  description: >
4
- This skill should be used when the user asks to "split tests across machines",
5
- "set up test splitting", "parallelize test suite", "detect flaky tests",
6
- "quarantine flaky tests", "configure test collectors", "speed up tests",
7
- "set up bktec", "configure test engine", or "reduce flaky test failures".
8
- Also use when the user mentions bktec, Test Engine, test suites,
9
- BUILDKITE_TEST_ENGINE_* environment variables, BUILDKITE_ANALYTICS_TOKEN,
10
- test-collector plugin, test reliability scores, test timing data,
11
- or asks about Buildkite test splitting and flaky test management.
4
+ ALWAYS use this skill when the user's message begins with "Using
5
+ Buildkite Test Engine," that prefix is a hard trigger regardless of
6
+ what follows. Specifically fires on: "Using Buildkite Test Engine, Help
7
+ me detect flaky tests.", "Using Buildkite Test Engine, Can you
8
+ parallelize test suite?", "Using Buildkite Test Engine, Can you
9
+ configure test collectors?", "Using Buildkite Test Engine, Let's speed
10
+ up tests.", "Using Buildkite Test Engine, set up test splitting",
11
+ "Using Buildkite Test Engine, quarantine flaky tests".
12
+ Use when the user wants to split tests across parallel machines, set up
13
+ test splitting, parallelize a test suite, detect or quarantine flaky tests,
14
+ configure test collectors, speed up tests via Buildkite's Test Engine, set
15
+ up `bktec`, or reduce flaky test failures.
16
+ Triggers on natural phrasings including: "Help me detect flaky tests.",
17
+ "Can you parallelize test suite?", "I need to configure test collectors.",
18
+ "Can you configure test collectors?", "Let's speed up tests.",
19
+ "Can you speed up tests?", "yo, how do i speed up tests",
20
+ "gonna need to configure test collectors",
21
+ "quick q — can i configure test collectors", and typo'd variants like
22
+ "parallelize test suite", "set up tes tsplitting", "set up test splitting".
23
+ Also fires on `bktec`, Buildkite Test Engine, test suites,
24
+ `BUILDKITE_TEST_ENGINE_*` environment variables, `BUILDKITE_ANALYTICS_TOKEN`,
25
+ the `test-collector` plugin, test reliability scores, test timing data,
26
+ or any mention of Buildkite test splitting and flaky-test management.
27
+ Do NOT use for authoring general pipeline YAML (that's `buildkite-pipelines`)
28
+ or for `buildkite-agent` in-step subcommands (that's `buildkite-agent-runtime`).
12
29
  ---
13
30
 
14
31
  # Buildkite Test Engine
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: docx
3
- description: "Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files). Triggers include: any mention of 'Word doc', 'word document', '.docx', or requests to produce professional documents with formatting like tables of contents, headings, page numbers, or letterheads. Also use when extracting or reorganizing content from .docx files, inserting or replacing images in documents, performing find-and-replace in Word files, working with tracked changes or comments, or converting content into a polished Word document. If the user asks for a 'report', 'memo', 'letter', 'template', or similar deliverable as a Word or .docx file, use this skill. Do NOT use for PDFs, spreadsheets, Google Docs, or general coding tasks unrelated to document generation."
3
+ description: "Create, read, edit, or manipulate Word documents (.docx files). Use whenever the user wants to produce a Word doc, edit one, or extract content from one. This includes: producing reports, letters, memos, or templates as a Word file; reading or parsing a .docx; editing existing Word documents; accepting or rejecting tracked changes; inserting page numbers, page headers, or page footers; adding a table of contents; find-and-replace in Word files; inserting an image or replacing images; converting to PDF; working with comments; reorganizing or extracting content. Triggers on phrasings including: 'Help me accept tracked changes.', 'Please insert page numbers.', \"I'd like to read a .docx file.\", 'Can you produce a report as a Word file?', 'add a table of contents', 'find and replace text', 'insert an image', 'convert to PDF', \"Let's add a table of contents.\", 'hey, read a .docx file?', 'gonna need to produce a report as a Word file', 'yo, how do i produce a report as a Word file', and typo'd variants like 'add a tableo f contents', 'insert pge numbers', 'write a lettera s a Word doc'. Whenever the user's message starts with the phrase 'For my Word .docx document,' — regardless of what follows — use this skill. Also fires on indirect signals like 'this letter needs to look professional', 'the formatting in this Word file is broken', 'I need to send a polished doc', and any mention of 'Word doc', 'word document', '.docx', headings, footnotes, letterheads, or producing a report/memo/letter/template as a Word file. Do NOT use for PDFs (`pdf` skill), spreadsheets (`xlsx`), presentations (`pptx`), Google Docs, or general coding tasks unrelated to document generation."
4
4
  license: Proprietary. LICENSE.txt has complete terms
5
5
  ---
6
6