tryharness 0.7.54 → 0.7.58
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/README.md +15 -16
- package/cli.mjs +384 -62
- package/lib/activity.mjs +10 -10
- package/lib/adapters.mjs +16 -0
- package/lib/agentBinaries.mjs +71 -0
- package/lib/agentRuntimeConfig.mjs +1 -1
- package/lib/agentRuntimes.mjs +9 -3
- package/lib/agentSignIn.mjs +271 -41
- package/lib/answers.mjs +5 -5
- package/lib/archetypes.d.ts +64 -0
- package/lib/archetypes.js +989 -0
- package/lib/asks.mjs +4 -4
- package/lib/audit.mjs +36 -13
- package/lib/backupSetup.mjs +4 -2
- package/lib/boardAccess.mjs +17 -11
- package/lib/boardBackup.mjs +6 -6
- package/lib/boardFileCommands.mjs +6 -6
- package/lib/boardFiles.mjs +13 -12
- package/lib/boardMirror.mjs +82 -47
- package/lib/boardProtocol.json +30 -1
- package/lib/boardWaits.mjs +2 -3
- package/lib/book.mjs +6 -6
- package/lib/bridge.mjs +5 -5
- package/lib/cards.mjs +2 -2
- package/lib/cloudAgents.mjs +216 -0
- package/lib/cloudAi.mjs +1312 -0
- package/lib/cloudAssistants.mjs +242 -0
- package/lib/cloudBoot.mjs +81 -86
- package/lib/cloudSave.mjs +197 -0
- package/lib/cloudSsh.mjs +178 -0
- package/lib/context.mjs +3 -3
- package/lib/contractGate.mjs +34 -12
- package/lib/control-client.mjs +9 -1
- package/lib/controlSocket.mjs +86 -0
- package/lib/coordinator.mjs +103 -101
- package/lib/daemon.mjs +1128 -2865
- package/lib/desk.mjs +7 -6
- package/lib/desktop.mjs +72 -68
- package/lib/directLink.mjs +16 -5
- package/lib/environment.mjs +2 -1
- package/lib/environments.mjs +14 -6
- package/lib/firewall.mjs +9 -9
- package/lib/folders.mjs +18 -14
- package/lib/frames.mjs +2 -3
- package/lib/gitHost.mjs +3 -3
- package/lib/goalCommands.mjs +25 -7
- package/lib/goals.mjs +7 -7
- package/lib/guestRequests.mjs +94 -0
- package/lib/handoffs.mjs +8 -7
- package/lib/handover.mjs +4 -4
- package/lib/harnessModel.mjs +6 -6
- package/lib/harnessOffers.mjs +266 -0
- package/lib/inference.mjs +26 -8
- package/lib/jobAnswers.mjs +190 -0
- package/lib/landed.mjs +1 -1
- package/lib/lane.mjs +42 -11
- package/lib/lessons.mjs +16 -16
- package/lib/library.mjs +3 -3
- package/lib/lineup.mjs +3 -0
- package/lib/linkRelay.mjs +574 -0
- package/lib/localAgentAsk.mjs +74 -0
- package/lib/localStack.mjs +536 -0
- package/lib/localmodels.mjs +6 -4
- package/lib/loopBackstop.mjs +4 -4
- package/lib/machineIdentity.mjs +9 -1
- package/lib/machineRoutes.mjs +181 -2
- package/lib/machineRuns.mjs +76 -1
- package/lib/machineSeal.mjs +39 -12
- package/lib/mcp-stdio.mjs +96 -26
- package/lib/mcpRelay.mjs +1 -1
- package/lib/members.json +13 -0
- package/lib/members.mjs +1 -1
- package/lib/models.mjs +77 -23
- package/lib/museSession.mjs +6 -1
- package/lib/nativeHost.mjs +35 -7
- package/lib/network.mjs +50 -5
- package/lib/notify.mjs +7 -5
- package/lib/nudge.mjs +3 -3
- package/lib/ocr.mjs +9 -9
- package/lib/onboard.mjs +141 -50
- package/lib/oneLine.mjs +7 -7
- package/lib/ownMachines.mjs +928 -149
- package/lib/pairing.mjs +39 -8
- package/lib/paths.mjs +15 -1
- package/lib/peerProcess.mjs +124 -0
- package/lib/personModel.mjs +3 -3
- package/lib/personNotices.mjs +151 -0
- package/lib/phones.mjs +490 -38
- package/lib/placeCommands.mjs +4 -4
- package/lib/places.mjs +70 -2
- package/lib/profile.mjs +67 -14
- package/lib/projectGit.mjs +158 -14
- package/lib/projectPieces.mjs +902 -0
- package/lib/projectSettings.mjs +7 -4
- package/lib/projects.mjs +384 -62
- package/lib/provenance.mjs +5 -1
- package/lib/proxyLinks.mjs +267 -0
- package/lib/reactions.mjs +7 -5
- package/lib/readiness.mjs +12 -7
- package/lib/record.mjs +19 -6
- package/lib/redact.mjs +4 -4
- package/lib/relayLimits.mjs +62 -0
- package/lib/release.mjs +170 -0
- package/lib/releaseKeys.json +6 -0
- package/lib/repoLinks.mjs +4 -4
- package/lib/roomChannels.mjs +24 -0
- package/lib/roomPage.mjs +1 -1
- package/lib/runAuthority.mjs +101 -0
- package/lib/runBrief.mjs +19 -8
- package/lib/runWorker.mjs +14 -5
- package/lib/runner.mjs +215 -25
- package/lib/runtime-install.mjs +143 -9
- package/lib/schedules.mjs +2 -2
- package/lib/screens.mjs +1 -1
- package/lib/sealed.mjs +11 -2
- package/lib/sealedThreads.mjs +671 -0
- package/lib/secretPatterns.json +1 -1
- package/lib/secrets.mjs +4 -4
- package/lib/seen.mjs +6 -6
- package/lib/serverWords.mjs +175 -0
- package/lib/service.mjs +22 -12
- package/lib/sessionControl.mjs +6 -6
- package/lib/specialties.mjs +6 -6
- package/lib/specialtyKeys.js +4 -5
- package/lib/specialtyNotice.mjs +7 -7
- package/lib/specialtySnapshot.mjs +5 -5
- package/lib/speech.mjs +5 -5
- package/lib/store.mjs +140 -39
- package/lib/stuck.mjs +1 -1
- package/lib/swarm.mjs +167 -16
- package/lib/swarmDevices.mjs +319 -0
- package/lib/swarmMemory.mjs +27 -25
- package/lib/t3.mjs +13 -13
- package/lib/taskCommands.mjs +44 -11
- package/lib/taskRooms.mjs +125 -0
- package/lib/taskRuns.mjs +36 -1
- package/lib/team.mjs +41 -18
- package/lib/threadActions.mjs +315 -0
- package/lib/threadAuthority.mjs +101 -0
- package/lib/threadBriefs.mjs +178 -0
- package/lib/threadLine.mjs +2 -2
- package/lib/threadRuns.mjs +138 -43
- package/lib/threadView.mjs +5 -5
- package/lib/usageTotals.mjs +2 -3
- package/lib/vault.mjs +101 -10
- package/lib/vaultCloud.mjs +2 -2
- package/lib/vaultCommands.mjs +15 -6
- package/lib/vaultTools.js +2 -2
- package/lib/verdicts.mjs +328 -0
- package/lib/wakes.mjs +1 -1
- package/lib/watches.mjs +2 -2
- package/lib/windowAsks.mjs +13 -5
- package/lib/worktrees.mjs +112 -18
- package/npm-shrinkwrap.json +1093 -0
- package/package.json +11 -10
- package/release.json +220 -0
package/lib/onboard.mjs
CHANGED
|
@@ -8,6 +8,7 @@ import {
|
|
|
8
8
|
} from "./wakes.mjs";
|
|
9
9
|
import { columns, createUi, wrap } from "./ui.mjs";
|
|
10
10
|
import { CHECKABLE, SIGN_IN } from "./readiness.mjs";
|
|
11
|
+
import { relayCommand } from "./runtime-install.mjs";
|
|
11
12
|
|
|
12
13
|
// "Your swarm" in setup: every agent class with how Harness reaches it, the recommended way already chosen, and a real
|
|
13
14
|
// test at the end that passes only when the agent claims and reports a task. Also reachable on its own as
|
|
@@ -20,10 +21,10 @@ const LABEL = {
|
|
|
20
21
|
"grok-bot": "Grok Bot",
|
|
21
22
|
};
|
|
22
23
|
const later = (agent) =>
|
|
23
|
-
`Later: ${pc.cyan(
|
|
24
|
+
`Later: ${pc.cyan(`${relayCommand()} agents setup ${agent}`)}`;
|
|
24
25
|
|
|
25
|
-
// The Harness mark
|
|
26
|
-
//
|
|
26
|
+
// The Harness mark, as the app's walkthrough draws it, in box characters: dim corners, the bright one in Harness teal,
|
|
27
|
+
// the wordmark beside it. Plain when the output is not a terminal or NO_COLOR is set.
|
|
27
28
|
export function banner(version, { color = pc.isColorSupported } = {}) {
|
|
28
29
|
const c = pc.createColors(color),
|
|
29
30
|
teal = (text) => (color ? `\x1b[38;5;36m${text}\x1b[39m` : text);
|
|
@@ -69,15 +70,21 @@ const copy = (text) => {
|
|
|
69
70
|
return result.status === 0;
|
|
70
71
|
};
|
|
71
72
|
|
|
72
|
-
|
|
73
|
+
// How long setup waits for an agent's answer to its check before moving on. A gateway on this computer (OpenClaw,
|
|
74
|
+
// Hermes) answers within seconds or is not running; Grok Bot is woken by email, whose pickups have taken up to 59 s.
|
|
75
|
+
const ANSWER_WAIT_MS = { "grok-bot": 10 * 60_000 };
|
|
76
|
+
const DEFAULT_ANSWER_WAIT_MS = 60_000;
|
|
77
|
+
|
|
78
|
+
/** Post a setup check for the agent and wait for its report: the same path real work takes. Enter skips the wait. */
|
|
73
79
|
export async function testAgent({
|
|
74
80
|
agent,
|
|
75
81
|
daemonRequest,
|
|
76
82
|
ui = createUi(),
|
|
77
|
-
waitMs =
|
|
83
|
+
waitMs = ANSWER_WAIT_MS[agent] ?? DEFAULT_ANSWER_WAIT_MS,
|
|
78
84
|
sleep = (ms) => new Promise((r) => setTimeout(r, ms)),
|
|
79
85
|
}) {
|
|
80
86
|
const name = LABEL[agent] || agent;
|
|
87
|
+
const retry = `${relayCommand()} agents test ${agent}`;
|
|
81
88
|
const posted = await daemonRequest({
|
|
82
89
|
command: "board.post",
|
|
83
90
|
agent: "user",
|
|
@@ -93,37 +100,56 @@ export async function testAgent({
|
|
|
93
100
|
);
|
|
94
101
|
return false;
|
|
95
102
|
}
|
|
96
|
-
const started = Date.now()
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
);
|
|
119
|
-
return false;
|
|
103
|
+
const started = Date.now();
|
|
104
|
+
let skipped = false;
|
|
105
|
+
const answered = (async () => {
|
|
106
|
+
while (!skipped && Date.now() - started < waitMs) {
|
|
107
|
+
await sleep(2_000);
|
|
108
|
+
const task = (
|
|
109
|
+
await daemonRequest({
|
|
110
|
+
command: "board.get",
|
|
111
|
+
agent: "user",
|
|
112
|
+
id: posted.task.id,
|
|
113
|
+
}).catch(() => null)
|
|
114
|
+
)?.task;
|
|
115
|
+
if (task?.status === "done")
|
|
116
|
+
return {
|
|
117
|
+
ok: true,
|
|
118
|
+
line: `${name} answered in ${Math.round((Date.now() - started) / 1000)}s. Ready.`,
|
|
119
|
+
};
|
|
120
|
+
if (task && ["failed", "needs_input"].includes(task.status))
|
|
121
|
+
return {
|
|
122
|
+
ok: false,
|
|
123
|
+
line: `${name} answered, but the task is ${task.status}${task.result ? `: ${task.result}` : ""}`,
|
|
124
|
+
};
|
|
120
125
|
}
|
|
126
|
+
const waited =
|
|
127
|
+
waitMs < 60_000
|
|
128
|
+
? `${Math.round(waitMs / 1000)} seconds`
|
|
129
|
+
: waitMs === 60_000
|
|
130
|
+
? "a minute"
|
|
131
|
+
: `${Math.round(waitMs / 60_000)} minutes`;
|
|
132
|
+
return {
|
|
133
|
+
ok: false,
|
|
134
|
+
line: `No answer after ${waited}. Check that ${name} is running, then: ${retry}`,
|
|
135
|
+
};
|
|
136
|
+
})();
|
|
137
|
+
if (ui.interactive) {
|
|
138
|
+
const answer = await ui.waitOrType({
|
|
139
|
+
message: `Waiting for ${name} to answer a test task`,
|
|
140
|
+
placeholder: "press Enter to skip",
|
|
141
|
+
until: answered,
|
|
142
|
+
});
|
|
143
|
+
if (answer.done) return answer.done.ok;
|
|
144
|
+
skipped = true;
|
|
145
|
+
ui.info(`Skipped. When ${name} is running: ${retry}`);
|
|
146
|
+
return false;
|
|
121
147
|
}
|
|
122
|
-
spin.
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
);
|
|
126
|
-
return
|
|
148
|
+
const spin = ui.spinner();
|
|
149
|
+
spin.start(`Waiting for ${name} to answer a test task`);
|
|
150
|
+
const result = await answered;
|
|
151
|
+
spin.stop(result.line, result.ok ? 0 : 2);
|
|
152
|
+
return result.ok;
|
|
127
153
|
}
|
|
128
154
|
|
|
129
155
|
async function setupLocal({
|
|
@@ -292,7 +318,7 @@ async function setupGrok({ ui, daemonRequest, clipboard }) {
|
|
|
292
318
|
});
|
|
293
319
|
if (!saved.ok) {
|
|
294
320
|
ui.warn(
|
|
295
|
-
`${saved.error}. Try again:
|
|
321
|
+
`${saved.error}. Try again: ${relayCommand()} agents setup grok-bot`
|
|
296
322
|
);
|
|
297
323
|
return false;
|
|
298
324
|
}
|
|
@@ -363,7 +389,7 @@ async function setupGrok({ ui, daemonRequest, clipboard }) {
|
|
|
363
389
|
? { ok, line: "Grok registered its address" }
|
|
364
390
|
: {
|
|
365
391
|
ok,
|
|
366
|
-
line:
|
|
392
|
+
line: `Grok has not registered yet. When it has: ${relayCommand()} agents test grok-bot`,
|
|
367
393
|
}
|
|
368
394
|
);
|
|
369
395
|
const answer = await ui.waitOrType({
|
|
@@ -444,8 +470,10 @@ export async function setupSwarm({
|
|
|
444
470
|
);
|
|
445
471
|
}
|
|
446
472
|
|
|
447
|
-
|
|
448
|
-
|
|
473
|
+
// A function, not a constant: the installed command only exists once setup has installed the runtime.
|
|
474
|
+
// A function, not a constant: the installed command only exists once setup has installed the runtime.
|
|
475
|
+
const ADD_LATER = () =>
|
|
476
|
+
`Add an agent any time: in the Harness app, Agents, then Add an agent, or run ${pc.cyan(`${relayCommand()} agents add`)}. A coding agent you install or sign in to later joins by itself once it answers.`;
|
|
449
477
|
|
|
450
478
|
const COMMAND = {
|
|
451
479
|
"claude-code": "claude",
|
|
@@ -609,10 +637,73 @@ export async function setupChosen({
|
|
|
609
637
|
);
|
|
610
638
|
for (const entry of local)
|
|
611
639
|
await setupLocal({ entry, runtimeRoot, ui, daemonRequest, ask: false });
|
|
612
|
-
ui.info(JOINS_LATER);
|
|
613
640
|
}
|
|
614
641
|
|
|
615
|
-
|
|
642
|
+
// What each agent that runs elsewhere is, in the offer below.
|
|
643
|
+
const ELSEWHERE_HINT = {
|
|
644
|
+
"grok-bot": "Grok in its own cloud, woken by email or webhook: set up next",
|
|
645
|
+
muse: "set up in Harness once added",
|
|
646
|
+
bankr: "trades and wallets: set Bankr up in Harness so it can act",
|
|
647
|
+
};
|
|
648
|
+
|
|
649
|
+
/**
|
|
650
|
+
* The agents that run elsewhere, at the end of setup, so a person finds them without knowing their names. Quotient has
|
|
651
|
+
* nothing to set up and Bankr's setup is on the account, so on a first setup Quotient joins, and Bankr too once the
|
|
652
|
+
* person set it up in Harness; Grok Bot and Muse each need their own setup, so they are offered. An agent the person
|
|
653
|
+
* took out of their swarm (`removed`) is left out.
|
|
654
|
+
*/
|
|
655
|
+
export async function setupElsewhere({
|
|
656
|
+
daemonRequest,
|
|
657
|
+
ui = createUi(),
|
|
658
|
+
fresh,
|
|
659
|
+
removed = [],
|
|
660
|
+
clipboard = copy,
|
|
661
|
+
}) {
|
|
662
|
+
const lineup = await daemonRequest({ command: "swarm.lineup" }).catch(
|
|
663
|
+
() => null
|
|
664
|
+
);
|
|
665
|
+
if (lineup?.ok) {
|
|
666
|
+
const outside = (id) =>
|
|
667
|
+
!removed.includes(id) &&
|
|
668
|
+
lineup.agents.some((entry) => entry.id === id && !entry.inSwarm);
|
|
669
|
+
const account = await daemonRequest({
|
|
670
|
+
command: "wake.server",
|
|
671
|
+
input: { action: "list" },
|
|
672
|
+
}).catch(() => null);
|
|
673
|
+
const joining = fresh
|
|
674
|
+
? ["quotient", ...(account?.bankrWallet ? ["bankr"] : [])].filter(outside)
|
|
675
|
+
: [];
|
|
676
|
+
const joined = [];
|
|
677
|
+
for (const id of joining) {
|
|
678
|
+
const added = await daemonRequest({ command: "swarm.add", target: id });
|
|
679
|
+
if (added?.ok) joined.push({ id, name: added.name });
|
|
680
|
+
}
|
|
681
|
+
if (joined.length)
|
|
682
|
+
ui.success(
|
|
683
|
+
`${joined.map((agent) => agent.name).join(" and ")} ${joined.length > 1 ? "are" : "is"} in your swarm ${pc.dim(`· ${joined.length > 1 ? "they run" : "it runs"} on Harness, nothing to set up`)}`
|
|
684
|
+
);
|
|
685
|
+
const offered = ["grok-bot", "muse", "bankr"].filter(
|
|
686
|
+
(id) => outside(id) && !joined.some((agent) => agent.id === id)
|
|
687
|
+
);
|
|
688
|
+
if (offered.length && ui.interactive) {
|
|
689
|
+
const picked =
|
|
690
|
+
(await ui.multiselect({
|
|
691
|
+
message: `Agents that run elsewhere. Add any? ${pc.dim("(space to tick, enter to go on)")}`,
|
|
692
|
+
options: offered.map((id) => ({
|
|
693
|
+
value: id,
|
|
694
|
+
label: lineup.agents.find((entry) => entry.id === id).name,
|
|
695
|
+
hint: ELSEWHERE_HINT[id],
|
|
696
|
+
})),
|
|
697
|
+
})) ?? [];
|
|
698
|
+
if (picked.length)
|
|
699
|
+
await addAgents({ daemonRequest, wanted: picked, ui, clipboard });
|
|
700
|
+
}
|
|
701
|
+
}
|
|
702
|
+
ui.info(ADD_LATER());
|
|
703
|
+
}
|
|
704
|
+
|
|
705
|
+
// A function, not a constant: the installed command only exists once setup has installed the runtime.
|
|
706
|
+
const T3_LATER = () => `Later: ${pc.cyan(`${relayCommand()} t3`)}`;
|
|
616
707
|
const t3Line = (access) =>
|
|
617
708
|
access?.state === "send"
|
|
618
709
|
? {
|
|
@@ -651,7 +742,7 @@ export async function setupT3({ ui = createUi(), daemonRequest, open }) {
|
|
|
651
742
|
if (first.t3?.state === "expired")
|
|
652
743
|
ui.info("Harness's approval in T3 Code ran out.");
|
|
653
744
|
if (!ui.interactive) {
|
|
654
|
-
ui.info(T3_LATER);
|
|
745
|
+
ui.info(T3_LATER());
|
|
655
746
|
return;
|
|
656
747
|
}
|
|
657
748
|
const approve = await ui.select({
|
|
@@ -666,7 +757,7 @@ export async function setupT3({ ui = createUi(), daemonRequest, open }) {
|
|
|
666
757
|
],
|
|
667
758
|
});
|
|
668
759
|
if (approve !== "approve") {
|
|
669
|
-
ui.info(`Skipped. ${T3_LATER}`);
|
|
760
|
+
ui.info(`Skipped. ${T3_LATER()}`);
|
|
670
761
|
return;
|
|
671
762
|
}
|
|
672
763
|
for (;;) {
|
|
@@ -675,7 +766,7 @@ export async function setupT3({ ui = createUi(), daemonRequest, open }) {
|
|
|
675
766
|
if (!started.ok) {
|
|
676
767
|
ui.warn(started.error || "Harness could not start the approval.");
|
|
677
768
|
if (started.code !== "not_running") {
|
|
678
|
-
ui.info(T3_LATER);
|
|
769
|
+
ui.info(T3_LATER());
|
|
679
770
|
return;
|
|
680
771
|
}
|
|
681
772
|
const next = await ui.select({
|
|
@@ -686,7 +777,7 @@ export async function setupT3({ ui = createUi(), daemonRequest, open }) {
|
|
|
686
777
|
],
|
|
687
778
|
});
|
|
688
779
|
if (next !== "check") {
|
|
689
|
-
ui.info(`Skipped. ${T3_LATER}`);
|
|
780
|
+
ui.info(`Skipped. ${T3_LATER()}`);
|
|
690
781
|
return;
|
|
691
782
|
}
|
|
692
783
|
continue;
|
|
@@ -718,7 +809,7 @@ export async function setupT3({ ui = createUi(), daemonRequest, open }) {
|
|
|
718
809
|
if (answer.cancelled) {
|
|
719
810
|
settled = true;
|
|
720
811
|
ui.info(
|
|
721
|
-
`Stopped waiting. Approving it on that page still counts. ${T3_LATER}`
|
|
812
|
+
`Stopped waiting. Approving it on that page still counts. ${T3_LATER()}`
|
|
722
813
|
);
|
|
723
814
|
return;
|
|
724
815
|
}
|
|
@@ -754,7 +845,7 @@ export async function showLineup({ daemonRequest, ui = createUi() }) {
|
|
|
754
845
|
const lineup = await daemonRequest({ command: "swarm.lineup" });
|
|
755
846
|
if (!lineup?.ok) {
|
|
756
847
|
ui.warn(
|
|
757
|
-
lineup?.error ||
|
|
848
|
+
lineup?.error || `Harness is not running here. Run: ${relayCommand()}`
|
|
758
849
|
);
|
|
759
850
|
return;
|
|
760
851
|
}
|
|
@@ -765,7 +856,7 @@ export async function showLineup({ daemonRequest, ui = createUi() }) {
|
|
|
765
856
|
ui.step(
|
|
766
857
|
`Your swarm ${pc.dim("· ✓ in it, + can be added")}\n${rows.join("\n")}`
|
|
767
858
|
);
|
|
768
|
-
ui.info(ADD_LATER);
|
|
859
|
+
ui.info(ADD_LATER());
|
|
769
860
|
}
|
|
770
861
|
|
|
771
862
|
/**
|
|
@@ -781,7 +872,7 @@ export async function addAgents({
|
|
|
781
872
|
const lineup = await daemonRequest({ command: "swarm.lineup" });
|
|
782
873
|
if (!lineup?.ok) {
|
|
783
874
|
ui.warn(
|
|
784
|
-
lineup?.error ||
|
|
875
|
+
lineup?.error || `Harness is not running here. Run: ${relayCommand()}`
|
|
785
876
|
);
|
|
786
877
|
return false;
|
|
787
878
|
}
|
|
@@ -806,7 +897,7 @@ export async function addAgents({
|
|
|
806
897
|
}
|
|
807
898
|
if (!ui.interactive) {
|
|
808
899
|
ui.info(
|
|
809
|
-
`Can be added: ${open.map((entry) => entry.id).join(", ")}. Run:
|
|
900
|
+
`Can be added: ${open.map((entry) => entry.id).join(", ")}. Run: ${relayCommand()} agents add <agent>`
|
|
810
901
|
);
|
|
811
902
|
return true;
|
|
812
903
|
}
|
|
@@ -856,7 +947,7 @@ export async function removeAgent({ daemonRequest, agent, ui = createUi() }) {
|
|
|
856
947
|
return false;
|
|
857
948
|
}
|
|
858
949
|
ui.success(
|
|
859
|
-
`${removed.name} is out of your swarm. Add it back any time:
|
|
950
|
+
`${removed.name} is out of your swarm. Add it back any time: ${relayCommand()} agents add ${agent}`
|
|
860
951
|
);
|
|
861
952
|
return true;
|
|
862
953
|
}
|
package/lib/oneLine.mjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
// A field one agent wrote that another agent reads as one line (an objective, an origin chain, a thread title in a
|
|
2
|
-
// a steering header, a card's model) is made safe here: a line break or control character in it could otherwise
|
|
3
|
-
// line of its own and forge one, such as a "Harness task board:" line in another agent's session start (33
|
|
4
|
-
// task objectives on
|
|
5
|
-
//
|
|
1
|
+
// A field one agent wrote that another agent reads as one line (an objective, an origin chain, a thread title in a
|
|
2
|
+
// frame, a steering header, a card's model) is made safe here: a line break or control character in it could otherwise
|
|
3
|
+
// start a line of its own and forge one, such as a "Harness task board:" line in another agent's session start (33
|
|
4
|
+
// agent-written task objectives on one real board held line breaks). Every control and separator character becomes one
|
|
5
|
+
// space, and the field is cut to a fixed length, marked with an ellipsis.
|
|
6
6
|
|
|
7
7
|
// The length the relay already cuts titles at (run titles, plan lines, the coordinator's session titles). Measured on
|
|
8
|
-
//
|
|
9
|
-
//
|
|
8
|
+
// one real board: every thread title (60, at most 120) and file name (334, at most 51) fits whole; task objectives
|
|
9
|
+
// (median 346) are cut, and get_task still gives each whole.
|
|
10
10
|
export const LINE_LIMIT = 120;
|
|
11
11
|
|
|
12
12
|
// C0 and C1 controls with DEL (Cc), the line and paragraph separators (U+2028, U+2029) and format characters that
|