svamp-cli 0.2.91 → 0.2.93
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/dist/{agentCommands-Cq5-Dj_E.mjs → agentCommands-5UkFbjCr.mjs} +2 -2
- package/dist/{auth-DPhc_hNc.mjs → auth-DIlY0Nww.mjs} +1 -3
- package/dist/cli.mjs +66 -51
- package/dist/{commands-LfAaLGbG.mjs → commands-BjtQRoGi.mjs} +1 -3
- package/dist/{commands-kGkSBEMq.mjs → commands-D-m22ZpN.mjs} +1 -3
- package/dist/{commands-DemyBiUh.mjs → commands-Do8wtW5P.mjs} +1 -3
- package/dist/{commands-C6HpuYOB.mjs → commands-POgHLHF-.mjs} +2 -4
- package/dist/{commands-B9ssOqX0.mjs → commands-yzDiaiRy.mjs} +5 -5
- package/dist/{fleet-DRQS1weD.mjs → fleet-ChKjkV1V.mjs} +1 -3
- package/dist/{frpc-BBNWJChC.mjs → frpc-glQKHUBu.mjs} +1 -3
- package/dist/headlessCli-D2ZOlMNL.mjs +332 -0
- package/dist/index.mjs +1 -3
- package/dist/{package-GxcmHBEB.mjs → package-Caxptr7d.mjs} +2 -2
- package/dist/{run-YihZemmc.mjs → run-CuHAFrIm.mjs} +1 -3
- package/dist/{run-DWr_h85y.mjs → run-CvIUzIMP.mjs} +115 -345
- package/dist/{serveCommands-Js_HSnLs.mjs → serveCommands-1TJus4ZX.mjs} +5 -5
- package/dist/{serveManager-Dn9GyzAG.mjs → serveManager-CoVwgYS_.mjs} +2 -4
- package/dist/sideband-7glSvpTW.mjs +79 -0
- package/package.json +2 -2
|
@@ -0,0 +1,332 @@
|
|
|
1
|
+
import { E as resolveModel, N as describeMisconfiguration, O as buildMachineDeps } from './run-CvIUzIMP.mjs';
|
|
2
|
+
import { handleRealtimeEvent, initMachineVoiceSession } from './sideband-7glSvpTW.mjs';
|
|
3
|
+
import { WebSocket } from 'ws';
|
|
4
|
+
import { execSync, spawn } from 'child_process';
|
|
5
|
+
import 'os';
|
|
6
|
+
import 'fs/promises';
|
|
7
|
+
import 'fs';
|
|
8
|
+
import 'path';
|
|
9
|
+
import 'url';
|
|
10
|
+
import 'crypto';
|
|
11
|
+
import 'node:fs';
|
|
12
|
+
import 'node:child_process';
|
|
13
|
+
import 'util';
|
|
14
|
+
import 'node:crypto';
|
|
15
|
+
import 'node:path';
|
|
16
|
+
import 'node:os';
|
|
17
|
+
import '@agentclientprotocol/sdk';
|
|
18
|
+
import '@modelcontextprotocol/sdk/client/index.js';
|
|
19
|
+
import '@modelcontextprotocol/sdk/client/stdio.js';
|
|
20
|
+
import '@modelcontextprotocol/sdk/types.js';
|
|
21
|
+
import 'zod';
|
|
22
|
+
import 'node:fs/promises';
|
|
23
|
+
import 'node:util';
|
|
24
|
+
|
|
25
|
+
const PCM_RATE = 24e3;
|
|
26
|
+
function buildHeadlessSessionUpdate(cfg) {
|
|
27
|
+
const turn = cfg.vad ? {
|
|
28
|
+
type: "server_vad",
|
|
29
|
+
threshold: cfg.vad.threshold ?? 0.5,
|
|
30
|
+
prefix_padding_ms: cfg.vad.prefixPaddingMs ?? 300,
|
|
31
|
+
silence_duration_ms: cfg.vad.silenceDurationMs ?? 600
|
|
32
|
+
} : { type: "server_vad" };
|
|
33
|
+
return {
|
|
34
|
+
type: "session.update",
|
|
35
|
+
session: {
|
|
36
|
+
type: "realtime",
|
|
37
|
+
instructions: cfg.instructions,
|
|
38
|
+
tools: cfg.tools.map((t) => ({ type: "function", name: t.name, description: t.description, parameters: t.parameters })),
|
|
39
|
+
tool_choice: "auto",
|
|
40
|
+
output_modalities: ["audio"],
|
|
41
|
+
audio: {
|
|
42
|
+
input: {
|
|
43
|
+
format: { type: "audio/pcm", rate: PCM_RATE },
|
|
44
|
+
turn_detection: turn,
|
|
45
|
+
transcription: { model: "gpt-4o-mini-transcribe" }
|
|
46
|
+
},
|
|
47
|
+
output: {
|
|
48
|
+
format: { type: "audio/pcm", rate: PCM_RATE },
|
|
49
|
+
...cfg.voice ? { voice: cfg.voice } : {}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
function appendAudioEvent(pcm) {
|
|
56
|
+
return { type: "input_audio_buffer.append", audio: pcm.toString("base64") };
|
|
57
|
+
}
|
|
58
|
+
const AUDIO_DELTA_TYPES = /* @__PURE__ */ new Set(["response.output_audio.delta", "response.audio.delta"]);
|
|
59
|
+
async function handleHeadlessEvent(ev, tools, send, onAudioOut, onInterrupt, nameByCallId) {
|
|
60
|
+
if (ev?.type && AUDIO_DELTA_TYPES.has(ev.type) && typeof ev.delta === "string") {
|
|
61
|
+
onAudioOut(Buffer.from(ev.delta, "base64"));
|
|
62
|
+
return null;
|
|
63
|
+
}
|
|
64
|
+
if (ev?.type === "input_audio_buffer.speech_started") {
|
|
65
|
+
onInterrupt();
|
|
66
|
+
return null;
|
|
67
|
+
}
|
|
68
|
+
return handleRealtimeEvent(ev, tools, send, nameByCallId);
|
|
69
|
+
}
|
|
70
|
+
const realHeadlessFactory = (url, headers) => new WebSocket(url, { headers });
|
|
71
|
+
let _testHeadlessFactory;
|
|
72
|
+
async function openHeadlessSession(opts) {
|
|
73
|
+
const base = (opts.baseUrl || "https://api.openai.com").replace(/^http/, "ws").replace(/\/+$/, "");
|
|
74
|
+
const model = opts.config.model || "gpt-realtime-mini";
|
|
75
|
+
const url = `${base}/v1/realtime?model=${encodeURIComponent(model)}`;
|
|
76
|
+
const ws = (opts.wsFactory || _testHeadlessFactory || realHeadlessFactory)(url, { Authorization: `Bearer ${opts.apiKey}` });
|
|
77
|
+
const send = (e) => {
|
|
78
|
+
try {
|
|
79
|
+
ws.send(JSON.stringify(e));
|
|
80
|
+
} catch {
|
|
81
|
+
}
|
|
82
|
+
};
|
|
83
|
+
const nameByCallId = /* @__PURE__ */ new Map();
|
|
84
|
+
const idleMs = opts.idleTimeoutMs ?? 3e4;
|
|
85
|
+
let idleTimer;
|
|
86
|
+
let closed = false;
|
|
87
|
+
const closeSession = () => {
|
|
88
|
+
if (closed) return;
|
|
89
|
+
closed = true;
|
|
90
|
+
if (idleTimer) clearTimeout(idleTimer);
|
|
91
|
+
opts.audio.stopCapture();
|
|
92
|
+
try {
|
|
93
|
+
ws.close();
|
|
94
|
+
} catch {
|
|
95
|
+
}
|
|
96
|
+
};
|
|
97
|
+
const bumpIdle = () => {
|
|
98
|
+
if (idleTimer) clearTimeout(idleTimer);
|
|
99
|
+
idleTimer = setTimeout(closeSession, idleMs);
|
|
100
|
+
};
|
|
101
|
+
ws.on("open", () => {
|
|
102
|
+
send(buildHeadlessSessionUpdate(opts.config));
|
|
103
|
+
opts.audio.startCapture((pcm) => send(appendAudioEvent(pcm)));
|
|
104
|
+
bumpIdle();
|
|
105
|
+
});
|
|
106
|
+
ws.on("message", async (data) => {
|
|
107
|
+
let ev;
|
|
108
|
+
try {
|
|
109
|
+
ev = JSON.parse(typeof data === "string" ? data : data?.toString?.() ?? "");
|
|
110
|
+
} catch {
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
113
|
+
bumpIdle();
|
|
114
|
+
try {
|
|
115
|
+
const r = await handleHeadlessEvent(ev, opts.config.tools, send, (pcm) => opts.audio.play(pcm), () => opts.audio.clearPlayback(), nameByCallId);
|
|
116
|
+
if (r) opts.onTool?.(r);
|
|
117
|
+
} catch (e) {
|
|
118
|
+
opts.onError?.(e instanceof Error ? e : new Error(String(e)));
|
|
119
|
+
}
|
|
120
|
+
});
|
|
121
|
+
ws.on("close", () => {
|
|
122
|
+
closed = true;
|
|
123
|
+
if (idleTimer) clearTimeout(idleTimer);
|
|
124
|
+
opts.audio.stopCapture();
|
|
125
|
+
opts.onClose?.();
|
|
126
|
+
});
|
|
127
|
+
ws.on("error", (e) => opts.onError?.(e instanceof Error ? e : new Error(String(e))));
|
|
128
|
+
return { close: closeSession };
|
|
129
|
+
}
|
|
130
|
+
function runHeadlessVoice(opts) {
|
|
131
|
+
let current = null;
|
|
132
|
+
let stopped = false;
|
|
133
|
+
const openOne = async () => {
|
|
134
|
+
if (stopped || current) return;
|
|
135
|
+
try {
|
|
136
|
+
current = await openHeadlessSession({
|
|
137
|
+
...opts,
|
|
138
|
+
onClose: () => {
|
|
139
|
+
current = null;
|
|
140
|
+
opts.onClose?.();
|
|
141
|
+
}
|
|
142
|
+
});
|
|
143
|
+
} catch (e) {
|
|
144
|
+
opts.onError?.(e instanceof Error ? e : new Error(String(e)));
|
|
145
|
+
}
|
|
146
|
+
};
|
|
147
|
+
if (opts.wakeWord) {
|
|
148
|
+
opts.wakeWord.start(() => {
|
|
149
|
+
void openOne();
|
|
150
|
+
});
|
|
151
|
+
} else {
|
|
152
|
+
void openOne();
|
|
153
|
+
}
|
|
154
|
+
return {
|
|
155
|
+
stop: () => {
|
|
156
|
+
stopped = true;
|
|
157
|
+
opts.wakeWord?.stop();
|
|
158
|
+
current?.close();
|
|
159
|
+
current = null;
|
|
160
|
+
}
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
const RAW = ["-q", "-t", "raw", "-r", String(PCM_RATE), "-b", "16", "-e", "signed-integer", "-c", "1"];
|
|
165
|
+
function soxAvailable() {
|
|
166
|
+
try {
|
|
167
|
+
execSync("command -v sox", { stdio: "ignore" });
|
|
168
|
+
return true;
|
|
169
|
+
} catch {
|
|
170
|
+
return false;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
function createSoxAudioAdapter() {
|
|
174
|
+
if (!soxAvailable()) {
|
|
175
|
+
throw new Error("headless voice needs `sox` (raw PCM mic/speaker bridge). Install it: macOS `brew install sox`, Debian `apt install sox`.");
|
|
176
|
+
}
|
|
177
|
+
let capture = null;
|
|
178
|
+
let playback = null;
|
|
179
|
+
const startPlayback = () => {
|
|
180
|
+
playback = spawn("sox", [...RAW, "-", "-d"], { stdio: ["pipe", "ignore", "ignore"] });
|
|
181
|
+
playback.on("error", () => {
|
|
182
|
+
playback = null;
|
|
183
|
+
});
|
|
184
|
+
};
|
|
185
|
+
return {
|
|
186
|
+
startCapture(onChunk) {
|
|
187
|
+
if (capture) return;
|
|
188
|
+
capture = spawn("sox", ["-d", ...RAW, "-"], { stdio: ["ignore", "pipe", "ignore"] });
|
|
189
|
+
capture.stdout?.on("data", (buf) => onChunk(buf));
|
|
190
|
+
capture.on("error", () => {
|
|
191
|
+
capture = null;
|
|
192
|
+
});
|
|
193
|
+
},
|
|
194
|
+
stopCapture() {
|
|
195
|
+
try {
|
|
196
|
+
capture?.kill("SIGTERM");
|
|
197
|
+
} catch {
|
|
198
|
+
}
|
|
199
|
+
capture = null;
|
|
200
|
+
},
|
|
201
|
+
play(pcm) {
|
|
202
|
+
if (!playback) startPlayback();
|
|
203
|
+
try {
|
|
204
|
+
playback?.stdin?.write(pcm);
|
|
205
|
+
} catch {
|
|
206
|
+
playback = null;
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
clearPlayback() {
|
|
210
|
+
try {
|
|
211
|
+
playback?.kill("SIGTERM");
|
|
212
|
+
} catch {
|
|
213
|
+
}
|
|
214
|
+
playback = null;
|
|
215
|
+
},
|
|
216
|
+
close() {
|
|
217
|
+
try {
|
|
218
|
+
capture?.kill("SIGTERM");
|
|
219
|
+
} catch {
|
|
220
|
+
}
|
|
221
|
+
try {
|
|
222
|
+
playback?.kill("SIGTERM");
|
|
223
|
+
} catch {
|
|
224
|
+
}
|
|
225
|
+
capture = null;
|
|
226
|
+
playback = null;
|
|
227
|
+
}
|
|
228
|
+
};
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
async function createPorcupineWakeWord(opts) {
|
|
232
|
+
if (!opts.accessKey) throw new Error("wake-word needs PICOVOICE_ACCESS_KEY (free at console.picovoice.ai).");
|
|
233
|
+
let Porcupine, BuiltinKeyword, PvRecorder;
|
|
234
|
+
try {
|
|
235
|
+
({ Porcupine, BuiltinKeyword } = await import('@picovoice/porcupine-node'));
|
|
236
|
+
({ PvRecorder } = await import('@picovoice/pvrecorder-node'));
|
|
237
|
+
} catch {
|
|
238
|
+
throw new Error("wake-word needs the Picovoice modules: `yarn add @picovoice/porcupine-node @picovoice/pvrecorder-node`.");
|
|
239
|
+
}
|
|
240
|
+
const keywords = opts.keywordPath ? [opts.keywordPath] : [opts.builtinKeyword || BuiltinKeyword.PORCUPINE];
|
|
241
|
+
const sensitivities = [opts.sensitivity ?? 0.5];
|
|
242
|
+
const porcupine = new Porcupine(opts.accessKey, keywords, sensitivities);
|
|
243
|
+
const recorder = new PvRecorder(porcupine.frameLength, opts.deviceIndex ?? -1);
|
|
244
|
+
let running = false;
|
|
245
|
+
return {
|
|
246
|
+
start(onWake) {
|
|
247
|
+
if (running) return;
|
|
248
|
+
running = true;
|
|
249
|
+
recorder.start();
|
|
250
|
+
(async () => {
|
|
251
|
+
while (running) {
|
|
252
|
+
let frame;
|
|
253
|
+
try {
|
|
254
|
+
frame = await recorder.read();
|
|
255
|
+
} catch {
|
|
256
|
+
break;
|
|
257
|
+
}
|
|
258
|
+
if (!running) break;
|
|
259
|
+
if (porcupine.process(frame) >= 0) onWake();
|
|
260
|
+
}
|
|
261
|
+
})();
|
|
262
|
+
},
|
|
263
|
+
stop() {
|
|
264
|
+
running = false;
|
|
265
|
+
try {
|
|
266
|
+
recorder.stop();
|
|
267
|
+
} catch {
|
|
268
|
+
}
|
|
269
|
+
try {
|
|
270
|
+
recorder.release?.();
|
|
271
|
+
} catch {
|
|
272
|
+
}
|
|
273
|
+
try {
|
|
274
|
+
porcupine.release?.();
|
|
275
|
+
} catch {
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
};
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
async function runWiseVoiceCli(opts = {}) {
|
|
282
|
+
const resolved = resolveModel({ provider: "openai" }, process.env);
|
|
283
|
+
const mis = describeMisconfiguration(resolved);
|
|
284
|
+
if (mis || !resolved.apiKey) {
|
|
285
|
+
console.error(`\u2717 ${mis || "No OpenAI API key on this machine."}
|
|
286
|
+
Configure it: svamp wise-agent auth use-openai <KEY> (or set OPENAI_API_KEY in ~/.svamp/.env)`);
|
|
287
|
+
process.exit(1);
|
|
288
|
+
}
|
|
289
|
+
if (!soxAvailable()) {
|
|
290
|
+
console.error("\u2717 headless voice needs `sox` for the mic/speaker bridge.\n macOS: brew install sox Debian/Ubuntu: sudo apt install sox");
|
|
291
|
+
process.exit(1);
|
|
292
|
+
}
|
|
293
|
+
const deps = buildMachineDeps({}, { cwd: process.env.HOME });
|
|
294
|
+
const { tools, sessionUpdate } = await initMachineVoiceSession({ deps, role: "admin", voice: opts.voice });
|
|
295
|
+
const instructions = sessionUpdate.session.instructions;
|
|
296
|
+
let wakeWord;
|
|
297
|
+
if (opts.wakeKeywordPath) {
|
|
298
|
+
try {
|
|
299
|
+
wakeWord = await createPorcupineWakeWord({ accessKey: process.env.PICOVOICE_ACCESS_KEY || "", keywordPath: opts.wakeKeywordPath });
|
|
300
|
+
} catch (e) {
|
|
301
|
+
console.error(`\u2717 wake-word: ${e.message}`);
|
|
302
|
+
process.exit(1);
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
const audio = createSoxAudioAdapter();
|
|
306
|
+
console.log(`\u25CF WISE headless voice \u2014 ${tools.length} tools | model ${opts.model || resolved.model || "gpt-realtime-mini"} | ${wakeWord ? `wake: "${opts.wakeKeywordPath}"` : "always-listening (Ctrl-C to stop)"}`);
|
|
307
|
+
const loop = runHeadlessVoice({
|
|
308
|
+
apiKey: resolved.apiKey,
|
|
309
|
+
baseUrl: resolved.baseUrl,
|
|
310
|
+
config: { instructions, tools, voice: opts.voice, model: opts.model || resolved.model },
|
|
311
|
+
audio,
|
|
312
|
+
wakeWord,
|
|
313
|
+
onTool: (t) => console.log(` \u21B3 ${t.name}: ${t.output.slice(0, 120).replace(/\n/g, " ")}`),
|
|
314
|
+
onError: (e) => console.error(` ! ${e.message}`)
|
|
315
|
+
});
|
|
316
|
+
const shutdown = () => {
|
|
317
|
+
console.log("\nstopping\u2026");
|
|
318
|
+
try {
|
|
319
|
+
loop.stop();
|
|
320
|
+
} catch {
|
|
321
|
+
}
|
|
322
|
+
try {
|
|
323
|
+
audio.close();
|
|
324
|
+
} catch {
|
|
325
|
+
}
|
|
326
|
+
process.exit(0);
|
|
327
|
+
};
|
|
328
|
+
process.on("SIGINT", shutdown);
|
|
329
|
+
process.on("SIGTERM", shutdown);
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
export { runWiseVoiceCli };
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { c as connectToHypha, d as daemonStatus, g as getHyphaServerUrl, r as registerMachineService, a as registerSessionService, s as startDaemon, b as stopDaemon } from './run-
|
|
1
|
+
export { c as connectToHypha, d as daemonStatus, g as getHyphaServerUrl, r as registerMachineService, a as registerSessionService, s as startDaemon, b as stopDaemon } from './run-CvIUzIMP.mjs';
|
|
2
2
|
import 'os';
|
|
3
3
|
import 'fs/promises';
|
|
4
4
|
import 'fs';
|
|
@@ -7,9 +7,7 @@ import 'url';
|
|
|
7
7
|
import 'child_process';
|
|
8
8
|
import 'crypto';
|
|
9
9
|
import 'node:fs';
|
|
10
|
-
import 'node:vm';
|
|
11
10
|
import 'node:child_process';
|
|
12
|
-
import 'ws';
|
|
13
11
|
import 'util';
|
|
14
12
|
import 'node:crypto';
|
|
15
13
|
import 'node:path';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var name = "svamp-cli";
|
|
2
|
-
var version = "0.2.
|
|
2
|
+
var version = "0.2.93";
|
|
3
3
|
var description = "Svamp CLI — AI workspace daemon on Hypha Cloud";
|
|
4
4
|
var author = "Amun AI AB";
|
|
5
5
|
var license = "SEE LICENSE IN LICENSE";
|
|
@@ -19,7 +19,7 @@ var exports$1 = {
|
|
|
19
19
|
var scripts = {
|
|
20
20
|
build: "rm -rf dist bin/skills && mkdir -p bin/skills && cp -r ../../skills/artifact bin/skills/artifact && tsc --noEmit && pkgroll",
|
|
21
21
|
typecheck: "tsc --noEmit",
|
|
22
|
-
test: "npx tsx test/test-context-window.mjs && npx tsx test/test-instance-config.mjs && npx tsx test/test-authorize.mjs && npx tsx test/test-normalize-allowed-user.mjs && npx tsx test/test-share-url.mjs && npx tsx test/test-update-sharing-normalization.mjs && npx tsx test/test-staged-homes-sweep.mjs && npx tsx test/test-session-helpers.mjs && npx tsx test/test-cli-routing.mjs && npx tsx test/test-security-context.mjs && npx tsx test/test-isolation-decision.mjs && npx tsx test/test-ralph-loop.mjs && npx tsx test/test-message-helpers.mjs && npx tsx test/test-agent-config.mjs && npx tsx test/test-wrap-command.mjs && npx tsx test/test-credential-staging.mjs && npx tsx test/test-claude-auth.mjs && npx tsx test/test-output-formatters.mjs && npx tsx test/test-inbox-guard.mjs && npx tsx test/test-agent-types.mjs && npx tsx test/test-transport.mjs && npx tsx test/test-session-update-handlers.mjs && npx tsx test/test-session-scanner.mjs && npx tsx test/test-hypha-client.mjs && npx tsx test/test-hook-settings.mjs && npx tsx test/test-session-service-logic.mjs && npx tsx test/test-daemon-persistence.mjs && npx tsx test/test-detect-isolation.mjs && npx tsx test/test-machine-service-logic.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-backend.mjs && npx tsx test/test-acp-backend.mjs && npx tsx test/test-acp-bridge.mjs && npx tsx test/test-hook-server.mjs && npx tsx test/test-session-commands.mjs && npx tsx test/test-interactive-console.mjs && npx tsx test/test-session-messages.mjs && npx tsx test/test-session-send-query.mjs && npx tsx test/test-skills.mjs && npx tsx test/test-agent-grouping.mjs && npx tsx test/test-ralph-loop-integration.mjs && npx tsx test/test-ralph-loop-modes.mjs && npx tsx test/test-machine-list-directory.mjs && npx tsx test/test-service-commands.mjs && npx tsx test/test-supervisor.mjs && npx tsx test/test-supervisor-lock.mjs && node test/test-supervisor-restart.mjs && npx tsx test/test-clear-detection.mjs && npx tsx test/test-session-consolidation.mjs && npx tsx test/test-inbox.mjs && npx tsx test/test-session-rpc-dispatch.mjs && npx tsx test/test-sandbox-cli.mjs && npx tsx test/test-serve-manager.mjs && npx tsx test/test-serve-stability.mjs && npx tsx test/test-frpc-e2e.mjs --unit-only && node test/pinnedClaudeCode.test.mjs && node test/fleet.test.mjs && npx tsx test/test-routine.mjs && npx tsx test/test-routine-rpc.mjs && npx tsx test/test-session-file.mjs && npx tsx test/test-channel-rpc.mjs && npx tsx test/test-wise-agent.mjs && npx tsx test/test-channel-agent.mjs && npx tsx test/test-channels-service.mjs && npx tsx test/test-wise-
|
|
22
|
+
test: "npx tsx test/test-context-window.mjs && npx tsx test/test-instance-config.mjs && npx tsx test/test-authorize.mjs && npx tsx test/test-normalize-allowed-user.mjs && npx tsx test/test-share-url.mjs && npx tsx test/test-update-sharing-normalization.mjs && npx tsx test/test-staged-homes-sweep.mjs && npx tsx test/test-session-helpers.mjs && npx tsx test/test-cli-routing.mjs && npx tsx test/test-security-context.mjs && npx tsx test/test-isolation-decision.mjs && npx tsx test/test-ralph-loop.mjs && npx tsx test/test-message-helpers.mjs && npx tsx test/test-agent-config.mjs && npx tsx test/test-wrap-command.mjs && npx tsx test/test-credential-staging.mjs && npx tsx test/test-claude-auth.mjs && npx tsx test/test-output-formatters.mjs && npx tsx test/test-inbox-guard.mjs && npx tsx test/test-agent-types.mjs && npx tsx test/test-transport.mjs && npx tsx test/test-session-update-handlers.mjs && npx tsx test/test-session-scanner.mjs && npx tsx test/test-hypha-client.mjs && npx tsx test/test-hook-settings.mjs && npx tsx test/test-session-service-logic.mjs && npx tsx test/test-daemon-persistence.mjs && npx tsx test/test-detect-isolation.mjs && npx tsx test/test-machine-service-logic.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-backend.mjs && npx tsx test/test-acp-backend.mjs && npx tsx test/test-acp-bridge.mjs && npx tsx test/test-hook-server.mjs && npx tsx test/test-session-commands.mjs && npx tsx test/test-interactive-console.mjs && npx tsx test/test-session-messages.mjs && npx tsx test/test-session-send-query.mjs && npx tsx test/test-skills.mjs && npx tsx test/test-agent-grouping.mjs && npx tsx test/test-ralph-loop-integration.mjs && npx tsx test/test-ralph-loop-modes.mjs && npx tsx test/test-machine-list-directory.mjs && npx tsx test/test-service-commands.mjs && npx tsx test/test-supervisor.mjs && npx tsx test/test-supervisor-lock.mjs && node test/test-supervisor-restart.mjs && npx tsx test/test-clear-detection.mjs && npx tsx test/test-session-consolidation.mjs && npx tsx test/test-inbox.mjs && npx tsx test/test-session-rpc-dispatch.mjs && npx tsx test/test-sandbox-cli.mjs && npx tsx test/test-serve-manager.mjs && npx tsx test/test-serve-stability.mjs && npx tsx test/test-frpc-e2e.mjs --unit-only && node test/pinnedClaudeCode.test.mjs && node test/fleet.test.mjs && npx tsx test/test-routine.mjs && npx tsx test/test-routine-rpc.mjs && npx tsx test/test-session-file.mjs && npx tsx test/test-channel-rpc.mjs && npx tsx test/test-wise-agent.mjs && npx tsx test/test-channel-agent.mjs && npx tsx test/test-channels-service.mjs && npx tsx test/test-wise-agent-auth.mjs && npx tsx test/test-channel-http.mjs && npx tsx test/test-wise-voice.mjs && npx tsx test/test-wise-headless.mjs && npx tsx test/test-wise-machine.mjs",
|
|
23
23
|
"test:hypha": "node --no-warnings test/test-hypha-service.mjs",
|
|
24
24
|
dev: "tsx src/cli.ts",
|
|
25
25
|
"dev:daemon": "tsx src/cli.ts daemon start-sync",
|
|
@@ -2,7 +2,7 @@ import{createRequire as _pkgrollCR}from"node:module";const require=_pkgrollCR(im
|
|
|
2
2
|
import os from 'node:os';
|
|
3
3
|
import { resolve, join } from 'node:path';
|
|
4
4
|
import { existsSync, readFileSync, watch } from 'node:fs';
|
|
5
|
-
import { c as connectToHypha, a as registerSessionService,
|
|
5
|
+
import { c as connectToHypha, a as registerSessionService, P as generateHookSettings } from './run-CvIUzIMP.mjs';
|
|
6
6
|
import { createServer } from 'node:http';
|
|
7
7
|
import { spawn } from 'node:child_process';
|
|
8
8
|
import { createInterface } from 'node:readline';
|
|
@@ -13,8 +13,6 @@ import 'path';
|
|
|
13
13
|
import 'url';
|
|
14
14
|
import 'child_process';
|
|
15
15
|
import 'crypto';
|
|
16
|
-
import 'node:vm';
|
|
17
|
-
import 'ws';
|
|
18
16
|
import 'util';
|
|
19
17
|
import '@agentclientprotocol/sdk';
|
|
20
18
|
import '@modelcontextprotocol/sdk/client/index.js';
|