@camstack/types 0.1.7 → 0.1.10
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/__tests__/addon-capability-provider.test.d.ts +2 -0
- package/dist/__tests__/addon-capability-provider.test.d.ts.map +1 -0
- package/dist/__tests__/addon-declaration.test.d.ts +2 -0
- package/dist/__tests__/addon-declaration.test.d.ts.map +1 -0
- package/dist/__tests__/capability.test.d.ts +2 -0
- package/dist/__tests__/capability.test.d.ts.map +1 -0
- package/dist/catalogs/coco-classmap.d.ts +5 -0
- package/dist/catalogs/coco-classmap.d.ts.map +1 -0
- package/dist/catalogs/index.d.ts +2 -0
- package/dist/catalogs/index.d.ts.map +1 -0
- package/dist/constants.d.ts +3 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/generated/addon-api.d.ts +4974 -0
- package/dist/generated/addon-api.d.ts.map +1 -0
- package/dist/index.d.ts +82 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +550 -744
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +529 -777
- package/dist/index.mjs.map +1 -1
- package/dist/interfaces/addon-i18n.d.ts +41 -0
- package/dist/interfaces/addon-i18n.d.ts.map +1 -0
- package/dist/interfaces/addon-routes.d.ts +50 -0
- package/dist/interfaces/addon-routes.d.ts.map +1 -0
- package/dist/interfaces/addon.d.ts +294 -0
- package/dist/interfaces/addon.d.ts.map +1 -0
- package/dist/interfaces/advanced-notifier.d.ts +59 -0
- package/dist/interfaces/advanced-notifier.d.ts.map +1 -0
- package/dist/interfaces/agent-protocol.d.ts +189 -0
- package/dist/interfaces/agent-protocol.d.ts.map +1 -0
- package/dist/interfaces/agent.d.ts +87 -0
- package/dist/interfaces/agent.d.ts.map +1 -0
- package/dist/interfaces/analysis-persistence.d.ts +278 -0
- package/dist/interfaces/analysis-persistence.d.ts.map +1 -0
- package/dist/interfaces/analysis.d.ts +27 -0
- package/dist/interfaces/analysis.d.ts.map +1 -0
- package/dist/interfaces/api-shared.d.ts +176 -0
- package/dist/interfaces/api-shared.d.ts.map +1 -0
- package/dist/interfaces/auth-provider.d.ts +39 -0
- package/dist/interfaces/auth-provider.d.ts.map +1 -0
- package/dist/interfaces/auth.d.ts +47 -0
- package/dist/interfaces/auth.d.ts.map +1 -0
- package/dist/interfaces/camera-pipeline.d.ts +121 -0
- package/dist/interfaces/camera-pipeline.d.ts.map +1 -0
- package/dist/interfaces/capability.d.ts +84 -0
- package/dist/interfaces/capability.d.ts.map +1 -0
- package/dist/interfaces/classifier.d.ts +8 -0
- package/dist/interfaces/classifier.d.ts.map +1 -0
- package/dist/interfaces/config-ui.d.ts +152 -0
- package/dist/interfaces/config-ui.d.ts.map +1 -0
- package/dist/interfaces/context.d.ts +44 -0
- package/dist/interfaces/context.d.ts.map +1 -0
- package/dist/interfaces/cropper.d.ts +8 -0
- package/dist/interfaces/cropper.d.ts.map +1 -0
- package/dist/interfaces/decoder.d.ts +27 -0
- package/dist/interfaces/decoder.d.ts.map +1 -0
- package/dist/interfaces/detection-addon.d.ts +15 -0
- package/dist/interfaces/detection-addon.d.ts.map +1 -0
- package/dist/interfaces/detector.d.ts +8 -0
- package/dist/interfaces/detector.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/accessory.d.ts +14 -0
- package/dist/interfaces/device-capabilities/accessory.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/audio-detector.d.ts +12 -0
- package/dist/interfaces/device-capabilities/audio-detector.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/camera.d.ts +22 -0
- package/dist/interfaces/device-capabilities/camera.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/doorbell.d.ts +10 -0
- package/dist/interfaces/device-capabilities/doorbell.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/events.d.ts +47 -0
- package/dist/interfaces/device-capabilities/events.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/index.d.ts +15 -0
- package/dist/interfaces/device-capabilities/index.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/motion-sensor.d.ts +7 -0
- package/dist/interfaces/device-capabilities/motion-sensor.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/native-detection.d.ts +14 -0
- package/dist/interfaces/device-capabilities/native-detection.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/object-detector.d.ts +59 -0
- package/dist/interfaces/device-capabilities/object-detector.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/pan-tilt-zoom.d.ts +29 -0
- package/dist/interfaces/device-capabilities/pan-tilt-zoom.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/recording.d.ts +18 -0
- package/dist/interfaces/device-capabilities/recording.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/siren.d.ts +8 -0
- package/dist/interfaces/device-capabilities/siren.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/status-light.d.ts +7 -0
- package/dist/interfaces/device-capabilities/status-light.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/switch.d.ts +8 -0
- package/dist/interfaces/device-capabilities/switch.d.ts.map +1 -0
- package/dist/interfaces/device-capabilities/two-way-audio.d.ts +8 -0
- package/dist/interfaces/device-capabilities/two-way-audio.d.ts.map +1 -0
- package/dist/interfaces/device-capability.d.ts +14 -0
- package/dist/interfaces/device-capability.d.ts.map +1 -0
- package/dist/interfaces/device-provider.d.ts +43 -0
- package/dist/interfaces/device-provider.d.ts.map +1 -0
- package/dist/interfaces/device.d.ts +40 -0
- package/dist/interfaces/device.d.ts.map +1 -0
- package/dist/interfaces/event-bus.d.ts +244 -0
- package/dist/interfaces/event-bus.d.ts.map +1 -0
- package/dist/interfaces/feature-flags.d.ts +14 -0
- package/dist/interfaces/feature-flags.d.ts.map +1 -0
- package/dist/interfaces/ffmpeg.d.ts +10 -0
- package/dist/interfaces/ffmpeg.d.ts.map +1 -0
- package/dist/interfaces/inference-capabilities.d.ts +101 -0
- package/dist/interfaces/inference-capabilities.d.ts.map +1 -0
- package/dist/interfaces/inference-engine.d.ts +17 -0
- package/dist/interfaces/inference-engine.d.ts.map +1 -0
- package/dist/interfaces/lifecycle.d.ts +19 -0
- package/dist/interfaces/lifecycle.d.ts.map +1 -0
- package/dist/interfaces/logging.d.ts +33 -0
- package/dist/interfaces/logging.d.ts.map +1 -0
- package/dist/interfaces/model-catalog.d.ts +25 -0
- package/dist/interfaces/model-catalog.d.ts.map +1 -0
- package/dist/interfaces/network-quality.d.ts +25 -0
- package/dist/interfaces/network-quality.d.ts.map +1 -0
- package/dist/interfaces/network.d.ts +43 -0
- package/dist/interfaces/network.d.ts.map +1 -0
- package/dist/interfaces/notification.d.ts +53 -0
- package/dist/interfaces/notification.d.ts.map +1 -0
- package/dist/interfaces/pipeline-runner.d.ts +23 -0
- package/dist/interfaces/pipeline-runner.d.ts.map +1 -0
- package/dist/interfaces/pipeline-slot.d.ts +10 -0
- package/dist/interfaces/pipeline-slot.d.ts.map +1 -0
- package/dist/interfaces/platform.d.ts +55 -0
- package/dist/interfaces/platform.d.ts.map +1 -0
- package/dist/interfaces/process.d.ts +41 -0
- package/dist/interfaces/process.d.ts.map +1 -0
- package/dist/interfaces/python-env.d.ts +20 -0
- package/dist/interfaces/python-env.d.ts.map +1 -0
- package/dist/interfaces/refiner.d.ts +8 -0
- package/dist/interfaces/refiner.d.ts.map +1 -0
- package/dist/interfaces/repl.d.ts +26 -0
- package/dist/interfaces/repl.d.ts.map +1 -0
- package/dist/interfaces/repositories.d.ts +20 -0
- package/dist/interfaces/repositories.d.ts.map +1 -0
- package/dist/interfaces/restreamer.d.ts +24 -0
- package/dist/interfaces/restreamer.d.ts.map +1 -0
- package/dist/interfaces/router.d.ts +30 -0
- package/dist/interfaces/router.d.ts.map +1 -0
- package/dist/interfaces/scene-intelligence.d.ts +21 -0
- package/dist/interfaces/scene-intelligence.d.ts.map +1 -0
- package/dist/interfaces/scoped-token.d.ts +22 -0
- package/dist/interfaces/scoped-token.d.ts.map +1 -0
- package/dist/interfaces/server-analysis.d.ts +146 -0
- package/dist/interfaces/server-analysis.d.ts.map +1 -0
- package/dist/interfaces/server-network.d.ts +78 -0
- package/dist/interfaces/server-network.d.ts.map +1 -0
- package/dist/interfaces/storage-backend.d.ts +27 -0
- package/dist/interfaces/storage-backend.d.ts.map +1 -0
- package/dist/interfaces/storage.d.ts +174 -0
- package/dist/interfaces/storage.d.ts.map +1 -0
- package/dist/interfaces/stream-broker.d.ts +92 -0
- package/dist/interfaces/stream-broker.d.ts.map +1 -0
- package/dist/interfaces/streaming.d.ts +29 -0
- package/dist/interfaces/streaming.d.ts.map +1 -0
- package/dist/interfaces/task-handler.d.ts +46 -0
- package/dist/interfaces/task-handler.d.ts.map +1 -0
- package/dist/interfaces/webrtc-provider.d.ts +11 -0
- package/dist/interfaces/webrtc-provider.d.ts.map +1 -0
- package/dist/interfaces/worker-protocol.d.ts +110 -0
- package/dist/interfaces/worker-protocol.d.ts.map +1 -0
- package/dist/schemas/system-settings-schemas.d.ts +27 -0
- package/dist/schemas/system-settings-schemas.d.ts.map +1 -0
- package/dist/types/analytics.d.ts +75 -0
- package/dist/types/analytics.d.ts.map +1 -0
- package/dist/types/benchmark.d.ts +112 -0
- package/dist/types/benchmark.d.ts.map +1 -0
- package/dist/types/camera-detection.d.ts +34 -0
- package/dist/types/camera-detection.d.ts.map +1 -0
- package/dist/types/config.d.ts +37 -0
- package/dist/types/config.d.ts.map +1 -0
- package/dist/types/detection.d.ts +93 -0
- package/dist/types/detection.d.ts.map +1 -0
- package/dist/types/device-type.d.ts +10 -0
- package/dist/types/device-type.d.ts.map +1 -0
- package/dist/types/entities.d.ts +35 -0
- package/dist/types/entities.d.ts.map +1 -0
- package/dist/types/events.d.ts +35 -0
- package/dist/types/events.d.ts.map +1 -0
- package/dist/types/io.d.ts +25 -0
- package/dist/types/io.d.ts.map +1 -0
- package/dist/types/labels.d.ts +12 -0
- package/dist/types/labels.d.ts.map +1 -0
- package/dist/types/live-state.d.ts +47 -0
- package/dist/types/live-state.d.ts.map +1 -0
- package/dist/types/models.d.ts +79 -0
- package/dist/types/models.d.ts.map +1 -0
- package/dist/types/pipeline-schema.d.ts +78 -0
- package/dist/types/pipeline-schema.d.ts.map +1 -0
- package/dist/types/pipeline.d.ts +42 -0
- package/dist/types/pipeline.d.ts.map +1 -0
- package/dist/types/tracked.d.ts +21 -0
- package/dist/types/tracked.d.ts.map +1 -0
- package/dist/types/zones.d.ts +48 -0
- package/dist/types/zones.d.ts.map +1 -0
- package/dist/utils/cosine-similarity.d.ts +3 -0
- package/dist/utils/cosine-similarity.d.ts.map +1 -0
- package/dist/utils/hf-url.d.ts +2 -0
- package/dist/utils/hf-url.d.ts.map +1 -0
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -1,13 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
2
|
var __defProp = Object.defineProperty;
|
|
4
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
9
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
10
|
-
};
|
|
11
6
|
var __export = (target, all) => {
|
|
12
7
|
for (var name in all)
|
|
13
8
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
@@ -20,801 +15,612 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
20
15
|
}
|
|
21
16
|
return to;
|
|
22
17
|
};
|
|
23
|
-
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
24
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
25
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
26
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
27
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
28
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
29
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
30
|
-
mod
|
|
31
|
-
));
|
|
32
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
33
19
|
|
|
34
|
-
// src/
|
|
35
|
-
var
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
"use strict";
|
|
62
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
63
|
-
}
|
|
64
|
-
});
|
|
65
|
-
|
|
66
|
-
// src/types/events.js
|
|
67
|
-
var require_events = __commonJS({
|
|
68
|
-
"src/types/events.js"(exports2) {
|
|
69
|
-
"use strict";
|
|
70
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
71
|
-
}
|
|
72
|
-
});
|
|
73
|
-
|
|
74
|
-
// src/types/config.js
|
|
75
|
-
var require_config = __commonJS({
|
|
76
|
-
"src/types/config.js"(exports2) {
|
|
77
|
-
"use strict";
|
|
78
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
79
|
-
}
|
|
20
|
+
// src/index.ts
|
|
21
|
+
var src_exports = {};
|
|
22
|
+
__export(src_exports, {
|
|
23
|
+
BINARY_FRAME_HEADER_SIZE: () => BINARY_FRAME_HEADER_SIZE,
|
|
24
|
+
BINARY_FRAME_TYPE: () => BINARY_FRAME_TYPE,
|
|
25
|
+
COCO_80_LABELS: () => COCO_80_LABELS,
|
|
26
|
+
COCO_TO_MACRO: () => COCO_TO_MACRO,
|
|
27
|
+
DEFAULT_FEATURES: () => DEFAULT_FEATURES,
|
|
28
|
+
DEFAULT_LOCATION_SUBPATHS: () => DEFAULT_LOCATION_SUBPATHS,
|
|
29
|
+
DEFAULT_RETENTION: () => DEFAULT_RETENTION,
|
|
30
|
+
DETECTION_TYPES: () => DETECTION_TYPES,
|
|
31
|
+
DEVICE_TYPE_INFO: () => DEVICE_TYPE_INFO,
|
|
32
|
+
DeviceType: () => DeviceType,
|
|
33
|
+
HF_BASE_URL: () => HF_BASE_URL,
|
|
34
|
+
HF_REPO: () => HF_REPO,
|
|
35
|
+
MACRO_LABELS: () => MACRO_LABELS,
|
|
36
|
+
READ_ONLY_SECTIONS: () => READ_ONLY_SECTIONS,
|
|
37
|
+
RECOGNITION_TYPES: () => RECOGNITION_TYPES,
|
|
38
|
+
SETTINGS_TABS: () => SETTINGS_TABS,
|
|
39
|
+
SUB_DETECTION_TYPES: () => SUB_DETECTION_TYPES,
|
|
40
|
+
SYSTEM_SETTINGS_SCHEMAS: () => SYSTEM_SETTINGS_SCHEMAS,
|
|
41
|
+
cosineSimilarity: () => cosineSimilarity,
|
|
42
|
+
createAnalysisContext: () => createAnalysisContext,
|
|
43
|
+
enrichContext: () => enrichContext,
|
|
44
|
+
getSystemSettingsSchema: () => getSystemSettingsSchema,
|
|
45
|
+
hfModelUrl: () => hfModelUrl,
|
|
46
|
+
resolveTranslation: () => resolveTranslation
|
|
80
47
|
});
|
|
48
|
+
module.exports = __toCommonJS(src_exports);
|
|
81
49
|
|
|
82
|
-
// src/
|
|
83
|
-
var
|
|
84
|
-
"
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
50
|
+
// src/interfaces/storage-backend.ts
|
|
51
|
+
var DEFAULT_LOCATION_SUBPATHS = {
|
|
52
|
+
"recordings-high": "recordings-high",
|
|
53
|
+
"recordings-low": "recordings-low",
|
|
54
|
+
"recordings-clips": "recordings-clips",
|
|
55
|
+
"event-images": "event-images",
|
|
56
|
+
"models": "models",
|
|
57
|
+
"addons-data": "addons-data",
|
|
58
|
+
"cache": "/tmp/camstack-cache",
|
|
59
|
+
"logs": "logs"
|
|
60
|
+
};
|
|
89
61
|
|
|
90
|
-
// src/
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
62
|
+
// src/interfaces/addon-i18n.ts
|
|
63
|
+
function resolveTranslation(provider, locale, key) {
|
|
64
|
+
if (provider.getTranslations) {
|
|
65
|
+
const map = provider.getTranslations(locale);
|
|
66
|
+
if (map && key in map) return map[key];
|
|
67
|
+
if (locale !== "en") {
|
|
68
|
+
const fallback = provider.getTranslations("en");
|
|
69
|
+
if (fallback && key in fallback) return fallback[key];
|
|
70
|
+
}
|
|
95
71
|
}
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
72
|
+
if (provider.getTranslationBundle) {
|
|
73
|
+
const bundle = provider.getTranslationBundle();
|
|
74
|
+
const map = bundle[locale];
|
|
75
|
+
if (map && key in map) return map[key];
|
|
76
|
+
if (locale !== "en") {
|
|
77
|
+
const fallback = bundle["en"];
|
|
78
|
+
if (fallback && key in fallback) return fallback[key];
|
|
79
|
+
}
|
|
103
80
|
}
|
|
104
|
-
|
|
81
|
+
return key;
|
|
82
|
+
}
|
|
105
83
|
|
|
106
|
-
// src/
|
|
107
|
-
var
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
84
|
+
// src/interfaces/feature-flags.ts
|
|
85
|
+
var DEFAULT_FEATURES = {
|
|
86
|
+
streaming: true,
|
|
87
|
+
notifications: true,
|
|
88
|
+
objectDetection: false,
|
|
89
|
+
remoteAccess: true,
|
|
90
|
+
agentCluster: false,
|
|
91
|
+
smartHome: true,
|
|
92
|
+
recordings: true,
|
|
93
|
+
backup: true,
|
|
94
|
+
repl: true
|
|
95
|
+
};
|
|
113
96
|
|
|
114
|
-
// src/
|
|
115
|
-
var
|
|
116
|
-
|
|
117
|
-
"use strict";
|
|
118
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
119
|
-
}
|
|
120
|
-
});
|
|
97
|
+
// src/interfaces/agent-protocol.ts
|
|
98
|
+
var BINARY_FRAME_HEADER_SIZE = 29;
|
|
99
|
+
var BINARY_FRAME_TYPE = 1;
|
|
121
100
|
|
|
122
|
-
// src/
|
|
123
|
-
var
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
101
|
+
// src/interfaces/server-analysis.ts
|
|
102
|
+
var DETECTION_TYPES = ["person", "vehicle", "animal", "package"];
|
|
103
|
+
var SUB_DETECTION_TYPES = ["face", "plate"];
|
|
104
|
+
var RECOGNITION_TYPES = ["face", "plate", "clip", "custom"];
|
|
105
|
+
function createAnalysisContext(deviceId, frame, rawDetections) {
|
|
106
|
+
return {
|
|
107
|
+
deviceId,
|
|
108
|
+
frame,
|
|
109
|
+
timestamp: frame.timestamp,
|
|
110
|
+
rawDetections,
|
|
111
|
+
trackedDetections: [],
|
|
112
|
+
events: [],
|
|
113
|
+
metadata: {}
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
function enrichContext(ctx, updates) {
|
|
117
|
+
return {
|
|
118
|
+
...ctx,
|
|
119
|
+
trackedDetections: updates.trackedDetections ?? ctx.trackedDetections,
|
|
120
|
+
events: updates.events ?? ctx.events,
|
|
121
|
+
metadata: updates.metadata ? { ...ctx.metadata, ...updates.metadata } : ctx.metadata
|
|
122
|
+
};
|
|
123
|
+
}
|
|
129
124
|
|
|
130
|
-
// src/interfaces/
|
|
131
|
-
var
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
"recordings-high": "recordings-high",
|
|
138
|
-
"recordings-low": "recordings-low",
|
|
139
|
-
"recordings-clips": "recordings-clips",
|
|
140
|
-
"event-images": "event-images",
|
|
141
|
-
"models": "models",
|
|
142
|
-
"addons-data": "addons-data",
|
|
143
|
-
"cache": "/tmp/camstack-cache",
|
|
144
|
-
"logs": "logs"
|
|
145
|
-
};
|
|
146
|
-
}
|
|
147
|
-
});
|
|
125
|
+
// src/interfaces/analysis-persistence.ts
|
|
126
|
+
var DEFAULT_RETENTION = {
|
|
127
|
+
cleanupIntervalMs: 60 * 60 * 1e3,
|
|
128
|
+
detectionEventsDays: 30,
|
|
129
|
+
audioLevelsDays: 7,
|
|
130
|
+
snapshotsDays: 14
|
|
131
|
+
};
|
|
148
132
|
|
|
149
|
-
// src/
|
|
150
|
-
var
|
|
151
|
-
"
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
133
|
+
// src/schemas/system-settings-schemas.ts
|
|
134
|
+
var READ_ONLY_SECTIONS = /* @__PURE__ */ new Set([
|
|
135
|
+
"server"
|
|
136
|
+
]);
|
|
137
|
+
var SETTINGS_TABS = [
|
|
138
|
+
{ id: "server", label: "Server" },
|
|
139
|
+
{ id: "logging", label: "Logs" },
|
|
140
|
+
{ id: "recording", label: "Recording" },
|
|
141
|
+
{ id: "ffmpeg", label: "FFmpeg" },
|
|
142
|
+
{ id: "detection", label: "Detection" },
|
|
143
|
+
{ id: "auth", label: "Auth" },
|
|
144
|
+
{ id: "retention", label: "Retention" }
|
|
145
|
+
];
|
|
146
|
+
var SERVER_SCHEMA = {
|
|
147
|
+
sections: [
|
|
148
|
+
{
|
|
149
|
+
id: "server-info",
|
|
150
|
+
title: "Server",
|
|
151
|
+
description: "Core server connection settings (read-only)",
|
|
152
|
+
columns: 2,
|
|
153
|
+
fields: [
|
|
154
|
+
{
|
|
155
|
+
type: "info",
|
|
156
|
+
key: "server-restart-note",
|
|
157
|
+
label: "Restart required",
|
|
158
|
+
content: "Server settings are read-only. Change them in config.yaml and restart.",
|
|
159
|
+
variant: "warning"
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
type: "text",
|
|
163
|
+
key: "port",
|
|
164
|
+
label: "Port",
|
|
165
|
+
disabled: true,
|
|
166
|
+
description: "Listening port"
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
type: "text",
|
|
170
|
+
key: "host",
|
|
171
|
+
label: "Host",
|
|
172
|
+
disabled: true,
|
|
173
|
+
description: "Bind address"
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
type: "text",
|
|
177
|
+
key: "dataPath",
|
|
178
|
+
label: "Data Path",
|
|
179
|
+
disabled: true,
|
|
180
|
+
description: "Root data directory",
|
|
181
|
+
span: 2
|
|
175
182
|
}
|
|
176
|
-
|
|
177
|
-
return key;
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
});
|
|
181
|
-
|
|
182
|
-
// src/interfaces/feature-flags.js
|
|
183
|
-
var require_feature_flags = __commonJS({
|
|
184
|
-
"src/interfaces/feature-flags.js"(exports2) {
|
|
185
|
-
"use strict";
|
|
186
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
187
|
-
exports2.DEFAULT_FEATURES = void 0;
|
|
188
|
-
exports2.DEFAULT_FEATURES = {
|
|
189
|
-
streaming: true,
|
|
190
|
-
notifications: true,
|
|
191
|
-
objectDetection: false,
|
|
192
|
-
remoteAccess: true,
|
|
193
|
-
agentCluster: false,
|
|
194
|
-
smartHome: true,
|
|
195
|
-
recordings: true,
|
|
196
|
-
backup: true,
|
|
197
|
-
repl: true
|
|
198
|
-
};
|
|
199
|
-
}
|
|
200
|
-
});
|
|
201
|
-
|
|
202
|
-
// src/interfaces/agent-protocol.js
|
|
203
|
-
var require_agent_protocol = __commonJS({
|
|
204
|
-
"src/interfaces/agent-protocol.js"(exports2) {
|
|
205
|
-
"use strict";
|
|
206
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
207
|
-
exports2.BINARY_FRAME_TYPE = exports2.BINARY_FRAME_HEADER_SIZE = void 0;
|
|
208
|
-
exports2.BINARY_FRAME_HEADER_SIZE = 29;
|
|
209
|
-
exports2.BINARY_FRAME_TYPE = 1;
|
|
210
|
-
}
|
|
211
|
-
});
|
|
212
|
-
|
|
213
|
-
// src/interfaces/server-analysis.js
|
|
214
|
-
var require_server_analysis = __commonJS({
|
|
215
|
-
"src/interfaces/server-analysis.js"(exports2) {
|
|
216
|
-
"use strict";
|
|
217
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
218
|
-
exports2.RECOGNITION_TYPES = exports2.SUB_DETECTION_TYPES = exports2.DETECTION_TYPES = void 0;
|
|
219
|
-
exports2.createAnalysisContext = createAnalysisContext;
|
|
220
|
-
exports2.enrichContext = enrichContext;
|
|
221
|
-
exports2.DETECTION_TYPES = ["person", "vehicle", "animal", "package"];
|
|
222
|
-
exports2.SUB_DETECTION_TYPES = ["face", "plate"];
|
|
223
|
-
exports2.RECOGNITION_TYPES = ["face", "plate", "clip", "custom"];
|
|
224
|
-
function createAnalysisContext(deviceId, frame, rawDetections) {
|
|
225
|
-
return {
|
|
226
|
-
deviceId,
|
|
227
|
-
frame,
|
|
228
|
-
timestamp: frame.timestamp,
|
|
229
|
-
rawDetections,
|
|
230
|
-
trackedDetections: [],
|
|
231
|
-
events: [],
|
|
232
|
-
metadata: {}
|
|
233
|
-
};
|
|
234
|
-
}
|
|
235
|
-
function enrichContext(ctx, updates) {
|
|
236
|
-
return {
|
|
237
|
-
...ctx,
|
|
238
|
-
trackedDetections: updates.trackedDetections ?? ctx.trackedDetections,
|
|
239
|
-
events: updates.events ?? ctx.events,
|
|
240
|
-
metadata: updates.metadata ? { ...ctx.metadata, ...updates.metadata } : ctx.metadata
|
|
241
|
-
};
|
|
183
|
+
]
|
|
242
184
|
}
|
|
243
|
-
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
snapshotsDays: 14
|
|
257
|
-
};
|
|
258
|
-
}
|
|
259
|
-
});
|
|
260
|
-
|
|
261
|
-
// src/schemas/system-settings-schemas.js
|
|
262
|
-
var require_system_settings_schemas = __commonJS({
|
|
263
|
-
"src/schemas/system-settings-schemas.js"(exports2) {
|
|
264
|
-
"use strict";
|
|
265
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
266
|
-
exports2.SYSTEM_SETTINGS_SCHEMAS = exports2.SETTINGS_TABS = exports2.READ_ONLY_SECTIONS = void 0;
|
|
267
|
-
exports2.getSystemSettingsSchema = getSystemSettingsSchema;
|
|
268
|
-
exports2.READ_ONLY_SECTIONS = /* @__PURE__ */ new Set([
|
|
269
|
-
"server"
|
|
270
|
-
]);
|
|
271
|
-
exports2.SETTINGS_TABS = [
|
|
272
|
-
{ id: "server", label: "Server" },
|
|
273
|
-
{ id: "logging", label: "Logs" },
|
|
274
|
-
{ id: "recording", label: "Recording" },
|
|
275
|
-
{ id: "ffmpeg", label: "FFmpeg" },
|
|
276
|
-
{ id: "detection", label: "Detection" },
|
|
277
|
-
{ id: "auth", label: "Auth" },
|
|
278
|
-
{ id: "retention", label: "Retention" }
|
|
279
|
-
];
|
|
280
|
-
var SERVER_SCHEMA = {
|
|
281
|
-
sections: [
|
|
185
|
+
]
|
|
186
|
+
};
|
|
187
|
+
var STORAGE_SCHEMA = {
|
|
188
|
+
sections: []
|
|
189
|
+
};
|
|
190
|
+
var LOGGING_SCHEMA = {
|
|
191
|
+
sections: [
|
|
192
|
+
{
|
|
193
|
+
id: "logging-settings",
|
|
194
|
+
title: "Logging",
|
|
195
|
+
description: "Global log verbosity. Retention is managed per log-destination addon.",
|
|
196
|
+
columns: 1,
|
|
197
|
+
fields: [
|
|
282
198
|
{
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
{
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
label: "Restart required",
|
|
292
|
-
content: "Server settings are read-only. Change them in config.yaml and restart.",
|
|
293
|
-
variant: "warning"
|
|
294
|
-
},
|
|
295
|
-
{
|
|
296
|
-
type: "text",
|
|
297
|
-
key: "port",
|
|
298
|
-
label: "Port",
|
|
299
|
-
disabled: true,
|
|
300
|
-
description: "Listening port"
|
|
301
|
-
},
|
|
302
|
-
{
|
|
303
|
-
type: "text",
|
|
304
|
-
key: "host",
|
|
305
|
-
label: "Host",
|
|
306
|
-
disabled: true,
|
|
307
|
-
description: "Bind address"
|
|
308
|
-
},
|
|
309
|
-
{
|
|
310
|
-
type: "text",
|
|
311
|
-
key: "dataPath",
|
|
312
|
-
label: "Data Path",
|
|
313
|
-
disabled: true,
|
|
314
|
-
description: "Root data directory",
|
|
315
|
-
span: 2
|
|
316
|
-
}
|
|
199
|
+
type: "select",
|
|
200
|
+
key: "level",
|
|
201
|
+
label: "Log Level",
|
|
202
|
+
options: [
|
|
203
|
+
{ value: "debug", label: "Debug" },
|
|
204
|
+
{ value: "info", label: "Info" },
|
|
205
|
+
{ value: "warn", label: "Warn" },
|
|
206
|
+
{ value: "error", label: "Error" }
|
|
317
207
|
]
|
|
318
208
|
}
|
|
319
209
|
]
|
|
320
|
-
}
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
210
|
+
}
|
|
211
|
+
]
|
|
212
|
+
};
|
|
213
|
+
var RECORDING_SCHEMA = {
|
|
214
|
+
sections: [
|
|
215
|
+
{
|
|
216
|
+
id: "recording-settings",
|
|
217
|
+
title: "Recording",
|
|
218
|
+
description: "Video recording segment and retention defaults",
|
|
219
|
+
columns: 2,
|
|
220
|
+
fields: [
|
|
326
221
|
{
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
222
|
+
type: "number",
|
|
223
|
+
key: "segmentDurationSeconds",
|
|
224
|
+
label: "Segment Duration",
|
|
225
|
+
description: "Length of each recording segment",
|
|
226
|
+
min: 1,
|
|
227
|
+
max: 60,
|
|
228
|
+
step: 1,
|
|
229
|
+
unit: "seconds"
|
|
230
|
+
},
|
|
231
|
+
{
|
|
232
|
+
type: "number",
|
|
233
|
+
key: "defaultRetentionDays",
|
|
234
|
+
label: "Default Retention",
|
|
235
|
+
description: "Days to keep recordings before auto-delete",
|
|
236
|
+
min: 1,
|
|
237
|
+
max: 365,
|
|
238
|
+
step: 1,
|
|
239
|
+
unit: "days"
|
|
344
240
|
}
|
|
345
241
|
]
|
|
346
|
-
}
|
|
347
|
-
|
|
348
|
-
|
|
242
|
+
}
|
|
243
|
+
]
|
|
244
|
+
};
|
|
245
|
+
var FFMPEG_SCHEMA = {
|
|
246
|
+
sections: [
|
|
247
|
+
{
|
|
248
|
+
id: "ffmpeg-settings",
|
|
249
|
+
title: "FFmpeg",
|
|
250
|
+
description: "FFmpeg binary and hardware acceleration settings",
|
|
251
|
+
columns: 2,
|
|
252
|
+
fields: [
|
|
253
|
+
{
|
|
254
|
+
type: "text",
|
|
255
|
+
key: "binaryPath",
|
|
256
|
+
label: "Binary Path",
|
|
257
|
+
description: "Path to ffmpeg executable",
|
|
258
|
+
placeholder: "ffmpeg",
|
|
259
|
+
span: 2
|
|
260
|
+
},
|
|
349
261
|
{
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
{
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
max: 60,
|
|
362
|
-
step: 1,
|
|
363
|
-
unit: "seconds"
|
|
364
|
-
},
|
|
365
|
-
{
|
|
366
|
-
type: "number",
|
|
367
|
-
key: "defaultRetentionDays",
|
|
368
|
-
label: "Default Retention",
|
|
369
|
-
description: "Days to keep recordings before auto-delete",
|
|
370
|
-
min: 1,
|
|
371
|
-
max: 365,
|
|
372
|
-
step: 1,
|
|
373
|
-
unit: "days"
|
|
374
|
-
}
|
|
262
|
+
type: "select",
|
|
263
|
+
key: "hwAccel",
|
|
264
|
+
label: "Hardware Acceleration",
|
|
265
|
+
description: "GPU decoding/encoding backend",
|
|
266
|
+
options: [
|
|
267
|
+
{ value: "auto", label: "Auto-detect" },
|
|
268
|
+
{ value: "none", label: "None (CPU only)" },
|
|
269
|
+
{ value: "videotoolbox", label: "VideoToolbox (macOS)" },
|
|
270
|
+
{ value: "vaapi", label: "VA-API (Linux Intel/AMD)" },
|
|
271
|
+
{ value: "qsv", label: "QSV (Intel Quick Sync)" },
|
|
272
|
+
{ value: "cuda", label: "CUDA (NVIDIA)" }
|
|
375
273
|
]
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
type: "number",
|
|
277
|
+
key: "threadCount",
|
|
278
|
+
label: "Thread Count",
|
|
279
|
+
description: "0 = auto (let FFmpeg decide)",
|
|
280
|
+
min: 0,
|
|
281
|
+
max: 16,
|
|
282
|
+
step: 1
|
|
376
283
|
}
|
|
377
284
|
]
|
|
378
|
-
}
|
|
379
|
-
|
|
380
|
-
|
|
285
|
+
}
|
|
286
|
+
]
|
|
287
|
+
};
|
|
288
|
+
var DETECTION_SCHEMA = {
|
|
289
|
+
sections: [
|
|
290
|
+
{
|
|
291
|
+
id: "detection-fps",
|
|
292
|
+
title: "Frame Rates",
|
|
293
|
+
description: "Default analysis frame rates for new cameras",
|
|
294
|
+
columns: 2,
|
|
295
|
+
fields: [
|
|
381
296
|
{
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
options: [
|
|
401
|
-
{ value: "auto", label: "Auto-detect" },
|
|
402
|
-
{ value: "none", label: "None (CPU only)" },
|
|
403
|
-
{ value: "videotoolbox", label: "VideoToolbox (macOS)" },
|
|
404
|
-
{ value: "vaapi", label: "VA-API (Linux Intel/AMD)" },
|
|
405
|
-
{ value: "qsv", label: "QSV (Intel Quick Sync)" },
|
|
406
|
-
{ value: "cuda", label: "CUDA (NVIDIA)" }
|
|
407
|
-
]
|
|
408
|
-
},
|
|
409
|
-
{
|
|
410
|
-
type: "number",
|
|
411
|
-
key: "threadCount",
|
|
412
|
-
label: "Thread Count",
|
|
413
|
-
description: "0 = auto (let FFmpeg decide)",
|
|
414
|
-
min: 0,
|
|
415
|
-
max: 16,
|
|
416
|
-
step: 1
|
|
417
|
-
}
|
|
418
|
-
]
|
|
297
|
+
type: "number",
|
|
298
|
+
key: "defaultMotionFps",
|
|
299
|
+
label: "Motion FPS",
|
|
300
|
+
description: "Frames per second for motion detection",
|
|
301
|
+
min: 1,
|
|
302
|
+
max: 30,
|
|
303
|
+
step: 1,
|
|
304
|
+
unit: "fps"
|
|
305
|
+
},
|
|
306
|
+
{
|
|
307
|
+
type: "number",
|
|
308
|
+
key: "defaultDetectionFps",
|
|
309
|
+
label: "Detection FPS",
|
|
310
|
+
description: "Frames per second for object detection",
|
|
311
|
+
min: 1,
|
|
312
|
+
max: 30,
|
|
313
|
+
step: 1,
|
|
314
|
+
unit: "fps"
|
|
419
315
|
}
|
|
420
316
|
]
|
|
421
|
-
}
|
|
422
|
-
|
|
423
|
-
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
id: "detection-thresholds",
|
|
320
|
+
title: "Thresholds",
|
|
321
|
+
description: "Default confidence and cooldown for detections",
|
|
322
|
+
columns: 2,
|
|
323
|
+
fields: [
|
|
424
324
|
{
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
label: "Motion FPS",
|
|
434
|
-
description: "Frames per second for motion detection",
|
|
435
|
-
min: 1,
|
|
436
|
-
max: 30,
|
|
437
|
-
step: 1,
|
|
438
|
-
unit: "fps"
|
|
439
|
-
},
|
|
440
|
-
{
|
|
441
|
-
type: "number",
|
|
442
|
-
key: "defaultDetectionFps",
|
|
443
|
-
label: "Detection FPS",
|
|
444
|
-
description: "Frames per second for object detection",
|
|
445
|
-
min: 1,
|
|
446
|
-
max: 30,
|
|
447
|
-
step: 1,
|
|
448
|
-
unit: "fps"
|
|
449
|
-
}
|
|
450
|
-
]
|
|
325
|
+
type: "slider",
|
|
326
|
+
key: "defaultConfidenceThreshold",
|
|
327
|
+
label: "Confidence Threshold",
|
|
328
|
+
description: "Minimum confidence to trigger a detection event",
|
|
329
|
+
min: 0.1,
|
|
330
|
+
max: 1,
|
|
331
|
+
step: 0.05,
|
|
332
|
+
showValue: true
|
|
451
333
|
},
|
|
452
334
|
{
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
335
|
+
type: "number",
|
|
336
|
+
key: "defaultCooldownSeconds",
|
|
337
|
+
label: "Cooldown",
|
|
338
|
+
description: "Seconds between duplicate events",
|
|
339
|
+
min: 0,
|
|
340
|
+
max: 300,
|
|
341
|
+
step: 1,
|
|
342
|
+
unit: "seconds"
|
|
343
|
+
}
|
|
344
|
+
]
|
|
345
|
+
},
|
|
346
|
+
{
|
|
347
|
+
id: "detection-tracker",
|
|
348
|
+
title: "Tracker",
|
|
349
|
+
description: "SORT/IoU tracker parameters",
|
|
350
|
+
columns: 3,
|
|
351
|
+
fields: [
|
|
352
|
+
{
|
|
353
|
+
type: "number",
|
|
354
|
+
key: "trackerMaxAgeFrames",
|
|
355
|
+
label: "Max Age",
|
|
356
|
+
description: "Frames before a lost track is removed",
|
|
357
|
+
min: 1,
|
|
358
|
+
max: 120,
|
|
359
|
+
step: 1,
|
|
360
|
+
unit: "frames"
|
|
479
361
|
},
|
|
480
362
|
{
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
key: "trackerMinHits",
|
|
499
|
-
label: "Min Hits",
|
|
500
|
-
description: "Consecutive detections to confirm a track",
|
|
501
|
-
min: 1,
|
|
502
|
-
max: 20,
|
|
503
|
-
step: 1
|
|
504
|
-
},
|
|
505
|
-
{
|
|
506
|
-
type: "slider",
|
|
507
|
-
key: "trackerIouThreshold",
|
|
508
|
-
label: "IoU Threshold",
|
|
509
|
-
description: "Minimum IoU to associate detection with track",
|
|
510
|
-
min: 0.1,
|
|
511
|
-
max: 0.9,
|
|
512
|
-
step: 0.05,
|
|
513
|
-
showValue: true
|
|
514
|
-
}
|
|
515
|
-
]
|
|
363
|
+
type: "number",
|
|
364
|
+
key: "trackerMinHits",
|
|
365
|
+
label: "Min Hits",
|
|
366
|
+
description: "Consecutive detections to confirm a track",
|
|
367
|
+
min: 1,
|
|
368
|
+
max: 20,
|
|
369
|
+
step: 1
|
|
370
|
+
},
|
|
371
|
+
{
|
|
372
|
+
type: "slider",
|
|
373
|
+
key: "trackerIouThreshold",
|
|
374
|
+
label: "IoU Threshold",
|
|
375
|
+
description: "Minimum IoU to associate detection with track",
|
|
376
|
+
min: 0.1,
|
|
377
|
+
max: 0.9,
|
|
378
|
+
step: 0.05,
|
|
379
|
+
showValue: true
|
|
516
380
|
}
|
|
517
381
|
]
|
|
518
|
-
}
|
|
519
|
-
|
|
520
|
-
|
|
382
|
+
}
|
|
383
|
+
]
|
|
384
|
+
};
|
|
385
|
+
var AUTH_SCHEMA = {
|
|
386
|
+
sections: [
|
|
387
|
+
{
|
|
388
|
+
id: "auth-settings",
|
|
389
|
+
title: "Authentication",
|
|
390
|
+
description: "Token and session settings",
|
|
391
|
+
columns: 1,
|
|
392
|
+
fields: [
|
|
521
393
|
{
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
{
|
|
528
|
-
type: "text",
|
|
529
|
-
key: "tokenExpiry",
|
|
530
|
-
label: "Token Expiry",
|
|
531
|
-
description: "JWT token lifetime (e.g. 24h, 7d, 1h)",
|
|
532
|
-
placeholder: "24h"
|
|
533
|
-
}
|
|
534
|
-
]
|
|
394
|
+
type: "text",
|
|
395
|
+
key: "tokenExpiry",
|
|
396
|
+
label: "Token Expiry",
|
|
397
|
+
description: "JWT token lifetime (e.g. 24h, 7d, 1h)",
|
|
398
|
+
placeholder: "24h"
|
|
535
399
|
}
|
|
536
400
|
]
|
|
537
|
-
}
|
|
538
|
-
|
|
539
|
-
|
|
401
|
+
}
|
|
402
|
+
]
|
|
403
|
+
};
|
|
404
|
+
var RETENTION_SCHEMA = {
|
|
405
|
+
sections: [
|
|
406
|
+
{
|
|
407
|
+
id: "retention-settings",
|
|
408
|
+
title: "Retention",
|
|
409
|
+
description: "Data retention periods for analytics data",
|
|
410
|
+
columns: 1,
|
|
411
|
+
fields: [
|
|
540
412
|
{
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
label: "Audio Levels Retention",
|
|
560
|
-
min: 1,
|
|
561
|
-
max: 90,
|
|
562
|
-
unit: "days",
|
|
563
|
-
showValue: true,
|
|
564
|
-
span: 1
|
|
565
|
-
}
|
|
566
|
-
]
|
|
413
|
+
type: "slider",
|
|
414
|
+
key: "detectionEventsDays",
|
|
415
|
+
label: "Detection Events Retention",
|
|
416
|
+
min: 1,
|
|
417
|
+
max: 365,
|
|
418
|
+
unit: "days",
|
|
419
|
+
showValue: true,
|
|
420
|
+
span: 1
|
|
421
|
+
},
|
|
422
|
+
{
|
|
423
|
+
type: "slider",
|
|
424
|
+
key: "audioLevelsDays",
|
|
425
|
+
label: "Audio Levels Retention",
|
|
426
|
+
min: 1,
|
|
427
|
+
max: 90,
|
|
428
|
+
unit: "days",
|
|
429
|
+
showValue: true,
|
|
430
|
+
span: 1
|
|
567
431
|
}
|
|
568
432
|
]
|
|
569
|
-
};
|
|
570
|
-
exports2.SYSTEM_SETTINGS_SCHEMAS = {
|
|
571
|
-
server: SERVER_SCHEMA,
|
|
572
|
-
storage: STORAGE_SCHEMA,
|
|
573
|
-
logging: LOGGING_SCHEMA,
|
|
574
|
-
recording: RECORDING_SCHEMA,
|
|
575
|
-
ffmpeg: FFMPEG_SCHEMA,
|
|
576
|
-
detection: DETECTION_SCHEMA,
|
|
577
|
-
auth: AUTH_SCHEMA,
|
|
578
|
-
retention: RETENTION_SCHEMA,
|
|
579
|
-
// These sections have no UI form — managed programmatically or addon-specific
|
|
580
|
-
streaming: { sections: [] },
|
|
581
|
-
backup: { sections: [] },
|
|
582
|
-
features: { sections: [] },
|
|
583
|
-
addons: { sections: [] }
|
|
584
|
-
};
|
|
585
|
-
function getSystemSettingsSchema(section) {
|
|
586
|
-
return exports2.SYSTEM_SETTINGS_SCHEMAS[section];
|
|
587
433
|
}
|
|
588
|
-
|
|
589
|
-
}
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
}
|
|
434
|
+
]
|
|
435
|
+
};
|
|
436
|
+
var SYSTEM_SETTINGS_SCHEMAS = {
|
|
437
|
+
server: SERVER_SCHEMA,
|
|
438
|
+
storage: STORAGE_SCHEMA,
|
|
439
|
+
logging: LOGGING_SCHEMA,
|
|
440
|
+
recording: RECORDING_SCHEMA,
|
|
441
|
+
ffmpeg: FFMPEG_SCHEMA,
|
|
442
|
+
detection: DETECTION_SCHEMA,
|
|
443
|
+
auth: AUTH_SCHEMA,
|
|
444
|
+
retention: RETENTION_SCHEMA,
|
|
445
|
+
// These sections have no UI form — managed programmatically or addon-specific
|
|
446
|
+
streaming: { sections: [] },
|
|
447
|
+
backup: { sections: [] },
|
|
448
|
+
features: { sections: [] },
|
|
449
|
+
addons: { sections: [] }
|
|
450
|
+
};
|
|
451
|
+
function getSystemSettingsSchema(section) {
|
|
452
|
+
return SYSTEM_SETTINGS_SCHEMAS[section];
|
|
453
|
+
}
|
|
601
454
|
|
|
602
|
-
// src/
|
|
603
|
-
var
|
|
604
|
-
|
|
605
|
-
"use strict";
|
|
606
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
607
|
-
exports2.hfModelUrl = hfModelUrl2;
|
|
608
|
-
function hfModelUrl2(repo, path) {
|
|
609
|
-
return `https://huggingface.co/${repo}/resolve/main/${path}`;
|
|
610
|
-
}
|
|
611
|
-
}
|
|
612
|
-
});
|
|
455
|
+
// src/constants.ts
|
|
456
|
+
var HF_REPO = "camstack/camstack-models";
|
|
457
|
+
var HF_BASE_URL = `https://huggingface.co/${HF_REPO}/resolve/main`;
|
|
613
458
|
|
|
614
|
-
// src/utils/
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
619
|
-
exports2.cosineSimilarity = cosineSimilarity2;
|
|
620
|
-
function cosineSimilarity2(a, b) {
|
|
621
|
-
if (a.length !== b.length)
|
|
622
|
-
return 0;
|
|
623
|
-
let dotProduct = 0;
|
|
624
|
-
let normA = 0;
|
|
625
|
-
let normB = 0;
|
|
626
|
-
for (let i = 0; i < a.length; i++) {
|
|
627
|
-
dotProduct += a[i] * b[i];
|
|
628
|
-
normA += a[i] * a[i];
|
|
629
|
-
normB += b[i] * b[i];
|
|
630
|
-
}
|
|
631
|
-
const denom = Math.sqrt(normA) * Math.sqrt(normB);
|
|
632
|
-
return denom === 0 ? 0 : dotProduct / denom;
|
|
633
|
-
}
|
|
634
|
-
}
|
|
635
|
-
});
|
|
459
|
+
// src/utils/hf-url.ts
|
|
460
|
+
function hfModelUrl(repo, path) {
|
|
461
|
+
return `https://huggingface.co/${repo}/resolve/main/${path}`;
|
|
462
|
+
}
|
|
636
463
|
|
|
637
|
-
// src/
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
{ id: "motorcycle", name: "Motorcycle" },
|
|
648
|
-
{ id: "airplane", name: "Airplane" },
|
|
649
|
-
{ id: "bus", name: "Bus" },
|
|
650
|
-
{ id: "train", name: "Train" },
|
|
651
|
-
{ id: "truck", name: "Truck" },
|
|
652
|
-
{ id: "boat", name: "Boat" },
|
|
653
|
-
{ id: "traffic light", name: "Traffic Light" },
|
|
654
|
-
{ id: "fire hydrant", name: "Fire Hydrant" },
|
|
655
|
-
{ id: "stop sign", name: "Stop Sign" },
|
|
656
|
-
{ id: "parking meter", name: "Parking Meter" },
|
|
657
|
-
{ id: "bench", name: "Bench" },
|
|
658
|
-
{ id: "bird", name: "Bird" },
|
|
659
|
-
{ id: "cat", name: "Cat" },
|
|
660
|
-
{ id: "dog", name: "Dog" },
|
|
661
|
-
{ id: "horse", name: "Horse" },
|
|
662
|
-
{ id: "sheep", name: "Sheep" },
|
|
663
|
-
{ id: "cow", name: "Cow" },
|
|
664
|
-
{ id: "elephant", name: "Elephant" },
|
|
665
|
-
{ id: "bear", name: "Bear" },
|
|
666
|
-
{ id: "zebra", name: "Zebra" },
|
|
667
|
-
{ id: "giraffe", name: "Giraffe" },
|
|
668
|
-
{ id: "backpack", name: "Backpack" },
|
|
669
|
-
{ id: "umbrella", name: "Umbrella" },
|
|
670
|
-
{ id: "handbag", name: "Handbag" },
|
|
671
|
-
{ id: "tie", name: "Tie" },
|
|
672
|
-
{ id: "suitcase", name: "Suitcase" },
|
|
673
|
-
{ id: "frisbee", name: "Frisbee" },
|
|
674
|
-
{ id: "skis", name: "Skis" },
|
|
675
|
-
{ id: "snowboard", name: "Snowboard" },
|
|
676
|
-
{ id: "sports ball", name: "Sports Ball" },
|
|
677
|
-
{ id: "kite", name: "Kite" },
|
|
678
|
-
{ id: "baseball bat", name: "Baseball Bat" },
|
|
679
|
-
{ id: "baseball glove", name: "Baseball Glove" },
|
|
680
|
-
{ id: "skateboard", name: "Skateboard" },
|
|
681
|
-
{ id: "surfboard", name: "Surfboard" },
|
|
682
|
-
{ id: "tennis racket", name: "Tennis Racket" },
|
|
683
|
-
{ id: "bottle", name: "Bottle" },
|
|
684
|
-
{ id: "wine glass", name: "Wine Glass" },
|
|
685
|
-
{ id: "cup", name: "Cup" },
|
|
686
|
-
{ id: "fork", name: "Fork" },
|
|
687
|
-
{ id: "knife", name: "Knife" },
|
|
688
|
-
{ id: "spoon", name: "Spoon" },
|
|
689
|
-
{ id: "bowl", name: "Bowl" },
|
|
690
|
-
{ id: "banana", name: "Banana" },
|
|
691
|
-
{ id: "apple", name: "Apple" },
|
|
692
|
-
{ id: "sandwich", name: "Sandwich" },
|
|
693
|
-
{ id: "orange", name: "Orange" },
|
|
694
|
-
{ id: "broccoli", name: "Broccoli" },
|
|
695
|
-
{ id: "carrot", name: "Carrot" },
|
|
696
|
-
{ id: "hot dog", name: "Hot Dog" },
|
|
697
|
-
{ id: "pizza", name: "Pizza" },
|
|
698
|
-
{ id: "donut", name: "Donut" },
|
|
699
|
-
{ id: "cake", name: "Cake" },
|
|
700
|
-
{ id: "chair", name: "Chair" },
|
|
701
|
-
{ id: "couch", name: "Couch" },
|
|
702
|
-
{ id: "potted plant", name: "Potted Plant" },
|
|
703
|
-
{ id: "bed", name: "Bed" },
|
|
704
|
-
{ id: "dining table", name: "Dining Table" },
|
|
705
|
-
{ id: "toilet", name: "Toilet" },
|
|
706
|
-
{ id: "tv", name: "TV" },
|
|
707
|
-
{ id: "laptop", name: "Laptop" },
|
|
708
|
-
{ id: "mouse", name: "Mouse" },
|
|
709
|
-
{ id: "remote", name: "Remote" },
|
|
710
|
-
{ id: "keyboard", name: "Keyboard" },
|
|
711
|
-
{ id: "cell phone", name: "Cell Phone" },
|
|
712
|
-
{ id: "microwave", name: "Microwave" },
|
|
713
|
-
{ id: "oven", name: "Oven" },
|
|
714
|
-
{ id: "toaster", name: "Toaster" },
|
|
715
|
-
{ id: "sink", name: "Sink" },
|
|
716
|
-
{ id: "refrigerator", name: "Refrigerator" },
|
|
717
|
-
{ id: "book", name: "Book" },
|
|
718
|
-
{ id: "clock", name: "Clock" },
|
|
719
|
-
{ id: "vase", name: "Vase" },
|
|
720
|
-
{ id: "scissors", name: "Scissors" },
|
|
721
|
-
{ id: "teddy bear", name: "Teddy Bear" },
|
|
722
|
-
{ id: "hair drier", name: "Hair Drier" },
|
|
723
|
-
{ id: "toothbrush", name: "Toothbrush" }
|
|
724
|
-
];
|
|
725
|
-
exports2.MACRO_LABELS = [
|
|
726
|
-
{ id: "person", name: "Person" },
|
|
727
|
-
{ id: "vehicle", name: "Vehicle" },
|
|
728
|
-
{ id: "animal", name: "Animal" }
|
|
729
|
-
];
|
|
730
|
-
exports2.COCO_TO_MACRO = {
|
|
731
|
-
mapping: {
|
|
732
|
-
person: "person",
|
|
733
|
-
bicycle: "vehicle",
|
|
734
|
-
car: "vehicle",
|
|
735
|
-
motorcycle: "vehicle",
|
|
736
|
-
airplane: "vehicle",
|
|
737
|
-
bus: "vehicle",
|
|
738
|
-
train: "vehicle",
|
|
739
|
-
truck: "vehicle",
|
|
740
|
-
boat: "vehicle",
|
|
741
|
-
bird: "animal",
|
|
742
|
-
cat: "animal",
|
|
743
|
-
dog: "animal",
|
|
744
|
-
horse: "animal",
|
|
745
|
-
sheep: "animal",
|
|
746
|
-
cow: "animal",
|
|
747
|
-
elephant: "animal",
|
|
748
|
-
bear: "animal",
|
|
749
|
-
zebra: "animal",
|
|
750
|
-
giraffe: "animal"
|
|
751
|
-
},
|
|
752
|
-
preserveOriginal: true
|
|
753
|
-
};
|
|
464
|
+
// src/utils/cosine-similarity.ts
|
|
465
|
+
function cosineSimilarity(a, b) {
|
|
466
|
+
if (a.length !== b.length) return 0;
|
|
467
|
+
let dotProduct = 0;
|
|
468
|
+
let normA = 0;
|
|
469
|
+
let normB = 0;
|
|
470
|
+
for (let i = 0; i < a.length; i++) {
|
|
471
|
+
dotProduct += a[i] * b[i];
|
|
472
|
+
normA += a[i] * a[i];
|
|
473
|
+
normB += b[i] * b[i];
|
|
754
474
|
}
|
|
755
|
-
|
|
475
|
+
const denom = Math.sqrt(normA) * Math.sqrt(normB);
|
|
476
|
+
return denom === 0 ? 0 : dotProduct / denom;
|
|
477
|
+
}
|
|
756
478
|
|
|
757
|
-
// src/
|
|
758
|
-
var
|
|
759
|
-
"
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
}
|
|
771
|
-
}
|
|
479
|
+
// src/catalogs/coco-classmap.ts
|
|
480
|
+
var COCO_80_LABELS = [
|
|
481
|
+
{ id: "person", name: "Person" },
|
|
482
|
+
{ id: "bicycle", name: "Bicycle" },
|
|
483
|
+
{ id: "car", name: "Car" },
|
|
484
|
+
{ id: "motorcycle", name: "Motorcycle" },
|
|
485
|
+
{ id: "airplane", name: "Airplane" },
|
|
486
|
+
{ id: "bus", name: "Bus" },
|
|
487
|
+
{ id: "train", name: "Train" },
|
|
488
|
+
{ id: "truck", name: "Truck" },
|
|
489
|
+
{ id: "boat", name: "Boat" },
|
|
490
|
+
{ id: "traffic light", name: "Traffic Light" },
|
|
491
|
+
{ id: "fire hydrant", name: "Fire Hydrant" },
|
|
492
|
+
{ id: "stop sign", name: "Stop Sign" },
|
|
493
|
+
{ id: "parking meter", name: "Parking Meter" },
|
|
494
|
+
{ id: "bench", name: "Bench" },
|
|
495
|
+
{ id: "bird", name: "Bird" },
|
|
496
|
+
{ id: "cat", name: "Cat" },
|
|
497
|
+
{ id: "dog", name: "Dog" },
|
|
498
|
+
{ id: "horse", name: "Horse" },
|
|
499
|
+
{ id: "sheep", name: "Sheep" },
|
|
500
|
+
{ id: "cow", name: "Cow" },
|
|
501
|
+
{ id: "elephant", name: "Elephant" },
|
|
502
|
+
{ id: "bear", name: "Bear" },
|
|
503
|
+
{ id: "zebra", name: "Zebra" },
|
|
504
|
+
{ id: "giraffe", name: "Giraffe" },
|
|
505
|
+
{ id: "backpack", name: "Backpack" },
|
|
506
|
+
{ id: "umbrella", name: "Umbrella" },
|
|
507
|
+
{ id: "handbag", name: "Handbag" },
|
|
508
|
+
{ id: "tie", name: "Tie" },
|
|
509
|
+
{ id: "suitcase", name: "Suitcase" },
|
|
510
|
+
{ id: "frisbee", name: "Frisbee" },
|
|
511
|
+
{ id: "skis", name: "Skis" },
|
|
512
|
+
{ id: "snowboard", name: "Snowboard" },
|
|
513
|
+
{ id: "sports ball", name: "Sports Ball" },
|
|
514
|
+
{ id: "kite", name: "Kite" },
|
|
515
|
+
{ id: "baseball bat", name: "Baseball Bat" },
|
|
516
|
+
{ id: "baseball glove", name: "Baseball Glove" },
|
|
517
|
+
{ id: "skateboard", name: "Skateboard" },
|
|
518
|
+
{ id: "surfboard", name: "Surfboard" },
|
|
519
|
+
{ id: "tennis racket", name: "Tennis Racket" },
|
|
520
|
+
{ id: "bottle", name: "Bottle" },
|
|
521
|
+
{ id: "wine glass", name: "Wine Glass" },
|
|
522
|
+
{ id: "cup", name: "Cup" },
|
|
523
|
+
{ id: "fork", name: "Fork" },
|
|
524
|
+
{ id: "knife", name: "Knife" },
|
|
525
|
+
{ id: "spoon", name: "Spoon" },
|
|
526
|
+
{ id: "bowl", name: "Bowl" },
|
|
527
|
+
{ id: "banana", name: "Banana" },
|
|
528
|
+
{ id: "apple", name: "Apple" },
|
|
529
|
+
{ id: "sandwich", name: "Sandwich" },
|
|
530
|
+
{ id: "orange", name: "Orange" },
|
|
531
|
+
{ id: "broccoli", name: "Broccoli" },
|
|
532
|
+
{ id: "carrot", name: "Carrot" },
|
|
533
|
+
{ id: "hot dog", name: "Hot Dog" },
|
|
534
|
+
{ id: "pizza", name: "Pizza" },
|
|
535
|
+
{ id: "donut", name: "Donut" },
|
|
536
|
+
{ id: "cake", name: "Cake" },
|
|
537
|
+
{ id: "chair", name: "Chair" },
|
|
538
|
+
{ id: "couch", name: "Couch" },
|
|
539
|
+
{ id: "potted plant", name: "Potted Plant" },
|
|
540
|
+
{ id: "bed", name: "Bed" },
|
|
541
|
+
{ id: "dining table", name: "Dining Table" },
|
|
542
|
+
{ id: "toilet", name: "Toilet" },
|
|
543
|
+
{ id: "tv", name: "TV" },
|
|
544
|
+
{ id: "laptop", name: "Laptop" },
|
|
545
|
+
{ id: "mouse", name: "Mouse" },
|
|
546
|
+
{ id: "remote", name: "Remote" },
|
|
547
|
+
{ id: "keyboard", name: "Keyboard" },
|
|
548
|
+
{ id: "cell phone", name: "Cell Phone" },
|
|
549
|
+
{ id: "microwave", name: "Microwave" },
|
|
550
|
+
{ id: "oven", name: "Oven" },
|
|
551
|
+
{ id: "toaster", name: "Toaster" },
|
|
552
|
+
{ id: "sink", name: "Sink" },
|
|
553
|
+
{ id: "refrigerator", name: "Refrigerator" },
|
|
554
|
+
{ id: "book", name: "Book" },
|
|
555
|
+
{ id: "clock", name: "Clock" },
|
|
556
|
+
{ id: "vase", name: "Vase" },
|
|
557
|
+
{ id: "scissors", name: "Scissors" },
|
|
558
|
+
{ id: "teddy bear", name: "Teddy Bear" },
|
|
559
|
+
{ id: "hair drier", name: "Hair Drier" },
|
|
560
|
+
{ id: "toothbrush", name: "Toothbrush" }
|
|
561
|
+
];
|
|
562
|
+
var MACRO_LABELS = [
|
|
563
|
+
{ id: "person", name: "Person" },
|
|
564
|
+
{ id: "vehicle", name: "Vehicle" },
|
|
565
|
+
{ id: "animal", name: "Animal" }
|
|
566
|
+
];
|
|
567
|
+
var COCO_TO_MACRO = {
|
|
568
|
+
mapping: {
|
|
569
|
+
person: "person",
|
|
570
|
+
bicycle: "vehicle",
|
|
571
|
+
car: "vehicle",
|
|
572
|
+
motorcycle: "vehicle",
|
|
573
|
+
airplane: "vehicle",
|
|
574
|
+
bus: "vehicle",
|
|
575
|
+
train: "vehicle",
|
|
576
|
+
truck: "vehicle",
|
|
577
|
+
boat: "vehicle",
|
|
578
|
+
bird: "animal",
|
|
579
|
+
cat: "animal",
|
|
580
|
+
dog: "animal",
|
|
581
|
+
horse: "animal",
|
|
582
|
+
sheep: "animal",
|
|
583
|
+
cow: "animal",
|
|
584
|
+
elephant: "animal",
|
|
585
|
+
bear: "animal",
|
|
586
|
+
zebra: "animal",
|
|
587
|
+
giraffe: "animal"
|
|
588
|
+
},
|
|
589
|
+
preserveOriginal: true
|
|
590
|
+
};
|
|
772
591
|
|
|
773
|
-
// src/
|
|
774
|
-
var
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
cosineSimilarity: () => import_cosine_similarity.cosineSimilarity,
|
|
782
|
-
hfModelUrl: () => import_hf_url.hfModelUrl,
|
|
783
|
-
resolveTranslation: () => import_addon_i18n.resolveTranslation
|
|
784
|
-
});
|
|
785
|
-
module.exports = __toCommonJS(src_exports);
|
|
786
|
-
__reExport(src_exports, __toESM(require_io()), module.exports);
|
|
787
|
-
__reExport(src_exports, __toESM(require_labels()), module.exports);
|
|
788
|
-
__reExport(src_exports, __toESM(require_detection()), module.exports);
|
|
789
|
-
__reExport(src_exports, __toESM(require_tracked()), module.exports);
|
|
790
|
-
__reExport(src_exports, __toESM(require_events()), module.exports);
|
|
791
|
-
__reExport(src_exports, __toESM(require_config()), module.exports);
|
|
792
|
-
__reExport(src_exports, __toESM(require_entities()), module.exports);
|
|
793
|
-
__reExport(src_exports, __toESM(require_zones()), module.exports);
|
|
794
|
-
__reExport(src_exports, __toESM(require_models()), module.exports);
|
|
795
|
-
__reExport(src_exports, __toESM(require_pipeline()), module.exports);
|
|
796
|
-
__reExport(src_exports, __toESM(require_live_state()), module.exports);
|
|
797
|
-
__reExport(src_exports, __toESM(require_analytics()), module.exports);
|
|
798
|
-
__reExport(src_exports, __toESM(require_storage_backend()), module.exports);
|
|
799
|
-
var import_addon_i18n = __toESM(require_addon_i18n());
|
|
800
|
-
__reExport(src_exports, __toESM(require_feature_flags()), module.exports);
|
|
801
|
-
__reExport(src_exports, __toESM(require_agent_protocol()), module.exports);
|
|
802
|
-
__reExport(src_exports, __toESM(require_server_analysis()), module.exports);
|
|
803
|
-
__reExport(src_exports, __toESM(require_analysis_persistence()), module.exports);
|
|
804
|
-
__reExport(src_exports, __toESM(require_system_settings_schemas()), module.exports);
|
|
805
|
-
__reExport(src_exports, __toESM(require_constants()), module.exports);
|
|
806
|
-
var import_hf_url = __toESM(require_hf_url());
|
|
807
|
-
var import_cosine_similarity = __toESM(require_cosine_similarity());
|
|
808
|
-
var import_coco_classmap = __toESM(require_coco_classmap());
|
|
809
|
-
var import_device_type = __toESM(require_device_type());
|
|
592
|
+
// src/types/device-type.ts
|
|
593
|
+
var DeviceType = /* @__PURE__ */ ((DeviceType2) => {
|
|
594
|
+
DeviceType2["Camera"] = "camera";
|
|
595
|
+
return DeviceType2;
|
|
596
|
+
})(DeviceType || {});
|
|
597
|
+
var DEVICE_TYPE_INFO = {
|
|
598
|
+
["camera" /* Camera */]: { type: "camera" /* Camera */, label: "Camera", icon: "camera" }
|
|
599
|
+
};
|
|
810
600
|
// Annotate the CommonJS export names for ESM import in node:
|
|
811
601
|
0 && (module.exports = {
|
|
602
|
+
BINARY_FRAME_HEADER_SIZE,
|
|
603
|
+
BINARY_FRAME_TYPE,
|
|
812
604
|
COCO_80_LABELS,
|
|
813
605
|
COCO_TO_MACRO,
|
|
606
|
+
DEFAULT_FEATURES,
|
|
607
|
+
DEFAULT_LOCATION_SUBPATHS,
|
|
608
|
+
DEFAULT_RETENTION,
|
|
609
|
+
DETECTION_TYPES,
|
|
814
610
|
DEVICE_TYPE_INFO,
|
|
815
611
|
DeviceType,
|
|
612
|
+
HF_BASE_URL,
|
|
613
|
+
HF_REPO,
|
|
816
614
|
MACRO_LABELS,
|
|
615
|
+
READ_ONLY_SECTIONS,
|
|
616
|
+
RECOGNITION_TYPES,
|
|
617
|
+
SETTINGS_TABS,
|
|
618
|
+
SUB_DETECTION_TYPES,
|
|
619
|
+
SYSTEM_SETTINGS_SCHEMAS,
|
|
817
620
|
cosineSimilarity,
|
|
621
|
+
createAnalysisContext,
|
|
622
|
+
enrichContext,
|
|
623
|
+
getSystemSettingsSchema,
|
|
818
624
|
hfModelUrl,
|
|
819
625
|
resolveTranslation
|
|
820
626
|
});
|