@camstack/addon-pipeline 1.2.604 → 1.2.605
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/dist/audio-analyzer/index.js +3 -3
- package/dist/audio-analyzer/index.mjs +3 -3
- package/dist/{custom-model-catalog-BmQ6g825.js → custom-model-catalog-CEwbRUr7.js} +2 -2
- package/dist/{custom-model-catalog-BWxCwQ1L.mjs → custom-model-catalog-G0HvRpSn.mjs} +2 -2
- package/dist/detection-pipeline/index.js +4 -4
- package/dist/detection-pipeline/index.mjs +4 -4
- package/dist/{dist-DGzDqaBO.js → dist-7LlEAfx1.js} +165 -102
- package/dist/{dist-BZ34hSbo.mjs → dist-C_81FQSz.mjs} +165 -102
- package/dist/{model-catalogs-EjFqjUfh.mjs → model-catalogs-CWnvAqRN.mjs} +1 -1
- package/dist/{model-catalogs-BZ7wE3tk.js → model-catalogs-PZwyhy-6.js} +1 -1
- package/dist/motion-wasm/index.js +1 -1
- package/dist/motion-wasm/index.mjs +1 -1
- package/dist/{node-CVbPzQN2.js → node-B8vaXwjz.js} +1 -1
- package/dist/{node-CJPdIMAm.mjs → node-Du8pLNm0.mjs} +1 -1
- package/dist/pipeline-runner/index.js +3 -3
- package/dist/pipeline-runner/index.mjs +3 -3
- package/dist/{process-memory-C8-aiceH.js → process-memory-BekNMmIb.js} +1 -1
- package/dist/{process-memory-BPqkGyDA.mjs → process-memory-BpmFzpGK.mjs} +1 -1
- package/dist/recorder/index.js +4 -4
- package/dist/recorder/index.mjs +4 -4
- package/dist/{segment-demux-js-z3asNjJ8.js → segment-demux-js-CAVgSBfN.js} +1 -1
- package/dist/{segment-demux-js-CxA4wyuM.mjs → segment-demux-js-DgTOmmSE.mjs} +1 -1
- package/dist/stream-broker/_stub.js +2 -2
- package/dist/stream-broker/{_virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-D28YdqZf.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-Bcv9Iadt.mjs} +3 -3
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-UQheneKm.mjs +26 -0
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-CSyOD5De.mjs +26 -0
- package/dist/stream-broker/demux-worker-child.js +1 -1
- package/dist/stream-broker/demux-worker-child.mjs +1 -1
- package/dist/stream-broker/{hostInit-CT3_w1iD.mjs → hostInit-BPTm2pJj.mjs} +3 -3
- package/dist/stream-broker/index.js +3 -3
- package/dist/stream-broker/index.mjs +3 -3
- package/dist/stream-broker/remoteEntry.js +1 -1
- package/package.json +1 -1
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-DdrO8p3-.mjs +0 -26
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-RrTYeVaZ.mjs +0 -26
|
@@ -3,9 +3,9 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../chunk-emK7D4bc.js");
|
|
6
|
-
const require_dist = require("../dist-
|
|
7
|
-
const require_model_catalogs = require("../model-catalogs-
|
|
8
|
-
const require_process_memory = require("../process-memory-
|
|
6
|
+
const require_dist = require("../dist-7LlEAfx1.js");
|
|
7
|
+
const require_model_catalogs = require("../model-catalogs-PZwyhy-6.js");
|
|
8
|
+
const require_process_memory = require("../process-memory-BekNMmIb.js");
|
|
9
9
|
let node_fs = require("node:fs");
|
|
10
10
|
node_fs = require_chunk.__toESM(node_fs);
|
|
11
11
|
let node_path = require("node:path");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { n as __require } from "../chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { $ as audioAnalyzerCapability, F as PoolMemoryWatchdog, Gn as hydrateSchema, Lt as mapAudioLabelToMacro, Nn as BaseAddon, Q as audioAnalysisCapability, Rn as audioChunkBytesPerSample, Un as expandAudioChunkToF32le, Zn as nodePin, cn as resolvePoolMemoryPolicy, h as DEFAULT_AUDIO_ANALYZER_CONFIG, jn as errMsg, mr as EventCategory, r as AUDIO_BACKEND_CHOICES } from "../dist-
|
|
3
|
-
import { n as AUDIO_CLASSIFIER_MODELS } from "../model-catalogs-
|
|
4
|
-
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-
|
|
2
|
+
import { $ as audioAnalyzerCapability, F as PoolMemoryWatchdog, Gn as hydrateSchema, Lt as mapAudioLabelToMacro, Nn as BaseAddon, Q as audioAnalysisCapability, Rn as audioChunkBytesPerSample, Un as expandAudioChunkToF32le, Zn as nodePin, cn as resolvePoolMemoryPolicy, h as DEFAULT_AUDIO_ANALYZER_CONFIG, jn as errMsg, mr as EventCategory, r as AUDIO_BACKEND_CHOICES } from "../dist-C_81FQSz.mjs";
|
|
3
|
+
import { n as AUDIO_CLASSIFIER_MODELS } from "../model-catalogs-CWnvAqRN.mjs";
|
|
4
|
+
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-BpmFzpGK.mjs";
|
|
5
5
|
import * as fs from "node:fs";
|
|
6
6
|
import * as path$1 from "node:path";
|
|
7
7
|
import { ensureModel } from "@camstack/system/addon-utils";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const require_dist = require("./dist-
|
|
2
|
-
const require_model_catalogs = require("./model-catalogs-
|
|
1
|
+
const require_dist = require("./dist-7LlEAfx1.js");
|
|
2
|
+
const require_model_catalogs = require("./model-catalogs-PZwyhy-6.js");
|
|
3
3
|
const require_worker_protocol = require("./worker-protocol-C-G8qmye.js");
|
|
4
4
|
let node_crypto = require("node:crypto");
|
|
5
5
|
//#region src/detection-pipeline/registry/effective-confidence.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { b as DEVICE_BACKEND_TO_FORMAT, et as audioKindId, f as COCO_80_LABELS, i as AUDIO_MACRO_LABELS, jt as inferModelProvider, k as LABEL_SUPPLY_VOCABULARIES, mn as stepModelRunsOnFormat, p as COCO_TO_MACRO } from "./dist-
|
|
2
|
-
import { a as FACE_DETECTION_MODELS, c as OBJECT_DETECTION_MODELS, d as PLATE_OCR_MODELS, f as SEGMENTATION_REFINER_MODELS, i as CLIP_EMBEDDING_MODELS, l as PACKAGE_DETECTION_MODELS, n as AUDIO_CLASSIFIER_MODELS, o as FACE_EMBEDDING_MODELS, p as VEHICLE_CLASSIFIER_MODELS, r as BIRD_CLASSIFIER_MODELS, s as INSTANCE_SEGMENTATION_MODELS, t as ANIMAL_CLASSIFIER_MODELS, u as PLATE_DETECTION_MODELS } from "./model-catalogs-
|
|
1
|
+
import { b as DEVICE_BACKEND_TO_FORMAT, et as audioKindId, f as COCO_80_LABELS, i as AUDIO_MACRO_LABELS, jt as inferModelProvider, k as LABEL_SUPPLY_VOCABULARIES, mn as stepModelRunsOnFormat, p as COCO_TO_MACRO } from "./dist-C_81FQSz.mjs";
|
|
2
|
+
import { a as FACE_DETECTION_MODELS, c as OBJECT_DETECTION_MODELS, d as PLATE_OCR_MODELS, f as SEGMENTATION_REFINER_MODELS, i as CLIP_EMBEDDING_MODELS, l as PACKAGE_DETECTION_MODELS, n as AUDIO_CLASSIFIER_MODELS, o as FACE_EMBEDDING_MODELS, p as VEHICLE_CLASSIFIER_MODELS, r as BIRD_CLASSIFIER_MODELS, s as INSTANCE_SEGMENTATION_MODELS, t as ANIMAL_CLASSIFIER_MODELS, u as PLATE_DETECTION_MODELS } from "./model-catalogs-CWnvAqRN.mjs";
|
|
3
3
|
import { t as isWorkerReply } from "./worker-protocol-D_NzPcnh.mjs";
|
|
4
4
|
import { randomUUID } from "node:crypto";
|
|
5
5
|
//#region src/detection-pipeline/registry/effective-confidence.ts
|
|
@@ -3,11 +3,11 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../chunk-emK7D4bc.js");
|
|
6
|
-
const require_dist = require("../dist-
|
|
7
|
-
const require_node = require("../node-
|
|
8
|
-
const require_custom_model_catalog = require("../custom-model-catalog-
|
|
6
|
+
const require_dist = require("../dist-7LlEAfx1.js");
|
|
7
|
+
const require_node = require("../node-B8vaXwjz.js");
|
|
8
|
+
const require_custom_model_catalog = require("../custom-model-catalog-CEwbRUr7.js");
|
|
9
9
|
const require_lazy_sharp = require("../lazy-sharp-BuwKlQLR.js");
|
|
10
|
-
const require_process_memory = require("../process-memory-
|
|
10
|
+
const require_process_memory = require("../process-memory-BekNMmIb.js");
|
|
11
11
|
let node_os = require("node:os");
|
|
12
12
|
node_os = require_chunk.__toESM(node_os);
|
|
13
13
|
let node_fs = require("node:fs");
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { n as __require } from "../chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { F as PoolMemoryWatchdog, Ft as loadContributionCapability, Gn as hydrateSchema, Gt as overlayClusterStepSettings, Nn as BaseAddon, Nt as linkedLabelStepId, O as LABEL_SUPPLY_MACRO, St as evaluateZoneRules, Ut as modelBindingKey, Wn as hfModelUrl, X as applyModelBoundSettings, Xt as pipelineExecutorCapability, Zn as nodePin, _t as detectionPipelineCapability, cn as resolvePoolMemoryPolicy, ct as containingParentIndex, d as CLUSTER_MODEL_SCOPED_STEPS, dn as rootSuppliesOf, er as sleep, fn as runtimeDevices$1, fr as string, ft as defaultDeviceFor$1, g as DEFAULT_CLUSTER_STEP_SETTINGS, jn as errMsg$1, lr as object, mn as stepModelRunsOnFormat, mr as EventCategory, n as APPLE_SA_TO_MACRO, pr as union, q as YAMNET_TO_MACRO, qt as pickClusterStepSettings, rn as resolveClusterStepModelId, rr as array, st as collectModelBoundKeys, xt as enumerateInferenceDevices, yn as supportedRuntimes$1, zn as createEvent } from "../dist-
|
|
3
|
-
import { c as readProcessCost } from "../node-
|
|
4
|
-
import { C as resolveModelDefaultConfidence, S as landmarkPrecisionVerdict, _ as ALL_STEPS, b as getStepDefinition, f as localFrameRegistry, g as ALL_PIPELINE_STEPS, l as resolveDefaultDetectionModel, n as mergeCustomModels, o as deviceKeyOf, r as buildSubtreeCanRun, s as resolveDeviceEngine, t as CustomModelCatalog, u as macroGateVerdict, v as getDefaultModelForFormat, x as resolveModelForFormat, y as getStep } from "../custom-model-catalog-
|
|
2
|
+
import { F as PoolMemoryWatchdog, Ft as loadContributionCapability, Gn as hydrateSchema, Gt as overlayClusterStepSettings, Nn as BaseAddon, Nt as linkedLabelStepId, O as LABEL_SUPPLY_MACRO, St as evaluateZoneRules, Ut as modelBindingKey, Wn as hfModelUrl, X as applyModelBoundSettings, Xt as pipelineExecutorCapability, Zn as nodePin, _t as detectionPipelineCapability, cn as resolvePoolMemoryPolicy, ct as containingParentIndex, d as CLUSTER_MODEL_SCOPED_STEPS, dn as rootSuppliesOf, er as sleep, fn as runtimeDevices$1, fr as string, ft as defaultDeviceFor$1, g as DEFAULT_CLUSTER_STEP_SETTINGS, jn as errMsg$1, lr as object, mn as stepModelRunsOnFormat, mr as EventCategory, n as APPLE_SA_TO_MACRO, pr as union, q as YAMNET_TO_MACRO, qt as pickClusterStepSettings, rn as resolveClusterStepModelId, rr as array, st as collectModelBoundKeys, xt as enumerateInferenceDevices, yn as supportedRuntimes$1, zn as createEvent } from "../dist-C_81FQSz.mjs";
|
|
3
|
+
import { c as readProcessCost } from "../node-Du8pLNm0.mjs";
|
|
4
|
+
import { C as resolveModelDefaultConfidence, S as landmarkPrecisionVerdict, _ as ALL_STEPS, b as getStepDefinition, f as localFrameRegistry, g as ALL_PIPELINE_STEPS, l as resolveDefaultDetectionModel, n as mergeCustomModels, o as deviceKeyOf, r as buildSubtreeCanRun, s as resolveDeviceEngine, t as CustomModelCatalog, u as macroGateVerdict, v as getDefaultModelForFormat, x as resolveModelForFormat, y as getStep } from "../custom-model-catalog-G0HvRpSn.mjs";
|
|
5
5
|
import { t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
6
|
-
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-
|
|
6
|
+
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-BpmFzpGK.mjs";
|
|
7
7
|
import * as os$1 from "node:os";
|
|
8
8
|
import * as fs from "node:fs";
|
|
9
9
|
import * as path$1 from "node:path";
|
|
@@ -5547,7 +5547,7 @@ var ZodIssueCode = {
|
|
|
5547
5547
|
var ZodFirstPartyTypeKind;
|
|
5548
5548
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5549
5549
|
//#endregion
|
|
5550
|
-
//#region ../types/dist/sleep-
|
|
5550
|
+
//#region ../types/dist/sleep-yKL5gfrH.mjs
|
|
5551
5551
|
/**
|
|
5552
5552
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5553
5553
|
* window to float samples (D455).
|
|
@@ -7978,9 +7978,9 @@ function normalizeAddonInitResult(result) {
|
|
|
7978
7978
|
return result;
|
|
7979
7979
|
}
|
|
7980
7980
|
/**
|
|
7981
|
-
* The share-view scope kinds a
|
|
7982
|
-
* and validates them (`
|
|
7983
|
-
* list); a data plane names the kinds it ACCEPTS in `share`.
|
|
7981
|
+
* The share-view scope kinds a share-link token can carry. The hub mints
|
|
7982
|
+
* and validates them (`ShareViewGrantSchema` builds its
|
|
7983
|
+
* enum from this list); a data plane names the kinds it ACCEPTS in `share`.
|
|
7984
7984
|
*/
|
|
7985
7985
|
var SHARE_VIEW_KINDS = ["grid-view", "events-view"];
|
|
7986
7986
|
/** The wire shape of {@link PeerBytesTicket} — see the type for what it is. */
|
|
@@ -15306,7 +15306,7 @@ var ConvertResultSchema = object({
|
|
|
15306
15306
|
* `super_admin` — collapsed onto the single boolean because every
|
|
15307
15307
|
* non-admin caller is governed by the same scope-check rules; the
|
|
15308
15308
|
* distinction was only ever used to route role-specific procedures
|
|
15309
|
-
* which we no longer have. CLI / webhook integrations are `
|
|
15309
|
+
* which we no longer have. CLI / webhook integrations are tokens (`auth.mintToken`)
|
|
15310
15310
|
* with `isAdmin: false` + an explicit scope list.
|
|
15311
15311
|
*/
|
|
15312
15312
|
/** Per-method access flavour. Materialised on every cap method via codegen. */
|
|
@@ -15495,10 +15495,12 @@ var AddonRoutesScopeSchema = object({
|
|
|
15495
15495
|
type: literal("addon-routes"),
|
|
15496
15496
|
access: array(MethodAccessSchema).min(1)
|
|
15497
15497
|
});
|
|
15498
|
+
var PreferencesSelfScopeSchema = object({ type: literal("preferences-self") });
|
|
15498
15499
|
var CredentialScopeSchema = union([
|
|
15499
15500
|
literal("*"),
|
|
15500
15501
|
ShareViewScopeSchema,
|
|
15501
15502
|
AddonRoutesScopeSchema,
|
|
15503
|
+
PreferencesSelfScopeSchema,
|
|
15502
15504
|
TokenScopeSchema
|
|
15503
15505
|
]);
|
|
15504
15506
|
object({
|
|
@@ -15507,6 +15509,55 @@ object({
|
|
|
15507
15509
|
jti: string().min(16),
|
|
15508
15510
|
scopes: array(CredentialScopeSchema).min(1)
|
|
15509
15511
|
});
|
|
15512
|
+
var PreferenceNamespaceSchema = string().regex(/^[a-z][a-z0-9.-]{0,63}$/);
|
|
15513
|
+
/** A namespace's value: a JSON object, opaque to the hub. */
|
|
15514
|
+
var PreferenceValueSchema = record(string(), unknown());
|
|
15515
|
+
var PreferenceDeviceIdSchema = string().min(1).max(64);
|
|
15516
|
+
/** A stored row, as the owner reads it. */
|
|
15517
|
+
var PreferenceRowSchema = object({
|
|
15518
|
+
namespace: PreferenceNamespaceSchema,
|
|
15519
|
+
value: PreferenceValueSchema,
|
|
15520
|
+
/** Starts at 1, +1 on every write of this namespace. A delete ends the row and its count. */
|
|
15521
|
+
revision: number().int().positive(),
|
|
15522
|
+
updatedAt: number().int(),
|
|
15523
|
+
/** The client id the last writer sent; `null` when it sent none. */
|
|
15524
|
+
updatedByDevice: PreferenceDeviceIdSchema.nullable()
|
|
15525
|
+
});
|
|
15526
|
+
object({
|
|
15527
|
+
/** Absent: every namespace the caller holds. */
|
|
15528
|
+
namespaces: array(PreferenceNamespaceSchema).max(32).optional() });
|
|
15529
|
+
object({ rows: array(PreferenceRowSchema) });
|
|
15530
|
+
object({
|
|
15531
|
+
namespace: PreferenceNamespaceSchema,
|
|
15532
|
+
value: PreferenceValueSchema,
|
|
15533
|
+
/**
|
|
15534
|
+
* The revision the edit was based on. Absent: last write wins. `0`: the
|
|
15535
|
+
* namespace must not exist yet. Any other value that is not the current
|
|
15536
|
+
* revision answers `conflict` and writes nothing.
|
|
15537
|
+
*/
|
|
15538
|
+
baseRevision: number().int().nonnegative().optional(),
|
|
15539
|
+
deviceId: PreferenceDeviceIdSchema.optional()
|
|
15540
|
+
});
|
|
15541
|
+
discriminatedUnion("status", [object({
|
|
15542
|
+
status: literal("saved"),
|
|
15543
|
+
row: PreferenceRowSchema
|
|
15544
|
+
}), object({
|
|
15545
|
+
status: literal("conflict"),
|
|
15546
|
+
current: PreferenceRowSchema.nullable()
|
|
15547
|
+
})]);
|
|
15548
|
+
object({ namespace: PreferenceNamespaceSchema });
|
|
15549
|
+
object({
|
|
15550
|
+
/** `false` when the namespace did not exist. */
|
|
15551
|
+
deleted: boolean() });
|
|
15552
|
+
object({
|
|
15553
|
+
/** The revision the client holds per namespace; a namespace it does not list is new to it. */
|
|
15554
|
+
revisionByNamespace: record(PreferenceNamespaceSchema, number().int().nonnegative()).refine((map) => Object.keys(map).length <= 32, { message: `at most 32 namespaces` }) });
|
|
15555
|
+
object({
|
|
15556
|
+
/** Every row whose revision differs from the client's, and every row it did not list. */
|
|
15557
|
+
rows: array(PreferenceRowSchema),
|
|
15558
|
+
/** Namespaces the client listed that no longer exist. */
|
|
15559
|
+
deleted: array(PreferenceNamespaceSchema)
|
|
15560
|
+
});
|
|
15510
15561
|
_enum(["new-session", "step-up"]);
|
|
15511
15562
|
/** The languages the hub's app landing pages are written in (D858). */
|
|
15512
15563
|
var AppPageLangSchema = _enum(["en", "it"]);
|
|
@@ -42924,38 +42975,37 @@ method(LlmRuntimeCompleteInputSchema, LlmGenerateResultSchema, {
|
|
|
42924
42975
|
auth: "admin",
|
|
42925
42976
|
timeoutMs: AI_CAP_TRANSPORT_TIMEOUT_MS
|
|
42926
42977
|
});
|
|
42978
|
+
var LlmProfileKindSchema = string().regex(/^[a-z0-9][a-z0-9-]{0,63}$/, "a kind id is lower-case letters, digits and dashes");
|
|
42979
|
+
/** What a model (or, by default, every model of a kind) can do. */
|
|
42980
|
+
var LlmModelFeaturesSchema = object({
|
|
42981
|
+
vision: boolean(),
|
|
42982
|
+
tools: boolean(),
|
|
42983
|
+
streaming: boolean()
|
|
42984
|
+
});
|
|
42985
|
+
/** One model a provider offers. `features` overrides the kind's defaults, per field. */
|
|
42986
|
+
var LlmModelInfoSchema = object({
|
|
42987
|
+
id: string(),
|
|
42988
|
+
label: string().optional(),
|
|
42989
|
+
contextLength: number().int().positive().optional(),
|
|
42990
|
+
features: LlmModelFeaturesSchema.partial().optional()
|
|
42991
|
+
});
|
|
42927
42992
|
/**
|
|
42928
|
-
*
|
|
42929
|
-
*
|
|
42930
|
-
*
|
|
42931
|
-
*
|
|
42932
|
-
* (hub-placed); the cap stays open for future providers.
|
|
42933
|
-
*
|
|
42934
|
-
* Profiles are ROWS (data), not addons: one row = one usable model endpoint.
|
|
42935
|
-
* `apiKey` is a password field — providers REDACT it on read and merge on
|
|
42936
|
-
* write; a stored key NEVER round-trips to a client.
|
|
42993
|
+
* The provider-specific part of a profile, validated by the provider that owns
|
|
42994
|
+
* the kind (`upsertProfile` refuses what it does not accept). A field its
|
|
42995
|
+
* `connectionSchema` declares `type: 'password'` is a secret: it is held in the
|
|
42996
|
+
* keychain, never in the row, and reads back as the redaction marker.
|
|
42937
42997
|
*/
|
|
42938
|
-
var
|
|
42939
|
-
"openai-compatible",
|
|
42940
|
-
"openai",
|
|
42941
|
-
"anthropic",
|
|
42942
|
-
"google",
|
|
42943
|
-
"managed-local",
|
|
42944
|
-
"apple-foundation"
|
|
42945
|
-
]);
|
|
42998
|
+
var LlmProviderConfigSchema = record(string(), unknown());
|
|
42946
42999
|
var LlmProfileSchema = object({
|
|
42947
43000
|
id: string(),
|
|
42948
43001
|
name: string(),
|
|
43002
|
+
/** The provider-declared kind (`LlmProfileKindDescriptor.kind`). */
|
|
42949
43003
|
kind: LlmProfileKindSchema,
|
|
42950
43004
|
/** Stamped by the provider — keeps the fanned catalog routable. */
|
|
42951
43005
|
addonId: string(),
|
|
42952
43006
|
enabled: boolean(),
|
|
42953
43007
|
/** Vendor model id, or the managed runtime's loaded model. */
|
|
42954
43008
|
model: string(),
|
|
42955
|
-
/** Required for openai-compatible; override for cloud kinds. */
|
|
42956
|
-
baseUrl: string().optional(),
|
|
42957
|
-
/** ConfigUISchema type:'password' — never round-trips (spec §5). */
|
|
42958
|
-
apiKey: string().optional(),
|
|
42959
43009
|
/** Vision on/off. A vision call against a `false` profile is REFUSED, never
|
|
42960
43010
|
* degraded to text — that shipped once and produced a confident answer to a
|
|
42961
43011
|
* question about a picture nobody sent. */
|
|
@@ -42963,15 +43013,11 @@ var LlmProfileSchema = object({
|
|
|
42963
43013
|
temperature: number().min(0).max(2).optional(),
|
|
42964
43014
|
/** Nucleus sampling. Every wire we speak has it. */
|
|
42965
43015
|
topP: number().min(0).max(1).optional(),
|
|
42966
|
-
/** Top-k sampling. Carried only by the wires that have it —
|
|
42967
|
-
*
|
|
42968
|
-
* `top_p` and no `top_k`). The profile editor hides the field wherever it
|
|
42969
|
-
* would change nothing; `KINDS_WITH_TOP_K` is the single owner of that list. */
|
|
43016
|
+
/** Top-k sampling. Carried only by the wires that have it — a kind offers the
|
|
43017
|
+
* field in its editor only when its descriptor lists it in `profileFields`. */
|
|
42970
43018
|
topK: number().int().positive().optional(),
|
|
42971
43019
|
maxTokens: number().int().positive().optional(),
|
|
42972
|
-
/** Prompt context window. Advisory for cloud kinds (they enforce their own)
|
|
42973
|
-
* for `managed-local` it is the llama.cpp `--ctx-size` the runtime starts
|
|
42974
|
-
* the model with, so it is the one field that changes a PROCESS. */
|
|
43020
|
+
/** Prompt context window. Advisory for cloud kinds (they enforce their own). */
|
|
42975
43021
|
contextLength: number().int().positive().optional(),
|
|
42976
43022
|
/** Default system prompt. A caller's `system` REPLACES it (never appends —
|
|
42977
43023
|
* two system prompts fighting is worse than either alone). */
|
|
@@ -42997,16 +43043,37 @@ var LlmProfileSchema = object({
|
|
|
42997
43043
|
* library; the REGISTRY of callable tools is ours and is empty in v1, so a
|
|
42998
43044
|
* `true` here buys the wiring, not behaviour, until tools are registered. */
|
|
42999
43045
|
toolsEnabled: boolean().default(false),
|
|
43000
|
-
|
|
43001
|
-
|
|
43002
|
-
|
|
43003
|
-
|
|
43004
|
-
|
|
43005
|
-
|
|
43006
|
-
|
|
43007
|
-
|
|
43008
|
-
|
|
43009
|
-
|
|
43046
|
+
/** Everything the kind's provider owns (endpoint, key, node, runtime…). */
|
|
43047
|
+
providerConfig: LlmProviderConfigSchema.default({})
|
|
43048
|
+
});
|
|
43049
|
+
/**
|
|
43050
|
+
* The common profile fields a kind's editor offers. The editor owns how each
|
|
43051
|
+
* one is drawn; the provider says which of them mean something on its wire.
|
|
43052
|
+
*/
|
|
43053
|
+
var LlmProfileFieldSchema = _enum([
|
|
43054
|
+
"temperature",
|
|
43055
|
+
"topP",
|
|
43056
|
+
"topK",
|
|
43057
|
+
"maxTokens",
|
|
43058
|
+
"contextLength",
|
|
43059
|
+
"systemPrompt",
|
|
43060
|
+
"timeoutMs",
|
|
43061
|
+
"connectTimeoutMs",
|
|
43062
|
+
"firstTokenTimeoutMs",
|
|
43063
|
+
"idleTimeoutMs",
|
|
43064
|
+
"retry",
|
|
43065
|
+
"toolsEnabled"
|
|
43066
|
+
]);
|
|
43067
|
+
/**
|
|
43068
|
+
* A provider-drawn part of the editor, by a generic widget id the admin UI
|
|
43069
|
+
* registers (`ai/apple-node`). `placement: 'model'` replaces the generic model
|
|
43070
|
+
* picker: that widget owns the model choice.
|
|
43071
|
+
*/
|
|
43072
|
+
var LlmProviderWidgetSchema = object({
|
|
43073
|
+
id: string(),
|
|
43074
|
+
placement: _enum(["connection", "model"]),
|
|
43075
|
+
/** `providerConfig` keys this widget must fill before the profile can be saved. */
|
|
43076
|
+
requires: array(string()).optional()
|
|
43010
43077
|
});
|
|
43011
43078
|
/** ConfigUISchema tree passed through untyped on the wire (the
|
|
43012
43079
|
* notification-output `ConfigSchemaPassthrough` precedent at
|
|
@@ -43015,11 +43082,56 @@ var ConfigSchemaPassthrough$3 = unknown();
|
|
|
43015
43082
|
var LlmProfileKindDescriptorSchema = object({
|
|
43016
43083
|
kind: LlmProfileKindSchema,
|
|
43017
43084
|
label: string(),
|
|
43085
|
+
/** A generic icon name (`cloud`, `plug`, `cpu`) — never a glyph or a logo. */
|
|
43018
43086
|
icon: string(),
|
|
43019
43087
|
/** Stamped by each provider so the concat-fanned catalog stays routable. */
|
|
43020
43088
|
addonId: string(),
|
|
43021
|
-
|
|
43089
|
+
/** The provider's own fields (`providerConfig`); `password` fields are keychain-held. */
|
|
43090
|
+
connectionSchema: ConfigSchemaPassthrough$3,
|
|
43091
|
+
/** Provider fields that belong under "Advanced" (extra headers, runtime tuning). */
|
|
43092
|
+
advancedSchema: ConfigSchemaPassthrough$3.optional(),
|
|
43093
|
+
/** The kind's defaults; a model from `listModels` may override any of them. */
|
|
43094
|
+
features: LlmModelFeaturesSchema,
|
|
43095
|
+
/** `false` = the provider stamps `supportsVision` itself (from what a node reports). */
|
|
43096
|
+
visionEditable: boolean(),
|
|
43097
|
+
/** Where the model list comes from: `listModels`, `staticModels`, or nowhere. */
|
|
43098
|
+
modelCatalog: _enum([
|
|
43099
|
+
"fetch",
|
|
43100
|
+
"static",
|
|
43101
|
+
"none"
|
|
43102
|
+
]),
|
|
43103
|
+
staticModels: array(LlmModelInfoSchema).optional(),
|
|
43104
|
+
/** The common fields that mean something on this kind's wire. */
|
|
43105
|
+
profileFields: array(LlmProfileFieldSchema),
|
|
43106
|
+
providerWidgets: array(LlmProviderWidgetSchema).optional()
|
|
43022
43107
|
});
|
|
43108
|
+
/**
|
|
43109
|
+
* `listModels` input. `connection` is an UNSAVED draft of `providerConfig`
|
|
43110
|
+
* (the editor's form); with `profileId` too, a secret the draft leaves
|
|
43111
|
+
* untouched (absent or the redaction marker) is resolved server-side from the
|
|
43112
|
+
* stored profile — the browser never receives it.
|
|
43113
|
+
*/
|
|
43114
|
+
var LlmListModelsInputSchema = object({
|
|
43115
|
+
addonId: string(),
|
|
43116
|
+
kind: LlmProfileKindSchema,
|
|
43117
|
+
profileId: string().optional(),
|
|
43118
|
+
connection: LlmProviderConfigSchema.optional()
|
|
43119
|
+
});
|
|
43120
|
+
var LlmListModelsErrorCodeSchema = _enum([
|
|
43121
|
+
"auth",
|
|
43122
|
+
"network",
|
|
43123
|
+
"unsupported",
|
|
43124
|
+
"invalid"
|
|
43125
|
+
]);
|
|
43126
|
+
/** A RESULT, never a throw: "wrong key" is an answer the editor renders inline. */
|
|
43127
|
+
var LlmListModelsResultSchema = discriminatedUnion("ok", [object({
|
|
43128
|
+
ok: literal(true),
|
|
43129
|
+
models: array(LlmModelInfoSchema)
|
|
43130
|
+
}), object({
|
|
43131
|
+
ok: literal(false),
|
|
43132
|
+
code: LlmListModelsErrorCodeSchema,
|
|
43133
|
+
message: string()
|
|
43134
|
+
})]);
|
|
43023
43135
|
var LlmDefaultSelectorSchema = union([object({ consumer: string() }), object({ purpose: _enum(["text", "vision"]) })]);
|
|
43024
43136
|
var LlmDefaultSchema = object({
|
|
43025
43137
|
selector: LlmDefaultSelectorSchema,
|
|
@@ -43119,7 +43231,10 @@ method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, {
|
|
|
43119
43231
|
kind: "mutation",
|
|
43120
43232
|
auth: "admin",
|
|
43121
43233
|
timeoutMs: AI_CAP_TRANSPORT_TIMEOUT_MS
|
|
43122
|
-
}), method(
|
|
43234
|
+
}), method(LlmListModelsInputSchema, LlmListModelsResultSchema, {
|
|
43235
|
+
kind: "mutation",
|
|
43236
|
+
auth: "admin"
|
|
43237
|
+
}), method(object({}), array(LlmDefaultSchema)), method(object({
|
|
43123
43238
|
selector: LlmDefaultSelectorSchema,
|
|
43124
43239
|
profileId: string().nullable()
|
|
43125
43240
|
}), _void(), {
|
|
@@ -65975,26 +66090,6 @@ var ApiKeySummarySchema = object({
|
|
|
65975
66090
|
createdAt: number(),
|
|
65976
66091
|
lastUsedAt: number().optional()
|
|
65977
66092
|
});
|
|
65978
|
-
var ScopedTokenSummarySchema = object({
|
|
65979
|
-
id: string(),
|
|
65980
|
-
userId: string(),
|
|
65981
|
-
name: string(),
|
|
65982
|
-
tokenPrefix: string(),
|
|
65983
|
-
scopes: array(TokenScopeSchema),
|
|
65984
|
-
expiresAt: number().nullish(),
|
|
65985
|
-
lastUsedAt: number().nullish(),
|
|
65986
|
-
createdAt: number()
|
|
65987
|
-
});
|
|
65988
|
-
var CreateScopedTokenInputSchema = object({
|
|
65989
|
-
userId: string(),
|
|
65990
|
-
name: string(),
|
|
65991
|
-
scopes: array(TokenScopeSchema),
|
|
65992
|
-
expiresAt: number().optional()
|
|
65993
|
-
});
|
|
65994
|
-
var CreateScopedTokenResultSchema = object({
|
|
65995
|
-
token: string(),
|
|
65996
|
-
record: ScopedTokenSummarySchema
|
|
65997
|
-
});
|
|
65998
66093
|
var OauthSessionSummarySchema = object({
|
|
65999
66094
|
id: string(),
|
|
66000
66095
|
userId: string(),
|
|
@@ -66016,11 +66111,11 @@ var TotpStatusSchema = object({
|
|
|
66016
66111
|
confirmedAt: number().nullable()
|
|
66017
66112
|
});
|
|
66018
66113
|
/**
|
|
66019
|
-
* user-management — singleton capability for user accounts
|
|
66020
|
-
*
|
|
66114
|
+
* user-management — singleton capability for user accounts and the
|
|
66115
|
+
* legacy API-key rows.
|
|
66021
66116
|
*
|
|
66022
66117
|
* v2 model: every method gated by `auth: 'admin'`. Admin-only delegation
|
|
66023
|
-
* — the subset check on `setUserScopes`
|
|
66118
|
+
* — the subset check on `setUserScopes` is moot
|
|
66024
66119
|
* because non-admins never reach these. If/when we open non-admin
|
|
66025
66120
|
* delegation, structural caller-scope subset check goes inside the
|
|
66026
66121
|
* provider.
|
|
@@ -66077,15 +66172,7 @@ method(_void(), array(UserSummarySchema), { auth: "admin" }), method(CreateUserI
|
|
|
66077
66172
|
kind: "mutation",
|
|
66078
66173
|
auth: "admin",
|
|
66079
66174
|
access: "delete"
|
|
66080
|
-
}), method(
|
|
66081
|
-
kind: "mutation",
|
|
66082
|
-
auth: "admin",
|
|
66083
|
-
access: "create"
|
|
66084
|
-
}), method(object({ id: string() }), object({ success: literal(true) }), {
|
|
66085
|
-
kind: "mutation",
|
|
66086
|
-
auth: "admin",
|
|
66087
|
-
access: "delete"
|
|
66088
|
-
}), method(object({ token: string() }), ScopedTokenSummarySchema.nullable(), { access: "view" }), method(object({ userId: string() }), array(ScopedTokenSummarySchema), { auth: "admin" }), method(object({ userId: string() }), TotpSetupResultSchema, {
|
|
66175
|
+
}), method(object({ userId: string() }), TotpSetupResultSchema, {
|
|
66089
66176
|
kind: "mutation",
|
|
66090
66177
|
auth: "admin",
|
|
66091
66178
|
access: "create"
|
|
@@ -70259,7 +70346,7 @@ Object.freeze({
|
|
|
70259
70346
|
capName: "llm",
|
|
70260
70347
|
capScope: "system",
|
|
70261
70348
|
addonId: null,
|
|
70262
|
-
access: "
|
|
70349
|
+
access: "create"
|
|
70263
70350
|
},
|
|
70264
70351
|
"llm.listNodeModels": {
|
|
70265
70352
|
capName: "llm",
|
|
@@ -74923,12 +75010,6 @@ Object.freeze({
|
|
|
74923
75010
|
addonId: null,
|
|
74924
75011
|
access: "create"
|
|
74925
75012
|
},
|
|
74926
|
-
"userManagement.createScopedToken": {
|
|
74927
|
-
capName: "user-management",
|
|
74928
|
-
capScope: "system",
|
|
74929
|
-
addonId: null,
|
|
74930
|
-
access: "create"
|
|
74931
|
-
},
|
|
74932
75013
|
"userManagement.createUser": {
|
|
74933
75014
|
capName: "user-management",
|
|
74934
75015
|
capScope: "system",
|
|
@@ -74977,12 +75058,6 @@ Object.freeze({
|
|
|
74977
75058
|
addonId: null,
|
|
74978
75059
|
access: "view"
|
|
74979
75060
|
},
|
|
74980
|
-
"userManagement.listScopedTokens": {
|
|
74981
|
-
capName: "user-management",
|
|
74982
|
-
capScope: "system",
|
|
74983
|
-
addonId: null,
|
|
74984
|
-
access: "view"
|
|
74985
|
-
},
|
|
74986
75061
|
"userManagement.listUsers": {
|
|
74987
75062
|
capName: "user-management",
|
|
74988
75063
|
capScope: "system",
|
|
@@ -75037,12 +75112,6 @@ Object.freeze({
|
|
|
75037
75112
|
addonId: null,
|
|
75038
75113
|
access: "delete"
|
|
75039
75114
|
},
|
|
75040
|
-
"userManagement.revokeScopedToken": {
|
|
75041
|
-
capName: "user-management",
|
|
75042
|
-
capScope: "system",
|
|
75043
|
-
addonId: null,
|
|
75044
|
-
access: "delete"
|
|
75045
|
-
},
|
|
75046
75115
|
"userManagement.setupTotp": {
|
|
75047
75116
|
capName: "user-management",
|
|
75048
75117
|
capScope: "system",
|
|
@@ -75073,12 +75142,6 @@ Object.freeze({
|
|
|
75073
75142
|
addonId: null,
|
|
75074
75143
|
access: "view"
|
|
75075
75144
|
},
|
|
75076
|
-
"userManagement.validateScopedToken": {
|
|
75077
|
-
capName: "user-management",
|
|
75078
|
-
capScope: "system",
|
|
75079
|
-
addonId: null,
|
|
75080
|
-
access: "view"
|
|
75081
|
-
},
|
|
75082
75145
|
"userManagement.verifyTotp": {
|
|
75083
75146
|
capName: "user-management",
|
|
75084
75147
|
capScope: "system",
|