volute 0.34.0 → 0.35.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.
Files changed (209) hide show
  1. package/README.md +7 -6
  2. package/dist/accept-ZBDVVCEU.js +42 -0
  3. package/dist/{activity-events-BN7V6KCC.js → activity-events-ZW4SDL2C.js} +4 -4
  4. package/dist/{ai-service-PSILB5WD.js → ai-service-LURBEDDB.js} +5 -5
  5. package/dist/{api-client-XUXOB7LI.js → api-client-3A77HMH7.js} +1 -1
  6. package/dist/api.d.ts +1 -5618
  7. package/dist/{archive-C2VEMQOR.js → archive-ESU2FUN4.js} +3 -3
  8. package/dist/{auth-ZFZXJZDQ.js → auth-WX4TESEI.js} +5 -5
  9. package/dist/bridge-PXIO6PS2.js +206 -0
  10. package/dist/chat-QXAJF3FU.js +51 -0
  11. package/dist/{chunk-7F2SW2KD.js → chunk-2TGZJFAT.js} +3 -3
  12. package/dist/{chunk-6LXAAQ43.js → chunk-33ODGMFZ.js} +1 -1
  13. package/dist/{chunk-4JSR7YO7.js → chunk-5N7Y5WAM.js} +1 -1
  14. package/dist/{chunk-FYCALD4Q.js → chunk-5T5YMX6S.js} +1 -1
  15. package/dist/{chunk-B2BVAIZ4.js → chunk-5XJYUFZH.js} +21 -15
  16. package/dist/{chunk-M3K5AARV.js → chunk-A2ZLHBHG.js} +2 -2
  17. package/dist/{chunk-U5BTYSAL.js → chunk-AN2W47GW.js} +2 -2
  18. package/dist/{chunk-G53F3JA4.js → chunk-AOB6GVRM.js} +1 -1
  19. package/dist/{chunk-N7BLAHNE.js → chunk-BDYXIWA5.js} +5 -5
  20. package/dist/{chunk-YUIHSKR6.js → chunk-BKF4WQCY.js} +2 -2
  21. package/dist/{chunk-6OWJXUAR.js → chunk-BMZQYACC.js} +2 -2
  22. package/dist/{chunk-NAOW2CLO.js → chunk-BTY4WNFE.js} +1 -1
  23. package/dist/{chunk-MLOQKQNB.js → chunk-BV65KRHM.js} +2 -2
  24. package/dist/{chunk-XWXBJQBE.js → chunk-CORXD635.js} +4 -4
  25. package/dist/{chunk-PVY5W6QN.js → chunk-F7ZNLYKZ.js} +2 -2
  26. package/dist/{chunk-BFWHBQK4.js → chunk-FT5KETXZ.js} +3 -3
  27. package/dist/{chunk-N3DNFPVA.js → chunk-IJHIXLVN.js} +8 -8
  28. package/dist/{chunk-V6ZCNULL.js → chunk-J6CJQDWI.js} +37 -28
  29. package/dist/{chunk-4RQBJWQX.js → chunk-LOPXTW6H.js} +1 -1
  30. package/dist/{chunk-47ZPNLF4.js → chunk-MDJGMOSD.js} +8 -137
  31. package/dist/{chunk-BTWAGDV5.js → chunk-N446KRP7.js} +3 -3
  32. package/dist/{chunk-6WAWMWR5.js → chunk-N5LMGYXX.js} +2 -2
  33. package/dist/{chunk-G6BSYHPK.js → chunk-NJK5SDGR.js} +1 -1
  34. package/dist/{chunk-D424ZQGI.js → chunk-O7IGP7ZW.js} +11 -3
  35. package/dist/{chunk-2IOP6PHB.js → chunk-OTC67N2Z.js} +2 -2
  36. package/dist/{chunk-V45JXOWY.js → chunk-PWQ2ITYG.js} +4 -4
  37. package/dist/{chunk-KTLFDYPT.js → chunk-QCH6K235.js} +1 -1
  38. package/dist/chunk-QHG4OMZL.js +145 -0
  39. package/dist/{chunk-IS7WJ56Q.js → chunk-QWTR6AWZ.js} +3 -3
  40. package/dist/chunk-TXSA4Q3V.js +116 -0
  41. package/dist/{chunk-BDK73LK6.js → chunk-VHJRZM2S.js} +2 -2
  42. package/dist/{chunk-SSI47XP2.js → chunk-VHWGEJ4V.js} +1 -1
  43. package/dist/chunk-VY3RB2V7.js +164 -0
  44. package/dist/chunk-WJPROOU5.js +8314 -0
  45. package/dist/{chunk-E5C7OWZ2.js → chunk-WZRZFFCL.js} +8 -8
  46. package/dist/{chunk-BM474GX6.js → chunk-XRQSAMX2.js} +4 -4
  47. package/dist/{chunk-OYAKCAVY.js → chunk-ZSR72JB3.js} +1 -1
  48. package/dist/{chunk-PLDWHR4D.js → chunk-ZX7EAV5J.js} +17 -7
  49. package/dist/cli.js +90 -29
  50. package/dist/clock-HSEKS5AR.js +289 -0
  51. package/dist/{cloud-sync-TG3TIX5H.js → cloud-sync-6JL4C24T.js} +21 -22
  52. package/dist/config-UTS7QULS.js +76 -0
  53. package/dist/connectors/discord-bridge.js +3 -3
  54. package/dist/connectors/slack-bridge.js +3 -3
  55. package/dist/connectors/telegram-bridge.js +3 -3
  56. package/dist/{conversations-HL2JP5GI.js → conversations-2PW57WO2.js} +5 -5
  57. package/dist/create-5BPOOJAN.js +75 -0
  58. package/dist/create-UVCK2CS6.js +50 -0
  59. package/dist/daemon-client-RVIKXGFQ.js +12 -0
  60. package/dist/daemon-restart-HSZ3BCX5.js +65 -0
  61. package/dist/daemon.js +845 -1766
  62. package/dist/{db-PLEDCBHZ.js → db-BDMH4SZ2.js} +7 -3
  63. package/dist/{db-RYX3SS2W.js → db-BVBJ57TU.js} +2 -2
  64. package/dist/delete-L5PAVDGQ.js +42 -0
  65. package/dist/delivery-manager-H5ZVBMCQ.js +31 -0
  66. package/dist/{delivery-router-D5ELDMS2.js → delivery-router-HEJSJAHQ.js} +4 -4
  67. package/dist/down-74VXM45A.js +17 -0
  68. package/dist/env-E4XHO2BI.js +223 -0
  69. package/dist/{exec-DVLXKRIO.js → exec-PY7THYH4.js} +4 -4
  70. package/dist/export-OAS6QVBN.js +113 -0
  71. package/dist/{extension-PM42QCID.js → extension-D74CNM7G.js} +25 -33
  72. package/dist/{extensions-BBGVL5JC.js → extensions-XDDFY72A.js} +22 -11
  73. package/dist/files-CWTK6V3H.js +53 -0
  74. package/dist/import-5A3T7QV4.js +143 -0
  75. package/dist/{isolation-62MKDZN3.js → isolation-TK5RX2WM.js} +3 -3
  76. package/dist/join-DF5XSJAC.js +67 -0
  77. package/dist/list-PDMQM7ZV.js +53 -0
  78. package/dist/login-7TE6CIZF.js +60 -0
  79. package/dist/login-GOTAYLXP.js +51 -0
  80. package/dist/logout-6KIA74EV.js +29 -0
  81. package/dist/logout-T4XS6LRU.js +50 -0
  82. package/dist/message-delivery-GRC4W6P7.js +41 -0
  83. package/dist/mind-5IEYKV7I.js +97 -0
  84. package/dist/{mind-activity-tracker-2ACNHA7B.js → mind-activity-tracker-QBLIV7ZJ.js} +5 -5
  85. package/dist/{mind-history-WOYFLQAI.js → mind-history-IE2QH7U5.js} +82 -71
  86. package/dist/mind-list-GEWHWAL4.js +38 -0
  87. package/dist/mind-manager-HFLB5653.js +31 -0
  88. package/dist/mind-profile-DCBDVF5B.js +53 -0
  89. package/dist/mind-service-X2CAA6W6.js +37 -0
  90. package/dist/mind-sleep-ITCF6OQA.js +47 -0
  91. package/dist/mind-status-X4SX3YUG.js +65 -0
  92. package/dist/mind-wake-KXMKMGWX.js +42 -0
  93. package/dist/{package-V2WHWVG6.js → package-D2FSVFAX.js} +5 -5
  94. package/dist/read-67VRP2DO.js +91 -0
  95. package/dist/{read-stdin-PIRM6A2Y.js → read-stdin-3X5VYKNS.js} +1 -1
  96. package/dist/register-SB7NXCOE.js +51 -0
  97. package/dist/{registry-UYV5S6QT.js → registry-GBSNW3HG.js} +2 -2
  98. package/dist/reject-MUR2KWJ4.js +40 -0
  99. package/dist/restart-5EGG4JXU.js +42 -0
  100. package/dist/{sandbox-SI5HMBP3.js → sandbox-R37VIU36.js} +5 -5
  101. package/dist/scheduler-Y7O4CJXL.js +31 -0
  102. package/dist/{schema-ETMABTW4.js → schema-XVZ2CLKW.js} +1 -1
  103. package/dist/{seed-WNGI6PNW.js → seed-EQORWX77.js} +2 -2
  104. package/dist/seed-check-KJNTL72M.js +35 -0
  105. package/dist/seed-cmd-ZM2XGVU2.js +30 -0
  106. package/dist/seed-create-DRWGGHEI.js +113 -0
  107. package/dist/seed-sprout-JYXGXOP3.js +148 -0
  108. package/dist/send-JBJJQ7CA.js +409 -0
  109. package/dist/service-WNPCNHOX.js +121 -0
  110. package/dist/{setup-Z3DEVWV7.js → setup-BJ4YAY26.js} +153 -127
  111. package/dist/{setup-GGMKENLN.js → setup-RHJRFURI.js} +3 -3
  112. package/dist/skill-TAAKEYBV.js +389 -0
  113. package/dist/skills/volute-mind/SKILL.md +3 -7
  114. package/dist/skills/volute-mind/references/extensions.md +8 -11
  115. package/dist/{skills-Q6VZ2UGD.js → skills-EKMCQ46K.js} +7 -7
  116. package/dist/sleep-manager-7KFK3USC.js +35 -0
  117. package/dist/spirit-ZFRDXMG7.js +23 -0
  118. package/dist/split-AWVOYOPZ.js +64 -0
  119. package/dist/{sprout-E3HJIV2Z.js → sprout-HE4TITMK.js} +2 -2
  120. package/dist/start-3UXOPXQG.js +39 -0
  121. package/dist/status-ZK34WYIM.js +125 -0
  122. package/dist/stop-3XYIBGFM.js +41 -0
  123. package/dist/system-chat-IDPHYHY4.js +35 -0
  124. package/dist/systems-O43WGQY6.js +52 -0
  125. package/dist/{tailscale-ZEUK7GKZ.js → tailscale-ZIZ2HWJ5.js} +4 -4
  126. package/dist/{template-hash-EJRTKE36.js → template-hash-A7FNHTB7.js} +2 -2
  127. package/dist/up-77ICEDEW.js +19 -0
  128. package/dist/update-ANE5ZM7F.js +225 -0
  129. package/dist/{update-check-X3YG4WVP.js → update-check-UV55CBEP.js} +3 -3
  130. package/dist/upgrade-ZMDGC7M2.js +74 -0
  131. package/dist/variant-QWL2WSRI.js +62 -0
  132. package/dist/{version-notify-YCH4UVQ2.js → version-notify-FXSEMXWW.js} +28 -27
  133. package/dist/{volute-config-WBKYJGYQ.js → volute-config-D2XVS2YI.js} +1 -1
  134. package/dist/web-assets/assets/index-BhxWKvbB.css +1 -0
  135. package/dist/web-assets/assets/index-CHVKJ9II.js +75 -0
  136. package/dist/web-assets/index.html +2 -2
  137. package/dist/web-assets/sw.js +117 -0
  138. package/package.json +5 -5
  139. package/packages/extensions/pages/dist/ui/assets/index-DKZLNMED.js +2 -0
  140. package/packages/extensions/pages/dist/ui/index.html +1 -1
  141. package/packages/extensions/pages/skills/pages/SKILL.md +84 -9
  142. package/templates/_base/src/lib/auto-commit.ts +8 -8
  143. package/templates/_base/src/lib/volute-server.ts +6 -0
  144. package/templates/claude/src/agent.ts +8 -1
  145. package/dist/accept-TW6V4WI4.js +0 -42
  146. package/dist/bridge-O753D5F4.js +0 -207
  147. package/dist/chat-BHYX7DJ4.js +0 -68
  148. package/dist/chunk-47XDEWWV.js +0 -156
  149. package/dist/chunk-CVL5IGIR.js +0 -2084
  150. package/dist/chunk-PB65JZK2.js +0 -85
  151. package/dist/chunk-TAHX36HZ.js +0 -3679
  152. package/dist/clock-3X4DSC2N.js +0 -281
  153. package/dist/config-OROA5DUA.js +0 -72
  154. package/dist/create-3SEKKI6P.js +0 -71
  155. package/dist/create-UOSOQ2HN.js +0 -44
  156. package/dist/daemon-client-WOAQXXBM.js +0 -12
  157. package/dist/daemon-restart-5ABHNXJZ.js +0 -52
  158. package/dist/delete-KYOVWR23.js +0 -35
  159. package/dist/delivery-manager-2BR5NZKF.js +0 -32
  160. package/dist/down-QVFN4UPK.js +0 -15
  161. package/dist/env-R34DT7XL.js +0 -195
  162. package/dist/export-6ZXAXATG.js +0 -112
  163. package/dist/files-VQV2VZQO.js +0 -47
  164. package/dist/import-MK2I2T6F.js +0 -23
  165. package/dist/join-DGYHTJUH.js +0 -66
  166. package/dist/list-C644WTHV.js +0 -49
  167. package/dist/login-IIGEQPHL.js +0 -47
  168. package/dist/login-KZQLMAWE.js +0 -47
  169. package/dist/logout-AGTZVRGP.js +0 -40
  170. package/dist/logout-KD6GXIJJ.js +0 -21
  171. package/dist/message-delivery-V3R6NXJP.js +0 -42
  172. package/dist/mind-BI4EPBVZ.js +0 -108
  173. package/dist/mind-list-6VPM7GUQ.js +0 -30
  174. package/dist/mind-manager-MWW3BTS4.js +0 -32
  175. package/dist/mind-profile-WPG42U5Y.js +0 -47
  176. package/dist/mind-service-VIKZJK2M.js +0 -38
  177. package/dist/mind-sleep-XDISJY74.js +0 -42
  178. package/dist/mind-status-7FTZWPZF.js +0 -56
  179. package/dist/mind-wake-KIIKEI3A.js +0 -37
  180. package/dist/read-H5C26YO7.js +0 -85
  181. package/dist/register-J27WP33N.js +0 -47
  182. package/dist/reject-OEANJYIA.js +0 -40
  183. package/dist/restart-V5EGYBJG.js +0 -33
  184. package/dist/scheduler-AGG3L2FO.js +0 -32
  185. package/dist/seed-check-PXTH7YXS.js +0 -32
  186. package/dist/seed-cmd-VENFTGS3.js +0 -36
  187. package/dist/seed-create-663ALOKH.js +0 -112
  188. package/dist/seed-sprout-EH3AGKAI.js +0 -132
  189. package/dist/send-7FUUUZZH.js +0 -386
  190. package/dist/skill-DKNYJS4P.js +0 -362
  191. package/dist/skills/shared-files/SKILL.md +0 -44
  192. package/dist/skills/shared-files/scripts/merge.ts +0 -72
  193. package/dist/skills/shared-files/scripts/pull.ts +0 -52
  194. package/dist/sleep-manager-BJK2ROPX.js +0 -36
  195. package/dist/spirit-4JP4TY4C.js +0 -23
  196. package/dist/split-3YPMS2CL.js +0 -63
  197. package/dist/start-W3TPKX4D.js +0 -33
  198. package/dist/status-4OVFXFEJ.js +0 -115
  199. package/dist/stop-GTT6YWYO.js +0 -32
  200. package/dist/system-channel-DXD2JBOU.js +0 -36
  201. package/dist/system-chat-TYLOL7SX.js +0 -36
  202. package/dist/systems-AYLO727G.js +0 -61
  203. package/dist/up-PA7F2CXE.js +0 -18
  204. package/dist/update-HG4LCUSG.js +0 -215
  205. package/dist/upgrade-YGNIDICG.js +0 -67
  206. package/dist/variant-MZUMRTQO.js +0 -41
  207. package/dist/web-assets/assets/index-DiiwC-CZ.css +0 -1
  208. package/dist/web-assets/assets/index-d6y5b9Ij.js +0 -75
  209. package/packages/extensions/pages/dist/ui/assets/index-tLTROSk5.js +0 -2
@@ -1,195 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- isCompact
4
- } from "./chunk-FYCALD4Q.js";
5
- import {
6
- promptLine
7
- } from "./chunk-SSI47XP2.js";
8
- import {
9
- getClient,
10
- urlOf
11
- } from "./chunk-4RQBJWQX.js";
12
- import {
13
- parseArgs
14
- } from "./chunk-D424ZQGI.js";
15
- import {
16
- daemonFetch
17
- } from "./chunk-PLDWHR4D.js";
18
- import "./chunk-N7BLAHNE.js";
19
- import "./chunk-4JSR7YO7.js";
20
- import "./chunk-7KJOFUNN.js";
21
-
22
- // src/commands/env.ts
23
- function maskValue(value) {
24
- if (value.length <= 6) return "***";
25
- return `${value.slice(0, 3)}...${value.slice(-3)}`;
26
- }
27
- async function run(args) {
28
- const { positional, flags } = parseArgs(args, {
29
- mind: { type: "string" },
30
- reveal: { type: "boolean" }
31
- });
32
- const subcommand = positional[0];
33
- const client = getClient();
34
- switch (subcommand) {
35
- case "set": {
36
- const key = positional[1];
37
- if (!key) {
38
- console.error("Usage: volute env set <KEY> [<VALUE>] [--mind <name>]");
39
- process.exit(1);
40
- }
41
- const value = positional[2] ?? await promptLine(`Enter value for ${key}: `);
42
- let res;
43
- if (flags.mind) {
44
- res = await daemonFetch(
45
- urlOf(
46
- client.api.minds[":name"].env[":key"].$url({
47
- param: { name: flags.mind, key }
48
- })
49
- ),
50
- {
51
- method: "PUT",
52
- headers: { "Content-Type": "application/json" },
53
- body: JSON.stringify({ value })
54
- }
55
- );
56
- } else {
57
- res = await daemonFetch(urlOf(client.api.env[":key"].$url({ param: { key } })), {
58
- method: "PUT",
59
- headers: { "Content-Type": "application/json" },
60
- body: JSON.stringify({ value })
61
- });
62
- }
63
- if (!res.ok) {
64
- const body = await res.json().catch(() => ({}));
65
- console.error(body.error ?? `Failed to set ${key}`);
66
- process.exit(1);
67
- }
68
- const scope = flags.mind ? `mind:${flags.mind}` : "shared";
69
- console.log(`Set ${key} [${scope}]`);
70
- break;
71
- }
72
- case "get": {
73
- const key = positional[1];
74
- if (!key) {
75
- console.error("Usage: volute env get <KEY> [--mind <name>]");
76
- process.exit(1);
77
- }
78
- if (flags.mind) {
79
- const res = await daemonFetch(
80
- urlOf(
81
- client.api.minds[":name"].env[":key"].$url({
82
- param: { name: flags.mind, key }
83
- })
84
- )
85
- );
86
- if (!res.ok) {
87
- const body = await res.json().catch(() => ({}));
88
- console.error(body.error ?? `${key} not set`);
89
- process.exit(1);
90
- }
91
- const data = await res.json();
92
- console.log(data.value);
93
- } else {
94
- const res = await daemonFetch(urlOf(client.api.env.$url()));
95
- if (!res.ok) {
96
- console.error(`Failed to read shared env`);
97
- process.exit(1);
98
- }
99
- const env = await res.json();
100
- if (key in env) {
101
- console.log(env[key]);
102
- } else {
103
- console.error(`${key} not set`);
104
- process.exit(1);
105
- }
106
- }
107
- break;
108
- }
109
- case "list": {
110
- const compact = isCompact();
111
- if (flags.mind) {
112
- const res = await daemonFetch(
113
- urlOf(client.api.minds[":name"].env.$url({ param: { name: flags.mind } }))
114
- );
115
- if (!res.ok) {
116
- const body = await res.json().catch(() => ({}));
117
- console.error(body.error ?? "Failed to list env");
118
- process.exit(1);
119
- }
120
- const data = await res.json();
121
- const allKeys = /* @__PURE__ */ new Set([...Object.keys(data.shared), ...Object.keys(data.mind)]);
122
- if (allKeys.size === 0) {
123
- console.log("No environment variables set.");
124
- return;
125
- }
126
- for (const key of [...allKeys].sort()) {
127
- const scope = key in data.mind ? "mind" : "shared";
128
- const raw = key in data.mind ? data.mind[key] : data.shared[key];
129
- const value = flags.reveal ? raw : maskValue(raw);
130
- console.log(compact ? `${key}=${value}` : `${key}=${value} [${scope}]`);
131
- }
132
- } else {
133
- const res = await daemonFetch(urlOf(client.api.env.$url()));
134
- if (!res.ok) {
135
- console.error("Failed to list shared env");
136
- process.exit(1);
137
- }
138
- const env = await res.json();
139
- const keys = Object.keys(env);
140
- if (keys.length === 0) {
141
- console.log("No shared environment variables set.");
142
- return;
143
- }
144
- for (const key of keys.sort()) {
145
- const value = flags.reveal ? env[key] : maskValue(env[key]);
146
- console.log(compact ? `${key}=${value}` : `${key}=${value} [shared]`);
147
- }
148
- }
149
- break;
150
- }
151
- case "remove": {
152
- const key = positional[1];
153
- if (!key) {
154
- console.error("Usage: volute env remove <KEY> [--mind <name>]");
155
- process.exit(1);
156
- }
157
- let res;
158
- if (flags.mind) {
159
- res = await daemonFetch(
160
- urlOf(
161
- client.api.minds[":name"].env[":key"].$url({
162
- param: { name: flags.mind, key }
163
- })
164
- ),
165
- { method: "DELETE" }
166
- );
167
- } else {
168
- res = await daemonFetch(urlOf(client.api.env[":key"].$url({ param: { key } })), {
169
- method: "DELETE"
170
- });
171
- }
172
- if (!res.ok) {
173
- const scope2 = flags.mind ? `mind:${flags.mind}` : "shared";
174
- console.error(`${key} not set in ${scope2} scope`);
175
- process.exit(1);
176
- }
177
- const scope = flags.mind ? `mind:${flags.mind}` : "shared";
178
- console.log(`Removed ${key} [${scope}]`);
179
- break;
180
- }
181
- case "--help":
182
- case "-h":
183
- case void 0:
184
- console.log(`Usage: volute env <set|get|list|remove> [--mind <name>]`);
185
- break;
186
- default:
187
- console.error(`Usage: volute env <set|get|list|remove> [--mind <name>]`);
188
- console.error(`
189
- Unknown subcommand: ${subcommand}`);
190
- process.exit(1);
191
- }
192
- }
193
- export {
194
- run
195
- };
@@ -1,112 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- addHistoryToArchive,
4
- createExportArchive
5
- } from "./chunk-6WAWMWR5.js";
6
- import {
7
- parseArgs
8
- } from "./chunk-D424ZQGI.js";
9
- import {
10
- findMind,
11
- mindDir
12
- } from "./chunk-N7BLAHNE.js";
13
- import "./chunk-4JSR7YO7.js";
14
- import "./chunk-7KJOFUNN.js";
15
-
16
- // src/commands/export.ts
17
- import { existsSync, writeFileSync } from "fs";
18
- import { resolve } from "path";
19
- async function run(args) {
20
- const { positional, flags } = parseArgs(args, {
21
- "include-env": { type: "boolean" },
22
- "include-identity": { type: "boolean" },
23
- "include-connectors": { type: "boolean" },
24
- "include-history": { type: "boolean" },
25
- "include-sessions": { type: "boolean" },
26
- "include-src": { type: "boolean" },
27
- all: { type: "boolean" },
28
- output: { type: "string" }
29
- });
30
- const name = positional[0];
31
- if (!name) {
32
- console.error(
33
- "Usage: volute mind export <name> [--include-env] [--include-identity] [--include-connectors] [--include-history] [--include-sessions] [--include-src] [--all] [--output <path>]"
34
- );
35
- process.exit(1);
36
- }
37
- const entry = await findMind(name);
38
- if (!entry) {
39
- console.error(`Unknown mind: ${name}`);
40
- process.exit(1);
41
- }
42
- const dir = mindDir(name);
43
- if (!existsSync(dir)) {
44
- console.error(`Mind directory missing: ${dir}`);
45
- process.exit(1);
46
- }
47
- const includeAll = flags.all;
48
- const includeEnv = includeAll || flags["include-env"];
49
- const includeIdentity = includeAll || flags["include-identity"];
50
- const includeConnectors = includeAll || flags["include-connectors"];
51
- const includeHistory = includeAll || flags["include-history"];
52
- const includeSessions = includeAll || flags["include-sessions"];
53
- const includeSrc = includeAll || flags["include-src"];
54
- const zip = createExportArchive({
55
- name,
56
- template: entry.template ?? "claude",
57
- stage: entry.stage,
58
- includeSrc,
59
- includeEnv,
60
- includeIdentity,
61
- includeConnectors,
62
- includeHistory,
63
- includeSessions
64
- });
65
- if (includeHistory) {
66
- try {
67
- const { daemonFetch } = await import("./daemon-client-WOAQXXBM.js");
68
- const { getClient, urlOf } = await import("./api-client-XUXOB7LI.js");
69
- const client = getClient();
70
- const res = await daemonFetch(
71
- urlOf(client.api.minds[":name"].history.export.$url({ param: { name } }))
72
- );
73
- if (!res.ok) {
74
- const text = await res.text().catch(() => "");
75
- throw new Error(`Failed to fetch history: HTTP ${res.status}${text ? ` - ${text}` : ""}`);
76
- }
77
- const rows = await res.json();
78
- addHistoryToArchive(zip, rows);
79
- } catch (err) {
80
- console.error(`Error: could not export history: ${err.message}`);
81
- process.exit(1);
82
- }
83
- }
84
- const outputPath = resolve(flags.output ?? `${name}.volute`);
85
- const buf = zip.toBuffer();
86
- try {
87
- writeFileSync(outputPath, buf);
88
- } catch (err) {
89
- console.error(`Failed to write archive to ${outputPath}: ${err.message}`);
90
- process.exit(1);
91
- }
92
- const sizeMB = (buf.length / 1024 / 1024).toFixed(2);
93
- console.log(`
94
- Exported ${name} \u2192 ${outputPath} (${sizeMB} MB)`);
95
- const included = [];
96
- const excluded = [];
97
- for (const [key, val] of [
98
- ["src", includeSrc],
99
- ["env", includeEnv],
100
- ["identity", includeIdentity],
101
- ["connectors", includeConnectors],
102
- ["history", includeHistory],
103
- ["sessions", includeSessions]
104
- ]) {
105
- (val ? included : excluded).push(key);
106
- }
107
- if (included.length > 0) console.log(` Included: ${included.join(", ")}`);
108
- if (excluded.length > 0) console.log(` Excluded: ${excluded.join(", ")}`);
109
- }
110
- export {
111
- run
112
- };
@@ -1,47 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- resolveMindName
4
- } from "./chunk-NAOW2CLO.js";
5
- import {
6
- formatFileSize
7
- } from "./chunk-MLOQKQNB.js";
8
- import {
9
- parseArgs
10
- } from "./chunk-D424ZQGI.js";
11
- import {
12
- daemonFetch
13
- } from "./chunk-PLDWHR4D.js";
14
- import "./chunk-N7BLAHNE.js";
15
- import "./chunk-4JSR7YO7.js";
16
- import "./chunk-7KJOFUNN.js";
17
-
18
- // src/commands/chat/files.ts
19
- async function run(args) {
20
- const { flags } = parseArgs(args, {
21
- mind: { type: "string" }
22
- });
23
- const mind = resolveMindName(flags);
24
- const res = await daemonFetch(`/api/minds/${encodeURIComponent(mind)}/files/pending`);
25
- if (!res.ok) {
26
- const data = await res.json();
27
- console.error(data.error ?? `Failed to list pending files: ${res.status}`);
28
- process.exit(1);
29
- }
30
- const pending = await res.json();
31
- if (pending.length === 0) {
32
- console.log("No pending files.");
33
- return;
34
- }
35
- const idW = Math.max(2, ...pending.map((p) => p.id.length));
36
- const senderW = Math.max(6, ...pending.map((p) => p.sender.length));
37
- const fileW = Math.max(4, ...pending.map((p) => p.filename.length));
38
- console.log(`${"ID".padEnd(idW)} ${"SENDER".padEnd(senderW)} ${"FILE".padEnd(fileW)} SIZE`);
39
- for (const p of pending) {
40
- console.log(
41
- `${p.id.padEnd(idW)} ${p.sender.padEnd(senderW)} ${p.filename.padEnd(fileW)} ${formatFileSize(p.size)}`
42
- );
43
- }
44
- }
45
- export {
46
- run
47
- };
@@ -1,23 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- findOpenClawSession,
4
- importOpenClawConnectors,
5
- importPiSession,
6
- parseNameFromIdentity,
7
- run,
8
- sessionMatchesWorkspace
9
- } from "./chunk-47ZPNLF4.js";
10
- import "./chunk-M3K5AARV.js";
11
- import "./chunk-YUIHSKR6.js";
12
- import "./chunk-D424ZQGI.js";
13
- import "./chunk-N7BLAHNE.js";
14
- import "./chunk-4JSR7YO7.js";
15
- import "./chunk-7KJOFUNN.js";
16
- export {
17
- findOpenClawSession,
18
- importOpenClawConnectors,
19
- importPiSession,
20
- parseNameFromIdentity,
21
- run,
22
- sessionMatchesWorkspace
23
- };
@@ -1,66 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- parseArgs
4
- } from "./chunk-D424ZQGI.js";
5
- import "./chunk-7KJOFUNN.js";
6
-
7
- // src/commands/join.ts
8
- async function run(args) {
9
- const { positional, flags } = parseArgs(args, {
10
- summary: { type: "string" },
11
- justification: { type: "string" },
12
- memory: { type: "string" },
13
- "skip-verify": { type: "boolean" }
14
- });
15
- const variantName = positional[0];
16
- if (!variantName) {
17
- console.error(
18
- "Usage: volute mind join <variant-name> [--summary '...'] [--justification '...'] [--memory '...'] [--skip-verify]"
19
- );
20
- process.exit(1);
21
- }
22
- console.log(`Joining variant ${variantName}...`);
23
- const { daemonFetch } = await import("./daemon-client-WOAQXXBM.js");
24
- const { getClient, urlOf } = await import("./api-client-XUXOB7LI.js");
25
- const client = getClient();
26
- const statusRes = await daemonFetch(
27
- urlOf(client.api.minds[":name"].$url({ param: { name: variantName } }))
28
- );
29
- if (!statusRes.ok) {
30
- const data2 = await statusRes.json().catch(() => ({}));
31
- console.error(data2.error ?? `Variant '${variantName}' not found (HTTP ${statusRes.status})`);
32
- process.exit(1);
33
- }
34
- const statusData = await statusRes.json();
35
- const parentName = statusData.parent;
36
- if (!parentName) {
37
- console.error(`'${variantName}' is not a variant \u2014 it has no parent mind`);
38
- process.exit(1);
39
- }
40
- const res = await daemonFetch(
41
- urlOf(
42
- client.api.minds[":name"].variants[":variant"].merge.$url({
43
- param: { name: parentName, variant: variantName }
44
- })
45
- ),
46
- {
47
- method: "POST",
48
- headers: { "Content-Type": "application/json" },
49
- body: JSON.stringify({
50
- ...flags.summary && { summary: flags.summary },
51
- ...flags.justification && { justification: flags.justification },
52
- ...flags.memory && { memory: flags.memory },
53
- ...flags["skip-verify"] && { skipVerify: true }
54
- })
55
- }
56
- );
57
- const data = await res.json();
58
- if (!res.ok) {
59
- console.error(data.error ?? "Failed to join variant");
60
- process.exit(1);
61
- }
62
- console.log(`Variant ${variantName} joined and cleaned up.`);
63
- }
64
- export {
65
- run
66
- };
@@ -1,49 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- isCompact
4
- } from "./chunk-FYCALD4Q.js";
5
- import {
6
- resolveMindName
7
- } from "./chunk-NAOW2CLO.js";
8
- import {
9
- parseArgs
10
- } from "./chunk-D424ZQGI.js";
11
- import {
12
- daemonFetch
13
- } from "./chunk-PLDWHR4D.js";
14
- import "./chunk-N7BLAHNE.js";
15
- import "./chunk-4JSR7YO7.js";
16
- import "./chunk-7KJOFUNN.js";
17
-
18
- // src/commands/chat/list.ts
19
- async function run(args) {
20
- const { flags } = parseArgs(args, {
21
- mind: { type: "string" }
22
- });
23
- const mindName = resolveMindName(flags);
24
- const res = await daemonFetch(`/api/minds/${encodeURIComponent(mindName)}/conversations`);
25
- if (!res.ok) {
26
- console.error(`Failed to list conversations: ${res.status}`);
27
- process.exit(1);
28
- }
29
- const convs = await res.json();
30
- if (convs.length === 0) {
31
- console.log("No conversations.");
32
- return;
33
- }
34
- const compact = isCompact();
35
- for (const conv of convs) {
36
- const label = conv.type === "channel" ? `#${conv.name}` : conv.title ?? conv.id.slice(0, 8);
37
- if (compact) {
38
- console.log(`${label} (${conv.type})`);
39
- } else {
40
- const time = new Date(
41
- conv.updated_at.endsWith("Z") ? conv.updated_at : `${conv.updated_at}Z`
42
- ).toLocaleString();
43
- console.log(` ${label} (${conv.type}) ${time}`);
44
- }
45
- }
46
- }
47
- export {
48
- run
49
- };
@@ -1,47 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- promptLine
4
- } from "./chunk-SSI47XP2.js";
5
- import {
6
- parseArgs
7
- } from "./chunk-D424ZQGI.js";
8
- import {
9
- daemonFetch
10
- } from "./chunk-PLDWHR4D.js";
11
- import "./chunk-N7BLAHNE.js";
12
- import "./chunk-4JSR7YO7.js";
13
- import "./chunk-7KJOFUNN.js";
14
-
15
- // src/commands/systems/login.ts
16
- async function run(args) {
17
- const { flags } = parseArgs(args, {
18
- key: { type: "string" }
19
- });
20
- let key = flags.key;
21
- if (!key) {
22
- if (!process.stdin.isTTY) {
23
- console.error("Usage: volute systems login --key <api-key>");
24
- process.exit(1);
25
- }
26
- key = await promptLine("API key: ");
27
- if (!key) {
28
- console.error("No key provided.");
29
- process.exit(1);
30
- }
31
- }
32
- const res = await daemonFetch("/api/system/login", {
33
- method: "POST",
34
- headers: { "Content-Type": "application/json" },
35
- body: JSON.stringify({ key })
36
- });
37
- if (!res.ok) {
38
- const body = await res.json().catch(() => ({ error: `HTTP ${res.status}` }));
39
- console.error(`Login failed: ${body.error}`);
40
- process.exit(1);
41
- }
42
- const { system } = await res.json();
43
- console.log(`Logged in as "${system}". Credentials saved.`);
44
- }
45
- export {
46
- run
47
- };
@@ -1,47 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- promptLine,
4
- promptPassword
5
- } from "./chunk-SSI47XP2.js";
6
- import {
7
- daemonFetch
8
- } from "./chunk-PLDWHR4D.js";
9
- import {
10
- voluteUserHome
11
- } from "./chunk-N7BLAHNE.js";
12
- import "./chunk-4JSR7YO7.js";
13
- import "./chunk-7KJOFUNN.js";
14
-
15
- // src/commands/login.ts
16
- import { writeFileSync } from "fs";
17
- import { resolve } from "path";
18
- async function run(_args) {
19
- const username = await promptLine("Username: ");
20
- const password = await promptPassword("Password: ");
21
- const res = await daemonFetch("/api/auth/login", {
22
- method: "POST",
23
- headers: { "Content-Type": "application/json" },
24
- body: JSON.stringify({ username, password })
25
- });
26
- if (!res.ok) {
27
- const data = await res.json().catch(() => ({}));
28
- console.error(data.error || "Login failed");
29
- process.exit(1);
30
- }
31
- const {
32
- username: name,
33
- role,
34
- sessionId
35
- } = await res.json();
36
- const sessionPath = resolve(voluteUserHome(), "cli-session.json");
37
- try {
38
- writeFileSync(sessionPath, JSON.stringify({ sessionId, username: name }), { mode: 384 });
39
- } catch (err) {
40
- console.error(`Login succeeded but failed to save session: ${err.message}`);
41
- process.exit(1);
42
- }
43
- console.log(`Logged in as ${name} (role: ${role})`);
44
- }
45
- export {
46
- run
47
- };
@@ -1,40 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- daemonFetch
4
- } from "./chunk-PLDWHR4D.js";
5
- import {
6
- voluteUserHome
7
- } from "./chunk-N7BLAHNE.js";
8
- import "./chunk-4JSR7YO7.js";
9
- import "./chunk-7KJOFUNN.js";
10
-
11
- // src/commands/logout.ts
12
- import { existsSync, readFileSync, unlinkSync } from "fs";
13
- import { resolve } from "path";
14
- async function run(_args) {
15
- const sessionPath = resolve(voluteUserHome(), "cli-session.json");
16
- if (!existsSync(sessionPath)) {
17
- console.log("Not logged in");
18
- return;
19
- }
20
- let sessionId;
21
- try {
22
- const data = JSON.parse(readFileSync(sessionPath, "utf-8"));
23
- sessionId = data.sessionId;
24
- } catch {
25
- }
26
- if (sessionId) {
27
- try {
28
- await daemonFetch("/api/auth/logout", {
29
- method: "POST",
30
- headers: { Authorization: `Bearer ${sessionId}` }
31
- });
32
- } catch {
33
- }
34
- }
35
- unlinkSync(sessionPath);
36
- console.log("Logged out");
37
- }
38
- export {
39
- run
40
- };
@@ -1,21 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- daemonFetch
4
- } from "./chunk-PLDWHR4D.js";
5
- import "./chunk-N7BLAHNE.js";
6
- import "./chunk-4JSR7YO7.js";
7
- import "./chunk-7KJOFUNN.js";
8
-
9
- // src/commands/systems/logout.ts
10
- async function run() {
11
- const res = await daemonFetch("/api/system/logout", { method: "POST" });
12
- if (!res.ok) {
13
- const body = await res.json().catch(() => ({ error: `HTTP ${res.status}` }));
14
- console.error(`Logout failed: ${body.error}`);
15
- process.exit(1);
16
- }
17
- console.log("Logged out. Credentials removed.");
18
- }
19
- export {
20
- run
21
- };
@@ -1,42 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- deliverMessage,
4
- linkToolResultToTurn,
5
- recordInbound,
6
- recordOutbound,
7
- resolveSleepAction,
8
- tagRecentInbound,
9
- tagUntaggedInbound,
10
- tagUntaggedOutbound
11
- } from "./chunk-TAHX36HZ.js";
12
- import "./chunk-CVL5IGIR.js";
13
- import "./chunk-B2BVAIZ4.js";
14
- import "./chunk-G53F3JA4.js";
15
- import "./chunk-N3DNFPVA.js";
16
- import "./chunk-OYAKCAVY.js";
17
- import "./chunk-V45JXOWY.js";
18
- import "./chunk-IS7WJ56Q.js";
19
- import "./chunk-BTWAGDV5.js";
20
- import "./chunk-M3K5AARV.js";
21
- import "./chunk-PB65JZK2.js";
22
- import "./chunk-BM474GX6.js";
23
- import "./chunk-E5C7OWZ2.js";
24
- import "./chunk-XWXBJQBE.js";
25
- import "./chunk-BFWHBQK4.js";
26
- import "./chunk-YUIHSKR6.js";
27
- import "./chunk-U5BTYSAL.js";
28
- import "./chunk-BDK73LK6.js";
29
- import "./chunk-6OWJXUAR.js";
30
- import "./chunk-N7BLAHNE.js";
31
- import "./chunk-4JSR7YO7.js";
32
- import "./chunk-7KJOFUNN.js";
33
- export {
34
- deliverMessage,
35
- linkToolResultToTurn,
36
- recordInbound,
37
- recordOutbound,
38
- resolveSleepAction,
39
- tagRecentInbound,
40
- tagUntaggedInbound,
41
- tagUntaggedOutbound
42
- };