@the-vibe-company/armada 0.2.8 → 0.2.10

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 (3) hide show
  1. package/README.md +6 -3
  2. package/dist/armada.js +324 -45
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -35,6 +35,7 @@ Workers then need no key either: each one's launch message carries a one-time to
35
35
  `armada status` reads the `armada.toml` of the current repository (or the nearest parent directory) and prints:
36
36
 
37
37
  - **In flight**: tickets an agent holds, with their phase, runtime, last report and pull request. A worker with no report (an `armada report` event recorded through Armada, an `Agent status:` comment or its claim) for longer than `policy.silence_minutes` is flagged `silent`, unless it is waiting on a human (`awaiting-approval`, `blocked`, `ready-to-merge`). A ticket that never had a report falls back to its last sign of life (ticket edit, comment or pull request update).
38
+ - **Launched, not started**: signed in to Armada, the workers launched with a launch token that have not claimed their ticket after `policy.not_started_minutes`, each saying whether the token was never used (the worker never reached its `armada login` line) or used without a claim.
38
39
  - **Ready to start**: tickets without sub-issues that are not started, not held by an agent, have no open pull request, and whose blocked-by tickets are all closed, ranked by what they unlock. Tickets without the ready label, or still in triage, are listed separately.
39
40
  - **Pull requests waiting**: open pull requests with their CI state and mergeability.
40
41
 
@@ -84,7 +85,8 @@ armada brief ABC-12 --profile codex --reason "a back-end bug behind a web label"
84
85
  - The prompt names the ticket and its Linear branch, starts by installing the coordinator's Armada version (`npm install -g`, with an `npm exec` fallback), signing in with `armada login --launch-token <token>` and running `armada claim` with the handle `$CONDUCTOR_WORKSPACE_ID/$CONDUCTOR_SESSION_ID`, and carries the blockers with their hand-back notes, the comments already on the ticket and the workers in flight.
85
86
  - **Plan rule.** A "Plan" section says in one line whether the worker waits for approval: "post your plan with `armada report implementing --plan-file -` and go on" when plans are pre-approved, "post your plan with `armada report awaiting-approval --plan-file -` and wait for approval" otherwise. `[policy] plans` decides (`approve` by default, or `pre-approved`); a ticket labelled `plan-approved` (`policy.pre_approved_label`) is pre-approved, and one labelled `needs-plan-approval` (`policy.approval_label`) waits for approval, which wins when a ticket has both. The settings show the rule and where it comes from (`Plans:`), and `--json` carries it as `plans`.
86
87
  - **Project conventions.** `[brief] extra = "<path>"` names a file of the repository (relative to `armada.toml`) that every prompt ends with, under "Project conventions": the checks to run, the generated files to refresh, how to bring main in. A missing file is a brief warning, and `armada doctor` checks it.
87
- - **Workers need no key.** When the coordinator is signed in to an Armada that keeps the organization's keys, the brief asks it for a launch token: one ticket, used once, valid one hour. The worker exchanges it for a session limited to its ticket's `claim`, `report`, `ask` and `release`, and Armada gives each of those commands its keys. The `Launch:` line says whether the prompt carries one, and when there is none, why (not signed in, or an Armada without accounts or keys). Only `--prompt` prints the token; the full brief and `--json` show it as `armada_launch_••••`, so it stays out of the coordinator's transcript. Make the brief right before the launch; the token is the only secret a prompt ever holds, useless once used. Merging or releasing the ticket ends the worker's session, and Organization > Workers on the dashboard revokes one.
88
+ - **Workers need no key.** When the coordinator is signed in to an Armada that keeps the organization's keys, the brief asks it for a launch token: one ticket, used once, valid one hour. The worker exchanges it for a session limited to its ticket's `claim`, `report`, `ask` and `release`, and Armada gives each of those commands its keys. The `Launch:` line says whether the prompt carries one, and when there is none, why (not signed in, or an Armada without accounts or keys). Only `--prompt` prints the token; the full brief and `--json` show it as `armada_launch_••••`, so it stays out of the coordinator's transcript. Make the brief right before the launch; the token is the only secret a prompt ever holds, useless once used. The launch message is the `--prompt` output only: a worker given the masked token is told so by `armada login`.
89
+ - **A version npm serves.** The brief pins the coordinator's Armada version, after one request to npm (3 s at most, beside the Linear reads). When npm does not serve it yet (a release still publishing, a checkout ahead of npm), the brief pins the newest published version and warns; offline, it only warns. Merging or releasing the ticket ends the worker's session, and Organization > Workers on the dashboard revokes one.
88
90
  - The settings give the profile's agent, model and effort from `[conductor]` in `armada.toml`, and the environment variables: `ARMADA_TICKET=<ticket>`, and, only without a launch token, `LINEAR_API_KEY` (required). Each shows whether this shell has it. No value is ever printed.
89
91
  - A profile with `runtime = "claude-code"` routes the launch to the `armada-runtime-claude-code` skill: the `Runtime:` line names the skill, the claim runs `--runtime claude-code` with the subagent's name as its handle (the ticket id in lowercase), and the prompt first makes the worker check it runs in its own worktree. The Agent tool applies no effort; the brief says so.
90
92
  - The profile follows the ticket's Linear labels: the first `[[conductor.routing]]` rule with a label the ticket carries (case, spaces and punctuation ignored), else `conductor.default_profile`, else the only profile. The settings say which rule chose it.
@@ -129,7 +131,7 @@ armada answer --note ABC-12 "main moved: bring it in before you ship" # an unso
129
131
 
130
132
  - `ask` reports the `blocked` phase with `Agent status: blocked — question: <first line>` (the rest and the numbered options below it) and adds a `question` item to the coordinator's inbox on Armada. The worker then stops and waits for the answer in its session, and reports the phase it resumes. It finds the ticket like `report`.
131
133
  - `report awaiting-approval` adds a `plan` item with the full message (and the `--plan` block) and worker handle to the coordinator's inbox. Same-phase heartbeats neither duplicate nor reopen it. Answering it, recording a note, leaving the phase or releasing the ticket closes the plan and any pending approval request. For a pre-approved plan (the brief's "Plan" line says which), post the plan with `report implementing --plan-file -` instead: no approval item is needed.
132
- - `inbox` lists the coordinator's open items (questions, plans, requests, hand-backs) and silent workers, oldest first. A worker is silent when it holds a ticket, its newest event is older than `policy.silence_minutes`, and its phase does not wait on someone else. It reads Armada only (a sign-in, no Linear key) and records that the coordinator is at work, for the dashboard. `--wait` asks Armada every 15 s until `--timeout`; Armada answers "not modified" (HTTP 304, no body) while the inbox holds the same entries, so a waiting coordinator costs one short request per ask and holds nothing open. It marks the items that were not there before with `*`; loop on it.
134
+ - `inbox` lists the coordinator's open items (questions, plans, requests, hand-backs), silent workers and workers that never started, oldest first. A worker never started (`not-started`) was launched with a launch token and has not claimed its ticket after `policy.not_started_minutes`; the entry says whether the token was never used or used without a claim, names the worker's session when its sign-in gave one, and clears on the claim, when the launch ends (release, merge, revoke) or when a newer launch of the ticket replaces it. A launch on a ticket a session still holds is not followed (a brief made to read a running worker's prompt again launches nobody; a relaunch releases the old claim first). A launched worker counts as in flight from its launch until it shows as not started, so `armada watch` waits for its claim; past that, its entry carries it. A worker is silent when it holds a ticket, its newest event is older than `policy.silence_minutes`, and its phase does not wait on someone else. It reads Armada only (a sign-in, no Linear key) and records that the coordinator is at work, for the dashboard. `--wait` asks Armada every 15 s until `--timeout`; Armada answers "not modified" (HTTP 304, no body) while the inbox holds the same entries, so a waiting coordinator costs one short request per ask and holds nothing open. It marks the items that were not there before with `*`; loop on it. A hand-back handed back again on a new head (or a plan rewritten in place) counts as new.
133
135
  - `watch` is how a coordinator keeps listening, run in the background while a worker is in flight. It asks Armada like `inbox --wait` (every 15 s, every 60 s when no worker is in flight, 304 while nothing changed) with no time limit of its own, and exits as soon as something needs the coordinator that it has not been shown yet by `inbox` or `watch` on this machine: it prints the inbox, new items marked `*`. It exits with "nothing to watch" when no worker is in flight and nothing is open. Armada unreachable or answering 5xx only prints a warning and it keeps going, waiting longer each time; a refusal (signed out) ends it. One watch per project and machine: a second one says the first is running. Its state (a lock, the entries shown, the tickets in flight at the last read, the checkout it ran in) lives in `~/.config/armada/watch/`, no secret.
134
136
  - The last line of `inbox`, `watch`, `merge` and `brief` (not `brief --prompt`) says whether to start watching again, for example `2 workers in flight (ABC-1, ABC-2) — keep watching: armada watch`; with `--json`, the same is the `watch` field.
135
137
  - `armada hook stop` is the Claude Code Stop hook `armada init` adds to `.claude/settings.json` (it asks; `--no-stop-hook` leaves it out; `armada doctor` shows it). It reads only armada.toml and the watch state, so it answers at once without the network. It refuses to end the turn, and tells the agent to start `armada watch` in the background, only in the checkout where `armada watch` ran (never a worker's), while the last read had workers in flight and no watch runs. A watch that ended on a refusal lets the turn end, and `ARMADA_STOP_HOOK=off` turns the hook off.
@@ -163,7 +165,7 @@ armada merge 35 --no-ticket # a pull request no ticket owns: armada init's, a re
163
165
 
164
166
  `packages/dashboard` is a Next.js app whose main page is the Fleet of the projects registered in its database. With accounts, each person sees the projects of their organization; under the shared password, every project.
165
167
 
166
- - **Waiting for you** comes first, across projects. It lists questions, blocked workers, plans to approve, hand-backs and silent workers, the most urgent first.
168
+ - **Waiting for you** comes first, across projects. It lists questions, blocked workers, plans to approve, hand-backs, workers launched that never started and silent workers, the most urgent first.
167
169
  - **At work** has one row per ticket in flight. A row shows the project, the runtime and session, the six-step phase pipeline, time in phase, the last report, the pull request with its CI, and the flags (red CI, conflict, double claim).
168
170
  - A filter shows one project. Each project shows whether its coordinator is active, from its last inbox read.
169
171
  - **Answer** a question from its line in Waiting for you (an option of the question fills the answer in). **Ready to launch** lists the frontier with a Launch button and a profile picker, the routed profile preselected. Neither reaches a worker: each becomes a request in that project's coordinator inbox, signed with the signed-in person's name and address (with accounts) or with the name the viewer gives (under the shared password; remembered in a cookie, default `ARMADA_DASHBOARD_AUTHOR`), and shows as pending until the coordinator carries it out. The dashboard holds no runtime credential.
@@ -389,6 +391,7 @@ local_commands = ["npm ci", "npm test"] # run by `armada merge` on a test merge
389
391
  [policy]
390
392
  silence_minutes = 15 # a worker with no report for longer is flagged silent (default 15)
391
393
  coordinator_minutes = 10 # an inbox item open longer shows "waiting for the coordinator" (default 10)
394
+ not_started_minutes = 10 # a launched worker that has not claimed after this long shows as not started (default 10; a CLI older than this setting refuses it)
392
395
  plans = "approve" # or "pre-approved": workers post their plan and go on (default "approve")
393
396
  pre_approved_label = "plan-approved" # a ticket with this label is pre-approved (default)
394
397
  approval_label = "needs-plan-approval" # a ticket with this label waits for approval; wins over the other (default)
package/dist/armada.js CHANGED
@@ -319,6 +319,12 @@ var CHANGED_COMMENTS_QUERY = `
319
319
  }`;
320
320
 
321
321
  // ../core/src/armada-api.ts
322
+ var MASKED_LAUNCH_TOKEN = "armada_launch_••••";
323
+ var isMaskedLaunchToken = (token) => token.includes("•");
324
+ var MASKED_LAUNCH_TOKEN_REFUSAL = {
325
+ error: "this is the masked token from `armada brief`'s human view, not a launch token",
326
+ next: "ask the coordinator for the `armada brief <ticket> --prompt` text: only it carries the token"
327
+ };
322
328
  var displayCode = (code) => code.length === 8 ? `${code.slice(0, 4)}-${code.slice(4)}` : code;
323
329
  var CLI_PACKAGE = "@the-vibe-company/armada";
324
330
  var CLI_VERSION_HEADER = "x-armada-cli-version";
@@ -337,6 +343,9 @@ function compareVersions(a, b) {
337
343
  var versionToInstall = (minimum, latest) => latest && compareVersions(latest, minimum) >= 0 ? latest : minimum;
338
344
  var installCommand = (version) => `npm install -g ${CLI_PACKAGE}@${version}`;
339
345
  var upgradeLine = (version, install) => `Armada ${version} is older than this server expects: ${installCommand(install)}`;
346
+ var releaseNotesUrl = (version) => `https://github.com/The-Vibe-Company/armada/releases/tag/v${version}`;
347
+ var newerRelease = (running, latest) => latest && running !== "0.0.0" && compareVersions(latest, running) > 0 ? latest : null;
348
+ var releaseLine = (running, latest) => `Armada ${latest} is out (you run ${running}): ${installCommand(latest)} — then armada init to refresh this project's skills. Changes: ${releaseNotesUrl(latest)}`;
340
349
 
341
350
  class ArmadaApiError extends Error {
342
351
  next;
@@ -397,8 +406,10 @@ function armadaApi(opts) {
397
406
  });
398
407
  const minimum = res.headers.get(CLI_MINIMUM_HEADER);
399
408
  const latest = res.headers.get(CLI_LATEST_HEADER) || null;
400
- if (minimum)
409
+ if (minimum) {
401
410
  serverCli = { minimum, latest };
411
+ opts.onServerCli?.(serverCli);
412
+ }
402
413
  if (opts.version && minimum && compareVersions(opts.version, minimum) < 0) {
403
414
  await res.body?.cancel().catch(() => {});
404
415
  const install = versionToInstall(minimum, latest);
@@ -562,8 +573,10 @@ function armadaApi(opts) {
562
573
  throw new ArmadaApiError(`Armada (${host}) answered the launch token in a shape this CLI does not know`);
563
574
  return body;
564
575
  },
565
- async exchangeLaunchToken(token) {
566
- const { status, body } = await call("POST", "launch-tokens/exchange", { body: { token } });
576
+ async exchangeLaunchToken(token, handle = null) {
577
+ const { status, body } = await call("POST", "launch-tokens/exchange", {
578
+ body: handle ? { token, handle } : { token }
579
+ });
567
580
  if (status !== 200)
568
581
  throw refusal(status, body, null);
569
582
  const w = body.worker;
@@ -1900,6 +1913,7 @@ var CONFIG_DEFAULTS = {
1900
1913
  runtimes: ["Claude Code", "Codex", "Conductor"],
1901
1914
  silentAfterMinutes: 15,
1902
1915
  coordinatorMinutes: 10,
1916
+ notStartedMinutes: 10,
1903
1917
  plans: "approve",
1904
1918
  preApprovedLabel: "plan-approved",
1905
1919
  approvalLabel: "needs-plan-approval"
@@ -2014,6 +2028,7 @@ function parseConfig(text, source = CONFIG_FILE) {
2014
2028
  "silence_minutes",
2015
2029
  "silent_after_minutes",
2016
2030
  "coordinator_minutes",
2031
+ "not_started_minutes",
2017
2032
  "plans",
2018
2033
  "pre_approved_label",
2019
2034
  "approval_label"
@@ -2111,6 +2126,14 @@ function parseConfig(text, source = CONFIG_FILE) {
2111
2126
  else
2112
2127
  problems.push(`"policy.coordinator_minutes" must be a positive number`);
2113
2128
  }
2129
+ let notStartedMinutes = CONFIG_DEFAULTS.notStartedMinutes;
2130
+ if (policyT.not_started_minutes !== undefined) {
2131
+ const v = policyT.not_started_minutes;
2132
+ if (typeof v === "number" && Number.isFinite(v) && v > 0)
2133
+ notStartedMinutes = v;
2134
+ else
2135
+ problems.push(`"policy.not_started_minutes" must be a positive number`);
2136
+ }
2114
2137
  let plans = CONFIG_DEFAULTS.plans;
2115
2138
  if (policyT.plans !== undefined) {
2116
2139
  const v = policyT.plans;
@@ -2177,7 +2200,7 @@ function parseConfig(text, source = CONFIG_FILE) {
2177
2200
  repository: str(github, "github", "repository", { pattern: REPOSITORY, hint: "owner/name" })
2178
2201
  },
2179
2202
  gates: { requiredChecks, localCommands },
2180
- policy: { silentAfterMinutes, coordinatorMinutes, plans, preApprovedLabel, approvalLabel },
2203
+ policy: { silentAfterMinutes, coordinatorMinutes, notStartedMinutes, plans, preApprovedLabel, approvalLabel },
2181
2204
  brief: { extra },
2182
2205
  secrets: { names: secretNames },
2183
2206
  conductor: { defaultProfile, profiles, routing }
@@ -2215,6 +2238,7 @@ repository = ${q(p.repository)}
2215
2238
  [policy]
2216
2239
  silence_minutes = 15 # a worker with no report for longer than this shows as silent
2217
2240
  coordinator_minutes = 10 # an inbox item open longer than this shows "waiting for the coordinator"
2241
+ # not_started_minutes = 10 # a launched worker that has not claimed after this long shows as not started
2218
2242
  # plans = "approve" # or "pre-approved": workers post their plan and go on without waiting
2219
2243
  # pre_approved_label = "plan-approved" # a ticket with this label skips the approval
2220
2244
  # approval_label = "needs-plan-approval" # a ticket with this label waits for it; wins over the other
@@ -2748,6 +2772,27 @@ async function releaseTicket(ctx, input) {
2748
2772
 
2749
2773
  // ../core/src/brief.ts
2750
2774
  var ARMADA_PACKAGE = "@the-vibe-company/armada";
2775
+ var NPM_REGISTRY_URL = `https://registry.npmjs.org/${ARMADA_PACKAGE.replace("/", "%2f")}`;
2776
+ var NPM_CHECK_MS = 3000;
2777
+ async function checkPublished(version, fetch2, timeoutMs = NPM_CHECK_MS) {
2778
+ try {
2779
+ const res = await fetch2(NPM_REGISTRY_URL, {
2780
+ headers: { accept: "application/vnd.npm.install-v1+json" },
2781
+ signal: AbortSignal.timeout(timeoutMs)
2782
+ });
2783
+ if (!res.ok)
2784
+ return { state: "unknown", reason: `npm answered HTTP ${res.status}` };
2785
+ const versions = Object.keys((await res.json()).versions ?? {});
2786
+ if (!versions.length)
2787
+ return { state: "unknown", reason: "npm listed no version" };
2788
+ if (versions.includes(version))
2789
+ return { state: "published" };
2790
+ const older = versions.filter((v) => !v.includes("-") && compareVersions(v, version) < 0).sort(compareVersions);
2791
+ return { state: "missing", newest: older.at(-1) ?? null };
2792
+ } catch (err) {
2793
+ return { state: "unknown", reason: networkReason(err, timeoutMs) };
2794
+ }
2795
+ }
2751
2796
  var WORKER_SKILL_PATH = ".agents/skills/armada-worker/SKILL.md";
2752
2797
  var CONDUCTOR_HANDLE = '"$CONDUCTOR_WORKSPACE_ID/$CONDUCTOR_SESSION_ID"';
2753
2798
  var subagentName = (ticket) => ticket.toLowerCase();
@@ -2871,7 +2916,8 @@ function buildBrief(input) {
2871
2916
  branch: l.claim?.branch ?? null,
2872
2917
  pr: l.pr?.url ?? null
2873
2918
  }));
2874
- const pkg = `${ARMADA_PACKAGE}@${input.version}`;
2919
+ const pinned = npmPin(input.version, input.npm ?? null, warnings);
2920
+ const pkg = `${ARMADA_PACKAGE}@${pinned}`;
2875
2921
  const branch = ticket.branchName;
2876
2922
  const runtime = choice?.profile.runtime ?? "conductor";
2877
2923
  const handle = runtime === "claude-code" ? subagentName(ticket.id) : CONDUCTOR_HANDLE;
@@ -2921,6 +2967,7 @@ function buildBrief(input) {
2921
2967
  profile: choice ? { name: choice.name, ...choice.profile } : null,
2922
2968
  routing: choice ? { source: choice.source, rule: choice.rule, routed: choice.routed, reason: choice.reason, why: choice.why } : null,
2923
2969
  repository: { name: config.github.repository, url: `https://github.com/${config.github.repository}` },
2970
+ armadaVersion: { pinned, coordinator: input.version },
2924
2971
  install: `npm install -g ${pkg}`,
2925
2972
  fallback: `npm exec --yes --package=${pkg} -- armada`,
2926
2973
  claimCommand,
@@ -2941,6 +2988,20 @@ function buildBrief(input) {
2941
2988
  warnings.push(`${ticket.id} has ${ticket.notes.length} comments; the brief carries the newest ${MAX_NOTES}`);
2942
2989
  return { ...brief, prompt: renderPrompt(brief) };
2943
2990
  }
2991
+ function npmPin(version, npm, warnings) {
2992
+ if (!npm || npm.state === "published")
2993
+ return version;
2994
+ if (npm.state === "unknown") {
2995
+ warnings.push(`could not check that armada ${version} is on npm (${npm.reason}); if it is not published yet, the worker's install fails`);
2996
+ return version;
2997
+ }
2998
+ if (!npm.newest) {
2999
+ warnings.push(`armada ${version} is not on npm, nor any older version: the worker's install and its fallback line fail until it is published`);
3000
+ return version;
3001
+ }
3002
+ warnings.push(`armada ${version} is not on npm yet: this brief pins ${npm.newest}, the newest published version. The skills of this checkout may describe commands ${npm.newest} lacks; publish ${version} (the release pull request) and brief again to launch with it`);
3003
+ return npm.newest;
3004
+ }
2944
3005
  var shellWord = (s) => /^\w[\w./:@+-]*$/.test(s) ? s : `'${s.replaceAll("'", `'\\''`)}'`;
2945
3006
  var quote = (body) => body.trim().split(`
2946
3007
  `).map((l) => l ? `> ${l}` : ">").join(`
@@ -2968,7 +3029,7 @@ function renderPrompt(b) {
2968
3029
  b.claimCommand,
2969
3030
  "```",
2970
3031
  "",
2971
- `This installs the coordinator's Armada version. If the global install is refused, use \`${b.fallback}\` wherever this brief or the skill says \`armada\`.`,
3032
+ `${b.armadaVersion.pinned === b.armadaVersion.coordinator ? "This installs the coordinator's Armada version." : `This installs Armada ${b.armadaVersion.pinned}, the newest on npm (the coordinator runs ${b.armadaVersion.coordinator}, not published yet).`} If the global install is refused, use \`${b.fallback}\` wherever this brief or the skill says \`armada\`.`,
2972
3033
  ...b.launch ? [
2973
3034
  "",
2974
3035
  `\`armada login --launch-token\` signs this workspace in to Armada as the worker of ${t.id}, with a one-time token valid until ${b.launch.expiresAt.slice(0, 16).replace("T", " ")} UTC. Run it first, once.`
@@ -3028,9 +3089,10 @@ async function loadBrief(config, opts) {
3028
3089
  throw new BriefError(err.message);
3029
3090
  throw err;
3030
3091
  }
3031
- const [ticket, program] = await Promise.all([
3092
+ const [ticket, program, npm] = await Promise.all([
3032
3093
  fetchBriefTicket(linear, opts.ticket),
3033
- fetchProgram({ ...linear, rootId: config.tracker.programRoot, labels: config.tracker.labels, now })
3094
+ fetchProgram({ ...linear, rootId: config.tracker.programRoot, labels: config.tracker.labels, now }),
3095
+ opts.npm?.(opts.version) ?? null
3034
3096
  ]);
3035
3097
  if (!ticket)
3036
3098
  throw new Refusal(`ticket ${opts.ticket} not found in Linear`, "armada status, to see the tickets of the program");
@@ -3047,6 +3109,7 @@ async function loadBrief(config, opts) {
3047
3109
  profile: opts.profile,
3048
3110
  reason: opts.reason ?? null,
3049
3111
  version: opts.version,
3112
+ npm,
3050
3113
  env: opts.env,
3051
3114
  ...opts.stored ? { stored: opts.stored } : {},
3052
3115
  launch: made,
@@ -3280,7 +3343,19 @@ function updateDotenv(text, updates) {
3280
3343
  ` : "";
3281
3344
  }
3282
3345
  // ../core/src/live.ts
3283
- var entryKey = (e) => e.id === null ? `silent:${e.ticket}` : `#${e.id}`;
3346
+ import { createHash } from "node:crypto";
3347
+ var LAUNCH_WINDOW_MS = 24 * 60 * 60000;
3348
+ var MIN2 = 60000;
3349
+ var REWRITTEN = ["hand-back", "plan"];
3350
+ var digest = (text) => createHash("sha256").update(text).digest("base64url").slice(0, 12);
3351
+ var entryKey = (e) => e.id !== null ? REWRITTEN.includes(e.kind) ? `#${e.id}@${digest(e.body)}` : `#${e.id}` : e.version ? `version:${e.version}` : `${e.kind}:${e.ticket}`;
3352
+ var hhmm = (iso) => `${iso.slice(11, 16)} UTC`;
3353
+ function notStartedBody(l, now) {
3354
+ const minutes = Math.floor((now.getTime() - Date.parse(l.launchedAt)) / MIN2);
3355
+ const why = l.tokenUsedAt ? `the worker signed in with its launch token at ${hhmm(l.tokenUsedAt)}, then stopped before \`armada claim\`` : "its launch token was never used: the worker never reached its `armada login` line (an install that failed, a prompt cut short)";
3356
+ return `launched ${minutes} min ago and never claimed; ${why}${l.handle ? ` (session ${l.handle})` : ""}. Check its session with the runtime guide's status section; launch it again with armada brief, or revoke the launch on the dashboard's Workers page`;
3357
+ }
3358
+ var notStartedLaunches = (launches, now, minutes) => launches.filter((l) => now.getTime() - Date.parse(l.launchedAt) > minutes * MIN2);
3284
3359
 
3285
3360
  // ../core/src/fleet-api.ts
3286
3361
  var WORKER_FLEET_OPS = ["claim", "report", "ask", "release"];
@@ -3288,6 +3363,7 @@ var FLEET_OPS = [
3288
3363
  ...WORKER_FLEET_OPS,
3289
3364
  "register",
3290
3365
  "events/latest",
3366
+ "launches",
3291
3367
  "inbox",
3292
3368
  "inbox/item",
3293
3369
  "inbox/ticket",
@@ -3308,6 +3384,7 @@ function fleetClient(o) {
3308
3384
  return;
3309
3385
  }),
3310
3386
  lastEventTimes: () => call("events/latest", {}),
3387
+ pendingLaunches: () => call("launches", {}),
3311
3388
  claim: (c) => call("claim", c),
3312
3389
  report: (r) => call("report", r),
3313
3390
  ask: (q) => call("ask", q),
@@ -3597,7 +3674,11 @@ async function askCoordinator(ctx, input) {
3597
3674
  var INBOX_POLL_MS = 15000;
3598
3675
  async function checkInbox(fleet, o) {
3599
3676
  const started = o.now();
3600
- const query = { coordinator: o.coordinator ?? null, silentAfterMinutes: o.silentAfterMinutes };
3677
+ const query = {
3678
+ coordinator: o.coordinator ?? null,
3679
+ silentAfterMinutes: o.silentAfterMinutes,
3680
+ ...o.notStartedMinutes !== undefined ? { notStartedMinutes: o.notStartedMinutes } : {}
3681
+ };
3601
3682
  const first = await fleet.inbox({ ...query, etag: null });
3602
3683
  if (!first)
3603
3684
  throw new Error("Armada answered the first inbox read with nothing");
@@ -3966,7 +4047,11 @@ function transientFailure(err) {
3966
4047
  return /\bunreachable\b|\bHTTP (?:5\d\d|408|429) without JSON\b/.test(err.message);
3967
4048
  }
3968
4049
  async function watchInbox(fleet, o) {
3969
- const query = { coordinator: o.coordinator, silentAfterMinutes: o.silentAfterMinutes };
4050
+ const query = {
4051
+ coordinator: o.coordinator,
4052
+ silentAfterMinutes: o.silentAfterMinutes,
4053
+ ...o.notStartedMinutes !== undefined ? { notStartedMinutes: o.notStartedMinutes } : {}
4054
+ };
3970
4055
  const pollMs = o.pollMs ?? WATCH_POLL_MS;
3971
4056
  const idlePollMs = o.idlePollMs ?? WATCH_IDLE_POLL_MS;
3972
4057
  let known = new Set(o.seen);
@@ -4005,14 +4090,36 @@ async function watchInbox(fleet, o) {
4005
4090
  for (const w of read.warnings)
4006
4091
  warnings.add(w);
4007
4092
  await o.onRead?.({ items, inFlight });
4008
- if (items.some((e) => e.new))
4009
- return report("items");
4010
- if (inFlight !== null && !inFlight.length && !items.length)
4011
- return report("nothing");
4012
4093
  }
4094
+ const release = await o.release?.() ?? null;
4095
+ if (release)
4096
+ items = [...items, { ...release, new: true }];
4097
+ if (items.some((e) => e.new))
4098
+ return report("items");
4099
+ if (read && inFlight !== null && !inFlight.length && !items.length)
4100
+ return report("nothing");
4013
4101
  await o.sleep(inFlight !== null && !inFlight.length ? idlePollMs : pollMs);
4014
4102
  }
4015
4103
  }
4104
+ function releaseEntry(running, latest, at) {
4105
+ return {
4106
+ id: null,
4107
+ kind: "version",
4108
+ ticket: null,
4109
+ author: null,
4110
+ version: latest,
4111
+ body: [
4112
+ `Armada ${latest} is out (you run ${running}). Changes: ${releaseNotesUrl(latest)}`,
4113
+ "Not urgent: finish what is in flight first, then, between rounds:",
4114
+ ` 1. ${installCommand(latest)}`,
4115
+ " 2. armada init, then merge its pull request: armada merge <n> --no-ticket",
4116
+ "Workers in flight keep the version their brief pinned: tell them nothing unless the notes say otherwise."
4117
+ ].join(`
4118
+ `),
4119
+ createdAt: at.toISOString(),
4120
+ new: false
4121
+ };
4122
+ }
4016
4123
  var workers = (n) => `${n} worker${n === 1 ? "" : "s"} in flight`;
4017
4124
  function rearm(o) {
4018
4125
  const then = o.act ? "act on the items above, then " : "";
@@ -4278,6 +4385,23 @@ async function runningWatch(paths, project, alive = processAlive) {
4278
4385
  const pid = await readWatchLock(paths, project).catch(() => null);
4279
4386
  return pid !== null && alive(pid) ? pid : null;
4280
4387
  }
4388
+ var NOTICED_KEPT = 50;
4389
+ var releasesFile = (paths) => join(paths.dir, "releases.json");
4390
+ async function readNoticedReleases(paths) {
4391
+ try {
4392
+ const raw = JSON.parse(await readFile(releasesFile(paths), "utf8"));
4393
+ return strings(raw?.noticed) ?? [];
4394
+ } catch {
4395
+ return [];
4396
+ }
4397
+ }
4398
+ async function addNoticedRelease(paths, version) {
4399
+ const noticed = (await readNoticedReleases(paths)).filter((v) => v !== version);
4400
+ noticed.push(version);
4401
+ const text = `${JSON.stringify({ noticed: noticed.slice(-NOTICED_KEPT) }, null, 2)}
4402
+ `;
4403
+ await writePrivate(paths, releasesFile(paths), text, 420);
4404
+ }
4281
4405
  // ../core/src/merge.ts
4282
4406
  var MERGE_LEASE = "merge";
4283
4407
  var MERGE_LEASE_TTL_MS = 20 * 60000;
@@ -4950,7 +5074,7 @@ async function readProjectConfig(p, opts) {
4950
5074
  }
4951
5075
  }
4952
5076
  // ../core/src/skills.ts
4953
- import { createHash } from "node:crypto";
5077
+ import { createHash as createHash2 } from "node:crypto";
4954
5078
 
4955
5079
  // ../../skills/armada-coordinator/MERGE.md
4956
5080
  var MERGE_default = "# Merging a pull request\n\nRun `armada merge <pr>` (add `--dry-run` to see the checklist only, `--wait` when main keeps moving, `--no-ticket` for a pull request no ticket owns). It checks everything below, takes the project's merge lock, merges pinned to the handed-back SHA, confirms the merge on GitHub and closes the ticket. Its output lists the workers in flight to tell and the worker session to archive. When a refusal names a rule, fix the cause (usually: ask the worker to bring the default branch in and report again) rather than merging by hand. When you must merge by hand, follow the same steps.\n\n## Main kept moving: `--wait`\n\nWith several workers in flight, main often moves between a green hand-back and its merge. Instead of asking the worker to bring main in, run `armada merge <pr> --wait [--timeout <min>]` (30 minutes by default), in the background where your runtime allows it (Claude Code: `run_in_background`):\n\n- A head behind main that GitHub says merges cleanly is updated with GitHub's \"update branch\": a merge commit on the branch, no force-push. Squash merges make that merge commit harmless. When main does not require heads to be up to date and `[gates] local_commands` is set, it is test-merged instead, as without `--wait`, so a busy main does not restart CI each time.\n- It waits for every required check on the new head, then merges pinned to that head.\n- It holds the project's merge lock only while merging, not while waiting, so two waits never block each other. Signed in with Armada down, it refuses before touching the branch.\n- It stops at once, naming the cause, on a red check, a conflict, any other refused rule, or when GitHub refuses the update (a branch protection rule or ruleset can forbid it) or accepts it without the head moving within 3 minutes: ask the worker to fix it. A refusal after an update says so: the worker pulls the updated branch before pushing again.\n- The updated head still counts as the worker's hand-back, because the only change is main coming in: `armada merge` accepts a head that is the handed-back SHA followed only by merge commits, each bringing in a commit of main, with the tree of a clean merge (checked with git). That holds without `--wait` too, for example after \"Update branch\" on GitHub. The ticket's merged comment names both heads: `head <new>, the handed-back <old> updated with main`.\n\n## No ticket: `--no-ticket`\n\n`armada merge <pr> --no-ticket` merges a pull request no ticket owns: the `armada init` pull request (its output names the command) or the release pull request below. There is no hand-back and nothing is written to Linear; every other check is unchanged, and the merge is pinned to the head it checked. It refuses a branch that names a ticket of the program: that one is merged on its worker's hand-back.\n\nWhen none of the required checks ran on the head (a release pull request opened with the workflow's own token gets no CI run), it passes with a note, on GitHub's own state (`UNSTABLE` included, when nothing failed) and the checks that did run, once the head is a minute old; a younger head, or a head this run updated (its update starts CI), is waited for (`--wait`) or refused.\n\n## Before\n\n1. The worker has handed back: `Agent phase` is `ready-to-merge` and you have the full 40-character head SHA it reported.\n2. `gh pr view <n> --json headRefOid,mergeStateStatus,isDraft,title` shows that SHA (or that SHA with only main merged in), `CLEAN` (or `HAS_HOOKS`), not a draft, and a Commitizen title.\n3. `gh pr checks <n>` shows every required check passing.\n4. The head contains the current default branch: `git merge-base --is-ancestor origin/<default> <sha>`. If not, update it (`--wait`) or ask the worker to bring the default branch in (rebase, or merge it into their branch; never force-push a branch someone else pushed to).\n5. Semantic check: search the default branch for callers of anything the pull request deletes or renames.\n\n## Merge\n\n```sh\ngh pr merge <n> --squash --match-head-commit <full-sha>\n```\n\n- One merge at a time: `armada merge` holds the project's merge lock. If it refuses because Armada is down, use `--no-lock` only when you are sure no other coordinator merges in the project.\n- Leave out `--delete-branch`: it deletes local worktrees that have the branch checked out, including other agents'. Delete the branch once its worktree is gone.\n- If GitHub answers with a 5xx, check `gh pr view <n> --json state` before retrying.\n\n## After\n\n1. The ticket is Done, its `Agent phase` and `Agent runtime` labels removed, the pull request linked.\n2. Tell every in-flight worker what the merge changes for them: a shared file, a migration, a new check, code they must now reuse or delete.\n3. Archive the merged worker's workspace with the \"Stop and archive\" section of its runtime guide.\n4. Launch the tickets this merge unblocked.\n\n## The release pull request\n\nSome repositories publish through release-please: every merge to the default branch opens or updates one release pull request, and merging it tags the version and publishes it. When the repository's rules (`AGENTS.md`) say to merge it after each merge, do it right after the ticket's merge, without a hand-back: no worker owns it.\n\n- **What it looks like.** Title `chore(main): release <version>`, opened by `github-actions`, label `autorelease: pending`, and a diff that only touches the changelog, the manifest and version fields. It is opened with the workflow's own token, so **no CI check runs on it** (only checks from apps such as Vercel, if any) and `mergeStateStatus` is often `UNSTABLE` (`armada merge --no-ticket` accepts it when none of the required checks ran and nothing failed). Both are expected: the publish job runs the repository's checks again before publishing. Anything else in the diff, or a `DIRTY` state, is not expected: stop and tell the owner.\n- **Find it and its head:**\n\n```sh\ngh pr list --state open --label \"autorelease: pending\" --json number,title,headRefOid,mergeStateStatus\n```\n\n- **Merge it** with `armada merge <n> --no-ticket`: no ticket owns it, and no required check runs on it (see \"No ticket\" above). By hand, pin it to that head, like any merge, and without `--delete-branch`:\n\n```sh\ngh pr merge <n> --squash --match-head-commit <full-sha>\n```\n\n- **Check the publish.** After a minute or two the new version is on the registry, for example `npm view <package> version` for an npm package (the package is named in `AGENTS.md` or the release workflow). If it is not, open the Release run (`gh run list --workflow release.yml --limit 3`), fix the cause and re-run its failed jobs: a later push does not publish a version already tagged.\n- Release-please updates the same pull request on each merge to the default branch; one release pull request can carry several merges.\n";
@@ -4987,11 +5111,11 @@ A coordinator may start cold, on a laptop or in a fresh cloud session, with noth
4987
5111
  - \`answer-request\` (it names the question or plan it answers, \`answers #<id>\`): deliver its text in the worker's session with the runtime guide's *message* section, as the owner's answer or plan approval, then \`armada answer <request id> "<the text you delivered>"\`. That resolves the request and its question or plan, and the ticket names who answered. If the item is gone (the worker was released or changed phase), \`armada answer <request id> "<why>"\` closes it.
4988
5112
  - \`launch-request\` (it names the profile the owner chose): launch the ticket as in step 5, with that profile. When it differs from the routed one, the request's body gives the \`--profile\` and \`--reason\` to pass to \`armada brief\` and to the worker's claim. The worker's \`armada claim\` resolves the request and posts who asked. If the ticket must not start (it collides with work in flight, or its plan changed), decline it: \`armada answer <request id> "<why>"\`, and tell the owner in your report.
4989
5113
  Done when the inbox shows no open request.
4990
- 4. **Check silent workers** with the runtime guide's *status* section. A worker that is still working gets a nudge to report; a worker that died is relaunched or its ticket released.
5114
+ 4. **Check silent workers and workers that never started** with the runtime guide's *status* section. A worker that is still working gets a nudge to report; a worker that died is relaunched or its ticket released. A \`not-started\` entry is a worker launched that has not claimed after \`[policy] not_started_minutes\` (10 by default); it says whether the worker never used its launch token (it never reached its \`armada login\` line: an install that failed, a prompt cut short) or signed in and stopped before its claim. Read its session: a worker stuck on a setup choice gets a message to take the safe option and go on; one that is gone is launched again with a new brief, or its launch revoked on the dashboard's Workers page. The entry clears on the claim.
4991
5115
  5. **Launch ready tickets** that do not collide with work in flight, one at a time:
4992
5116
  - pick the ticket from the frontier in \`armada status\`;
4993
5117
  - run \`armada brief <ticket>\` and resolve its warnings. The profile (agent, model, effort) is routed from the ticket's labels by \`[[conductor.routing]]\` in \`armada.toml\`, else \`default_profile\`, and the brief says which rule chose it. Follow it. Override it only when the ticket's labels mislead (for example a \`web\` ticket that is really a tricky back-end bug): \`armada brief <ticket> --profile <name> --reason "<why>"\`. The reason lands in the worker's claim comment;
4994
- - write the prompt with \`armada brief <ticket> --prompt > <file>\` and add what only you know: which parallel workers touch neighbouring code and where the boundary is, and decisions not yet on the ticket. The brief already says whether the plan needs approval (\`[policy] plans\`, or the ticket's label) and ends with the project's conventions (\`[brief] extra\`): put a note every worker needs in that file, not in each prompt;
5118
+ - write the prompt with \`armada brief <ticket> --prompt > <file>\`. **The launch message is that \`--prompt\` output, never text cut from the human view or \`--json\`**: those show the token masked as \`armada_launch_••••\`, which signs nobody in. Add what only you know: which parallel workers touch neighbouring code and where the boundary is, and decisions not yet on the ticket. The brief already says whether the plan needs approval (\`[policy] plans\`, or the ticket's label) and ends with the project's conventions (\`[brief] extra\`): put a note every worker needs in that file, not in each prompt;
4995
5119
  - launch it with the runtime guide's *launch* section, passing the profile's values. When the brief's \`Launch:\` line says the prompt carries a one-time token, pass no key: the worker signs in with it. When it says there is none, fix the reason (usually your sign-in) and brief again, rather than pass keys; the token works once, within the hour, so brief right before the launch;
4996
5120
  - check the claim: \`armada status\` shows the ticket in flight, phase \`planning\`, with the handle the runtime returned. Done when every launched ticket is In Progress with a claim.
4997
5121
  6. **Merge handed-back pull requests** one at a time with \`armada merge <pr>\` (\`--wait\` when main moved since the hand-back, \`--no-ticket\` for a pull request no ticket owns), following [MERGE.md](MERGE.md). Done when the pull request is merged, the ticket is Done with its agent labels removed, and every in-flight worker affected by what landed has been told. When the repository's rules (\`AGENTS.md\`) ask you to ship each merge through its release pull request (release-please's \`chore(main): release …\`), merge that one next, as "The release pull request" in [MERGE.md](MERGE.md) describes.
@@ -5002,11 +5126,12 @@ Repeat from step 1.
5002
5126
 
5003
5127
  ## Keep watching
5004
5128
 
5005
- You only learn of something new when a command you run ends. So while a worker is in flight, always have exactly one \`armada watch\` running, in the background (in Claude Code, a Bash command with \`run_in_background\`; in another runtime, its own way of running a command in the background). It waits until something needs you (a question, a plan, a request, a hand-back or a silent worker you have not been shown yet), prints it and exits, and you are woken. Armada being down or a command time limit does not end it, and it tells the dashboard you are at work.
5129
+ You only learn of something new when a command you run ends. So while a worker is in flight, always have exactly one \`armada watch\` running, in the background (in Claude Code, a Bash command with \`run_in_background\`; in another runtime, its own way of running a command in the background). It waits until something needs you (a question, a plan, a request, a hand-back, a silent worker or one that never started, you have not been shown yet), prints it and exits, and you are woken. Armada being down or a command time limit does not end it, and it tells the dashboard you are at work.
5006
5130
 
5007
5131
  - Start it as soon as a worker is in flight, and start it again right after acting on what it returned. Never end your turn with a worker in flight and no watch running: that is how a hand-back sits unmerged.
5008
5132
  - The last line of \`armada inbox\`, \`armada watch\`, \`armada merge\` and \`armada brief\` says whether to: \`2 workers in flight (ABC-1, ABC-2) — keep watching: armada watch\`, \`armada watch is already running (pid …)\`, or \`nothing to watch\`. Follow it. A second \`armada watch\` on the same project only says the first one is running.
5009
5133
  - \`armada watch\` exits with "nothing to watch" when no worker is in flight and nothing is open: the round is over.
5134
+ - A \`version\` item means a newer Armada is out; any coordinator command also says so once, on stderr. It is not urgent: questions, plans, hand-backs and merges come first. Between rounds, upgrade the CLI with the \`npm install -g\` line it gives, run \`armada init\` and merge its pull request with \`armada merge <n> --no-ticket\`. Tell workers in flight nothing: each keeps the version its brief pinned, unless the release notes (the item's link) say otherwise. \`armada status\` and \`armada doctor\` say when this project's skills differ from your CLI's.
5010
5135
  - Your own coordination ticket is not a worker: the watch and the re-arm line leave out the claim whose handle is yours, taken from \`ARMADA_COORDINATOR_HANDLE\`, else from Conductor's workspace and session. Outside Conductor, set \`ARMADA_COORDINATOR_HANDLE\` to the handle you claimed with.
5011
5136
  - In Claude Code, the stop hook \`armada init\` installs refuses to end your turn while workers are in flight and no watch runs, and tells you to start one. It holds only the checkout where \`armada watch\` ran, never a worker. If it misbehaves, \`ARMADA_STOP_HOOK=off\` in the environment turns it off; say so in your report. Other runtimes have no hook: follow the same rule yourself.
5012
5137
  - A runtime that cannot run a command in the background uses \`armada inbox --wait\` instead, again and again: it returns when a new item arrives or at its timeout (default 300 s, \`--timeout <seconds>\`; keep it under your command time limit).
@@ -5038,7 +5163,7 @@ Armada never calls a runtime. This guide tells a coordinator running inside Clau
5038
5163
  1. Pick a ready ticket from \`armada status\` that does not collide with work in flight.
5039
5164
  2. Run \`armada brief ABC-12\` (with \`--profile <name> --reason "<why>"\` when you override the routed profile), right before the launch. Its \`Runtime:\` line must say \`claude-code\`: the profile has \`runtime = "claude-code"\` in \`armada.toml\`. Read the profile (model), the \`Launch:\` line and the warnings, and resolve every warning first. The profile's effort is not applied by the Agent tool; a worker that needs a set effort goes to Conductor.
5040
5165
  - \`Launch: one-time token in the prompt\` is the normal case. \`Launch: no launch token (…)\` says why: usually \`armada login\`, then brief again.
5041
- 3. Read the prompt: \`armada brief ABC-12 --prompt\`. The token in it works once, within the hour: brief again when that hour has passed before the launch. Add what only you know (the boundary with a parallel worker, a decision not yet on the ticket) at the end.
5166
+ 3. Read the prompt: \`armada brief ABC-12 --prompt\`. **The launch message is that \`--prompt\` output, and only it**: the human view and \`--json\` mask the token as \`armada_launch_••••\`, which signs nobody in. The token in it works once, within the hour: brief again when that hour has passed before the launch. Add what only you know (the boundary with a parallel worker, a decision not yet on the ticket) at the end.
5042
5167
  4. Launch with the Agent tool, every value set:
5043
5168
 
5044
5169
  \`\`\`json
@@ -5059,7 +5184,7 @@ Armada never calls a runtime. This guide tells a coordinator running inside Clau
5059
5184
  - The result gives the \`agentId\` and an \`output_file\`: the worker's transcript (JSONL). Keep both. Never read that file whole: it is the entire conversation (Status section).
5060
5185
  - \`.claude/worktrees/\` appears as untracked in your own checkout: never commit it (add it to \`.gitignore\`).
5061
5186
 
5062
- 5. **Check the claim.** Within a few minutes, \`armada status\` lists the ticket in flight, phase \`planning\`, runtime \`Claude Code\`, and the claim comment reads \`session: abc-12\` and \`profile: <name>\`. No claim: read the transcript (Status section). A worker whose launch token was refused needs a new one: brief again and message it only the \`armada login --launch-token …\` line of the new prompt. A worker cut off from Armada was revoked on the dashboard or left idle for three days: ask the owner before you give it a new token.
5187
+ 5. **Check the claim.** Within a few minutes, \`armada status\` lists the ticket in flight, phase \`planning\`, runtime \`Claude Code\`, and the claim comment reads \`session: abc-12\` and \`profile: <name>\`. No claim after \`[policy] not_started_minutes\` (ten by default): \`armada watch\` and \`armada inbox\` show a \`not-started\` entry saying whether the worker never used its token or signed in and stopped. Read the transcript (Status section). A worker whose launch token was refused needs a new one: brief again and message it only the \`armada login --launch-token …\` line of the new \`--prompt\` output. A worker cut off from Armada was revoked on the dashboard or left idle for three days: ask the owner before you give it a new token.
5063
5188
 
5064
5189
  ## Message
5065
5190
 
@@ -5129,7 +5254,7 @@ A subagent launched without \`isolation: "worktree"\` runs in your checkout. The
5129
5254
  `;
5130
5255
 
5131
5256
  // ../../skills/armada-runtime-conductor/SKILL.md
5132
- var SKILL_default3 = "---\nname: armada-runtime-conductor\ndescription: Runtime guide for running Armada workers on Conductor Cloud. Use when an Armada coordinator must launch a worker on a ticket, send it a message, check whether a silent worker is still alive, or stop and archive it. Four fixed sections, each with the exact conductor command and how to read its output.\n---\n\nArmada never calls a runtime. This guide tells the coordinator how to launch, message, check and stop a worker with the `conductor` command line tool, and what to record in Armada afterwards. It was checked against `conductor` 0.89.x (the desktop app's CLI, macOS) and 0.1.x (the CLI inside a Conductor Cloud workspace, Linux); every command below works in both. `conductor --version` prints yours; if a flag is refused, compare with `conductor <command> --help`.\n\n- On a Mac, the app ships the CLI at `/Applications/Conductor.app/Contents/Resources/bin/conductor`, which is not on PATH. `armada doctor` looks for it and prints the fix: a link from a directory already on PATH (`ln -s \"/Applications/Conductor.app/Contents/Resources/bin/conductor\" ~/.local/bin/conductor`), or a PATH line for your shell profile.\n- Always pass `--json` and read fields with `jq`. Exit codes: 0 ok, 1 runtime error, 2 usage error, 3 authentication, 4 server error.\n- On exit code 3, `conductor auth whoami` checks the token the CLI uses (it exits 0 when the token works). Do not rely on `conductor auth status`: it only looks for a macOS Keychain entry and fails on Linux (\"Keychain storage is only supported on macOS\"). In a Conductor Cloud workspace the CLI reads `CONDUCTOR_API_KEY` from the environment and needs no login; on a Mac, `conductor auth login` stores a token in the Keychain.\n- A worker is one workspace with one session. Its Armada handle is `<workspaceId>/<sessionId>`; the worker's claim comment carries it, so `armada status` and the ticket always lead back to the session.\n- A worker needs no key in its workspace: the prompt of `armada brief` carries a one-time launch token, and the worker's first command exchanges it for a session limited to its ticket, through which Armada gives each command its keys. The token works once, within the hour, so a copy left in a transcript is useless once used.\n- Never type a secret value into a command, a file or a message: name the variable and let your shell expand it. The expanded value is still in the `conductor` process's arguments while it runs, so launch from a machine only you use.\n\n## Launch\n\n1. Pick a ready ticket from `armada status` that does not collide with work in flight.\n2. Run `armada brief ABC-12` (with `--profile <name> --reason \"<why>\"` when you override the routed profile), right before the launch. Read the profile (agent, model, effort, fast mode), the `Launch:` line and the warnings. Resolve every warning first: an open blocker, a ticket already in flight.\n - `Launch: one-time token in the prompt` is the normal case: the worker signs in to Armada with it and fetches its own keys. Its workspace receives no key at all. This view and `--json` show the token as `armada_launch_••••`; only `--prompt` prints it.\n - `Launch: no launch token (…)` says why. Not signed in: `armada login` (a headless coordinator sets `ARMADA_API_KEY`), then brief again; `armada doctor` checks the sign-in. Launch with keys (step 4, second block) only on an Armada that keeps no keys yet (no accounts or no vault: a self-hosted one, CI, or before the owner's switch to the Keys page).\n3. Write the prompt to a file only you can read, and add what only you know (the boundary with a parallel worker, a decision not yet on the ticket). The token in it works once, within the hour: brief again when that hour has passed before the launch.\n\n```sh\n(umask 077; armada brief ABC-12 --prompt > /tmp/abc-12-brief.md)\n```\n\n4. Create the workspace with every value from the profile. Never leave the agent, model or effort to Conductor's defaults. Add `--fast-mode` when the profile says fast mode. Run the whole block as one command: shell state does not carry over between separate calls.\n\n```sh\nconductor --json workspace create \\\n --repo-url https://github.com/<owner>/<name> \\\n --branch main \\\n --name \"ABC-12 <short title>\" \\\n --agent claude --model opus-5-5-1m --effort high \\\n --message-file - \\\n --env ARMADA_TICKET=ABC-12 \\\n < /tmp/abc-12-brief.md > /tmp/abc-12-launch.json\nrm -f /tmp/abc-12-brief.md\njq -r '\"\\(.workspaceId)/\\(.sessionId)\"' /tmp/abc-12-launch.json\n```\n\nWithout a launch token (an Armada that keeps no keys), pass the keys the brief's environment table marks `required`, from your shell or from Armada's credentials file (`in credentials file`: the `set -a` line loads it without printing it; drop it when every variable is set in your shell). The subshell keeps the keys out of the rest of your session. Without a launch token the worker is not signed in to Armada: its claims and reports reach Linear only, with a warning. When Conductor's organization environment still holds the keys, every workspace already has them: use the first block.\n\n```sh\n(\n set -a; . \"${XDG_CONFIG_HOME:-$HOME/.config}/armada/credentials\"; set +a\n [ -n \"$LINEAR_API_KEY\" ] || { echo \"LINEAR_API_KEY is missing\" >&2; exit 1; }\n conductor --json workspace create \\\n --repo-url https://github.com/<owner>/<name> \\\n --branch main \\\n --name \"ABC-12 <short title>\" \\\n --agent claude --model opus-5-5-1m --effort high \\\n --message-file - \\\n --env ARMADA_TICKET=ABC-12 \\\n --env LINEAR_API_KEY=\"$LINEAR_API_KEY\" \\\n < /tmp/abc-12-brief.md > /tmp/abc-12-launch.json\n)\nrm -f /tmp/abc-12-brief.md\n```\n\n- `--branch` is the base branch (the default branch). Conductor creates a branch named `conductor/<slug of --name>`; the brief tells the worker to rename it to the ticket's branch.\n- The output has `workspaceId`, `sessionId`, `deepLink` and `initialMessage` (`messageId`, `state: \"queued\"`). Keep the handle the `jq` line prints, and give the owner the `deepLink` when they want to watch.\n- Conductor sets `CONDUCTOR_WORKSPACE_ID` and `CONDUCTOR_SESSION_ID` inside the workspace, and signs `gh` in for the worker's pushes. The brief's first commands install your Armada version (`npm install -g`), sign in with the launch token (`armada login --launch-token`) and claim the ticket. `--env` values are not shown back by `workspace get`.\n- Keys in Conductor's organization environment reach every workspace, workers included: once Armada keeps the organization's keys, they belong on Armada's Keys page, not there.\n- An unknown agent, model or effort fails the command. Check the ids with `conductor model` (each agent's models, efforts and defaults) and fix the profile in `armada.toml`.\n\n5. **Check the claim.** Within a few minutes, `armada status` lists the ticket in flight, phase `planning`, runtime `Conductor`, and the ticket's claim comment reads `session: <workspaceId>/<sessionId>` and `profile: <name>`. No claim after ten minutes: read the transcript (Status section). A worker whose launch token was refused (already used, or more than an hour old) needs a new one: `armada brief ABC-12 --prompt` again, and message it only the `armada login --launch-token …` line of the new prompt (Message section). A worker cut off from Armada was revoked on the dashboard (Organization > Workers says by whom) or left idle for three days: ask the owner before you give a revoked worker a new token. If the worker cannot claim for another reason, fix the cause and message it; as a last resort record the handle yourself with `armada claim ABC-12 --runtime conductor --handle <workspaceId>/<sessionId> --profile <name>`, adding the brief's `--reason` for an override.\n\n## Message\n\n```sh\nprintf '%s\\n' \"Plan approved. Go on.\" | conductor --json message create --session <sessionId> --message-file -\nconductor --json message create --session <sessionId> --message-file - < /tmp/abc-12-answer.md\n```\n\nThe output is `{\"messageId\": …, \"state\": \"sent\"}`. Exit code 0 means Conductor accepted the message, not that the worker read it: check that the session turns `working`, then read its reply in the transcript. Use it to deliver an answer, a plan approval, or a heads-up that the default branch moved. Then record it in Armada: `armada answer <item> \"<answer>\"` for a question from `armada inbox`, `armada answer --note ABC-12 \"<message>\"` for a message the worker did not ask for.\n\n## Status\n\n```sh\nconductor --json session status <sessionId>\n```\n\nThe output is `{\"workspaceId\", \"sessionId\", \"status\", \"updatedAt\"}`. For a worker:\n\n- `working`: a turn is running. A silent worker that is `working` is busy (a long build or test run): leave it, and read the transcript if it stays silent past twice `policy.silence_minutes`.\n- `idle`: no turn is running. The worker finished its turn: it handed back, it waits for an answer, or it stopped without finishing. If `armada status` does not show it `ready-to-merge`, `awaiting-approval` or `blocked`, it has stopped: read its last reply, then message it to go on, or release and relaunch the ticket.\n- `error`: the last turn failed (agent or provider failure). Read the transcript and message it to resume; if it fails again, cancel, archive, release and relaunch.\n- Right after launch the session is `idle` for a few seconds while the workspace is initializing and the first message is queued; it turns `working` when the agent starts.\n\nThe workspace itself: `conductor --json workspace status <workspaceId>` gives `status` `initializing`, `ready` or `archived`.\n\n**Read the transcript** to see what a worker did or said. Events come oldest first, 100 per page; `hasMore` tells when to fetch the next page with `--after` the last event id. Keep the last id you read and poll from it.\n\n```sh\nconductor --json session message <sessionId> --limit 100 > /tmp/abc-12-events.json\njq -r '.hasMore, .data[-1].id' /tmp/abc-12-events.json\nconductor --json session message <sessionId> --after <lastEventId> --limit 100\n```\n\nThe second line prints whether more pages exist and the id to continue from. `.content.rawPayload` is the agent's own event format, so the filters depend on the worker's agent (the `agent` of its profile in `armada.toml`).\n\nA `claude` worker: each turn's final reply, then the commands and tools it ran.\n\n```sh\njq -r '.data[] | select(.content.rawPayload.type == \"result\") | .content.rawPayload | \"error=\\(.is_error)\\n\\(.result)\"' /tmp/abc-12-events.json\njq -r '.data[] | select(.content.rawPayload.type == \"assistant\") | .content.rawPayload.message.content[] | select(.type == \"tool_use\") | .input.command // .name' /tmp/abc-12-events.json\n```\n\nA `codex` worker: its events are `.content.rawPayload.event`, each item once as `item.started` and once as `item.completed`; read the completed ones. Its messages (`phase` is `commentary` along the way, `final_answer` at the end of a turn), then each command with its exit code, and its tool calls (Linear and other MCP servers).\n\n```sh\njq -r '.data[] | .content.rawPayload.event | select(.type == \"item.completed\") | .item | select(.type == \"agentMessage\") | \"[\\(.phase)] \\(.text)\"' /tmp/abc-12-events.json\njq -r '.data[] | .content.rawPayload.event | select(.type == \"item.completed\") | .item | select(.type == \"commandExecution\") | \"exit=\\(.exitCode) \\(.command)\"' /tmp/abc-12-events.json\njq -r '.data[] | .content.rawPayload.event | select(.type == \"item.completed\") | .item | select(.type == \"mcpToolCall\") | \"\\(.server) \\(.tool)\"' /tmp/abc-12-events.json\n```\n\nAnother agent, or a filter that prints nothing: count the event types, look at one event of the type you need, and adapt the filter.\n\n```sh\njq -r '.data[].content.rawPayload | .type // .event.type // \"(no payload)\"' /tmp/abc-12-events.json | sort | uniq -c\n```\n\n## Stop and archive\n\n```sh\nconductor --json session cancel <sessionId>\nconductor --json workspace archive <workspaceId>\n```\n\n- `session cancel` stops the running turn: `{\"status\", \"canceledQueuedMessages\"}`, and the session is `idle` within seconds. The workspace stays; a message starts a new turn. Use it on a worker that runs the wrong thing.\n- `workspace archive` answers `{\"status\": \"archived\"}`. Archive a worker's workspace after its pull request is merged, or after `armada release --ticket ABC-12 --reason \"<why>\"` for a worker that stops without handing back. The branch and the pull request stay on GitHub.\n- **Wait for `idle` before archiving.** A hand-back often arrives while the worker's session is still `working`: `armada report ready-to-merge` runs inside its last turn, which then writes its final reply. Archive only once `session status` answers `idle`. Poll it every 15 seconds; if it is still `working` after 10 minutes, cancel the turn and archive (the transcript keeps what it was doing). Run the whole block as one command; it can take up to 10 minutes, so run it in the background or give it a longer command timeout:\n\n```sh\nfor i in $(seq 40); do\n [ \"$(conductor --json session status <sessionId> | jq -r .status)\" = working ] || break\n sleep 15\ndone\n[ \"$(conductor --json session status <sessionId> | jq -r .status)\" = working ] && conductor --json session cancel <sessionId>\nconductor --json workspace archive <workspaceId>\n```\n- After an archive, `session status` still answers `idle`; `workspace status` says `archived`.\n";
5257
+ var SKILL_default3 = "---\nname: armada-runtime-conductor\ndescription: Runtime guide for running Armada workers on Conductor Cloud. Use when an Armada coordinator must launch a worker on a ticket, send it a message, check whether a silent worker is still alive, or stop and archive it. Four fixed sections, each with the exact conductor command and how to read its output.\n---\n\nArmada never calls a runtime. This guide tells the coordinator how to launch, message, check and stop a worker with the `conductor` command line tool, and what to record in Armada afterwards. It was checked against `conductor` 0.89.x (the desktop app's CLI, macOS) and 0.1.x (the CLI inside a Conductor Cloud workspace, Linux); every command below works in both. `conductor --version` prints yours; if a flag is refused, compare with `conductor <command> --help`.\n\n- On a Mac, the app ships the CLI at `/Applications/Conductor.app/Contents/Resources/bin/conductor`, which is not on PATH. `armada doctor` looks for it and prints the fix: a link from a directory already on PATH (`ln -s \"/Applications/Conductor.app/Contents/Resources/bin/conductor\" ~/.local/bin/conductor`), or a PATH line for your shell profile.\n- Always pass `--json` and read fields with `jq`. Exit codes: 0 ok, 1 runtime error, 2 usage error, 3 authentication, 4 server error.\n- On exit code 3, `conductor auth whoami` checks the token the CLI uses (it exits 0 when the token works). Do not rely on `conductor auth status`: it only looks for a macOS Keychain entry and fails on Linux (\"Keychain storage is only supported on macOS\"). In a Conductor Cloud workspace the CLI reads `CONDUCTOR_API_KEY` from the environment and needs no login; on a Mac, `conductor auth login` stores a token in the Keychain.\n- A worker is one workspace with one session. Its Armada handle is `<workspaceId>/<sessionId>`; the worker's claim comment carries it, so `armada status` and the ticket always lead back to the session.\n- A worker needs no key in its workspace: the prompt of `armada brief` carries a one-time launch token, and the worker's first command exchanges it for a session limited to its ticket, through which Armada gives each command its keys. The token works once, within the hour, so a copy left in a transcript is useless once used.\n- Never type a secret value into a command, a file or a message: name the variable and let your shell expand it. The expanded value is still in the `conductor` process's arguments while it runs, so launch from a machine only you use.\n\n## Launch\n\n1. Pick a ready ticket from `armada status` that does not collide with work in flight.\n2. Run `armada brief ABC-12` (with `--profile <name> --reason \"<why>\"` when you override the routed profile), right before the launch. Read the profile (agent, model, effort, fast mode), the `Launch:` line and the warnings. Resolve every warning first: an open blocker, a ticket already in flight.\n - `Launch: one-time token in the prompt` is the normal case: the worker signs in to Armada with it and fetches its own keys. Its workspace receives no key at all. This view and `--json` show the token as `armada_launch_••••`; only `--prompt` prints it.\n - `Launch: no launch token (…)` says why. Not signed in: `armada login` (a headless coordinator sets `ARMADA_API_KEY`), then brief again; `armada doctor` checks the sign-in. Launch with keys (step 4, second block) only on an Armada that keeps no keys yet (no accounts or no vault: a self-hosted one, CI, or before the owner's switch to the Keys page).\n3. **The launch message is the `--prompt` output, and only it.** Never cut the prompt out of the human view of `armada brief` or its `--json`: they mask the token as `armada_launch_••••`, which signs nobody in, and the worker's `armada login` stops on it. Write the prompt to a file only you can read with `--prompt`, and add what only you know (the boundary with a parallel worker, a decision not yet on the ticket). The token in it works once, within the hour: brief again when that hour has passed before the launch.\n\n```sh\n(umask 077; armada brief ABC-12 --prompt > /tmp/abc-12-brief.md)\n```\n\n4. Create the workspace with every value from the profile. Never leave the agent, model or effort to Conductor's defaults. Add `--fast-mode` when the profile says fast mode. Run the whole block as one command: shell state does not carry over between separate calls.\n\n```sh\nconductor --json workspace create \\\n --repo-url https://github.com/<owner>/<name> \\\n --branch main \\\n --name \"ABC-12 <short title>\" \\\n --agent claude --model opus-5-5-1m --effort high \\\n --message-file - \\\n --env ARMADA_TICKET=ABC-12 \\\n < /tmp/abc-12-brief.md > /tmp/abc-12-launch.json\nrm -f /tmp/abc-12-brief.md\njq -r '\"\\(.workspaceId)/\\(.sessionId)\"' /tmp/abc-12-launch.json\n```\n\nWithout a launch token (an Armada that keeps no keys), pass the keys the brief's environment table marks `required`, from your shell or from Armada's credentials file (`in credentials file`: the `set -a` line loads it without printing it; drop it when every variable is set in your shell). The subshell keeps the keys out of the rest of your session. Without a launch token the worker is not signed in to Armada: its claims and reports reach Linear only, with a warning. When Conductor's organization environment still holds the keys, every workspace already has them: use the first block.\n\n```sh\n(\n set -a; . \"${XDG_CONFIG_HOME:-$HOME/.config}/armada/credentials\"; set +a\n [ -n \"$LINEAR_API_KEY\" ] || { echo \"LINEAR_API_KEY is missing\" >&2; exit 1; }\n conductor --json workspace create \\\n --repo-url https://github.com/<owner>/<name> \\\n --branch main \\\n --name \"ABC-12 <short title>\" \\\n --agent claude --model opus-5-5-1m --effort high \\\n --message-file - \\\n --env ARMADA_TICKET=ABC-12 \\\n --env LINEAR_API_KEY=\"$LINEAR_API_KEY\" \\\n < /tmp/abc-12-brief.md > /tmp/abc-12-launch.json\n)\nrm -f /tmp/abc-12-brief.md\n```\n\n- `--branch` is the base branch (the default branch). Conductor creates a branch named `conductor/<slug of --name>`; the brief tells the worker to rename it to the ticket's branch.\n- The output has `workspaceId`, `sessionId`, `deepLink` and `initialMessage` (`messageId`, `state: \"queued\"`). Keep the handle the `jq` line prints, and give the owner the `deepLink` when they want to watch.\n- Conductor sets `CONDUCTOR_WORKSPACE_ID` and `CONDUCTOR_SESSION_ID` inside the workspace, and signs `gh` in for the worker's pushes. The brief's first commands install your Armada version (`npm install -g`), sign in with the launch token (`armada login --launch-token`) and claim the ticket. `--env` values are not shown back by `workspace get`.\n- Keys in Conductor's organization environment reach every workspace, workers included: once Armada keeps the organization's keys, they belong on Armada's Keys page, not there.\n- An unknown agent, model or effort fails the command. Check the ids with `conductor model` (each agent's models, efforts and defaults) and fix the profile in `armada.toml`.\n\n5. **Check the claim.** Within a few minutes, `armada status` lists the ticket in flight, phase `planning`, runtime `Conductor`, and the ticket's claim comment reads `session: <workspaceId>/<sessionId>` and `profile: <name>`. No claim after `[policy] not_started_minutes` (ten by default): `armada watch` and `armada inbox` show a `not-started` entry, and `armada status` lists the ticket under \"Launched, not started\". It says whether the worker never used its launch token (it never reached its login line) or signed in and stopped before its claim. Read the transcript (Status section). A worker whose launch token was refused (already used, or more than an hour old) needs a new one: `armada brief ABC-12 --prompt` again, and message it only the `armada login --launch-token …` line of the new `--prompt` output (Message section). A worker cut off from Armada was revoked on the dashboard (Organization > Workers says by whom) or left idle for three days: ask the owner before you give a revoked worker a new token. If the worker cannot claim for another reason, fix the cause and message it; as a last resort record the handle yourself with `armada claim ABC-12 --runtime conductor --handle <workspaceId>/<sessionId> --profile <name>`, adding the brief's `--reason` for an override.\n\n## Message\n\n```sh\nprintf '%s\\n' \"Plan approved. Go on.\" | conductor --json message create --session <sessionId> --message-file -\nconductor --json message create --session <sessionId> --message-file - < /tmp/abc-12-answer.md\n```\n\nThe output is `{\"messageId\": …, \"state\": \"sent\"}`. Exit code 0 means Conductor accepted the message, not that the worker read it: check that the session turns `working`, then read its reply in the transcript. Use it to deliver an answer, a plan approval, or a heads-up that the default branch moved. Then record it in Armada: `armada answer <item> \"<answer>\"` for a question from `armada inbox`, `armada answer --note ABC-12 \"<message>\"` for a message the worker did not ask for.\n\n## Status\n\n```sh\nconductor --json session status <sessionId>\n```\n\nThe output is `{\"workspaceId\", \"sessionId\", \"status\", \"updatedAt\"}`. For a worker:\n\n- `working`: a turn is running. A silent worker that is `working` is busy (a long build or test run): leave it, and read the transcript if it stays silent past twice `policy.silence_minutes`.\n- `idle`: no turn is running. The worker finished its turn: it handed back, it waits for an answer, or it stopped without finishing. If `armada status` does not show it `ready-to-merge`, `awaiting-approval` or `blocked`, it has stopped: read its last reply, then message it to go on, or release and relaunch the ticket.\n- `error`: the last turn failed (agent or provider failure). Read the transcript and message it to resume; if it fails again, cancel, archive, release and relaunch.\n- Right after launch the session is `idle` for a few seconds while the workspace is initializing and the first message is queued; it turns `working` when the agent starts.\n\nThe workspace itself: `conductor --json workspace status <workspaceId>` gives `status` `initializing`, `ready` or `archived`.\n\n**Read the transcript** to see what a worker did or said. Events come oldest first, 100 per page; `hasMore` tells when to fetch the next page with `--after` the last event id. Keep the last id you read and poll from it.\n\n```sh\nconductor --json session message <sessionId> --limit 100 > /tmp/abc-12-events.json\njq -r '.hasMore, .data[-1].id' /tmp/abc-12-events.json\nconductor --json session message <sessionId> --after <lastEventId> --limit 100\n```\n\nThe second line prints whether more pages exist and the id to continue from. `.content.rawPayload` is the agent's own event format, so the filters depend on the worker's agent (the `agent` of its profile in `armada.toml`).\n\nA `claude` worker: each turn's final reply, then the commands and tools it ran.\n\n```sh\njq -r '.data[] | select(.content.rawPayload.type == \"result\") | .content.rawPayload | \"error=\\(.is_error)\\n\\(.result)\"' /tmp/abc-12-events.json\njq -r '.data[] | select(.content.rawPayload.type == \"assistant\") | .content.rawPayload.message.content[] | select(.type == \"tool_use\") | .input.command // .name' /tmp/abc-12-events.json\n```\n\nA `codex` worker: its events are `.content.rawPayload.event`, each item once as `item.started` and once as `item.completed`; read the completed ones. Its messages (`phase` is `commentary` along the way, `final_answer` at the end of a turn), then each command with its exit code, and its tool calls (Linear and other MCP servers).\n\n```sh\njq -r '.data[] | .content.rawPayload.event | select(.type == \"item.completed\") | .item | select(.type == \"agentMessage\") | \"[\\(.phase)] \\(.text)\"' /tmp/abc-12-events.json\njq -r '.data[] | .content.rawPayload.event | select(.type == \"item.completed\") | .item | select(.type == \"commandExecution\") | \"exit=\\(.exitCode) \\(.command)\"' /tmp/abc-12-events.json\njq -r '.data[] | .content.rawPayload.event | select(.type == \"item.completed\") | .item | select(.type == \"mcpToolCall\") | \"\\(.server) \\(.tool)\"' /tmp/abc-12-events.json\n```\n\nAnother agent, or a filter that prints nothing: count the event types, look at one event of the type you need, and adapt the filter.\n\n```sh\njq -r '.data[].content.rawPayload | .type // .event.type // \"(no payload)\"' /tmp/abc-12-events.json | sort | uniq -c\n```\n\n## Stop and archive\n\n```sh\nconductor --json session cancel <sessionId>\nconductor --json workspace archive <workspaceId>\n```\n\n- `session cancel` stops the running turn: `{\"status\", \"canceledQueuedMessages\"}`, and the session is `idle` within seconds. The workspace stays; a message starts a new turn. Use it on a worker that runs the wrong thing.\n- `workspace archive` answers `{\"status\": \"archived\"}`. Archive a worker's workspace after its pull request is merged, or after `armada release --ticket ABC-12 --reason \"<why>\"` for a worker that stops without handing back. The branch and the pull request stay on GitHub.\n- **Wait for `idle` before archiving.** A hand-back often arrives while the worker's session is still `working`: `armada report ready-to-merge` runs inside its last turn, which then writes its final reply. Archive only once `session status` answers `idle`. Poll it every 15 seconds; if it is still `working` after 10 minutes, cancel the turn and archive (the transcript keeps what it was doing). Run the whole block as one command; it can take up to 10 minutes, so run it in the background or give it a longer command timeout:\n\n```sh\nfor i in $(seq 40); do\n [ \"$(conductor --json session status <sessionId> | jq -r .status)\" = working ] || break\n sleep 15\ndone\n[ \"$(conductor --json session status <sessionId> | jq -r .status)\" = working ] && conductor --json session cancel <sessionId>\nconductor --json workspace archive <workspaceId>\n```\n- After an archive, `session status` still answers `idle`; `workspace status` says `archived`.\n";
5133
5258
 
5134
5259
  // ../../skills/armada-worker/SKILL.md
5135
5260
  var SKILL_default4 = `---
@@ -5143,6 +5268,7 @@ You are a worker. You own exactly one ticket, named in your launch brief. You tu
5143
5268
 
5144
5269
  - **Never merge**, never enable auto-merge, never approve your own plan. The coordinator merges.
5145
5270
  - **Report at least every 15 minutes** of work with \`armada report <phase> --message "<what you are doing>"\`. The same phase is allowed: it is your heartbeat. A worker silent for longer than \`policy.silence_minutes\` shows as silent, and the coordinator comes to check on you.
5271
+ - **Keep going on setup choices.** When setup needs a choice (an install fallback, a retry, a missing tool), pick the safe option, say which in your next report, and keep going: never stop to ask about it. Ask only for product decisions.
5146
5272
  - **Ask instead of guessing** when a choice changes the ticket's outcome: \`armada ask "<question and your recommendation>" --options "<a> | <b>"\`. Your phase becomes \`blocked\` and the question reaches the coordinator's inbox. Then **stop and end your turn**: the answer arrives as a message in this session, not in a command's output. When it arrives, report the phase you resume, for example \`armada report implementing --message "resumed: <the decision>"\`. Decide reversible technical choices yourself and record each one, with its reason, on the ticket and in the pull request.
5147
5273
  - **The ticket is the source of truth.** Read it, its parent spec and the hand-back comments of its merged blockers in full before planning.
5148
5274
  - Work only in your own branch and worktree. Never touch another agent's checkout, and stop only the processes you started.
@@ -5151,7 +5277,7 @@ You are a worker. You own exactly one ticket, named in your launch brief. You tu
5151
5277
 
5152
5278
  ## Steps
5153
5279
 
5154
- 1. **Claim** with the exact commands your brief starts with, for example \`armada claim <ticket> --runtime conductor --handle "$CONDUCTOR_WORKSPACE_ID/$CONDUCTOR_SESSION_ID"\`. Install the Armada version the brief names first; if it gives a fallback command, use it wherever this skill says \`armada\`. When the brief has an \`armada login --launch-token <token>\` line, run it once, right after the install and before the claim: it signs your workspace in to Armada for your ticket only, and Armada then gives your \`claim\`, \`report\`, \`ask\` and \`release\` their keys, so none is needed in your environment (do not ask for one; \`armada whoami\` shows the sign-in). The token works once, within the hour; never copy it anywhere else. If it is refused, or a later command says you were cut off from Armada, stop and say so in your reply: the coordinator decides whether you get a new one. The claim assigns the ticket, moves it to In Progress, sets \`Agent phase = planning\` and your \`Agent runtime\`, and posts the \`Agent claim\` comment. If it refuses because another claim exists, stop: the older claim wins.
5280
+ 1. **Claim** with the exact commands your brief starts with, for example \`armada claim <ticket> --runtime conductor --handle "$CONDUCTOR_WORKSPACE_ID/$CONDUCTOR_SESSION_ID"\`. Install the Armada version the brief names first; if it gives a fallback command, use it wherever this skill says \`armada\`. If neither installs (a version npm does not serve yet), install the newest published one (\`npm install -g @the-vibe-company/armada\`), say so in your first report, and go on. When the brief has an \`armada login --launch-token <token>\` line, run it once, right after the install and before the claim: it signs your workspace in to Armada for your ticket only, and Armada then gives your \`claim\`, \`report\`, \`ask\` and \`release\` their keys, so none is needed in your environment (do not ask for one; \`armada whoami\` shows the sign-in). The token works once, within the hour; never copy it anywhere else. If it is refused, or a later command says you were cut off from Armada, stop and say so in your reply: the coordinator decides whether you get a new one. A token shown as \`armada_launch_••••\` is the masked one of the brief's human view: it signs nobody in, and \`armada login\` says so; ask for the \`armada brief <ticket> --prompt\` text. The claim assigns the ticket, moves it to In Progress, sets \`Agent phase = planning\` and your \`Agent runtime\`, and posts the \`Agent claim\` comment. If it refuses because another claim exists, stop: the older claim wins.
5155
5281
  2. **Branch.** Use the branch named after the ticket (the tracker suggests one, for example \`feature/abc-12-short-title\`), created from the latest default branch.
5156
5282
  3. **Plan.** Write the plan: what changes, how it is tested, and the checks a person could observe when it is done. Your brief's "Plan" section says in one line whether it needs approval (from \`[policy] plans\` in \`armada.toml\`, or a label on the ticket); follow that line, do not guess. Pre-approved: post the plan with \`armada report implementing --plan-file -\` (or \`--plan-file <path>\`) and go on; do not enter \`awaiting-approval\`. Otherwise post it with \`armada report awaiting-approval --plan-file -\`: it creates a \`plan\` item in the coordinator's inbox. \`--plan-file\` posts the plan as its own block, under a one-line status (\`--message\` sets that line, else the plan's first line). Push your branch and wait for the coordinator's decision in your session. On approval, report \`implementing\`; on amendments, report \`planning\`, revise the plan and submit it for approval again.
5157
5283
  4. **Implement** test-first. A material change to the approved plan needs a new approval.
@@ -5181,7 +5307,7 @@ var BUNDLED_SKILLS = [
5181
5307
  { name: "armada-worker", files: [{ path: "SKILL.md", content: SKILL_default4 }] }
5182
5308
  ];
5183
5309
  function skillFolderHash(files) {
5184
- const hash = createHash("sha256");
5310
+ const hash = createHash2("sha256");
5185
5311
  for (const f of [...files].sort((a, b) => a.path.localeCompare(b.path))) {
5186
5312
  hash.update(f.path);
5187
5313
  hash.update(f.content);
@@ -5243,6 +5369,50 @@ function conductorSetup(text) {
5243
5369
  }
5244
5370
  var IGNORES_SHIP = new Set(["plans/ship-pr-dev/", "plans/ship-pr-dev", "plans/", "plans", "plans/*"]);
5245
5371
  var ignoresShipArtifacts = (gitignore) => (gitignore ?? "").split(/\r?\n/).some((l) => IGNORES_SHIP.has(l.trim().replace(/^\//, "")));
5372
+ async function installedHash(view, name) {
5373
+ const folder = await view.readFolder(skillDir(name));
5374
+ return folder?.some((f) => f.path === "SKILL.md") ? skillFolderHash(folder) : null;
5375
+ }
5376
+ function behindOf(lock, differing) {
5377
+ if (!differing.length)
5378
+ return null;
5379
+ const refs = differing.flatMap((name) => {
5380
+ const ref = lock?.skills[name]?.ref;
5381
+ return typeof ref === "string" && /^v\d/.test(ref) ? [ref.slice(1)] : [];
5382
+ }).sort(compareVersions);
5383
+ return { recorded: refs[0] ?? null, newest: refs.at(-1) ?? null, differing };
5384
+ }
5385
+ var ahead = (b, cli) => b.newest && compareVersions(b.newest, cli) > 0 ? b.newest : null;
5386
+ function skillsBehindMessage(b, cli) {
5387
+ const which = `${b.differing.join(", ")} ${b.differing.length === 1 ? "differs" : "differ"}`;
5388
+ const newer = ahead(b, cli);
5389
+ if (newer)
5390
+ return `this project's Armada skills are ${newer} (${which}), newer than the CLI ${cli}`;
5391
+ return `this project's Armada skills are ${b.recorded ?? "of an unrecorded version"} (${which}), the CLI is ${cli}`;
5392
+ }
5393
+ function skillsBehindFix(b, cli) {
5394
+ const newer = ahead(b, cli);
5395
+ return newer ? `update the CLI, not the skills: ${installCommand(newer)}` : "run `armada init` and merge its PR (`armada merge <n> --no-ticket`)";
5396
+ }
5397
+ var skillsBehindLine = (b, cli) => `${skillsBehindMessage(b, cli)}: ${skillsBehindFix(b, cli)}`;
5398
+ async function skillsBehind(view) {
5399
+ let lock;
5400
+ try {
5401
+ lock = parseSkillsLock(await view.readFile(SKILLS_LOCK_FILE));
5402
+ } catch (err) {
5403
+ if (err instanceof SetupError)
5404
+ lock = null;
5405
+ else
5406
+ throw err;
5407
+ }
5408
+ const differing = [];
5409
+ for (const skill of BUNDLED_SKILLS) {
5410
+ const installed = await installedHash(view, skill.name);
5411
+ if (installed !== null && installed !== bundledHash(skill))
5412
+ differing.push(skill.name);
5413
+ }
5414
+ return behindOf(lock, differing);
5415
+ }
5246
5416
  async function checkRepository(view, armadaVersion) {
5247
5417
  const checks = [];
5248
5418
  const configText = await view.readFile(CONFIG_FILE);
@@ -5272,17 +5442,20 @@ async function checkRepository(view, armadaVersion) {
5272
5442
  if (lockError)
5273
5443
  checks.push(bad("skills-lock", "error", lockError, `repair or delete ${SKILLS_LOCK_FILE}`));
5274
5444
  const wholeDir = await linksWholeDir(view);
5445
+ const differing = [];
5446
+ let present = 0;
5275
5447
  for (const skill of BUNDLED_SKILLS) {
5276
- const folder = await view.readFolder(skillDir(skill.name));
5277
- const installed = folder?.some((f) => f.path === "SKILL.md") ? skillFolderHash(folder) : null;
5448
+ const installed = await installedHash(view, skill.name);
5278
5449
  const id = `skill:${skill.name}`;
5279
5450
  if (installed === null) {
5280
5451
  checks.push(bad(id, "error", `skill ${skill.name} is missing from ${AGENTS_SKILLS_DIR}`, "run `armada init`"));
5281
5452
  continue;
5282
5453
  }
5283
- if (installed !== bundledHash(skill))
5454
+ present++;
5455
+ if (installed !== bundledHash(skill)) {
5456
+ differing.push(skill.name);
5284
5457
  checks.push(bad(id, "warning", `skill ${skill.name} differs from the version in Armada ${armadaVersion}`, "run `armada init` to open a pull request that updates it"));
5285
- else
5458
+ } else
5286
5459
  checks.push(ok(id, `skill ${skill.name} is up to date`));
5287
5460
  const target = await view.readLink(linkPath(skill.name));
5288
5461
  const linkId = `skill-link:${skill.name}`;
@@ -5303,6 +5476,11 @@ async function checkRepository(view, armadaVersion) {
5303
5476
  else
5304
5477
  checks.push(ok(lockId, `${SKILLS_LOCK_FILE} records ${skill.name}`));
5305
5478
  }
5479
+ const behind = behindOf(lock, differing);
5480
+ if (behind)
5481
+ checks.push(bad("skills-version", "warning", skillsBehindMessage(behind, armadaVersion), skillsBehindFix(behind, armadaVersion)));
5482
+ else if (present)
5483
+ checks.push(ok("skills-version", `this project's Armada skills match Armada ${armadaVersion}'s`));
5306
5484
  const settings = await view.readFile(CONDUCTOR_SETTINGS);
5307
5485
  if (settings === null)
5308
5486
  checks.push(bad("conductor", "error", `${CONDUCTOR_SETTINGS} is missing`, "run `armada init` to add it with a setup script"));
@@ -5497,6 +5675,7 @@ function buildStatus({
5497
5675
  forgeError = null,
5498
5676
  lastEvents,
5499
5677
  live,
5678
+ launches = [],
5500
5679
  extraWarnings = [],
5501
5680
  now
5502
5681
  }) {
@@ -5548,6 +5727,10 @@ function buildStatus({
5548
5727
  openBlockers: l.openBlockers,
5549
5728
  flags: l.flags
5550
5729
  })),
5730
+ notStarted: notStartedLaunches(launches, now, config.policy.notStartedMinutes).map((l) => {
5731
+ const issue = issues.find((i) => i.id === l.ticket);
5732
+ return { ...l, title: issue?.title ?? null, url: issue?.url ?? null, detail: notStartedBody(l, now) };
5733
+ }),
5551
5734
  frontier: frontier(m, config.tracker.readyLabel).filter((c) => !phaseOf.has(c.issue.id)).map((c) => ({
5552
5735
  id: c.issue.id,
5553
5736
  title: c.issue.title,
@@ -5595,22 +5778,46 @@ async function loadStatus(config, opts) {
5595
5778
  const eventsP = opts.lastEvents ? opts.lastEvents().then((events) => ({ events }), (err) => ({
5596
5779
  warning: `Armada's live data could not be read (${err instanceof Error ? err.message : String(err)}); silence is measured from Linear only`
5597
5780
  })) : Promise.resolve({});
5598
- const [{ program, forge, forgeError }, events] = await Promise.all([readStatusSources(config, opts), eventsP]);
5781
+ const launchesP = opts.launches ? opts.launches().then((launches) => ({ launches }), (err) => ({
5782
+ warning: `Armada's launches could not be read (${err instanceof Error ? err.message : String(err)}); workers launched that never started are not listed`
5783
+ })) : Promise.resolve({});
5784
+ const [{ program, forge, forgeError }, events, launches] = await Promise.all([
5785
+ readStatusSources(config, opts),
5786
+ eventsP,
5787
+ launchesP
5788
+ ]);
5599
5789
  return buildStatus({
5600
5790
  config,
5601
5791
  program,
5602
5792
  forge,
5603
5793
  forgeError,
5604
5794
  ...events.events ? { lastEvents: events.events } : {},
5605
- extraWarnings: events.warning ? [events.warning] : [],
5795
+ ...launches.launches ? { launches: launches.launches } : {},
5796
+ extraWarnings: [events.warning, launches.warning].filter((w) => !!w),
5606
5797
  now: now()
5607
5798
  });
5608
5799
  }
5609
5800
  // package.json
5610
- var version = "0.2.8";
5801
+ var version = "0.2.10";
5611
5802
 
5612
5803
  // src/api.ts
5613
- var apiOf = (io, url, cliVersion = version) => armadaApi({ url, version: cliVersion, ...io.fetch ? { fetch: io.fetch } : {} });
5804
+ var runs = new WeakMap;
5805
+ function heard(io) {
5806
+ let h = runs.get(io);
5807
+ if (!h) {
5808
+ h = { server: null };
5809
+ runs.set(io, h);
5810
+ }
5811
+ return h;
5812
+ }
5813
+ var apiOf = (io, url, cliVersion = version) => armadaApi({
5814
+ url,
5815
+ version: cliVersion,
5816
+ onServerCli: (server) => {
5817
+ heard(io).server = server;
5818
+ },
5819
+ ...io.fetch ? { fetch: io.fetch } : {}
5820
+ });
5614
5821
 
5615
5822
  // src/io.ts
5616
5823
  class UsageError extends Error {
@@ -5934,7 +6141,14 @@ The key is stored in ${p.credentials}.
5934
6141
  `);
5935
6142
  return 0;
5936
6143
  }
6144
+ function sessionHandle(io) {
6145
+ const workspace = io.env.CONDUCTOR_WORKSPACE_ID?.trim();
6146
+ const session = io.env.CONDUCTOR_SESSION_ID?.trim();
6147
+ return workspace && session ? `${workspace}/${session}` : null;
6148
+ }
5937
6149
  async function loginWithLaunchToken(io, credentials, token, apiUrl) {
6150
+ if (isMaskedLaunchToken(token))
6151
+ throw new Refusal(MASKED_LAUNCH_TOKEN_REFUSAL.error, MASKED_LAUNCH_TOKEN_REFUSAL.next);
5938
6152
  const p = paths(io);
5939
6153
  let url = credentials.armadaApi.url;
5940
6154
  if (apiUrl) {
@@ -5943,7 +6157,7 @@ async function loginWithLaunchToken(io, credentials, token, apiUrl) {
5943
6157
  throw new UsageError(`the launch message names ${hostOf(apiUrl)}, but ARMADA_API_URL or [api] url names ${hostOf(url)}`, "unset ARMADA_API_URL, or ask the coordinator for a launch from that Armada");
5944
6158
  url = apiUrl;
5945
6159
  }
5946
- const session = await apiOf(io, url).exchangeLaunchToken(token.trim());
6160
+ const session = await apiOf(io, url).exchangeLaunchToken(token.trim(), sessionHandle(io));
5947
6161
  const w = session.worker;
5948
6162
  await updateCredentialStore(p, {
5949
6163
  [workerSessionVariable(w.ticket)]: formatWorkerSession({
@@ -6075,9 +6289,9 @@ function liveFleet(io, config, credentials) {
6075
6289
  };
6076
6290
  }
6077
6291
  }
6078
- function statusEvents(io, config, credentials) {
6292
+ function statusLive(io, config, credentials) {
6079
6293
  const { fleet } = liveFleet(io, config, credentials);
6080
- return fleet ? () => fleet.lastEventTimes() : undefined;
6294
+ return fleet ? { lastEvents: () => fleet.lastEventTimes(), launches: () => fleet.pendingLaunches() } : undefined;
6081
6295
  }
6082
6296
  function currentTicket(io, config, explicit, workers = []) {
6083
6297
  const fromEnv = io.env.ARMADA_TICKET?.trim();
@@ -6338,6 +6552,7 @@ async function inbox2(io, config, credentials, a) {
6338
6552
  project: config.project.slug,
6339
6553
  coordinator: coordinatorHandle(io),
6340
6554
  silentAfterMinutes: config.policy.silentAfterMinutes,
6555
+ notStartedMinutes: config.policy.notStartedMinutes,
6341
6556
  now: io.now ?? (() => new Date),
6342
6557
  ...wait ? { wait: { timeoutMs, sleep: io.sleep ?? ((ms) => new Promise((done) => setTimeout(done, ms))) } } : {}
6343
6558
  });
@@ -6355,6 +6570,42 @@ async function inbox2(io, config, credentials, a) {
6355
6570
  return 0;
6356
6571
  }
6357
6572
 
6573
+ // src/release.ts
6574
+ var NOTICE_COMMANDS = new Set(["status", "inbox", "watch", "brief", "merge", "doctor"]);
6575
+ function newer(io, running) {
6576
+ const server = heard(io).server;
6577
+ if (io.env.ARMADA_TICKET?.trim() || !server || compareVersions(running, server.minimum) < 0)
6578
+ return null;
6579
+ return newerRelease(running, server.latest);
6580
+ }
6581
+ async function noticedReleases(io) {
6582
+ const paths = machinePaths(io.env);
6583
+ return new Set(paths ? await readNoticedReleases(paths).catch(() => []) : []);
6584
+ }
6585
+ async function rememberRelease(io, version) {
6586
+ const paths = machinePaths(io.env);
6587
+ if (paths)
6588
+ await addNoticedRelease(paths, version).catch(() => {});
6589
+ }
6590
+ async function noticeRelease(io, running) {
6591
+ const latest = newer(io, running);
6592
+ if (!latest || (await noticedReleases(io)).has(latest))
6593
+ return;
6594
+ io.stderr(`armada: ${releaseLine(running, latest)}
6595
+ `);
6596
+ await rememberRelease(io, latest);
6597
+ }
6598
+ function pendingRelease(io, running, seen) {
6599
+ return async () => {
6600
+ const latest = newer(io, running);
6601
+ if (!latest || !machinePaths(io.env) || seen.includes(`version:${latest}`))
6602
+ return null;
6603
+ if ((await noticedReleases(io)).has(latest))
6604
+ return null;
6605
+ return releaseEntry(running, latest, (io.now ?? (() => new Date))());
6606
+ };
6607
+ }
6608
+
6358
6609
  // src/watch.ts
6359
6610
  function coordinatorHandle(io) {
6360
6611
  const workspace = io.env.CONDUCTOR_WORKSPACE_ID?.trim();
@@ -6429,6 +6680,7 @@ async function watchUntil(io, config, credentials, json, configPath) {
6429
6680
  project,
6430
6681
  coordinator: coordinatorHandle(io),
6431
6682
  silentAfterMinutes: config.policy.silentAfterMinutes,
6683
+ notStartedMinutes: config.policy.notStartedMinutes,
6432
6684
  seen: before?.seen ?? [],
6433
6685
  now: io.now ?? (() => new Date),
6434
6686
  sleep: io.sleep ?? ((ms) => new Promise((done) => setTimeout(done, ms))),
@@ -6437,10 +6689,15 @@ async function watchUntil(io, config, credentials, json, configPath) {
6437
6689
  await remember(io, project, { inFlight, readAt: now(io).toISOString() });
6438
6690
  },
6439
6691
  onRetry: (message) => io.stderr(`armada: warning: ${message}
6440
- `)
6692
+ `),
6693
+ release: pendingRelease(io, version, before?.seen ?? [])
6441
6694
  });
6442
6695
  await remember(io, project, shown(io, report.items, report.inFlight));
6443
- const next = rearm({ inFlight: report.inFlight, open: report.items.length, running: null, act: true });
6696
+ for (const e of report.items)
6697
+ if (e.kind === "version" && e.version)
6698
+ await rememberRelease(io, e.version);
6699
+ const open = report.items.filter((e) => e.kind !== "version").length;
6700
+ const next = rearm({ inFlight: report.inFlight, open, running: null, act: true });
6444
6701
  if (json)
6445
6702
  io.stdout(`${JSON.stringify({ ...report, watch: next }, null, 2)}
6446
6703
  `);
@@ -6480,7 +6737,7 @@ async function hookStop(io, rest, findConfig) {
6480
6737
  }
6481
6738
 
6482
6739
  // src/brief.ts
6483
- var HIDDEN_LAUNCH_TOKEN = "armada_launch_••••";
6740
+ var HIDDEN_LAUNCH_TOKEN = MASKED_LAUNCH_TOKEN;
6484
6741
  function hideLaunchToken(b) {
6485
6742
  if (!b.launch)
6486
6743
  return b;
@@ -6576,6 +6833,7 @@ async function brief2(io, config, credentials, a, version, configPath) {
6576
6833
  env: io.env,
6577
6834
  stored: STORED_KEYS.filter((k) => credentials.sources[k.name]?.kind === "store").map((k) => k.variable),
6578
6835
  launch: launcher(io, config, credentials),
6836
+ npm: (v) => checkPublished(v, io.fetch ?? fetch),
6579
6837
  conventions,
6580
6838
  ...io.fetch ? { fetch: io.fetch } : {},
6581
6839
  ...io.now ? { now: io.now } : {}
@@ -7418,10 +7676,10 @@ async function merge2(io, config, credentials, a, configPath) {
7418
7676
  }
7419
7677
 
7420
7678
  // src/render.ts
7421
- var MIN2 = 60000;
7679
+ var MIN3 = 60000;
7422
7680
  function relative2(iso, now) {
7423
7681
  const diff = now - Date.parse(iso);
7424
- const m = Math.round(Math.abs(diff) / MIN2);
7682
+ const m = Math.round(Math.abs(diff) / MIN3);
7425
7683
  const suffix = diff >= 0 ? "ago" : "from now";
7426
7684
  if (m < 1)
7427
7685
  return "just now";
@@ -7450,7 +7708,7 @@ var phaseLabel = (t) => t.phaseSource === "label" ? t.phase : `${t.phase} (${t.p
7450
7708
  function renderStatus(r) {
7451
7709
  const now = Date.parse(r.generatedAt);
7452
7710
  const out = [];
7453
- const idWidth = Math.max(6, ...r.inFlight.map((t) => t.id.length), ...r.frontier.map((t) => t.id.length), ...(r.pullRequests ?? []).map((p) => `#${p.number}`.length));
7711
+ const idWidth = Math.max(6, ...r.inFlight.map((t) => t.id.length), ...r.notStarted.map((l) => l.ticket.length), ...r.frontier.map((t) => t.id.length), ...(r.pullRequests ?? []).map((p) => `#${p.number}`.length));
7454
7712
  const indent = " ".repeat(idWidth + 4);
7455
7713
  const phaseWidth = Math.max(0, ...r.inFlight.map((t) => phaseLabel(t).length));
7456
7714
  out.push(`${r.project.name} · ${r.programRoot.id} ${r.programRoot.title}`);
@@ -7472,6 +7730,15 @@ function renderStatus(r) {
7472
7730
  if (t.flags.length)
7473
7731
  out.push(`${indent}! ${t.flags.join(", ")}`);
7474
7732
  }
7733
+ if (r.notStarted.length) {
7734
+ out.push("", `Launched, not started (${r.notStarted.length})`);
7735
+ for (const l of r.notStarted) {
7736
+ out.push(` ${pad(l.ticket, idWidth)} launched ${relative2(l.launchedAt, now)} · ${l.tokenUsedAt ? `signed in ${relative2(l.tokenUsedAt, now)}, no claim` : "launch token never used"}${l.handle ? ` · ${l.handle}` : ""}`);
7737
+ if (l.title)
7738
+ out.push(`${indent}${truncate(l.title, 90)}`);
7739
+ out.push(`${indent}! check its session with the runtime guide's status section`);
7740
+ }
7741
+ }
7475
7742
  const ready = r.frontier.filter((t) => t.readyForAgent);
7476
7743
  const untriaged = r.frontier.filter((t) => !t.readyForAgent);
7477
7744
  out.push("", `Ready to start (${ready.length})`);
@@ -7569,7 +7836,7 @@ ${"─".repeat(60)}
7569
7836
  // src/secrets.ts
7570
7837
  import { dirname as dirname6, relative as relative3, resolve } from "node:path";
7571
7838
  var NAME_HINT = "upper snake case, e.g. OPENAI_API_KEY";
7572
- var hhmm = (iso) => `${iso.slice(0, 16).replace("T", " ")} UTC`;
7839
+ var hhmm2 = (iso) => `${iso.slice(0, 16).replace("T", " ")} UTC`;
7573
7840
  function signInOf(config, credentials) {
7574
7841
  const signIn = credentials.armadaSignIn;
7575
7842
  if (!signIn)
@@ -7639,7 +7906,7 @@ Next: armada secrets set <NAME> (an owner or admin), or the Keys page of Armada
7639
7906
  const width = Math.max(...secrets.map((s) => s.name.length));
7640
7907
  const lines = [`Secrets for workers of ${p} (names only; values stay in Armada)`];
7641
7908
  for (const s of secrets)
7642
- lines.push(` ${s.name.padEnd(width)} ${s.scope.padEnd(12)} set by ${s.setBy}, ${hhmm(s.setAt)}${s.overridden ? " (the project's own wins)" : ""}`);
7909
+ lines.push(` ${s.name.padEnd(width)} ${s.scope.padEnd(12)} set by ${s.setBy}, ${hhmm2(s.setAt)}${s.overridden ? " (the project's own wins)" : ""}`);
7643
7910
  return `${lines.join(`
7644
7911
  `)}
7645
7912
  `;
@@ -7953,6 +8220,8 @@ Files:
7953
8220
  \`armada login\` (the sign-in: ARMADA_SESSION_TOKEN or ARMADA_API_KEY)
7954
8221
  config.toml personal defaults: language, [dashboard] url, [api] url
7955
8222
  watch/<project>.* the project's watch: its lock, what you were shown, who is in flight
8223
+ releases.json the Armada releases you were told of: a coordinator command says once
8224
+ when a newer one is out (\`armada watch\` ends on it)
7956
8225
  `;
7957
8226
  function commandHelp(command) {
7958
8227
  const block = Object.hasOwn(COMMAND_HELP, command) ? COMMAND_HELP[command] : undefined;
@@ -8095,14 +8364,17 @@ async function status2(io, args) {
8095
8364
  const { linearApiKey, githubToken } = credentials;
8096
8365
  if (!linearApiKey)
8097
8366
  throw missingKey(LINEAR_KEY);
8098
- const events = statusEvents(io, config, credentials);
8367
+ const live = statusLive(io, config, credentials);
8099
8368
  const report = await loadStatus(config, {
8100
8369
  linearApiKey,
8101
8370
  githubToken,
8102
- ...events ? { lastEvents: events } : {},
8371
+ ...live ?? {},
8103
8372
  ...io.fetch ? { fetch: io.fetch } : {},
8104
8373
  ...io.now ? { now: io.now } : {}
8105
8374
  });
8375
+ const behind = await skillsBehind(fsRepoView(dirname7(path))).catch(() => null);
8376
+ if (behind)
8377
+ report.warnings.push(skillsBehindLine(behind, version));
8106
8378
  io.stdout(args.json ? `${JSON.stringify(report, null, 2)}
8107
8379
  ` : renderStatus(report));
8108
8380
  return 0;
@@ -8140,6 +8412,13 @@ function nextStep(err, command) {
8140
8412
  return null;
8141
8413
  }
8142
8414
  async function run(argv, io) {
8415
+ const code = await dispatch(argv, io);
8416
+ const command = commandOf(argv);
8417
+ if (command && NOTICE_COMMANDS.has(command))
8418
+ await noticeRelease(io, version).catch(() => {});
8419
+ return code;
8420
+ }
8421
+ async function dispatch(argv, io) {
8143
8422
  try {
8144
8423
  const args = parseArgs(argv);
8145
8424
  if (args.version) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@the-vibe-company/armada",
3
- "version": "0.2.8",
3
+ "version": "0.2.10",
4
4
  "type": "module",
5
5
  "description": "Run a fleet of coding agents on one project: the armada command line.",
6
6
  "license": "MIT",