@camstack/types 1.1.43 → 1.1.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/addon.js +1 -1
  2. package/dist/addon.mjs +1 -1
  3. package/dist/capabilities/advanced-notifier.cap.d.ts +4 -0
  4. package/dist/capabilities/cap-router-predicates.d.ts +60 -0
  5. package/dist/capabilities/capability-definition.d.ts +1 -1
  6. package/dist/capabilities/custom-model-registry.cap.d.ts +24 -0
  7. package/dist/capabilities/index.d.ts +14 -7
  8. package/dist/capabilities/llm-runtime.cap.d.ts +286 -0
  9. package/dist/capabilities/llm-shared.d.ts +104 -0
  10. package/dist/capabilities/llm.cap.d.ts +596 -0
  11. package/dist/capabilities/login-method.cap.d.ts +53 -7
  12. package/dist/capabilities/model-convert.cap.d.ts +13 -0
  13. package/dist/capabilities/model-distributor.cap.d.ts +26 -0
  14. package/dist/capabilities/pipeline-analytics.cap.d.ts +144 -25
  15. package/dist/capabilities/pipeline-executor.cap.d.ts +24 -0
  16. package/dist/capabilities/pipeline-orchestrator.cap.d.ts +16 -0
  17. package/dist/capabilities/plate-gallery.cap.d.ts +114 -0
  18. package/dist/capabilities/platform-probe.cap.d.ts +9 -0
  19. package/dist/capabilities/scene-monitor.cap.d.ts +483 -0
  20. package/dist/capabilities/zone-analytics.cap.d.ts +78 -1
  21. package/dist/enums/event-category.d.ts +41 -0
  22. package/dist/generated/addon-api.d.ts +3135 -933
  23. package/dist/generated/cap-status-types.d.ts +3 -1
  24. package/dist/generated/capability-router-map.d.ts +13 -4
  25. package/dist/generated/device-local-state.d.ts +3 -0
  26. package/dist/generated/device-proxy.d.ts +3 -0
  27. package/dist/generated/method-access-map.d.ts +1 -1
  28. package/dist/generated/provider-kind-map.d.ts +1 -1
  29. package/dist/generated/system-proxy.d.ts +3 -1
  30. package/dist/index.js +1307 -58
  31. package/dist/index.mjs +1272 -59
  32. package/dist/inference/runtime-capabilities.d.ts +1 -1
  33. package/dist/interfaces/addon.d.ts +5 -1
  34. package/dist/interfaces/advanced-notifier.d.ts +2 -0
  35. package/dist/interfaces/event-bus.d.ts +107 -2
  36. package/dist/interfaces/platform.d.ts +17 -0
  37. package/dist/{sleep-DmvEGsRg.js → sleep-BdhADtqT.js} +55 -0
  38. package/dist/{sleep-Baang_XW.mjs → sleep-_sv7WKkq.mjs} +55 -0
  39. package/dist/types/models.d.ts +38 -1
  40. package/dist/types/pipeline-step.d.ts +20 -2
  41. package/package.json +1 -1
@@ -0,0 +1,596 @@
1
+ /**
2
+ * `llm` — consumer-facing LLM surface (spec §1-§3). Collection-mode: array
3
+ * methods concat-fan across providers; single-row methods route to ONE
4
+ * provider by the `addonId` in the call input (the notification-output
5
+ * posture, notification-output.cap.ts:215-250). Provided by `addon-ai`
6
+ * (hub-placed); the cap stays open for future providers.
7
+ *
8
+ * Profiles are ROWS (data), not addons: one row = one usable model endpoint.
9
+ * `apiKey` is a password field — providers REDACT it on read and merge on
10
+ * write; a stored key NEVER round-trips to a client.
11
+ */
12
+ import { z } from 'zod';
13
+ import type { ConfigUISchema } from '../interfaces/config-ui.js';
14
+ import { type InferProvider } from './capability-definition.js';
15
+ export declare const LlmProfileKindSchema: z.ZodEnum<{
16
+ "openai-compatible": "openai-compatible";
17
+ openai: "openai";
18
+ anthropic: "anthropic";
19
+ google: "google";
20
+ "managed-local": "managed-local";
21
+ }>;
22
+ export type LlmProfileKind = z.infer<typeof LlmProfileKindSchema>;
23
+ export declare const LlmProfileSchema: z.ZodObject<{
24
+ id: z.ZodString;
25
+ name: z.ZodString;
26
+ kind: z.ZodEnum<{
27
+ "openai-compatible": "openai-compatible";
28
+ openai: "openai";
29
+ anthropic: "anthropic";
30
+ google: "google";
31
+ "managed-local": "managed-local";
32
+ }>;
33
+ addonId: z.ZodString;
34
+ enabled: z.ZodBoolean;
35
+ model: z.ZodString;
36
+ baseUrl: z.ZodOptional<z.ZodString>;
37
+ apiKey: z.ZodOptional<z.ZodString>;
38
+ supportsVision: z.ZodBoolean;
39
+ temperature: z.ZodOptional<z.ZodNumber>;
40
+ maxTokens: z.ZodOptional<z.ZodNumber>;
41
+ timeoutMs: z.ZodDefault<z.ZodNumber>;
42
+ extraHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
43
+ runtime: z.ZodOptional<z.ZodObject<{
44
+ nodeId: z.ZodString;
45
+ engine: z.ZodEnum<{
46
+ "llama-cpp": "llama-cpp";
47
+ }>;
48
+ model: z.ZodDiscriminatedUnion<[z.ZodObject<{
49
+ kind: z.ZodLiteral<"catalog">;
50
+ catalogId: z.ZodString;
51
+ }, z.core.$strip>, z.ZodObject<{
52
+ kind: z.ZodLiteral<"url">;
53
+ url: z.ZodString;
54
+ sha256: z.ZodOptional<z.ZodString>;
55
+ }, z.core.$strip>, z.ZodObject<{
56
+ kind: z.ZodLiteral<"path">;
57
+ path: z.ZodString;
58
+ }, z.core.$strip>], "kind">;
59
+ contextSize: z.ZodDefault<z.ZodNumber>;
60
+ gpuLayers: z.ZodDefault<z.ZodNumber>;
61
+ threads: z.ZodOptional<z.ZodNumber>;
62
+ parallel: z.ZodDefault<z.ZodNumber>;
63
+ autoStart: z.ZodDefault<z.ZodBoolean>;
64
+ idleStopMinutes: z.ZodDefault<z.ZodNumber>;
65
+ }, z.core.$strip>>;
66
+ }, z.core.$strip>;
67
+ export type LlmProfile = z.infer<typeof LlmProfileSchema>;
68
+ export declare const LlmProfileKindDescriptorSchema: z.ZodObject<{
69
+ kind: z.ZodEnum<{
70
+ "openai-compatible": "openai-compatible";
71
+ openai: "openai";
72
+ anthropic: "anthropic";
73
+ google: "google";
74
+ "managed-local": "managed-local";
75
+ }>;
76
+ label: z.ZodString;
77
+ icon: z.ZodString;
78
+ addonId: z.ZodString;
79
+ configSchema: z.ZodUnknown;
80
+ }, z.core.$strip>;
81
+ export type LlmProfileKindDescriptor = Omit<z.infer<typeof LlmProfileKindDescriptorSchema>, 'configSchema'> & {
82
+ readonly configSchema: ConfigUISchema;
83
+ };
84
+ export declare const LlmDefaultSelectorSchema: z.ZodUnion<readonly [z.ZodObject<{
85
+ consumer: z.ZodString;
86
+ }, z.core.$strip>, z.ZodObject<{
87
+ purpose: z.ZodEnum<{
88
+ text: "text";
89
+ vision: "vision";
90
+ }>;
91
+ }, z.core.$strip>]>;
92
+ export type LlmDefaultSelector = z.infer<typeof LlmDefaultSelectorSchema>;
93
+ export declare const LlmDefaultSchema: z.ZodObject<{
94
+ selector: z.ZodUnion<readonly [z.ZodObject<{
95
+ consumer: z.ZodString;
96
+ }, z.core.$strip>, z.ZodObject<{
97
+ purpose: z.ZodEnum<{
98
+ text: "text";
99
+ vision: "vision";
100
+ }>;
101
+ }, z.core.$strip>]>;
102
+ profileId: z.ZodString;
103
+ }, z.core.$strip>;
104
+ export type LlmDefault = z.infer<typeof LlmDefaultSchema>;
105
+ /** Server-side rollup row — getUsage never dumps raw call rows (spec §6). */
106
+ export declare const LlmUsageRollupSchema: z.ZodObject<{
107
+ day: z.ZodString;
108
+ consumer: z.ZodString;
109
+ profileId: z.ZodString;
110
+ calls: z.ZodNumber;
111
+ okCalls: z.ZodNumber;
112
+ errorCalls: z.ZodNumber;
113
+ inputTokens: z.ZodNumber;
114
+ outputTokens: z.ZodNumber;
115
+ avgLatencyMs: z.ZodNumber;
116
+ }, z.core.$strip>;
117
+ export type LlmUsageRollup = z.infer<typeof LlmUsageRollupSchema>;
118
+ /** LLM-facing view over the reused ModelCatalogEntry mechanism (spec §4.2). */
119
+ export declare const ManagedModelCatalogEntrySchema: z.ZodObject<{
120
+ id: z.ZodString;
121
+ label: z.ZodString;
122
+ family: z.ZodString;
123
+ purpose: z.ZodEnum<{
124
+ text: "text";
125
+ vision: "vision";
126
+ }>;
127
+ url: z.ZodString;
128
+ sha256: z.ZodString;
129
+ sizeBytes: z.ZodNumber;
130
+ quantization: z.ZodString;
131
+ minRamBytes: z.ZodNumber;
132
+ contextSizeDefault: z.ZodNumber;
133
+ mmprojUrl: z.ZodOptional<z.ZodString>;
134
+ }, z.core.$strip>;
135
+ export type ManagedModelCatalogEntry = z.infer<typeof ManagedModelCatalogEntrySchema>;
136
+ export declare const LlmRuntimeNodeSchema: z.ZodObject<{
137
+ nodeId: z.ZodString;
138
+ reachable: z.ZodBoolean;
139
+ status: z.ZodOptional<z.ZodObject<{
140
+ nodeId: z.ZodString;
141
+ state: z.ZodEnum<{
142
+ ready: "ready";
143
+ stopped: "stopped";
144
+ failed: "failed";
145
+ starting: "starting";
146
+ downloading: "downloading";
147
+ crashed: "crashed";
148
+ }>;
149
+ pid: z.ZodOptional<z.ZodNumber>;
150
+ port: z.ZodOptional<z.ZodNumber>;
151
+ modelPath: z.ZodOptional<z.ZodString>;
152
+ modelId: z.ZodOptional<z.ZodString>;
153
+ downloadProgress: z.ZodOptional<z.ZodNumber>;
154
+ lastError: z.ZodOptional<z.ZodString>;
155
+ crashesInWindow: z.ZodNumber;
156
+ memoryBytes: z.ZodOptional<z.ZodNumber>;
157
+ vramBytes: z.ZodOptional<z.ZodNumber>;
158
+ }, z.core.$strip>>;
159
+ disk: z.ZodOptional<z.ZodObject<{
160
+ nodeId: z.ZodString;
161
+ modelsBytes: z.ZodNumber;
162
+ freeBytes: z.ZodOptional<z.ZodNumber>;
163
+ }, z.core.$strip>>;
164
+ error: z.ZodOptional<z.ZodString>;
165
+ }, z.core.$strip>;
166
+ export type LlmRuntimeNode = z.infer<typeof LlmRuntimeNodeSchema>;
167
+ export declare const llmCapability: {
168
+ readonly name: "llm";
169
+ readonly scope: "system";
170
+ readonly mode: "collection";
171
+ readonly internal: false;
172
+ readonly providerKind: "ai";
173
+ /** `nodeId` inputs below are DATA (the hub provider pins itself), never routing. */
174
+ readonly nodeIdMode: "data";
175
+ readonly methods: {
176
+ readonly generate: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
177
+ addonId: z.ZodOptional<z.ZodString>;
178
+ profileId: z.ZodOptional<z.ZodString>;
179
+ consumer: z.ZodString;
180
+ system: z.ZodOptional<z.ZodString>;
181
+ prompt: z.ZodString;
182
+ jsonSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
183
+ maxTokens: z.ZodOptional<z.ZodNumber>;
184
+ temperature: z.ZodOptional<z.ZodNumber>;
185
+ }, z.core.$strip>, z.ZodDiscriminatedUnion<[z.ZodObject<{
186
+ ok: z.ZodLiteral<true>;
187
+ text: z.ZodString;
188
+ model: z.ZodString;
189
+ usage: z.ZodObject<{
190
+ inputTokens: z.ZodNumber;
191
+ outputTokens: z.ZodNumber;
192
+ }, z.core.$strip>;
193
+ truncated: z.ZodBoolean;
194
+ latencyMs: z.ZodNumber;
195
+ }, z.core.$strip>, z.ZodObject<{
196
+ ok: z.ZodLiteral<false>;
197
+ code: z.ZodEnum<{
198
+ auth: "auth";
199
+ timeout: "timeout";
200
+ "rate-limited": "rate-limited";
201
+ refusal: "refusal";
202
+ "bad-request": "bad-request";
203
+ unavailable: "unavailable";
204
+ "no-profile": "no-profile";
205
+ "budget-exceeded": "budget-exceeded";
206
+ "adapter-error": "adapter-error";
207
+ }>;
208
+ message: z.ZodString;
209
+ retryAfterMs: z.ZodOptional<z.ZodNumber>;
210
+ }, z.core.$strip>], "ok">, "mutation">;
211
+ readonly generateVision: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
212
+ addonId: z.ZodOptional<z.ZodString>;
213
+ profileId: z.ZodOptional<z.ZodString>;
214
+ consumer: z.ZodString;
215
+ system: z.ZodOptional<z.ZodString>;
216
+ prompt: z.ZodString;
217
+ jsonSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
218
+ maxTokens: z.ZodOptional<z.ZodNumber>;
219
+ temperature: z.ZodOptional<z.ZodNumber>;
220
+ images: z.ZodArray<z.ZodObject<{
221
+ bytes: z.ZodCustom<Uint8Array<ArrayBuffer>, Uint8Array<ArrayBuffer>>;
222
+ mimeType: z.ZodString;
223
+ }, z.core.$strip>>;
224
+ }, z.core.$strip>, z.ZodDiscriminatedUnion<[z.ZodObject<{
225
+ ok: z.ZodLiteral<true>;
226
+ text: z.ZodString;
227
+ model: z.ZodString;
228
+ usage: z.ZodObject<{
229
+ inputTokens: z.ZodNumber;
230
+ outputTokens: z.ZodNumber;
231
+ }, z.core.$strip>;
232
+ truncated: z.ZodBoolean;
233
+ latencyMs: z.ZodNumber;
234
+ }, z.core.$strip>, z.ZodObject<{
235
+ ok: z.ZodLiteral<false>;
236
+ code: z.ZodEnum<{
237
+ auth: "auth";
238
+ timeout: "timeout";
239
+ "rate-limited": "rate-limited";
240
+ refusal: "refusal";
241
+ "bad-request": "bad-request";
242
+ unavailable: "unavailable";
243
+ "no-profile": "no-profile";
244
+ "budget-exceeded": "budget-exceeded";
245
+ "adapter-error": "adapter-error";
246
+ }>;
247
+ message: z.ZodString;
248
+ retryAfterMs: z.ZodOptional<z.ZodNumber>;
249
+ }, z.core.$strip>], "ok">, "mutation">;
250
+ readonly listProfileKinds: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{}, z.core.$strip>, z.ZodArray<z.ZodObject<{
251
+ kind: z.ZodEnum<{
252
+ "openai-compatible": "openai-compatible";
253
+ openai: "openai";
254
+ anthropic: "anthropic";
255
+ google: "google";
256
+ "managed-local": "managed-local";
257
+ }>;
258
+ label: z.ZodString;
259
+ icon: z.ZodString;
260
+ addonId: z.ZodString;
261
+ configSchema: z.ZodUnknown;
262
+ }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
263
+ readonly listProfiles: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{}, z.core.$strip>, z.ZodArray<z.ZodObject<{
264
+ id: z.ZodString;
265
+ name: z.ZodString;
266
+ kind: z.ZodEnum<{
267
+ "openai-compatible": "openai-compatible";
268
+ openai: "openai";
269
+ anthropic: "anthropic";
270
+ google: "google";
271
+ "managed-local": "managed-local";
272
+ }>;
273
+ addonId: z.ZodString;
274
+ enabled: z.ZodBoolean;
275
+ model: z.ZodString;
276
+ baseUrl: z.ZodOptional<z.ZodString>;
277
+ apiKey: z.ZodOptional<z.ZodString>;
278
+ supportsVision: z.ZodBoolean;
279
+ temperature: z.ZodOptional<z.ZodNumber>;
280
+ maxTokens: z.ZodOptional<z.ZodNumber>;
281
+ timeoutMs: z.ZodDefault<z.ZodNumber>;
282
+ extraHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
283
+ runtime: z.ZodOptional<z.ZodObject<{
284
+ nodeId: z.ZodString;
285
+ engine: z.ZodEnum<{
286
+ "llama-cpp": "llama-cpp";
287
+ }>;
288
+ model: z.ZodDiscriminatedUnion<[z.ZodObject<{
289
+ kind: z.ZodLiteral<"catalog">;
290
+ catalogId: z.ZodString;
291
+ }, z.core.$strip>, z.ZodObject<{
292
+ kind: z.ZodLiteral<"url">;
293
+ url: z.ZodString;
294
+ sha256: z.ZodOptional<z.ZodString>;
295
+ }, z.core.$strip>, z.ZodObject<{
296
+ kind: z.ZodLiteral<"path">;
297
+ path: z.ZodString;
298
+ }, z.core.$strip>], "kind">;
299
+ contextSize: z.ZodDefault<z.ZodNumber>;
300
+ gpuLayers: z.ZodDefault<z.ZodNumber>;
301
+ threads: z.ZodOptional<z.ZodNumber>;
302
+ parallel: z.ZodDefault<z.ZodNumber>;
303
+ autoStart: z.ZodDefault<z.ZodBoolean>;
304
+ idleStopMinutes: z.ZodDefault<z.ZodNumber>;
305
+ }, z.core.$strip>>;
306
+ }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
307
+ readonly upsertProfile: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
308
+ profile: z.ZodObject<{
309
+ id: z.ZodString;
310
+ name: z.ZodString;
311
+ kind: z.ZodEnum<{
312
+ "openai-compatible": "openai-compatible";
313
+ openai: "openai";
314
+ anthropic: "anthropic";
315
+ google: "google";
316
+ "managed-local": "managed-local";
317
+ }>;
318
+ addonId: z.ZodString;
319
+ enabled: z.ZodBoolean;
320
+ model: z.ZodString;
321
+ baseUrl: z.ZodOptional<z.ZodString>;
322
+ apiKey: z.ZodOptional<z.ZodString>;
323
+ supportsVision: z.ZodBoolean;
324
+ temperature: z.ZodOptional<z.ZodNumber>;
325
+ maxTokens: z.ZodOptional<z.ZodNumber>;
326
+ timeoutMs: z.ZodDefault<z.ZodNumber>;
327
+ extraHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
328
+ runtime: z.ZodOptional<z.ZodObject<{
329
+ nodeId: z.ZodString;
330
+ engine: z.ZodEnum<{
331
+ "llama-cpp": "llama-cpp";
332
+ }>;
333
+ model: z.ZodDiscriminatedUnion<[z.ZodObject<{
334
+ kind: z.ZodLiteral<"catalog">;
335
+ catalogId: z.ZodString;
336
+ }, z.core.$strip>, z.ZodObject<{
337
+ kind: z.ZodLiteral<"url">;
338
+ url: z.ZodString;
339
+ sha256: z.ZodOptional<z.ZodString>;
340
+ }, z.core.$strip>, z.ZodObject<{
341
+ kind: z.ZodLiteral<"path">;
342
+ path: z.ZodString;
343
+ }, z.core.$strip>], "kind">;
344
+ contextSize: z.ZodDefault<z.ZodNumber>;
345
+ gpuLayers: z.ZodDefault<z.ZodNumber>;
346
+ threads: z.ZodOptional<z.ZodNumber>;
347
+ parallel: z.ZodDefault<z.ZodNumber>;
348
+ autoStart: z.ZodDefault<z.ZodBoolean>;
349
+ idleStopMinutes: z.ZodDefault<z.ZodNumber>;
350
+ }, z.core.$strip>>;
351
+ }, z.core.$strip>;
352
+ }, z.core.$strip>, z.ZodObject<{
353
+ id: z.ZodString;
354
+ name: z.ZodString;
355
+ kind: z.ZodEnum<{
356
+ "openai-compatible": "openai-compatible";
357
+ openai: "openai";
358
+ anthropic: "anthropic";
359
+ google: "google";
360
+ "managed-local": "managed-local";
361
+ }>;
362
+ addonId: z.ZodString;
363
+ enabled: z.ZodBoolean;
364
+ model: z.ZodString;
365
+ baseUrl: z.ZodOptional<z.ZodString>;
366
+ apiKey: z.ZodOptional<z.ZodString>;
367
+ supportsVision: z.ZodBoolean;
368
+ temperature: z.ZodOptional<z.ZodNumber>;
369
+ maxTokens: z.ZodOptional<z.ZodNumber>;
370
+ timeoutMs: z.ZodDefault<z.ZodNumber>;
371
+ extraHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
372
+ runtime: z.ZodOptional<z.ZodObject<{
373
+ nodeId: z.ZodString;
374
+ engine: z.ZodEnum<{
375
+ "llama-cpp": "llama-cpp";
376
+ }>;
377
+ model: z.ZodDiscriminatedUnion<[z.ZodObject<{
378
+ kind: z.ZodLiteral<"catalog">;
379
+ catalogId: z.ZodString;
380
+ }, z.core.$strip>, z.ZodObject<{
381
+ kind: z.ZodLiteral<"url">;
382
+ url: z.ZodString;
383
+ sha256: z.ZodOptional<z.ZodString>;
384
+ }, z.core.$strip>, z.ZodObject<{
385
+ kind: z.ZodLiteral<"path">;
386
+ path: z.ZodString;
387
+ }, z.core.$strip>], "kind">;
388
+ contextSize: z.ZodDefault<z.ZodNumber>;
389
+ gpuLayers: z.ZodDefault<z.ZodNumber>;
390
+ threads: z.ZodOptional<z.ZodNumber>;
391
+ parallel: z.ZodDefault<z.ZodNumber>;
392
+ autoStart: z.ZodDefault<z.ZodBoolean>;
393
+ idleStopMinutes: z.ZodDefault<z.ZodNumber>;
394
+ }, z.core.$strip>>;
395
+ }, z.core.$strip>, "mutation">;
396
+ readonly deleteProfile: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
397
+ addonId: z.ZodString;
398
+ profileId: z.ZodString;
399
+ }, z.core.$strip>, z.ZodVoid, "mutation">;
400
+ readonly testProfile: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
401
+ addonId: z.ZodString;
402
+ profileId: z.ZodString;
403
+ }, z.core.$strip>, z.ZodDiscriminatedUnion<[z.ZodObject<{
404
+ ok: z.ZodLiteral<true>;
405
+ text: z.ZodString;
406
+ model: z.ZodString;
407
+ usage: z.ZodObject<{
408
+ inputTokens: z.ZodNumber;
409
+ outputTokens: z.ZodNumber;
410
+ }, z.core.$strip>;
411
+ truncated: z.ZodBoolean;
412
+ latencyMs: z.ZodNumber;
413
+ }, z.core.$strip>, z.ZodObject<{
414
+ ok: z.ZodLiteral<false>;
415
+ code: z.ZodEnum<{
416
+ auth: "auth";
417
+ timeout: "timeout";
418
+ "rate-limited": "rate-limited";
419
+ refusal: "refusal";
420
+ "bad-request": "bad-request";
421
+ unavailable: "unavailable";
422
+ "no-profile": "no-profile";
423
+ "budget-exceeded": "budget-exceeded";
424
+ "adapter-error": "adapter-error";
425
+ }>;
426
+ message: z.ZodString;
427
+ retryAfterMs: z.ZodOptional<z.ZodNumber>;
428
+ }, z.core.$strip>], "ok">, "mutation">;
429
+ /** Live vendor enumeration (GET /models etc.). */
430
+ readonly listModels: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
431
+ addonId: z.ZodString;
432
+ profileId: z.ZodString;
433
+ }, z.core.$strip>, z.ZodArray<z.ZodString>, import("./capability-definition.js").CapabilityMethodKind>;
434
+ readonly getDefaults: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{}, z.core.$strip>, z.ZodArray<z.ZodObject<{
435
+ selector: z.ZodUnion<readonly [z.ZodObject<{
436
+ consumer: z.ZodString;
437
+ }, z.core.$strip>, z.ZodObject<{
438
+ purpose: z.ZodEnum<{
439
+ text: "text";
440
+ vision: "vision";
441
+ }>;
442
+ }, z.core.$strip>]>;
443
+ profileId: z.ZodString;
444
+ }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
445
+ readonly setDefault: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
446
+ selector: z.ZodUnion<readonly [z.ZodObject<{
447
+ consumer: z.ZodString;
448
+ }, z.core.$strip>, z.ZodObject<{
449
+ purpose: z.ZodEnum<{
450
+ text: "text";
451
+ vision: "vision";
452
+ }>;
453
+ }, z.core.$strip>]>;
454
+ profileId: z.ZodNullable<z.ZodString>;
455
+ }, z.core.$strip>, z.ZodVoid, "mutation">;
456
+ readonly getUsage: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
457
+ since: z.ZodOptional<z.ZodNumber>;
458
+ until: z.ZodOptional<z.ZodNumber>;
459
+ consumer: z.ZodOptional<z.ZodString>;
460
+ profileId: z.ZodOptional<z.ZodString>;
461
+ }, z.core.$strip>, z.ZodArray<z.ZodObject<{
462
+ day: z.ZodString;
463
+ consumer: z.ZodString;
464
+ profileId: z.ZodString;
465
+ calls: z.ZodNumber;
466
+ okCalls: z.ZodNumber;
467
+ errorCalls: z.ZodNumber;
468
+ inputTokens: z.ZodNumber;
469
+ outputTokens: z.ZodNumber;
470
+ avgLatencyMs: z.ZodNumber;
471
+ }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
472
+ readonly listModelCatalog: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{}, z.core.$strip>, z.ZodArray<z.ZodObject<{
473
+ id: z.ZodString;
474
+ label: z.ZodString;
475
+ family: z.ZodString;
476
+ purpose: z.ZodEnum<{
477
+ text: "text";
478
+ vision: "vision";
479
+ }>;
480
+ url: z.ZodString;
481
+ sha256: z.ZodString;
482
+ sizeBytes: z.ZodNumber;
483
+ quantization: z.ZodString;
484
+ minRamBytes: z.ZodNumber;
485
+ contextSizeDefault: z.ZodNumber;
486
+ mmprojUrl: z.ZodOptional<z.ZodString>;
487
+ }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
488
+ readonly listRuntimeNodes: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{}, z.core.$strip>, z.ZodArray<z.ZodObject<{
489
+ nodeId: z.ZodString;
490
+ reachable: z.ZodBoolean;
491
+ status: z.ZodOptional<z.ZodObject<{
492
+ nodeId: z.ZodString;
493
+ state: z.ZodEnum<{
494
+ ready: "ready";
495
+ stopped: "stopped";
496
+ failed: "failed";
497
+ starting: "starting";
498
+ downloading: "downloading";
499
+ crashed: "crashed";
500
+ }>;
501
+ pid: z.ZodOptional<z.ZodNumber>;
502
+ port: z.ZodOptional<z.ZodNumber>;
503
+ modelPath: z.ZodOptional<z.ZodString>;
504
+ modelId: z.ZodOptional<z.ZodString>;
505
+ downloadProgress: z.ZodOptional<z.ZodNumber>;
506
+ lastError: z.ZodOptional<z.ZodString>;
507
+ crashesInWindow: z.ZodNumber;
508
+ memoryBytes: z.ZodOptional<z.ZodNumber>;
509
+ vramBytes: z.ZodOptional<z.ZodNumber>;
510
+ }, z.core.$strip>>;
511
+ disk: z.ZodOptional<z.ZodObject<{
512
+ nodeId: z.ZodString;
513
+ modelsBytes: z.ZodNumber;
514
+ freeBytes: z.ZodOptional<z.ZodNumber>;
515
+ }, z.core.$strip>>;
516
+ error: z.ZodOptional<z.ZodString>;
517
+ }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
518
+ readonly listNodeModels: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
519
+ nodeId: z.ZodString;
520
+ }, z.core.$strip>, z.ZodArray<z.ZodObject<{
521
+ file: z.ZodString;
522
+ sizeBytes: z.ZodNumber;
523
+ catalogId: z.ZodOptional<z.ZodString>;
524
+ installedAt: z.ZodOptional<z.ZodNumber>;
525
+ }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
526
+ readonly installModel: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
527
+ nodeId: z.ZodString;
528
+ model: z.ZodDiscriminatedUnion<[z.ZodObject<{
529
+ kind: z.ZodLiteral<"catalog">;
530
+ catalogId: z.ZodString;
531
+ }, z.core.$strip>, z.ZodObject<{
532
+ kind: z.ZodLiteral<"url">;
533
+ url: z.ZodString;
534
+ sha256: z.ZodOptional<z.ZodString>;
535
+ }, z.core.$strip>, z.ZodObject<{
536
+ kind: z.ZodLiteral<"path">;
537
+ path: z.ZodString;
538
+ }, z.core.$strip>], "kind">;
539
+ }, z.core.$strip>, z.ZodVoid, "mutation">;
540
+ readonly deleteModel: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
541
+ nodeId: z.ZodString;
542
+ file: z.ZodString;
543
+ }, z.core.$strip>, z.ZodVoid, "mutation">;
544
+ readonly getRuntimeStatus: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
545
+ addonId: z.ZodString;
546
+ profileId: z.ZodString;
547
+ }, z.core.$strip>, z.ZodObject<{
548
+ nodeId: z.ZodString;
549
+ state: z.ZodEnum<{
550
+ ready: "ready";
551
+ stopped: "stopped";
552
+ failed: "failed";
553
+ starting: "starting";
554
+ downloading: "downloading";
555
+ crashed: "crashed";
556
+ }>;
557
+ pid: z.ZodOptional<z.ZodNumber>;
558
+ port: z.ZodOptional<z.ZodNumber>;
559
+ modelPath: z.ZodOptional<z.ZodString>;
560
+ modelId: z.ZodOptional<z.ZodString>;
561
+ downloadProgress: z.ZodOptional<z.ZodNumber>;
562
+ lastError: z.ZodOptional<z.ZodString>;
563
+ crashesInWindow: z.ZodNumber;
564
+ memoryBytes: z.ZodOptional<z.ZodNumber>;
565
+ vramBytes: z.ZodOptional<z.ZodNumber>;
566
+ }, z.core.$strip>, import("./capability-definition.js").CapabilityMethodKind>;
567
+ readonly startRuntime: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
568
+ addonId: z.ZodString;
569
+ profileId: z.ZodString;
570
+ }, z.core.$strip>, z.ZodObject<{
571
+ nodeId: z.ZodString;
572
+ state: z.ZodEnum<{
573
+ ready: "ready";
574
+ stopped: "stopped";
575
+ failed: "failed";
576
+ starting: "starting";
577
+ downloading: "downloading";
578
+ crashed: "crashed";
579
+ }>;
580
+ pid: z.ZodOptional<z.ZodNumber>;
581
+ port: z.ZodOptional<z.ZodNumber>;
582
+ modelPath: z.ZodOptional<z.ZodString>;
583
+ modelId: z.ZodOptional<z.ZodString>;
584
+ downloadProgress: z.ZodOptional<z.ZodNumber>;
585
+ lastError: z.ZodOptional<z.ZodString>;
586
+ crashesInWindow: z.ZodNumber;
587
+ memoryBytes: z.ZodOptional<z.ZodNumber>;
588
+ vramBytes: z.ZodOptional<z.ZodNumber>;
589
+ }, z.core.$strip>, "mutation">;
590
+ readonly stopRuntime: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
591
+ addonId: z.ZodString;
592
+ profileId: z.ZodString;
593
+ }, z.core.$strip>, z.ZodVoid, "mutation">;
594
+ };
595
+ };
596
+ export type ILlmProvider = InferProvider<typeof llmCapability>;