@ai-matrx/desktop-protocol 0.17.10 → 0.17.12
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 +14 -0
- package/dist/client.cjs +394 -298
- package/dist/client.cjs.map +1 -1
- package/dist/client.d.cts +2 -2
- package/dist/client.d.ts +2 -2
- package/dist/client.js +394 -298
- package/dist/client.js.map +1 -1
- package/dist/index.cjs +210 -84
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +232 -14
- package/dist/index.d.ts +232 -14
- package/dist/index.js +210 -84
- package/dist/index.js.map +1 -1
- package/dist/{models-BcBSKFeq.d.cts → models-A0PWllJz.d.cts} +395 -16
- package/dist/{models-BcBSKFeq.d.ts → models-A0PWllJz.d.ts} +395 -16
- package/dist/react.d.cts +192 -7
- package/dist/react.d.ts +192 -7
- package/generated/desktop-protocol.schema.json +525 -4
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -342,6 +342,21 @@ __export(src_exports, {
|
|
|
342
342
|
SpendScopes: () => SpendScopes,
|
|
343
343
|
SpendSplit: () => SpendSplit,
|
|
344
344
|
SpendStart: () => SpendStart,
|
|
345
|
+
StackErrorsParams: () => StackErrorsParams,
|
|
346
|
+
StackErrorsResult: () => StackErrorsResult,
|
|
347
|
+
StackEvent: () => StackEvent,
|
|
348
|
+
StackLogsParams: () => StackLogsParams,
|
|
349
|
+
StackLogsResult: () => StackLogsResult,
|
|
350
|
+
StackRunResult: () => StackRunResult,
|
|
351
|
+
StackServer: () => StackServer,
|
|
352
|
+
StackServerActionParams: () => StackServerActionParams,
|
|
353
|
+
StackServerActionResult: () => StackServerActionResult,
|
|
354
|
+
StackServerName: () => StackServerName,
|
|
355
|
+
StackStartParams: () => StackStartParams,
|
|
356
|
+
StackStateParams: () => StackStateParams,
|
|
357
|
+
StackStateResult: () => StackStateResult,
|
|
358
|
+
StackStopParams: () => StackStopParams,
|
|
359
|
+
StackTone: () => StackTone,
|
|
345
360
|
StreamMeta: () => StreamMeta,
|
|
346
361
|
StreamMsg: () => StreamMsg,
|
|
347
362
|
SysinfoGetParams: () => SysinfoGetParams,
|
|
@@ -407,7 +422,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
407
422
|
// src/schema/primitives.ts
|
|
408
423
|
var import_zod = require("zod");
|
|
409
424
|
var PROTOCOL_MAJOR = 1;
|
|
410
|
-
var PROTOCOL_MINOR =
|
|
425
|
+
var PROTOCOL_MINOR = 16;
|
|
411
426
|
var PROTOCOL_VERSION = `${PROTOCOL_MAJOR}.${PROTOCOL_MINOR}`;
|
|
412
427
|
var ProtocolVersion = import_zod.z.string().regex(/^[1-9][0-9]{0,2}\.[0-9]{1,3}$/);
|
|
413
428
|
var RequestId = import_zod.z.string().min(1).max(64).regex(/^[A-Za-z0-9_-]+$/);
|
|
@@ -1346,6 +1361,7 @@ var ChatAppProject = import_zod12.z.strictObject({
|
|
|
1346
1361
|
id: import_zod12.z.string().min(1).max(200),
|
|
1347
1362
|
name: import_zod12.z.string().max(200)
|
|
1348
1363
|
});
|
|
1364
|
+
var ChatTitleSource = import_zod12.z.enum(["app", "app-remembered", "custom-title", "ai-title", "agent-name", "summary", "first-prompt", "last-prompt"]);
|
|
1349
1365
|
var ChatRow = import_zod12.z.strictObject({
|
|
1350
1366
|
id: ChatId,
|
|
1351
1367
|
/** The short id people see (the listing's first 8 characters). */
|
|
@@ -1382,10 +1398,12 @@ var ChatRow = import_zod12.z.strictObject({
|
|
|
1382
1398
|
* `title` is what to show (`title_override` when set, else this).
|
|
1383
1399
|
*/
|
|
1384
1400
|
original_title: import_zod12.z.string().max(1e3).optional(),
|
|
1385
|
-
/** 1.14: where `original_title` came from (
|
|
1386
|
-
title_source:
|
|
1401
|
+
/** 1.14: where `original_title` came from (the one rule's sources, strongest first; 1.15: a closed set). */
|
|
1402
|
+
title_source: ChatTitleSource.optional(),
|
|
1387
1403
|
/** 1.14: the person's rename inside Matrx (Coding Sessions), applied once by the row builder; absent = none. */
|
|
1388
|
-
title_override: import_zod12.z.string().min(1).max(300).optional()
|
|
1404
|
+
title_override: import_zod12.z.string().min(1).max(300).optional(),
|
|
1405
|
+
/** 1.15: the app itself archived it (hidden_in says where and why, in words for people; this is the typed fact). */
|
|
1406
|
+
archived: import_zod12.z.boolean().optional()
|
|
1389
1407
|
});
|
|
1390
1408
|
var ChatFamily = import_zod12.z.strictObject({
|
|
1391
1409
|
id: ChatId,
|
|
@@ -2064,121 +2082,207 @@ var ResourcesSnapshotResult = import_zod23.z.strictObject({
|
|
|
2064
2082
|
uptime_seconds: nonNegInt
|
|
2065
2083
|
});
|
|
2066
2084
|
|
|
2067
|
-
// src/schema/
|
|
2085
|
+
// src/schema/stack.ts
|
|
2068
2086
|
var import_zod24 = require("zod");
|
|
2069
|
-
var
|
|
2087
|
+
var StackServerName = import_zod24.z.string().regex(/^[a-z0-9_-]{1,64}$/);
|
|
2088
|
+
var StackTone = import_zod24.z.enum(["good", "wait", "bad", "off"]);
|
|
2089
|
+
var StackServer = import_zod24.z.strictObject({
|
|
2090
|
+
name: StackServerName,
|
|
2091
|
+
/** One word: Healthy, Starting, Unhealthy, Restarting, Stopping, Waiting, Stopped, Crashed, Off. */
|
|
2092
|
+
label: import_zod24.z.string().max(32),
|
|
2093
|
+
tone: StackTone,
|
|
2094
|
+
/** What is going on, in one or two plain sentences. */
|
|
2095
|
+
sentence: import_zod24.z.string().max(2e3),
|
|
2096
|
+
/** The config's own description of the server. */
|
|
2097
|
+
description: import_zod24.z.string().max(512),
|
|
2098
|
+
/** Where the server answers, when its description names an address. */
|
|
2099
|
+
open_url: import_zod24.z.string().max(2048).nullable(),
|
|
2100
|
+
log_file: import_zod24.z.string().max(4096),
|
|
2101
|
+
/** When its log file was last written. */
|
|
2102
|
+
last_output_at_ms: epochMs.nullable(),
|
|
2103
|
+
started_at_ms: epochMs.nullable(),
|
|
2104
|
+
restarts: nonNegInt,
|
|
2105
|
+
exit_code: import_zod24.z.int().nullable(),
|
|
2106
|
+
pid: import_zod24.z.int().nullable()
|
|
2107
|
+
});
|
|
2108
|
+
var StackEvent = import_zod24.z.strictObject({
|
|
2109
|
+
at_ms: epochMs,
|
|
2110
|
+
/** A server name, or "stack" for the stack as a whole. */
|
|
2111
|
+
server: import_zod24.z.string().max(64),
|
|
2112
|
+
/** started · stopped · healthy · unhealthy · crashed · exited · restarting · stopping · action · action-done · action-failed · setup · error */
|
|
2113
|
+
kind: import_zod24.z.string().max(32),
|
|
2114
|
+
text: import_zod24.z.string().max(4e3)
|
|
2115
|
+
});
|
|
2116
|
+
var StackStateParams = import_zod24.z.strictObject({});
|
|
2117
|
+
var StackStateResult = import_zod24.z.strictObject({
|
|
2118
|
+
/** The stack's config file, when found. */
|
|
2119
|
+
config_path: import_zod24.z.string().max(4096).nullable(),
|
|
2120
|
+
/** Why the stack cannot be run from here (no config, no process-compose), else null. */
|
|
2121
|
+
problem: import_zod24.z.string().max(1e3).nullable(),
|
|
2122
|
+
stack_up: import_zod24.z.boolean(),
|
|
2123
|
+
stack_started_at_ms: epochMs.nullable(),
|
|
2124
|
+
servers: import_zod24.z.array(StackServer).max(64),
|
|
2125
|
+
/** One line about the one-shot setup steps ("Docker Desktop: running."), or null. */
|
|
2126
|
+
setup_note: import_zod24.z.string().max(500).nullable(),
|
|
2127
|
+
/** Start everything / Stop everything in flight. */
|
|
2128
|
+
pending: import_zod24.z.strictObject({ verb: import_zod24.z.enum(["start", "stop"]), label: import_zod24.z.string().max(64), since_ms: epochMs }).nullable(),
|
|
2129
|
+
/** The newest entries last. */
|
|
2130
|
+
events: import_zod24.z.array(StackEvent).max(300)
|
|
2131
|
+
});
|
|
2132
|
+
var StackStartParams = import_zod24.z.strictObject({});
|
|
2133
|
+
var StackStopParams = import_zod24.z.strictObject({});
|
|
2134
|
+
var StackRunResult = import_zod24.z.strictObject({ accepted: import_zod24.z.boolean() });
|
|
2135
|
+
var StackServerActionParams = import_zod24.z.strictObject({
|
|
2136
|
+
name: StackServerName,
|
|
2137
|
+
verb: import_zod24.z.enum(["start", "stop", "restart"])
|
|
2138
|
+
});
|
|
2139
|
+
var StackServerActionResult = import_zod24.z.strictObject({ message: import_zod24.z.string().max(1e3) });
|
|
2140
|
+
var StackLogsParams = import_zod24.z.strictObject({
|
|
2141
|
+
name: StackServerName,
|
|
2142
|
+
/** Without `offset`: the last this-many complete lines. With it: new lines after it, at most this many. */
|
|
2143
|
+
lines: import_zod24.z.int().min(1).max(2e5).default(2e3),
|
|
2144
|
+
/** Byte offset the last read ended at: answer only what was written after it (follow). */
|
|
2145
|
+
offset: nonNegInt.optional(),
|
|
2146
|
+
/** A "Clear" point: the lines written after this byte offset (no `offset`). */
|
|
2147
|
+
since: nonNegInt.optional(),
|
|
2148
|
+
/** With `offset`: wait up to this long for a new line when none is waiting (0 answers at once). */
|
|
2149
|
+
wait_ms: import_zod24.z.int().min(0).max(25e3).default(0)
|
|
2150
|
+
});
|
|
2151
|
+
var StackLogsResult = import_zod24.z.strictObject({
|
|
2152
|
+
/** Complete lines, colour codes removed. */
|
|
2153
|
+
lines: import_zod24.z.array(import_zod24.z.string().max(65536)).max(2e5),
|
|
2154
|
+
/** Where these lines end: pass it back as `offset` to follow. */
|
|
2155
|
+
offset: nonNegInt,
|
|
2156
|
+
/** False when `since` no longer exists (the log rotated): the lines are the plain tail instead. */
|
|
2157
|
+
since_valid: import_zod24.z.boolean(),
|
|
2158
|
+
/** The log was rotated or truncated since `offset`: these lines start the file again. */
|
|
2159
|
+
reset: import_zod24.z.boolean(),
|
|
2160
|
+
log_file: import_zod24.z.string().max(4096)
|
|
2161
|
+
});
|
|
2162
|
+
var StackErrorsParams = import_zod24.z.strictObject({
|
|
2163
|
+
window_minutes: import_zod24.z.int().min(1).max(1440).default(60)
|
|
2164
|
+
});
|
|
2165
|
+
var StackErrorsResult = import_zod24.z.strictObject({
|
|
2166
|
+
/** Per server: a heading line ("=== aidream — errors in the last 60 minutes (<file>) ===") and each error with the 10 lines after it. */
|
|
2167
|
+
sections: import_zod24.z.array(import_zod24.z.strictObject({ name: StackServerName, heading: import_zod24.z.string().max(4096), lines: import_zod24.z.array(import_zod24.z.string().max(65536)).max(5e3) })).max(64),
|
|
2168
|
+
window_minutes: import_zod24.z.int().min(1).max(1440)
|
|
2169
|
+
});
|
|
2170
|
+
|
|
2171
|
+
// src/schema/audio.ts
|
|
2172
|
+
var import_zod25 = require("zod");
|
|
2173
|
+
var AudioDevice = import_zod25.z.strictObject({
|
|
2070
2174
|
/** The OS's name for it, as audio.record takes it. */
|
|
2071
|
-
id:
|
|
2072
|
-
name:
|
|
2073
|
-
default:
|
|
2175
|
+
id: import_zod25.z.string().min(1).max(256),
|
|
2176
|
+
name: import_zod25.z.string().max(256),
|
|
2177
|
+
default: import_zod25.z.boolean()
|
|
2074
2178
|
});
|
|
2075
|
-
var AudioDevicesParams =
|
|
2076
|
-
var AudioDevicesResult =
|
|
2077
|
-
inputs:
|
|
2078
|
-
outputs:
|
|
2179
|
+
var AudioDevicesParams = import_zod25.z.strictObject({});
|
|
2180
|
+
var AudioDevicesResult = import_zod25.z.strictObject({
|
|
2181
|
+
inputs: import_zod25.z.array(AudioDevice).max(64),
|
|
2182
|
+
outputs: import_zod25.z.array(AudioDevice).max(64)
|
|
2079
2183
|
});
|
|
2080
|
-
var AudioRecordParams =
|
|
2081
|
-
seconds:
|
|
2184
|
+
var AudioRecordParams = import_zod25.z.strictObject({
|
|
2185
|
+
seconds: import_zod25.z.number().min(0.5).max(600),
|
|
2082
2186
|
/** The microphone (from audio.devices); the default input when absent. */
|
|
2083
|
-
device_id:
|
|
2187
|
+
device_id: import_zod25.z.string().min(1).max(256).optional(),
|
|
2084
2188
|
/** Where the WAV file goes; a new file in the temp folder when absent. */
|
|
2085
2189
|
path: AbsPath.optional()
|
|
2086
2190
|
});
|
|
2087
|
-
var AudioRecordResult =
|
|
2191
|
+
var AudioRecordResult = import_zod25.z.strictObject({
|
|
2088
2192
|
path: AbsPath,
|
|
2089
|
-
seconds:
|
|
2193
|
+
seconds: import_zod25.z.number().min(0),
|
|
2090
2194
|
bytes: nonNegInt,
|
|
2091
2195
|
/** Loudest sample, 0–1: 0 means the device gave silence. */
|
|
2092
|
-
peak:
|
|
2196
|
+
peak: import_zod25.z.number().min(0).max(1)
|
|
2093
2197
|
});
|
|
2094
|
-
var AudioPlayParams =
|
|
2095
|
-
var AudioPlayResult =
|
|
2198
|
+
var AudioPlayParams = import_zod25.z.strictObject({ path: AbsPath });
|
|
2199
|
+
var AudioPlayResult = import_zod25.z.strictObject({ path: AbsPath, seconds: import_zod25.z.number().min(0) });
|
|
2096
2200
|
|
|
2097
2201
|
// src/schema/fs-watch.ts
|
|
2098
|
-
var
|
|
2099
|
-
var FsWatchId =
|
|
2100
|
-
var FsWatchStartParams =
|
|
2202
|
+
var import_zod26 = require("zod");
|
|
2203
|
+
var FsWatchId = import_zod26.z.string().regex(/^fw_[A-Za-z0-9]{12,40}$/);
|
|
2204
|
+
var FsWatchStartParams = import_zod26.z.strictObject({
|
|
2101
2205
|
path: AbsPath,
|
|
2102
|
-
recursive:
|
|
2206
|
+
recursive: import_zod26.z.boolean().default(true),
|
|
2103
2207
|
/** Globs relative to `path` whose changes are not reported (".git/**", "node_modules/**"). */
|
|
2104
|
-
ignore:
|
|
2208
|
+
ignore: import_zod26.z.array(import_zod26.z.string().max(256)).max(64).default([])
|
|
2105
2209
|
});
|
|
2106
|
-
var FsWatchStartResult =
|
|
2210
|
+
var FsWatchStartResult = import_zod26.z.strictObject({
|
|
2107
2211
|
watch_id: FsWatchId,
|
|
2108
2212
|
path: AbsPath,
|
|
2109
2213
|
/** The watch ends by itself if nobody reads it for 30 minutes. */
|
|
2110
2214
|
expires_at_ms: epochMs
|
|
2111
2215
|
});
|
|
2112
|
-
var FsWatchEventsParams =
|
|
2216
|
+
var FsWatchEventsParams = import_zod26.z.strictObject({
|
|
2113
2217
|
watch_id: FsWatchId,
|
|
2114
2218
|
/** Wait up to this long for a first change when none is waiting (0 answers at once). */
|
|
2115
|
-
wait_ms:
|
|
2219
|
+
wait_ms: import_zod26.z.int().min(0).max(25e3).default(0)
|
|
2116
2220
|
});
|
|
2117
|
-
var FsWatchEventsResult =
|
|
2221
|
+
var FsWatchEventsResult = import_zod26.z.strictObject({
|
|
2118
2222
|
/** What changed since the last read, oldest first; re-checked against the disk when read. */
|
|
2119
|
-
changes:
|
|
2223
|
+
changes: import_zod26.z.array(FsChange).max(1e3),
|
|
2120
2224
|
/** Changes were dropped (more than 1000 waited): list the folder again. */
|
|
2121
|
-
overflow:
|
|
2225
|
+
overflow: import_zod26.z.boolean(),
|
|
2122
2226
|
expires_at_ms: epochMs
|
|
2123
2227
|
});
|
|
2124
|
-
var FsWatchStopParams =
|
|
2125
|
-
var FsWatchStopResult =
|
|
2228
|
+
var FsWatchStopParams = import_zod26.z.strictObject({ watch_id: FsWatchId });
|
|
2229
|
+
var FsWatchStopResult = import_zod26.z.strictObject({ watch_id: FsWatchId });
|
|
2126
2230
|
|
|
2127
2231
|
// src/schema/exec-job.ts
|
|
2128
|
-
var
|
|
2129
|
-
var ExecJobId =
|
|
2130
|
-
var ExecJobStartParams =
|
|
2131
|
-
command:
|
|
2232
|
+
var import_zod27 = require("zod");
|
|
2233
|
+
var ExecJobId = import_zod27.z.string().regex(/^job_[A-Za-z0-9]{12,40}$/);
|
|
2234
|
+
var ExecJobStartParams = import_zod27.z.strictObject({
|
|
2235
|
+
command: import_zod27.z.string().min(1).max(131072),
|
|
2132
2236
|
/** The folder it runs in; the home folder when absent. */
|
|
2133
2237
|
cwd: AbsPath.optional(),
|
|
2134
|
-
env:
|
|
2238
|
+
env: import_zod27.z.record(import_zod27.z.string().regex(/^[A-Za-z_][A-Za-z0-9_]*$/).max(128), import_zod27.z.string().max(32768)).optional()
|
|
2135
2239
|
});
|
|
2136
|
-
var ExecJobStartResult =
|
|
2137
|
-
var ExecJobOutputParams =
|
|
2240
|
+
var ExecJobStartResult = import_zod27.z.strictObject({ job_id: ExecJobId, pid: import_zod27.z.int().min(1), cwd: AbsPath });
|
|
2241
|
+
var ExecJobOutputParams = import_zod27.z.strictObject({
|
|
2138
2242
|
job_id: ExecJobId,
|
|
2139
2243
|
/** Byte offset into the job's output to read from (next_offset of the last read; 0 = the start). */
|
|
2140
2244
|
offset: nonNegInt.default(0),
|
|
2141
2245
|
/** Wait up to this long for new output or the exit when none is waiting (0 answers at once). */
|
|
2142
|
-
wait_ms:
|
|
2143
|
-
max_bytes:
|
|
2246
|
+
wait_ms: import_zod27.z.int().min(0).max(25e3).default(0),
|
|
2247
|
+
max_bytes: import_zod27.z.int().min(1024).max(1048576).default(65536)
|
|
2144
2248
|
});
|
|
2145
|
-
var ExecJobOutputResult =
|
|
2249
|
+
var ExecJobOutputResult = import_zod27.z.strictObject({
|
|
2146
2250
|
/** stdout and stderr interleaved as they arrived (UTF-8). */
|
|
2147
|
-
output:
|
|
2251
|
+
output: import_zod27.z.string(),
|
|
2148
2252
|
next_offset: nonNegInt,
|
|
2149
2253
|
/** Bytes before `offset` that are gone (the job keeps its last 4 MiB). */
|
|
2150
2254
|
dropped_bytes: nonNegInt,
|
|
2151
|
-
running:
|
|
2152
|
-
exit_code:
|
|
2255
|
+
running: import_zod27.z.boolean(),
|
|
2256
|
+
exit_code: import_zod27.z.int().nullable()
|
|
2153
2257
|
});
|
|
2154
|
-
var ExecJobStopParams =
|
|
2258
|
+
var ExecJobStopParams = import_zod27.z.strictObject({
|
|
2155
2259
|
job_id: ExecJobId,
|
|
2156
2260
|
/** End it at once (SIGKILL; on Windows the whole tree with /F) instead of asking it to quit. */
|
|
2157
|
-
force:
|
|
2261
|
+
force: import_zod27.z.boolean().default(false)
|
|
2158
2262
|
});
|
|
2159
|
-
var ExecJobStopResult =
|
|
2160
|
-
var ExecJobInfo =
|
|
2263
|
+
var ExecJobStopResult = import_zod27.z.strictObject({ job_id: ExecJobId, exited: import_zod27.z.boolean(), exit_code: import_zod27.z.int().nullable() });
|
|
2264
|
+
var ExecJobInfo = import_zod27.z.strictObject({
|
|
2161
2265
|
job_id: ExecJobId,
|
|
2162
|
-
command:
|
|
2163
|
-
pid:
|
|
2266
|
+
command: import_zod27.z.string().max(1024),
|
|
2267
|
+
pid: import_zod27.z.int().min(1),
|
|
2164
2268
|
cwd: AbsPath,
|
|
2165
|
-
running:
|
|
2166
|
-
exit_code:
|
|
2269
|
+
running: import_zod27.z.boolean(),
|
|
2270
|
+
exit_code: import_zod27.z.int().nullable(),
|
|
2167
2271
|
started_at_ms: epochMs,
|
|
2168
2272
|
output_bytes: nonNegInt
|
|
2169
2273
|
});
|
|
2170
|
-
var ExecJobListParams =
|
|
2171
|
-
var ExecJobListResult =
|
|
2274
|
+
var ExecJobListParams = import_zod27.z.strictObject({});
|
|
2275
|
+
var ExecJobListResult = import_zod27.z.strictObject({ jobs: import_zod27.z.array(ExecJobInfo).max(64) });
|
|
2172
2276
|
|
|
2173
2277
|
// src/schema/coding.ts
|
|
2174
|
-
var
|
|
2175
|
-
var CodingServiceCredentials =
|
|
2176
|
-
access_token:
|
|
2177
|
-
user_id:
|
|
2278
|
+
var import_zod28 = require("zod");
|
|
2279
|
+
var CodingServiceCredentials = import_zod28.z.strictObject({
|
|
2280
|
+
access_token: import_zod28.z.string().min(16).max(16384),
|
|
2281
|
+
user_id: import_zod28.z.string().regex(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/),
|
|
2178
2282
|
/** The AI Matrx server this app talks to (production, or a local server on the nightly copy). */
|
|
2179
|
-
server_url:
|
|
2283
|
+
server_url: import_zod28.z.string().min(1).max(2048).regex(/^https?:\/\/[^\s/?#]+(\/[^\s?#]*)?$/)
|
|
2180
2284
|
});
|
|
2181
|
-
var CodingHistoryBlocked =
|
|
2285
|
+
var CodingHistoryBlocked = import_zod28.z.enum([
|
|
2182
2286
|
"signed_out",
|
|
2183
2287
|
"offline",
|
|
2184
2288
|
"organization_required",
|
|
@@ -2186,11 +2290,11 @@ var CodingHistoryBlocked = import_zod27.z.enum([
|
|
|
2186
2290
|
"cloud_list_unavailable",
|
|
2187
2291
|
"history_too_large"
|
|
2188
2292
|
]);
|
|
2189
|
-
var CodingHistoryFailure =
|
|
2190
|
-
session_id:
|
|
2191
|
-
reason:
|
|
2293
|
+
var CodingHistoryFailure = import_zod28.z.strictObject({
|
|
2294
|
+
session_id: import_zod28.z.string().max(64),
|
|
2295
|
+
reason: import_zod28.z.string().max(300)
|
|
2192
2296
|
});
|
|
2193
|
-
var CodingHistoryRun =
|
|
2297
|
+
var CodingHistoryRun = import_zod28.z.strictObject({
|
|
2194
2298
|
/** Claude Code sessions found on this computer. */
|
|
2195
2299
|
local_sessions: nonNegInt,
|
|
2196
2300
|
/** Of those, already complete in AI Matrx. */
|
|
@@ -2205,39 +2309,39 @@ var CodingHistoryRun = import_zod27.z.strictObject({
|
|
|
2205
2309
|
/** Changed while being read; a later run takes them. */
|
|
2206
2310
|
changed: nonNegInt,
|
|
2207
2311
|
failed: nonNegInt,
|
|
2208
|
-
failures:
|
|
2312
|
+
failures: import_zod28.z.array(CodingHistoryFailure).max(20),
|
|
2209
2313
|
/** Candidates not reached yet. */
|
|
2210
2314
|
remaining: nonNegInt,
|
|
2211
2315
|
/** The one line a person reads, e.g. "Imported 12 of 14 sessions. 140 already in AI Matrx." */
|
|
2212
|
-
summary:
|
|
2316
|
+
summary: import_zod28.z.string().max(400)
|
|
2213
2317
|
});
|
|
2214
|
-
var CodingHistoryStep =
|
|
2318
|
+
var CodingHistoryStep = import_zod28.z.strictObject({
|
|
2215
2319
|
/** Null when the run could not start (blocked before a plan existed). */
|
|
2216
|
-
plan_id:
|
|
2217
|
-
finished:
|
|
2320
|
+
plan_id: import_zod28.z.string().regex(/^[0-9a-f]{32}$/).nullable(),
|
|
2321
|
+
finished: import_zod28.z.boolean(),
|
|
2218
2322
|
blocked: CodingHistoryBlocked.nullable(),
|
|
2219
2323
|
run: CodingHistoryRun
|
|
2220
2324
|
});
|
|
2221
|
-
var CodingPlanMissingParams =
|
|
2222
|
-
var CodingImportNextParams =
|
|
2223
|
-
plan_id:
|
|
2325
|
+
var CodingPlanMissingParams = import_zod28.z.strictObject({ credentials: CodingServiceCredentials.nullable() });
|
|
2326
|
+
var CodingImportNextParams = import_zod28.z.strictObject({
|
|
2327
|
+
plan_id: import_zod28.z.string().regex(/^[0-9a-f]{32}$/),
|
|
2224
2328
|
credentials: CodingServiceCredentials.nullable()
|
|
2225
2329
|
});
|
|
2226
|
-
var CodingServiceProgress =
|
|
2227
|
-
phase:
|
|
2330
|
+
var CodingServiceProgress = import_zod28.z.strictObject({
|
|
2331
|
+
phase: import_zod28.z.enum(["checking", "importing"]),
|
|
2228
2332
|
done: nonNegInt,
|
|
2229
2333
|
total: nonNegInt
|
|
2230
2334
|
});
|
|
2231
|
-
var CodingHistoryImportMissingParams =
|
|
2232
|
-
var CodingHistoryImportMissingResult =
|
|
2233
|
-
state:
|
|
2335
|
+
var CodingHistoryImportMissingParams = import_zod28.z.strictObject({});
|
|
2336
|
+
var CodingHistoryImportMissingResult = import_zod28.z.strictObject({
|
|
2337
|
+
state: import_zod28.z.enum(["done", "blocked", "cancelled"]),
|
|
2234
2338
|
blocked: CodingHistoryBlocked.nullable(),
|
|
2235
2339
|
run: CodingHistoryRun,
|
|
2236
2340
|
elapsed_ms: nonNegInt
|
|
2237
2341
|
});
|
|
2238
|
-
var CodingHistoryProgressEvent =
|
|
2342
|
+
var CodingHistoryProgressEvent = import_zod28.z.strictObject({
|
|
2239
2343
|
request_id: RequestId,
|
|
2240
|
-
phase:
|
|
2344
|
+
phase: import_zod28.z.enum(["checking", "importing"]),
|
|
2241
2345
|
/** Sessions settled so far, of `total` candidates (0 of 0 while checking). */
|
|
2242
2346
|
done: nonNegInt,
|
|
2243
2347
|
total: nonNegInt,
|
|
@@ -2342,6 +2446,13 @@ var OPS = {
|
|
|
2342
2446
|
"audio.devices": { params: AudioDevicesParams, result: AudioDevicesResult, kind: "unary", since: "1.6", errors: ["PLATFORM_UNSUPPORTED", "INTERNAL"] },
|
|
2343
2447
|
"audio.record": { params: AudioRecordParams, result: AudioRecordResult, kind: "unary", since: "1.6", errors: ["NOT_FOUND", "PERMISSION_DENIED_OS", "PLATFORM_UNSUPPORTED", "RESOURCE_BUSY", "INTERNAL"] },
|
|
2344
2448
|
"audio.play": { params: AudioPlayParams, result: AudioPlayResult, kind: "unary", since: "1.6", errors: ["NOT_FOUND", "INVALID_PARAMS", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
|
|
2449
|
+
// The local AI Matrx servers (aidream's process-compose stack), supervised from Matrx 2's core.
|
|
2450
|
+
"stack.state": { params: StackStateParams, result: StackStateResult, kind: "unary", since: "1.16", errors: ["INTERNAL"] },
|
|
2451
|
+
"stack.start": { params: StackStartParams, result: StackRunResult, kind: "unary", since: "1.16", errors: ["RESOURCE_BUSY", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
|
|
2452
|
+
"stack.stop": { params: StackStopParams, result: StackRunResult, kind: "unary", since: "1.16", errors: ["RESOURCE_BUSY", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
|
|
2453
|
+
"stack.server.action": { params: StackServerActionParams, result: StackServerActionResult, kind: "unary", since: "1.16", errors: ["NOT_FOUND", "CONFLICT", "INTERNAL"] },
|
|
2454
|
+
"stack.logs": { params: StackLogsParams, result: StackLogsResult, kind: "unary", since: "1.16", errors: ["NOT_FOUND", "INTERNAL"] },
|
|
2455
|
+
"stack.errors": { params: StackErrorsParams, result: StackErrorsResult, kind: "unary", since: "1.16", errors: ["INTERNAL"] },
|
|
2345
2456
|
// Claude Code history (SPEC §6 coding): served by the `coding` Python service through SERVICES below.
|
|
2346
2457
|
"coding.history.import_missing": { params: CodingHistoryImportMissingParams, result: CodingHistoryImportMissingResult, kind: "unary", since: "1.5", errors: ["RESOURCE_BUSY", "RESOURCE_GONE", "CANCELLED", "INTERNAL"] }
|
|
2347
2458
|
};
|
|
@@ -2573,6 +2684,21 @@ var NAMED_SCHEMAS = {
|
|
|
2573
2684
|
AudioRecordResult,
|
|
2574
2685
|
AudioPlayParams,
|
|
2575
2686
|
AudioPlayResult,
|
|
2687
|
+
StackServerName,
|
|
2688
|
+
StackTone,
|
|
2689
|
+
StackServer,
|
|
2690
|
+
StackEvent,
|
|
2691
|
+
StackStateParams,
|
|
2692
|
+
StackStateResult,
|
|
2693
|
+
StackStartParams,
|
|
2694
|
+
StackStopParams,
|
|
2695
|
+
StackRunResult,
|
|
2696
|
+
StackServerActionParams,
|
|
2697
|
+
StackServerActionResult,
|
|
2698
|
+
StackLogsParams,
|
|
2699
|
+
StackLogsResult,
|
|
2700
|
+
StackErrorsParams,
|
|
2701
|
+
StackErrorsResult,
|
|
2576
2702
|
FsWatchId,
|
|
2577
2703
|
FsWatchStartParams,
|
|
2578
2704
|
FsWatchStartResult,
|
|
@@ -2701,7 +2827,7 @@ var FIELDS_SINCE = {
|
|
|
2701
2827
|
AppsChatsListResult: { updating: "1.9", live: "1.9", families: "1.10" },
|
|
2702
2828
|
AppsAccountsUsageResult: { problem: "1.12" },
|
|
2703
2829
|
AppsAccountsResetsResult: { problem: "1.12" },
|
|
2704
|
-
ChatRow: { app_project: "1.13", tokens: "1.13", original_title: "1.14", title_source: "1.14", title_override: "1.14" },
|
|
2830
|
+
ChatRow: { app_project: "1.13", tokens: "1.13", original_title: "1.14", title_source: "1.14", title_override: "1.14", archived: "1.15" },
|
|
2705
2831
|
AccountUsage: { plan: "1.13", credits: "1.13" }
|
|
2706
2832
|
};
|
|
2707
2833
|
var NULL_SINCE = {
|
|
@@ -2830,7 +2956,7 @@ function forPeer(op, part, value, version) {
|
|
|
2830
2956
|
var VERSIONED_RESULT_OPS = [.../* @__PURE__ */ new Set([...RESULT_PATH.keys(), ...WINDOW_RESULTS.keys(), ...NESTED_RESULTS.keys()])];
|
|
2831
2957
|
|
|
2832
2958
|
// src/contract.ts
|
|
2833
|
-
var CONTRACT_SHA256 = "
|
|
2959
|
+
var CONTRACT_SHA256 = "ee6873cbbdcba3960248ff0c5c71fe47c663b54c6e657d62d1ed5e04e51f17e2";
|
|
2834
2960
|
|
|
2835
2961
|
// src/close-policy.ts
|
|
2836
2962
|
var CLOSE_RULES = {
|