@ai-matrx/desktop-protocol 0.21.76 → 0.21.78
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 +21 -1
- package/dist/{chunk-server-HOQE4M4I.js → chunk-server-2NXFL3HJ.js} +24 -4
- package/dist/chunk-server-2NXFL3HJ.js.map +1 -0
- package/dist/client.cjs +16 -2
- 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 +1 -1
- package/dist/index.cjs +30 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +16 -5
- package/dist/index.d.ts +16 -5
- package/dist/index.js +12 -6
- package/dist/index.js.map +1 -1
- package/dist/{models-Bz88NHi0.d.cts → models-DzJnHq8i.d.cts} +71 -3
- package/dist/{models-Bz88NHi0.d.ts → models-DzJnHq8i.d.ts} +71 -3
- package/dist/react.d.cts +16 -1
- package/dist/react.d.ts +16 -1
- package/generated/desktop-protocol.schema.json +66 -2
- package/package.json +2 -2
- package/dist/chunk-server-HOQE4M4I.js.map +0 -1
package/dist/client.d.cts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { BackoffOptions } from '@ai-matrx/data/realtime';
|
|
2
2
|
export { RECONNECT_ALARM_ATTEMPTS } from '@ai-matrx/data/realtime';
|
|
3
3
|
import { z } from 'zod';
|
|
4
|
-
import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-
|
|
5
|
-
export { i as isDesktopProtocolError } from './models-
|
|
4
|
+
import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-DzJnHq8i.cjs';
|
|
5
|
+
export { i as isDesktopProtocolError } from './models-DzJnHq8i.cjs';
|
|
6
6
|
import { FrameHeader } from './frame.cjs';
|
|
7
7
|
|
|
8
8
|
/** The subset of the WHATWG WebSocket the client uses — browser, React Native, `ws` and Workers all fit. */
|
package/dist/client.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { BackoffOptions } from '@ai-matrx/data/realtime';
|
|
2
2
|
export { RECONNECT_ALARM_ATTEMPTS } from '@ai-matrx/data/realtime';
|
|
3
3
|
import { z } from 'zod';
|
|
4
|
-
import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-
|
|
5
|
-
export { i as isDesktopProtocolError } from './models-
|
|
4
|
+
import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-DzJnHq8i.js';
|
|
5
|
+
export { i as isDesktopProtocolError } from './models-DzJnHq8i.js';
|
|
6
6
|
import { FrameHeader } from './frame.js';
|
|
7
7
|
|
|
8
8
|
/** The subset of the WHATWG WebSocket the client uses — browser, React Native, `ws` and Workers all fit. */
|
package/dist/client.js
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -565,6 +565,8 @@ __export(src_exports, {
|
|
|
565
565
|
ModelsDownloadsListResult: () => ModelsDownloadsListResult,
|
|
566
566
|
ModelsInstallParams: () => ModelsInstallParams,
|
|
567
567
|
ModelsInstallResult: () => ModelsInstallResult,
|
|
568
|
+
ModelsLlmChatParams: () => ModelsLlmChatParams,
|
|
569
|
+
ModelsLlmChatResult: () => ModelsLlmChatResult,
|
|
568
570
|
ModelsLlmInstallParams: () => ModelsLlmInstallParams,
|
|
569
571
|
ModelsLlmInstallResult: () => ModelsLlmInstallResult,
|
|
570
572
|
ModelsLlmStartParams: () => ModelsLlmStartParams,
|
|
@@ -941,7 +943,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
941
943
|
var import_zod = require("zod");
|
|
942
944
|
var import_uuid = require("@ai-matrx/kit/uuid");
|
|
943
945
|
var PROTOCOL_MAJOR = 1;
|
|
944
|
-
var PROTOCOL_MINOR =
|
|
946
|
+
var PROTOCOL_MINOR = 76;
|
|
945
947
|
var PROTOCOL_VERSION = `${PROTOCOL_MAJOR}.${PROTOCOL_MINOR}`;
|
|
946
948
|
var ProtocolVersion = import_zod.z.string().regex(/^[1-9][0-9]{0,2}\.[0-9]{1,3}$/);
|
|
947
949
|
var RequestId = import_zod.z.string().min(1).max(64).regex(/^[A-Za-z0-9_-]+$/);
|
|
@@ -1028,8 +1030,13 @@ var ErrorReason = import_zod2.z.enum([
|
|
|
1028
1030
|
"awaiting_confirmation",
|
|
1029
1031
|
// TIMEOUT: the person did not answer the browser's confirmation in time
|
|
1030
1032
|
// 1.34 (REASONS_SINCE): the per-device tool policy (src/tools/policy.ts)
|
|
1031
|
-
"tool_disabled_on_device"
|
|
1033
|
+
"tool_disabled_on_device",
|
|
1032
1034
|
// AUTH_FORBIDDEN: the person turned this tool off for agents on this computer (Agents › Tools)
|
|
1035
|
+
// 1.76 (REASONS_SINCE): models.llm.chat
|
|
1036
|
+
"model_not_running",
|
|
1037
|
+
// NOT_FOUND (nothing runs) or RESOURCE_BUSY (another model runs): start this model first
|
|
1038
|
+
"model_server_unreachable"
|
|
1039
|
+
// RESOURCE_GONE (retryable): llama-server did not answer on this computer
|
|
1033
1040
|
]);
|
|
1034
1041
|
var FsPatchEditFailure = import_zod2.z.strictObject({ edit_index: nonNegInt, reason: import_zod2.z.string().max(300) });
|
|
1035
1042
|
var ProtocolErrorBody = import_zod2.z.strictObject({
|
|
@@ -1888,6 +1895,14 @@ var ModelsLlmStartParams = import_zod10.z.strictObject({
|
|
|
1888
1895
|
var ModelsLlmStartResult = import_zod10.z.strictObject({ running: LlmRunning, elapsed_ms: nonNegInt });
|
|
1889
1896
|
var ModelsLlmStopParams = import_zod10.z.strictObject({});
|
|
1890
1897
|
var ModelsLlmStopResult = import_zod10.z.strictObject({ stopped: import_zod10.z.boolean() });
|
|
1898
|
+
var ModelsLlmChatParams = import_zod10.z.strictObject({
|
|
1899
|
+
model: TextModelId,
|
|
1900
|
+
body: import_zod10.z.record(import_zod10.z.string().max(200), import_zod10.z.unknown()),
|
|
1901
|
+
/** Start the model first when nothing runs (a `models` progress event says so); a different model running is never stopped. */
|
|
1902
|
+
start_if_stopped: import_zod10.z.boolean().optional(),
|
|
1903
|
+
window_bytes: import_zod10.z.int().min(4096).max(16777216).optional()
|
|
1904
|
+
});
|
|
1905
|
+
var ModelsLlmChatResult = import_zod10.z.strictObject({ model: TextModelId, content_type: import_zod10.z.string().max(128) });
|
|
1891
1906
|
var Sha256Hex = import_zod10.z.string().regex(/^[0-9a-f]{64}$/);
|
|
1892
1907
|
var CatalogFile = import_zod10.z.strictObject({
|
|
1893
1908
|
/** Path inside the model's folder (the artifact's path_in_repo). */
|
|
@@ -5805,6 +5820,7 @@ var OPS = {
|
|
|
5805
5820
|
"models.llm.install": { params: ModelsLlmInstallParams, result: ModelsLlmInstallResult, kind: "unary", since: "1.31", errors: ["RESOURCE_BUSY", "RESOURCE_GONE", "TIMEOUT", "CANCELLED", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
|
|
5806
5821
|
"models.llm.start": { params: ModelsLlmStartParams, result: ModelsLlmStartResult, kind: "unary", since: "1.31", errors: ["NOT_FOUND", "RESOURCE_BUSY", "RESOURCE_GONE", "TIMEOUT", "CANCELLED", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
|
|
5807
5822
|
"models.llm.stop": { params: ModelsLlmStopParams, result: ModelsLlmStopResult, kind: "unary", since: "1.31", errors: ["INTERNAL"] },
|
|
5823
|
+
"models.llm.chat": { params: ModelsLlmChatParams, result: ModelsLlmChatResult, kind: "stream", since: "1.76", errors: ["NOT_FOUND", "RESOURCE_BUSY", "RESOURCE_GONE", "INVALID_PARAMS", "TIMEOUT", "CANCELLED", "RATE_LIMITED", "INTERNAL"] },
|
|
5808
5824
|
"models.downloads.list": { params: ModelsDownloadsListParams, result: ModelsDownloadsListResult, kind: "unary", since: "1.45", errors: ["INTERNAL"] },
|
|
5809
5825
|
"models.downloads.cancel": { params: ModelsDownloadsCancelParams, result: ModelsDownloadsCancelResult, kind: "unary", since: "1.45", errors: ["NOT_FOUND", "INTERNAL"] },
|
|
5810
5826
|
"models.local.list": { params: ModelsLocalListParams, result: ModelsLocalListResult, kind: "unary", since: "1.74", errors: ["INTERNAL"] },
|
|
@@ -6283,6 +6299,8 @@ var NAMED_SCHEMAS = {
|
|
|
6283
6299
|
ModelsLlmStartResult,
|
|
6284
6300
|
ModelsLlmStopParams,
|
|
6285
6301
|
ModelsLlmStopResult,
|
|
6302
|
+
ModelsLlmChatParams,
|
|
6303
|
+
ModelsLlmChatResult,
|
|
6286
6304
|
DownloadKind,
|
|
6287
6305
|
DownloadRow,
|
|
6288
6306
|
ModelsDownloadsListParams,
|
|
@@ -7049,7 +7067,9 @@ var REASONS_SINCE = {
|
|
|
7049
7067
|
browser_account_mismatch: "1.28",
|
|
7050
7068
|
browser_connection_off: "1.28",
|
|
7051
7069
|
awaiting_confirmation: "1.28",
|
|
7052
|
-
tool_disabled_on_device: "1.34"
|
|
7070
|
+
tool_disabled_on_device: "1.34",
|
|
7071
|
+
model_not_running: "1.76",
|
|
7072
|
+
model_server_unreachable: "1.76"
|
|
7053
7073
|
};
|
|
7054
7074
|
var PERMISSIONS_SINCE = {
|
|
7055
7075
|
reminders: "1.41",
|
|
@@ -7275,7 +7295,7 @@ function forPeer(op, part, value, version) {
|
|
|
7275
7295
|
var VERSIONED_RESULT_OPS = [.../* @__PURE__ */ new Set([...RESULT_PATH.keys(), ...WINDOW_RESULTS.keys(), ...NESTED_RESULTS.keys()])];
|
|
7276
7296
|
|
|
7277
7297
|
// src/contract.ts
|
|
7278
|
-
var CONTRACT_SHA256 = "
|
|
7298
|
+
var CONTRACT_SHA256 = "2abe47c1779ecfce3c670b9a5ed3d0a85d9c95e7ec1ebe40b13efcfc54156ca2";
|
|
7279
7299
|
|
|
7280
7300
|
// src/close-policy.ts
|
|
7281
7301
|
var CLOSE_RULES = {
|
|
@@ -7358,8 +7378,11 @@ var TOOL_CATALOG = [
|
|
|
7358
7378
|
{ name: "coding_sessions_drive", group: "personal_automation", state: "built", path: "device_op", ops: ["coding.start", "coding.takeover", "coding.send", "coding.stop", "coding.stop_elsewhere", "coding.options.set", "coding.account.continue", "coding.agent.set", "coding.folders.create", "coding.prefs.set", "coding.reconcile"], platforms: ALL, summary: "Claude Code and Codex sessions: start, send, stop, take over, rename" },
|
|
7359
7379
|
// ── 4. Documents, notes and entities (1.37: the core's `documents` and `notes` owners; desktop_web is the `tools` service) ──
|
|
7360
7380
|
{ name: "desktop_documents", group: "tools_service", state: "built", path: "device_op", ops: ["documents.pdf_text", "documents.ocr", "documents.image_resize", "documents.office_generate"], platforms: ALL, summary: "PDF text, OCR, images, Word and Excel files" },
|
|
7361
|
-
{ name: "desktop_web", group: "tools_service", state: "built", path: "device_op", ops: ["web.fetch", "web.scrape", "web.search", "web.fetch_with_browser"], platforms: ALL, summary: "Fetch, scrape and
|
|
7381
|
+
{ name: "desktop_web", group: "tools_service", state: "built", path: "device_op", ops: ["web.fetch", "web.scrape", "web.search", "web.fetch_with_browser"], platforms: ALL, summary: "Fetch, scrape, search and research the web from this computer's own connection (research: search on AI Matrx, every result read here)" },
|
|
7362
7382
|
{ name: "desktop_entities", group: "tools_service", state: "built", path: "device_op", ops: ["entities.ner", "entities.pii"], platforms: ALL, summary: "Names, places, organizations and private data, found on the device" },
|
|
7383
|
+
// matrx-local's SemanticFindPaths: needs a local embedding index of this computer's files and an
|
|
7384
|
+
// embedding model on the device; neither exists yet, so it is Coming soon on Agents › Tools.
|
|
7385
|
+
{ name: "desktop_semantic_find", group: "files_shell", state: "planned", path: "device_op", ops: ["fs.search_semantic"], platforms: ALL, summary: "Find files by meaning (a local embedding index of this computer's files)" },
|
|
7363
7386
|
{ name: "desktop_notes", group: "files_shell", state: "built", path: "device_op", ops: ["notes.folders", "notes.list", "notes.read", "notes.write", "notes.search"], platforms: ALL, summary: "The person's local notes (Documents/Matrx/Notes): list, read, write, search" },
|
|
7364
7387
|
// ── 5. Python `ml` service ───────────────────────────────────────────────────────────────────
|
|
7365
7388
|
// Built: models.transcribe through local_proxy's POST /op/{cap.op} (matrx-ai implementations/desktop.py).
|
|
@@ -7374,7 +7397,6 @@ var EXCLUDED_TOOLS = {
|
|
|
7374
7397
|
var tool = (name) => ({ kind: "tool", tool: name });
|
|
7375
7398
|
var dropped = (reason) => ({ kind: "dropped", reason });
|
|
7376
7399
|
var SHELL_COVERS = "Done with shell_execute (mv, cp, rm, tar), as every coding agent does";
|
|
7377
|
-
var CLOUD_SCRAPER = "The cloud scraper and research tools run with this computer as their network (the `proxy` capability)";
|
|
7378
7400
|
var LEGACY_ACTIONS = {
|
|
7379
7401
|
"local_file.read": tool("fs_read"),
|
|
7380
7402
|
"local_file.write": tool("fs_write"),
|
|
@@ -7389,7 +7411,7 @@ var LEGACY_ACTIONS = {
|
|
|
7389
7411
|
"local_file.list": tool("fs_list"),
|
|
7390
7412
|
"local_file.places": dropped("The device's home and folders reach the agent in its binding briefing (sysinfo.get)"),
|
|
7391
7413
|
"local_file.find": tool("fs_search"),
|
|
7392
|
-
"local_file.semantic_find": dropped("Needs a local embedding index;
|
|
7414
|
+
"local_file.semantic_find": dropped("Needs a local embedding index; desktop_semantic_find is planned (Coming soon on Agents \u203A Tools) until it exists"),
|
|
7393
7415
|
"local_shell.run": tool("shell_execute"),
|
|
7394
7416
|
"local_shell.output": tool("shell_job"),
|
|
7395
7417
|
"local_shell.stop": tool("shell_job"),
|
|
@@ -7437,7 +7459,7 @@ var LEGACY_ACTIONS = {
|
|
|
7437
7459
|
"local_web.fetch_with_browser": tool("desktop_web"),
|
|
7438
7460
|
"local_web.scrape": tool("desktop_web"),
|
|
7439
7461
|
"local_web.search": tool("desktop_web"),
|
|
7440
|
-
"local_web.research":
|
|
7462
|
+
"local_web.research": tool("desktop_web"),
|
|
7441
7463
|
"local_web.download": tool("desktop_net"),
|
|
7442
7464
|
"local_web.upload": dropped("Uploads are cloud files (matrx-files) and file sync, one upload path"),
|
|
7443
7465
|
"local_net.info": tool("desktop_net"),
|