@camstack/addon-pipeline 1.2.179 → 1.2.181
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 +2 -2
- package/dist/audio-analyzer/index.mjs +2 -2
- package/dist/detection-pipeline/index.js +215 -7
- package/dist/detection-pipeline/index.mjs +214 -6
- package/dist/{dist-Bbu27T_N.js → dist-Bh1w7wfg.js} +6 -1
- package/dist/{dist-pMHigtQu.mjs → dist-DOJIQ-sh.mjs} +6 -1
- package/dist/{lazy-sharp-V_rih5vD.js → lazy-sharp-D8FzOY6L.js} +1 -1
- package/dist/{local-frame-registry-DK-Z1Ev1.js → local-frame-registry-Bz2DRFK7.js} +1 -1
- package/dist/{local-frame-registry-C7uCSrQG.mjs → local-frame-registry-Ct4YmN3z.mjs} +1 -1
- package/dist/motion-wasm/index.js +2 -2
- package/dist/motion-wasm/index.mjs +1 -1
- package/dist/{node-CmPPt-uJ.mjs → node-C0KMHgpF.mjs} +1 -1
- package/dist/{node-DMTe6WuM.js → node-Cl2Sjm4s.js} +1 -1
- package/dist/pipeline-runner/index.js +5 -5
- package/dist/pipeline-runner/index.mjs +4 -4
- package/dist/{process-memory-DFA42X6A.js → process-memory-DiEghzlW.js} +1 -1
- package/dist/{process-memory-BSR1vUsp.mjs → process-memory-zLBrzuFc.mjs} +1 -1
- package/dist/recorder/index.js +2 -2
- package/dist/recorder/index.mjs +2 -2
- package/dist/{segment-demux-js-jj19HZoq.js → segment-demux-js-BI5iWBgx.js} +1 -1
- package/dist/{segment-demux-js-D-yE6_2O.mjs → segment-demux-js-BtZ8kfA2.mjs} +1 -1
- package/dist/session-decode/decode-worker-child.js +2 -2
- package/dist/session-decode/decode-worker-child.mjs +1 -1
- package/dist/stream-broker/{_virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-CPhBUByO.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-U-2ES6SY.mjs} +3 -3
- 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-9unPdu_p.mjs → hostInit-pj_S4rLR.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/dist/{worker-protocol-D_44Incp.js → worker-protocol-BGRTG_GT.js} +1 -1
- package/dist/{worker-protocol-BqiZM7J3.mjs → worker-protocol-DGs9jUib.mjs} +1 -1
- package/package.json +1 -1
|
@@ -2,8 +2,8 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_dist = require("../dist-
|
|
6
|
-
const require_process_memory = require("../process-memory-
|
|
5
|
+
const require_dist = require("../dist-Bh1w7wfg.js");
|
|
6
|
+
const require_process_memory = require("../process-memory-DiEghzlW.js");
|
|
7
7
|
let node_fs = require("node:fs");
|
|
8
8
|
node_fs = require_dist.__toESM(node_fs);
|
|
9
9
|
let node_path = require("node:path");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as __require } from "../chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { A as audioAnalysisCapability, It as hydrateSchema, S as PoolMemoryWatchdog, _t as resolvePoolMemoryPolicy, j as audioAnalyzerCapability, jt as BaseAddon, n as AUDIO_BACKEND_CHOICES, nt as mapAudioLabelToMacro, s as DEFAULT_AUDIO_ANALYZER_CONFIG, v as HF_BASE_URL, wt as errMsg } from "../dist-
|
|
3
|
-
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-
|
|
2
|
+
import { A as audioAnalysisCapability, It as hydrateSchema, S as PoolMemoryWatchdog, _t as resolvePoolMemoryPolicy, j as audioAnalyzerCapability, jt as BaseAddon, n as AUDIO_BACKEND_CHOICES, nt as mapAudioLabelToMacro, s as DEFAULT_AUDIO_ANALYZER_CONFIG, v as HF_BASE_URL, wt as errMsg } from "../dist-DOJIQ-sh.mjs";
|
|
3
|
+
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-zLBrzuFc.mjs";
|
|
4
4
|
import * as fs from "node:fs";
|
|
5
5
|
import * as path$1 from "node:path";
|
|
6
6
|
import { downloadFile } from "@camstack/system/addon-utils";
|
|
@@ -2,12 +2,12 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_dist = require("../dist-
|
|
6
|
-
const require_node = require("../node-
|
|
7
|
-
const require_local_frame_registry = require("../local-frame-registry-
|
|
8
|
-
const require_lazy_sharp = require("../lazy-sharp-
|
|
5
|
+
const require_dist = require("../dist-Bh1w7wfg.js");
|
|
6
|
+
const require_node = require("../node-Cl2Sjm4s.js");
|
|
7
|
+
const require_local_frame_registry = require("../local-frame-registry-Bz2DRFK7.js");
|
|
8
|
+
const require_lazy_sharp = require("../lazy-sharp-D8FzOY6L.js");
|
|
9
9
|
const require_event_loop_stall_monitor = require("../event-loop-stall-monitor-DaUBcb13.js");
|
|
10
|
-
const require_process_memory = require("../process-memory-
|
|
10
|
+
const require_process_memory = require("../process-memory-DiEghzlW.js");
|
|
11
11
|
let node_fs = require("node:fs");
|
|
12
12
|
node_fs = require_dist.__toESM(node_fs);
|
|
13
13
|
let node_path = require("node:path");
|
|
@@ -869,6 +869,8 @@ var PoolWorker = class {
|
|
|
869
869
|
* Surfaced so "the camera is quiet" and "the camera is saturated" can be
|
|
870
870
|
* told apart without reading the logs. */
|
|
871
871
|
shedCount = 0;
|
|
872
|
+
/** Requests that hit their client-side deadline (`inference request timed out`). */
|
|
873
|
+
timedOutCount = 0;
|
|
872
874
|
/**
|
|
873
875
|
* Live requests whose deadline fired IN FLIGHT and were answered dropped by
|
|
874
876
|
* the local watchdog (the worker never replied in time). With a v2 worker
|
|
@@ -903,6 +905,9 @@ var PoolWorker = class {
|
|
|
903
905
|
getShedCount() {
|
|
904
906
|
return this.shedCount;
|
|
905
907
|
}
|
|
908
|
+
getTimedOutCount() {
|
|
909
|
+
return this.timedOutCount;
|
|
910
|
+
}
|
|
906
911
|
isReady() {
|
|
907
912
|
return this.ready;
|
|
908
913
|
}
|
|
@@ -1197,6 +1202,7 @@ var PoolWorker = class {
|
|
|
1197
1202
|
});
|
|
1198
1203
|
return;
|
|
1199
1204
|
}
|
|
1205
|
+
this.timedOutCount++;
|
|
1200
1206
|
this.log.error("inference request timed out", {
|
|
1201
1207
|
...deviceId !== void 0 ? { tags: { deviceId } } : {},
|
|
1202
1208
|
meta: {
|
|
@@ -1468,6 +1474,15 @@ var SharedInferencePool = class {
|
|
|
1468
1474
|
getDeadlineExpiredShedCount() {
|
|
1469
1475
|
return this.deadlineExpiredShedCount;
|
|
1470
1476
|
}
|
|
1477
|
+
/**
|
|
1478
|
+
* Requests that timed out client-side, summed over the live workers. A
|
|
1479
|
+
* worker restart resets its share; the inference-timeout guard treats a
|
|
1480
|
+
* drop as "the new count is the delta". This is the metric 1.2.218's
|
|
1481
|
+
* regression was invisible on for 4 h 19 min (2026-09-04).
|
|
1482
|
+
*/
|
|
1483
|
+
getTimedOutCount() {
|
|
1484
|
+
return this.workers.reduce((sum, w) => sum + w.getTimedOutCount(), 0);
|
|
1485
|
+
}
|
|
1471
1486
|
getHandle(modelIndex) {
|
|
1472
1487
|
return new PoolHandle(this, modelIndex);
|
|
1473
1488
|
}
|
|
@@ -2502,12 +2517,14 @@ var EngineFactory = class {
|
|
|
2502
2517
|
inFlight: 0,
|
|
2503
2518
|
shed: 0,
|
|
2504
2519
|
dropped: 0,
|
|
2505
|
-
deadlineExpired: 0
|
|
2520
|
+
deadlineExpired: 0,
|
|
2521
|
+
timedOut: 0
|
|
2506
2522
|
};
|
|
2507
2523
|
return {
|
|
2508
2524
|
...this.pool.getBacklog(),
|
|
2509
2525
|
dropped: this.pool.getDroppedResponseCount(),
|
|
2510
|
-
deadlineExpired: this.pool.getDeadlineExpiredShedCount()
|
|
2526
|
+
deadlineExpired: this.pool.getDeadlineExpiredShedCount(),
|
|
2527
|
+
timedOut: this.pool.getTimedOutCount()
|
|
2511
2528
|
};
|
|
2512
2529
|
}
|
|
2513
2530
|
/** Python-side per-worker memory diagnostics (see SharedInferencePool). */
|
|
@@ -3001,6 +3018,165 @@ async function samplePool(pool, log, reportedDead) {
|
|
|
3001
3018
|
};
|
|
3002
3019
|
}
|
|
3003
3020
|
//#endregion
|
|
3021
|
+
//#region src/detection-pipeline/engine/inference-timeout-guard.ts
|
|
3022
|
+
var TIMEOUT_GUARD_BUCKET_MS = 5 * 6e4;
|
|
3023
|
+
/** Addon-store key the ledger persists under (the addon's own settings blob). */
|
|
3024
|
+
var INFERENCE_TIMEOUT_LEDGER_KEY = "_inferenceTimeoutLedger";
|
|
3025
|
+
var HOUR_MS = 60 * 6e4;
|
|
3026
|
+
function recordTimeoutBucket(ledger, bucket) {
|
|
3027
|
+
const buckets = [...ledger.buckets, bucket];
|
|
3028
|
+
return {
|
|
3029
|
+
version: ledger.version,
|
|
3030
|
+
buckets: buckets.length > 12 ? buckets.slice(buckets.length - 12) : buckets
|
|
3031
|
+
};
|
|
3032
|
+
}
|
|
3033
|
+
/** Timeouts per hour over the ledger's buckets; `null` under the minimum. */
|
|
3034
|
+
function timeoutsPerHour(ledger) {
|
|
3035
|
+
if (ledger === null || ledger.buckets.length < 3) return null;
|
|
3036
|
+
return ledger.buckets.reduce((sum, b) => sum + b.timeouts, 0) / (ledger.buckets.length * TIMEOUT_GUARD_BUCKET_MS) * HOUR_MS;
|
|
3037
|
+
}
|
|
3038
|
+
function evaluateTimeoutRegression(input) {
|
|
3039
|
+
const { previous, current } = input;
|
|
3040
|
+
const previousPerHour = timeoutsPerHour(previous);
|
|
3041
|
+
const currentPerHour = timeoutsPerHour(current);
|
|
3042
|
+
const base = {
|
|
3043
|
+
previousVersion: previous?.version ?? null,
|
|
3044
|
+
currentVersion: current.version,
|
|
3045
|
+
previousPerHour,
|
|
3046
|
+
currentPerHour
|
|
3047
|
+
};
|
|
3048
|
+
if (previous === null || previous.version === current.version || previousPerHour === null || currentPerHour === null) return {
|
|
3049
|
+
kind: "not-comparable",
|
|
3050
|
+
...base
|
|
3051
|
+
};
|
|
3052
|
+
if (currentPerHour >= 20 && currentPerHour >= Math.max(previousPerHour, 20 / 5) * 5) return {
|
|
3053
|
+
kind: "regressed",
|
|
3054
|
+
...base
|
|
3055
|
+
};
|
|
3056
|
+
if (previousPerHour >= 20 && currentPerHour * 5 <= previousPerHour) return {
|
|
3057
|
+
kind: "improved",
|
|
3058
|
+
...base
|
|
3059
|
+
};
|
|
3060
|
+
return {
|
|
3061
|
+
kind: "quiet",
|
|
3062
|
+
...base
|
|
3063
|
+
};
|
|
3064
|
+
}
|
|
3065
|
+
function readStoredLedgers(blob) {
|
|
3066
|
+
const raw = blob[INFERENCE_TIMEOUT_LEDGER_KEY];
|
|
3067
|
+
if (typeof raw !== "object" || raw === null) return {};
|
|
3068
|
+
const r = raw;
|
|
3069
|
+
return {
|
|
3070
|
+
...isLedger(r.current) ? { current: r.current } : {},
|
|
3071
|
+
...isLedger(r.previous) ? { previous: r.previous } : {}
|
|
3072
|
+
};
|
|
3073
|
+
}
|
|
3074
|
+
function isLedger(value) {
|
|
3075
|
+
if (typeof value !== "object" || value === null) return false;
|
|
3076
|
+
const v = value;
|
|
3077
|
+
return typeof v.version === "string" && Array.isArray(v.buckets) && v.buckets.every((b) => typeof b === "object" && b !== null && typeof b.at === "number" && typeof b.timeouts === "number");
|
|
3078
|
+
}
|
|
3079
|
+
function createInferenceTimeoutGuard(deps) {
|
|
3080
|
+
const now = deps.now ?? (() => Date.now());
|
|
3081
|
+
const findingId = `inference-timeout-regression:${deps.nodeId}`;
|
|
3082
|
+
let timer = null;
|
|
3083
|
+
let current = null;
|
|
3084
|
+
let previous = null;
|
|
3085
|
+
let lastTotal = 0;
|
|
3086
|
+
let raised = false;
|
|
3087
|
+
let improvementLogged = false;
|
|
3088
|
+
const ensureLedger = async () => {
|
|
3089
|
+
if (current !== null) return true;
|
|
3090
|
+
const fingerprint = await deps.resolveFingerprint();
|
|
3091
|
+
if (fingerprint === null) return false;
|
|
3092
|
+
const stored = readStoredLedgers(await deps.readStore());
|
|
3093
|
+
if (stored.current !== void 0 && stored.current.version === fingerprint) {
|
|
3094
|
+
current = stored.current;
|
|
3095
|
+
previous = stored.previous ?? null;
|
|
3096
|
+
} else {
|
|
3097
|
+
current = {
|
|
3098
|
+
version: fingerprint,
|
|
3099
|
+
buckets: []
|
|
3100
|
+
};
|
|
3101
|
+
previous = stored.current ?? stored.previous ?? null;
|
|
3102
|
+
}
|
|
3103
|
+
lastTotal = deps.readTotalTimeouts();
|
|
3104
|
+
deps.log.info("inference timeout guard armed", { meta: {
|
|
3105
|
+
fingerprint,
|
|
3106
|
+
previousVersion: previous?.version ?? null,
|
|
3107
|
+
previousPerHour: timeoutsPerHour(previous),
|
|
3108
|
+
bucketMs: TIMEOUT_GUARD_BUCKET_MS
|
|
3109
|
+
} });
|
|
3110
|
+
return true;
|
|
3111
|
+
};
|
|
3112
|
+
const tick = async () => {
|
|
3113
|
+
try {
|
|
3114
|
+
if (!await ensureLedger() || current === null) return;
|
|
3115
|
+
const total = deps.readTotalTimeouts();
|
|
3116
|
+
const delta = total >= lastTotal ? total - lastTotal : total;
|
|
3117
|
+
lastTotal = total;
|
|
3118
|
+
current = recordTimeoutBucket(current, {
|
|
3119
|
+
at: now(),
|
|
3120
|
+
timeouts: delta
|
|
3121
|
+
});
|
|
3122
|
+
await deps.writeStore({ [INFERENCE_TIMEOUT_LEDGER_KEY]: {
|
|
3123
|
+
current,
|
|
3124
|
+
...previous !== null ? { previous } : {}
|
|
3125
|
+
} });
|
|
3126
|
+
const verdict = evaluateTimeoutRegression({
|
|
3127
|
+
previous,
|
|
3128
|
+
current
|
|
3129
|
+
});
|
|
3130
|
+
const meta = {
|
|
3131
|
+
previousVersion: verdict.previousVersion,
|
|
3132
|
+
currentVersion: verdict.currentVersion,
|
|
3133
|
+
previousPerHour: verdict.previousPerHour,
|
|
3134
|
+
currentPerHour: verdict.currentPerHour
|
|
3135
|
+
};
|
|
3136
|
+
if (verdict.kind === "regressed") {
|
|
3137
|
+
if (!raised) {
|
|
3138
|
+
raised = true;
|
|
3139
|
+
const message = `inference requests time out ${Math.round(verdict.currentPerHour ?? 0)}/h under ${verdict.currentVersion}, against ${Math.round(verdict.previousPerHour ?? 0)}/h under ${verdict.previousVersion ?? "unknown"} — the update regressed inference on ${deps.nodeId}`;
|
|
3140
|
+
deps.log.error("inference timeout REGRESSION after update", { meta });
|
|
3141
|
+
deps.emitFailed({
|
|
3142
|
+
findingId,
|
|
3143
|
+
severity: "error",
|
|
3144
|
+
title: "Inference timeouts regressed after update",
|
|
3145
|
+
message
|
|
3146
|
+
});
|
|
3147
|
+
}
|
|
3148
|
+
return;
|
|
3149
|
+
}
|
|
3150
|
+
if (raised && verdict.kind !== "not-comparable") {
|
|
3151
|
+
raised = false;
|
|
3152
|
+
deps.log.info("inference timeout regression cleared", { meta });
|
|
3153
|
+
deps.emitRecovered(findingId);
|
|
3154
|
+
}
|
|
3155
|
+
if (verdict.kind === "improved" && !improvementLogged) {
|
|
3156
|
+
improvementLogged = true;
|
|
3157
|
+
deps.log.info("inference timeouts improved after update", { meta });
|
|
3158
|
+
}
|
|
3159
|
+
} catch (err) {
|
|
3160
|
+
deps.log.warn("inference timeout guard tick failed", { meta: { error: err instanceof Error ? err.message : String(err) } });
|
|
3161
|
+
}
|
|
3162
|
+
};
|
|
3163
|
+
return {
|
|
3164
|
+
start: () => {
|
|
3165
|
+
if (timer !== null) return;
|
|
3166
|
+
timer = setInterval(() => {
|
|
3167
|
+
tick();
|
|
3168
|
+
}, TIMEOUT_GUARD_BUCKET_MS);
|
|
3169
|
+
timer.unref?.();
|
|
3170
|
+
ensureLedger();
|
|
3171
|
+
},
|
|
3172
|
+
tick,
|
|
3173
|
+
stop: () => {
|
|
3174
|
+
if (timer !== null) clearInterval(timer);
|
|
3175
|
+
timer = null;
|
|
3176
|
+
}
|
|
3177
|
+
};
|
|
3178
|
+
}
|
|
3179
|
+
//#endregion
|
|
3004
3180
|
//#region src/detection-pipeline/engine-provisioner.ts
|
|
3005
3181
|
/** Incremental backoff growing to a ~5 min cap; retries indefinitely at cap. */
|
|
3006
3182
|
var BACKOFF_SCHEDULE_MS = [
|
|
@@ -6179,6 +6355,11 @@ function applyZoneRuleGate(result, zones, rules) {
|
|
|
6179
6355
|
* This is the main provider that consumers (DetectionWiring, Benchmark, tRPC)
|
|
6180
6356
|
* interact with. It manages the engine factory, pipeline executor, and config persistence.
|
|
6181
6357
|
*/
|
|
6358
|
+
/** Event source of the inference-timeout guard's liveness findings. */
|
|
6359
|
+
var TIMEOUT_GUARD_SOURCE = {
|
|
6360
|
+
type: "addon",
|
|
6361
|
+
id: "detection-pipeline"
|
|
6362
|
+
};
|
|
6182
6363
|
var KEY_TEMPLATES = "pipelineTemplates";
|
|
6183
6364
|
function pythonModuleForBackend(backend) {
|
|
6184
6365
|
switch (backend) {
|
|
@@ -6606,6 +6787,8 @@ var DetectionPipelineProvider = class DetectionPipelineProvider {
|
|
|
6606
6787
|
* restart action. Started in `init()`, stopped in `shutdown()`.
|
|
6607
6788
|
*/
|
|
6608
6789
|
poolMemoryGuard = null;
|
|
6790
|
+
/** Compares this node's inference-timeout rate across closure updates. */
|
|
6791
|
+
inferenceTimeoutGuard = null;
|
|
6609
6792
|
/** Watchdog view of the live pools: the node-default pool plus every
|
|
6610
6793
|
* per-device pool. Keys are stable per pool identity so the watchdog's
|
|
6611
6794
|
* baseline tracks one pool across sweeps. */
|
|
@@ -6702,6 +6885,29 @@ var DetectionPipelineProvider = class DetectionPipelineProvider {
|
|
|
6702
6885
|
}, this.log);
|
|
6703
6886
|
this.poolMemoryGuard.start();
|
|
6704
6887
|
}
|
|
6888
|
+
if (!this.inferenceTimeoutGuard) {
|
|
6889
|
+
const nodeId = this.localProbeNodeId();
|
|
6890
|
+
this.inferenceTimeoutGuard = createInferenceTimeoutGuard({
|
|
6891
|
+
readTotalTimeouts: () => this.listGuardedPools().reduce((sum, pool) => sum + pool.factory.getPoolBacklog().timedOut, 0),
|
|
6892
|
+
readStore: () => this.readStore(),
|
|
6893
|
+
writeStore: (patch) => this.writeStore(patch),
|
|
6894
|
+
resolveFingerprint: async () => {
|
|
6895
|
+
const ctx = this.addonCtx;
|
|
6896
|
+
if (!ctx) return null;
|
|
6897
|
+
const status = await ctx.api.serverManagement.getServerPackageStatus.query({ nodeId });
|
|
6898
|
+
return status.runningVersion === null ? null : `server@${status.runningVersion}`;
|
|
6899
|
+
},
|
|
6900
|
+
emitFailed: (finding) => {
|
|
6901
|
+
this.eventBus?.emit(require_dist.createEvent(require_dist.EventCategory.SystemLivenessFailed, TIMEOUT_GUARD_SOURCE, finding));
|
|
6902
|
+
},
|
|
6903
|
+
emitRecovered: (findingId) => {
|
|
6904
|
+
this.eventBus?.emit(require_dist.createEvent(require_dist.EventCategory.SystemLivenessRecovered, TIMEOUT_GUARD_SOURCE, { findingId }));
|
|
6905
|
+
},
|
|
6906
|
+
nodeId,
|
|
6907
|
+
log: this.log.child("inference-timeout-guard")
|
|
6908
|
+
});
|
|
6909
|
+
this.inferenceTimeoutGuard.start();
|
|
6910
|
+
}
|
|
6705
6911
|
}
|
|
6706
6912
|
/**
|
|
6707
6913
|
* Lazy-install the pip requirements file matching `engine.backend` into
|
|
@@ -8623,6 +8829,8 @@ var DetectionPipelineProvider = class DetectionPipelineProvider {
|
|
|
8623
8829
|
async shutdown() {
|
|
8624
8830
|
this.poolMemoryGuard?.stop();
|
|
8625
8831
|
this.poolMemoryGuard = null;
|
|
8832
|
+
this.inferenceTimeoutGuard?.stop();
|
|
8833
|
+
this.inferenceTimeoutGuard = null;
|
|
8626
8834
|
await this.evictOverrideCache("shutdown");
|
|
8627
8835
|
if (this.engineFactory) {
|
|
8628
8836
|
await this.engineFactory.dispose();
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { n as __require } from "../chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { Bt as nodePin, Ft as createEvent, It as hydrateSchema, Kt as array, O as YAMNET_TO_MACRO, Q as inferModelProvider, Qt as object, S as PoolMemoryWatchdog, St as supportedRuntimes$1, Vt as parseJsonUnknown, W as detectionPipelineCapability, Wt as sleep, Y as evaluateZoneRules, _t as resolvePoolMemoryPolicy, at as overlayClusterStepSettings, c as DEFAULT_CLUSTER_STEP_MODELS, ct as pickClusterStepSettings, dt as pipelineExecutorCapability, en as string, et as loadContributionCapability, ht as resolveClusterStepModelId, jt as BaseAddon, l as DEFAULT_CLUSTER_STEP_SETTINGS, m as DEVICE_BACKEND_TO_FORMAT, nn as EventCategory, q as enumerateInferenceDevices, st as pickClusterStepModels, t as APPLE_SA_TO_MACRO, tn as union, wt as errMsg, yt as runtimeDevices$1, z as defaultDeviceFor$1 } from "../dist-
|
|
3
|
-
import { a as readProcessCost } from "../node-
|
|
4
|
-
import { a as getDefaultModelForFormat, c as getStepDefinition, i as ALL_STEPS, l as resolveModelForFormat, o as getDefaultModelForFormatFromDef, r as ALL_PIPELINE_STEPS, s as getStep, t as localFrameRegistry, u as landmarkPrecisionVerdict } from "../local-frame-registry-
|
|
2
|
+
import { Bt as nodePin, Ft as createEvent, It as hydrateSchema, Kt as array, O as YAMNET_TO_MACRO, Q as inferModelProvider, Qt as object, S as PoolMemoryWatchdog, St as supportedRuntimes$1, Vt as parseJsonUnknown, W as detectionPipelineCapability, Wt as sleep, Y as evaluateZoneRules, _t as resolvePoolMemoryPolicy, at as overlayClusterStepSettings, c as DEFAULT_CLUSTER_STEP_MODELS, ct as pickClusterStepSettings, dt as pipelineExecutorCapability, en as string, et as loadContributionCapability, ht as resolveClusterStepModelId, jt as BaseAddon, l as DEFAULT_CLUSTER_STEP_SETTINGS, m as DEVICE_BACKEND_TO_FORMAT, nn as EventCategory, q as enumerateInferenceDevices, st as pickClusterStepModels, t as APPLE_SA_TO_MACRO, tn as union, wt as errMsg, yt as runtimeDevices$1, z as defaultDeviceFor$1 } from "../dist-DOJIQ-sh.mjs";
|
|
3
|
+
import { a as readProcessCost } from "../node-C0KMHgpF.mjs";
|
|
4
|
+
import { a as getDefaultModelForFormat, c as getStepDefinition, i as ALL_STEPS, l as resolveModelForFormat, o as getDefaultModelForFormatFromDef, r as ALL_PIPELINE_STEPS, s as getStep, t as localFrameRegistry, u as landmarkPrecisionVerdict } from "../local-frame-registry-Ct4YmN3z.mjs";
|
|
5
5
|
import { t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
6
6
|
import { n as startEventLoopStallMonitor } from "../event-loop-stall-monitor-DXLNBMkY.mjs";
|
|
7
|
-
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-
|
|
7
|
+
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-zLBrzuFc.mjs";
|
|
8
8
|
import * as fs from "node:fs";
|
|
9
9
|
import * as path$1 from "node:path";
|
|
10
10
|
import { spawn } from "node:child_process";
|
|
@@ -862,6 +862,8 @@ var PoolWorker = class {
|
|
|
862
862
|
* Surfaced so "the camera is quiet" and "the camera is saturated" can be
|
|
863
863
|
* told apart without reading the logs. */
|
|
864
864
|
shedCount = 0;
|
|
865
|
+
/** Requests that hit their client-side deadline (`inference request timed out`). */
|
|
866
|
+
timedOutCount = 0;
|
|
865
867
|
/**
|
|
866
868
|
* Live requests whose deadline fired IN FLIGHT and were answered dropped by
|
|
867
869
|
* the local watchdog (the worker never replied in time). With a v2 worker
|
|
@@ -896,6 +898,9 @@ var PoolWorker = class {
|
|
|
896
898
|
getShedCount() {
|
|
897
899
|
return this.shedCount;
|
|
898
900
|
}
|
|
901
|
+
getTimedOutCount() {
|
|
902
|
+
return this.timedOutCount;
|
|
903
|
+
}
|
|
899
904
|
isReady() {
|
|
900
905
|
return this.ready;
|
|
901
906
|
}
|
|
@@ -1190,6 +1195,7 @@ var PoolWorker = class {
|
|
|
1190
1195
|
});
|
|
1191
1196
|
return;
|
|
1192
1197
|
}
|
|
1198
|
+
this.timedOutCount++;
|
|
1193
1199
|
this.log.error("inference request timed out", {
|
|
1194
1200
|
...deviceId !== void 0 ? { tags: { deviceId } } : {},
|
|
1195
1201
|
meta: {
|
|
@@ -1461,6 +1467,15 @@ var SharedInferencePool = class {
|
|
|
1461
1467
|
getDeadlineExpiredShedCount() {
|
|
1462
1468
|
return this.deadlineExpiredShedCount;
|
|
1463
1469
|
}
|
|
1470
|
+
/**
|
|
1471
|
+
* Requests that timed out client-side, summed over the live workers. A
|
|
1472
|
+
* worker restart resets its share; the inference-timeout guard treats a
|
|
1473
|
+
* drop as "the new count is the delta". This is the metric 1.2.218's
|
|
1474
|
+
* regression was invisible on for 4 h 19 min (2026-09-04).
|
|
1475
|
+
*/
|
|
1476
|
+
getTimedOutCount() {
|
|
1477
|
+
return this.workers.reduce((sum, w) => sum + w.getTimedOutCount(), 0);
|
|
1478
|
+
}
|
|
1464
1479
|
getHandle(modelIndex) {
|
|
1465
1480
|
return new PoolHandle(this, modelIndex);
|
|
1466
1481
|
}
|
|
@@ -2495,12 +2510,14 @@ var EngineFactory = class {
|
|
|
2495
2510
|
inFlight: 0,
|
|
2496
2511
|
shed: 0,
|
|
2497
2512
|
dropped: 0,
|
|
2498
|
-
deadlineExpired: 0
|
|
2513
|
+
deadlineExpired: 0,
|
|
2514
|
+
timedOut: 0
|
|
2499
2515
|
};
|
|
2500
2516
|
return {
|
|
2501
2517
|
...this.pool.getBacklog(),
|
|
2502
2518
|
dropped: this.pool.getDroppedResponseCount(),
|
|
2503
|
-
deadlineExpired: this.pool.getDeadlineExpiredShedCount()
|
|
2519
|
+
deadlineExpired: this.pool.getDeadlineExpiredShedCount(),
|
|
2520
|
+
timedOut: this.pool.getTimedOutCount()
|
|
2504
2521
|
};
|
|
2505
2522
|
}
|
|
2506
2523
|
/** Python-side per-worker memory diagnostics (see SharedInferencePool). */
|
|
@@ -2994,6 +3011,165 @@ async function samplePool(pool, log, reportedDead) {
|
|
|
2994
3011
|
};
|
|
2995
3012
|
}
|
|
2996
3013
|
//#endregion
|
|
3014
|
+
//#region src/detection-pipeline/engine/inference-timeout-guard.ts
|
|
3015
|
+
var TIMEOUT_GUARD_BUCKET_MS = 5 * 6e4;
|
|
3016
|
+
/** Addon-store key the ledger persists under (the addon's own settings blob). */
|
|
3017
|
+
var INFERENCE_TIMEOUT_LEDGER_KEY = "_inferenceTimeoutLedger";
|
|
3018
|
+
var HOUR_MS = 60 * 6e4;
|
|
3019
|
+
function recordTimeoutBucket(ledger, bucket) {
|
|
3020
|
+
const buckets = [...ledger.buckets, bucket];
|
|
3021
|
+
return {
|
|
3022
|
+
version: ledger.version,
|
|
3023
|
+
buckets: buckets.length > 12 ? buckets.slice(buckets.length - 12) : buckets
|
|
3024
|
+
};
|
|
3025
|
+
}
|
|
3026
|
+
/** Timeouts per hour over the ledger's buckets; `null` under the minimum. */
|
|
3027
|
+
function timeoutsPerHour(ledger) {
|
|
3028
|
+
if (ledger === null || ledger.buckets.length < 3) return null;
|
|
3029
|
+
return ledger.buckets.reduce((sum, b) => sum + b.timeouts, 0) / (ledger.buckets.length * TIMEOUT_GUARD_BUCKET_MS) * HOUR_MS;
|
|
3030
|
+
}
|
|
3031
|
+
function evaluateTimeoutRegression(input) {
|
|
3032
|
+
const { previous, current } = input;
|
|
3033
|
+
const previousPerHour = timeoutsPerHour(previous);
|
|
3034
|
+
const currentPerHour = timeoutsPerHour(current);
|
|
3035
|
+
const base = {
|
|
3036
|
+
previousVersion: previous?.version ?? null,
|
|
3037
|
+
currentVersion: current.version,
|
|
3038
|
+
previousPerHour,
|
|
3039
|
+
currentPerHour
|
|
3040
|
+
};
|
|
3041
|
+
if (previous === null || previous.version === current.version || previousPerHour === null || currentPerHour === null) return {
|
|
3042
|
+
kind: "not-comparable",
|
|
3043
|
+
...base
|
|
3044
|
+
};
|
|
3045
|
+
if (currentPerHour >= 20 && currentPerHour >= Math.max(previousPerHour, 20 / 5) * 5) return {
|
|
3046
|
+
kind: "regressed",
|
|
3047
|
+
...base
|
|
3048
|
+
};
|
|
3049
|
+
if (previousPerHour >= 20 && currentPerHour * 5 <= previousPerHour) return {
|
|
3050
|
+
kind: "improved",
|
|
3051
|
+
...base
|
|
3052
|
+
};
|
|
3053
|
+
return {
|
|
3054
|
+
kind: "quiet",
|
|
3055
|
+
...base
|
|
3056
|
+
};
|
|
3057
|
+
}
|
|
3058
|
+
function readStoredLedgers(blob) {
|
|
3059
|
+
const raw = blob[INFERENCE_TIMEOUT_LEDGER_KEY];
|
|
3060
|
+
if (typeof raw !== "object" || raw === null) return {};
|
|
3061
|
+
const r = raw;
|
|
3062
|
+
return {
|
|
3063
|
+
...isLedger(r.current) ? { current: r.current } : {},
|
|
3064
|
+
...isLedger(r.previous) ? { previous: r.previous } : {}
|
|
3065
|
+
};
|
|
3066
|
+
}
|
|
3067
|
+
function isLedger(value) {
|
|
3068
|
+
if (typeof value !== "object" || value === null) return false;
|
|
3069
|
+
const v = value;
|
|
3070
|
+
return typeof v.version === "string" && Array.isArray(v.buckets) && v.buckets.every((b) => typeof b === "object" && b !== null && typeof b.at === "number" && typeof b.timeouts === "number");
|
|
3071
|
+
}
|
|
3072
|
+
function createInferenceTimeoutGuard(deps) {
|
|
3073
|
+
const now = deps.now ?? (() => Date.now());
|
|
3074
|
+
const findingId = `inference-timeout-regression:${deps.nodeId}`;
|
|
3075
|
+
let timer = null;
|
|
3076
|
+
let current = null;
|
|
3077
|
+
let previous = null;
|
|
3078
|
+
let lastTotal = 0;
|
|
3079
|
+
let raised = false;
|
|
3080
|
+
let improvementLogged = false;
|
|
3081
|
+
const ensureLedger = async () => {
|
|
3082
|
+
if (current !== null) return true;
|
|
3083
|
+
const fingerprint = await deps.resolveFingerprint();
|
|
3084
|
+
if (fingerprint === null) return false;
|
|
3085
|
+
const stored = readStoredLedgers(await deps.readStore());
|
|
3086
|
+
if (stored.current !== void 0 && stored.current.version === fingerprint) {
|
|
3087
|
+
current = stored.current;
|
|
3088
|
+
previous = stored.previous ?? null;
|
|
3089
|
+
} else {
|
|
3090
|
+
current = {
|
|
3091
|
+
version: fingerprint,
|
|
3092
|
+
buckets: []
|
|
3093
|
+
};
|
|
3094
|
+
previous = stored.current ?? stored.previous ?? null;
|
|
3095
|
+
}
|
|
3096
|
+
lastTotal = deps.readTotalTimeouts();
|
|
3097
|
+
deps.log.info("inference timeout guard armed", { meta: {
|
|
3098
|
+
fingerprint,
|
|
3099
|
+
previousVersion: previous?.version ?? null,
|
|
3100
|
+
previousPerHour: timeoutsPerHour(previous),
|
|
3101
|
+
bucketMs: TIMEOUT_GUARD_BUCKET_MS
|
|
3102
|
+
} });
|
|
3103
|
+
return true;
|
|
3104
|
+
};
|
|
3105
|
+
const tick = async () => {
|
|
3106
|
+
try {
|
|
3107
|
+
if (!await ensureLedger() || current === null) return;
|
|
3108
|
+
const total = deps.readTotalTimeouts();
|
|
3109
|
+
const delta = total >= lastTotal ? total - lastTotal : total;
|
|
3110
|
+
lastTotal = total;
|
|
3111
|
+
current = recordTimeoutBucket(current, {
|
|
3112
|
+
at: now(),
|
|
3113
|
+
timeouts: delta
|
|
3114
|
+
});
|
|
3115
|
+
await deps.writeStore({ [INFERENCE_TIMEOUT_LEDGER_KEY]: {
|
|
3116
|
+
current,
|
|
3117
|
+
...previous !== null ? { previous } : {}
|
|
3118
|
+
} });
|
|
3119
|
+
const verdict = evaluateTimeoutRegression({
|
|
3120
|
+
previous,
|
|
3121
|
+
current
|
|
3122
|
+
});
|
|
3123
|
+
const meta = {
|
|
3124
|
+
previousVersion: verdict.previousVersion,
|
|
3125
|
+
currentVersion: verdict.currentVersion,
|
|
3126
|
+
previousPerHour: verdict.previousPerHour,
|
|
3127
|
+
currentPerHour: verdict.currentPerHour
|
|
3128
|
+
};
|
|
3129
|
+
if (verdict.kind === "regressed") {
|
|
3130
|
+
if (!raised) {
|
|
3131
|
+
raised = true;
|
|
3132
|
+
const message = `inference requests time out ${Math.round(verdict.currentPerHour ?? 0)}/h under ${verdict.currentVersion}, against ${Math.round(verdict.previousPerHour ?? 0)}/h under ${verdict.previousVersion ?? "unknown"} — the update regressed inference on ${deps.nodeId}`;
|
|
3133
|
+
deps.log.error("inference timeout REGRESSION after update", { meta });
|
|
3134
|
+
deps.emitFailed({
|
|
3135
|
+
findingId,
|
|
3136
|
+
severity: "error",
|
|
3137
|
+
title: "Inference timeouts regressed after update",
|
|
3138
|
+
message
|
|
3139
|
+
});
|
|
3140
|
+
}
|
|
3141
|
+
return;
|
|
3142
|
+
}
|
|
3143
|
+
if (raised && verdict.kind !== "not-comparable") {
|
|
3144
|
+
raised = false;
|
|
3145
|
+
deps.log.info("inference timeout regression cleared", { meta });
|
|
3146
|
+
deps.emitRecovered(findingId);
|
|
3147
|
+
}
|
|
3148
|
+
if (verdict.kind === "improved" && !improvementLogged) {
|
|
3149
|
+
improvementLogged = true;
|
|
3150
|
+
deps.log.info("inference timeouts improved after update", { meta });
|
|
3151
|
+
}
|
|
3152
|
+
} catch (err) {
|
|
3153
|
+
deps.log.warn("inference timeout guard tick failed", { meta: { error: err instanceof Error ? err.message : String(err) } });
|
|
3154
|
+
}
|
|
3155
|
+
};
|
|
3156
|
+
return {
|
|
3157
|
+
start: () => {
|
|
3158
|
+
if (timer !== null) return;
|
|
3159
|
+
timer = setInterval(() => {
|
|
3160
|
+
tick();
|
|
3161
|
+
}, TIMEOUT_GUARD_BUCKET_MS);
|
|
3162
|
+
timer.unref?.();
|
|
3163
|
+
ensureLedger();
|
|
3164
|
+
},
|
|
3165
|
+
tick,
|
|
3166
|
+
stop: () => {
|
|
3167
|
+
if (timer !== null) clearInterval(timer);
|
|
3168
|
+
timer = null;
|
|
3169
|
+
}
|
|
3170
|
+
};
|
|
3171
|
+
}
|
|
3172
|
+
//#endregion
|
|
2997
3173
|
//#region src/detection-pipeline/engine-provisioner.ts
|
|
2998
3174
|
/** Incremental backoff growing to a ~5 min cap; retries indefinitely at cap. */
|
|
2999
3175
|
var BACKOFF_SCHEDULE_MS = [
|
|
@@ -6172,6 +6348,11 @@ function applyZoneRuleGate(result, zones, rules) {
|
|
|
6172
6348
|
* This is the main provider that consumers (DetectionWiring, Benchmark, tRPC)
|
|
6173
6349
|
* interact with. It manages the engine factory, pipeline executor, and config persistence.
|
|
6174
6350
|
*/
|
|
6351
|
+
/** Event source of the inference-timeout guard's liveness findings. */
|
|
6352
|
+
var TIMEOUT_GUARD_SOURCE = {
|
|
6353
|
+
type: "addon",
|
|
6354
|
+
id: "detection-pipeline"
|
|
6355
|
+
};
|
|
6175
6356
|
var KEY_TEMPLATES = "pipelineTemplates";
|
|
6176
6357
|
function pythonModuleForBackend(backend) {
|
|
6177
6358
|
switch (backend) {
|
|
@@ -6599,6 +6780,8 @@ var DetectionPipelineProvider = class DetectionPipelineProvider {
|
|
|
6599
6780
|
* restart action. Started in `init()`, stopped in `shutdown()`.
|
|
6600
6781
|
*/
|
|
6601
6782
|
poolMemoryGuard = null;
|
|
6783
|
+
/** Compares this node's inference-timeout rate across closure updates. */
|
|
6784
|
+
inferenceTimeoutGuard = null;
|
|
6602
6785
|
/** Watchdog view of the live pools: the node-default pool plus every
|
|
6603
6786
|
* per-device pool. Keys are stable per pool identity so the watchdog's
|
|
6604
6787
|
* baseline tracks one pool across sweeps. */
|
|
@@ -6695,6 +6878,29 @@ var DetectionPipelineProvider = class DetectionPipelineProvider {
|
|
|
6695
6878
|
}, this.log);
|
|
6696
6879
|
this.poolMemoryGuard.start();
|
|
6697
6880
|
}
|
|
6881
|
+
if (!this.inferenceTimeoutGuard) {
|
|
6882
|
+
const nodeId = this.localProbeNodeId();
|
|
6883
|
+
this.inferenceTimeoutGuard = createInferenceTimeoutGuard({
|
|
6884
|
+
readTotalTimeouts: () => this.listGuardedPools().reduce((sum, pool) => sum + pool.factory.getPoolBacklog().timedOut, 0),
|
|
6885
|
+
readStore: () => this.readStore(),
|
|
6886
|
+
writeStore: (patch) => this.writeStore(patch),
|
|
6887
|
+
resolveFingerprint: async () => {
|
|
6888
|
+
const ctx = this.addonCtx;
|
|
6889
|
+
if (!ctx) return null;
|
|
6890
|
+
const status = await ctx.api.serverManagement.getServerPackageStatus.query({ nodeId });
|
|
6891
|
+
return status.runningVersion === null ? null : `server@${status.runningVersion}`;
|
|
6892
|
+
},
|
|
6893
|
+
emitFailed: (finding) => {
|
|
6894
|
+
this.eventBus?.emit(createEvent(EventCategory.SystemLivenessFailed, TIMEOUT_GUARD_SOURCE, finding));
|
|
6895
|
+
},
|
|
6896
|
+
emitRecovered: (findingId) => {
|
|
6897
|
+
this.eventBus?.emit(createEvent(EventCategory.SystemLivenessRecovered, TIMEOUT_GUARD_SOURCE, { findingId }));
|
|
6898
|
+
},
|
|
6899
|
+
nodeId,
|
|
6900
|
+
log: this.log.child("inference-timeout-guard")
|
|
6901
|
+
});
|
|
6902
|
+
this.inferenceTimeoutGuard.start();
|
|
6903
|
+
}
|
|
6698
6904
|
}
|
|
6699
6905
|
/**
|
|
6700
6906
|
* Lazy-install the pip requirements file matching `engine.backend` into
|
|
@@ -8616,6 +8822,8 @@ var DetectionPipelineProvider = class DetectionPipelineProvider {
|
|
|
8616
8822
|
async shutdown() {
|
|
8617
8823
|
this.poolMemoryGuard?.stop();
|
|
8618
8824
|
this.poolMemoryGuard = null;
|
|
8825
|
+
this.inferenceTimeoutGuard?.stop();
|
|
8826
|
+
this.inferenceTimeoutGuard = null;
|
|
8619
8827
|
await this.evictOverrideCache("shutdown");
|
|
8620
8828
|
if (this.engineFactory) {
|
|
8621
8829
|
await this.engineFactory.dispose();
|
|
@@ -14693,7 +14693,12 @@ var ConfigEntrySchema = object({
|
|
|
14693
14693
|
value: unknown(),
|
|
14694
14694
|
description: string().optional()
|
|
14695
14695
|
});
|
|
14696
|
-
|
|
14696
|
+
/**
|
|
14697
|
+
* Only `manual` since D356: the operator picks, nothing links itself. The
|
|
14698
|
+
* field survives on the wire because a viewer already OTA'd parses it —
|
|
14699
|
+
* drop it once no shipped client reads `mode`.
|
|
14700
|
+
*/
|
|
14701
|
+
var LinkedDevicesModeSchema = _enum(["manual"]);
|
|
14697
14702
|
/** One resolved linked device — the compact projection consumers need. */
|
|
14698
14703
|
var LinkedDeviceSchema = object({
|
|
14699
14704
|
deviceId: number(),
|
|
@@ -14670,7 +14670,12 @@ var ConfigEntrySchema = object({
|
|
|
14670
14670
|
value: unknown(),
|
|
14671
14671
|
description: string().optional()
|
|
14672
14672
|
});
|
|
14673
|
-
|
|
14673
|
+
/**
|
|
14674
|
+
* Only `manual` since D356: the operator picks, nothing links itself. The
|
|
14675
|
+
* field survives on the wire because a viewer already OTA'd parses it —
|
|
14676
|
+
* drop it once no shipped client reads `mode`.
|
|
14677
|
+
*/
|
|
14678
|
+
var LinkedDevicesModeSchema = _enum(["manual"]);
|
|
14674
14679
|
/** One resolved linked device — the compact projection consumers need. */
|
|
14675
14680
|
var LinkedDeviceSchema = object({
|
|
14676
14681
|
deviceId: number(),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as audioKindId, Z as hfModelUrl, a as COCO_80_LABELS, o as COCO_TO_MACRO, r as AUDIO_MACRO_LABELS } from "./dist-
|
|
1
|
+
import { M as audioKindId, Z as hfModelUrl, a as COCO_80_LABELS, o as COCO_TO_MACRO, r as AUDIO_MACRO_LABELS } from "./dist-DOJIQ-sh.mjs";
|
|
2
2
|
import { randomUUID } from "node:crypto";
|
|
3
3
|
//#region src/detection-pipeline/registry/model-catalogs.ts
|
|
4
4
|
var HF_REPO = "camstack/camstack-models";
|
|
@@ -2,8 +2,8 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_dist = require("../dist-
|
|
6
|
-
const require_lazy_sharp = require("../lazy-sharp-
|
|
5
|
+
const require_dist = require("../dist-Bh1w7wfg.js");
|
|
6
|
+
const require_lazy_sharp = require("../lazy-sharp-D8FzOY6L.js");
|
|
7
7
|
let node_fs = require("node:fs");
|
|
8
8
|
let node_path = require("node:path");
|
|
9
9
|
//#region src/motion-wasm/wasm-motion-detector.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { It as hydrateSchema, Pt as DeviceType, Y as evaluateZoneRules, it as motionDetectionCapability, jt as BaseAddon } from "../dist-
|
|
1
|
+
import { It as hydrateSchema, Pt as DeviceType, Y as evaluateZoneRules, it as motionDetectionCapability, jt as BaseAddon } from "../dist-DOJIQ-sh.mjs";
|
|
2
2
|
import { t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
3
3
|
import { readFileSync } from "node:fs";
|
|
4
4
|
import { join } from "node:path";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Dt as buildFfmpegArgs, Et as Fmp4BoxSplitter, kt as isSoftwareDecode, wt as errMsg } from "./dist-
|
|
1
|
+
import { Dt as buildFfmpegArgs, Et as Fmp4BoxSplitter, kt as isSoftwareDecode, wt as errMsg } from "./dist-DOJIQ-sh.mjs";
|
|
2
2
|
import { randomUUID } from "node:crypto";
|
|
3
3
|
import "node:fs";
|
|
4
4
|
import "node:path";
|
|
@@ -2,12 +2,12 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_dist = require("../dist-
|
|
6
|
-
const require_node = require("../node-
|
|
7
|
-
const require_local_frame_registry = require("../local-frame-registry-
|
|
8
|
-
const require_worker_protocol = require("../worker-protocol-
|
|
5
|
+
const require_dist = require("../dist-Bh1w7wfg.js");
|
|
6
|
+
const require_node = require("../node-Cl2Sjm4s.js");
|
|
7
|
+
const require_local_frame_registry = require("../local-frame-registry-Bz2DRFK7.js");
|
|
8
|
+
const require_worker_protocol = require("../worker-protocol-BGRTG_GT.js");
|
|
9
9
|
const require_hub_hostname = require("../hub-hostname-DAJXlOgV.js");
|
|
10
|
-
const require_lazy_sharp = require("../lazy-sharp-
|
|
10
|
+
const require_lazy_sharp = require("../lazy-sharp-D8FzOY6L.js");
|
|
11
11
|
const require_restream_intent = require("../restream-intent-Cv9x3jmu.js");
|
|
12
12
|
const require_event_loop_stall_monitor = require("../event-loop-stall-monitor-DaUBcb13.js");
|
|
13
13
|
const require_remote_restream = require("../remote-restream-CO36Sr30.js");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { B as defineCustomActions, Bt as nodePin, Ft as createEvent, Gt as _enum, H as deriveDetailCropRect, Kt as array, L as customAction, Qt as object, X as failureContributionCapability, Xt as literal, Yt as lazy, Zt as number, _ as FailureCounters, en as string, et as loadContributionCapability, ft as pipelineRunnerCapability, jt as BaseAddon, lt as pickDetailCropConvention, m as DEVICE_BACKEND_TO_FORMAT, nn as EventCategory, p as DEFAULT_NATIVE_LEASE_SETTINGS, qt as boolean, u as DEFAULT_DETAIL_CROP_CONVENTION, ut as pickNativeLeaseOverride, wt as errMsg } from "../dist-
|
|
2
|
-
import { i as NO_COST_CLAIM, t as ChildCostRegistry } from "../node-
|
|
3
|
-
import { c as getStepDefinition, n as resolveFrameViewGeometry, t as localFrameRegistry } from "../local-frame-registry-
|
|
4
|
-
import { a as nativeLeaseSettingEnv, t as isWorkerReply } from "../worker-protocol-
|
|
1
|
+
import { B as defineCustomActions, Bt as nodePin, Ft as createEvent, Gt as _enum, H as deriveDetailCropRect, Kt as array, L as customAction, Qt as object, X as failureContributionCapability, Xt as literal, Yt as lazy, Zt as number, _ as FailureCounters, en as string, et as loadContributionCapability, ft as pipelineRunnerCapability, jt as BaseAddon, lt as pickDetailCropConvention, m as DEVICE_BACKEND_TO_FORMAT, nn as EventCategory, p as DEFAULT_NATIVE_LEASE_SETTINGS, qt as boolean, u as DEFAULT_DETAIL_CROP_CONVENTION, ut as pickNativeLeaseOverride, wt as errMsg } from "../dist-DOJIQ-sh.mjs";
|
|
2
|
+
import { i as NO_COST_CLAIM, t as ChildCostRegistry } from "../node-C0KMHgpF.mjs";
|
|
3
|
+
import { c as getStepDefinition, n as resolveFrameViewGeometry, t as localFrameRegistry } from "../local-frame-registry-Ct4YmN3z.mjs";
|
|
4
|
+
import { a as nativeLeaseSettingEnv, t as isWorkerReply } from "../worker-protocol-DGs9jUib.mjs";
|
|
5
5
|
import { t as resolveHubHostname } from "../hub-hostname-cCknRYKj.mjs";
|
|
6
6
|
import { t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
7
7
|
import { n as withDetectionIntent } from "../restream-intent-B4BXZra7.mjs";
|
package/dist/recorder/index.js
CHANGED
|
@@ -2,8 +2,8 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_dist = require("../dist-
|
|
6
|
-
const require_node = require("../node-
|
|
5
|
+
const require_dist = require("../dist-Bh1w7wfg.js");
|
|
6
|
+
const require_node = require("../node-Cl2Sjm4s.js");
|
|
7
7
|
const require_hub_hostname = require("../hub-hostname-DAJXlOgV.js");
|
|
8
8
|
const require_restream_intent = require("../restream-intent-Cv9x3jmu.js");
|
|
9
9
|
const require_event_loop_stall_monitor = require("../event-loop-stall-monitor-DaUBcb13.js");
|
package/dist/recorder/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { $ as isFirstLevelMacroClass, $t as record, B as defineCustomActions, Bt as nodePin, E as RecordingConfigSchema, Gt as _enum, It as hydrateSchema, J as evaluateSensorEdge, Kt as array, L as customAction, N as batteryCapability, Nt as DeviceFeature, Pt as DeviceType, Qt as object, T as RECORDING_EXPORT_MAX_READ_BYTES, U as deriveRecordingMode, Ut as selectAssignedProfileSlots, V as deriveBatteryPresence, Wt as sleep$1, Zt as number, bt as storageEvictableCapability, d as DEFAULT_EVENTS_BAND_BUFFER_SEC, en as string, et as loadContributionCapability, g as ExportRecordSchema, i as BatteryStatusSchema, jt as BaseAddon, mt as recordingExportCapability, nn as EventCategory, pt as recordingCapability, qt as boolean, vt as resolveRecordingProfiles, wt as errMsg, x as OpsLogEntrySchema } from "../dist-
|
|
2
|
-
import { i as NO_COST_CLAIM, t as ChildCostRegistry } from "../node-
|
|
1
|
+
import { $ as isFirstLevelMacroClass, $t as record, B as defineCustomActions, Bt as nodePin, E as RecordingConfigSchema, Gt as _enum, It as hydrateSchema, J as evaluateSensorEdge, Kt as array, L as customAction, N as batteryCapability, Nt as DeviceFeature, Pt as DeviceType, Qt as object, T as RECORDING_EXPORT_MAX_READ_BYTES, U as deriveRecordingMode, Ut as selectAssignedProfileSlots, V as deriveBatteryPresence, Wt as sleep$1, Zt as number, bt as storageEvictableCapability, d as DEFAULT_EVENTS_BAND_BUFFER_SEC, en as string, et as loadContributionCapability, g as ExportRecordSchema, i as BatteryStatusSchema, jt as BaseAddon, mt as recordingExportCapability, nn as EventCategory, pt as recordingCapability, qt as boolean, vt as resolveRecordingProfiles, wt as errMsg, x as OpsLogEntrySchema } from "../dist-DOJIQ-sh.mjs";
|
|
2
|
+
import { i as NO_COST_CLAIM, t as ChildCostRegistry } from "../node-C0KMHgpF.mjs";
|
|
3
3
|
import { t as resolveHubHostname } from "../hub-hostname-cCknRYKj.mjs";
|
|
4
4
|
import { r as withRecordingIntent } from "../restream-intent-B4BXZra7.mjs";
|
|
5
5
|
import { n as startEventLoopStallMonitor } from "../event-loop-stall-monitor-DXLNBMkY.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_dist = require("./dist-
|
|
1
|
+
const require_dist = require("./dist-Bh1w7wfg.js");
|
|
2
2
|
let node_child_process = require("node:child_process");
|
|
3
3
|
//#region ../../node_modules/mp4box/dist/mp4box.all.js
|
|
4
4
|
var require_mp4box_all = /* @__PURE__ */ require_dist.__commonJSMin(((exports) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as __toESM, t as __commonJSMin } from "./chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { wt as errMsg } from "./dist-
|
|
2
|
+
import { wt as errMsg } from "./dist-DOJIQ-sh.mjs";
|
|
3
3
|
import { spawn } from "node:child_process";
|
|
4
4
|
//#region ../../node_modules/mp4box/dist/mp4box.all.js
|
|
5
5
|
var require_mp4box_all = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_worker_protocol = require("../worker-protocol-
|
|
3
|
-
const require_lazy_sharp = require("../lazy-sharp-
|
|
2
|
+
const require_worker_protocol = require("../worker-protocol-BGRTG_GT.js");
|
|
3
|
+
const require_lazy_sharp = require("../lazy-sharp-D8FzOY6L.js");
|
|
4
4
|
//#region src/session-decode/color-conversion.ts
|
|
5
5
|
/**
|
|
6
6
|
* Explicit YUV→RGB colorspace/range resolution for the session-decode worker.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as formatNativeLeaseKnobs, n as isWorkerRequest, o as resolveNativeLeaseKnobs, r as logLevelForLine } from "../worker-protocol-
|
|
1
|
+
import { i as formatNativeLeaseKnobs, n as isWorkerRequest, o as resolveNativeLeaseKnobs, r as logLevelForLine } from "../worker-protocol-DGs9jUib.mjs";
|
|
2
2
|
import { n as setSharpWarnSink, r as hostExternalEntryUrls, t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
3
3
|
//#region src/session-decode/color-conversion.ts
|
|
4
4
|
/**
|
|
@@ -3,7 +3,7 @@ import "./dist-CYZr2fwk.mjs";
|
|
|
3
3
|
var e = {
|
|
4
4
|
"@camstack/sdk": {
|
|
5
5
|
name: "@camstack/sdk",
|
|
6
|
-
version: "1.2.
|
|
6
|
+
version: "1.2.68",
|
|
7
7
|
scope: ["default"],
|
|
8
8
|
loaded: !1,
|
|
9
9
|
from: "addon_stream_broker_widgets",
|
|
@@ -18,7 +18,7 @@ var e = {
|
|
|
18
18
|
},
|
|
19
19
|
"@camstack/types": {
|
|
20
20
|
name: "@camstack/types",
|
|
21
|
-
version: "1.2.
|
|
21
|
+
version: "1.2.148",
|
|
22
22
|
scope: ["default"],
|
|
23
23
|
loaded: !1,
|
|
24
24
|
from: "addon_stream_broker_widgets",
|
|
@@ -33,7 +33,7 @@ var e = {
|
|
|
33
33
|
},
|
|
34
34
|
"@camstack/ui-library": {
|
|
35
35
|
name: "@camstack/ui-library",
|
|
36
|
-
version: "1.2.
|
|
36
|
+
version: "1.2.114",
|
|
37
37
|
scope: ["default"],
|
|
38
38
|
loaded: !1,
|
|
39
39
|
from: "addon_stream_broker_widgets",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_segment_demux_js = require("../segment-demux-js-
|
|
1
|
+
const require_segment_demux_js = require("../segment-demux-js-BI5iWBgx.js");
|
|
2
2
|
let node_worker_threads = require("node:worker_threads");
|
|
3
3
|
//#region src/stream-broker/recorded/demux-worker-child.ts
|
|
4
4
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as demuxSegmentFullJs } from "../segment-demux-js-
|
|
1
|
+
import { t as demuxSegmentFullJs } from "../segment-demux-js-BtZ8kfA2.mjs";
|
|
2
2
|
import { parentPort } from "node:worker_threads";
|
|
3
3
|
//#region src/stream-broker/recorded/demux-worker-child.ts
|
|
4
4
|
/**
|
|
@@ -36,7 +36,7 @@ async function r() {
|
|
|
36
36
|
}
|
|
37
37
|
},
|
|
38
38
|
"@camstack/types": {
|
|
39
|
-
version: "1.2.
|
|
39
|
+
version: "1.2.148",
|
|
40
40
|
scope: "default",
|
|
41
41
|
shareConfig: {
|
|
42
42
|
singleton: !0,
|
|
@@ -45,7 +45,7 @@ async function r() {
|
|
|
45
45
|
}
|
|
46
46
|
},
|
|
47
47
|
"@camstack/sdk": {
|
|
48
|
-
version: "1.2.
|
|
48
|
+
version: "1.2.68",
|
|
49
49
|
scope: "default",
|
|
50
50
|
shareConfig: {
|
|
51
51
|
singleton: !0,
|
|
@@ -81,7 +81,7 @@ async function r() {
|
|
|
81
81
|
}
|
|
82
82
|
},
|
|
83
83
|
"@camstack/ui-library": {
|
|
84
|
-
version: "1.2.
|
|
84
|
+
version: "1.2.114",
|
|
85
85
|
scope: "default",
|
|
86
86
|
shareConfig: {
|
|
87
87
|
singleton: !0,
|
|
@@ -2,12 +2,12 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_dist = require("../dist-
|
|
6
|
-
const require_node = require("../node-
|
|
5
|
+
const require_dist = require("../dist-Bh1w7wfg.js");
|
|
6
|
+
const require_node = require("../node-Cl2Sjm4s.js");
|
|
7
7
|
const require_restream_intent = require("../restream-intent-Cv9x3jmu.js");
|
|
8
8
|
const require_remote_restream = require("../remote-restream-CO36Sr30.js");
|
|
9
9
|
const require_retire_root_keys = require("../retire-root-keys-KE6D6Xh_.js");
|
|
10
|
-
const require_segment_demux_js = require("../segment-demux-js-
|
|
10
|
+
const require_segment_demux_js = require("../segment-demux-js-BI5iWBgx.js");
|
|
11
11
|
let node_crypto = require("node:crypto");
|
|
12
12
|
node_crypto = require_dist.__toESM(node_crypto);
|
|
13
13
|
let node_fs = require("node:fs");
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { r as __toESM } from "../chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { $t as record, At as BOOT_RECOVERY_BACKOFF_MS, Bt as nodePin, C as RATE_CONTROL_RELAXED, Ct as webrtcSessionCapability, D as RingBuffer, Dt as buildFfmpegArgs$1, F as createHwAccelCache, Ft as createEvent, G as egressTranscodeSharingKey, Gt as _enum, Ht as parseProfileBrokerId, I as createLogChannelsProvider, Jt as discriminatedUnion, K as egressTransportFromRequest, Kt as array, Lt as isEvent, Mt as CAM_PROFILE_ORDER, N as batteryCapability, Nt as DeviceFeature, Ot as invocationFromEncodeProfile, P as cameraStreamsCapability, Pt as DeviceType, Qt as object, R as declareLogChannel, Rt as makeProfileBrokerId, Tt as AUDIO_PRESETS, V as deriveBatteryPresence, Xt as literal, Zt as number, en as string, et as loadContributionCapability, gt as resolveEgressDecodeHwAccel, h as EncodeProfileSchema, i as BatteryStatusSchema, jt as BaseAddon, k as addonWidgetsSourceCapability, kt as isSoftwareDecode, nn as EventCategory, qt as boolean, rt as maskUrlCredentials, tn as union, tt as logChannelsCapability, w as RATE_CONTROL_TIGHT, wt as errMsg, xt as streamBrokerCapability, zt as makeSourceBrokerId } from "../dist-
|
|
3
|
-
import { i as NO_COST_CLAIM, n as Fmp4FragmentChild, r as Fmp4FragmentPlane, t as ChildCostRegistry } from "../node-
|
|
2
|
+
import { $t as record, At as BOOT_RECOVERY_BACKOFF_MS, Bt as nodePin, C as RATE_CONTROL_RELAXED, Ct as webrtcSessionCapability, D as RingBuffer, Dt as buildFfmpegArgs$1, F as createHwAccelCache, Ft as createEvent, G as egressTranscodeSharingKey, Gt as _enum, Ht as parseProfileBrokerId, I as createLogChannelsProvider, Jt as discriminatedUnion, K as egressTransportFromRequest, Kt as array, Lt as isEvent, Mt as CAM_PROFILE_ORDER, N as batteryCapability, Nt as DeviceFeature, Ot as invocationFromEncodeProfile, P as cameraStreamsCapability, Pt as DeviceType, Qt as object, R as declareLogChannel, Rt as makeProfileBrokerId, Tt as AUDIO_PRESETS, V as deriveBatteryPresence, Xt as literal, Zt as number, en as string, et as loadContributionCapability, gt as resolveEgressDecodeHwAccel, h as EncodeProfileSchema, i as BatteryStatusSchema, jt as BaseAddon, k as addonWidgetsSourceCapability, kt as isSoftwareDecode, nn as EventCategory, qt as boolean, rt as maskUrlCredentials, tn as union, tt as logChannelsCapability, w as RATE_CONTROL_TIGHT, wt as errMsg, xt as streamBrokerCapability, zt as makeSourceBrokerId } from "../dist-DOJIQ-sh.mjs";
|
|
3
|
+
import { i as NO_COST_CLAIM, n as Fmp4FragmentChild, r as Fmp4FragmentPlane, t as ChildCostRegistry } from "../node-C0KMHgpF.mjs";
|
|
4
4
|
import { t as parseRestreamPath } from "../restream-intent-B4BXZra7.mjs";
|
|
5
5
|
import { n as profileForStreamId } from "../remote-restream-BeHi78PZ.mjs";
|
|
6
6
|
import { n as RowMapStore, t as retireRootKeys } from "../retire-root-keys-DMolfhsP.mjs";
|
|
7
|
-
import { i as require_mp4box_all, n as demuxSegmentPreferJs, r as runFfmpegOnce, t as demuxSegmentFullJs } from "../segment-demux-js-
|
|
7
|
+
import { i as require_mp4box_all, n as demuxSegmentPreferJs, r as runFfmpegOnce, t as demuxSegmentFullJs } from "../segment-demux-js-BtZ8kfA2.mjs";
|
|
8
8
|
import { createRequire } from "node:module";
|
|
9
9
|
import * as crypto$1 from "node:crypto";
|
|
10
10
|
import crypto, { createHash, randomBytes, randomUUID } from "node:crypto";
|
|
@@ -30,7 +30,7 @@ async function d(e) {
|
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
32
|
async function f() {
|
|
33
|
-
return l ||= d(() => import("./_virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-
|
|
33
|
+
return l ||= d(() => import("./_virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-U-2ES6SY.mjs")).catch((e) => {
|
|
34
34
|
throw l = void 0, e;
|
|
35
35
|
}), l;
|
|
36
36
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { b as NativeLeaseSettingsSchema, p as DEFAULT_NATIVE_LEASE_SETTINGS, y as NativeLeaseAdmissionSchema } from "./dist-
|
|
1
|
+
import { b as NativeLeaseSettingsSchema, p as DEFAULT_NATIVE_LEASE_SETTINGS, y as NativeLeaseAdmissionSchema } from "./dist-DOJIQ-sh.mjs";
|
|
2
2
|
//#region src/session-decode/native-lease-config.ts
|
|
3
3
|
/**
|
|
4
4
|
* Resolution of the native-frame hold / tile knobs for one decode worker.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camstack/addon-pipeline",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.181",
|
|
4
4
|
"description": "Pipeline bundle — runner, detection, motion, audio + stream broker. Multi-entry npm package shipping pipeline addons under a single bundle.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"camstack",
|