volute 0.5.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{agent-Z2B6EFEQ.js → agent-7JF7MT73.js} +13 -9
- package/dist/{agent-manager-PXBKA2GK.js → agent-manager-IMZ7ZMBF.js} +4 -4
- package/dist/channel-SMCNOIVQ.js +262 -0
- package/dist/{chunk-MW2KFO3B.js → chunk-62X577Y7.js} +10 -8
- package/dist/chunk-7ACDT3P2.js +265 -0
- package/dist/{chunk-MXUCNIBG.js → chunk-BX7KI4S3.js} +68 -3
- package/dist/{up-7ILD7GU7.js → chunk-EG45HBSJ.js} +16 -4
- package/dist/{chunk-HE67X4T6.js → chunk-H7AMDUIA.js} +1 -1
- package/dist/{chunk-7L4AN5D4.js → chunk-JR4UXCTO.js} +1 -1
- package/dist/{down-O7IFZLVJ.js → chunk-LLJNZPCU.js} +48 -13
- package/dist/{chunk-5X7HGB6L.js → chunk-NKXULRSW.js} +2 -1
- package/dist/{chunk-UX25Z2ND.js → chunk-UWHWAPGO.js} +7 -0
- package/dist/{chunk-UAVD2AHX.js → chunk-W76KWE23.js} +1 -1
- package/dist/chunk-ZZOOTYXK.js +583 -0
- package/dist/cli.js +22 -21
- package/dist/{connector-LYEMXQEV.js → connector-Y7JPNROO.js} +3 -3
- package/dist/connectors/discord.js +38 -7
- package/dist/connectors/slack.js +22 -3
- package/dist/connectors/telegram.js +34 -4
- package/dist/{create-RVCZN6HE.js → create-G525LWEA.js} +2 -2
- package/dist/{daemon-client-ZY6UUN2M.js → daemon-client-442IV43D.js} +2 -2
- package/dist/daemon-restart-4HVEKYFY.js +23 -0
- package/dist/daemon.js +1042 -809
- package/dist/{delete-3QH7VYIN.js → delete-UOU4AFQN.js} +7 -3
- package/dist/down-AZVH5TCD.js +11 -0
- package/dist/{env-4D4REPJF.js → env-7GLUJCWS.js} +2 -2
- package/dist/{history-OEONB53Z.js → history-H72ZUIBN.js} +2 -2
- package/dist/{import-MXJB2EII.js → import-AVKQJDYC.js} +2 -2
- package/dist/{logs-DF342W4M.js → logs-EDGK26AK.js} +1 -1
- package/dist/{message-ADHWFHSI.js → message-SCOQDR3P.js} +2 -2
- package/dist/{package-VQOE7JNH.js → package-T2WAVJOU.js} +1 -1
- package/dist/restart-O4ETYLJF.js +29 -0
- package/dist/{schedule-NAG6F463.js → schedule-S6QVC5ON.js} +2 -2
- package/dist/send-G7PE4DOJ.js +72 -0
- package/dist/{setup-RPRRGG2F.js → setup-F4TCWVSP.js} +2 -2
- package/dist/{start-TUOXDSFL.js → start-VHQ7LNWM.js} +2 -2
- package/dist/{status-A36EHRO4.js → status-QAJWXKMZ.js} +2 -2
- package/dist/{stop-AOJZLQ5X.js → stop-CAGCT5NI.js} +2 -2
- package/dist/up-RWZF6MLT.js +12 -0
- package/dist/{update-LPSIAWQ2.js → update-F7QWV2LB.js} +2 -2
- package/dist/{update-check-Y33QDCFL.js → update-check-B4J6IEQ4.js} +2 -2
- package/dist/{upgrade-FX2TKJ2S.js → upgrade-YXKPWDRU.js} +2 -2
- package/dist/{variant-LAB67OC2.js → variant-4Z6W3PP6.js} +2 -2
- package/dist/web-assets/assets/index-B1CqjUYD.js +308 -0
- package/dist/web-assets/index.html +1 -1
- package/package.json +1 -1
- package/templates/_base/.init/.config/scripts/session-reader.ts +59 -0
- package/templates/_base/_skills/sessions/SKILL.md +49 -0
- package/templates/_base/_skills/volute-agent/SKILL.md +13 -9
- package/templates/_base/src/lib/format-prefix.ts +6 -0
- package/templates/_base/src/lib/router.ts +30 -3
- package/templates/_base/src/lib/session-monitor.ts +400 -0
- package/templates/_base/src/lib/types.ts +2 -0
- package/templates/agent-sdk/src/agent.ts +16 -0
- package/templates/agent-sdk/src/lib/hooks/session-context.ts +32 -0
- package/templates/pi/src/agent.ts +7 -1
- package/templates/pi/src/lib/session-context-extension.ts +33 -0
- package/dist/channel-MK5OK2SI.js +0 -113
- package/dist/chunk-SMISE4SV.js +0 -226
- package/dist/conversation-ERXEQZTY.js +0 -163
- package/dist/send-66QMKRUH.js +0 -75
- package/dist/web-assets/assets/index-BbRmoxoA.js +0 -308
package/dist/send-66QMKRUH.js
DELETED
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
3
|
-
readStdin
|
|
4
|
-
} from "./chunk-ZYGKG6VC.js";
|
|
5
|
-
import {
|
|
6
|
-
summarizeTool
|
|
7
|
-
} from "./chunk-B3R6L2GW.js";
|
|
8
|
-
import {
|
|
9
|
-
daemonFetch
|
|
10
|
-
} from "./chunk-7L4AN5D4.js";
|
|
11
|
-
import "./chunk-UX25Z2ND.js";
|
|
12
|
-
import "./chunk-K3NQKI34.js";
|
|
13
|
-
|
|
14
|
-
// src/commands/send.ts
|
|
15
|
-
import { userInfo } from "os";
|
|
16
|
-
async function run(args) {
|
|
17
|
-
const name = args[0];
|
|
18
|
-
const message = args[1] ?? await readStdin();
|
|
19
|
-
if (!name || !message) {
|
|
20
|
-
console.error('Usage: volute message send <name> "<message>"');
|
|
21
|
-
console.error(' echo "message" | volute message send <name>');
|
|
22
|
-
process.exit(1);
|
|
23
|
-
}
|
|
24
|
-
const agentSelf = process.env.VOLUTE_AGENT;
|
|
25
|
-
const sender = agentSelf || userInfo().username;
|
|
26
|
-
const res = await daemonFetch(`/api/agents/${encodeURIComponent(name)}/chat`, {
|
|
27
|
-
method: "POST",
|
|
28
|
-
headers: { "Content-Type": "application/json" },
|
|
29
|
-
body: JSON.stringify({ message, sender })
|
|
30
|
-
});
|
|
31
|
-
if (!res.ok) {
|
|
32
|
-
const data = await res.json();
|
|
33
|
-
console.error(data.error ?? `Failed to send message: ${res.status}`);
|
|
34
|
-
process.exit(1);
|
|
35
|
-
}
|
|
36
|
-
if (!res.body) {
|
|
37
|
-
console.error("No response body");
|
|
38
|
-
process.exit(1);
|
|
39
|
-
}
|
|
40
|
-
const reader = res.body.getReader();
|
|
41
|
-
const decoder = new TextDecoder();
|
|
42
|
-
let buffer = "";
|
|
43
|
-
while (true) {
|
|
44
|
-
const { done, value } = await reader.read();
|
|
45
|
-
if (done) break;
|
|
46
|
-
buffer += decoder.decode(value, { stream: true });
|
|
47
|
-
const lines = buffer.split("\n");
|
|
48
|
-
buffer = lines.pop() ?? "";
|
|
49
|
-
for (const line of lines) {
|
|
50
|
-
if (!line.startsWith("data:")) continue;
|
|
51
|
-
const data = line.slice(5).trim();
|
|
52
|
-
if (!data) continue;
|
|
53
|
-
let event;
|
|
54
|
-
try {
|
|
55
|
-
event = JSON.parse(data);
|
|
56
|
-
} catch {
|
|
57
|
-
continue;
|
|
58
|
-
}
|
|
59
|
-
if (event.type === "text") {
|
|
60
|
-
process.stdout.write(event.content);
|
|
61
|
-
} else if (event.type === "tool_use") {
|
|
62
|
-
process.stderr.write(`${summarizeTool(event.name, event.input)}
|
|
63
|
-
`);
|
|
64
|
-
}
|
|
65
|
-
if (event.type === "done") {
|
|
66
|
-
process.stdout.write("\n");
|
|
67
|
-
return;
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
process.stdout.write("\n");
|
|
72
|
-
}
|
|
73
|
-
export {
|
|
74
|
-
run
|
|
75
|
-
};
|