crewbus 10.0.7 → 10.0.8
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.
- package/CHANGELOG.md +9 -0
- package/README.md +2 -2
- package/bin/crewbus.js +10 -4
- package/bin/lib/identity.js +55 -0
- package/bin/lib/store.js +1 -1
- package/bin/lib/web.js +252 -49
- package/docs/VERSION_SKEW.md +1 -1
- package/documentation.html +5 -3
- package/index.html +8 -7
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 10.0.8 (2026-10-16)
|
|
4
|
+
|
|
5
|
+
PATCH RELEASE: Launch composer UI refinements & desktop companion. No board-schema change (`board.json` stays v2).
|
|
6
|
+
|
|
7
|
+
- **Streamlined Launch Composer**: Removed explicit worker target UI so all launches default to automatic agent naming (`w-1`, `w-2`, ...).
|
|
8
|
+
- **Clearer agent count stepper**: Renamed 'Count' to 'No. of Agents' with improved tooltips for clarity.
|
|
9
|
+
- **Flattened composer aesthetic**: Removed the box-shadow depth effect on the Launch Composer card for a clean, flat panel style.
|
|
10
|
+
- **Cleaned launch console**: Removed redundant static headers ("Launch & Chat") and introductory welcome message ("CrewBus Studio") for a compact, distraction-free console.
|
|
11
|
+
|
|
3
12
|
## 10.0.7 (2026-10-14)
|
|
4
13
|
|
|
5
14
|
PATCH RELEASE: Design refresh + icon fix. No board-schema change (`board.json` stays v2).
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# crewbus v10.0.
|
|
1
|
+
# crewbus v10.0.8 — DM bus
|
|
2
2
|
|
|
3
3
|
[](https://github.com/eamonpluto/crewbus/actions/workflows/ci.yml)
|
|
4
4
|
|
|
@@ -55,7 +55,7 @@ env overrides below.)
|
|
|
55
55
|
Layout: `board.json`, `agents/<name>.json`, `dm/<recipient>/<id>.json`,
|
|
56
56
|
`delivered/<recipient>/<id>.json` (push markers, written by the plugin).
|
|
57
57
|
|
|
58
|
-
Versions: `package.json` (currently 10.0.
|
|
58
|
+
Versions: `package.json` (currently 10.0.8) is the source of truth for the
|
|
59
59
|
release version. `board.json`'s `version: 2` is the **board schema version**
|
|
60
60
|
(a different number on purpose — do not "align" them). New to the project?
|
|
61
61
|
Start with `docs/QUICKSTART.md` (5 minutes).
|
package/bin/crewbus.js
CHANGED
|
@@ -42,7 +42,7 @@ import { execFileSync, spawn } from "node:child_process";
|
|
|
42
42
|
// at top level so the import graph (store <- everyone; identity <- sync/spawn/
|
|
43
43
|
// mail/groups/channels/web/relay/export) has no evaluation-order hazards.
|
|
44
44
|
import { BOARD_VERSION, BROADCAST_AFTER, MAX_BODY_CHARS, MAX_RECIPIENTS, MAX_SPAWN, VALUE_FLAGS, boardDir, chmodAgentFile, cleanArtifact, cleanBranchPrefix, cleanChannelName, cleanGroupName, cleanPriority, cleanReply, cleanSenderType, cleanSubject, cleanWebName, dirs, ensureBoard, fail, findBoardUpward, getFlag, gitRevForBoard, listJson, newId, optionalAgent, parseDuration, readBoardMeta, readJson, refuseDriveRootBoard, requireBoard, resolveAgent, restArgs, sanitizeName, writeBoardMeta, writeExclusiveJson, writeJson, nextHlc, stampSyncDoc, hlcCompare, SEND_RATE_CAP, SEND_RATE_WINDOW_MS, MAX_FWD_DEPTH, DEDUPE_WINDOW_MS, webErr } from "./lib/store.js";
|
|
45
|
-
import { VALID_ROLES, agentTokenMatches, assertMintWon, authorize, authorizeCheck, checkToken, cleanRole, countAgentRecords, defaultRoleForNew, ensureSender, hashToken, isHashRevoked, mergeAgentDoc, mergeSyncedAgent, mintToken, newSalt, readAgent, readBoardAcl, resolveToken, revokedPathForHash, roleOfRecord, sanitizeAgentForSync, stripAgentSecrets, timingSafeEqualStr, touchAgent, writeAgentFile, writeBoardAcl, isBoardFrozen } from "./lib/identity.js";
|
|
45
|
+
import { VALID_ROLES, agentTokenMatches, assertMintWon, authorize, authorizeCheck, checkToken, cleanRole, countAgentRecords, defaultRoleForNew, ensureLoopbackOperator, ensureSender, hashToken, isHashRevoked, mergeAgentDoc, mergeSyncedAgent, mintToken, newSalt, readAgent, readBoardAcl, resolveToken, revokedPathForHash, roleOfRecord, sanitizeAgentForSync, stripAgentSecrets, timingSafeEqualStr, touchAgent, writeAgentFile, writeBoardAcl, isBoardFrozen } from "./lib/identity.js";
|
|
46
46
|
import { saveTokenFile } from "./lib/tokenfile.js";
|
|
47
47
|
import { CLIENT_TLS, SYNC_LWW, cleanSyncRel, clientInsecureFromArgs, crewSurvey, httpJson, readPemFlag, readSyncState, readTombstones, relayAuthEntries, relayCredFor, relayCredHeaders, setupClientTls, splitByWeight, syncRound, syncWalk, warnInsecureOnce, writeSyncState, writeTombstone, SYNC_SUBS, SYNC_UNION, RELAY_CAPS, SUB_CAP, SUB_CAP_NOTE, tombstoneIdForRel, readSyncDoc } from "./lib/sync.js";
|
|
48
48
|
import { devicePath, isLoopbackHost, newDeviceCred, newPairToken, pairingPath, parseDeviceCred, readDevice, readRelayState, relaySecretFromArgs, remoteSpawn, requireRelayClientCert, requireRelaySecret, requireScope, tryAcquireFence, verifyOidcJwt, writeRelayState, relayStatePath, bearerFromReq, getOidcConfig, getOidcJwks, b64urlDecode, b64urlJson, jwsRawToDer, oidcGetJson, OIDC_SKEW_SEC, OIDC_JWKS_TTL_MS, OIDC_ALG_HASH, OIDC_EC_SIZE, deviceFromReq } from "./lib/relay.js";
|
|
@@ -4386,7 +4386,7 @@ function cmdDoctor(args) {
|
|
|
4386
4386
|
for (const f of found.slice(0, 5)) info(`dead-man: ${f}`);
|
|
4387
4387
|
if (found.length > 5) info(`dead-man: …and ${found.length - 5} more — see spawn-status --all`);
|
|
4388
4388
|
} catch {}
|
|
4389
|
-
if (!local) {
|
|
4389
|
+
if (!local) {
|
|
4390
4390
|
info(`non-local board: skipping project-file checks for ${root}`);
|
|
4391
4391
|
console.log(bad === 0 ? "doctor: healthy" : `doctor: ${bad} problem(s)`);
|
|
4392
4392
|
if (bad > 0) process.exitCode = 1;
|
|
@@ -4511,7 +4511,7 @@ function cmdDoctor(args) {
|
|
|
4511
4511
|
.map((x) => x.name);
|
|
4512
4512
|
if (stale.length > 0) info(`${stale.length} worker(s) with stale pids (presumed dead after reboot): ${stale.slice(0, 5).join(",")}${stale.length > 5 ? "…" : ""} — see spawn-status --all; respawn to reboot`);
|
|
4513
4513
|
} catch {}
|
|
4514
|
-
if (!process.env.CREWBUS_AGENT) info("CREWBUS_AGENT is unset — hooks need it to know who you are");
|
|
4514
|
+
if (!process.env.CREWBUS_AGENT) info("CREWBUS_AGENT is unset — hooks need it to know who you are");
|
|
4515
4515
|
if (!process.env.CREWBUS_TOKEN) info("CREWBUS_TOKEN is unset — sends/reads as a claimed name need it");
|
|
4516
4516
|
try {
|
|
4517
4517
|
const legacy = fs.readdirSync(path.join(root, "agents")).filter((f) => f.endsWith(".json")).map((f) => {
|
|
@@ -4880,8 +4880,14 @@ async function cmdServe(args) {
|
|
|
4880
4880
|
ensureBoardCliShim(d);
|
|
4881
4881
|
const host = getFlag(args, "--host") || "127.0.0.1";
|
|
4882
4882
|
const port = Number(getFlag(args, "--port") || 0);
|
|
4883
|
-
if (!(port >= 0 && port < 65536)) fail("--port must be 0-65535 (0 = random)");
|
|
4884
4883
|
const relaySecret = relaySecretFromArgs(args);
|
|
4884
|
+
// Desktop plug-and-play: loopback boots auto-provision a `lead` operator
|
|
4885
|
+
// identity (first boot only) so the dashboard launch UI works with zero
|
|
4886
|
+
// terminal steps. Relays with an explicit secret are CLI/fleet boards
|
|
4887
|
+
// and do not auto-provision. Non-loopback binds never auto-provision.
|
|
4888
|
+
if (!relaySecret) {
|
|
4889
|
+
try { ensureLoopbackOperator(d, host); } catch {}
|
|
4890
|
+
}
|
|
4885
4891
|
const remote = !isLoopbackHost(host);
|
|
4886
4892
|
const allowRemoteSpawn = args.includes("--allow-remote-spawn");
|
|
4887
4893
|
// Phase 1b: opening remote spawn/kill is admin-gated when a caller identity
|
package/bin/lib/identity.js
CHANGED
|
@@ -404,6 +404,61 @@ export function mergeAgentDoc(prev, patch) {
|
|
|
404
404
|
return base;
|
|
405
405
|
}
|
|
406
406
|
|
|
407
|
+
// Loopback operator auto-provision (desktop plug-and-play):
|
|
408
|
+
// `serve`/`web` on 127.0.0.1 auto-creates a `lead` identity on first boot so
|
|
409
|
+
// the dashboard can launch without any terminal step. First agent on the
|
|
410
|
+
// board becomes admin (see defaultRoleForNew), so this is the board owner.
|
|
411
|
+
// CLI boards are untouched: this only fires when `lead` is missing AND the
|
|
412
|
+
// bind is loopback. Returns { from, token } or null when not applicable.
|
|
413
|
+
export function ensureLoopbackOperator(d, host) {
|
|
414
|
+
const loop = String(host || "127.0.0.1");
|
|
415
|
+
if (loop !== "127.0.0.1" && loop !== "localhost" && loop !== "::1") return null;
|
|
416
|
+
let rec = null;
|
|
417
|
+
try { rec = readAgent(d, "lead"); } catch { rec = null; }
|
|
418
|
+
if (rec && (rec.tokenHash || rec.token)) return null; // already provisioned
|
|
419
|
+
if (countAgentRecords(d) > 0) return null; // board already has registered agents
|
|
420
|
+
const fresh = mintToken();
|
|
421
|
+
const salt = newSalt();
|
|
422
|
+
const now = new Date().toISOString();
|
|
423
|
+
let prev = null;
|
|
424
|
+
try { prev = readJson(path.join(d.agents, "lead.json")); } catch { prev = null; }
|
|
425
|
+
const { v, hlc } = stampSyncDoc(prev);
|
|
426
|
+
const doc = mergeAgentDoc(prev, {
|
|
427
|
+
name: "lead",
|
|
428
|
+
firstSeen: (prev && prev.firstSeen) || now,
|
|
429
|
+
lastSeen: now,
|
|
430
|
+
tokenHash: hashToken(fresh, salt),
|
|
431
|
+
salt,
|
|
432
|
+
revokedAt: undefined,
|
|
433
|
+
offboarded: undefined,
|
|
434
|
+
role: "admin",
|
|
435
|
+
v, hlc,
|
|
436
|
+
});
|
|
437
|
+
// Atomic first-claim: exactly one boot may win. Losers re-read below.
|
|
438
|
+
let won = false;
|
|
439
|
+
try {
|
|
440
|
+
if (!prev) {
|
|
441
|
+
won = writeExclusiveJson(path.join(d.agents, "lead.json"), doc);
|
|
442
|
+
} else {
|
|
443
|
+
writeAgentFile(d, "lead", doc);
|
|
444
|
+
won = true;
|
|
445
|
+
}
|
|
446
|
+
} catch { won = false; }
|
|
447
|
+
if (!won && !prev) {
|
|
448
|
+
// Lost the race (parallel boot): read the winner, no token to return.
|
|
449
|
+
return null;
|
|
450
|
+
}
|
|
451
|
+
if (won) {
|
|
452
|
+
try { chmodAgentFile(path.join(d.agents, "lead.json")); } catch {}
|
|
453
|
+
try {
|
|
454
|
+
fs.mkdirSync(path.join(d.root, "logs"), { recursive: true });
|
|
455
|
+
fs.writeFileSync(path.join(d.root, "logs", "lead.token"), fresh + "\n", "utf8");
|
|
456
|
+
try { fs.chmodSync(path.join(d.root, "logs", "lead.token"), 0o600); } catch {}
|
|
457
|
+
} catch {}
|
|
458
|
+
}
|
|
459
|
+
return won ? { from: "lead", token: fresh } : null;
|
|
460
|
+
}
|
|
461
|
+
|
|
407
462
|
export function touchAgent(d, name, extra) { // line 2647
|
|
408
463
|
const p = path.join(d.agents, `${name}.json`);
|
|
409
464
|
const now = new Date().toISOString();
|
package/bin/lib/store.js
CHANGED
|
@@ -123,7 +123,7 @@ export function dirs(root) { // line 122
|
|
|
123
123
|
|
|
124
124
|
export function ensureBoard(root) { // line 142
|
|
125
125
|
const d = dirs(root);
|
|
126
|
-
for (const p of [d.root, d.agents, d.dm, d.delivered, d.broadcast, d.groups, d.channels, d.locks, d.results, d.tombstones, d.poolState, d.workerSessions, d.index, d.cursors, d.revoked, d.holds]) {
|
|
126
|
+
for (const p of [d.root, d.agents, d.dm, d.delivered, d.broadcast, d.groups, d.channels, d.locks, d.results, d.tombstones, d.poolState, d.workerSessions, d.index, d.cursors, d.revoked, d.holds, path.join(root, "logs")]) {
|
|
127
127
|
fs.mkdirSync(p, { recursive: true });
|
|
128
128
|
}
|
|
129
129
|
const metaPath = path.join(d.root, "board.json");
|
package/bin/lib/web.js
CHANGED
|
@@ -16,14 +16,15 @@ import fs from "node:fs";
|
|
|
16
16
|
import path from "node:path";
|
|
17
17
|
import http from "node:http";
|
|
18
18
|
import { fileURLToPath } from "node:url";
|
|
19
|
-
import { boardDir, requireBoard, getFlag, fail, writeJson, listJson, cleanWebName, readJson, gitRevForBoard, newId, MAX_SPAWN, MAX_BODY_CHARS } from "./store.js";
|
|
20
|
-
import { readAgent, agentTokenMatches, authorizeCheck, mintToken, newSalt, hashToken, touchAgent } from "./identity.js";
|
|
19
|
+
import { boardDir, requireBoard, getFlag, fail, writeJson, listJson, cleanWebName, readJson, readBoardMeta, writeBoardMeta, gitRevForBoard, newId, MAX_SPAWN, MAX_BODY_CHARS } from "./store.js";
|
|
20
|
+
import { readAgent, agentTokenMatches, authorizeCheck, ensureLoopbackOperator, mintToken, newSalt, hashToken, touchAgent } from "./identity.js";
|
|
21
21
|
import { readDMs, readVisible, ackedIds, ackedIdSet, findMessageById, deliverDMs, parseRecipients } from "./mail.js";
|
|
22
22
|
import { workerStatus, pidAlive, killWorkers, bootWorker, buildSpawnPrompt, buildSpawnTarget, formatSpawnCmd, installCliToUserPath, ensureBoardCliShim } from "./spawn.js";
|
|
23
23
|
import { groupTelemetryData, collectBatch, gatherTelemetry, listBatches } from "./groups.js";
|
|
24
24
|
import { httpJson } from "./sync.js";
|
|
25
25
|
import { readChainRecords, verifyChainRecords, appendChainRecord, readHold, readBoardQuotas } from "./export.js";
|
|
26
|
-
import { launchDrivers, detectHarnessBinaries, validateLaunchPlan, advertiseEnv, HARNESS_MODELS, getDiscoveredModels, refreshDiscoveredModels } from "./launch.js";
|
|
26
|
+
import { launchDrivers, detectHarnessBinaries, validateLaunchPlan, advertiseEnv, buildPairUrl, HARNESS_MODELS, getDiscoveredModels, refreshDiscoveredModels } from "./launch.js";
|
|
27
|
+
import { newPairToken, pairingPath, readRelayState } from "./relay.js";
|
|
27
28
|
|
|
28
29
|
export function escapeHtml(s) {
|
|
29
30
|
return String(s === undefined || s === null ? "" : s).replace(/[&<>"']/g, (c) => ({
|
|
@@ -424,8 +425,9 @@ export function renderBoardHtml(boardPath) {
|
|
|
424
425
|
--panel:#ffffff;
|
|
425
426
|
--ink:#14201a;
|
|
426
427
|
--dim:#5b6a62;
|
|
427
|
-
--acc:#
|
|
428
|
+
--acc:#5b6a62;
|
|
428
429
|
--acc-ink:#ffffff;
|
|
430
|
+
--ok:#3d8f66;
|
|
429
431
|
--warn:#b86e00;
|
|
430
432
|
--line:#d5ddd7;
|
|
431
433
|
--code:#0f1419;
|
|
@@ -444,13 +446,13 @@ export function renderBoardHtml(boardPath) {
|
|
|
444
446
|
--radius-lg:12px;
|
|
445
447
|
}
|
|
446
448
|
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]){
|
|
447
|
-
--bg:#0f1419;--panel:#182028;--ink:#e3e9ee;--dim:#8b98a5;--acc:#
|
|
449
|
+
--bg:#0f1419;--panel:#182028;--ink:#e3e9ee;--dim:#8b98a5;--acc:#8b98a5;--acc-ink:#07130d;--ok:#4fb07f;--warn:#ffb454;--line:#2a343e;--code:#0b0f14;
|
|
448
450
|
--bg-card-hover:#222d37;
|
|
449
451
|
--warn-bg:#241b0e;
|
|
450
452
|
--scroll:rgba(255,255,255,.16);
|
|
451
453
|
--scroll-hi:rgba(255,255,255,.32);
|
|
452
454
|
}}
|
|
453
|
-
:root[data-theme="dark"]{--bg:#0f1419;--panel:#182028;--ink:#e3e9ee;--dim:#8b98a5;--acc:#
|
|
455
|
+
:root[data-theme="dark"]{--bg:#0f1419;--panel:#182028;--ink:#e3e9ee;--dim:#8b98a5;--acc:#8b98a5;--acc-ink:#07130d;--ok:#4fb07f;--warn:#ffb454;--line:#2a343e;--code:#0b0f14;--bg-card-hover:#222d37;--warn-bg:#241b0e;--scroll:rgba(255,255,255,.16);--scroll-hi:rgba(255,255,255,.32)}
|
|
454
456
|
*{box-sizing:border-box}
|
|
455
457
|
* {
|
|
456
458
|
scrollbar-width: thin;
|
|
@@ -575,6 +577,10 @@ button:disabled{opacity:.4;cursor:default}
|
|
|
575
577
|
|
|
576
578
|
/* Log and terminal boxes */
|
|
577
579
|
.log{font-family:var(--mono);font-size:11px;white-space:pre-wrap;background:var(--code);padding:8px 12px;border-radius:var(--radius-sm);border:1px solid var(--line);color:var(--code-ink);max-height:250px;overflow-y:auto}
|
|
580
|
+
/* Launch output is empty until an action writes to it — hide the black
|
|
581
|
+
terminal box entirely when blank instead of showing an empty bar. */
|
|
582
|
+
#launch-out:empty{display:none}
|
|
583
|
+
#chat-events:empty,#launch-diff:empty{display:none}
|
|
578
584
|
|
|
579
585
|
/* Chat Thread & Launch UI */
|
|
580
586
|
.thread-hero{margin-bottom:16px;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px}
|
|
@@ -587,7 +593,7 @@ button:disabled{opacity:.4;cursor:default}
|
|
|
587
593
|
.chat-time{color:var(--dim)}
|
|
588
594
|
|
|
589
595
|
/* Composer / Launch Box */
|
|
590
|
-
.composer-card{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius-lg);padding:16px;margin-top:16px
|
|
596
|
+
.composer-card{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius-lg);padding:16px;margin-top:16px}
|
|
591
597
|
.composer-harness-bar{margin-bottom:12px}
|
|
592
598
|
.harness-pills{display:flex;gap:8px;flex-wrap:wrap}
|
|
593
599
|
.harness-card{display:flex;flex-direction:column;gap:2px;padding:8px 12px;background:var(--panel);border:1px solid var(--line);border-radius:var(--radius-md);cursor:pointer;transition:all .15s ease;min-width:110px}
|
|
@@ -662,7 +668,10 @@ details.tech-details summary{cursor:pointer;font-weight:500;user-select:none}
|
|
|
662
668
|
<div class="pop-label" style="margin-top:10px">Workspace Board (Bus DB)</div>
|
|
663
669
|
<div class="pop-path" id="pop-board-path">${e(boardPath)}</div>
|
|
664
670
|
<button type="button" id="copy-board-btn" class="pop-btn"><svg class="btn-ic" width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="9" y="9" width="13" height="13" rx="2" ry="2"/><path d="M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"/></svg> Copy Board Path</button>
|
|
665
|
-
<button type="button" class="pop-btn" id="
|
|
671
|
+
<button type="button" class="pop-btn" id="switch-board-btn" title="Use another folder's board (e.g. a CLI project): restarts the sidecar against <folder>/.crewbus"><svg class="btn-ic" width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="16 3 21 3 21 8"/><line x1="4" y1="20" x2="21" y2="3"/><polyline points="21 16 21 21 16 21"/><line x1="15" y1="15" x2="21" y2="21"/></svg> Switch Board…</button>
|
|
672
|
+
<button type="button" class="pop-btn" id="reset-board-btn" title="Back to the default desktop board"> Use Default Board</button>
|
|
673
|
+
<div class="pop-path dim" id="board-switch-msg" style="display:none"></div>
|
|
674
|
+
<button type="button" class="pop-btn" id="pop-pair-btn" style="margin-top:8px" title="One-click: mints a one-time pairing link and shows the QR automatically"><svg class="btn-ic" width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="5" y="2" width="14" height="20" rx="2" ry="2"/><line x1="12" y1="18" x2="12.01" y2="18"/></svg> Pair Mobile Client (QR)…</button>
|
|
666
675
|
<button type="button" class="pop-btn" id="pop-install-cli-btn" style="margin-top:8px"><svg class="btn-ic" width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="4 17 10 11 4 5"/><line x1="12" y1="19" x2="20" y2="19"/></svg> Install 'crewbus' CLI in PATH</button>
|
|
667
676
|
</div>
|
|
668
677
|
</div>
|
|
@@ -732,24 +741,13 @@ details.tech-details summary{cursor:pointer;font-weight:500;user-select:none}
|
|
|
732
741
|
</header>
|
|
733
742
|
|
|
734
743
|
<main id="view-container">
|
|
735
|
-
<!-- SECTION: LAUNCH
|
|
744
|
+
<!-- SECTION: LAUNCH CONSOLE -->
|
|
736
745
|
<section id="sec-launch" data-section="Launch">
|
|
737
|
-
<div class="thread-hero">
|
|
738
|
-
<div>
|
|
739
|
-
<h2 style="margin:0">Launch & Chat</h2>
|
|
740
|
-
<div class="dim">Orchestrate coding agents with safety previews and real-time execution</div>
|
|
741
|
-
</div>
|
|
746
|
+
<div class="thread-hero" style="justify-content:flex-end">
|
|
742
747
|
<div id="routes-line" class="routes-badge">routes: loading…</div>
|
|
743
748
|
</div>
|
|
744
749
|
|
|
745
750
|
<div class="chat-stream" id="chat-feed">
|
|
746
|
-
<div class="chat-msg system">
|
|
747
|
-
<div class="chat-header">
|
|
748
|
-
<span class="chat-author">CrewBus Studio</span>
|
|
749
|
-
<span class="chat-time">Active</span>
|
|
750
|
-
</div>
|
|
751
|
-
<div>Ready to dispatch autonomous coding agents for <code>${e(boardPath)}</code>. Configure your task below and preview execution plans before live boot.</div>
|
|
752
|
-
</div>
|
|
753
751
|
<div id="chat-events"></div>
|
|
754
752
|
<div id="launch-diff"></div>
|
|
755
753
|
<div id="launch-out" class="log"></div>
|
|
@@ -763,13 +761,12 @@ details.tech-details summary{cursor:pointer;font-weight:500;user-select:none}
|
|
|
763
761
|
</div>
|
|
764
762
|
|
|
765
763
|
<div class="composer-config-row">
|
|
766
|
-
<
|
|
767
|
-
<
|
|
768
|
-
<span class="dim">Count:</span>
|
|
764
|
+
<input id="launch-to" type="hidden" value="">
|
|
765
|
+
<span class="dim">No. of Agents:</span>
|
|
769
766
|
<div class="stepper-wrap">
|
|
770
|
-
<button id="launch-count-minus" type="button" title="fewer
|
|
771
|
-
<input id="launch-count" size="2" value="1">
|
|
772
|
-
<button id="launch-count-plus" type="button" title="more
|
|
767
|
+
<button id="launch-count-minus" type="button" title="fewer agents">−</button>
|
|
768
|
+
<input id="launch-count" size="2" value="1" title="Number of agents">
|
|
769
|
+
<button id="launch-count-plus" type="button" title="more agents">+</button>
|
|
773
770
|
</div>
|
|
774
771
|
<span class="dim" style="margin-left:8px">Model:</span>
|
|
775
772
|
<select id="launch-model" style="background:var(--panel);color:var(--ink);border:1px solid var(--line);border-radius:4px;padding:3px 8px;font-size:12px">
|
|
@@ -803,10 +800,16 @@ details.tech-details summary{cursor:pointer;font-weight:500;user-select:none}
|
|
|
803
800
|
</div>
|
|
804
801
|
|
|
805
802
|
<div class="composer-bottom">
|
|
806
|
-
<div class="launch-identity">
|
|
807
|
-
|
|
808
|
-
|
|
803
|
+
<div class="launch-identity" title="Desktop launches as the board owner (auto-provisioned) — no token step needed">
|
|
804
|
+
<span class="dim">launching as <b id="launch-as">lead</b> (auto)</span>
|
|
805
|
+
<input id="launch-from" type="hidden" value="">
|
|
806
|
+
<input id="launch-token" type="password" style="display:none" value="">
|
|
809
807
|
</div>
|
|
808
|
+
<details class="tech-details" id="launch-identity-advanced" style="margin:0">
|
|
809
|
+
<summary class="dim" style="cursor:pointer;font-size:11px">advanced: use a different identity</summary>
|
|
810
|
+
<span class="dim" style="font-size:11px">from <input id="launch-from-manual" size="10" placeholder="agent name"></span>
|
|
811
|
+
<span class="dim" style="font-size:11px">token <input id="launch-token-manual" type="password" size="14" placeholder="abt-…"></span>
|
|
812
|
+
</details>
|
|
810
813
|
<div class="launch-actions">
|
|
811
814
|
<button id="launch-preview" type="button">Preview Plan</button>
|
|
812
815
|
<button id="launch-go" type="button" class="btn-launch danger">Launch Agents</button>
|
|
@@ -1001,6 +1004,13 @@ function markIdent(){
|
|
|
1001
1004
|
if(lf&&!lf.value&&c.from)lf.value=c.from;
|
|
1002
1005
|
var lt=document.getElementById('launch-token');
|
|
1003
1006
|
if(lt&&!lt.value&&c.token)lt.value=c.token;
|
|
1007
|
+
// Auto badge: reflect the effective launch identity (auto lead unless the
|
|
1008
|
+
// user typed a manual override in the advanced disclosure).
|
|
1009
|
+
try{
|
|
1010
|
+
var man=document.getElementById('launch-from-manual');
|
|
1011
|
+
var lbl=document.getElementById('launch-as');
|
|
1012
|
+
if(lbl)lbl.textContent=(man&&man.value.trim())||lf.value.trim()||c.from||'lead';
|
|
1013
|
+
}catch(_){}
|
|
1004
1014
|
}
|
|
1005
1015
|
async function autoLoadOperatorCreds(){
|
|
1006
1016
|
var lf=document.getElementById('launch-from');
|
|
@@ -1015,11 +1025,15 @@ async function autoLoadOperatorCreds(){
|
|
|
1015
1025
|
if(r.ok){
|
|
1016
1026
|
var j=await r.json();
|
|
1017
1027
|
if(j.ok&&j.from&&j.token){
|
|
1018
|
-
if(lf
|
|
1019
|
-
if(lt
|
|
1028
|
+
if(lf)lf.value=j.from;
|
|
1029
|
+
if(lt)lt.value=j.token;
|
|
1020
1030
|
if(who&&!who.value)who.value=j.from;
|
|
1021
1031
|
if(tok&&!tok.value)tok.value=j.token;
|
|
1022
|
-
|
|
1032
|
+
// NOTE: no localStorage write for the auto operator token.
|
|
1033
|
+
// The desktop sidecar binds --port 0 (random), so the origin
|
|
1034
|
+
// (127.0.0.1:PORT) changes every launch and per-origin
|
|
1035
|
+
// localStorage is wiped anyway. The server is the source of
|
|
1036
|
+
// truth: every launch re-fetches from /api/operator-creds.
|
|
1023
1037
|
markIdent();
|
|
1024
1038
|
}
|
|
1025
1039
|
}
|
|
@@ -1029,10 +1043,14 @@ async function autoLoadOperatorCreds(){
|
|
|
1029
1043
|
function say(t){document.getElementById('result').textContent=t;}
|
|
1030
1044
|
document.getElementById('save').onclick=function(){var c=creds();try{localStorage.setItem('ab-who',c.from);localStorage.setItem('ab-tok',c.token);}catch(e){}markIdent();say('identity saved in this tab');};
|
|
1031
1045
|
try{document.getElementById('who').value=localStorage.getItem('ab-who')||'';document.getElementById('tok').value=localStorage.getItem('ab-tok')||'';}catch(e){}markIdent();
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1046
|
+
try{
|
|
1047
|
+
// Manual-override fields mirror into Settings identity (two-way sync),
|
|
1048
|
+
// same as the old visible from+token row did.
|
|
1049
|
+
var _mf=document.getElementById('launch-from-manual');
|
|
1050
|
+
var _mt=document.getElementById('launch-token-manual');
|
|
1051
|
+
if(_mf){_mf.oninput=function(){var w=document.getElementById('who');if(w&&!w.value)w.value=this.value.trim();markIdent();};}
|
|
1052
|
+
if(_mt){_mt.oninput=function(){var t=document.getElementById('tok');if(t&&!t.value)t.value=this.value.trim();markIdent();};}
|
|
1053
|
+
}catch(_){}
|
|
1036
1054
|
autoLoadOperatorCreds();
|
|
1037
1055
|
function stateOf(w){if(!w.known)return 'unknown';if(w.reply)return w.acked?'done · acked':'done · reply waiting';if(w.alive===true)return 'running';if(w.alive===false)return 'exited · no reply';return 'no pid';}
|
|
1038
1056
|
var _fq=document.getElementById('feed-q');
|
|
@@ -1241,7 +1259,7 @@ async function refresh(){
|
|
|
1241
1259
|
Array.prototype.forEach.call(document.querySelectorAll('[data-approve]'),function(b){b.onclick=function(){decide(b.getAttribute('data-approve'),'approved');};});
|
|
1242
1260
|
Array.prototype.forEach.call(document.querySelectorAll('[data-deny]'),function(b){b.onclick=function(){decide(b.getAttribute('data-deny'),'denied');};});
|
|
1243
1261
|
refreshLaunchMeta();
|
|
1244
|
-
try{var _cd=document.getElementById('conn-dot');if(_cd){_cd.style.color='
|
|
1262
|
+
try{var _cd=document.getElementById('conn-dot');if(_cd){_cd.style.color='var(--ok)';_cd.title='connected: last poll ok';}}catch(_){}
|
|
1245
1263
|
}catch(e){try{var _cd2=document.getElementById('conn-dot');if(_cd2){_cd2.style.color='#f85149';_cd2.title='poll failed';}}catch(_){}say('refresh failed: '+e.message);}
|
|
1246
1264
|
}
|
|
1247
1265
|
async function ackOne(id){
|
|
@@ -1408,15 +1426,31 @@ if(_refBtn){
|
|
|
1408
1426
|
}
|
|
1409
1427
|
async function doLaunch(dry){
|
|
1410
1428
|
var out=document.getElementById('launch-out');
|
|
1411
|
-
|
|
1412
|
-
|
|
1429
|
+
// Identity resolution: advanced manual override wins, else hidden
|
|
1430
|
+
// auto fields (populated from /api/operator-creds), else Settings creds.
|
|
1431
|
+
// Manual fields live in the "advanced" disclosure so non-technical users
|
|
1432
|
+
// never see a token step.
|
|
1433
|
+
function launchCreds(){
|
|
1434
|
+
var manFrom=document.getElementById('launch-from-manual');
|
|
1435
|
+
var manTok=document.getElementById('launch-token-manual');
|
|
1436
|
+
var mf=manFrom?manFrom.value.trim():'';
|
|
1437
|
+
var mt=manTok?manTok.value:'';
|
|
1438
|
+
if(mf||mt) return {from:mf,token:mt};
|
|
1439
|
+
return {
|
|
1440
|
+
from:document.getElementById('launch-from').value.trim()||creds().from,
|
|
1441
|
+
token:document.getElementById('launch-token').value||creds().token
|
|
1442
|
+
};
|
|
1443
|
+
}
|
|
1444
|
+
var lc=launchCreds();
|
|
1445
|
+
var lf=lc.from, lt=lc.token;
|
|
1413
1446
|
if(!lf||!lt){
|
|
1414
1447
|
await autoLoadOperatorCreds();
|
|
1415
|
-
|
|
1416
|
-
lt=
|
|
1448
|
+
lc=launchCreds();
|
|
1449
|
+
lf=lc.from; lt=lc.token;
|
|
1417
1450
|
}
|
|
1418
|
-
if(!lf||!lt){out.textContent='
|
|
1419
|
-
var
|
|
1451
|
+
if(!lf||!lt){out.textContent='starting up — identity not ready yet, retry in a moment';return;}
|
|
1452
|
+
var toEl=document.getElementById('launch-to');
|
|
1453
|
+
var to=toEl?toEl.value.trim():'';
|
|
1420
1454
|
var count=Number(document.getElementById('launch-count').value)||1;
|
|
1421
1455
|
var selectedHarnesses = window.__selectedHarnesses && window.__selectedHarnesses.size ? Array.from(window.__selectedHarnesses) : (document.getElementById('launch-harness').value || 'claude').split(',').map(function(s){return s.trim();}).filter(Boolean);
|
|
1422
1456
|
if(!selectedHarnesses.length)selectedHarnesses=['claude'];
|
|
@@ -1587,7 +1621,7 @@ function paletteActivate(m){
|
|
|
1587
1621
|
else if(m.action==='copyboard'){copyBoardPath();}
|
|
1588
1622
|
else if(m.action==='openfolder'){document.getElementById('open-folder-btn').click();}
|
|
1589
1623
|
else if(m.action==='pairmobile'){
|
|
1590
|
-
try{window.parent.postMessage({type:'crewbus:open-pair'},'*');}catch(_){}
|
|
1624
|
+
try{window.parent.postMessage({type:'crewbus:open-pair', dashboard: location.origin},'*');}catch(_){}
|
|
1591
1625
|
try{window.open('./pair.html','_blank','width=420,height=560');}catch(_){}
|
|
1592
1626
|
}
|
|
1593
1627
|
else if(m.action==='refresh'){refresh();}
|
|
@@ -1819,7 +1853,7 @@ function copyBoardPath(){
|
|
|
1819
1853
|
document.getElementById('copy-board-btn').onclick=copyBoardPath;
|
|
1820
1854
|
var ppb=document.getElementById('pop-pair-btn');
|
|
1821
1855
|
if(ppb){ppb.onclick=function(){
|
|
1822
|
-
try{window.parent.postMessage({type:'crewbus:open-pair'},'*');}catch(_){}
|
|
1856
|
+
try{window.parent.postMessage({type:'crewbus:open-pair', dashboard: location.origin},'*');}catch(_){}
|
|
1823
1857
|
try{window.open('./pair.html','_blank','width=420,height=560');}catch(_){}
|
|
1824
1858
|
};}
|
|
1825
1859
|
var picb=document.getElementById('pop-install-cli-btn');
|
|
@@ -1880,6 +1914,11 @@ function applyTargetCwd(pathStr, notify){
|
|
|
1880
1914
|
}
|
|
1881
1915
|
if(pathStr){
|
|
1882
1916
|
try{localStorage.setItem('crewbus_last_cwd',pathStr);}catch(_){}
|
|
1917
|
+
// Server-side memory: survives the desktop random-port origin wipe.
|
|
1918
|
+
// Fire-and-forget (local apply above already updated the UI).
|
|
1919
|
+
try{
|
|
1920
|
+
fetch('/api/workspace',{method:'POST',headers:{'content-type':'application/json'},body:JSON.stringify({cwd:pathStr})}).catch(function(){});
|
|
1921
|
+
}catch(_){}
|
|
1883
1922
|
if(notify)say('Target codebase set to: '+pathStr);
|
|
1884
1923
|
}
|
|
1885
1924
|
}
|
|
@@ -1910,12 +1949,86 @@ async function promptOrSelectProjectFolder(){
|
|
|
1910
1949
|
document.getElementById('open-folder-btn').onclick=promptOrSelectProjectFolder;
|
|
1911
1950
|
var lcBrowse=document.getElementById('launch-cwd-browse');
|
|
1912
1951
|
if(lcBrowse)lcBrowse.onclick=promptOrSelectProjectFolder;
|
|
1952
|
+
// Phase-2 board switching (desktop): use another folder's board.
|
|
1953
|
+
// Under Tauri this invokes the switch_board command (validated restart);
|
|
1954
|
+
// everywhere else (plain crewbus web) it explains the CLI equivalent.
|
|
1955
|
+
// After a switch the iframe reloads (new random port) and the operator
|
|
1956
|
+
// token is re-fetched from the NEW board via /api/operator-creds.
|
|
1957
|
+
function boardSwitchMsg(t, isErr){
|
|
1958
|
+
var m=document.getElementById('board-switch-msg');
|
|
1959
|
+
if(!m)return;
|
|
1960
|
+
m.style.display=t?'block':'none';
|
|
1961
|
+
m.textContent=t||'';
|
|
1962
|
+
m.style.color=isErr?'var(--danger)':'var(--dim)';
|
|
1963
|
+
}
|
|
1964
|
+
async function doSwitchBoard(folderPath){
|
|
1965
|
+
var folder=String(folderPath||'').trim();
|
|
1966
|
+
if(!folder){
|
|
1967
|
+
folder=prompt('Switch board: enter the project folder (uses <folder>/.crewbus) or board dir directly:','');
|
|
1968
|
+
if(!folder||!folder.trim())return;
|
|
1969
|
+
folder=folder.trim();
|
|
1970
|
+
}
|
|
1971
|
+
try{
|
|
1972
|
+
var invoke=window.__TAURI__&&window.__TAURI__.core&&window.__TAURI__.core.invoke;
|
|
1973
|
+
if(typeof invoke!=='function'){
|
|
1974
|
+
boardSwitchMsg('Board switching needs the desktop app. CLI equivalent: crewbus serve --board '+folder+'/.crewbus',true);
|
|
1975
|
+
return;
|
|
1976
|
+
}
|
|
1977
|
+
boardSwitchMsg('Switching board — restarting sidecar…');
|
|
1978
|
+
var res=await invoke('switch_board',{path:folder});
|
|
1979
|
+
var board=(res&&res.board)||folder;
|
|
1980
|
+
boardSwitchMsg('Board switched to '+board+' — reloading…');
|
|
1981
|
+
// Clear per-origin identity: the new board has its own lead token.
|
|
1982
|
+
try{
|
|
1983
|
+
var lf=document.getElementById('launch-from');if(lf)lf.value='';
|
|
1984
|
+
var lt=document.getElementById('launch-token');if(lt)lt.value='';
|
|
1985
|
+
}catch(_){}
|
|
1986
|
+
setTimeout(function(){location.reload();},1200);
|
|
1987
|
+
}catch(e){
|
|
1988
|
+
boardSwitchMsg('Switch failed: '+String((e&&e.message)||e||e),true);
|
|
1989
|
+
}
|
|
1990
|
+
}
|
|
1991
|
+
var swBtn=document.getElementById('switch-board-btn');
|
|
1992
|
+
if(swBtn)swBtn.onclick=function(){doSwitchBoard('');};
|
|
1993
|
+
var rsBtn=document.getElementById('reset-board-btn');
|
|
1994
|
+
if(rsBtn)rsBtn.onclick=function(){
|
|
1995
|
+
// Reset = switch back via board_status defaultBoard (no hardcoded path).
|
|
1996
|
+
try{
|
|
1997
|
+
var invoke=window.__TAURI__&&window.__TAURI__.core&&window.__TAURI__.core.invoke;
|
|
1998
|
+
if(typeof invoke!=='function'){boardSwitchMsg('Reset needs the desktop app.',true);return;}
|
|
1999
|
+
boardSwitchMsg('Reading default board…');
|
|
2000
|
+
invoke('board_status').then(function(st){
|
|
2001
|
+
if(st&&st.defaultBoard)doSwitchBoard(st.defaultBoard);
|
|
2002
|
+
else boardSwitchMsg('No default board reported',true);
|
|
2003
|
+
}).catch(function(e){boardSwitchMsg('Reset failed: '+String((e&&e.message)||e),true);});
|
|
2004
|
+
}catch(e){boardSwitchMsg('Reset failed: '+String((e&&e.message)||e),true);}
|
|
2005
|
+
};
|
|
1913
2006
|
var lcInp=document.getElementById('launch-cwd');
|
|
1914
2007
|
if(lcInp)lcInp.oninput=function(){applyTargetCwd(this.value,false);};
|
|
1915
2008
|
try{
|
|
1916
2009
|
var lastCwd=localStorage.getItem('crewbus_last_cwd');
|
|
1917
2010
|
if(lastCwd){applyTargetCwd(lastCwd,false);}
|
|
1918
2011
|
}catch(_){}
|
|
2012
|
+
// Server memory wins over stale/absent localStorage: the desktop origin
|
|
2013
|
+
// (127.0.0.1:RANDOM) changes every launch, wiping per-origin storage.
|
|
2014
|
+
// The board remembers the workspace; a picked CLI folder like sandbox-1
|
|
2015
|
+
// survives restarts. localStorage-only values are pushed up so a fresh
|
|
2016
|
+
// board learns them too.
|
|
2017
|
+
try{
|
|
2018
|
+
fetch('/api/workspace').then(function(r){return r.ok?r.json():null;}).then(function(j){
|
|
2019
|
+
if(!j||!j.cwd)return;
|
|
2020
|
+
var cur=(document.getElementById('launch-cwd')?document.getElementById('launch-cwd').value.trim():'');
|
|
2021
|
+
try{
|
|
2022
|
+
var lsCwd=localStorage.getItem('crewbus_last_cwd')||'';
|
|
2023
|
+
if(lsCwd&&lsCwd!==j.cwd&&(!cur||cur===lsCwd)){
|
|
2024
|
+
// Fresh board that never saw our local pick: teach it.
|
|
2025
|
+
fetch('/api/workspace',{method:'POST',headers:{'content-type':'application/json'},body:JSON.stringify({cwd:lsCwd})}).catch(function(){});
|
|
2026
|
+
return;
|
|
2027
|
+
}
|
|
2028
|
+
}catch(_){}
|
|
2029
|
+
if(!cur)applyTargetCwd(j.cwd,false);
|
|
2030
|
+
}).catch(function(){});
|
|
2031
|
+
}catch(_){}
|
|
1919
2032
|
document.getElementById('launch-brief').addEventListener('keydown',function(e){
|
|
1920
2033
|
if((e.ctrlKey||e.metaKey)&&(e.key==='Enter')){
|
|
1921
2034
|
e.preventDefault();
|
|
@@ -2110,15 +2223,67 @@ export async function handleWebDashboardRoute(req, res, url, d) {
|
|
|
2110
2223
|
const tokenFile = path.join(d.root, "logs", "lead.token");
|
|
2111
2224
|
let tok = "";
|
|
2112
2225
|
try { tok = fs.readFileSync(tokenFile, "utf8").trim(); } catch {}
|
|
2226
|
+
// Verify the file token still matches the agent record: a stale file
|
|
2227
|
+
// (revoked/rotated lead) must not prefill a dead token.
|
|
2113
2228
|
if (tok) {
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2229
|
+
try {
|
|
2230
|
+
const rec = readAgent(d, "lead");
|
|
2231
|
+
if (rec && agentTokenMatches(rec, tok)) {
|
|
2232
|
+
res.writeHead(200, { "content-type": "application/json; charset=utf-8", "cache-control": "no-store" });
|
|
2233
|
+
res.end(JSON.stringify({ ok: true, from: "lead", token: tok }));
|
|
2234
|
+
return true;
|
|
2235
|
+
}
|
|
2236
|
+
} catch {}
|
|
2117
2237
|
}
|
|
2118
2238
|
res.writeHead(404, { "content-type": "application/json; charset=utf-8", "cache-control": "no-store" });
|
|
2119
2239
|
res.end(JSON.stringify({ ok: false, error: "no lead.token found" }));
|
|
2120
2240
|
return true;
|
|
2121
2241
|
}
|
|
2242
|
+
// Workspace memory (server-side, survives the random-port origin wipe):
|
|
2243
|
+
// GET returns the last-set target codebase dir (or default board parent);
|
|
2244
|
+
// POST { cwd } validates + persists it to board.json so desktop + web agree.
|
|
2245
|
+
if (req.method === "GET" && url.pathname === "/api/workspace") {
|
|
2246
|
+
let meta = {};
|
|
2247
|
+
try { meta = readBoardMeta(d) || {}; } catch {}
|
|
2248
|
+
const cwd = (meta && meta.workspaceCwd) || path.dirname(d.root);
|
|
2249
|
+
res.writeHead(200, { "content-type": "application/json; charset=utf-8", "cache-control": "no-store" });
|
|
2250
|
+
res.end(JSON.stringify({ ok: true, cwd, board: d.root }));
|
|
2251
|
+
return true;
|
|
2252
|
+
}
|
|
2253
|
+
if (req.method === "POST" && url.pathname === "/api/workspace") {
|
|
2254
|
+
if (!String(req.headers["content-type"] || "").includes("application/json")) {
|
|
2255
|
+
res.writeHead(415, { "content-type": "application/json; charset=utf-8" });
|
|
2256
|
+
res.end(JSON.stringify({ error: "content-type must be application/json" }));
|
|
2257
|
+
return true;
|
|
2258
|
+
}
|
|
2259
|
+
const { body, error } = await readKillBody(req);
|
|
2260
|
+
if (error) {
|
|
2261
|
+
res.writeHead(error[0], { "content-type": "application/json; charset=utf-8" });
|
|
2262
|
+
res.end(JSON.stringify({ error: error[1] }));
|
|
2263
|
+
return true;
|
|
2264
|
+
}
|
|
2265
|
+
const raw = body && body.cwd !== undefined && body.cwd !== null ? String(body.cwd).trim() : "";
|
|
2266
|
+
const cwd = raw ? path.resolve(raw) : path.dirname(d.root);
|
|
2267
|
+
let ok = false;
|
|
2268
|
+
try { ok = fs.statSync(cwd).isDirectory(); } catch {}
|
|
2269
|
+
if (!ok) {
|
|
2270
|
+
res.writeHead(400, { "content-type": "application/json; charset=utf-8" });
|
|
2271
|
+
res.end(JSON.stringify({ error: `cwd is not a directory: ${cwd}` }));
|
|
2272
|
+
return true;
|
|
2273
|
+
}
|
|
2274
|
+
try {
|
|
2275
|
+
const meta = readBoardMeta(d) || {};
|
|
2276
|
+
meta.workspaceCwd = cwd;
|
|
2277
|
+
writeBoardMeta(d, meta);
|
|
2278
|
+
} catch (e) {
|
|
2279
|
+
res.writeHead(500, { "content-type": "application/json; charset=utf-8" });
|
|
2280
|
+
res.end(JSON.stringify({ error: String((e && e.message) || e) }));
|
|
2281
|
+
return true;
|
|
2282
|
+
}
|
|
2283
|
+
res.writeHead(200, { "content-type": "application/json; charset=utf-8", "cache-control": "no-store" });
|
|
2284
|
+
res.end(JSON.stringify({ ok: true, cwd, board: d.root }));
|
|
2285
|
+
return true;
|
|
2286
|
+
}
|
|
2122
2287
|
if (req.method === "POST" && url.pathname === "/api/install-cli") {
|
|
2123
2288
|
const ip = req.socket.remoteAddress || "";
|
|
2124
2289
|
const isLoop = ip === "127.0.0.1" || ip === "::1" || ip === "::ffff:127.0.0.1";
|
|
@@ -2137,6 +2302,41 @@ export async function handleWebDashboardRoute(req, res, url, d) {
|
|
|
2137
2302
|
}
|
|
2138
2303
|
return true;
|
|
2139
2304
|
}
|
|
2305
|
+
// One-click mobile pairing (plug-and-play): mint a one-time pair URL
|
|
2306
|
+
// server-side and return it for immediate QR render. Loopback-only;
|
|
2307
|
+
// same mint + audit as relay pair qr / serve --pair-qrcode. The dashboard
|
|
2308
|
+
// pair window calls this on open, so normies never touch a terminal.
|
|
2309
|
+
if (req.method === "POST" && url.pathname === "/api/pair-qr") {
|
|
2310
|
+
const ip = req.socket.remoteAddress || "";
|
|
2311
|
+
const isLoop = ip === "127.0.0.1" || ip === "::1" || ip === "::ffff:127.0.0.1" || ip === "localhost";
|
|
2312
|
+
if (!isLoop) {
|
|
2313
|
+
res.writeHead(403, { "content-type": "application/json; charset=utf-8" });
|
|
2314
|
+
res.end(JSON.stringify({ error: "loopback only" }));
|
|
2315
|
+
return true;
|
|
2316
|
+
}
|
|
2317
|
+
try {
|
|
2318
|
+
const token = newPairToken();
|
|
2319
|
+
const salt = newSalt();
|
|
2320
|
+
const now = Date.now();
|
|
2321
|
+
const ttlMs = 10 * 60 * 1000;
|
|
2322
|
+
const doc = {
|
|
2323
|
+
tokenHash: hashToken(token, salt), salt, label: "dashboard-oneclick",
|
|
2324
|
+
createdBy: "lead", createdAt: new Date(now).toISOString(),
|
|
2325
|
+
expiresAt: new Date(now + ttlMs).toISOString(),
|
|
2326
|
+
};
|
|
2327
|
+
fs.mkdirSync(path.join(d.root, "pairing"), { recursive: true });
|
|
2328
|
+
writeJson(pairingPath(d, doc.tokenHash), doc);
|
|
2329
|
+
try { appendChainRecord(d, "lead", "pair", { label: "dashboard-oneclick", expiresAt: doc.expiresAt }); } catch {}
|
|
2330
|
+
const envId = (readRelayState(d) && readRelayState(d).envId) || ("board:" + path.basename(d.root));
|
|
2331
|
+
const pairUrl = buildPairUrl({ envId, routes: [], caps: ["hlc", "tombstones", "channels", "revoked", "holds", "launch"], pairToken: token });
|
|
2332
|
+
res.writeHead(200, { "content-type": "application/json; charset=utf-8", "cache-control": "no-store" });
|
|
2333
|
+
res.end(JSON.stringify({ ok: true, pairUrl, expiresAt: doc.expiresAt, envId }));
|
|
2334
|
+
} catch (err) {
|
|
2335
|
+
res.writeHead(500, { "content-type": "application/json; charset=utf-8", "cache-control": "no-store" });
|
|
2336
|
+
res.end(JSON.stringify({ ok: false, error: String((err && err.message) || err) }));
|
|
2337
|
+
}
|
|
2338
|
+
return true;
|
|
2339
|
+
}
|
|
2140
2340
|
return false;
|
|
2141
2341
|
}
|
|
2142
2342
|
|
|
@@ -2146,6 +2346,9 @@ export async function cmdWeb(args) {
|
|
|
2146
2346
|
ensureBoardCliShim(d);
|
|
2147
2347
|
const host = getFlag(args, "--host") || "127.0.0.1";
|
|
2148
2348
|
const port = Number(getFlag(args, "--port") || 0);
|
|
2349
|
+
// Desktop plug-and-play: same loopback auto-provision as `serve` (see
|
|
2350
|
+
// ensureLoopbackOperator in identity.js). First loopback boot mints `lead`.
|
|
2351
|
+
try { ensureLoopbackOperator(d, host); } catch {}
|
|
2149
2352
|
if (!(port >= 0 && port < 65536)) fail("--port must be 0-65535 (0 = random)");
|
|
2150
2353
|
if (host !== "127.0.0.1" && host !== "localhost" && host !== "::1") {
|
|
2151
2354
|
process.stderr.write(`crewbus: warning: binding non-local ${host} — the dashboard has no auth, anyone who can reach it can read the board\n`);
|
package/docs/VERSION_SKEW.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Version skew (mixed-relay operation)
|
|
2
2
|
|
|
3
|
-
How crewbus versions interoperate. Evidence: `package.json:2` (`10.0.
|
|
3
|
+
How crewbus versions interoperate. Evidence: `package.json:2` (`10.0.8`),
|
|
4
4
|
`CHANGELOG.md` (10.0.0 2026-10-08; 7.0.0 2026-10-05; 6.4.0–6.0.0; 4.1.0/4.0.0 baseline).
|
|
5
5
|
Capabilities: `RELAY_CAPS` + `launch` per `packages/contracts/board-caps.json:6-8`.
|
|
6
6
|
Cell behavior is the NEW side's verified behavior (`bin/lib/sync.js` refs);
|
package/documentation.html
CHANGED
|
@@ -60,7 +60,7 @@ code{overflow-wrap:anywhere}pre code{overflow-wrap:normal}
|
|
|
60
60
|
</style>
|
|
61
61
|
</head>
|
|
62
62
|
<body>
|
|
63
|
-
<div class="top"><a class="logo" href="https://claude.ai/artifact/WZr8xSELhXve1kuJhJC8wU"><picture><source srcset="assets/brand/crewbus-logo-for-dark.png" media="(prefers-color-scheme: dark)"><img src="assets/brand/crewbus-logo-for-light.png" alt="crewbus" width="89" height="26" onerror="this.onerror=null;this.src='assets/brand/logo.svg'"></picture
|
|
63
|
+
<div class="top"><a class="logo" href="https://claude.ai/artifact/WZr8xSELhXve1kuJhJC8wU"><picture><source srcset="assets/brand/crewbus-logo-for-dark.png" media="(prefers-color-scheme: dark)"><img src="assets/brand/crewbus-logo-for-light.png" alt="crewbus" width="89" height="26" onerror="this.onerror=null;this.src='assets/brand/logo.svg'"></picture></a><span class="tag">docs</span><a class="back" href="https://claude.ai/artifact/WZr8xSELhXve1kuJhJC8wU">Back to site</a></div>
|
|
64
64
|
<div class="wrap">
|
|
65
65
|
<nav>
|
|
66
66
|
<b>Documentation</b>
|
|
@@ -86,7 +86,7 @@ code{overflow-wrap:anywhere}pre code{overflow-wrap:normal}
|
|
|
86
86
|
<main>
|
|
87
87
|
|
|
88
88
|
<h1>crewbus</h1>
|
|
89
|
-
<p class="sub">A zero-dependency local DM bus for AI coding agents — v10.0.
|
|
89
|
+
<p class="sub">A zero-dependency local DM bus for AI coding agents — v10.0.8 · package <code>crewbus</code> · <a href="https://github.com/eamonpluto/crewbus/actions/workflows/ci.yml">CI status</a></p>
|
|
90
90
|
<p class="sub">Lead audience: developers running <strong>mixed-harness crews</strong> (opencode, Claude Code, Codex, Antigravity, grok-build, Cursor). <code>package.json</code> is the release version source of truth; <code>board.json</code>'s <code>version: 2</code> is the board <em>schema</em> version, not the release.</p>
|
|
91
91
|
|
|
92
92
|
<h2 id="what">1 · What it is</h2>
|
|
@@ -299,6 +299,8 @@ crewbus init --harness <name> --portable # portable wiring
|
|
|
299
299
|
|
|
300
300
|
<h2 id="changes">16 · Changelog</h2>
|
|
301
301
|
<ul>
|
|
302
|
+
<li><strong>10.0.8</strong> — patch release: Launch composer UI refinements (streamlined worker naming, clearer agent count stepper, flat composer card, clean launch console) & desktop companion. Full text: <code>CHANGELOG.md ## 10.0.8</code>.</li>
|
|
303
|
+
<li><strong>10.0.7</strong> — patch release: design refresh and icon fix across desktop and mobile shells. Full text: <code>CHANGELOG.md ## 10.0.7</code>.</li>
|
|
302
304
|
<li><strong>10.0.6</strong> — hotfix: a template-literal escape in the dashboard page killed the whole client script at parse time — fixed, with a regression test that syntax-checks the served page. Full text: <code>CHANGELOG.md ## 10.0.6</code>.</li>
|
|
303
305
|
<li><strong>10.0.5</strong> — self-update command (<code>update [--check] [--yes] [--version x.y.z]</code> via your own npm config; checkouts refused with <code>git pull</code> guidance). Full text: <code>CHANGELOG.md ## 10.0.5</code>.</li>
|
|
304
306
|
<li><strong>10.0.4</strong> — patch release: dashboard Briefs view + <code>GET /api/gather</code>, task-scoped spawn rosters, mobile brief/thread/watcher screens. Full text: <code>CHANGELOG.md ## 10.0.4</code>.</li>
|
|
@@ -344,7 +346,7 @@ crewbus init --harness <name> --portable # portable wiring
|
|
|
344
346
|
<h3>Mobile shell</h3>
|
|
345
347
|
<p>Expo shell, remote-only v1 (see <code>apps/mobile/README.md</code>): pairs by QR scan, walks advertised + learned routes, offers triage/approvals/launch/fleet cards with an offline outbox that only retries on explicit tap. Triage groups inbox by brief thread; the Briefs screen shows one row per fan-out with tap-for-thread; a foreground watcher raises in-app alerts for approvals and dead workers.</p>
|
|
346
348
|
|
|
347
|
-
<footer>crewbus documentation · v10.0.
|
|
349
|
+
<footer>crewbus documentation · v10.0.8 tree · zero dependencies, node ≥18 · MIT</footer>
|
|
348
350
|
|
|
349
351
|
</main>
|
|
350
352
|
</div>
|
package/index.html
CHANGED
|
@@ -114,7 +114,7 @@ details{border-top:1px solid var(--line);padding:14px 0}summary{cursor:pointer;f
|
|
|
114
114
|
|
|
115
115
|
<div class="hero" id="top" data-page="home">
|
|
116
116
|
<div>
|
|
117
|
-
<span class="pill"><i></i>v10.0.
|
|
117
|
+
<span class="pill"><i></i>v10.0.8 is out</span>
|
|
118
118
|
<h1>Let your coding agents talk to each other.</h1>
|
|
119
119
|
<p class="lede">A zero-dependency local DM bus. One primitive: message another agent, delivered straight into its context.</p>
|
|
120
120
|
<div class="cta"><a class="btn" href="#install">Get started</a><a class="btn ghost" href="https://github.com/eamonpluto/crewbus">View on GitHub</a></div>
|
|
@@ -221,13 +221,13 @@ crewbus doctor</pre>
|
|
|
221
221
|
<h2>Desktop and mobile control plane.</h2>
|
|
222
222
|
<p class="sub">Run live crews from a native app, then approve worker actions from your phone. Everything stays on your machines.</p>
|
|
223
223
|
<div class="grid" style="grid-template-columns:repeat(auto-fit,minmax(300px,1fr))">
|
|
224
|
-
<div class="card"><h3>CrewBus Desktop <span class="tag">v0.1.
|
|
224
|
+
<div class="card"><h3>CrewBus Desktop <span class="tag">v0.1.22</span></h3><p>A native GUI built on Tauri v2. It supervises an isolated sidecar on <code>127.0.0.1</code>, with zero cloud dependency.</p>
|
|
225
225
|
<ul><li>Sidecar supervisor with auto-restart and port recovery</li><li>Fleet inspector: terminate workers live, with an Undo toast</li><li>Multi-harness launcher with a context-sensitive model selector</li><li>Briefs view: one row per fan-out with gathered threads; data-age + STALE banner</li><li>One-click QR code to pair the mobile companion</li></ul>
|
|
226
|
-
<div class="dl"><a class="btn" href="https://github.com/eamonpluto/crewbus/releases/download/desktop-v0.1.
|
|
227
|
-
<a href="https://github.com/eamonpluto/crewbus/releases/tag/desktop-v0.1.
|
|
226
|
+
<div class="dl"><a class="btn" href="https://github.com/eamonpluto/crewbus/releases/download/desktop-v0.1.22/CrewBus_0.1.22_x64-setup.exe">Windows</a><a class="btn" href="https://github.com/eamonpluto/crewbus/releases/download/desktop-v0.1.22/CrewBus_0.1.22_aarch64.dmg">macOS (Apple silicon)</a><a class="btn" href="https://github.com/eamonpluto/crewbus/releases/download/desktop-v0.1.22/CrewBus_0.1.22_amd64.AppImage">Linux</a></div>
|
|
227
|
+
<a href="https://github.com/eamonpluto/crewbus/releases/tag/desktop-v0.1.22">All release assets (.msi, .deb, .rpm)</a></div>
|
|
228
228
|
<div class="card"><h3>CrewBus Mobile <span class="tag t">preview</span></h3><p>A companion built on React Native and Expo. Pair with your desktop or relay by scanning a QR code, without exposing root credentials.</p>
|
|
229
229
|
<ul><li>Per-device credentials with narrow scopes</li><li>Approve or deny worker shell calls from anywhere</li><li>Briefs screen: one row per fan-out, tap for its thread; triage grouped by brief</li><li>Foreground watcher: approvals and dead workers raise an in-app alert + buzz</li><li>Offline outbox: queued actions retry when you tap</li><li>Launch card with dynamic model selection</li></ul>
|
|
230
|
-
<div class="dl"><a class="btn" href="https://expo.dev/artifacts/eas/
|
|
230
|
+
<div class="dl"><a class="btn" href="https://expo.dev/artifacts/eas/clk0vyzypxygmxamqdpzhiib_2gggfvzsu053id9spg.apk">Android APK</a><a class="btn ghost" href="https://expo.dev/accounts/eamonpluto/projects/crewbus-mobile/builds/885a36dc-1689-4345-9274-6e31318b760f">EAS build</a></div>
|
|
231
231
|
<p style="margin:0">Pair from the CLI with <code>crewbus relay pair qr</code>.</p></div>
|
|
232
232
|
</div>
|
|
233
233
|
<h3 class="h3">Multi-harness launch from the CLI</h3>
|
|
@@ -256,6 +256,7 @@ POST /api/launch</pre>
|
|
|
256
256
|
<p class="sub" style="margin-top:18px">Enterprise verbs: <code>hold</code> <code>board</code> <code>login</code> <code>acl</code> <code>snapshot</code> <code>quota</code> <code>relay</code> <code>crew</code> <code>log</code></p>
|
|
257
257
|
<h3 class="h3">Documentation library</h3>
|
|
258
258
|
<div class="chips" id="docs"></div>
|
|
259
|
+
<p class="sub" style="margin-top:18px">Full reference: <a href="documentation.html">crewbus documentation</a> — every guide, the CLI reference, delivery model and trust boundary on one page.</p>
|
|
259
260
|
</div></section>
|
|
260
261
|
|
|
261
262
|
<section data-page="releases" hidden><div class="w">
|
|
@@ -266,7 +267,7 @@ POST /api/launch</pre>
|
|
|
266
267
|
<div id="faq"></div>
|
|
267
268
|
</div></section>
|
|
268
269
|
|
|
269
|
-
<div class="w"><footer><span>crewbus v10.0.
|
|
270
|
+
<div class="w"><footer><span>crewbus v10.0.8 · zero-dependency local DM bus</span><span><a href="https://github.com/eamonpluto/crewbus">GitHub</a></span></footer></div>
|
|
270
271
|
|
|
271
272
|
<script>
|
|
272
273
|
(function(){
|
|
@@ -308,7 +309,7 @@ cards('uses',[['Researchers','Parameter sweeps, parallel proof attempts where th
|
|
|
308
309
|
var C='init|Plants the board, writes agent instructions, installs harness wiring.|init --harness opencode;update|Self-update the global npm install to the registry latest.|update --check;register|First claim mints your token; later calls prove it.|register --from lead;token|Rotate, expire and inspect identity tokens.|token rotate --from lead;agents|Who exists and who is actually alive.|agents --active;send|The primitive: mission, scope and done-criteria in one DM.|send --to bob --body "…";inbox|Your mail, with no mark-read side effects.|inbox --unacked;listen|Block and print new arrivals, locally or via relay.|listen --timeout 60000;thread|One brief plus every reply, across inboxes.|thread --id msg-…;channel|Append-only public logs: post, tail, search, summarize.|channel tail findings;group|Named recipient sets for variant briefs.|group create team-a;gather|Reduce a batch to one transcript.|gather --batch …;ack|Accept a reply, optionally gated on a checker.|ack --verify "npm test";result|Keep verified-only group outcomes.|result record --group …;race|First verified result wins; losers stand down.|race close --kill;spawn|Brief workers and boot them detached.|spawn --count 8;spawn-status|Running? Replied? Acked?|spawn-status --all;spawn-kill|Terminate workers by recorded pid.|spawn-kill --to w1;pool|Boot at most S of N at once, auto-replace exits.|pool --count 20;stop|The global kill switch.|stop --all;serve|Relay: sync, remote crews, health checks.|serve --port 8471;sync|Peer-to-peer board merge.|sync --with …;web|Fleet console on localhost.|web --port 0;doctor|Validate wiring and diagnose split boards.|doctor;prune|Retention windows for old mail and logs.|prune --dry-run';
|
|
309
310
|
$('cmds').innerHTML=tbl(['Command','What it does','Try first'],C.split(';').map(function(r){var p=r.split('|');return ['<code>'+p[0]+'</code>',p[1],'<code>'+p[2]+'</code>']}));
|
|
310
311
|
$('docs').innerHTML='QUICKSTART TROUBLESHOOTING WHEN_NOT COMPATIBILITY DELIVERY GROUPS VERIFIER CONSOLIDATOR LIMITS THREAT_MODEL ISOLATION STORAGE EXPERIMENTS IDENTITY RBAC OIDC_TLS AUDIT_EXPORT TENANCY HA SHARED_RESPONSIBILITY CERT_READINESS PAIRING CREWS SPLIT'.split(' ').map(function(d){return '<a href="https://github.com/eamonpluto/crewbus/blob/master/docs/'+d+'.md">'+d.toLowerCase()+'</a>'}).join('');
|
|
311
|
-
var R=[['10.0.6','2026-10-13','Dashboard client hotfix: a template-literal escape killed the whole script block at parse time — fixed, with a regression test that syntax-checks the served page.'],['10.0.5','2026-10-12','Self-update command: crewbus update [--check] [--yes] [--version x.y.z] via your own npm config.'],['10.0.4','2026-10-12','Dashboard Briefs view + gather endpoint, task-scoped spawn rosters, mobile brief/thread/watcher screens.'],['10.0.3','2026-10-10','Worker-record integrity (canonical doc merge), truthful presence, Crew roster block in spawn briefs, doctor dead-man scan.'],['10.0.2','2026-10-09','Target workspace selector and persistence in Launch Studio, clearer project popover, directory picker replaces the upload prompt, desktop companion v0.1.16.'],['10.0.1','2026-10-09','Windows opencode detection fix, model selector sync that blocks incompatible pairings, refreshed model catalog with live discovery.'],['10.0.0','2026-10-08','Multi-harness orchestration (--harness claude,antigravity), canonical model selector, native desktop app, mobile companion with QR pairing, full control plane.'],['7.0.0','2026-10-05','Renamed to crewbus. Human-in-the-loop approvals, long-run resilience, respawn, checkpoints and pool-resume.'],['6.0.0','2026-10-03','Fleet hardening: capability negotiation, credential scrub for workers, per-device pairing, weighted multi-relay crews.'],['5.0.0','2026-10-03','Enterprise tier: RBAC, OIDC, TLS, audit export, legal holds, encrypted backups, quotas, standby relays.'],['3.0.0','2026-09-24','Token-bound identity, presence, pruning, detached spawn, ack and threading, local dashboard.'],['2.0.0','earlier','The DM-only rewrite: one primitive, message another agent, plus the opencode push layer.']];
|
|
312
|
+
var R=[['10.0.8','2026-10-16','Launch composer UI refinements: streamlined agent naming, clearer count stepper, flat panel styling, and clean console.'],['10.0.7','2026-10-14','Design refresh and icon fixes across desktop and mobile shells.'],['10.0.6','2026-10-13','Dashboard client hotfix: a template-literal escape killed the whole script block at parse time — fixed, with a regression test that syntax-checks the served page.'],['10.0.5','2026-10-12','Self-update command: crewbus update [--check] [--yes] [--version x.y.z] via your own npm config.'],['10.0.4','2026-10-12','Dashboard Briefs view + gather endpoint, task-scoped spawn rosters, mobile brief/thread/watcher screens.'],['10.0.3','2026-10-10','Worker-record integrity (canonical doc merge), truthful presence, Crew roster block in spawn briefs, doctor dead-man scan.'],['10.0.2','2026-10-09','Target workspace selector and persistence in Launch Studio, clearer project popover, directory picker replaces the upload prompt, desktop companion v0.1.16.'],['10.0.1','2026-10-09','Windows opencode detection fix, model selector sync that blocks incompatible pairings, refreshed model catalog with live discovery.'],['10.0.0','2026-10-08','Multi-harness orchestration (--harness claude,antigravity), canonical model selector, native desktop app, mobile companion with QR pairing, full control plane.'],['7.0.0','2026-10-05','Renamed to crewbus. Human-in-the-loop approvals, long-run resilience, respawn, checkpoints and pool-resume.'],['6.0.0','2026-10-03','Fleet hardening: capability negotiation, credential scrub for workers, per-device pairing, weighted multi-relay crews.'],['5.0.0','2026-10-03','Enterprise tier: RBAC, OIDC, TLS, audit export, legal holds, encrypted backups, quotas, standby relays.'],['3.0.0','2026-09-24','Token-bound identity, presence, pruning, detached spawn, ack and threading, local dashboard.'],['2.0.0','earlier','The DM-only rewrite: one primitive, message another agent, plus the opencode push layer.']];
|
|
312
313
|
$('rel').innerHTML=R.map(function(r){return '<div><b>'+r[0]+'</b><span class="mono">'+r[1]+'</span><p>'+r[2]+'</p></div>'}).join('');
|
|
313
314
|
var F=[['Is this just chat for robots?','No. The DM is the task object: a brief carries mission, scope and definition of done, replies thread back, and acks close the loop.'],['Can it run 10,000 agents at once?','10,000 is a broadcast limit: one brief reaches ten thousand inboxes. Live workers are whole harness processes, so size them like compute.'],['What stops an agent going rogue?','Token-bound identity with roles, relay auth with opt-in remote boot, untrusted-peer envelopes, loop and cost guards, budgets, dead-man timeouts and a global stop.'],['Does it phone home?','No. There are no accounts, no telemetry and no update checks. Boards sync only with peers you name.'],['What happens when a worker dies mid-brief?','The brief survives because it is a file, not a process. respawn reboots the worker with a catch-up brief, and pools replace exits automatically.'],['How are results verified?','ack --verify runs your tests or a checker. Only exit 0 records a verified result with its output.'],['When should I not use it?','Single-session work (use subagents), strict ordered pipelines (use a queue), and anything needing real-time guarantees, since the bus is files on disk.'],['Which Node versions work?','Node 18 and newer on Linux, macOS and Windows.'],['Who pays for the tokens agents burn?','Your model provider does. The bus itself costs nothing to run.']];
|
|
314
315
|
$('faq').innerHTML=F.map(function(f){return '<details><summary>'+f[0]+'</summary><p>'+f[1]+'</p></details>'}).join('');
|