camstack 1.2.137 → 1.2.139
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.
|
@@ -14522,7 +14522,35 @@ function date4(params) {
|
|
|
14522
14522
|
// ../../node_modules/zod/v4/classic/external.js
|
|
14523
14523
|
config(en_default());
|
|
14524
14524
|
|
|
14525
|
-
// ../types/dist/sleep-
|
|
14525
|
+
// ../types/dist/sleep-BnujYGPe.mjs
|
|
14526
|
+
var AUDIO_CHUNK_FORMATS = [
|
|
14527
|
+
"f32le",
|
|
14528
|
+
"pcmu",
|
|
14529
|
+
"pcma"
|
|
14530
|
+
];
|
|
14531
|
+
function buildUlawTable() {
|
|
14532
|
+
const table2 = new Float32Array(256);
|
|
14533
|
+
for (let i = 0; i < 256; i++) {
|
|
14534
|
+
const complemented = ~i & 255;
|
|
14535
|
+
const sign = (complemented & 128) !== 0 ? -1 : 1;
|
|
14536
|
+
const exponent = complemented >> 4 & 7;
|
|
14537
|
+
table2[i] = sign * ((8 * (complemented & 15) + 132 << exponent) - 132) / 32768;
|
|
14538
|
+
}
|
|
14539
|
+
return table2;
|
|
14540
|
+
}
|
|
14541
|
+
function buildAlawTable() {
|
|
14542
|
+
const table2 = new Float32Array(256);
|
|
14543
|
+
for (let i = 0; i < 256; i++) {
|
|
14544
|
+
const xored = i ^ 85;
|
|
14545
|
+
const sign = (xored & 128) !== 0 ? 1 : -1;
|
|
14546
|
+
const exponent = xored >> 4 & 7;
|
|
14547
|
+
const mantissa = xored & 15;
|
|
14548
|
+
table2[i] = sign * (exponent === 0 ? 16 * mantissa + 8 : 16 * mantissa + 264 << exponent - 1) / 32768;
|
|
14549
|
+
}
|
|
14550
|
+
return table2;
|
|
14551
|
+
}
|
|
14552
|
+
var ULAW_TABLE = buildUlawTable();
|
|
14553
|
+
var ALAW_TABLE = buildAlawTable();
|
|
14526
14554
|
var WELL_KNOWN_TABS = [
|
|
14527
14555
|
{
|
|
14528
14556
|
id: "overview",
|
|
@@ -14877,16 +14905,36 @@ var SubscribeFramesResultSchema = external_exports.object({
|
|
|
14877
14905
|
/** Reader-side cadence hint (frames/s) — echoes `SubscribeFramesInput.maxFps`. */
|
|
14878
14906
|
maxFps: external_exports.number().nonnegative()
|
|
14879
14907
|
});
|
|
14908
|
+
var AudioChunkFormatSchema = external_exports.enum(AUDIO_CHUNK_FORMATS);
|
|
14880
14909
|
var DecodedAudioChunkSchema = external_exports.object({
|
|
14881
14910
|
data: external_exports.instanceof(Uint8Array),
|
|
14882
14911
|
sampleRate: external_exports.number().int().positive(),
|
|
14883
14912
|
channels: external_exports.number().int().positive(),
|
|
14884
|
-
timestamp: external_exports.number()
|
|
14913
|
+
timestamp: external_exports.number(),
|
|
14914
|
+
/**
|
|
14915
|
+
* Byte format of `data`. ABSENT MEANS `f32le` — today's bytes, byte for
|
|
14916
|
+
* byte, for any peer that never heard of this field. A coded window
|
|
14917
|
+
* (`pcmu` / `pcma`, one byte per sample) is only ever emitted to a
|
|
14918
|
+
* subscription that DECLARED it accepts one, so absence can never mean
|
|
14919
|
+
* "coded bytes a consumer will read as floats" (D455).
|
|
14920
|
+
*/
|
|
14921
|
+
format: AudioChunkFormatSchema.optional()
|
|
14885
14922
|
});
|
|
14886
14923
|
var SubscribeAudioChunksInputSchema = external_exports.object({
|
|
14887
14924
|
brokerId: external_exports.string(),
|
|
14888
14925
|
/** Short caller-identity tag (`audio-analyzer`, …) for `listClients`. */
|
|
14889
|
-
tag: external_exports.string().optional()
|
|
14926
|
+
tag: external_exports.string().optional(),
|
|
14927
|
+
/**
|
|
14928
|
+
* Byte formats this subscriber can READ, best first. The broker serves the
|
|
14929
|
+
* chunk's own format when it is in this list and expands to `f32le`
|
|
14930
|
+
* otherwise, so a subscriber is never handed bytes it cannot interpret.
|
|
14931
|
+
*
|
|
14932
|
+
* Absent (or without the source format) means `f32le` — the behaviour every
|
|
14933
|
+
* subscriber had before D455, unchanged. This is the negotiation half of
|
|
14934
|
+
* the source-bytes lever: it is what lets the broker and its consumers
|
|
14935
|
+
* deploy one at a time across three nodes.
|
|
14936
|
+
*/
|
|
14937
|
+
accept: external_exports.array(AudioChunkFormatSchema).readonly().optional()
|
|
14890
14938
|
});
|
|
14891
14939
|
var SubscribeAudioChunksResultSchema = external_exports.object({
|
|
14892
14940
|
/** Opaque id passed to `pullAudioChunks` / `unsubscribeAudioChunks`. */
|
|
@@ -17896,6 +17944,37 @@ var AudioAnalysisSettingsSchema = external_exports.object({
|
|
|
17896
17944
|
minConfidence: external_exports.number().min(0).max(1).default(0.3),
|
|
17897
17945
|
allowedClasses: external_exports.array(external_exports.string()).default([])
|
|
17898
17946
|
});
|
|
17947
|
+
var AudioAttachDeviceInputSchema = external_exports.object({
|
|
17948
|
+
deviceId: external_exports.number(),
|
|
17949
|
+
/** Broker id (`<deviceId>/<camStreamId>`) carrying this camera's audio. */
|
|
17950
|
+
brokerId: external_exports.string(),
|
|
17951
|
+
/**
|
|
17952
|
+
* `clusterRoles.ingestNode` — the node whose broker owns the source dial.
|
|
17953
|
+
* Every `streamBroker` call the attachment makes is pinned to it, exactly as
|
|
17954
|
+
* the orchestrator's poller pinned them before the move.
|
|
17955
|
+
*/
|
|
17956
|
+
ingestNodeId: external_exports.string(),
|
|
17957
|
+
/**
|
|
17958
|
+
* Resolved once by the orchestrator at attach time, exactly as it was read
|
|
17959
|
+
* once per subscription before D461. The analyzer does NOT re-resolve per
|
|
17960
|
+
* window: a settings change re-attaches, which is what always happened.
|
|
17961
|
+
*/
|
|
17962
|
+
settings: AudioAnalysisSettingsSchema
|
|
17963
|
+
});
|
|
17964
|
+
var AudioAttachDeviceResultSchema = external_exports.object({
|
|
17965
|
+
/** False only when the analyzer is shutting down and refused to attach. */
|
|
17966
|
+
attached: external_exports.boolean(),
|
|
17967
|
+
/**
|
|
17968
|
+
* True when the attachment replaced a live one for the same device. An
|
|
17969
|
+
* attach is idempotent by REPLACEMENT — two pollers on one camera would
|
|
17970
|
+
* double the broker's fanout and neither would know about the other.
|
|
17971
|
+
*/
|
|
17972
|
+
replaced: external_exports.boolean()
|
|
17973
|
+
});
|
|
17974
|
+
var AudioDetachDeviceResultSchema = external_exports.object({
|
|
17975
|
+
/** False when no attachment existed — detach is idempotent. */
|
|
17976
|
+
detached: external_exports.boolean()
|
|
17977
|
+
});
|
|
17899
17978
|
var AudioClassificationResultSchema = external_exports.object({
|
|
17900
17979
|
labels: external_exports.array(AudioClassificationLabelSchema).readonly(),
|
|
17901
17980
|
rawLabels: external_exports.array(AudioClassificationLabelSchema).readonly().optional(),
|
|
@@ -17911,6 +17990,21 @@ var audioAnalyzerCapability = {
|
|
|
17911
17990
|
settings: AudioAnalysisSettingsSchema
|
|
17912
17991
|
}), AudioAnalysisResultSchema.nullable(), { kind: "mutation" }),
|
|
17913
17992
|
classify: method(AudioChunkInputSchema, AudioClassificationResultSchema, { timeoutMs: 3e4 }),
|
|
17993
|
+
/**
|
|
17994
|
+
* Start pulling this camera's audio from the broker, in THIS process.
|
|
17995
|
+
* Returns as soon as the attachment exists — the first
|
|
17996
|
+
* `subscribeAudioChunks` retries with backoff behind it, because the
|
|
17997
|
+
* broker for a camStream may not be registered yet (that tolerance moved
|
|
17998
|
+
* with the poller, D461). Replaces any live attachment for the device.
|
|
17999
|
+
*/
|
|
18000
|
+
attachDevice: method(AudioAttachDeviceInputSchema, AudioAttachDeviceResultSchema, { kind: "mutation" }),
|
|
18001
|
+
/**
|
|
18002
|
+
* Stop pulling this camera's audio and release the broker subscription.
|
|
18003
|
+
* Idempotent. A detach that never arrives is the one failure mode this
|
|
18004
|
+
* split adds, which is why `AudioChunkPlane` reaps a subscription nobody
|
|
18005
|
+
* drains rather than trusting it (D461).
|
|
18006
|
+
*/
|
|
18007
|
+
detachDevice: method(external_exports.object({ deviceId: external_exports.number() }), AudioDetachDeviceResultSchema, { kind: "mutation" }),
|
|
17914
18008
|
isReady: method(external_exports.void(), external_exports.boolean()),
|
|
17915
18009
|
dispose: method(external_exports.void(), external_exports.void(), { kind: "mutation" }),
|
|
17916
18010
|
/**
|
|
@@ -34020,8 +34114,8 @@ var faceGalleryCapability = {
|
|
|
34020
34114
|
*
|
|
34021
34115
|
* An **empty array reads NOTHING** — `[]` is an empty page, never
|
|
34022
34116
|
* "every camera". A request for no devices is a request, not an
|
|
34023
|
-
* omission; same contract as `deviceManager.
|
|
34024
|
-
* `pipelineAnalytics.listRecentTracks`.
|
|
34117
|
+
* omission; same contract as `deviceManager.listAll`'s `deviceIds`
|
|
34118
|
+
* and `pipelineAnalytics.listRecentTracks`.
|
|
34025
34119
|
*
|
|
34026
34120
|
* Absent (`undefined`) is the omission, and keeps the cluster-wide view.
|
|
34027
34121
|
*/
|
|
@@ -40954,12 +41048,24 @@ var METHOD_ACCESS_MAP = Object.freeze({
|
|
|
40954
41048
|
addonId: null,
|
|
40955
41049
|
access: "create"
|
|
40956
41050
|
},
|
|
41051
|
+
"audioAnalyzer.attachDevice": {
|
|
41052
|
+
capName: "audio-analyzer",
|
|
41053
|
+
capScope: "system",
|
|
41054
|
+
addonId: null,
|
|
41055
|
+
access: "create"
|
|
41056
|
+
},
|
|
40957
41057
|
"audioAnalyzer.classify": {
|
|
40958
41058
|
capName: "audio-analyzer",
|
|
40959
41059
|
capScope: "system",
|
|
40960
41060
|
addonId: null,
|
|
40961
41061
|
access: "view"
|
|
40962
41062
|
},
|
|
41063
|
+
"audioAnalyzer.detachDevice": {
|
|
41064
|
+
capName: "audio-analyzer",
|
|
41065
|
+
capScope: "system",
|
|
41066
|
+
addonId: null,
|
|
41067
|
+
access: "create"
|
|
41068
|
+
},
|
|
40963
41069
|
"audioAnalyzer.dispose": {
|
|
40964
41070
|
capName: "audio-analyzer",
|
|
40965
41071
|
capScope: "system",
|
|
@@ -46803,11 +46909,21 @@ var METHOD_DEVICE_SELECTORS = Object.freeze({
|
|
|
46803
46909
|
form: "single",
|
|
46804
46910
|
optional: false
|
|
46805
46911
|
}],
|
|
46912
|
+
"audioAnalyzer.attachDevice": [{
|
|
46913
|
+
name: "deviceId",
|
|
46914
|
+
form: "single",
|
|
46915
|
+
optional: false
|
|
46916
|
+
}],
|
|
46806
46917
|
"audioAnalyzer.classify": [{
|
|
46807
46918
|
name: "deviceId",
|
|
46808
46919
|
form: "single",
|
|
46809
46920
|
optional: true
|
|
46810
46921
|
}],
|
|
46922
|
+
"audioAnalyzer.detachDevice": [{
|
|
46923
|
+
name: "deviceId",
|
|
46924
|
+
form: "single",
|
|
46925
|
+
optional: false
|
|
46926
|
+
}],
|
|
46811
46927
|
"audioMetrics.getCurrentSnapshot": [{
|
|
46812
46928
|
name: "deviceId",
|
|
46813
46929
|
form: "single",
|
|
@@ -48659,6 +48775,16 @@ var CAP_PROVIDER_KIND_MAP = Object.freeze({
|
|
|
48659
48775
|
"network-access": "ingress",
|
|
48660
48776
|
"smtp-provider": "email"
|
|
48661
48777
|
});
|
|
48778
|
+
var AUDIO_SCALE_EPOCH_ISO = "2026-09-11T00:00:00.000Z";
|
|
48779
|
+
var AUDIO_SCALE_EPOCH_MS = Date.parse(AUDIO_SCALE_EPOCH_ISO);
|
|
48780
|
+
var G711_SCALE_CORRECTION_DB = {
|
|
48781
|
+
PCMU: 20 * Math.log10(4),
|
|
48782
|
+
PCMA: 20 * Math.log10(8)
|
|
48783
|
+
};
|
|
48784
|
+
function ituDbfsFromPreEpoch(law, authoredDbfs) {
|
|
48785
|
+
return authoredDbfs + G711_SCALE_CORRECTION_DB[law];
|
|
48786
|
+
}
|
|
48787
|
+
var NC_AUDIO_DB_OFFERED = Math.round(ituDbfsFromPreEpoch("PCMU", -55));
|
|
48662
48788
|
var NC_AUDIO_DEFAULTS = {
|
|
48663
48789
|
hitPercent: 60,
|
|
48664
48790
|
samplingSeconds: 10
|
|
@@ -48668,7 +48794,7 @@ var BASE_CONDITION_SET = new Set(NC_BASE_CONDITION_KEYS);
|
|
|
48668
48794
|
var NC_AUDIO_SEED = {
|
|
48669
48795
|
hitPercent: NC_AUDIO_DEFAULTS.hitPercent,
|
|
48670
48796
|
samplingSeconds: NC_AUDIO_DEFAULTS.samplingSeconds,
|
|
48671
|
-
dbThreshold:
|
|
48797
|
+
dbThreshold: NC_AUDIO_DB_OFFERED
|
|
48672
48798
|
};
|
|
48673
48799
|
var TimelapseTemplateSchema = external_exports.object({
|
|
48674
48800
|
title: external_exports.string().max(500).optional(),
|
package/dist/cli.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
runDiscover
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-CN634R3T.js";
|
|
5
5
|
import "./chunk-LMMQX4CK.js";
|
|
6
6
|
|
|
7
7
|
// src/cli.ts
|
|
@@ -38,7 +38,7 @@ async function runServe(args) {
|
|
|
38
38
|
...typeof values.data === "string" ? { data: values.data } : {}
|
|
39
39
|
};
|
|
40
40
|
Object.assign(process.env, buildServeEnv(opts));
|
|
41
|
-
await import("./launcher-
|
|
41
|
+
await import("./launcher-XPB2M67K.js");
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
// src/commands/agent.ts
|
|
@@ -83,7 +83,7 @@ async function runAgent(args) {
|
|
|
83
83
|
...typeof values.port === "string" ? { port: values.port } : {}
|
|
84
84
|
};
|
|
85
85
|
Object.assign(process.env, buildAgentEnv(opts));
|
|
86
|
-
await import("./launcher-
|
|
86
|
+
await import("./launcher-XPB2M67K.js");
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
// src/commands/setup.ts
|
|
@@ -1130,7 +1130,7 @@ function isUnknown(_value) {
|
|
|
1130
1130
|
return true;
|
|
1131
1131
|
}
|
|
1132
1132
|
async function resolveServerInteractive(presetNamespace) {
|
|
1133
|
-
const { discoverNodes, resolveHubFromDiscovered, filterHubNodes, DEFAULT_HUB_HTTPS_PORT } = await import("./discover-
|
|
1133
|
+
const { discoverNodes, resolveHubFromDiscovered, filterHubNodes, DEFAULT_HUB_HTTPS_PORT } = await import("./discover-5XVCTM5V.js");
|
|
1134
1134
|
if (presetNamespace) {
|
|
1135
1135
|
const spinner4 = clack.spinner();
|
|
1136
1136
|
spinner4.start(`Discovering hub on LAN (namespace "${presetNamespace}")`);
|