@ai-matrx/desktop-protocol 0.21.69 → 0.21.70
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 -2
- package/dist/{chunk-server-TH6RJ5S5.js → chunk-server-I6R2ZKMX.js} +29 -6
- package/dist/chunk-server-I6R2ZKMX.js.map +1 -0
- package/dist/client.cjs +24 -5
- 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 +29 -6
- 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 +4 -2
- package/dist/index.js.map +1 -1
- package/dist/{models-BaCCJM1M.d.cts → models-_17aNpEC.d.cts} +45 -1
- package/dist/{models-BaCCJM1M.d.ts → models-_17aNpEC.d.ts} +45 -1
- package/dist/react.d.cts +2 -0
- package/dist/react.d.ts +2 -0
- package/generated/desktop-protocol.schema.json +56 -2
- package/package.json +2 -2
- package/dist/chunk-server-TH6RJ5S5.js.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { O as OpName } from './models-
|
|
3
|
-
export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as CatalogFile, k as CatalogModelEntry, l as ClientToCoreMsg, e as ClientType, m as CloseAction, n as CloseCode, o as CloseCodeValue, C as CloseOutcome, p as CloseRule, q as CoreToClientMsg, r as CreditMsg, D as DesktopProtocolError, s as DownloadKind, t as DownloadRow, d as EVENTS, u as EndMsg, E as EndReason, v as ErrorCode, w as ErrorCodeName, x as ErrorData, y as ErrorMsg, z as ErrorReason, A as ErrorReasonName, F as EventMsg, G as EventName, H as FsPatchEditFailure, I as HelloMsg, L as Limits, J as LlamaServerBuild, K as LlmRunning, N as LlmServerState, P as MlCatalogSetParams, Q as MlCatalogSetResult, R as MlInstallPhase, U as MlInstallProgress, f as MlProgress, V as MlRuntimeState, X as MlServiceState, Y as MlServiceStatus, Z as MlStatusParams, _ as MlStatusResult, $ as ModelKey, a0 as ModelsDownloadsCancelParams, a1 as ModelsDownloadsCancelResult, a2 as ModelsDownloadsListParams, a3 as ModelsDownloadsListResult, a4 as ModelsInstallParams, a5 as ModelsInstallResult, a6 as ModelsLlmInstallParams, a7 as ModelsLlmInstallResult, a8 as ModelsLlmStartParams, a9 as ModelsLlmStartResult, aa as ModelsLlmStatusParams, ab as ModelsLlmStatusResult, ac as ModelsLlmStopParams, ad as ModelsLlmStopResult, ae as ModelsProgressEvent, af as ModelsStatusParams, ag as ModelsStatusResult, ah as ModelsTranscribeParams, M as ModelsTranscribeResult, ai as NAMED_SCHEMAS, aj as NamedSchemaId, c as OPS, ak as OpDescriptor, a as OpParams, b as OpResult, al as OpSpec, am as PING_TEXT, an as PONG_TEXT, ao as ProtocolErrorBody, ap as RelayMsg, aq as RequestMsg, ar as ResponseMsg, as as SERVICES, at as SUBPROTOCOL, au as ServiceId, av as ServiceOpName, aw as ServiceOpSpec, ax as ServiceSpec, ay as Sha256Hex, S as StreamMeta, az as StreamMsg, aA as TextModelId, aB as TextModelInfo, aC as TranscriptSegment, T as TranscriptionModelId, aD as TranscriptionModelInfo, W as Welcome,
|
|
2
|
+
import { O as OpName } from './models-_17aNpEC.cjs';
|
|
3
|
+
export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as CatalogFile, k as CatalogModelEntry, l as ClientToCoreMsg, e as ClientType, m as CloseAction, n as CloseCode, o as CloseCodeValue, C as CloseOutcome, p as CloseRule, q as CoreToClientMsg, r as CreditMsg, D as DesktopProtocolError, s as DownloadKind, t as DownloadRow, d as EVENTS, u as EndMsg, E as EndReason, v as ErrorCode, w as ErrorCodeName, x as ErrorData, y as ErrorMsg, z as ErrorReason, A as ErrorReasonName, F as EventMsg, G as EventName, H as FsPatchEditFailure, I as HelloMsg, L as Limits, J as LlamaServerBuild, K as LlmRunning, N as LlmServerState, P as MlCatalogSetParams, Q as MlCatalogSetResult, R as MlInstallPhase, U as MlInstallProgress, f as MlProgress, V as MlRuntimeState, X as MlServiceState, Y as MlServiceStatus, Z as MlStatusParams, _ as MlStatusResult, $ as ModelKey, a0 as ModelsDownloadsCancelParams, a1 as ModelsDownloadsCancelResult, a2 as ModelsDownloadsListParams, a3 as ModelsDownloadsListResult, a4 as ModelsInstallParams, a5 as ModelsInstallResult, a6 as ModelsLlmInstallParams, a7 as ModelsLlmInstallResult, a8 as ModelsLlmStartParams, a9 as ModelsLlmStartResult, aa as ModelsLlmStatusParams, ab as ModelsLlmStatusResult, ac as ModelsLlmStopParams, ad as ModelsLlmStopResult, ae as ModelsProgressEvent, af as ModelsStatusParams, ag as ModelsStatusResult, ah as ModelsTranscribeParams, M as ModelsTranscribeResult, ai as NAMED_SCHEMAS, aj as NamedSchemaId, c as OPS, ak as OpDescriptor, a as OpParams, b as OpResult, al as OpSpec, am as PING_TEXT, an as PONG_TEXT, ao as ProtocolErrorBody, ap as RelayMsg, aq as RequestMsg, ar as ResponseMsg, as as SERVICES, at as SUBPROTOCOL, au as ServiceId, av as ServiceOpName, aw as ServiceOpSpec, ax as ServiceSpec, ay as Sha256Hex, S as StreamMeta, az as StreamMsg, aA as TextModelId, aB as TextModelInfo, aC as TranscriptSegment, T as TranscriptionModelId, aD as TranscriptionModelInfo, aE as UnusableTextModel, W as Welcome, aF as closeRule, i as isDesktopProtocolError, aG as isTerminalClose } from './models-_17aNpEC.cjs';
|
|
4
4
|
export { BROADCAST_CID, DecodedFrame, FRAME_HEADER_BYTES, FRAME_STRUCT_FORMAT, FRAME_VERSION, FrameChannel, FrameChannelValue, FrameFlag, assertFrameHeader, connectionEndFrame, decodeFrame, encodeFrame, hasFlag, isConnectionEnd, readCid, stampCid } from './frame.cjs';
|
|
5
5
|
|
|
6
6
|
/** @ai-matrx/desktop-protocol — version and primitive schemas. Schema source: lint-enforced rules in scripts/check-schema-source.mjs. */
|
|
@@ -194,10 +194,14 @@ declare const PROTOCOL_MAJOR: 1;
|
|
|
194
194
|
* 1.68 — account.agents.restore_version answers `new_version` (the version row the restore saved,
|
|
195
195
|
* agx_promote_version since aidream migration 20261021233500) and `unchanged` (it already
|
|
196
196
|
* matched; nothing saved). Optional fields only.
|
|
197
|
+
* 1.69 — every local language model is listed: models.llm.status `models` carries `title` and
|
|
198
|
+
* `problem` (on this computer but cannot run here, in one line with its fix), lists the
|
|
199
|
+
* models on this computer first, and is bounded at 1024 (was 64); ml.catalog_set `unusable`
|
|
200
|
+
* hands those models to the service. Optional fields only.
|
|
197
201
|
*/
|
|
198
|
-
declare const PROTOCOL_MINOR:
|
|
202
|
+
declare const PROTOCOL_MINOR: 69;
|
|
199
203
|
/** This package's version as the wire spells it ("major.minor"): hello, welcome, relay status. */
|
|
200
|
-
declare const PROTOCOL_VERSION: "1.
|
|
204
|
+
declare const PROTOCOL_VERSION: "1.69";
|
|
201
205
|
/** Internal building blocks — deliberately unnamed in $defs (inlined wherever used). */
|
|
202
206
|
declare const u32: z.ZodInt;
|
|
203
207
|
declare const nonNegInt: z.ZodInt;
|
|
@@ -11621,6 +11625,13 @@ declare const FIELDS_SINCE: {
|
|
|
11621
11625
|
readonly gpu_layers: "1.48";
|
|
11622
11626
|
readonly threads: "1.48";
|
|
11623
11627
|
};
|
|
11628
|
+
readonly TextModelInfo: {
|
|
11629
|
+
readonly title: "1.69";
|
|
11630
|
+
readonly problem: "1.69";
|
|
11631
|
+
};
|
|
11632
|
+
readonly MlCatalogSetParams: {
|
|
11633
|
+
readonly unusable: "1.69";
|
|
11634
|
+
};
|
|
11624
11635
|
readonly ModelsLlmStartParams: {
|
|
11625
11636
|
readonly gpu_layers: "1.48";
|
|
11626
11637
|
readonly threads: "1.48";
|
|
@@ -11958,7 +11969,7 @@ declare function forPeer(op: OpName | null, part: "error", value: unknown, versi
|
|
|
11958
11969
|
declare const VERSIONED_RESULT_OPS: readonly OpName[];
|
|
11959
11970
|
|
|
11960
11971
|
/** SHA-256 of generated/desktop-protocol.schema.json: the contract both sides of a service connection were built from. */
|
|
11961
|
-
declare const CONTRACT_SHA256: "
|
|
11972
|
+
declare const CONTRACT_SHA256: "6395bc1bd368ea907614881ce0921792316b2c56872074b11cc9b9b5c6c42b1f";
|
|
11962
11973
|
|
|
11963
11974
|
/**
|
|
11964
11975
|
* The local tool catalog (SPEC §10): every tool a platform agent calls on a person's computer, the
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { O as OpName } from './models-
|
|
3
|
-
export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as CatalogFile, k as CatalogModelEntry, l as ClientToCoreMsg, e as ClientType, m as CloseAction, n as CloseCode, o as CloseCodeValue, C as CloseOutcome, p as CloseRule, q as CoreToClientMsg, r as CreditMsg, D as DesktopProtocolError, s as DownloadKind, t as DownloadRow, d as EVENTS, u as EndMsg, E as EndReason, v as ErrorCode, w as ErrorCodeName, x as ErrorData, y as ErrorMsg, z as ErrorReason, A as ErrorReasonName, F as EventMsg, G as EventName, H as FsPatchEditFailure, I as HelloMsg, L as Limits, J as LlamaServerBuild, K as LlmRunning, N as LlmServerState, P as MlCatalogSetParams, Q as MlCatalogSetResult, R as MlInstallPhase, U as MlInstallProgress, f as MlProgress, V as MlRuntimeState, X as MlServiceState, Y as MlServiceStatus, Z as MlStatusParams, _ as MlStatusResult, $ as ModelKey, a0 as ModelsDownloadsCancelParams, a1 as ModelsDownloadsCancelResult, a2 as ModelsDownloadsListParams, a3 as ModelsDownloadsListResult, a4 as ModelsInstallParams, a5 as ModelsInstallResult, a6 as ModelsLlmInstallParams, a7 as ModelsLlmInstallResult, a8 as ModelsLlmStartParams, a9 as ModelsLlmStartResult, aa as ModelsLlmStatusParams, ab as ModelsLlmStatusResult, ac as ModelsLlmStopParams, ad as ModelsLlmStopResult, ae as ModelsProgressEvent, af as ModelsStatusParams, ag as ModelsStatusResult, ah as ModelsTranscribeParams, M as ModelsTranscribeResult, ai as NAMED_SCHEMAS, aj as NamedSchemaId, c as OPS, ak as OpDescriptor, a as OpParams, b as OpResult, al as OpSpec, am as PING_TEXT, an as PONG_TEXT, ao as ProtocolErrorBody, ap as RelayMsg, aq as RequestMsg, ar as ResponseMsg, as as SERVICES, at as SUBPROTOCOL, au as ServiceId, av as ServiceOpName, aw as ServiceOpSpec, ax as ServiceSpec, ay as Sha256Hex, S as StreamMeta, az as StreamMsg, aA as TextModelId, aB as TextModelInfo, aC as TranscriptSegment, T as TranscriptionModelId, aD as TranscriptionModelInfo, W as Welcome,
|
|
2
|
+
import { O as OpName } from './models-_17aNpEC.js';
|
|
3
|
+
export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as CatalogFile, k as CatalogModelEntry, l as ClientToCoreMsg, e as ClientType, m as CloseAction, n as CloseCode, o as CloseCodeValue, C as CloseOutcome, p as CloseRule, q as CoreToClientMsg, r as CreditMsg, D as DesktopProtocolError, s as DownloadKind, t as DownloadRow, d as EVENTS, u as EndMsg, E as EndReason, v as ErrorCode, w as ErrorCodeName, x as ErrorData, y as ErrorMsg, z as ErrorReason, A as ErrorReasonName, F as EventMsg, G as EventName, H as FsPatchEditFailure, I as HelloMsg, L as Limits, J as LlamaServerBuild, K as LlmRunning, N as LlmServerState, P as MlCatalogSetParams, Q as MlCatalogSetResult, R as MlInstallPhase, U as MlInstallProgress, f as MlProgress, V as MlRuntimeState, X as MlServiceState, Y as MlServiceStatus, Z as MlStatusParams, _ as MlStatusResult, $ as ModelKey, a0 as ModelsDownloadsCancelParams, a1 as ModelsDownloadsCancelResult, a2 as ModelsDownloadsListParams, a3 as ModelsDownloadsListResult, a4 as ModelsInstallParams, a5 as ModelsInstallResult, a6 as ModelsLlmInstallParams, a7 as ModelsLlmInstallResult, a8 as ModelsLlmStartParams, a9 as ModelsLlmStartResult, aa as ModelsLlmStatusParams, ab as ModelsLlmStatusResult, ac as ModelsLlmStopParams, ad as ModelsLlmStopResult, ae as ModelsProgressEvent, af as ModelsStatusParams, ag as ModelsStatusResult, ah as ModelsTranscribeParams, M as ModelsTranscribeResult, ai as NAMED_SCHEMAS, aj as NamedSchemaId, c as OPS, ak as OpDescriptor, a as OpParams, b as OpResult, al as OpSpec, am as PING_TEXT, an as PONG_TEXT, ao as ProtocolErrorBody, ap as RelayMsg, aq as RequestMsg, ar as ResponseMsg, as as SERVICES, at as SUBPROTOCOL, au as ServiceId, av as ServiceOpName, aw as ServiceOpSpec, ax as ServiceSpec, ay as Sha256Hex, S as StreamMeta, az as StreamMsg, aA as TextModelId, aB as TextModelInfo, aC as TranscriptSegment, T as TranscriptionModelId, aD as TranscriptionModelInfo, aE as UnusableTextModel, W as Welcome, aF as closeRule, i as isDesktopProtocolError, aG as isTerminalClose } from './models-_17aNpEC.js';
|
|
4
4
|
export { BROADCAST_CID, DecodedFrame, FRAME_HEADER_BYTES, FRAME_STRUCT_FORMAT, FRAME_VERSION, FrameChannel, FrameChannelValue, FrameFlag, assertFrameHeader, connectionEndFrame, decodeFrame, encodeFrame, hasFlag, isConnectionEnd, readCid, stampCid } from './frame.js';
|
|
5
5
|
|
|
6
6
|
/** @ai-matrx/desktop-protocol — version and primitive schemas. Schema source: lint-enforced rules in scripts/check-schema-source.mjs. */
|
|
@@ -194,10 +194,14 @@ declare const PROTOCOL_MAJOR: 1;
|
|
|
194
194
|
* 1.68 — account.agents.restore_version answers `new_version` (the version row the restore saved,
|
|
195
195
|
* agx_promote_version since aidream migration 20261021233500) and `unchanged` (it already
|
|
196
196
|
* matched; nothing saved). Optional fields only.
|
|
197
|
+
* 1.69 — every local language model is listed: models.llm.status `models` carries `title` and
|
|
198
|
+
* `problem` (on this computer but cannot run here, in one line with its fix), lists the
|
|
199
|
+
* models on this computer first, and is bounded at 1024 (was 64); ml.catalog_set `unusable`
|
|
200
|
+
* hands those models to the service. Optional fields only.
|
|
197
201
|
*/
|
|
198
|
-
declare const PROTOCOL_MINOR:
|
|
202
|
+
declare const PROTOCOL_MINOR: 69;
|
|
199
203
|
/** This package's version as the wire spells it ("major.minor"): hello, welcome, relay status. */
|
|
200
|
-
declare const PROTOCOL_VERSION: "1.
|
|
204
|
+
declare const PROTOCOL_VERSION: "1.69";
|
|
201
205
|
/** Internal building blocks — deliberately unnamed in $defs (inlined wherever used). */
|
|
202
206
|
declare const u32: z.ZodInt;
|
|
203
207
|
declare const nonNegInt: z.ZodInt;
|
|
@@ -11621,6 +11625,13 @@ declare const FIELDS_SINCE: {
|
|
|
11621
11625
|
readonly gpu_layers: "1.48";
|
|
11622
11626
|
readonly threads: "1.48";
|
|
11623
11627
|
};
|
|
11628
|
+
readonly TextModelInfo: {
|
|
11629
|
+
readonly title: "1.69";
|
|
11630
|
+
readonly problem: "1.69";
|
|
11631
|
+
};
|
|
11632
|
+
readonly MlCatalogSetParams: {
|
|
11633
|
+
readonly unusable: "1.69";
|
|
11634
|
+
};
|
|
11624
11635
|
readonly ModelsLlmStartParams: {
|
|
11625
11636
|
readonly gpu_layers: "1.48";
|
|
11626
11637
|
readonly threads: "1.48";
|
|
@@ -11958,7 +11969,7 @@ declare function forPeer(op: OpName | null, part: "error", value: unknown, versi
|
|
|
11958
11969
|
declare const VERSIONED_RESULT_OPS: readonly OpName[];
|
|
11959
11970
|
|
|
11960
11971
|
/** SHA-256 of generated/desktop-protocol.schema.json: the contract both sides of a service connection were built from. */
|
|
11961
|
-
declare const CONTRACT_SHA256: "
|
|
11972
|
+
declare const CONTRACT_SHA256: "6395bc1bd368ea907614881ce0921792316b2c56872074b11cc9b9b5c6c42b1f";
|
|
11962
11973
|
|
|
11963
11974
|
/**
|
|
11964
11975
|
* The local tool catalog (SPEC §10): every tool a platform agent calls on a person's computer, the
|
package/dist/index.js
CHANGED
|
@@ -770,6 +770,7 @@ import {
|
|
|
770
770
|
TranscriptSegment,
|
|
771
771
|
TranscriptionModelId,
|
|
772
772
|
TranscriptionModelInfo,
|
|
773
|
+
UnusableTextModel,
|
|
773
774
|
VERSIONED_RESULT_OPS,
|
|
774
775
|
VaultFieldSummary,
|
|
775
776
|
VaultItemKind,
|
|
@@ -856,7 +857,7 @@ import {
|
|
|
856
857
|
statusForPeer,
|
|
857
858
|
u32,
|
|
858
859
|
versionSubprotocol
|
|
859
|
-
} from "./chunk-server-
|
|
860
|
+
} from "./chunk-server-I6R2ZKMX.js";
|
|
860
861
|
import {
|
|
861
862
|
BROADCAST_CID,
|
|
862
863
|
DesktopProtocolError,
|
|
@@ -877,7 +878,7 @@ import {
|
|
|
877
878
|
} from "./chunk-server-OVLU5III.js";
|
|
878
879
|
|
|
879
880
|
// src/contract.ts
|
|
880
|
-
var CONTRACT_SHA256 = "
|
|
881
|
+
var CONTRACT_SHA256 = "6395bc1bd368ea907614881ce0921792316b2c56872074b11cc9b9b5c6c42b1f";
|
|
881
882
|
|
|
882
883
|
// src/tools/catalog.ts
|
|
883
884
|
var TOOL_GROUPS = [
|
|
@@ -2033,6 +2034,7 @@ export {
|
|
|
2033
2034
|
TranscriptSegment,
|
|
2034
2035
|
TranscriptionModelId,
|
|
2035
2036
|
TranscriptionModelInfo,
|
|
2037
|
+
UnusableTextModel,
|
|
2036
2038
|
VERSIONED_RESULT_OPS,
|
|
2037
2039
|
VaultFieldSummary,
|
|
2038
2040
|
VaultItemKind,
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/contract.ts","../src/tools/catalog.ts","../src/tools/status.ts","../src/tools/policy.ts"],"sourcesContent":["// AUTO-GENERATED by scripts/generate.ts — DO NOT EDIT. `pnpm generate --check` fails on any hand edit.\n/** SHA-256 of generated/desktop-protocol.schema.json: the contract both sides of a service connection were built from. */\nexport const CONTRACT_SHA256 = \"700c5295bf34b56cc46a8804292b88b06fcefd8c7b39e3929a6957b13c4fdfbb\" as const;\n","/**\n * The local tool catalog (SPEC §10): every tool a platform agent calls on a person's computer, the\n * protocol ops it reaches, the group it ships in, and what became of each of matrx-local's 139\n * handlers (120 actions + the 19 action-enum dispatchers that fanned out to them).\n *\n * Data only. The status table (./status.ts) joins it with the harnesses' results, so a tool listed\n * here with no passing result reads \"untested\", never \"working\". Design and the reasons behind each\n * group: matrx-desktop/design/local-tools.md.\n */\nimport type { OpName } from \"../schema/registry\";\nimport type { ToolPlatform } from \"../schema/tools\";\n\nexport type ToolGroupId = \"files_shell\" | \"os_control\" | \"personal_automation\" | \"tools_service\" | \"ml_service\" | \"windows_admin\";\n\nexport interface ToolGroup {\n readonly id: ToolGroupId;\n readonly order: number;\n readonly title: string;\n /** Who implements the ops: a TS capability owner in the core, or a Python service. */\n readonly owner: \"core\" | \"python_tools\" | \"python_ml\";\n}\n\nexport const TOOL_GROUPS: readonly ToolGroup[] = [\n { id: \"files_shell\", order: 1, title: \"Files and shell\", owner: \"core\" },\n { id: \"os_control\", order: 2, title: \"Computer control\", owner: \"core\" },\n { id: \"personal_automation\", order: 3, title: \"Personal apps and automation\", owner: \"core\" },\n { id: \"tools_service\", order: 4, title: \"Web, documents, OCR and entities\", owner: \"python_tools\" },\n { id: \"ml_service\", order: 5, title: \"Speech\", owner: \"python_ml\" },\n { id: \"windows_admin\", order: 6, title: \"Windows administration\", owner: \"core\" },\n];\n\n/**\n * How an agent's call reaches the device. Both end at the relay's `POST /v1/devices/{id}/call`:\n * - `sandbox_proxy`: the cloud-sandbox-shaped tools (fs_*, shell_*). matrx-ai's `_sandbox_proxy`\n * calls aidream `/api/local-proxy/{device}/{fs|search|exec}/…`, which maps the route to its op.\n * Agent code never knows a laptop from a cloud box (SPEC §6.1).\n * - `device_op`: desktop-only capabilities. One generic route, `/api/local-proxy/{device}/op/{cap.op}`,\n * params and result exactly the op's schema; the tool definition is generated from that schema.\n * - `server`: runs on the aidream server even when the turn is bound to a device (a defect when\n * the tool reads a local path; see `note`).\n */\nexport type ToolPath = \"sandbox_proxy\" | \"device_op\" | \"server\";\n\n/** `built`: the ops exist in the protocol and Matrx 2's core serves them (registered on the platform for agents with the server tool); `planned`: designed, not built; `broken`: registered but wrong on a device. */\nexport type ToolState = \"built\" | \"planned\" | \"broken\";\n\nexport interface CatalogTool {\n /** The platform registry name (`tool.definition.name`). */\n readonly name: string;\n readonly group: ToolGroupId;\n readonly state: ToolState;\n readonly path: ToolPath;\n /** Ops the tool sends. For `built` tools every one is in OPS (a test enforces it). */\n readonly ops: readonly string[];\n readonly platforms: readonly ToolPlatform[];\n /** One line for the status table. */\n readonly summary: string;\n /** Required for `broken`: what is wrong. */\n readonly note?: string;\n}\n\nconst ALL: readonly ToolPlatform[] = [\"darwin\", \"win32\", \"linux\"];\n\nexport const TOOL_CATALOG: readonly CatalogTool[] = [\n // ── 1. Files and shell (core `fs`, `exec`; the cloud sandbox's agent tools) ──────────────────\n { name: \"fs_read\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\"], platforms: ALL, summary: \"Read a file, paged\" },\n { name: \"fs_write\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\", \"fs.write\"], platforms: ALL, summary: \"Create or overwrite a file\" },\n { name: \"fs_edit\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\", \"fs.patch\"], platforms: ALL, summary: \"Replace one exact string\" },\n { name: \"fs_patch\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\", \"fs.patch\"], platforms: ALL, summary: \"Apply several exact edits at once\" },\n { name: \"fs_list\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.list\"], platforms: ALL, summary: \"List a folder\" },\n { name: \"fs_mkdir\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.mkdir\"], platforms: ALL, summary: \"Create a folder\" },\n { name: \"fs_search\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.search_paths\", \"fs.search_content\"], platforms: ALL, summary: \"Find files by name or content\" },\n { name: \"shell_execute\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"exec.run\"], platforms: ALL, summary: \"Run a command; cd carries over\" },\n { name: \"shell_python\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"exec.run\"], platforms: ALL, summary: \"Run a Python script\" },\n { name: \"desktop_git\", group: \"files_shell\", state: \"built\", path: \"device_op\", ops: [\"git.status\", \"git.diff\", \"git.log\", \"git.add\", \"git.commit\", \"git.push\", \"git.pull\", \"git.branch\", \"git.stash\", \"git.clone\"], platforms: ALL, summary: \"Git: status, diff, log, commit, branches, push and pull\" },\n { name: \"shell_job\", group: \"files_shell\", state: \"built\", path: \"device_op\", ops: [\"exec.job.start\", \"exec.job.output\", \"exec.job.stop\", \"exec.job.list\"], platforms: ALL, summary: \"Background commands: start, read output, stop\" },\n\n // ── 2. Computer control (TS owners) ──────────────────────────────────────────────────────────\n { name: \"desktop_process\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"proc.list\", \"proc.ports\", \"proc.kill\"], platforms: ALL, summary: \"Running processes and ports; stop one\" },\n { name: \"desktop_apps\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"apps.list\", \"apps.open\"], platforms: ALL, summary: \"Installed apps; open or bring one forward\" },\n { name: \"desktop_system\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"sysinfo.get\", \"sysinfo.hardware\", \"system.open_url\", \"system.open_path\", \"system.open_settings\", \"system.notify\"], platforms: ALL, summary: \"System facts, open, notify\" },\n { name: \"desktop_clipboard\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"clipboard.read\", \"clipboard.write\"], platforms: ALL, summary: \"Read and write the clipboard's text\" },\n { name: \"desktop_screen\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"screen.list\", \"screen.capture\"], platforms: ALL, summary: \"Displays and screenshots\" },\n { name: \"desktop_browser\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"browser.sessions\", \"browser.call\"], platforms: ALL, summary: \"The person's own browser through the AI Matrx extension: tabs, read, screenshot, navigate, click, type\" },\n { name: \"desktop_window\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"window.list\", \"window.focus\", \"window.move\", \"window.minimize\"], platforms: ALL, summary: \"Find, focus and arrange windows\" },\n { name: \"desktop_input\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"input.type_text\", \"input.hotkey\", \"input.mouse_click\", \"input.mouse_move\", \"input.keyboard_settings\", \"input.set_keyboard_settings\"], platforms: ALL, summary: \"Keyboard and mouse\" },\n { name: \"desktop_audio\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"audio.devices\", \"audio.levels\", \"audio.set_levels\", \"audio.record\", \"audio.play\"], platforms: ALL, summary: \"Audio devices, record, play\" },\n { name: \"desktop_power\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"power.status\", \"power.history\", \"power.prevent_sleep\"], platforms: ALL, summary: \"Battery and keep awake\" },\n { name: \"desktop_resources\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"resources.snapshot\", \"resources.activity\", \"resources.stop_job\", \"resources.incidents\"], platforms: ALL, summary: \"CPU, memory and disk use; what is using them, grouped into jobs; stop a job; the slowdown log\" },\n { name: \"fs_watch\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"fs.watch.start\", \"fs.watch.events\", \"fs.watch.stop\"], platforms: ALL, summary: \"Watch a folder; read what changed\" },\n\n // ── 3. Personal apps and automation (1.37: the core's `automation`, `personal`, `net` and `schedule` owners) ──\n { name: \"desktop_automation\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"automation.script\"], platforms: [\"darwin\", \"win32\"], summary: \"AppleScript or JavaScript for Automation on a Mac, PowerShell on Windows\" },\n { name: \"desktop_mail\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"mail.accounts\", \"mail.list\", \"mail.send\"], platforms: [\"darwin\"], summary: \"The Mail app: accounts, messages, send\" },\n { name: \"desktop_outlook\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"outlook.status\", \"outlook.draft\", \"outlook.list\", \"outlook.read\"], platforms: [\"win32\"], summary: \"The person's own Outlook: drafts with attachments, recent mail, one message\" },\n { name: \"desktop_messages\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"messages.chats\", \"messages.list\", \"messages.send\"], platforms: [\"darwin\"], summary: \"The Messages app: chats, messages, send\" },\n { name: \"desktop_contacts\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"contacts.search\", \"contacts.get\"], platforms: [\"darwin\"], summary: \"Contacts: search, one card\" },\n { name: \"desktop_calendar\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"calendar.list\", \"calendar.create\", \"reminders.list\", \"reminders.create\"], platforms: [\"darwin\"], summary: \"Calendar and Reminders: list and add\" },\n { name: \"desktop_photos\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"photos.search\", \"photos.get\"], platforms: [\"darwin\"], summary: \"The Photos library: find, export an original\" },\n // Windows comes back once a Windows location fix is proven (plan attack retire-local 2026-10-12, B6):\n // until then local_mac_apps (macOS-only) is judged on macOS and nothing claims Windows.\n { name: \"desktop_location\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"location.get\"], platforms: [\"darwin\"], summary: \"Where the computer is (the OS's location service)\" },\n { name: \"desktop_net\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"net.info\", \"net.wifi\", \"net.bluetooth\", \"net.devices\", \"net.mdns\", \"net.scan\", \"net.download\"], platforms: ALL, summary: \"Local network, Wi-Fi, Bluetooth, open ports and downloads\" },\n { name: \"desktop_schedule\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"schedule.create\", \"schedule.list\", \"schedule.cancel\"], platforms: ALL, summary: \"Run a tool's op on this computer on an interval; list and cancel\" },\n // 1.38, code from anywhere: the person's Claude Code and Codex sessions on this computer. Turning\n // either off in Agents › Tools refuses its ops on every relay connection (the existing switch).\n { name: \"coding_sessions_read\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"coding.providers\", \"coding.sessions.list\", \"coding.discover\", \"coding.runs.list\", \"coding.history\", \"coding.transcript.read\", \"coding.item.full\", \"coding.activity\", \"coding.folders.recent\", \"coding.folders.check\", \"coding.agents.access\", \"coding.titles.status\", \"coding.prefs.list\", \"coding.recent.seen\", \"coding.search\", \"coding.transcript.raw\", \"coding.watch\", \"coding.session.watch\"], platforms: ALL, summary: \"Claude Code and Codex sessions: list, read live, search, download\" },\n { 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\" },\n\n // ── 4. Documents, notes and entities (1.37: the core's `documents` and `notes` owners; desktop_web is the `tools` service) ──\n { 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\" },\n { 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 search the web from this computer's own connection\" },\n { 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\" },\n { 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\" },\n\n // ── 5. Python `ml` service ───────────────────────────────────────────────────────────────────\n // Built: models.transcribe through local_proxy's POST /op/{cap.op} (matrx-ai implementations/desktop.py).\n // Whisper detects the language itself, so matrx-local's speech_locales needs no op of its own.\n { name: \"desktop_transcribe\", group: \"ml_service\", state: \"built\", path: \"device_op\", ops: [\"models.transcribe\"], platforms: ALL, summary: \"Speech to text on the device\" },\n\n // ── 6. Windows administration ────────────────────────────────────────────────────────────────\n { name: \"desktop_windows_admin\", group: \"windows_admin\", state: \"built\", path: \"device_op\", ops: [\"windows.registry_read\", \"windows.registry_write\", \"windows.services\", \"windows.service_control\", \"windows.event_log\", \"windows.features\"], platforms: [\"win32\"], summary: \"Registry, services, event log, optional features\" },\n];\n\n/**\n * Tools armed with a device binding that are deliberately NOT device tools, each with its reason.\n * They run on the server; the status table does not track them.\n */\nexport const EXCLUDED_TOOLS: Readonly<Record<string, string>> = {\n git_ingest:\n \"Runs on the server: it ingests repository URLs. A local path on a bound computer or sandbox is refused with the fs_* and shell remedy, since the server cannot see it\",\n};\n\n/** What became of one matrx-local handler. */\nexport type LegacyDisposition =\n | { readonly kind: \"tool\"; readonly tool: string }\n | { readonly kind: \"dropped\"; readonly reason: string };\n\nconst tool = (name: string): LegacyDisposition => ({ kind: \"tool\", tool: name });\nconst dropped = (reason: string): LegacyDisposition => ({ kind: \"dropped\", reason });\n\nconst SHELL_COVERS = \"Done with shell_execute (mv, cp, rm, tar), as every coding agent does\";\nconst CLOUD_SCRAPER = \"The cloud scraper and research tools run with this computer as their network (the `proxy` capability)\";\n\n/** matrx-local's 120 actions (`app/tools/actions.py` ACTION_GROUPS), keyed `<mega tool>.<action>`. */\nexport const LEGACY_ACTIONS: Readonly<Record<string, LegacyDisposition>> = {\n \"local_file.read\": tool(\"fs_read\"),\n \"local_file.write\": tool(\"fs_write\"),\n \"local_file.edit\": tool(\"fs_edit\"),\n \"local_file.move\": dropped(SHELL_COVERS),\n \"local_file.copy\": dropped(SHELL_COVERS),\n \"local_file.delete\": dropped(SHELL_COVERS),\n \"local_file.rename\": dropped(SHELL_COVERS),\n \"local_file.mkdir\": tool(\"fs_mkdir\"),\n \"local_file.glob\": tool(\"fs_search\"),\n \"local_file.grep\": tool(\"fs_search\"),\n \"local_file.list\": tool(\"fs_list\"),\n \"local_file.places\": dropped(\"The device's home and folders reach the agent in its binding briefing (sysinfo.get)\"),\n \"local_file.find\": tool(\"fs_search\"),\n \"local_file.semantic_find\": dropped(\"Needs a local embedding index; returns with file sync's index, not before\"),\n\n \"local_shell.run\": tool(\"shell_execute\"),\n \"local_shell.output\": tool(\"shell_job\"),\n \"local_shell.stop\": tool(\"shell_job\"),\n\n \"local_window.list\": tool(\"desktop_window\"),\n \"local_window.focus\": tool(\"desktop_window\"),\n \"local_window.move\": tool(\"desktop_window\"),\n \"local_window.minimize\": tool(\"desktop_window\"),\n\n \"local_process.list\": tool(\"desktop_process\"),\n \"local_process.ports\": tool(\"desktop_process\"),\n \"local_process.launch_app\": tool(\"desktop_apps\"),\n \"local_process.kill\": tool(\"desktop_process\"),\n \"local_process.focus_app\": tool(\"desktop_apps\"),\n \"local_process.terminals\": dropped(\"Matrx 2 terminals are exec sessions; the person's own terminal windows are not the agent's\"),\n \"local_process.tail_terminal\": dropped(\"Matrx 2 terminals are exec sessions; the person's own terminal windows are not the agent's\"),\n \"local_process.installed_apps\": tool(\"desktop_apps\"),\n\n \"local_input.type_text\": tool(\"desktop_input\"),\n \"local_input.hotkey\": tool(\"desktop_input\"),\n \"local_input.mouse_click\": tool(\"desktop_input\"),\n \"local_input.mouse_move\": tool(\"desktop_input\"),\n\n \"local_audio.devices\": tool(\"desktop_audio\"),\n \"local_audio.record\": tool(\"desktop_audio\"),\n \"local_audio.play\": tool(\"desktop_audio\"),\n \"local_audio.transcribe\": tool(\"desktop_transcribe\"),\n \"local_audio.transcribe_with_speech\": tool(\"desktop_transcribe\"),\n \"local_audio.speech_locales\": tool(\"desktop_transcribe\"),\n\n \"local_clipboard.read\": tool(\"desktop_clipboard\"),\n \"local_clipboard.write\": tool(\"desktop_clipboard\"),\n\n \"local_screen.screenshot\": tool(\"desktop_screen\"),\n \"local_screen.list\": tool(\"desktop_screen\"),\n \"local_screen.capture_book\": dropped(\"A one-off loop of screenshot plus page turn; the agent composes it from desktop_screen and desktop_input\"),\n\n \"local_system.info\": tool(\"desktop_system\"),\n \"local_system.open_url\": tool(\"desktop_system\"),\n \"local_system.open_path\": tool(\"desktop_system\"),\n \"local_system.notify\": tool(\"desktop_system\"),\n\n // The person's own browser is the AI Matrx extension paired with Matrx 2 (cap browser).\n \"local_browser.navigate\": tool(\"desktop_browser\"),\n \"local_browser.click\": tool(\"desktop_browser\"),\n \"local_browser.type_text\": tool(\"desktop_browser\"),\n \"local_browser.extract\": tool(\"desktop_browser\"),\n \"local_browser.screenshot\": tool(\"desktop_browser\"),\n \"local_browser.eval\": dropped(\"The extension runs no page script for Matrx 2: its script and cdp tools are privileged and refused over the desktop path; read, click and type cover what eval was used for\"),\n \"local_browser.tabs\": tool(\"desktop_browser\"),\n \"local_browser.close\": tool(\"desktop_browser\"),\n\n \"local_web.fetch\": tool(\"desktop_web\"),\n \"local_web.fetch_with_browser\": tool(\"desktop_web\"),\n \"local_web.scrape\": tool(\"desktop_web\"),\n \"local_web.search\": tool(\"desktop_web\"),\n \"local_web.research\": dropped(CLOUD_SCRAPER),\n \"local_web.download\": tool(\"desktop_net\"),\n \"local_web.upload\": dropped(\"Uploads are cloud files (matrx-files) and file sync, one upload path\"),\n\n \"local_net.info\": tool(\"desktop_net\"),\n \"local_net.scan\": tool(\"desktop_net\"),\n \"local_net.port_scan\": tool(\"desktop_net\"),\n \"local_net.mdns_discover\": tool(\"desktop_net\"),\n \"local_net.wifi_networks\": tool(\"desktop_net\"),\n \"local_net.bluetooth_devices\": tool(\"desktop_net\"),\n \"local_net.connected_devices\": tool(\"desktop_net\"),\n\n \"local_monitor.resources\": tool(\"desktop_resources\"),\n \"local_monitor.battery\": tool(\"desktop_power\"),\n \"local_monitor.disk_usage\": tool(\"desktop_resources\"),\n \"local_monitor.top_processes\": tool(\"desktop_process\"),\n \"local_monitor.watch_directory\": tool(\"fs_watch\"),\n \"local_monitor.watch_events\": tool(\"fs_watch\"),\n \"local_monitor.stop_watch\": tool(\"fs_watch\"),\n \"local_monitor.heartbeat\": dropped(\"The relay's device status replaces the heartbeat\"),\n\n // Matrx Local's scheduler ran one of its tools on an interval; desktop_schedule runs an op so.\n \"local_schedule.create\": tool(\"desktop_schedule\"),\n \"local_schedule.list\": tool(\"desktop_schedule\"),\n \"local_schedule.cancel\": tool(\"desktop_schedule\"),\n \"local_schedule.prevent_sleep\": tool(\"desktop_power\"),\n\n // Matrx Local's documents are the Markdown notes in Documents/Matrx/Notes; desktop_notes reads and writes them.\n \"local_documents.list\": tool(\"desktop_notes\"),\n \"local_documents.folders\": tool(\"desktop_notes\"),\n \"local_documents.read\": tool(\"desktop_notes\"),\n \"local_documents.write\": tool(\"desktop_notes\"),\n \"local_documents.search\": tool(\"desktop_notes\"),\n\n \"local_media.ocr\": tool(\"desktop_documents\"),\n \"local_media.resize\": tool(\"desktop_documents\"),\n \"local_media.pdf_extract\": tool(\"desktop_documents\"),\n \"local_media.office_generate\": tool(\"desktop_documents\"),\n \"local_media.archive_create\": dropped(SHELL_COVERS),\n \"local_media.archive_extract\": dropped(SHELL_COVERS),\n\n \"local_ner.entities\": tool(\"desktop_entities\"),\n \"local_ner.pii\": tool(\"desktop_entities\"),\n\n \"local_mac_apps.applescript\": tool(\"desktop_automation\"),\n \"local_mac_apps.list_emails\": tool(\"desktop_mail\"),\n \"local_mac_apps.send_email\": tool(\"desktop_mail\"),\n \"local_mac_apps.email_accounts\": tool(\"desktop_mail\"),\n \"local_mac_apps.list_messages\": tool(\"desktop_messages\"),\n \"local_mac_apps.list_conversations\": tool(\"desktop_messages\"),\n \"local_mac_apps.send_message\": tool(\"desktop_messages\"),\n \"local_mac_apps.search_contacts\": tool(\"desktop_contacts\"),\n \"local_mac_apps.get_contact\": tool(\"desktop_contacts\"),\n \"local_mac_apps.list_events\": tool(\"desktop_calendar\"),\n \"local_mac_apps.create_event\": tool(\"desktop_calendar\"),\n \"local_mac_apps.list_reminders\": tool(\"desktop_calendar\"),\n \"local_mac_apps.create_reminder\": tool(\"desktop_calendar\"),\n \"local_mac_apps.search_photos\": tool(\"desktop_photos\"),\n \"local_mac_apps.get_photo\": tool(\"desktop_photos\"),\n \"local_mac_apps.location\": tool(\"desktop_location\"),\n\n \"local_windows_ps.run\": tool(\"desktop_automation\"),\n \"local_windows_ps.get_env\": dropped(\"Read with shell_execute; a per-command env rides exec.run\"),\n \"local_windows_ps.set_env\": dropped(\"Changing the person's persistent environment is not an agent tool\"),\n \"local_windows_ps.registry_read\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.registry_write\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.service_list\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.service_control\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.event_log\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.windows_features\": tool(\"desktop_windows_admin\"),\n};\n\n/**\n * matrx-local's 19 action-enum dispatchers. Each fanned an `action` out to the handlers above and\n * did nothing else; they retire with the `matrx-local` executor binding (the platform reaches a\n * device through the relay now, never by client delegation).\n */\nexport const LEGACY_DISPATCHERS: readonly string[] = [\n \"local_file\",\n \"local_shell\",\n \"local_window\",\n \"local_process\",\n \"local_input\",\n \"local_audio\",\n \"local_clipboard\",\n \"local_screen\",\n \"local_system\",\n \"local_browser\",\n \"local_web\",\n \"local_net\",\n \"local_monitor\",\n \"local_schedule\",\n \"local_documents\",\n \"local_media\",\n \"local_ner\",\n \"local_mac_apps\",\n \"local_windows_ps\",\n];\n\n/** Built tools' ops, typed: a built tool naming an op the protocol does not have fails to compile in the test. */\nexport function builtOps(): OpName[] {\n return TOOL_CATALOG.filter((t) => t.state === \"built\").flatMap((t) => t.ops as OpName[]);\n}\n","/**\n * The generated tool status table (SPEC §10): tool × level × platform, built ONLY from harness\n * results (`ToolResultsFile`) joined with the catalog. Never written by hand; the one status anyone\n * cites. `renderToolStatusMarkdown` is the committed text form; screens render `ToolStatus` itself.\n */\nimport { ToolResultsFile, type ToolLevel, type ToolLevelResult, type ToolPlatform, type ToolTransport } from \"../schema/tools\";\nimport { EXCLUDED_TOOLS, TOOL_CATALOG, TOOL_GROUPS, type CatalogTool, type ToolGroupId, type ToolState } from \"./catalog\";\n\nexport const TOOL_LEVELS: readonly ToolLevel[] = [\"programmatic\", \"protocol\", \"chat\"];\nexport const TOOL_PLATFORMS: readonly ToolPlatform[] = [\"darwin\", \"win32\", \"linux\"];\n\n/**\n * `pass`: every required proof passed and none failed. `partial`: passes so far, a required proof\n * missing (`missing` says which). `fail`: the latest run of some proof failed. `untested`: nothing\n * ran. `not_built`: the tool is planned. `unsupported`: the tool does not exist on this platform.\n */\nconst UUID_IN_NAME = /[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/gi;\n\nexport type CellState = \"pass\" | \"partial\" | \"fail\" | \"untested\" | \"not_built\" | \"unsupported\";\n\nexport interface StatusEvidence {\n readonly suite: string;\n readonly test: string;\n readonly transport: ToolTransport;\n readonly outcome: ToolLevelResult[\"outcome\"];\n readonly remote_network: boolean;\n readonly commit: string;\n readonly run_at_ms: number;\n readonly detail: string;\n /** Chat level: the tool calls the turn made, of any tool (absent on older evidence). */\n readonly calls_made?: number;\n}\n\n/**\n * A run that never exercised the tool: a `skip`, or a chat turn that made no tool calls at all (the\n * model answered in prose, or the chat request failed). It is shown as the latest run but is never\n * evidence about the tool, so it can neither prove a cell nor turn a proven one red.\n */\nexport function isInconclusive(e: Pick<StatusEvidence, \"outcome\" | \"calls_made\">): boolean {\n return e.outcome === \"skip\" || e.calls_made === 0;\n}\n\nexport interface StatusCell {\n readonly state: CellState;\n /** Required proofs not yet passed, e.g. \"relay from another network\". */\n readonly missing: readonly string[];\n readonly last_run_at_ms: number | null;\n readonly evidence: readonly StatusEvidence[];\n}\n\nexport interface StatusRow {\n readonly tool: string;\n readonly group: ToolGroupId;\n readonly tool_state: ToolState;\n readonly summary: string;\n readonly note: string | null;\n readonly cells: Readonly<Record<ToolPlatform, Readonly<Record<ToolLevel, StatusCell>>>>;\n /** Working on a platform = all three levels pass there (SPEC §10). */\n readonly working: Readonly<Record<ToolPlatform, boolean>>;\n}\n\nexport interface ToolStatus {\n readonly schema: \"matrx.tool-status.v1\";\n readonly generated_at_ms: number;\n readonly commits: readonly string[];\n readonly rows: readonly StatusRow[];\n readonly totals: Readonly<Record<ToolPlatform, { readonly working: number; readonly built: number; readonly tools: number }>>;\n}\n\n/** What each level needs before it reads `pass`. Level 2 is the transports AND the relay from another network. */\nconst REQUIRED: Readonly<Record<ToolLevel, readonly { readonly label: string; readonly ok: (e: StatusEvidence) => boolean }[]>> = {\n programmatic: [{ label: \"in process\", ok: (e) => e.transport === \"in_process\" }],\n protocol: [\n { label: \"localhost\", ok: (e) => e.transport === \"localhost\" },\n { label: \"relay\", ok: (e) => e.transport === \"relay\" },\n { label: \"relay from another network\", ok: (e) => e.transport === \"relay\" && e.remote_network },\n ],\n chat: [{ label: \"a real agent in a real chat\", ok: (e) => e.transport === \"agent\" }],\n};\n\nfunction cellFor(tool: CatalogTool, platform: ToolPlatform, level: ToolLevel, evidence: StatusEvidence[]): StatusCell {\n if (!tool.platforms.includes(platform)) return { state: \"unsupported\", missing: [], last_run_at_ms: null, evidence: [] };\n // The latest DECISIVE run of each (suite, test, transport, network) decides; older runs are\n // history. A run that never exercised the tool (`isInconclusive`) never replaces a decisive one:\n // it is kept beside it, when newer, so the table still shows that the last run proved nothing.\n const latest = new Map<string, StatusEvidence>();\n const latestInconclusive = new Map<string, StatusEvidence>();\n for (const e of evidence) {\n // A uuid in a test name (the agent a chat proof ran, a conversation) is run data, never the\n // proof's identity: the same proof under a new test agent replaces the old one's result.\n const key = `${e.suite}\\u0000${e.test.replace(UUID_IN_NAME, \"<id>\")}\\u0000${e.transport}\\u0000${e.remote_network}`;\n const into = isInconclusive(e) ? latestInconclusive : latest;\n const prev = into.get(key);\n if (!prev || prev.run_at_ms < e.run_at_ms) into.set(key, e);\n }\n const runs = [...latest.values()].sort((a, b) => b.run_at_ms - a.run_at_ms);\n const unproven = [...latestInconclusive].filter(([k, e]) => (latest.get(k)?.run_at_ms ?? -1) < e.run_at_ms).map(([, e]) => e);\n const shown = [...runs, ...unproven].sort((a, b) => b.run_at_ms - a.run_at_ms);\n const last = runs[0]?.run_at_ms ?? null;\n if (tool.state === \"planned\" && runs.length === 0) return { state: \"not_built\", missing: [], last_run_at_ms: null, evidence: [] };\n if (runs.length === 0) return { state: \"untested\", missing: REQUIRED[level].map((r) => r.label), last_run_at_ms: null, evidence: shown };\n if (runs.some((e) => e.outcome === \"fail\")) return { state: \"fail\", missing: [], last_run_at_ms: last, evidence: shown };\n const missing = REQUIRED[level].filter((r) => !runs.some((e) => e.outcome === \"pass\" && r.ok(e))).map((r) => r.label);\n return { state: missing.length === 0 ? \"pass\" : \"partial\", missing, last_run_at_ms: last, evidence: shown };\n}\n\n/** Build the table from every results file. Throws when a file is off-contract (never silently skipped). */\nexport function buildToolStatus(files: readonly unknown[], opts: { readonly generatedAtMs: number }): ToolStatus {\n const parsed = files.map((f, i) => {\n const r = ToolResultsFile.safeParse(f);\n if (!r.success) throw new Error(`tool results file #${i} is off-contract: ${r.error.issues[0]?.path.join(\".\")} ${r.error.issues[0]?.message}`);\n return r.data;\n });\n const known = new Set(TOOL_CATALOG.map((t) => t.name));\n const byKey = new Map<string, StatusEvidence[]>();\n for (const file of parsed) {\n for (const r of file.results) {\n if (!known.has(r.tool)) throw new Error(`a result names ${r.tool}, which is not in the tool catalog`);\n const key = `${r.tool}|${r.platform}|${r.level}`;\n const list = byKey.get(key) ?? [];\n list.push({\n suite: r.suite,\n test: r.test,\n transport: r.transport,\n outcome: r.outcome,\n remote_network: r.remote_network,\n commit: file.commit,\n run_at_ms: r.run_at_ms,\n detail: r.detail,\n ...(r.calls_made === undefined ? {} : { calls_made: r.calls_made }),\n });\n byKey.set(key, list);\n }\n }\n const groupOrder = new Map(TOOL_GROUPS.map((g) => [g.id, g.order]));\n const tools = [...TOOL_CATALOG].sort((a, b) => (groupOrder.get(a.group) ?? 99) - (groupOrder.get(b.group) ?? 99));\n const rows: StatusRow[] = tools.map((tool) => {\n const cells = {} as Record<ToolPlatform, Record<ToolLevel, StatusCell>>;\n const working = {} as Record<ToolPlatform, boolean>;\n for (const platform of TOOL_PLATFORMS) {\n const perLevel = {} as Record<ToolLevel, StatusCell>;\n for (const level of TOOL_LEVELS) perLevel[level] = cellFor(tool, platform, level, byKey.get(`${tool.name}|${platform}|${level}`) ?? []);\n cells[platform] = perLevel;\n working[platform] = TOOL_LEVELS.every((l) => perLevel[l].state === \"pass\");\n }\n return { tool: tool.name, group: tool.group, tool_state: tool.state, summary: tool.summary, note: tool.note ?? null, cells, working };\n });\n const totals = {} as Record<ToolPlatform, { working: number; built: number; tools: number }>;\n for (const platform of TOOL_PLATFORMS) {\n const onPlatform = TOOL_CATALOG.filter((t) => t.platforms.includes(platform));\n totals[platform] = {\n working: rows.filter((r) => r.working[platform]).length,\n built: onPlatform.filter((t) => t.state !== \"planned\").length,\n tools: onPlatform.length,\n };\n }\n const commits = [...new Set(parsed.map((f) => f.commit))].sort();\n return { schema: \"matrx.tool-status.v1\", generated_at_ms: opts.generatedAtMs, commits, rows, totals };\n}\n\nconst MARK: Readonly<Record<CellState, string>> = { pass: \"✓\", partial: \"◐\", fail: \"✗\", untested: \"·\", not_built: \"—\", unsupported: \" \" };\n\n/** The committed text form. Columns: per platform, the three levels (P = programmatic, R = protocol, C = chat). */\nexport function renderToolStatusMarkdown(status: ToolStatus): string {\n const lines: string[] = [\n \"<!-- GENERATED by `pnpm tools:status` from test results. Never edit by hand. -->\",\n \"# Local tools: status\",\n \"\",\n `Generated ${new Date(status.generated_at_ms).toISOString()} from commits ${status.commits.join(\", \") || \"none\"}.`,\n \"\",\n \"✓ pass · ◐ passing so far, a required proof missing · ✗ fail · `·` untested · — not built. Levels: P programmatic, R protocol, C chat.\",\n \"\",\n \"| Platform | Working | Built | Tools |\",\n \"|---|---|---|---|\",\n ...TOOL_PLATFORMS.map((p) => `| ${p} | ${status.totals[p].working} | ${status.totals[p].built} | ${status.totals[p].tools} |`),\n \"\",\n ];\n for (const group of TOOL_GROUPS) {\n const rows = status.rows.filter((r) => r.group === group.id);\n if (rows.length === 0) continue;\n lines.push(`## ${group.order}. ${group.title}`, \"\", \"| Tool | darwin P R C | win32 P R C | linux P R C | Missing |\", \"|---|---|---|---|---|\");\n for (const r of rows) {\n const cols = TOOL_PLATFORMS.map((p) => TOOL_LEVELS.map((l) => MARK[r.cells[p][l].state]).join(\" \"));\n const missing = new Set<string>();\n for (const p of TOOL_PLATFORMS) for (const l of TOOL_LEVELS) for (const m of r.cells[p][l].missing) if (r.cells[p][l].state !== \"untested\") missing.add(`${p} ${l}: ${m}`);\n const name = r.tool_state === \"broken\" ? `${r.tool} (broken: ${r.note ?? \"\"})` : r.tool;\n lines.push(`| ${name} | ${cols.join(\" | \")} | ${[...missing].join(\"; \")} |`);\n }\n lines.push(\"\");\n }\n const excluded = Object.entries(EXCLUDED_TOOLS);\n if (excluded.length > 0) {\n lines.push(\"## Not device tools\", \"\", \"| Tool | Why |\", \"|---|---|\", ...excluded.map(([name, why]) => `| ${name} | ${why} |`), \"\");\n }\n return lines.join(\"\\n\");\n}\n","/**\n * The per-device tool policy's op rule (Matrx 2: Agents › Tools' switches, the\n * `desktop.tools/disabled_on_device` knob). The relay carries an op, never the tool that sent it, and\n * several tools share ops (fs_read, fs_write and fs_edit all read with `fs.read`; shell_execute and\n * shell_python both run `exec.run`). So an op is refused when EVERY catalog tool that sends it is\n * turned off. Pure, data-only: the core enforces it on relay connections, the screen explains it.\n */\nimport { TOOL_CATALOG } from \"./catalog\";\n\n/** The ops refused when these tools are off: those every sending tool has turned off. */\nexport function refusedOps(disabledTools: readonly string[]): ReadonlySet<string> {\n const off = new Set(disabledTools);\n const senders = new Map<string, string[]>();\n for (const tool of TOOL_CATALOG) for (const op of tool.ops) senders.set(op, [...(senders.get(op) ?? []), tool.name]);\n const refused = new Set<string>();\n for (const [op, tools] of senders) if (tools.every((t) => off.has(t))) refused.add(op);\n return refused;\n}\n\n/** The catalog tools that send this op. */\nexport function toolsSending(op: string): string[] {\n return TOOL_CATALOG.filter((t) => t.ops.includes(op)).map((t) => t.name);\n}\n\n/**\n * For one tool switched off: the tools still on that keep ALL its ops open (turning it off alone\n * stops nothing until they are off too). Empty when turning it off stops at least one op.\n */\nexport function sharedOpsBlocking(tool: string, disabledTools: readonly string[]): string[] {\n const entry = TOOL_CATALOG.find((t) => t.name === tool);\n if (!entry || entry.ops.length === 0) return [];\n const off = new Set([...disabledTools, tool]);\n const refused = refusedOps([...off]);\n if (entry.ops.some((op) => refused.has(op))) return [];\n const keepers = new Set<string>();\n for (const op of entry.ops) for (const other of TOOL_CATALOG) if (other.name !== tool && !off.has(other.name) && other.ops.includes(op)) keepers.add(other.name);\n return [...keepers].sort();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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Q,IAAI,EAAE;AACrF,SAAO;AACT;AAGO,SAAS,aAAa,IAAsB;AACjD,SAAO,aAAa,OAAO,CAAC,MAAM,EAAE,IAAI,SAAS,EAAE,CAAC,EAAE,IAAI,CAAC,MAAM,EAAE,IAAI;AACzE;AAMO,SAAS,kBAAkBA,OAAc,eAA4C;AAC1F,QAAM,QAAQ,aAAa,KAAK,CAAC,MAAM,EAAE,SAASA,KAAI;AACtD,MAAI,CAAC,SAAS,MAAM,IAAI,WAAW,EAAG,QAAO,CAAC;AAC9C,QAAM,MAAM,oBAAI,IAAI,CAAC,GAAG,eAAeA,KAAI,CAAC;AAC5C,QAAM,UAAU,WAAW,CAAC,GAAG,GAAG,CAAC;AACnC,MAAI,MAAM,IAAI,KAAK,CAAC,OAAO,QAAQ,IAAI,EAAE,CAAC,EAAG,QAAO,CAAC;AACrD,QAAM,UAAU,oBAAI,IAAY;AAChC,aAAW,MAAM,MAAM,IAAK,YAAW,SAAS,aAAc,KAAI,MAAM,SAASA,SAAQ,CAAC,IAAI,IAAI,MAAM,IAAI,KAAK,MAAM,IAAI,SAAS,EAAE,EAAG,SAAQ,IAAI,MAAM,IAAI;AAC/J,SAAO,CAAC,GAAG,OAAO,EAAE,KAAK;AAC3B;","names":["tool","tool"]}
|
|
1
|
+
{"version":3,"sources":["../src/contract.ts","../src/tools/catalog.ts","../src/tools/status.ts","../src/tools/policy.ts"],"sourcesContent":["// AUTO-GENERATED by scripts/generate.ts — DO NOT EDIT. `pnpm generate --check` fails on any hand edit.\n/** SHA-256 of generated/desktop-protocol.schema.json: the contract both sides of a service connection were built from. */\nexport const CONTRACT_SHA256 = \"6395bc1bd368ea907614881ce0921792316b2c56872074b11cc9b9b5c6c42b1f\" as const;\n","/**\n * The local tool catalog (SPEC §10): every tool a platform agent calls on a person's computer, the\n * protocol ops it reaches, the group it ships in, and what became of each of matrx-local's 139\n * handlers (120 actions + the 19 action-enum dispatchers that fanned out to them).\n *\n * Data only. The status table (./status.ts) joins it with the harnesses' results, so a tool listed\n * here with no passing result reads \"untested\", never \"working\". Design and the reasons behind each\n * group: matrx-desktop/design/local-tools.md.\n */\nimport type { OpName } from \"../schema/registry\";\nimport type { ToolPlatform } from \"../schema/tools\";\n\nexport type ToolGroupId = \"files_shell\" | \"os_control\" | \"personal_automation\" | \"tools_service\" | \"ml_service\" | \"windows_admin\";\n\nexport interface ToolGroup {\n readonly id: ToolGroupId;\n readonly order: number;\n readonly title: string;\n /** Who implements the ops: a TS capability owner in the core, or a Python service. */\n readonly owner: \"core\" | \"python_tools\" | \"python_ml\";\n}\n\nexport const TOOL_GROUPS: readonly ToolGroup[] = [\n { id: \"files_shell\", order: 1, title: \"Files and shell\", owner: \"core\" },\n { id: \"os_control\", order: 2, title: \"Computer control\", owner: \"core\" },\n { id: \"personal_automation\", order: 3, title: \"Personal apps and automation\", owner: \"core\" },\n { id: \"tools_service\", order: 4, title: \"Web, documents, OCR and entities\", owner: \"python_tools\" },\n { id: \"ml_service\", order: 5, title: \"Speech\", owner: \"python_ml\" },\n { id: \"windows_admin\", order: 6, title: \"Windows administration\", owner: \"core\" },\n];\n\n/**\n * How an agent's call reaches the device. Both end at the relay's `POST /v1/devices/{id}/call`:\n * - `sandbox_proxy`: the cloud-sandbox-shaped tools (fs_*, shell_*). matrx-ai's `_sandbox_proxy`\n * calls aidream `/api/local-proxy/{device}/{fs|search|exec}/…`, which maps the route to its op.\n * Agent code never knows a laptop from a cloud box (SPEC §6.1).\n * - `device_op`: desktop-only capabilities. One generic route, `/api/local-proxy/{device}/op/{cap.op}`,\n * params and result exactly the op's schema; the tool definition is generated from that schema.\n * - `server`: runs on the aidream server even when the turn is bound to a device (a defect when\n * the tool reads a local path; see `note`).\n */\nexport type ToolPath = \"sandbox_proxy\" | \"device_op\" | \"server\";\n\n/** `built`: the ops exist in the protocol and Matrx 2's core serves them (registered on the platform for agents with the server tool); `planned`: designed, not built; `broken`: registered but wrong on a device. */\nexport type ToolState = \"built\" | \"planned\" | \"broken\";\n\nexport interface CatalogTool {\n /** The platform registry name (`tool.definition.name`). */\n readonly name: string;\n readonly group: ToolGroupId;\n readonly state: ToolState;\n readonly path: ToolPath;\n /** Ops the tool sends. For `built` tools every one is in OPS (a test enforces it). */\n readonly ops: readonly string[];\n readonly platforms: readonly ToolPlatform[];\n /** One line for the status table. */\n readonly summary: string;\n /** Required for `broken`: what is wrong. */\n readonly note?: string;\n}\n\nconst ALL: readonly ToolPlatform[] = [\"darwin\", \"win32\", \"linux\"];\n\nexport const TOOL_CATALOG: readonly CatalogTool[] = [\n // ── 1. Files and shell (core `fs`, `exec`; the cloud sandbox's agent tools) ──────────────────\n { name: \"fs_read\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\"], platforms: ALL, summary: \"Read a file, paged\" },\n { name: \"fs_write\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\", \"fs.write\"], platforms: ALL, summary: \"Create or overwrite a file\" },\n { name: \"fs_edit\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\", \"fs.patch\"], platforms: ALL, summary: \"Replace one exact string\" },\n { name: \"fs_patch\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.read\", \"fs.patch\"], platforms: ALL, summary: \"Apply several exact edits at once\" },\n { name: \"fs_list\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.list\"], platforms: ALL, summary: \"List a folder\" },\n { name: \"fs_mkdir\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.mkdir\"], platforms: ALL, summary: \"Create a folder\" },\n { name: \"fs_search\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"fs.search_paths\", \"fs.search_content\"], platforms: ALL, summary: \"Find files by name or content\" },\n { name: \"shell_execute\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"exec.run\"], platforms: ALL, summary: \"Run a command; cd carries over\" },\n { name: \"shell_python\", group: \"files_shell\", state: \"built\", path: \"sandbox_proxy\", ops: [\"exec.run\"], platforms: ALL, summary: \"Run a Python script\" },\n { name: \"desktop_git\", group: \"files_shell\", state: \"built\", path: \"device_op\", ops: [\"git.status\", \"git.diff\", \"git.log\", \"git.add\", \"git.commit\", \"git.push\", \"git.pull\", \"git.branch\", \"git.stash\", \"git.clone\"], platforms: ALL, summary: \"Git: status, diff, log, commit, branches, push and pull\" },\n { name: \"shell_job\", group: \"files_shell\", state: \"built\", path: \"device_op\", ops: [\"exec.job.start\", \"exec.job.output\", \"exec.job.stop\", \"exec.job.list\"], platforms: ALL, summary: \"Background commands: start, read output, stop\" },\n\n // ── 2. Computer control (TS owners) ──────────────────────────────────────────────────────────\n { name: \"desktop_process\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"proc.list\", \"proc.ports\", \"proc.kill\"], platforms: ALL, summary: \"Running processes and ports; stop one\" },\n { name: \"desktop_apps\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"apps.list\", \"apps.open\"], platforms: ALL, summary: \"Installed apps; open or bring one forward\" },\n { name: \"desktop_system\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"sysinfo.get\", \"sysinfo.hardware\", \"system.open_url\", \"system.open_path\", \"system.open_settings\", \"system.notify\"], platforms: ALL, summary: \"System facts, open, notify\" },\n { name: \"desktop_clipboard\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"clipboard.read\", \"clipboard.write\"], platforms: ALL, summary: \"Read and write the clipboard's text\" },\n { name: \"desktop_screen\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"screen.list\", \"screen.capture\"], platforms: ALL, summary: \"Displays and screenshots\" },\n { name: \"desktop_browser\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"browser.sessions\", \"browser.call\"], platforms: ALL, summary: \"The person's own browser through the AI Matrx extension: tabs, read, screenshot, navigate, click, type\" },\n { name: \"desktop_window\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"window.list\", \"window.focus\", \"window.move\", \"window.minimize\"], platforms: ALL, summary: \"Find, focus and arrange windows\" },\n { name: \"desktop_input\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"input.type_text\", \"input.hotkey\", \"input.mouse_click\", \"input.mouse_move\", \"input.keyboard_settings\", \"input.set_keyboard_settings\"], platforms: ALL, summary: \"Keyboard and mouse\" },\n { name: \"desktop_audio\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"audio.devices\", \"audio.levels\", \"audio.set_levels\", \"audio.record\", \"audio.play\"], platforms: ALL, summary: \"Audio devices, record, play\" },\n { name: \"desktop_power\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"power.status\", \"power.history\", \"power.prevent_sleep\"], platforms: ALL, summary: \"Battery and keep awake\" },\n { name: \"desktop_resources\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"resources.snapshot\", \"resources.activity\", \"resources.stop_job\", \"resources.incidents\"], platforms: ALL, summary: \"CPU, memory and disk use; what is using them, grouped into jobs; stop a job; the slowdown log\" },\n { name: \"fs_watch\", group: \"os_control\", state: \"built\", path: \"device_op\", ops: [\"fs.watch.start\", \"fs.watch.events\", \"fs.watch.stop\"], platforms: ALL, summary: \"Watch a folder; read what changed\" },\n\n // ── 3. Personal apps and automation (1.37: the core's `automation`, `personal`, `net` and `schedule` owners) ──\n { name: \"desktop_automation\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"automation.script\"], platforms: [\"darwin\", \"win32\"], summary: \"AppleScript or JavaScript for Automation on a Mac, PowerShell on Windows\" },\n { name: \"desktop_mail\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"mail.accounts\", \"mail.list\", \"mail.send\"], platforms: [\"darwin\"], summary: \"The Mail app: accounts, messages, send\" },\n { name: \"desktop_outlook\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"outlook.status\", \"outlook.draft\", \"outlook.list\", \"outlook.read\"], platforms: [\"win32\"], summary: \"The person's own Outlook: drafts with attachments, recent mail, one message\" },\n { name: \"desktop_messages\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"messages.chats\", \"messages.list\", \"messages.send\"], platforms: [\"darwin\"], summary: \"The Messages app: chats, messages, send\" },\n { name: \"desktop_contacts\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"contacts.search\", \"contacts.get\"], platforms: [\"darwin\"], summary: \"Contacts: search, one card\" },\n { name: \"desktop_calendar\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"calendar.list\", \"calendar.create\", \"reminders.list\", \"reminders.create\"], platforms: [\"darwin\"], summary: \"Calendar and Reminders: list and add\" },\n { name: \"desktop_photos\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"photos.search\", \"photos.get\"], platforms: [\"darwin\"], summary: \"The Photos library: find, export an original\" },\n // Windows comes back once a Windows location fix is proven (plan attack retire-local 2026-10-12, B6):\n // until then local_mac_apps (macOS-only) is judged on macOS and nothing claims Windows.\n { name: \"desktop_location\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"location.get\"], platforms: [\"darwin\"], summary: \"Where the computer is (the OS's location service)\" },\n { name: \"desktop_net\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"net.info\", \"net.wifi\", \"net.bluetooth\", \"net.devices\", \"net.mdns\", \"net.scan\", \"net.download\"], platforms: ALL, summary: \"Local network, Wi-Fi, Bluetooth, open ports and downloads\" },\n { name: \"desktop_schedule\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"schedule.create\", \"schedule.list\", \"schedule.cancel\"], platforms: ALL, summary: \"Run a tool's op on this computer on an interval; list and cancel\" },\n // 1.38, code from anywhere: the person's Claude Code and Codex sessions on this computer. Turning\n // either off in Agents › Tools refuses its ops on every relay connection (the existing switch).\n { name: \"coding_sessions_read\", group: \"personal_automation\", state: \"built\", path: \"device_op\", ops: [\"coding.providers\", \"coding.sessions.list\", \"coding.discover\", \"coding.runs.list\", \"coding.history\", \"coding.transcript.read\", \"coding.item.full\", \"coding.activity\", \"coding.folders.recent\", \"coding.folders.check\", \"coding.agents.access\", \"coding.titles.status\", \"coding.prefs.list\", \"coding.recent.seen\", \"coding.search\", \"coding.transcript.raw\", \"coding.watch\", \"coding.session.watch\"], platforms: ALL, summary: \"Claude Code and Codex sessions: list, read live, search, download\" },\n { 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\" },\n\n // ── 4. Documents, notes and entities (1.37: the core's `documents` and `notes` owners; desktop_web is the `tools` service) ──\n { 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\" },\n { 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 search the web from this computer's own connection\" },\n { 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\" },\n { 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\" },\n\n // ── 5. Python `ml` service ───────────────────────────────────────────────────────────────────\n // Built: models.transcribe through local_proxy's POST /op/{cap.op} (matrx-ai implementations/desktop.py).\n // Whisper detects the language itself, so matrx-local's speech_locales needs no op of its own.\n { name: \"desktop_transcribe\", group: \"ml_service\", state: \"built\", path: \"device_op\", ops: [\"models.transcribe\"], platforms: ALL, summary: \"Speech to text on the device\" },\n\n // ── 6. Windows administration ────────────────────────────────────────────────────────────────\n { name: \"desktop_windows_admin\", group: \"windows_admin\", state: \"built\", path: \"device_op\", ops: [\"windows.registry_read\", \"windows.registry_write\", \"windows.services\", \"windows.service_control\", \"windows.event_log\", \"windows.features\"], platforms: [\"win32\"], summary: \"Registry, services, event log, optional features\" },\n];\n\n/**\n * Tools armed with a device binding that are deliberately NOT device tools, each with its reason.\n * They run on the server; the status table does not track them.\n */\nexport const EXCLUDED_TOOLS: Readonly<Record<string, string>> = {\n git_ingest:\n \"Runs on the server: it ingests repository URLs. A local path on a bound computer or sandbox is refused with the fs_* and shell remedy, since the server cannot see it\",\n};\n\n/** What became of one matrx-local handler. */\nexport type LegacyDisposition =\n | { readonly kind: \"tool\"; readonly tool: string }\n | { readonly kind: \"dropped\"; readonly reason: string };\n\nconst tool = (name: string): LegacyDisposition => ({ kind: \"tool\", tool: name });\nconst dropped = (reason: string): LegacyDisposition => ({ kind: \"dropped\", reason });\n\nconst SHELL_COVERS = \"Done with shell_execute (mv, cp, rm, tar), as every coding agent does\";\nconst CLOUD_SCRAPER = \"The cloud scraper and research tools run with this computer as their network (the `proxy` capability)\";\n\n/** matrx-local's 120 actions (`app/tools/actions.py` ACTION_GROUPS), keyed `<mega tool>.<action>`. */\nexport const LEGACY_ACTIONS: Readonly<Record<string, LegacyDisposition>> = {\n \"local_file.read\": tool(\"fs_read\"),\n \"local_file.write\": tool(\"fs_write\"),\n \"local_file.edit\": tool(\"fs_edit\"),\n \"local_file.move\": dropped(SHELL_COVERS),\n \"local_file.copy\": dropped(SHELL_COVERS),\n \"local_file.delete\": dropped(SHELL_COVERS),\n \"local_file.rename\": dropped(SHELL_COVERS),\n \"local_file.mkdir\": tool(\"fs_mkdir\"),\n \"local_file.glob\": tool(\"fs_search\"),\n \"local_file.grep\": tool(\"fs_search\"),\n \"local_file.list\": tool(\"fs_list\"),\n \"local_file.places\": dropped(\"The device's home and folders reach the agent in its binding briefing (sysinfo.get)\"),\n \"local_file.find\": tool(\"fs_search\"),\n \"local_file.semantic_find\": dropped(\"Needs a local embedding index; returns with file sync's index, not before\"),\n\n \"local_shell.run\": tool(\"shell_execute\"),\n \"local_shell.output\": tool(\"shell_job\"),\n \"local_shell.stop\": tool(\"shell_job\"),\n\n \"local_window.list\": tool(\"desktop_window\"),\n \"local_window.focus\": tool(\"desktop_window\"),\n \"local_window.move\": tool(\"desktop_window\"),\n \"local_window.minimize\": tool(\"desktop_window\"),\n\n \"local_process.list\": tool(\"desktop_process\"),\n \"local_process.ports\": tool(\"desktop_process\"),\n \"local_process.launch_app\": tool(\"desktop_apps\"),\n \"local_process.kill\": tool(\"desktop_process\"),\n \"local_process.focus_app\": tool(\"desktop_apps\"),\n \"local_process.terminals\": dropped(\"Matrx 2 terminals are exec sessions; the person's own terminal windows are not the agent's\"),\n \"local_process.tail_terminal\": dropped(\"Matrx 2 terminals are exec sessions; the person's own terminal windows are not the agent's\"),\n \"local_process.installed_apps\": tool(\"desktop_apps\"),\n\n \"local_input.type_text\": tool(\"desktop_input\"),\n \"local_input.hotkey\": tool(\"desktop_input\"),\n \"local_input.mouse_click\": tool(\"desktop_input\"),\n \"local_input.mouse_move\": tool(\"desktop_input\"),\n\n \"local_audio.devices\": tool(\"desktop_audio\"),\n \"local_audio.record\": tool(\"desktop_audio\"),\n \"local_audio.play\": tool(\"desktop_audio\"),\n \"local_audio.transcribe\": tool(\"desktop_transcribe\"),\n \"local_audio.transcribe_with_speech\": tool(\"desktop_transcribe\"),\n \"local_audio.speech_locales\": tool(\"desktop_transcribe\"),\n\n \"local_clipboard.read\": tool(\"desktop_clipboard\"),\n \"local_clipboard.write\": tool(\"desktop_clipboard\"),\n\n \"local_screen.screenshot\": tool(\"desktop_screen\"),\n \"local_screen.list\": tool(\"desktop_screen\"),\n \"local_screen.capture_book\": dropped(\"A one-off loop of screenshot plus page turn; the agent composes it from desktop_screen and desktop_input\"),\n\n \"local_system.info\": tool(\"desktop_system\"),\n \"local_system.open_url\": tool(\"desktop_system\"),\n \"local_system.open_path\": tool(\"desktop_system\"),\n \"local_system.notify\": tool(\"desktop_system\"),\n\n // The person's own browser is the AI Matrx extension paired with Matrx 2 (cap browser).\n \"local_browser.navigate\": tool(\"desktop_browser\"),\n \"local_browser.click\": tool(\"desktop_browser\"),\n \"local_browser.type_text\": tool(\"desktop_browser\"),\n \"local_browser.extract\": tool(\"desktop_browser\"),\n \"local_browser.screenshot\": tool(\"desktop_browser\"),\n \"local_browser.eval\": dropped(\"The extension runs no page script for Matrx 2: its script and cdp tools are privileged and refused over the desktop path; read, click and type cover what eval was used for\"),\n \"local_browser.tabs\": tool(\"desktop_browser\"),\n \"local_browser.close\": tool(\"desktop_browser\"),\n\n \"local_web.fetch\": tool(\"desktop_web\"),\n \"local_web.fetch_with_browser\": tool(\"desktop_web\"),\n \"local_web.scrape\": tool(\"desktop_web\"),\n \"local_web.search\": tool(\"desktop_web\"),\n \"local_web.research\": dropped(CLOUD_SCRAPER),\n \"local_web.download\": tool(\"desktop_net\"),\n \"local_web.upload\": dropped(\"Uploads are cloud files (matrx-files) and file sync, one upload path\"),\n\n \"local_net.info\": tool(\"desktop_net\"),\n \"local_net.scan\": tool(\"desktop_net\"),\n \"local_net.port_scan\": tool(\"desktop_net\"),\n \"local_net.mdns_discover\": tool(\"desktop_net\"),\n \"local_net.wifi_networks\": tool(\"desktop_net\"),\n \"local_net.bluetooth_devices\": tool(\"desktop_net\"),\n \"local_net.connected_devices\": tool(\"desktop_net\"),\n\n \"local_monitor.resources\": tool(\"desktop_resources\"),\n \"local_monitor.battery\": tool(\"desktop_power\"),\n \"local_monitor.disk_usage\": tool(\"desktop_resources\"),\n \"local_monitor.top_processes\": tool(\"desktop_process\"),\n \"local_monitor.watch_directory\": tool(\"fs_watch\"),\n \"local_monitor.watch_events\": tool(\"fs_watch\"),\n \"local_monitor.stop_watch\": tool(\"fs_watch\"),\n \"local_monitor.heartbeat\": dropped(\"The relay's device status replaces the heartbeat\"),\n\n // Matrx Local's scheduler ran one of its tools on an interval; desktop_schedule runs an op so.\n \"local_schedule.create\": tool(\"desktop_schedule\"),\n \"local_schedule.list\": tool(\"desktop_schedule\"),\n \"local_schedule.cancel\": tool(\"desktop_schedule\"),\n \"local_schedule.prevent_sleep\": tool(\"desktop_power\"),\n\n // Matrx Local's documents are the Markdown notes in Documents/Matrx/Notes; desktop_notes reads and writes them.\n \"local_documents.list\": tool(\"desktop_notes\"),\n \"local_documents.folders\": tool(\"desktop_notes\"),\n \"local_documents.read\": tool(\"desktop_notes\"),\n \"local_documents.write\": tool(\"desktop_notes\"),\n \"local_documents.search\": tool(\"desktop_notes\"),\n\n \"local_media.ocr\": tool(\"desktop_documents\"),\n \"local_media.resize\": tool(\"desktop_documents\"),\n \"local_media.pdf_extract\": tool(\"desktop_documents\"),\n \"local_media.office_generate\": tool(\"desktop_documents\"),\n \"local_media.archive_create\": dropped(SHELL_COVERS),\n \"local_media.archive_extract\": dropped(SHELL_COVERS),\n\n \"local_ner.entities\": tool(\"desktop_entities\"),\n \"local_ner.pii\": tool(\"desktop_entities\"),\n\n \"local_mac_apps.applescript\": tool(\"desktop_automation\"),\n \"local_mac_apps.list_emails\": tool(\"desktop_mail\"),\n \"local_mac_apps.send_email\": tool(\"desktop_mail\"),\n \"local_mac_apps.email_accounts\": tool(\"desktop_mail\"),\n \"local_mac_apps.list_messages\": tool(\"desktop_messages\"),\n \"local_mac_apps.list_conversations\": tool(\"desktop_messages\"),\n \"local_mac_apps.send_message\": tool(\"desktop_messages\"),\n \"local_mac_apps.search_contacts\": tool(\"desktop_contacts\"),\n \"local_mac_apps.get_contact\": tool(\"desktop_contacts\"),\n \"local_mac_apps.list_events\": tool(\"desktop_calendar\"),\n \"local_mac_apps.create_event\": tool(\"desktop_calendar\"),\n \"local_mac_apps.list_reminders\": tool(\"desktop_calendar\"),\n \"local_mac_apps.create_reminder\": tool(\"desktop_calendar\"),\n \"local_mac_apps.search_photos\": tool(\"desktop_photos\"),\n \"local_mac_apps.get_photo\": tool(\"desktop_photos\"),\n \"local_mac_apps.location\": tool(\"desktop_location\"),\n\n \"local_windows_ps.run\": tool(\"desktop_automation\"),\n \"local_windows_ps.get_env\": dropped(\"Read with shell_execute; a per-command env rides exec.run\"),\n \"local_windows_ps.set_env\": dropped(\"Changing the person's persistent environment is not an agent tool\"),\n \"local_windows_ps.registry_read\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.registry_write\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.service_list\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.service_control\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.event_log\": tool(\"desktop_windows_admin\"),\n \"local_windows_ps.windows_features\": tool(\"desktop_windows_admin\"),\n};\n\n/**\n * matrx-local's 19 action-enum dispatchers. Each fanned an `action` out to the handlers above and\n * did nothing else; they retire with the `matrx-local` executor binding (the platform reaches a\n * device through the relay now, never by client delegation).\n */\nexport const LEGACY_DISPATCHERS: readonly string[] = [\n \"local_file\",\n \"local_shell\",\n \"local_window\",\n \"local_process\",\n \"local_input\",\n \"local_audio\",\n \"local_clipboard\",\n \"local_screen\",\n \"local_system\",\n \"local_browser\",\n \"local_web\",\n \"local_net\",\n \"local_monitor\",\n \"local_schedule\",\n \"local_documents\",\n \"local_media\",\n \"local_ner\",\n \"local_mac_apps\",\n \"local_windows_ps\",\n];\n\n/** Built tools' ops, typed: a built tool naming an op the protocol does not have fails to compile in the test. */\nexport function builtOps(): OpName[] {\n return TOOL_CATALOG.filter((t) => t.state === \"built\").flatMap((t) => t.ops as OpName[]);\n}\n","/**\n * The generated tool status table (SPEC §10): tool × level × platform, built ONLY from harness\n * results (`ToolResultsFile`) joined with the catalog. Never written by hand; the one status anyone\n * cites. `renderToolStatusMarkdown` is the committed text form; screens render `ToolStatus` itself.\n */\nimport { ToolResultsFile, type ToolLevel, type ToolLevelResult, type ToolPlatform, type ToolTransport } from \"../schema/tools\";\nimport { EXCLUDED_TOOLS, TOOL_CATALOG, TOOL_GROUPS, type CatalogTool, type ToolGroupId, type ToolState } from \"./catalog\";\n\nexport const TOOL_LEVELS: readonly ToolLevel[] = [\"programmatic\", \"protocol\", \"chat\"];\nexport const TOOL_PLATFORMS: readonly ToolPlatform[] = [\"darwin\", \"win32\", \"linux\"];\n\n/**\n * `pass`: every required proof passed and none failed. `partial`: passes so far, a required proof\n * missing (`missing` says which). `fail`: the latest run of some proof failed. `untested`: nothing\n * ran. `not_built`: the tool is planned. `unsupported`: the tool does not exist on this platform.\n */\nconst UUID_IN_NAME = /[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/gi;\n\nexport type CellState = \"pass\" | \"partial\" | \"fail\" | \"untested\" | \"not_built\" | \"unsupported\";\n\nexport interface StatusEvidence {\n readonly suite: string;\n readonly test: string;\n readonly transport: ToolTransport;\n readonly outcome: ToolLevelResult[\"outcome\"];\n readonly remote_network: boolean;\n readonly commit: string;\n readonly run_at_ms: number;\n readonly detail: string;\n /** Chat level: the tool calls the turn made, of any tool (absent on older evidence). */\n readonly calls_made?: number;\n}\n\n/**\n * A run that never exercised the tool: a `skip`, or a chat turn that made no tool calls at all (the\n * model answered in prose, or the chat request failed). It is shown as the latest run but is never\n * evidence about the tool, so it can neither prove a cell nor turn a proven one red.\n */\nexport function isInconclusive(e: Pick<StatusEvidence, \"outcome\" | \"calls_made\">): boolean {\n return e.outcome === \"skip\" || e.calls_made === 0;\n}\n\nexport interface StatusCell {\n readonly state: CellState;\n /** Required proofs not yet passed, e.g. \"relay from another network\". */\n readonly missing: readonly string[];\n readonly last_run_at_ms: number | null;\n readonly evidence: readonly StatusEvidence[];\n}\n\nexport interface StatusRow {\n readonly tool: string;\n readonly group: ToolGroupId;\n readonly tool_state: ToolState;\n readonly summary: string;\n readonly note: string | null;\n readonly cells: Readonly<Record<ToolPlatform, Readonly<Record<ToolLevel, StatusCell>>>>;\n /** Working on a platform = all three levels pass there (SPEC §10). */\n readonly working: Readonly<Record<ToolPlatform, boolean>>;\n}\n\nexport interface ToolStatus {\n readonly schema: \"matrx.tool-status.v1\";\n readonly generated_at_ms: number;\n readonly commits: readonly string[];\n readonly rows: readonly StatusRow[];\n readonly totals: Readonly<Record<ToolPlatform, { readonly working: number; readonly built: number; readonly tools: number }>>;\n}\n\n/** What each level needs before it reads `pass`. Level 2 is the transports AND the relay from another network. */\nconst REQUIRED: Readonly<Record<ToolLevel, readonly { readonly label: string; readonly ok: (e: StatusEvidence) => boolean }[]>> = {\n programmatic: [{ label: \"in process\", ok: (e) => e.transport === \"in_process\" }],\n protocol: [\n { label: \"localhost\", ok: (e) => e.transport === \"localhost\" },\n { label: \"relay\", ok: (e) => e.transport === \"relay\" },\n { label: \"relay from another network\", ok: (e) => e.transport === \"relay\" && e.remote_network },\n ],\n chat: [{ label: \"a real agent in a real chat\", ok: (e) => e.transport === \"agent\" }],\n};\n\nfunction cellFor(tool: CatalogTool, platform: ToolPlatform, level: ToolLevel, evidence: StatusEvidence[]): StatusCell {\n if (!tool.platforms.includes(platform)) return { state: \"unsupported\", missing: [], last_run_at_ms: null, evidence: [] };\n // The latest DECISIVE run of each (suite, test, transport, network) decides; older runs are\n // history. A run that never exercised the tool (`isInconclusive`) never replaces a decisive one:\n // it is kept beside it, when newer, so the table still shows that the last run proved nothing.\n const latest = new Map<string, StatusEvidence>();\n const latestInconclusive = new Map<string, StatusEvidence>();\n for (const e of evidence) {\n // A uuid in a test name (the agent a chat proof ran, a conversation) is run data, never the\n // proof's identity: the same proof under a new test agent replaces the old one's result.\n const key = `${e.suite}\\u0000${e.test.replace(UUID_IN_NAME, \"<id>\")}\\u0000${e.transport}\\u0000${e.remote_network}`;\n const into = isInconclusive(e) ? latestInconclusive : latest;\n const prev = into.get(key);\n if (!prev || prev.run_at_ms < e.run_at_ms) into.set(key, e);\n }\n const runs = [...latest.values()].sort((a, b) => b.run_at_ms - a.run_at_ms);\n const unproven = [...latestInconclusive].filter(([k, e]) => (latest.get(k)?.run_at_ms ?? -1) < e.run_at_ms).map(([, e]) => e);\n const shown = [...runs, ...unproven].sort((a, b) => b.run_at_ms - a.run_at_ms);\n const last = runs[0]?.run_at_ms ?? null;\n if (tool.state === \"planned\" && runs.length === 0) return { state: \"not_built\", missing: [], last_run_at_ms: null, evidence: [] };\n if (runs.length === 0) return { state: \"untested\", missing: REQUIRED[level].map((r) => r.label), last_run_at_ms: null, evidence: shown };\n if (runs.some((e) => e.outcome === \"fail\")) return { state: \"fail\", missing: [], last_run_at_ms: last, evidence: shown };\n const missing = REQUIRED[level].filter((r) => !runs.some((e) => e.outcome === \"pass\" && r.ok(e))).map((r) => r.label);\n return { state: missing.length === 0 ? \"pass\" : \"partial\", missing, last_run_at_ms: last, evidence: shown };\n}\n\n/** Build the table from every results file. Throws when a file is off-contract (never silently skipped). */\nexport function buildToolStatus(files: readonly unknown[], opts: { readonly generatedAtMs: number }): ToolStatus {\n const parsed = files.map((f, i) => {\n const r = ToolResultsFile.safeParse(f);\n if (!r.success) throw new Error(`tool results file #${i} is off-contract: ${r.error.issues[0]?.path.join(\".\")} ${r.error.issues[0]?.message}`);\n return r.data;\n });\n const known = new Set(TOOL_CATALOG.map((t) => t.name));\n const byKey = new Map<string, StatusEvidence[]>();\n for (const file of parsed) {\n for (const r of file.results) {\n if (!known.has(r.tool)) throw new Error(`a result names ${r.tool}, which is not in the tool catalog`);\n const key = `${r.tool}|${r.platform}|${r.level}`;\n const list = byKey.get(key) ?? [];\n list.push({\n suite: r.suite,\n test: r.test,\n transport: r.transport,\n outcome: r.outcome,\n remote_network: r.remote_network,\n commit: file.commit,\n run_at_ms: r.run_at_ms,\n detail: r.detail,\n ...(r.calls_made === undefined ? {} : { calls_made: r.calls_made }),\n });\n byKey.set(key, list);\n }\n }\n const groupOrder = new Map(TOOL_GROUPS.map((g) => [g.id, g.order]));\n const tools = [...TOOL_CATALOG].sort((a, b) => (groupOrder.get(a.group) ?? 99) - (groupOrder.get(b.group) ?? 99));\n const rows: StatusRow[] = tools.map((tool) => {\n const cells = {} as Record<ToolPlatform, Record<ToolLevel, StatusCell>>;\n const working = {} as Record<ToolPlatform, boolean>;\n for (const platform of TOOL_PLATFORMS) {\n const perLevel = {} as Record<ToolLevel, StatusCell>;\n for (const level of TOOL_LEVELS) perLevel[level] = cellFor(tool, platform, level, byKey.get(`${tool.name}|${platform}|${level}`) ?? []);\n cells[platform] = perLevel;\n working[platform] = TOOL_LEVELS.every((l) => perLevel[l].state === \"pass\");\n }\n return { tool: tool.name, group: tool.group, tool_state: tool.state, summary: tool.summary, note: tool.note ?? null, cells, working };\n });\n const totals = {} as Record<ToolPlatform, { working: number; built: number; tools: number }>;\n for (const platform of TOOL_PLATFORMS) {\n const onPlatform = TOOL_CATALOG.filter((t) => t.platforms.includes(platform));\n totals[platform] = {\n working: rows.filter((r) => r.working[platform]).length,\n built: onPlatform.filter((t) => t.state !== \"planned\").length,\n tools: onPlatform.length,\n };\n }\n const commits = [...new Set(parsed.map((f) => f.commit))].sort();\n return { schema: \"matrx.tool-status.v1\", generated_at_ms: opts.generatedAtMs, commits, rows, totals };\n}\n\nconst MARK: Readonly<Record<CellState, string>> = { pass: \"✓\", partial: \"◐\", fail: \"✗\", untested: \"·\", not_built: \"—\", unsupported: \" \" };\n\n/** The committed text form. Columns: per platform, the three levels (P = programmatic, R = protocol, C = chat). */\nexport function renderToolStatusMarkdown(status: ToolStatus): string {\n const lines: string[] = [\n \"<!-- GENERATED by `pnpm tools:status` from test results. Never edit by hand. -->\",\n \"# Local tools: status\",\n \"\",\n `Generated ${new Date(status.generated_at_ms).toISOString()} from commits ${status.commits.join(\", \") || \"none\"}.`,\n \"\",\n \"✓ pass · ◐ passing so far, a required proof missing · ✗ fail · `·` untested · — not built. Levels: P programmatic, R protocol, C chat.\",\n \"\",\n \"| Platform | Working | Built | Tools |\",\n \"|---|---|---|---|\",\n ...TOOL_PLATFORMS.map((p) => `| ${p} | ${status.totals[p].working} | ${status.totals[p].built} | ${status.totals[p].tools} |`),\n \"\",\n ];\n for (const group of TOOL_GROUPS) {\n const rows = status.rows.filter((r) => r.group === group.id);\n if (rows.length === 0) continue;\n lines.push(`## ${group.order}. ${group.title}`, \"\", \"| Tool | darwin P R C | win32 P R C | linux P R C | Missing |\", \"|---|---|---|---|---|\");\n for (const r of rows) {\n const cols = TOOL_PLATFORMS.map((p) => TOOL_LEVELS.map((l) => MARK[r.cells[p][l].state]).join(\" \"));\n const missing = new Set<string>();\n for (const p of TOOL_PLATFORMS) for (const l of TOOL_LEVELS) for (const m of r.cells[p][l].missing) if (r.cells[p][l].state !== \"untested\") missing.add(`${p} ${l}: ${m}`);\n const name = r.tool_state === \"broken\" ? `${r.tool} (broken: ${r.note ?? \"\"})` : r.tool;\n lines.push(`| ${name} | ${cols.join(\" | \")} | ${[...missing].join(\"; \")} |`);\n }\n lines.push(\"\");\n }\n const excluded = Object.entries(EXCLUDED_TOOLS);\n if (excluded.length > 0) {\n lines.push(\"## Not device tools\", \"\", \"| Tool | Why |\", \"|---|---|\", ...excluded.map(([name, why]) => `| ${name} | ${why} |`), \"\");\n }\n return lines.join(\"\\n\");\n}\n","/**\n * The per-device tool policy's op rule (Matrx 2: Agents › Tools' switches, the\n * `desktop.tools/disabled_on_device` knob). The relay carries an op, never the tool that sent it, and\n * several tools share ops (fs_read, fs_write and fs_edit all read with `fs.read`; shell_execute and\n * shell_python both run `exec.run`). So an op is refused when EVERY catalog tool that sends it is\n * turned off. Pure, data-only: the core enforces it on relay connections, the screen explains it.\n */\nimport { TOOL_CATALOG } from \"./catalog\";\n\n/** The ops refused when these tools are off: those every sending tool has turned off. */\nexport function refusedOps(disabledTools: readonly string[]): ReadonlySet<string> {\n const off = new Set(disabledTools);\n const senders = new Map<string, string[]>();\n for (const tool of TOOL_CATALOG) for (const op of tool.ops) senders.set(op, [...(senders.get(op) ?? []), tool.name]);\n const refused = new Set<string>();\n for (const [op, tools] of senders) if (tools.every((t) => off.has(t))) refused.add(op);\n return refused;\n}\n\n/** The catalog tools that send this op. */\nexport function toolsSending(op: string): string[] {\n return TOOL_CATALOG.filter((t) => t.ops.includes(op)).map((t) => t.name);\n}\n\n/**\n * For one tool switched off: the tools still on that keep ALL its ops open (turning it off alone\n * stops nothing until they are off too). Empty when turning it off stops at least one op.\n */\nexport function sharedOpsBlocking(tool: string, disabledTools: readonly string[]): string[] {\n const entry = TOOL_CATALOG.find((t) => t.name === tool);\n if (!entry || entry.ops.length === 0) return [];\n const off = new Set([...disabledTools, tool]);\n const refused = refusedOps([...off]);\n if (entry.ops.some((op) => refused.has(op))) return [];\n const keepers = new Set<string>();\n for (const op of entry.ops) for (const other of TOOL_CATALOG) if (other.name !== tool && !off.has(other.name) && other.ops.includes(op)) keepers.add(other.name);\n return [...keepers].sort();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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M,EAAE,IAAI,SAAS,EAAE,CAAC,EAAE,IAAI,CAAC,MAAM,EAAE,IAAI;AACzE;AAMO,SAAS,kBAAkBA,OAAc,eAA4C;AAC1F,QAAM,QAAQ,aAAa,KAAK,CAAC,MAAM,EAAE,SAASA,KAAI;AACtD,MAAI,CAAC,SAAS,MAAM,IAAI,WAAW,EAAG,QAAO,CAAC;AAC9C,QAAM,MAAM,oBAAI,IAAI,CAAC,GAAG,eAAeA,KAAI,CAAC;AAC5C,QAAM,UAAU,WAAW,CAAC,GAAG,GAAG,CAAC;AACnC,MAAI,MAAM,IAAI,KAAK,CAAC,OAAO,QAAQ,IAAI,EAAE,CAAC,EAAG,QAAO,CAAC;AACrD,QAAM,UAAU,oBAAI,IAAY;AAChC,aAAW,MAAM,MAAM,IAAK,YAAW,SAAS,aAAc,KAAI,MAAM,SAASA,SAAQ,CAAC,IAAI,IAAI,MAAM,IAAI,KAAK,MAAM,IAAI,SAAS,EAAE,EAAG,SAAQ,IAAI,MAAM,IAAI;AAC/J,SAAO,CAAC,GAAG,OAAO,EAAE,KAAK;AAC3B;","names":["tool","tool"]}
|
|
@@ -1568,6 +1568,8 @@ declare const OPS: {
|
|
|
1568
1568
|
id: z.ZodString;
|
|
1569
1569
|
size_bytes: z.ZodInt;
|
|
1570
1570
|
installed: z.ZodBoolean;
|
|
1571
|
+
title: z.ZodOptional<z.ZodString>;
|
|
1572
|
+
problem: z.ZodOptional<z.ZodString>;
|
|
1571
1573
|
}, z.core.$strict>>;
|
|
1572
1574
|
running: z.ZodNullable<z.ZodObject<{
|
|
1573
1575
|
id: z.ZodString;
|
|
@@ -8903,6 +8905,8 @@ declare const SERVICES: {
|
|
|
8903
8905
|
id: z.ZodString;
|
|
8904
8906
|
size_bytes: z.ZodInt;
|
|
8905
8907
|
installed: z.ZodBoolean;
|
|
8908
|
+
title: z.ZodOptional<z.ZodString>;
|
|
8909
|
+
problem: z.ZodOptional<z.ZodString>;
|
|
8906
8910
|
}, z.core.$strict>>;
|
|
8907
8911
|
running: z.ZodNullable<z.ZodObject<{
|
|
8908
8912
|
id: z.ZodString;
|
|
@@ -9030,6 +9034,12 @@ declare const SERVICES: {
|
|
|
9030
9034
|
}, z.core.$strict>>;
|
|
9031
9035
|
default_transcription: z.ZodNullable<z.ZodString>;
|
|
9032
9036
|
catalog_updated_at: z.ZodString;
|
|
9037
|
+
unusable: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
9038
|
+
key: z.ZodString;
|
|
9039
|
+
title: z.ZodString;
|
|
9040
|
+
size_bytes: z.ZodInt;
|
|
9041
|
+
problem: z.ZodString;
|
|
9042
|
+
}, z.core.$strict>>>;
|
|
9033
9043
|
}, z.core.$strict>;
|
|
9034
9044
|
readonly result: z.ZodObject<{
|
|
9035
9045
|
text: z.ZodInt;
|
|
@@ -11067,6 +11077,14 @@ declare const NAMED_SCHEMAS: {
|
|
|
11067
11077
|
id: z.ZodString;
|
|
11068
11078
|
size_bytes: z.ZodInt;
|
|
11069
11079
|
installed: z.ZodBoolean;
|
|
11080
|
+
title: z.ZodOptional<z.ZodString>;
|
|
11081
|
+
problem: z.ZodOptional<z.ZodString>;
|
|
11082
|
+
}, z.core.$strict>;
|
|
11083
|
+
readonly UnusableTextModel: z.ZodObject<{
|
|
11084
|
+
key: z.ZodString;
|
|
11085
|
+
title: z.ZodString;
|
|
11086
|
+
size_bytes: z.ZodInt;
|
|
11087
|
+
problem: z.ZodString;
|
|
11070
11088
|
}, z.core.$strict>;
|
|
11071
11089
|
readonly ModelKey: z.ZodString;
|
|
11072
11090
|
readonly Sha256Hex: z.ZodString;
|
|
@@ -11131,6 +11149,12 @@ declare const NAMED_SCHEMAS: {
|
|
|
11131
11149
|
}, z.core.$strict>>;
|
|
11132
11150
|
default_transcription: z.ZodNullable<z.ZodString>;
|
|
11133
11151
|
catalog_updated_at: z.ZodString;
|
|
11152
|
+
unusable: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
11153
|
+
key: z.ZodString;
|
|
11154
|
+
title: z.ZodString;
|
|
11155
|
+
size_bytes: z.ZodInt;
|
|
11156
|
+
problem: z.ZodString;
|
|
11157
|
+
}, z.core.$strict>>>;
|
|
11134
11158
|
}, z.core.$strict>;
|
|
11135
11159
|
readonly MlCatalogSetResult: z.ZodObject<{
|
|
11136
11160
|
text: z.ZodInt;
|
|
@@ -11161,6 +11185,8 @@ declare const NAMED_SCHEMAS: {
|
|
|
11161
11185
|
id: z.ZodString;
|
|
11162
11186
|
size_bytes: z.ZodInt;
|
|
11163
11187
|
installed: z.ZodBoolean;
|
|
11188
|
+
title: z.ZodOptional<z.ZodString>;
|
|
11189
|
+
problem: z.ZodOptional<z.ZodString>;
|
|
11164
11190
|
}, z.core.$strict>>;
|
|
11165
11191
|
running: z.ZodNullable<z.ZodObject<{
|
|
11166
11192
|
id: z.ZodString;
|
|
@@ -20311,6 +20337,12 @@ declare const MlCatalogSetParams: z.ZodObject<{
|
|
|
20311
20337
|
}, z.core.$strict>>;
|
|
20312
20338
|
default_transcription: z.ZodNullable<z.ZodString>;
|
|
20313
20339
|
catalog_updated_at: z.ZodString;
|
|
20340
|
+
unusable: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
20341
|
+
key: z.ZodString;
|
|
20342
|
+
title: z.ZodString;
|
|
20343
|
+
size_bytes: z.ZodInt;
|
|
20344
|
+
problem: z.ZodString;
|
|
20345
|
+
}, z.core.$strict>>>;
|
|
20314
20346
|
}, z.core.$strict>;
|
|
20315
20347
|
type MlCatalogSetParams = z.output<typeof MlCatalogSetParams>;
|
|
20316
20348
|
/**
|
|
@@ -20337,6 +20369,8 @@ declare const ModelsLlmStatusResult: z.ZodObject<{
|
|
|
20337
20369
|
id: z.ZodString;
|
|
20338
20370
|
size_bytes: z.ZodInt;
|
|
20339
20371
|
installed: z.ZodBoolean;
|
|
20372
|
+
title: z.ZodOptional<z.ZodString>;
|
|
20373
|
+
problem: z.ZodOptional<z.ZodString>;
|
|
20340
20374
|
}, z.core.$strict>>;
|
|
20341
20375
|
running: z.ZodNullable<z.ZodObject<{
|
|
20342
20376
|
id: z.ZodString;
|
|
@@ -20460,8 +20494,18 @@ declare const TextModelInfo: z.ZodObject<{
|
|
|
20460
20494
|
id: z.ZodString;
|
|
20461
20495
|
size_bytes: z.ZodInt;
|
|
20462
20496
|
installed: z.ZodBoolean;
|
|
20497
|
+
title: z.ZodOptional<z.ZodString>;
|
|
20498
|
+
problem: z.ZodOptional<z.ZodString>;
|
|
20463
20499
|
}, z.core.$strict>;
|
|
20464
20500
|
type TextModelInfo = z.output<typeof TextModelInfo>;
|
|
20501
|
+
/** (1.69) A language model on this computer that cannot run here (ml.catalog_set `unusable`): listed with why, never started. */
|
|
20502
|
+
declare const UnusableTextModel: z.ZodObject<{
|
|
20503
|
+
key: z.ZodString;
|
|
20504
|
+
title: z.ZodString;
|
|
20505
|
+
size_bytes: z.ZodInt;
|
|
20506
|
+
problem: z.ZodString;
|
|
20507
|
+
}, z.core.$strict>;
|
|
20508
|
+
type UnusableTextModel = z.output<typeof UnusableTextModel>;
|
|
20465
20509
|
/** The model server's process: one model loaded at a time. */
|
|
20466
20510
|
declare const LlmServerState: z.ZodEnum<{
|
|
20467
20511
|
running: "running";
|
|
@@ -20550,4 +20594,4 @@ type MlServiceStatus = z.output<typeof MlServiceStatus>;
|
|
|
20550
20594
|
declare const ModelsStatusParams: z.ZodObject<{}, z.core.$strict>;
|
|
20551
20595
|
type ModelsStatusParams = z.output<typeof ModelsStatusParams>;
|
|
20552
20596
|
|
|
20553
|
-
export { ModelKey as $, type ErrorReasonName as A, BEARER_PREFIX as B, type CloseOutcome as C, DesktopProtocolError as D, EndReason as E, EventMsg as F, type EventName as G, FsPatchEditFailure as H, HelloMsg as I, LlamaServerBuild as J, LlmRunning as K, Limits as L, ModelsTranscribeResult as M, LlmServerState as N, type OpName as O, MlCatalogSetParams as P, MlCatalogSetResult as Q, MlInstallPhase as R, StreamMeta as S, TranscriptionModelId as T, MlInstallProgress as U, MlRuntimeState as V, Welcome as W, MlServiceState as X, MlServiceStatus as Y, MlStatusParams as Z, MlStatusResult as _, type OpParams as a, ModelsDownloadsCancelParams as a0, ModelsDownloadsCancelResult as a1, ModelsDownloadsListParams as a2, ModelsDownloadsListResult as a3, ModelsInstallParams as a4, ModelsInstallResult as a5, ModelsLlmInstallParams as a6, ModelsLlmInstallResult as a7, ModelsLlmStartParams as a8, ModelsLlmStartResult as a9, TextModelId as aA, TextModelInfo as aB, TranscriptSegment as aC, TranscriptionModelInfo as aD,
|
|
20597
|
+
export { ModelKey as $, type ErrorReasonName as A, BEARER_PREFIX as B, type CloseOutcome as C, DesktopProtocolError as D, EndReason as E, EventMsg as F, type EventName as G, FsPatchEditFailure as H, HelloMsg as I, LlamaServerBuild as J, LlmRunning as K, Limits as L, ModelsTranscribeResult as M, LlmServerState as N, type OpName as O, MlCatalogSetParams as P, MlCatalogSetResult as Q, MlInstallPhase as R, StreamMeta as S, TranscriptionModelId as T, MlInstallProgress as U, MlRuntimeState as V, Welcome as W, MlServiceState as X, MlServiceStatus as Y, MlStatusParams as Z, MlStatusResult as _, type OpParams as a, ModelsDownloadsCancelParams as a0, ModelsDownloadsCancelResult as a1, ModelsDownloadsListParams as a2, ModelsDownloadsListResult as a3, ModelsInstallParams as a4, ModelsInstallResult as a5, ModelsLlmInstallParams as a6, ModelsLlmInstallResult as a7, ModelsLlmStartParams as a8, ModelsLlmStartResult as a9, TextModelId as aA, TextModelInfo as aB, TranscriptSegment as aC, TranscriptionModelInfo as aD, UnusableTextModel as aE, closeRule as aF, isTerminalClose as aG, ModelsLlmStatusParams as aa, ModelsLlmStatusResult as ab, ModelsLlmStopParams as ac, ModelsLlmStopResult as ad, ModelsProgressEvent as ae, ModelsStatusParams as af, ModelsStatusResult as ag, ModelsTranscribeParams as ah, NAMED_SCHEMAS as ai, type NamedSchemaId as aj, OpDescriptor as ak, type OpSpec as al, PING_TEXT as am, PONG_TEXT as an, ProtocolErrorBody as ao, RelayMsg as ap, RequestMsg as aq, ResponseMsg as ar, SERVICES as as, SUBPROTOCOL as at, type ServiceId as au, type ServiceOpName as av, type ServiceOpSpec as aw, type ServiceSpec as ax, Sha256Hex as ay, StreamMsg as az, type OpResult as b, OPS as c, EVENTS as d, ClientType as e, MlProgress as f, CLOSE_RULES as g, CancelMsg as h, isDesktopProtocolError as i, CatalogFile as j, CatalogModelEntry as k, ClientToCoreMsg as l, type CloseAction as m, CloseCode as n, CloseCodeValue as o, type CloseRule as p, CoreToClientMsg as q, CreditMsg as r, DownloadKind as s, DownloadRow as t, EndMsg as u, ErrorCode as v, type ErrorCodeName as w, type ErrorData as x, ErrorMsg as y, ErrorReason as z };
|