@camstack/server 1.2.718 → 1.2.720

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (970) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/dist/addon-root-inventory.js +1 -1
  3. package/dist/agent/addon-scan.js +11 -7
  4. package/dist/agent/agent-addon-updates.js +1 -1
  5. package/dist/agent/agent-cap-dispatch-service.js +1 -1
  6. package/dist/agent/agent-heap-watch.js +1 -1
  7. package/dist/agent/agent-http.js +1 -1
  8. package/dist/agent/agent-hub-addon-update.js +1 -1
  9. package/dist/agent/agent-hub-registration.js +1 -1
  10. package/dist/agent/agent-infra-capabilities.js +2 -2
  11. package/dist/agent/agent-mesh-gate.js +1 -1
  12. package/dist/agent/agent-node-certificates.js +1 -1
  13. package/dist/agent/agent-pairing-routes.js +1 -1
  14. package/dist/agent/agent-pairing-store.js +1 -1
  15. package/dist/agent/agent-service.js +6 -2
  16. package/dist/agent/agent-update-service.js +3 -1
  17. package/dist/agent/hub-membership-client.js +1 -1
  18. package/dist/agent/infra-boot-guard.js +2 -2
  19. package/dist/agent/main.js +9 -9
  20. package/dist/api/addon-upload.js +1 -1
  21. package/dist/api/core/addon-settings.router.js +1 -1
  22. package/dist/api/core/agent-pairing.router.js +1 -1
  23. package/dist/api/core/auth-device-cert.procedures.js +1 -1
  24. package/dist/api/core/cap-providers.js +6 -6
  25. package/dist/api/core/certificates.router.js +1 -1
  26. package/dist/api/core/lifecycle-job-runner.js +1 -1
  27. package/dist/api/core/logging-settings.js +1 -1
  28. package/dist/api/core/logs.router.js +2 -2
  29. package/dist/api/core/notifications.router.js +1 -1
  30. package/dist/api/core/preferences.router.js +1 -1
  31. package/dist/api/core/repl.router.js +1 -1
  32. package/dist/api/cors/cors-policy.js +1 -1
  33. package/dist/api/mesh-membership-routes.js +1 -1
  34. package/dist/api/model-distributor.js +1 -1
  35. package/dist/api/trpc/cap-route-error-formatter.js +1 -1
  36. package/dist/api/trpc/cap-router-runtime.js +2 -2
  37. package/dist/api/trpc/core-cap-bridge.js +1 -1
  38. package/dist/api/trpc/device-collection-dispatch.js +1 -1
  39. package/dist/api/trpc/generated-cap-routers.js +1 -1
  40. package/dist/api/trpc/principal-authorization.js +1 -1
  41. package/dist/api/trpc/principal-visibility.js +1 -1
  42. package/dist/api/trpc/scope-access.js +1 -1
  43. package/dist/api/trpc/trpc.context.js +1 -1
  44. package/dist/api/trpc/trpc.middleware.js +1 -1
  45. package/dist/api/trpc/trpc.router.js +3 -3
  46. package/dist/auth/auth-network-policy.js +1 -1
  47. package/dist/auth/client-address.js +1 -1
  48. package/dist/auth/hub-sessions.js +1 -1
  49. package/dist/auth/session-lifetimes.js +1 -1
  50. package/dist/auth/sso-finish-deps.js +1 -1
  51. package/dist/boot/boot-config.js +53 -133
  52. package/dist/boot/platform-keychain-key.js +1 -1
  53. package/dist/boot/post-boot.service.js +1 -1
  54. package/dist/bootstrap-packages.js +3 -3
  55. package/dist/core/addon/addon-call-gateway.js +1 -1
  56. package/dist/core/addon/addon-package.service.js +140 -21
  57. package/dist/core/addon/addon-registry.service.js +36 -32
  58. package/dist/core/addon/addon-requirements.js +81 -0
  59. package/dist/core/addon/hub-addon-api.js +1 -1
  60. package/dist/core/addon/installed-addon-versions.js +82 -0
  61. package/dist/core/addon/package-dir-utils.js +11 -1
  62. package/dist/core/addon/settings-door-wiring.js +1 -1
  63. package/dist/core/addon-bridge/addon-bridge.service.js +3 -3
  64. package/dist/core/addon-pages/addon-pages.service.js +1 -1
  65. package/dist/core/agent/agent-desired-set.js +1 -1
  66. package/dist/core/agent/agent-pairing-http.js +1 -1
  67. package/dist/core/agent/agent-registry.service.js +41 -7
  68. package/dist/core/agent/cluster-node-history-store.js +1 -1
  69. package/dist/core/agent/delivery-requirements.js +36 -0
  70. package/dist/core/agent/forgotten-node-revoker.js +1 -1
  71. package/dist/core/agent/node-removal-hooks.js +6 -2
  72. package/dist/core/auth/auth.service.js +1 -1
  73. package/dist/core/config/config.schema.js +2 -2
  74. package/dist/core/config/config.service.js +1 -1
  75. package/dist/core/events/event-bus.service.js +1 -1
  76. package/dist/core/feature/feature.service.js +1 -1
  77. package/dist/core/lifecycle/lifecycle-state-machine.js +2 -2
  78. package/dist/core/logging/log-history.js +1 -1
  79. package/dist/core/logging/log-ring-buffer.js +2 -2
  80. package/dist/core/logging/logging.service.js +2 -2
  81. package/dist/core/logging/scoped-logger.js +2 -2
  82. package/dist/core/moleculer/cap-route-authority.js +2 -2
  83. package/dist/core/moleculer/hub-mesh-guard.js +1 -1
  84. package/dist/core/moleculer/moleculer.service.js +1 -1
  85. package/dist/core/network/network-quality.service.js +1 -1
  86. package/dist/core/notification/notification-wrapper.service.js +1 -1
  87. package/dist/core/notification/toast-wrapper.service.js +1 -1
  88. package/dist/core/repl/repl-engine.service.js +1 -1
  89. package/dist/core/server-update/server-update.service.js +3 -0
  90. package/dist/core/server-update/system-ensure-prebuilds.js +3 -3
  91. package/dist/core/server-update/system-exec-npm.js +2 -2
  92. package/dist/core/storage/fs-storage-backend.js +2 -2
  93. package/dist/core/storage/storage-location-manager.js +2 -2
  94. package/dist/core/storage/storage.service.js +1 -1
  95. package/dist/framework-nodepath.js +14 -1
  96. package/dist/launcher.js +23 -23
  97. package/dist/legacy-package-names.js +15 -0
  98. package/dist/main.js +2 -2
  99. package/dist/manual-boot.js +4 -3
  100. package/dist/package-inventory.js +6 -3
  101. package/dist/server-root/index.js +182 -30
  102. package/dist/single-copy-cleanup-runner.js +3 -3
  103. package/dist/single-copy-cleanup.js +19 -14
  104. package/package.json +53 -19
  105. package/scripts/closure-postinstall.mjs +1 -1
  106. package/system/assets/addon-pages-aggregator/icon.svg +5 -0
  107. package/system/assets/addon-widgets-aggregator/icon.svg +6 -0
  108. package/system/assets/alert-center/icon.svg +5 -0
  109. package/system/assets/autotrack/icon.svg +5 -0
  110. package/system/assets/backup-orchestrator/icon.svg +5 -0
  111. package/system/assets/calendars/icon.svg +5 -0
  112. package/system/assets/camera-grid/icon.svg +10 -0
  113. package/system/assets/composer/icon.svg +7 -0
  114. package/system/assets/console-logging/icon.svg +4 -0
  115. package/system/assets/core-blocks/icon.svg +6 -0
  116. package/system/assets/device-history/icon.svg +4 -0
  117. package/system/assets/device-manager/icon.svg +6 -0
  118. package/system/assets/filesystem-storage/icon.svg +6 -0
  119. package/system/assets/hub-forwarder/icon.svg +7 -0
  120. package/system/assets/keychain/icon.svg +6 -0
  121. package/system/assets/liveness-monitor/icon.svg +4 -0
  122. package/system/assets/local-auth/icon.svg +5 -0
  123. package/system/assets/local-network/icon.svg +7 -0
  124. package/system/assets/loki-logging/icon.svg +7 -0
  125. package/system/assets/metrics-native/icon.svg +3 -0
  126. package/system/assets/platform-probe/icon.svg +5 -0
  127. package/system/assets/record-entries/icon.svg +8 -0
  128. package/system/assets/remote-access-orchestrator/icon.svg +5 -0
  129. package/system/assets/snapshot/icon.svg +4 -0
  130. package/system/assets/sqlite-settings/icon.svg +5 -0
  131. package/system/assets/storage-orchestrator/icon.svg +8 -0
  132. package/system/assets/system-config/icon.svg +4 -0
  133. package/system/assets/winston-logging/icon.svg +6 -0
  134. package/system/dist/addon/addon-api-factory.d.ts +35 -0
  135. package/system/dist/addon-routes/addon-route-registry.d.ts +37 -0
  136. package/system/dist/addon-runner.js +11894 -0
  137. package/system/dist/addon-runner.mjs +11840 -0
  138. package/system/dist/addon-utils.d.ts +23 -0
  139. package/system/dist/addon-utils.js +27 -0
  140. package/system/dist/addon-utils.mjs +3 -0
  141. package/system/dist/agent-https-BMbnmX5u.mjs +1042 -0
  142. package/system/dist/agent-https-DslXCDRW.js +1289 -0
  143. package/system/dist/amd-accelerators-CEuPFBBK.js +36 -0
  144. package/system/dist/amd-accelerators-U_RsoEDd.mjs +35 -0
  145. package/system/dist/auth/auth-audit-log.d.ts +45 -0
  146. package/system/dist/auth/auth-manager.d.ts +155 -0
  147. package/system/dist/auth/cidr.d.ts +22 -0
  148. package/system/dist/auth/device-ca-store.d.ts +57 -0
  149. package/system/dist/auth/device-ca.d.ts +65 -0
  150. package/system/dist/auth/device-credential-manager.d.ts +158 -0
  151. package/system/dist/auth/external-identity-manager.d.ts +42 -0
  152. package/system/dist/auth/jwt-signing-key.d.ts +42 -0
  153. package/system/dist/auth/legacy-token-tables.d.ts +16 -0
  154. package/system/dist/auth/login-session-manager.d.ts +140 -0
  155. package/system/dist/auth/origin.d.ts +34 -0
  156. package/system/dist/auth/parse-record.d.ts +18 -0
  157. package/system/dist/auth/scope-matcher.d.ts +8 -0
  158. package/system/dist/auth/session-revocation-bus.d.ts +32 -0
  159. package/system/dist/auth/token-expiry.d.ts +62 -0
  160. package/system/dist/auth/totp-manager.d.ts +107 -0
  161. package/system/dist/auth/user-management-internal.d.ts +90 -0
  162. package/system/dist/auth/user-manager.d.ts +69 -0
  163. package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.d.ts +57 -0
  164. package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +271 -0
  165. package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +263 -0
  166. package/system/dist/builtins/addon-pages-aggregator/dedupe-pages.d.ts +24 -0
  167. package/system/dist/builtins/addon-pages-aggregator/index.d.ts +1 -0
  168. package/system/dist/builtins/addon-pages-aggregator/index.js +8 -0
  169. package/system/dist/builtins/addon-pages-aggregator/index.mjs +2 -0
  170. package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.d.ts +57 -0
  171. package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +257 -0
  172. package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +249 -0
  173. package/system/dist/builtins/addon-widgets-aggregator/index.d.ts +1 -0
  174. package/system/dist/builtins/addon-widgets-aggregator/index.js +8 -0
  175. package/system/dist/builtins/addon-widgets-aggregator/index.mjs +2 -0
  176. package/system/dist/builtins/alerts/alert-episode-policy.d.ts +39 -0
  177. package/system/dist/builtins/alerts/alert-store.d.ts +32 -0
  178. package/system/dist/builtins/alerts/alerts.addon.d.ts +148 -0
  179. package/system/dist/builtins/alerts/alerts.addon.js +1566 -0
  180. package/system/dist/builtins/alerts/alerts.addon.mjs +1559 -0
  181. package/system/dist/builtins/alerts/device-label.d.ts +8 -0
  182. package/system/dist/builtins/alerts/emit-alert-policy.d.ts +15 -0
  183. package/system/dist/builtins/alerts/index.d.ts +1 -0
  184. package/system/dist/builtins/alerts/index.js +4 -0
  185. package/system/dist/builtins/alerts/index.mjs +2 -0
  186. package/system/dist/builtins/alerts/migration-alerts.d.ts +13 -0
  187. package/system/dist/builtins/alerts/prune-policy.d.ts +44 -0
  188. package/system/dist/builtins/alerts/record-kinds.d.ts +15 -0
  189. package/system/dist/builtins/alerts/runner-alert.d.ts +58 -0
  190. package/system/dist/builtins/autotrack/autotrack-cameras.d.ts +125 -0
  191. package/system/dist/builtins/autotrack/autotrack-config.d.ts +89 -0
  192. package/system/dist/builtins/autotrack/autotrack-decision.d.ts +86 -0
  193. package/system/dist/builtins/autotrack/autotrack-loop.d.ts +95 -0
  194. package/system/dist/builtins/autotrack/autotrack.addon.d.ts +108 -0
  195. package/system/dist/builtins/autotrack/frame-error.d.ts +50 -0
  196. package/system/dist/builtins/autotrack/frame-measurements.d.ts +97 -0
  197. package/system/dist/builtins/autotrack/index.d.ts +2 -0
  198. package/system/dist/builtins/autotrack/index.js +1018 -0
  199. package/system/dist/builtins/autotrack/index.mjs +1012 -0
  200. package/system/dist/builtins/autotrack/ptz-mirror.d.ts +54 -0
  201. package/system/dist/builtins/autotrack/target-selection.d.ts +46 -0
  202. package/system/dist/builtins/backup-orchestrator/backup-databases.d.ts +51 -0
  203. package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.d.ts +291 -0
  204. package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +3213 -0
  205. package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +3204 -0
  206. package/system/dist/builtins/backup-orchestrator/cron-helpers.d.ts +23 -0
  207. package/system/dist/builtins/backup-orchestrator/destination-policy.d.ts +91 -0
  208. package/system/dist/builtins/backup-orchestrator/download-helpers.d.ts +12 -0
  209. package/system/dist/builtins/backup-orchestrator/encryption-key-store.d.ts +49 -0
  210. package/system/dist/builtins/backup-orchestrator/index.d.ts +2 -0
  211. package/system/dist/builtins/backup-orchestrator/index.js +8 -0
  212. package/system/dist/builtins/backup-orchestrator/index.mjs +2 -0
  213. package/system/dist/builtins/backup-orchestrator/manifest-store.d.ts +134 -0
  214. package/system/dist/builtins/backup-orchestrator/record-kinds.d.ts +56 -0
  215. package/system/dist/builtins/backup-orchestrator/restore-archive.d.ts +24 -0
  216. package/system/dist/builtins/backup-orchestrator/run-queue.d.ts +106 -0
  217. package/system/dist/builtins/backup-orchestrator/schedule-store.d.ts +59 -0
  218. package/system/dist/builtins/backup-orchestrator/seed-marker-store.d.ts +26 -0
  219. package/system/dist/builtins/backup-orchestrator/staging-paths.d.ts +36 -0
  220. package/system/dist/builtins/backup-orchestrator/write-targets.d.ts +63 -0
  221. package/system/dist/builtins/calendars/calendar-color.d.ts +9 -0
  222. package/system/dist/builtins/calendars/calendar-prefs-store.d.ts +34 -0
  223. package/system/dist/builtins/calendars/calendars.addon.d.ts +19 -0
  224. package/system/dist/builtins/calendars/calendars.addon.js +227 -0
  225. package/system/dist/builtins/calendars/calendars.addon.mjs +220 -0
  226. package/system/dist/builtins/calendars/index.d.ts +1 -0
  227. package/system/dist/builtins/calendars/index.js +8 -0
  228. package/system/dist/builtins/calendars/index.mjs +2 -0
  229. package/system/dist/builtins/calendars/record-kinds.d.ts +18 -0
  230. package/system/dist/builtins/camera-grid/acquire-retry.d.ts +30 -0
  231. package/system/dist/builtins/camera-grid/addon.d.ts +205 -0
  232. package/system/dist/builtins/camera-grid/flv-join.d.ts +40 -0
  233. package/system/dist/builtins/camera-grid/grid-activity-mirror.d.ts +42 -0
  234. package/system/dist/builtins/camera-grid/grid-activity.d.ts +91 -0
  235. package/system/dist/builtins/camera-grid/grid-camera-declarations.d.ts +59 -0
  236. package/system/dist/builtins/camera-grid/grid-camera-device.d.ts +68 -0
  237. package/system/dist/builtins/camera-grid/grid-canvas-derivation.d.ts +54 -0
  238. package/system/dist/builtins/camera-grid/grid-canvas-seed.d.ts +112 -0
  239. package/system/dist/builtins/camera-grid/grid-canvas.d.ts +85 -0
  240. package/system/dist/builtins/camera-grid/grid-child.d.ts +32 -0
  241. package/system/dist/builtins/camera-grid/grid-compositor-child.d.ts +3 -0
  242. package/system/dist/builtins/camera-grid/grid-compositor-invocation.d.ts +47 -0
  243. package/system/dist/builtins/camera-grid/grid-compositor.d.ts +54 -0
  244. package/system/dist/builtins/camera-grid/grid-detection-mapping.d.ts +61 -0
  245. package/system/dist/builtins/camera-grid/grid-device-settings.d.ts +35 -0
  246. package/system/dist/builtins/camera-grid/grid-filter-graph.d.ts +53 -0
  247. package/system/dist/builtins/camera-grid/grid-frame-sample.d.ts +53 -0
  248. package/system/dist/builtins/camera-grid/grid-instances.d.ts +22 -0
  249. package/system/dist/builtins/camera-grid/grid-last-frame-store.d.ts +58 -0
  250. package/system/dist/builtins/camera-grid/grid-layout-native-provider.d.ts +34 -0
  251. package/system/dist/builtins/camera-grid/grid-plan.d.ts +34 -0
  252. package/system/dist/builtins/camera-grid/grid-profiles.d.ts +104 -0
  253. package/system/dist/builtins/camera-grid/grid-row-normalization.d.ts +10 -0
  254. package/system/dist/builtins/camera-grid/grid-sentry-sources.d.ts +64 -0
  255. package/system/dist/builtins/camera-grid/grid-snapshot.d.ts +62 -0
  256. package/system/dist/builtins/camera-grid/grid-stream-descriptor.d.ts +53 -0
  257. package/system/dist/builtins/camera-grid/grid-stream-invocation.d.ts +44 -0
  258. package/system/dist/builtins/camera-grid/grid-stream-relay.d.ts +35 -0
  259. package/system/dist/builtins/camera-grid/grid-stream-session.d.ts +143 -0
  260. package/system/dist/builtins/camera-grid/grid-tile-feed.d.ts +50 -0
  261. package/system/dist/builtins/camera-grid/grid-tile-plan.d.ts +66 -0
  262. package/system/dist/builtins/camera-grid/grid-wire-format.d.ts +30 -0
  263. package/system/dist/builtins/camera-grid/index.d.ts +45 -0
  264. package/system/dist/builtins/camera-grid/index.js +3994 -0
  265. package/system/dist/builtins/camera-grid/index.mjs +3961 -0
  266. package/system/dist/builtins/camera-grid/silence-analysis.d.ts +37 -0
  267. package/system/dist/builtins/cluster-agent/record-kinds.d.ts +49 -0
  268. package/system/dist/builtins/composer/actuator-dispatch.d.ts +13 -0
  269. package/system/dist/builtins/composer/actuator-groups.d.ts +68 -0
  270. package/system/dist/builtins/composer/actuator-invoke.d.ts +32 -0
  271. package/system/dist/builtins/composer/claim-gate.d.ts +59 -0
  272. package/system/dist/builtins/composer/composed-device-set.d.ts +52 -0
  273. package/system/dist/builtins/composer/composed-device.d.ts +57 -0
  274. package/system/dist/builtins/composer/composer-apply-waits.d.ts +28 -0
  275. package/system/dist/builtins/composer/composer-grafts.d.ts +73 -0
  276. package/system/dist/builtins/composer/composer-live-set.d.ts +30 -0
  277. package/system/dist/builtins/composer/composer-plan.d.ts +112 -0
  278. package/system/dist/builtins/composer/composer-runtime-factory.d.ts +30 -0
  279. package/system/dist/builtins/composer/composer-seeds.d.ts +28 -0
  280. package/system/dist/builtins/composer/composer-verdict.d.ts +33 -0
  281. package/system/dist/builtins/composer/composer.addon.d.ts +26 -0
  282. package/system/dist/builtins/composer/composer.addon.js +6229 -0
  283. package/system/dist/builtins/composer/composer.addon.mjs +6223 -0
  284. package/system/dist/builtins/composer/composer.d.ts +208 -0
  285. package/system/dist/builtins/composer/composition-declarations.d.ts +64 -0
  286. package/system/dist/builtins/composer/composition-evaluation.d.ts +53 -0
  287. package/system/dist/builtins/composer/composition-runtime.d.ts +203 -0
  288. package/system/dist/builtins/composer/composition-target.d.ts +60 -0
  289. package/system/dist/builtins/composer/confirmed-seed.d.ts +44 -0
  290. package/system/dist/builtins/composer/deadline-timer.d.ts +18 -0
  291. package/system/dist/builtins/composer/existing-target.d.ts +131 -0
  292. package/system/dist/builtins/composer/field-record.d.ts +64 -0
  293. package/system/dist/builtins/composer/forward-commands.d.ts +61 -0
  294. package/system/dist/builtins/composer/graft-host.d.ts +71 -0
  295. package/system/dist/builtins/composer/held-claims.d.ts +29 -0
  296. package/system/dist/builtins/composer/history-helpers.d.ts +67 -0
  297. package/system/dist/builtins/composer/index.d.ts +1 -0
  298. package/system/dist/builtins/composer/index.js +8 -0
  299. package/system/dist/builtins/composer/index.mjs +2 -0
  300. package/system/dist/builtins/composer/math-quantity.d.ts +20 -0
  301. package/system/dist/builtins/composer/own-field-reads.d.ts +30 -0
  302. package/system/dist/builtins/composer/owned-fields-target.d.ts +95 -0
  303. package/system/dist/builtins/composer/pulse-seed-resolve.d.ts +59 -0
  304. package/system/dist/builtins/composer/pulse-seed.d.ts +75 -0
  305. package/system/dist/builtins/composer/slice-assembler.d.ts +26 -0
  306. package/system/dist/builtins/composer/source-readings.d.ts +128 -0
  307. package/system/dist/builtins/composer/source-tracker.d.ts +135 -0
  308. package/system/dist/builtins/console-logging/console-destination.d.ts +19 -0
  309. package/system/dist/builtins/console-logging/console-logging.addon.d.ts +26 -0
  310. package/system/dist/builtins/console-logging/index.d.ts +3 -0
  311. package/system/dist/builtins/console-logging/index.js +108 -0
  312. package/system/dist/builtins/console-logging/index.mjs +99 -0
  313. package/system/dist/builtins/core-blocks/actions-service.d.ts +113 -0
  314. package/system/dist/builtins/core-blocks/actions-store.d.ts +32 -0
  315. package/system/dist/builtins/core-blocks/actions-wiring.d.ts +32 -0
  316. package/system/dist/builtins/core-blocks/block-package.d.ts +54 -0
  317. package/system/dist/builtins/core-blocks/block-settings-store.d.ts +93 -0
  318. package/system/dist/builtins/core-blocks/block-supervisor.d.ts +176 -0
  319. package/system/dist/builtins/core-blocks/block-type-defs.d.ts +29 -0
  320. package/system/dist/builtins/core-blocks/blocks-integration.d.ts +89 -0
  321. package/system/dist/builtins/core-blocks/compile-block.d.ts +52 -0
  322. package/system/dist/builtins/core-blocks/composition-api.d.ts +50 -0
  323. package/system/dist/builtins/core-blocks/composition-peers.d.ts +31 -0
  324. package/system/dist/builtins/core-blocks/composition-sources.d.ts +40 -0
  325. package/system/dist/builtins/core-blocks/core-block-store.d.ts +120 -0
  326. package/system/dist/builtins/core-blocks/core-blocks.addon.d.ts +108 -0
  327. package/system/dist/builtins/core-blocks/core-blocks.addon.js +6374 -0
  328. package/system/dist/builtins/core-blocks/core-blocks.addon.mjs +6355 -0
  329. package/system/dist/builtins/core-blocks/extract-settings-schema.d.ts +6 -0
  330. package/system/dist/builtins/core-blocks/index.d.ts +8 -0
  331. package/system/dist/builtins/core-blocks/index.js +21 -0
  332. package/system/dist/builtins/core-blocks/index.mjs +2 -0
  333. package/system/dist/builtins/core-blocks/lock-door-gate.d.ts +31 -0
  334. package/system/dist/builtins/core-blocks/lock-door-sensor.d.ts +35 -0
  335. package/system/dist/builtins/core-blocks/power-source-service.d.ts +70 -0
  336. package/system/dist/builtins/core-blocks/record-kinds.d.ts +83 -0
  337. package/system/dist/builtins/core-blocks/remote-call-redirect.d.ts +23 -0
  338. package/system/dist/builtins/core-blocks/remote-components-service.d.ts +10 -0
  339. package/system/dist/builtins/core-blocks/remote-service.d.ts +85 -0
  340. package/system/dist/builtins/core-blocks/remote-wiring.d.ts +49 -0
  341. package/system/dist/builtins/core-blocks/runs-api.d.ts +30 -0
  342. package/system/dist/builtins/core-blocks/runs-ledger.d.ts +64 -0
  343. package/system/dist/builtins/core-blocks/scheduler/scheduler-engine.d.ts +91 -0
  344. package/system/dist/builtins/core-blocks/scheduler/scheduler-holds.d.ts +54 -0
  345. package/system/dist/builtins/core-blocks/scheduler/scheduler-service.d.ts +76 -0
  346. package/system/dist/builtins/core-blocks/scheduler/scheduler-store.d.ts +23 -0
  347. package/system/dist/builtins/core-blocks/scheduler/scheduler-timeline.d.ts +53 -0
  348. package/system/dist/builtins/core-blocks/scheduler/scheduler-trace.d.ts +17 -0
  349. package/system/dist/builtins/core-blocks/scheduler/scheduler-types.d.ts +20 -0
  350. package/system/dist/builtins/core-blocks/scheduler/scheduler-wiring.d.ts +41 -0
  351. package/system/dist/builtins/core-blocks/templates-service.d.ts +24 -0
  352. package/system/dist/builtins/device-history/capture/capture-engine.d.ts +113 -0
  353. package/system/dist/builtins/device-history/capture/capture-filter.d.ts +37 -0
  354. package/system/dist/builtins/device-history/capture/device-directory.d.ts +47 -0
  355. package/system/dist/builtins/device-history/capture/field-path.d.ts +10 -0
  356. package/system/dist/builtins/device-history/capture/point-writer.d.ts +63 -0
  357. package/system/dist/builtins/device-history/device-history.addon.d.ts +53 -0
  358. package/system/dist/builtins/device-history/device-history.addon.js +2885 -0
  359. package/system/dist/builtins/device-history/device-history.addon.mjs +2878 -0
  360. package/system/dist/builtins/device-history/index.d.ts +3 -0
  361. package/system/dist/builtins/device-history/ingest/producer-ingest.d.ts +99 -0
  362. package/system/dist/builtins/device-history/query/history-query.d.ts +116 -0
  363. package/system/dist/builtins/device-history/query/point-shape.d.ts +31 -0
  364. package/system/dist/builtins/device-history/retention/departure-tracker.d.ts +33 -0
  365. package/system/dist/builtins/device-history/retention/orphans.d.ts +50 -0
  366. package/system/dist/builtins/device-history/retention/retention.d.ts +74 -0
  367. package/system/dist/builtins/device-history/rollup/rollup-engine.d.ts +74 -0
  368. package/system/dist/builtins/device-history/rollup/rollup-math.d.ts +50 -0
  369. package/system/dist/builtins/device-history/runtime/history-runtime.d.ts +118 -0
  370. package/system/dist/builtins/device-history/status/counters.d.ts +55 -0
  371. package/system/dist/builtins/device-history/store/history-door.d.ts +7 -0
  372. package/system/dist/builtins/device-history/store/history-schema.d.ts +28 -0
  373. package/system/dist/builtins/device-history/store/history-store.d.ts +109 -0
  374. package/system/dist/builtins/device-history/store/row-readers.d.ts +11 -0
  375. package/system/dist/builtins/device-history/store/series-registry.d.ts +64 -0
  376. package/system/dist/builtins/device-history/store/series-scale.d.ts +37 -0
  377. package/system/dist/builtins/device-history/time/bucket-time.d.ts +25 -0
  378. package/system/dist/builtins/device-manager/adoption-job-engine.d.ts +153 -0
  379. package/system/dist/builtins/device-manager/claimed-status-overlay.d.ts +45 -0
  380. package/system/dist/builtins/device-manager/contribution-cache.d.ts +85 -0
  381. package/system/dist/builtins/device-manager/day-night-config-schema.d.ts +30 -0
  382. package/system/dist/builtins/device-manager/device-aggregation-merge.d.ts +22 -0
  383. package/system/dist/builtins/device-manager/device-aggregation.d.ts +335 -0
  384. package/system/dist/builtins/device-manager/device-bindings-store.d.ts +278 -0
  385. package/system/dist/builtins/device-manager/device-config-contribution.d.ts +45 -0
  386. package/system/dist/builtins/device-manager/device-config-secrets.d.ts +40 -0
  387. package/system/dist/builtins/device-manager/device-event-propagator.d.ts +26 -0
  388. package/system/dist/builtins/device-manager/device-extension-linked-slot.d.ts +27 -0
  389. package/system/dist/builtins/device-manager/device-form-secrets.d.ts +25 -0
  390. package/system/dist/builtins/device-manager/device-linked-devices.d.ts +201 -0
  391. package/system/dist/builtins/device-manager/device-manager.addon.d.ts +234 -0
  392. package/system/dist/builtins/device-manager/device-manager.addon.js +11369 -0
  393. package/system/dist/builtins/device-manager/device-manager.addon.mjs +11358 -0
  394. package/system/dist/builtins/device-manager/device-meta-actions.d.ts +338 -0
  395. package/system/dist/builtins/device-manager/device-meta-store.d.ts +103 -0
  396. package/system/dist/builtins/device-manager/device-meta-types.d.ts +277 -0
  397. package/system/dist/builtins/device-manager/device-online-fallback.d.ts +35 -0
  398. package/system/dist/builtins/device-manager/device-projection.d.ts +71 -0
  399. package/system/dist/builtins/device-manager/device-provider-context.d.ts +126 -0
  400. package/system/dist/builtins/device-manager/device-queries.d.ts +67 -0
  401. package/system/dist/builtins/device-manager/device-removal-hooks.d.ts +92 -0
  402. package/system/dist/builtins/device-manager/device-row-store.d.ts +449 -0
  403. package/system/dist/builtins/device-manager/device-source-activation.d.ts +103 -0
  404. package/system/dist/builtins/device-manager/device-state-claim-views.d.ts +92 -0
  405. package/system/dist/builtins/device-manager/device-state-claims.d.ts +66 -0
  406. package/system/dist/builtins/device-manager/device-state-mirror.d.ts +267 -0
  407. package/system/dist/builtins/device-manager/device-sync-resolvers.d.ts +30 -0
  408. package/system/dist/builtins/device-manager/device-tombstone-store.d.ts +29 -0
  409. package/system/dist/builtins/device-manager/discovery-orchestrator.d.ts +45 -0
  410. package/system/dist/builtins/device-manager/field-claims-index.d.ts +96 -0
  411. package/system/dist/builtins/device-manager/field-ownership.d.ts +71 -0
  412. package/system/dist/builtins/device-manager/fleet-read-census.d.ts +104 -0
  413. package/system/dist/builtins/device-manager/image-settings-config-schema.d.ts +22 -0
  414. package/system/dist/builtins/device-manager/index.d.ts +2 -0
  415. package/system/dist/builtins/device-manager/index.js +8 -0
  416. package/system/dist/builtins/device-manager/index.mjs +2 -0
  417. package/system/dist/builtins/device-manager/linked-devices-manual-backfill.d.ts +27 -0
  418. package/system/dist/builtins/device-manager/location-alignment.d.ts +61 -0
  419. package/system/dist/builtins/device-manager/migrate-device.d.ts +192 -0
  420. package/system/dist/builtins/device-manager/migrate-guard.d.ts +78 -0
  421. package/system/dist/builtins/device-manager/migrate-hardware-state.d.ts +79 -0
  422. package/system/dist/builtins/device-manager/migrate-reload.d.ts +46 -0
  423. package/system/dist/builtins/device-manager/migration-refused.d.ts +23 -0
  424. package/system/dist/builtins/device-manager/mirror-row-writer.d.ts +222 -0
  425. package/system/dist/builtins/device-manager/record-kinds.d.ts +14 -0
  426. package/system/dist/builtins/device-manager/recording-onboard-config-schema.d.ts +65 -0
  427. package/system/dist/builtins/device-manager/removal-cleanup.d.ts +50 -0
  428. package/system/dist/builtins/device-manager/removal-fence.d.ts +58 -0
  429. package/system/dist/builtins/device-manager/running-flip.d.ts +11 -0
  430. package/system/dist/builtins/device-manager/runtime-state-persist-gate.d.ts +64 -0
  431. package/system/dist/builtins/device-manager/secret-config-paths.d.ts +24 -0
  432. package/system/dist/builtins/device-manager/stale-wrapper-activations.d.ts +59 -0
  433. package/system/dist/builtins/device-manager/write-lock.d.ts +17 -0
  434. package/system/dist/builtins/hub-forwarder/hub-forwarder-destination.d.ts +43 -0
  435. package/system/dist/builtins/hub-forwarder/hub-forwarder.addon.d.ts +16 -0
  436. package/system/dist/builtins/hub-forwarder/index.d.ts +3 -0
  437. package/system/dist/builtins/hub-forwarder/index.js +151 -0
  438. package/system/dist/builtins/hub-forwarder/index.mjs +142 -0
  439. package/system/dist/builtins/keychain/index.d.ts +1 -0
  440. package/system/dist/builtins/keychain/index.js +2059 -0
  441. package/system/dist/builtins/keychain/index.mjs +2052 -0
  442. package/system/dist/builtins/keychain/key-sources.d.ts +37 -0
  443. package/system/dist/builtins/keychain/keychain-crypto.d.ts +28 -0
  444. package/system/dist/builtins/keychain/keychain-reset-trigger.d.ts +25 -0
  445. package/system/dist/builtins/keychain/keychain-service.d.ts +180 -0
  446. package/system/dist/builtins/keychain/keychain-store.d.ts +125 -0
  447. package/system/dist/builtins/keychain/keychain-usage.d.ts +17 -0
  448. package/system/dist/builtins/keychain/keychain.addon.d.ts +36 -0
  449. package/system/dist/builtins/keychain/platform-key-source.d.ts +24 -0
  450. package/system/dist/builtins/keychain/record-kinds.d.ts +16 -0
  451. package/system/dist/builtins/keychain/system-held-secrets.d.ts +25 -0
  452. package/system/dist/builtins/liveness-monitor/index.d.ts +2 -0
  453. package/system/dist/builtins/liveness-monitor/index.js +6 -0
  454. package/system/dist/builtins/liveness-monitor/index.mjs +2 -0
  455. package/system/dist/builtins/liveness-monitor/liveness-checks.d.ts +85 -0
  456. package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.d.ts +46 -0
  457. package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.js +443 -0
  458. package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +437 -0
  459. package/system/dist/builtins/liveness-monitor/liveness-reporter.d.ts +28 -0
  460. package/system/dist/builtins/liveness-monitor/storage-root-access.d.ts +53 -0
  461. package/system/dist/builtins/local-auth/admin-account-boot.d.ts +27 -0
  462. package/system/dist/builtins/local-auth/auth-config-reader.d.ts +39 -0
  463. package/system/dist/builtins/local-auth/auth-schema.d.ts +93 -0
  464. package/system/dist/builtins/local-auth/index.d.ts +1 -0
  465. package/system/dist/builtins/local-auth/index.js +4 -0
  466. package/system/dist/builtins/local-auth/index.mjs +2 -0
  467. package/system/dist/builtins/local-auth/jwt-signing-key-keeper.d.ts +30 -0
  468. package/system/dist/builtins/local-auth/local-auth.addon.d.ts +48 -0
  469. package/system/dist/builtins/local-auth/local-auth.addon.js +12418 -0
  470. package/system/dist/builtins/local-auth/local-auth.addon.mjs +12388 -0
  471. package/system/dist/builtins/local-auth/oauth-grants.d.ts +71 -0
  472. package/system/dist/builtins/local-auth/oauth-session-manager.d.ts +44 -0
  473. package/system/dist/builtins/local-auth/person-scopes.d.ts +7 -0
  474. package/system/dist/builtins/local-auth/preferences-record-kinds.d.ts +27 -0
  475. package/system/dist/builtins/local-auth/record-kinds.d.ts +137 -0
  476. package/system/dist/builtins/local-auth/user-preferences-store.d.ts +56 -0
  477. package/system/dist/builtins/local-network/address-book.d.ts +128 -0
  478. package/system/dist/builtins/local-network/agent-mdns.d.ts +56 -0
  479. package/system/dist/builtins/local-network/hub-mdns-ciao.d.ts +7 -0
  480. package/system/dist/builtins/local-network/hub-mdns.d.ts +58 -0
  481. package/system/dist/builtins/local-network/index.d.ts +1 -0
  482. package/system/dist/builtins/local-network/index.js +10 -0
  483. package/system/dist/builtins/local-network/index.mjs +2 -0
  484. package/system/dist/builtins/local-network/ipv6-lan.d.ts +21 -0
  485. package/system/dist/builtins/local-network/local-hostname.d.ts +15 -0
  486. package/system/dist/builtins/local-network/local-network.addon.d.ts +334 -0
  487. package/system/dist/builtins/local-network/local-network.addon.js +2487 -0
  488. package/system/dist/builtins/local-network/local-network.addon.mjs +2466 -0
  489. package/system/dist/builtins/local-network/scan/dns-wire.d.ts +17 -0
  490. package/system/dist/builtins/local-network/scan/scan-engine.d.ts +31 -0
  491. package/system/dist/builtins/local-network/scan/scan-io-node.d.ts +2 -0
  492. package/system/dist/builtins/local-network/scan/scan-io.d.ts +56 -0
  493. package/system/dist/builtins/local-network/scan/subnets.d.ts +57 -0
  494. package/system/dist/builtins/loki-logging/index.d.ts +4 -0
  495. package/system/dist/builtins/loki-logging/index.js +915 -0
  496. package/system/dist/builtins/loki-logging/index.mjs +901 -0
  497. package/system/dist/builtins/loki-logging/loki-destination.d.ts +142 -0
  498. package/system/dist/builtins/loki-logging/loki-logging.addon.d.ts +66 -0
  499. package/system/dist/builtins/loki-logging/loki-payload.d.ts +100 -0
  500. package/system/dist/builtins/loki-logging/loki-read.d.ts +51 -0
  501. package/system/dist/builtins/loki-logging/retire-enabled-flag.d.ts +48 -0
  502. package/system/dist/builtins/native-metrics/cgroup-memory.d.ts +240 -0
  503. package/system/dist/builtins/native-metrics/cgroup-pids.d.ts +159 -0
  504. package/system/dist/builtins/native-metrics/container-memory-ring.d.ts +18 -0
  505. package/system/dist/builtins/native-metrics/darwin-memory.d.ts +26 -0
  506. package/system/dist/builtins/native-metrics/gpu-probe.d.ts +18 -0
  507. package/system/dist/builtins/native-metrics/index.d.ts +2 -0
  508. package/system/dist/builtins/native-metrics/load-series-config.d.ts +83 -0
  509. package/system/dist/builtins/native-metrics/load-series-reader.d.ts +63 -0
  510. package/system/dist/builtins/native-metrics/load-series-types.d.ts +14 -0
  511. package/system/dist/builtins/native-metrics/native-metrics-provider.d.ts +49 -0
  512. package/system/dist/builtins/native-metrics/native-metrics.addon.d.ts +233 -0
  513. package/system/dist/builtins/native-metrics/native-metrics.addon.js +3116 -0
  514. package/system/dist/builtins/native-metrics/native-metrics.addon.mjs +3106 -0
  515. package/system/dist/builtins/native-metrics/node-load-ring.d.ts +212 -0
  516. package/system/dist/builtins/native-metrics/node-metrics-history-recorder.d.ts +155 -0
  517. package/system/dist/builtins/native-metrics/proc-process-table.d.ts +25 -0
  518. package/system/dist/builtins/native-metrics/process-classification.d.ts +110 -0
  519. package/system/dist/builtins/native-metrics/thread-cpu-sampler.d.ts +116 -0
  520. package/system/dist/builtins/platform-probe/accelerator-facts-probe.d.ts +24 -0
  521. package/system/dist/builtins/platform-probe/accelerator-reprobe.d.ts +23 -0
  522. package/system/dist/builtins/platform-probe/amd-accelerators.d.ts +15 -0
  523. package/system/dist/builtins/platform-probe/amd-npu.d.ts +35 -0
  524. package/system/dist/builtins/platform-probe/coral-accelerators.d.ts +87 -0
  525. package/system/dist/builtins/platform-probe/index.d.ts +57 -0
  526. package/system/dist/builtins/platform-probe/index.js +1151 -0
  527. package/system/dist/builtins/platform-probe/index.mjs +1140 -0
  528. package/system/dist/builtins/platform-probe/inference-config-resolver.d.ts +29 -0
  529. package/system/dist/builtins/platform-probe/intel-accelerators.d.ts +14 -0
  530. package/system/dist/builtins/platform-probe/intel-npu.d.ts +38 -0
  531. package/system/dist/builtins/platform-probe/platform-scorer.d.ts +66 -0
  532. package/system/dist/builtins/platform-probe/runtime-packages.d.ts +6 -0
  533. package/system/dist/builtins/platform-probe/windows-hardware.d.ts +77 -0
  534. package/system/dist/builtins/record-entries/entries-service.d.ts +42 -0
  535. package/system/dist/builtins/record-entries/index.d.ts +1 -0
  536. package/system/dist/builtins/record-entries/index.js +162 -0
  537. package/system/dist/builtins/record-entries/index.mjs +156 -0
  538. package/system/dist/builtins/record-entries/record-entries.addon.d.ts +13 -0
  539. package/system/dist/builtins/records-isolated.d.ts +10 -0
  540. package/system/dist/builtins/remote-access-orchestrator/enabled-providers-reconcile.d.ts +96 -0
  541. package/system/dist/builtins/remote-access-orchestrator/index.d.ts +1 -0
  542. package/system/dist/builtins/remote-access-orchestrator/index.js +8 -0
  543. package/system/dist/builtins/remote-access-orchestrator/index.mjs +2 -0
  544. package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.d.ts +71 -0
  545. package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +214 -0
  546. package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +208 -0
  547. package/system/dist/builtins/shared/device-state-changed.d.ts +16 -0
  548. package/system/dist/builtins/shared/settle-sources.d.ts +22 -0
  549. package/system/dist/builtins/snapshot/index.d.ts +2 -0
  550. package/system/dist/builtins/snapshot/index.js +2720 -0
  551. package/system/dist/builtins/snapshot/index.mjs +2713 -0
  552. package/system/dist/builtins/snapshot/snapshot-cache.d.ts +108 -0
  553. package/system/dist/builtins/snapshot/snapshot-coalescing.d.ts +135 -0
  554. package/system/dist/builtins/snapshot/snapshot-courtesy.d.ts +68 -0
  555. package/system/dist/builtins/snapshot/snapshot-durable-store.d.ts +36 -0
  556. package/system/dist/builtins/snapshot/snapshot-fatigue.d.ts +41 -0
  557. package/system/dist/builtins/snapshot/snapshot-grab-pick.d.ts +20 -0
  558. package/system/dist/builtins/snapshot/snapshot-link-url.d.ts +66 -0
  559. package/system/dist/builtins/snapshot/snapshot-media-handler.d.ts +121 -0
  560. package/system/dist/builtins/snapshot/snapshot-resize.d.ts +75 -0
  561. package/system/dist/builtins/snapshot/snapshot.addon.d.ts +581 -0
  562. package/system/dist/builtins/sqlite-storage/analyze-stats.d.ts +83 -0
  563. package/system/dist/builtins/sqlite-storage/config-store.d.ts +8 -0
  564. package/system/dist/builtins/sqlite-storage/database-snapshot-provider.d.ts +18 -0
  565. package/system/dist/builtins/sqlite-storage/device-store.d.ts +23 -0
  566. package/system/dist/builtins/sqlite-storage/file-host-client.d.ts +75 -0
  567. package/system/dist/builtins/sqlite-storage/file-host-handlers.d.ts +27 -0
  568. package/system/dist/builtins/sqlite-storage/file-host-protocol.d.ts +167 -0
  569. package/system/dist/builtins/sqlite-storage/file-host-worker.d.ts +1 -0
  570. package/system/dist/builtins/sqlite-storage/filesystem-browse-provider.d.ts +25 -0
  571. package/system/dist/builtins/sqlite-storage/filesystem-storage-provider.d.ts +83 -0
  572. package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.d.ts +33 -0
  573. package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.js +419 -0
  574. package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +411 -0
  575. package/system/dist/builtins/sqlite-storage/filter-compiler.d.ts +126 -0
  576. package/system/dist/builtins/sqlite-storage/index.d.ts +12 -0
  577. package/system/dist/builtins/sqlite-storage/index.js +82 -0
  578. package/system/dist/builtins/sqlite-storage/index.mjs +50 -0
  579. package/system/dist/builtins/sqlite-storage/integration-record-kinds.d.ts +31 -0
  580. package/system/dist/builtins/sqlite-storage/integration-registry.d.ts +34 -0
  581. package/system/dist/builtins/sqlite-storage/migrations/migration-actions.d.ts +12 -0
  582. package/system/dist/builtins/sqlite-storage/migrations/migration-edits.d.ts +35 -0
  583. package/system/dist/builtins/sqlite-storage/migrations/migration-engine.d.ts +125 -0
  584. package/system/dist/builtins/sqlite-storage/migrations/migration-hold.d.ts +23 -0
  585. package/system/dist/builtins/sqlite-storage/migrations/migration-pass.d.ts +48 -0
  586. package/system/dist/builtins/sqlite-storage/migrations/migration-restore-marker.d.ts +3 -0
  587. package/system/dist/builtins/sqlite-storage/migrations/migration-types.d.ts +151 -0
  588. package/system/dist/builtins/sqlite-storage/migrations/migrations-provider.d.ts +61 -0
  589. package/system/dist/builtins/sqlite-storage/owned-sqlite-file.d.ts +173 -0
  590. package/system/dist/builtins/sqlite-storage/path-guard.d.ts +11 -0
  591. package/system/dist/builtins/sqlite-storage/placement-errors.d.ts +60 -0
  592. package/system/dist/builtins/sqlite-storage/placement-router.d.ts +85 -0
  593. package/system/dist/builtins/sqlite-storage/prefix-range.d.ts +50 -0
  594. package/system/dist/builtins/sqlite-storage/query-bounds.d.ts +110 -0
  595. package/system/dist/builtins/sqlite-storage/query-profiler.d.ts +242 -0
  596. package/system/dist/builtins/sqlite-storage/records/records-catalog.d.ts +27 -0
  597. package/system/dist/builtins/sqlite-storage/records/records-engine-types.d.ts +48 -0
  598. package/system/dist/builtins/sqlite-storage/records/records-engine.d.ts +115 -0
  599. package/system/dist/builtins/sqlite-storage/records/records-explain.d.ts +18 -0
  600. package/system/dist/builtins/sqlite-storage/records/records-plan.d.ts +95 -0
  601. package/system/dist/builtins/sqlite-storage/records/records-probe.d.ts +33 -0
  602. package/system/dist/builtins/sqlite-storage/records/records-provider.d.ts +72 -0
  603. package/system/dist/builtins/sqlite-storage/records/records-rows.d.ts +46 -0
  604. package/system/dist/builtins/sqlite-storage/records/records-sql.d.ts +39 -0
  605. package/system/dist/builtins/sqlite-storage/retired-settings-keys.d.ts +276 -0
  606. package/system/dist/builtins/sqlite-storage/shm-lock-canary.d.ts +60 -0
  607. package/system/dist/builtins/sqlite-storage/sqlite-pragmas.d.ts +191 -0
  608. package/system/dist/builtins/sqlite-storage/sqlite-settings-backend.d.ts +583 -0
  609. package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.d.ts +52 -0
  610. package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.js +2960 -0
  611. package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +2952 -0
  612. package/system/dist/builtins/sqlite-storage/sqlite-snapshot-protocol.d.ts +54 -0
  613. package/system/dist/builtins/sqlite-storage/sqlite-snapshot-worker.d.ts +33 -0
  614. package/system/dist/builtins/sqlite-storage/sqlite-snapshotter.d.ts +118 -0
  615. package/system/dist/builtins/sqlite-storage/stale-data/stale-data-audit.d.ts +81 -0
  616. package/system/dist/builtins/sqlite-storage/stale-data/stale-data-ports.d.ts +17 -0
  617. package/system/dist/builtins/sqlite-storage/statement-shape.d.ts +64 -0
  618. package/system/dist/builtins/sqlite-storage/storage-admin-provider.d.ts +33 -0
  619. package/system/dist/builtins/sqlite-storage/table-sizes.d.ts +95 -0
  620. package/system/dist/builtins/sqlite-storage/vector-index-shared.d.ts +81 -0
  621. package/system/dist/builtins/sqlite-storage/vector-index-vec.d.ts +143 -0
  622. package/system/dist/builtins/sqlite-storage/vector-provider.d.ts +30 -0
  623. package/system/dist/builtins/sqlite-storage/wal-checkpoint-policy.d.ts +196 -0
  624. package/system/dist/builtins/sqlite-storage/wal-checkpoint-worker.d.ts +1 -0
  625. package/system/dist/builtins/sqlite-storage/wal-checkpointer.d.ts +76 -0
  626. package/system/dist/builtins/sqlite-storage/wal-maintenance.d.ts +130 -0
  627. package/system/dist/builtins/storage-orchestrator/access-guards.d.ts +43 -0
  628. package/system/dist/builtins/storage-orchestrator/data-store-dispatch.d.ts +39 -0
  629. package/system/dist/builtins/storage-orchestrator/drain-ratchet.d.ts +104 -0
  630. package/system/dist/builtins/storage-orchestrator/drain-state-store.d.ts +26 -0
  631. package/system/dist/builtins/storage-orchestrator/hub-settings-forward.d.ts +128 -0
  632. package/system/dist/builtins/storage-orchestrator/index.d.ts +7 -0
  633. package/system/dist/builtins/storage-orchestrator/index.js +11 -0
  634. package/system/dist/builtins/storage-orchestrator/index.mjs +2 -0
  635. package/system/dist/builtins/storage-orchestrator/location-class-paths.d.ts +13 -0
  636. package/system/dist/builtins/storage-orchestrator/location-history-recorder.d.ts +76 -0
  637. package/system/dist/builtins/storage-orchestrator/location-occupancy-slice.d.ts +71 -0
  638. package/system/dist/builtins/storage-orchestrator/location-occupancy.d.ts +19 -0
  639. package/system/dist/builtins/storage-orchestrator/location-protection.d.ts +20 -0
  640. package/system/dist/builtins/storage-orchestrator/location-repoint-move.d.ts +57 -0
  641. package/system/dist/builtins/storage-orchestrator/location-repointer.d.ts +97 -0
  642. package/system/dist/builtins/storage-orchestrator/location-root-collision.d.ts +80 -0
  643. package/system/dist/builtins/storage-orchestrator/location-secrets.d.ts +114 -0
  644. package/system/dist/builtins/storage-orchestrator/location-store.d.ts +82 -0
  645. package/system/dist/builtins/storage-orchestrator/location-volume-capacity.d.ts +58 -0
  646. package/system/dist/builtins/storage-orchestrator/provider-discovery.d.ts +24 -0
  647. package/system/dist/builtins/storage-orchestrator/record-kinds.d.ts +43 -0
  648. package/system/dist/builtins/storage-orchestrator/storage-cleanup-coordinator.d.ts +68 -0
  649. package/system/dist/builtins/storage-orchestrator/storage-location-band-monitor.d.ts +77 -0
  650. package/system/dist/builtins/storage-orchestrator/storage-migration-coordinator.d.ts +241 -0
  651. package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.d.ts +318 -0
  652. package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +5280 -0
  653. package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +5264 -0
  654. package/system/dist/builtins/storage-orchestrator/storage-orchestrator.service.d.ts +475 -0
  655. package/system/dist/builtins/storage-orchestrator/storage-pressure-manager.d.ts +115 -0
  656. package/system/dist/builtins/system-backup/backup-encryption.d.ts +94 -0
  657. package/system/dist/builtins/system-backup/system-backup.service.d.ts +308 -0
  658. package/system/dist/builtins/system-config/index.d.ts +2 -0
  659. package/system/dist/builtins/system-config/index.js +10 -0
  660. package/system/dist/builtins/system-config/index.mjs +2 -0
  661. package/system/dist/builtins/system-config/mesh-actions.d.ts +3 -0
  662. package/system/dist/builtins/system-config/record-kinds.d.ts +32 -0
  663. package/system/dist/builtins/system-config/system-config.addon.d.ts +56 -0
  664. package/system/dist/builtins/system-config/system-config.addon.js +89334 -0
  665. package/system/dist/builtins/system-config/system-config.addon.mjs +89233 -0
  666. package/system/dist/builtins/winston-logging/index.d.ts +3 -0
  667. package/system/dist/builtins/winston-logging/index.js +324 -0
  668. package/system/dist/builtins/winston-logging/index.mjs +313 -0
  669. package/system/dist/builtins/winston-logging/log-file-cursor.d.ts +12 -0
  670. package/system/dist/builtins/winston-logging/log-file-index-store.d.ts +11 -0
  671. package/system/dist/builtins/winston-logging/log-file-index.d.ts +77 -0
  672. package/system/dist/builtins/winston-logging/log-file-read-client.d.ts +44 -0
  673. package/system/dist/builtins/winston-logging/log-file-read-protocol.d.ts +41 -0
  674. package/system/dist/builtins/winston-logging/log-file-read-worker.d.ts +1 -0
  675. package/system/dist/builtins/winston-logging/log-file-reader.d.ts +51 -0
  676. package/system/dist/builtins/winston-logging/winston-destination.d.ts +39 -0
  677. package/system/dist/builtins/winston-logging/winston-logging.addon.d.ts +20 -0
  678. package/system/dist/chunk-CNf5ZN-e.mjs +37 -0
  679. package/system/dist/chunk-Cek0wNdY.js +64 -0
  680. package/system/dist/composition-sources-C14epb_m.js +155 -0
  681. package/system/dist/composition-sources-EXNuxmGQ.mjs +132 -0
  682. package/system/dist/constants-DIGWBiNC.mjs +20 -0
  683. package/system/dist/constants-M7NtSiRo.js +66 -0
  684. package/system/dist/coral-accelerators-BSVsBVzt.js +250 -0
  685. package/system/dist/coral-accelerators-DBlgWB8k.mjs +231 -0
  686. package/system/dist/custom-action-registry-JuMHGKEc.js +1638 -0
  687. package/system/dist/custom-action-registry-oHl1xltx.mjs +1482 -0
  688. package/system/dist/device-ca-3vmBP1i0.js +474 -0
  689. package/system/dist/device-ca-DZlvNBWU.mjs +367 -0
  690. package/system/dist/dist-DcMqHB_N.mjs +108095 -0
  691. package/system/dist/dist-M9yHiIY7.js +110554 -0
  692. package/system/dist/download/hosted-model-revisions.d.ts +10 -0
  693. package/system/dist/download/model-download-service.d.ts +35 -0
  694. package/system/dist/download/model-downloader.d.ts +156 -0
  695. package/system/dist/events/event-bus.d.ts +10 -0
  696. package/system/dist/events/system-event-bus.d.ts +14 -0
  697. package/system/dist/feature/feature-manager.d.ts +11 -0
  698. package/system/dist/file-host-worker.js +160 -0
  699. package/system/dist/file-host-worker.mjs +160 -0
  700. package/system/dist/formatter-DkYZ4LXp.mjs +162 -0
  701. package/system/dist/formatter-xbxeV4GD.js +167 -0
  702. package/system/dist/framework-resolver-hook.mjs +49 -0
  703. package/system/dist/http/asset-compression.d.ts +55 -0
  704. package/system/dist/http/authenticated-file-server.d.ts +53 -0
  705. package/system/dist/http/data-plane-registry.d.ts +58 -0
  706. package/system/dist/http/file-data-plane.d.ts +18 -0
  707. package/system/dist/http/lan-http-bind.d.ts +41 -0
  708. package/system/dist/http/reverse-proxy.d.ts +42 -0
  709. package/system/dist/hub-mdns-ciao-CpCKuQnK.js +1163 -0
  710. package/system/dist/hub-mdns-ciao-Czz2ssit.mjs +942 -0
  711. package/system/dist/i18n/catalog-registry.d.ts +35 -0
  712. package/system/dist/i18n/index.d.ts +2 -0
  713. package/system/dist/index.d.ts +156 -0
  714. package/system/dist/index.js +28736 -0
  715. package/system/dist/index.mjs +28065 -0
  716. package/system/dist/intel-accelerators-BvBjZn4j.js +16 -0
  717. package/system/dist/intel-accelerators-idEumqk1.mjs +15 -0
  718. package/system/dist/intel-npu-C8HKvRQF.mjs +27 -0
  719. package/system/dist/intel-npu-DYF5hO5K.js +28 -0
  720. package/system/dist/kernel/addon-class-resolver.d.ts +4 -0
  721. package/system/dist/kernel/addon-engine-manager.d.ts +22 -0
  722. package/system/dist/kernel/addon-health-monitor.d.ts +163 -0
  723. package/system/dist/kernel/addon-installer.d.ts +651 -0
  724. package/system/dist/kernel/addon-loader.d.ts +144 -0
  725. package/system/dist/kernel/addon-manifest.d.ts +128 -0
  726. package/system/dist/kernel/addon-refused-error.d.ts +30 -0
  727. package/system/dist/kernel/addon-residue.d.ts +45 -0
  728. package/system/dist/kernel/addon-settings-store.d.ts +43 -0
  729. package/system/dist/kernel/addon-version-policy.d.ts +34 -0
  730. package/system/dist/kernel/anon-rss.d.ts +12 -0
  731. package/system/dist/kernel/array-buffer-census.d.ts +118 -0
  732. package/system/dist/kernel/bootstrap-config.d.ts +7 -0
  733. package/system/dist/kernel/cap-router-builder.d.ts +180 -0
  734. package/system/dist/kernel/capability-handle.d.ts +46 -0
  735. package/system/dist/kernel/capability-registry.d.ts +621 -0
  736. package/system/dist/kernel/config-manager.d.ts +174 -0
  737. package/system/dist/kernel/config-schema.d.ts +37 -0
  738. package/system/dist/kernel/custom-action-registry.d.ts +32 -0
  739. package/system/dist/kernel/deps/addon-deps-manager.d.ts +28 -0
  740. package/system/dist/kernel/deps/closure-dedupe.d.ts +105 -0
  741. package/system/dist/kernel/deps/ensure-addon-natives.d.ts +41 -0
  742. package/system/dist/kernel/deps/ensure-native-prebuilds.d.ts +40 -0
  743. package/system/dist/kernel/deps/manifest-native-deps.d.ts +42 -0
  744. package/system/dist/kernel/deps/manifest-python-deps.d.ts +20 -0
  745. package/system/dist/kernel/deps/manifest-system-deps.d.ts +18 -0
  746. package/system/dist/kernel/deps/npm-command.d.ts +60 -0
  747. package/system/dist/kernel/deps/system-package-allowlist.d.ts +12 -0
  748. package/system/dist/kernel/deps/system-package-broker.d.ts +31 -0
  749. package/system/dist/kernel/deps/system-package-client.d.ts +9 -0
  750. package/system/dist/kernel/device-call-redirect.d.ts +18 -0
  751. package/system/dist/kernel/device-registry.d.ts +29 -0
  752. package/system/dist/kernel/device-settings-store.d.ts +74 -0
  753. package/system/dist/kernel/event-loop-stall-monitor.d.ts +41 -0
  754. package/system/dist/kernel/event-plane-report.d.ts +225 -0
  755. package/system/dist/kernel/fs-utils.d.ts +88 -0
  756. package/system/dist/kernel/gc-census.d.ts +161 -0
  757. package/system/dist/kernel/heap-spaces.d.ts +112 -0
  758. package/system/dist/kernel/heap-watch.d.ts +816 -0
  759. package/system/dist/kernel/host-externals.d.ts +12 -0
  760. package/system/dist/kernel/hwaccel/hwaccel-resolver.d.ts +56 -0
  761. package/system/dist/kernel/hwaccel/vaapi-init-probe.d.ts +29 -0
  762. package/system/dist/kernel/index.d.ts +116 -0
  763. package/system/dist/kernel/inference/inference-resolver.d.ts +22 -0
  764. package/system/dist/kernel/inference/local-python-runtimes.d.ts +2 -0
  765. package/system/dist/kernel/infra-capabilities.d.ts +13 -0
  766. package/system/dist/kernel/isolated-builtin-phase.d.ts +57 -0
  767. package/system/dist/kernel/lifecycle/job-journal.d.ts +19 -0
  768. package/system/dist/kernel/lifecycle/lifecycle-job-engine.d.ts +106 -0
  769. package/system/dist/kernel/lifecycle/staging-area.d.ts +31 -0
  770. package/system/dist/kernel/moleculer/accessory-prune-gate.d.ts +55 -0
  771. package/system/dist/kernel/moleculer/addon-context-factory.d.ts +104 -0
  772. package/system/dist/kernel/moleculer/addon-data-plane-facility.d.ts +19 -0
  773. package/system/dist/kernel/moleculer/addon-deploy-source.d.ts +16 -0
  774. package/system/dist/kernel/moleculer/addon-peer-bytes-facility.d.ts +25 -0
  775. package/system/dist/kernel/moleculer/addon-runner.d.ts +1 -0
  776. package/system/dist/kernel/moleculer/addon-service-factory.d.ts +50 -0
  777. package/system/dist/kernel/moleculer/agent-event-scope.d.ts +49 -0
  778. package/system/dist/kernel/moleculer/agent-ui-unlock.d.ts +67 -0
  779. package/system/dist/kernel/moleculer/broker-factory.d.ts +95 -0
  780. package/system/dist/kernel/moleculer/broker-transport-swap.d.ts +60 -0
  781. package/system/dist/kernel/moleculer/cap-usage-registry.d.ts +126 -0
  782. package/system/dist/kernel/moleculer/capabilities-access.d.ts +21 -0
  783. package/system/dist/kernel/moleculer/child-addon-call-dispatch.d.ts +53 -0
  784. package/system/dist/kernel/moleculer/child-cap-descriptors.d.ts +34 -0
  785. package/system/dist/kernel/moleculer/child-cap-dispatch.d.ts +59 -0
  786. package/system/dist/kernel/moleculer/children-batch-loader.d.ts +98 -0
  787. package/system/dist/kernel/moleculer/core-cap-service.d.ts +65 -0
  788. package/system/dist/kernel/moleculer/crash-supervisor.d.ts +50 -0
  789. package/system/dist/kernel/moleculer/device-cap-proxy.d.ts +70 -0
  790. package/system/dist/kernel/moleculer/device-event-ring.d.ts +155 -0
  791. package/system/dist/kernel/moleculer/event-bus-core.d.ts +198 -0
  792. package/system/dist/kernel/moleculer/event-bus.d.ts +106 -0
  793. package/system/dist/kernel/moleculer/hub-log-forwarder.d.ts +36 -0
  794. package/system/dist/kernel/moleculer/hub-service.d.ts +39 -0
  795. package/system/dist/kernel/moleculer/init-watchdog.d.ts +60 -0
  796. package/system/dist/kernel/moleculer/mesh-access-middleware.d.ts +42 -0
  797. package/system/dist/kernel/moleculer/mesh-identity.d.ts +57 -0
  798. package/system/dist/kernel/moleculer/mesh-mtls/constants.d.ts +17 -0
  799. package/system/dist/kernel/moleculer/mesh-mtls/index.d.ts +12 -0
  800. package/system/dist/kernel/moleculer/mesh-mtls/mesh-ca-keeper.d.ts +60 -0
  801. package/system/dist/kernel/moleculer/mesh-mtls/mesh-ca.d.ts +49 -0
  802. package/system/dist/kernel/moleculer/mesh-mtls/mesh-certificate-registry.d.ts +105 -0
  803. package/system/dist/kernel/moleculer/mesh-mtls/mesh-crl.d.ts +16 -0
  804. package/system/dist/kernel/moleculer/mesh-mtls/mesh-membership.d.ts +64 -0
  805. package/system/dist/kernel/moleculer/mesh-mtls/mesh-peer-transport.d.ts +47 -0
  806. package/system/dist/kernel/moleculer/mesh-mtls/mesh-renewal.d.ts +135 -0
  807. package/system/dist/kernel/moleculer/mesh-mtls/mesh-tls-enabler.d.ts +9 -0
  808. package/system/dist/kernel/moleculer/mesh-mtls/mesh-tls-gate.d.ts +40 -0
  809. package/system/dist/kernel/moleculer/mesh-mtls/pairing/agent-pairing.d.ts +214 -0
  810. package/system/dist/kernel/moleculer/mesh-mtls/pairing/hub-pairing.d.ts +115 -0
  811. package/system/dist/kernel/moleculer/mesh-mtls/pairing/index.d.ts +3 -0
  812. package/system/dist/kernel/moleculer/mesh-mtls/pairing/pairing-protocol.d.ts +107 -0
  813. package/system/dist/kernel/moleculer/mesh-mtls/tls-tcp-transporter.d.ts +242 -0
  814. package/system/dist/kernel/moleculer/mesh-queue-report.d.ts +51 -0
  815. package/system/dist/kernel/moleculer/node-registry.d.ts +146 -0
  816. package/system/dist/kernel/moleculer/process-context.d.ts +4 -0
  817. package/system/dist/kernel/moleculer/process-service.d.ts +92 -0
  818. package/system/dist/kernel/moleculer/provider-registry.d.ts +28 -0
  819. package/system/dist/kernel/moleculer/readiness-context.d.ts +67 -0
  820. package/system/dist/kernel/moleculer/readiness-service.d.ts +37 -0
  821. package/system/dist/kernel/moleculer/records-api-transport.d.ts +9 -0
  822. package/system/dist/kernel/moleculer/register-framework-resolver.d.ts +8 -0
  823. package/system/dist/kernel/moleculer/register-node-client.d.ts +49 -0
  824. package/system/dist/kernel/moleculer/remote-logger.d.ts +43 -0
  825. package/system/dist/kernel/moleculer/resilient-cap-call.d.ts +28 -0
  826. package/system/dist/kernel/moleculer/runner-addon-settings.d.ts +29 -0
  827. package/system/dist/kernel/moleculer/runner-device-settings.d.ts +39 -0
  828. package/system/dist/kernel/moleculer/runner-heap-flags.d.ts +228 -0
  829. package/system/dist/kernel/moleculer/runner-native-allocator.d.ts +107 -0
  830. package/system/dist/kernel/moleculer/runner-process-group.d.ts +96 -0
  831. package/system/dist/kernel/moleculer/runner-refusal.d.ts +27 -0
  832. package/system/dist/kernel/moleculer/runtime-state-load.d.ts +29 -0
  833. package/system/dist/kernel/moleculer/settings-read-guard.d.ts +49 -0
  834. package/system/dist/kernel/moleculer/stream-probe-service.d.ts +28 -0
  835. package/system/dist/kernel/moleculer/trpc-links.d.ts +244 -0
  836. package/system/dist/kernel/moleculer/typed-array-serde.d.ts +14 -0
  837. package/system/dist/kernel/moleculer/worker-device-restore.d.ts +10 -0
  838. package/system/dist/kernel/outbound-queue-watch.d.ts +94 -0
  839. package/system/dist/kernel/prefix-walk.d.ts +39 -0
  840. package/system/dist/kernel/process-cpu-census.d.ts +74 -0
  841. package/system/dist/kernel/provider-kind-drift.d.ts +21 -0
  842. package/system/dist/kernel/restart-coordinator.d.ts +90 -0
  843. package/system/dist/kernel/sections-store.d.ts +20 -0
  844. package/system/dist/kernel/settings-door-view.d.ts +41 -0
  845. package/system/dist/kernel/settings-read-error.d.ts +35 -0
  846. package/system/dist/kernel/settings-view-types.d.ts +80 -0
  847. package/system/dist/kernel/socket-plane-report.d.ts +268 -0
  848. package/system/dist/kernel/status-overlay.d.ts +38 -0
  849. package/system/dist/kernel/storage-location-registry.d.ts +55 -0
  850. package/system/dist/kernel/store-settings-view.d.ts +14 -0
  851. package/system/dist/kernel/system-settings-mirror.d.ts +46 -0
  852. package/system/dist/kernel/system-settings-policy.d.ts +28 -0
  853. package/system/dist/kernel/transport/cap-action-census.d.ts +218 -0
  854. package/system/dist/kernel/transport/cap-action-name.d.ts +100 -0
  855. package/system/dist/kernel/transport/cap-child-index.d.ts +49 -0
  856. package/system/dist/kernel/transport/cap-route-resolver.d.ts +231 -0
  857. package/system/dist/kernel/transport/cap-route.d.ts +168 -0
  858. package/system/dist/kernel/transport/cap-routing-hints.d.ts +42 -0
  859. package/system/dist/kernel/transport/child-cap-protocol.d.ts +307 -0
  860. package/system/dist/kernel/transport/claimed-get-status.d.ts +39 -0
  861. package/system/dist/kernel/transport/create-local-transport.d.ts +7 -0
  862. package/system/dist/kernel/transport/device-call-redirect.d.ts +39 -0
  863. package/system/dist/kernel/transport/frame-codec.d.ts +122 -0
  864. package/system/dist/kernel/transport/hub-cap-forward.d.ts +96 -0
  865. package/system/dist/kernel/transport/index.d.ts +38 -0
  866. package/system/dist/kernel/transport/local-child-client.d.ts +199 -0
  867. package/system/dist/kernel/transport/local-child-registry.d.ts +654 -0
  868. package/system/dist/kernel/transport/local-endpoint-path.d.ts +6 -0
  869. package/system/dist/kernel/transport/local-transport.d.ts +122 -0
  870. package/system/dist/kernel/transport/parent-unowned-call.d.ts +283 -0
  871. package/system/dist/kernel/transport/peer-answered-error.d.ts +21 -0
  872. package/system/dist/kernel/transport/socket-channel.d.ts +116 -0
  873. package/system/dist/kernel/transport/socket-traffic.d.ts +118 -0
  874. package/system/dist/kernel/transport/uds-event-bridge.d.ts +85 -0
  875. package/system/dist/kernel/transport/uds-event-bus.d.ts +93 -0
  876. package/system/dist/kernel/transport/uds-local-transport.d.ts +18 -0
  877. package/system/dist/kernel/transport/uds-log-ingest.d.ts +43 -0
  878. package/system/dist/kernel/transport/uds-logger.d.ts +44 -0
  879. package/system/dist/kernel/utils/ring-buffer.d.ts +15 -0
  880. package/system/dist/kernel/workspace-detect.d.ts +9 -0
  881. package/system/dist/lib-5THG9eKz.mjs +15545 -0
  882. package/system/dist/lib-C3U1yluo.js +7110 -0
  883. package/system/dist/lib-CZ3g2WTS.js +15549 -0
  884. package/system/dist/lib-DFZblCIu.mjs +7106 -0
  885. package/system/dist/lifecycle/lifecycle-state-machine.d.ts +28 -0
  886. package/system/dist/log-file-read-protocol-B7M3X3bT.mjs +785 -0
  887. package/system/dist/log-file-read-protocol-D0WcLbIV.js +817 -0
  888. package/system/dist/log-file-read-worker.js +64 -0
  889. package/system/dist/log-file-read-worker.mjs +64 -0
  890. package/system/dist/log-read-filter-Bi066jwU.js +134 -0
  891. package/system/dist/log-read-filter-D7Ev3zm-.mjs +93 -0
  892. package/system/dist/logging/formatter.d.ts +57 -0
  893. package/system/dist/logging/log-manager.d.ts +145 -0
  894. package/system/dist/logging/log-read-filter.d.ts +43 -0
  895. package/system/dist/logging/log-redactor.d.ts +30 -0
  896. package/system/dist/logging/log-ring-buffer.d.ts +62 -0
  897. package/system/dist/logging/logging-gate.d.ts +76 -0
  898. package/system/dist/logging/logging-gate.singleton.d.ts +16 -0
  899. package/system/dist/logging/partitioned-log-buffer.d.ts +169 -0
  900. package/system/dist/logging/scoped-logger.d.ts +17 -0
  901. package/system/dist/migrations/hub/index.d.ts +11 -0
  902. package/system/dist/ms-CgH2OFlD.mjs +120 -0
  903. package/system/dist/ms-LB3giGoU.js +124 -0
  904. package/system/dist/network/network-quality.d.ts +11 -0
  905. package/system/dist/notification/notification-service.d.ts +43 -0
  906. package/system/dist/notification/toast-service.d.ts +22 -0
  907. package/system/dist/pipeline/engine-manager-resolver.d.ts +15 -0
  908. package/system/dist/pipeline/pipeline-runner.d.ts +8 -0
  909. package/system/dist/pipeline/pipeline-validator.d.ts +13 -0
  910. package/system/dist/platform-key-source-BWlq0jjn.mjs +23 -0
  911. package/system/dist/platform-key-source-Di7HrlGR.js +40 -0
  912. package/system/dist/prefix-range-D_KueXbQ.js +27 -0
  913. package/system/dist/prefix-range-Dl0znowN.mjs +22 -0
  914. package/system/dist/prefix-walk-DAOBSyH1.mjs +88 -0
  915. package/system/dist/prefix-walk-Dv6MLZlM.js +99 -0
  916. package/system/dist/process/proc-stat.d.ts +75 -0
  917. package/system/dist/process/resource-monitor.d.ts +28 -0
  918. package/system/dist/python/python-env-manager.d.ts +12 -0
  919. package/system/dist/read-all-rows-CVoO1ONM.js +29 -0
  920. package/system/dist/read-all-rows-TaPqdWNF.mjs +25 -0
  921. package/system/dist/records/read-all-rows.d.ts +6 -0
  922. package/system/dist/repl/interfaces.d.ts +31 -0
  923. package/system/dist/repl/repl-engine.d.ts +8 -0
  924. package/system/dist/resource-monitor-Di9daRwI.mjs +96 -0
  925. package/system/dist/resource-monitor-mio9dSCT.js +113 -0
  926. package/system/dist/restore-archive-Cy7jGqiD.js +4325 -0
  927. package/system/dist/restore-archive-DS4nvQ43.mjs +4213 -0
  928. package/system/dist/retention-Dqm_EiVq.mjs +893 -0
  929. package/system/dist/retention-Ufa2fci-.js +1024 -0
  930. package/system/dist/retired-settings-keys-C8nOOr5H.js +381 -0
  931. package/system/dist/retired-settings-keys-u6xQA6r7.mjs +364 -0
  932. package/system/dist/safe-buffer-B1OjL1I9.mjs +42 -0
  933. package/system/dist/safe-buffer-D3aoa-7X.js +46 -0
  934. package/system/dist/settle-sources-Bhsy57y-.js +38 -0
  935. package/system/dist/settle-sources-CDtNC8ub.mjs +33 -0
  936. package/system/dist/snapshot-courtesy-CyFs1M3I.mjs +167 -0
  937. package/system/dist/snapshot-courtesy-D_C5-nC0.js +192 -0
  938. package/system/dist/sqlite-snapshot-protocol-2QaTouWV.mjs +34 -0
  939. package/system/dist/sqlite-snapshot-protocol-B9OndqZv.js +51 -0
  940. package/system/dist/sqlite-snapshot-worker.js +185 -0
  941. package/system/dist/sqlite-snapshot-worker.mjs +179 -0
  942. package/system/dist/src-CnAqG6EF.js +714 -0
  943. package/system/dist/src-hG4grMU4.mjs +709 -0
  944. package/system/dist/storage/fs-storage-backend.d.ts +40 -0
  945. package/system/dist/storage/storage-location-manager.d.ts +23 -0
  946. package/system/dist/storage/storage-manager.d.ts +83 -0
  947. package/system/dist/tls/agent-https-names.d.ts +25 -0
  948. package/system/dist/tls/agent-https.d.ts +111 -0
  949. package/system/dist/tls/boot-tls.d.ts +35 -0
  950. package/system/dist/tls/cert-backdate.d.ts +10 -0
  951. package/system/dist/tls/cert-evaluation.d.ts +41 -0
  952. package/system/dist/tls/cert-identity.d.ts +60 -0
  953. package/system/dist/tls/cert-issue.d.ts +57 -0
  954. package/system/dist/tls/cert-manager.d.ts +124 -0
  955. package/system/dist/tls/cert-name-constraints.d.ts +53 -0
  956. package/system/dist/tls/cert-utc-time.d.ts +1 -0
  957. package/system/dist/tls/https-listener.d.ts +30 -0
  958. package/system/dist/tls/index.d.ts +12 -0
  959. package/system/dist/tls/tls-actions.d.ts +49 -0
  960. package/system/dist/tls/tls-status.d.ts +57 -0
  961. package/system/dist/tls/uploaded-cert.d.ts +46 -0
  962. package/system/dist/wal-checkpoint-policy-BahrTtyD.mjs +186 -0
  963. package/system/dist/wal-checkpoint-policy-d2z2qPqx.js +233 -0
  964. package/system/dist/wal-checkpoint-worker.js +144 -0
  965. package/system/dist/wal-checkpoint-worker.mjs +143 -0
  966. package/system/dist/wal-maintenance-BmugbgS7.js +0 -0
  967. package/system/dist/wal-maintenance-Bnb2QzYG.mjs +0 -0
  968. package/system/dist/x509.es-BRiJgOvu.mjs +11939 -0
  969. package/system/dist/x509.es-WtnRNyYS.js +12076 -0
  970. package/system/package.json +516 -0
@@ -0,0 +1,1482 @@
1
+ import { createHash } from "node:crypto";
2
+ import * as path$1 from "node:path";
3
+ import path from "node:path";
4
+ import { promisify } from "node:util";
5
+ import { HF_REPO, MODEL_FORMATS, describeCustomActions, hfModelUrl } from "@camstack/types/addon";
6
+ import * as fs$1 from "node:fs";
7
+ import { createReadStream, promises } from "node:fs";
8
+ import { createServer } from "node:http";
9
+ import { brotliCompress, constants as constants$1, gzip } from "node:zlib";
10
+ import { PerformanceObserver } from "node:perf_hooks";
11
+ //#region src/download/hosted-model-revisions.ts
12
+ /**
13
+ * GENERATED by `scripts/check-hosted-model-revisions.ts --write` — DO NOT EDIT.
14
+ *
15
+ * The revision of every artefact on the CamStack model mirror, keyed by its
16
+ * path under `https://huggingface.co/camstack/camstack-models/resolve/main/`: the sha256 (`lfs.oid`)
17
+ * of its weight file (`revisionWeightUrl`). `resolveFormatRevision` reads
18
+ * it for every catalog format hosted there (D743, D744). Regenerate after
19
+ * any upload to the mirror; the script without `--write` says when it is due.
20
+ */
21
+ var HOSTED_MODEL_REVISIONS = {
22
+ "animalClassification/animal-classifier/coreml/animal-classifier.mlpackage": "2194acb46c1a957c2db766cce0c6f7c295aafc8ad1983843dcb8bc95eac42a34",
23
+ "animalClassification/animal-classifier/onnx/animal-classifier.onnx": "2ccd51865c1d2d600ff68235f5e72a434cb89555197a872489a2357f50771768",
24
+ "animalClassification/animal-classifier/openvino/animal-classifier.xml": "30edf890ff200e8b5169e7a28fcebe148b0d6a5dd3eb570d7a4de89acc9bd63c",
25
+ "animalClassification/bird-classifier/coreml/bird-classifier.mlpackage": "09d5acd27abc89a139399b70ff6711094c05ace5edd6d40b67bf816a41d39a22",
26
+ "animalClassification/bird-classifier/onnx/bird-classifier.onnx": "64dd1b966628145219f2424b42b18b76b8dc33a0a9d9ce90b8c057397fa76da2",
27
+ "animalClassification/bird-classifier/openvino/bird-classifier.xml": "bef863425e1774fba8bf8809a4d690466eeaf183e8d9278493a584a436304339",
28
+ "animalClassification/bird-classifier/tflite/bird-classifier_edgetpu.tflite": "f5b37245cfda13909a34264df58784981aef8dde3bc8604e0ee42caeba29229c",
29
+ "audioClassification/yamnet/onnx/camstack-yamnet.onnx": "d7459a0aefffef8c1ccc60c8e0a0f0758a724fc1b55b47194b418029e938ea26",
30
+ "audioClassification/yamnet/openvino/camstack-yamnet.xml": "11d9e8f47f8af09245bf6a519bc9967b1ead9ac8f8e89d985289ac0fb07926b7",
31
+ "clip/siglip2/coreml/camstack-siglip2-b16-224-vision.mlpackage": "6fdf1936f91d40a4b9b4fcaabe5b2dcadfc6d8c0e76ab1cc9e18c38e95d60787",
32
+ "clip/siglip2/onnx/camstack-siglip2-b16-224-text.onnx": "df6ffc0c44a49648f903fbf6c46722de416447d065e63db97bd3f8edd9bfc411",
33
+ "clip/siglip2/openvino/camstack-siglip2-b16-224-text.xml": "a85203c195eccea00c9d31af5f3594733353cc6b3a3c2802b4e32dc0136f8dae",
34
+ "clip/siglip2/openvino/camstack-siglip2-b16-224-vision.xml": "2e190c41cfa980c8a7a24cb13ecdd71ae0a08eb8665c22a27314aec64e78f325",
35
+ "faceDetection/yunet/coreml/camstack-yunet-2023mar.mlpackage": "d6296bc3ae3048bf3815ef7df8ee934fde48018276c0b2278f93ba359556103b",
36
+ "faceDetection/yunet/onnx/camstack-yunet-2023mar.onnx": "55df63fd5a5128903ee2b6dd4315aa82979be9a1d6cf83cc154b74cd4bd2c42f",
37
+ "faceDetection/yunet/openvino/camstack-yunet-2023mar.xml": "c246c87702b346a9d1de7a70ea61b256d06c7db59bd895acb1aadeaba1985dff",
38
+ "faceDetection/yunet/tflite/camstack-yunet-2023mar_edgetpu.tflite": "b7214dafaf18b8a5c55c7ea502c783e6a356043c2900ff9e02515a368285e982",
39
+ "faceRecognition/auraface/coreml/camstack-auraface-r100.mlpackage": "c189aaf7d6758dafb1603b4ea7f7c2161b69639434ddbce800e0cc632b26d7e0",
40
+ "faceRecognition/auraface/onnx/camstack-auraface-r100.onnx": "1c050a0fd76a5770fb94bd35d1ff99648cb31385280d7fba43284b9b6e63277f",
41
+ "faceRecognition/auraface/openvino/camstack-auraface-r100.xml": "e8f53b3a4bc7d13520d561d2610887bffe8438fac71a496ec1cfcce2616734bb",
42
+ "objectDetection/yolo26/coreml/camstack-yolo26l-256.mlpackage": "87968708ab7ee99aac97d1d6644f6b70149b7b2c38b3f2c3c64326c3cc2333e2",
43
+ "objectDetection/yolo26/coreml/camstack-yolo26l-320.mlpackage": "f0a136258aa69978f5647e07ac4019a4f8c8745dc6d6500c8e3a2876d041f9e5",
44
+ "objectDetection/yolo26/coreml/camstack-yolo26l.mlpackage": "b53d9ce65fc0f84dd13e460bf2666362ac6854f645c897dd0e0c6e8691995146",
45
+ "objectDetection/yolo26/coreml/camstack-yolo26m-256.mlpackage": "bf1ac4cb5f2a3749815a36dde6d6e57ce0662a005ccefd435283d4e38c21298d",
46
+ "objectDetection/yolo26/coreml/camstack-yolo26m-320.mlpackage": "4cf582bf1b14fb7abf87f61a1cf198ad2626fedec32873224bc6f2411e6680b7",
47
+ "objectDetection/yolo26/coreml/camstack-yolo26m.mlpackage": "e9a3751fd3c60676ce94fba7d3d9e8cccfcc8711cd55025eb8837ad8b0fe1424",
48
+ "objectDetection/yolo26/coreml/camstack-yolo26n-256.mlpackage": "1c0565e40b4e04194561df09de4c007ccedd4d5d784adf2341f3af7c97f42cb9",
49
+ "objectDetection/yolo26/coreml/camstack-yolo26n-320.mlpackage": "b30bb5ced9c127f0a813c7740c451a1766226dde43e277e01eb9d298d44f17cd",
50
+ "objectDetection/yolo26/coreml/camstack-yolo26n.mlpackage": "1e176157d427b358db9d87613b1a57040d20c7d0b4a7de70e4477e162dd3d4c5",
51
+ "objectDetection/yolo26/coreml/camstack-yolo26s-256.mlpackage": "e4f3ba3ba99d9a068c4e064fd74427b8a2b56c5e1f56f56979886a493068fbd0",
52
+ "objectDetection/yolo26/coreml/camstack-yolo26s-320.mlpackage": "156d8db8d1f2b9d6bc23ce2e123889d6ad79a5ce866dfccc35c0d869df79db64",
53
+ "objectDetection/yolo26/coreml/camstack-yolo26s.mlpackage": "6d760c59e32daea2812258bd6db417ddfc2eb1be6184daef54ba349bd8d0d125",
54
+ "objectDetection/yolo26/coreml/camstack-yolo26x.mlpackage": "62871ed80cd80cf2b742d2a1ac3ff83f534d9f51039febcb966ee173851fcd5d",
55
+ "objectDetection/yolo26/onnx/camstack-yolo26l-256.onnx": "1a5a963e9b76a324e2fa0e111d96b23176e47a5337e12576a755b512f843592b",
56
+ "objectDetection/yolo26/onnx/camstack-yolo26l-320.onnx": "15ee305cb925934dd73d15a398cc76adf8a51ffa430b11da1ba61f3686eb24b3",
57
+ "objectDetection/yolo26/onnx/camstack-yolo26l.onnx": "62e55ec70eb11f19e75c519a10c1632e08d38a9ddb3229450156a6b423780bbc",
58
+ "objectDetection/yolo26/onnx/camstack-yolo26m-256.onnx": "3d2df9b07b06bfafc6487200674ecb899957e56acbf2ea64383ad477cab30072",
59
+ "objectDetection/yolo26/onnx/camstack-yolo26m-320.onnx": "6a4fc7a9a0c61cf2a401407805bb850b49dbe1faf1cf0ae2edc794a8bc61cc51",
60
+ "objectDetection/yolo26/onnx/camstack-yolo26m.onnx": "907982ada658a53736edfcbdde7e9cf0489a54c058da0deea106bcb2794fe6bc",
61
+ "objectDetection/yolo26/onnx/camstack-yolo26n-256.onnx": "352b15664cea1af55f80f96e9b7a0f8338ca2e6b6053bc27152ad82fc689cb58",
62
+ "objectDetection/yolo26/onnx/camstack-yolo26n-320.onnx": "22d8f1c749394509161b9053361dec19be23c3479f0386a50caba418e7e897a7",
63
+ "objectDetection/yolo26/onnx/camstack-yolo26n.onnx": "8f2e6c82ccbc63153c2284546880b1310d832d2b75efea67cb9cda1fa35da968",
64
+ "objectDetection/yolo26/onnx/camstack-yolo26s-256.onnx": "354ff62da4ffd763f1e7b8761c5d070c1d3f3eafc5221a1a52a3f5b8e651471b",
65
+ "objectDetection/yolo26/onnx/camstack-yolo26s-320.onnx": "465069e0eb3d44e45c2de2c57a57c9ff6f1466cda0816d7ca05ce15e388b0ae3",
66
+ "objectDetection/yolo26/onnx/camstack-yolo26s.onnx": "d2e7ed3e5ef3b7fac18628c63d2bef0d5ae144cb2c239b195eb90ff96437fed5",
67
+ "objectDetection/yolo26/onnx/camstack-yolo26x.onnx": "6d10ddc274ea5e6597c69471a3e122eee7a4cb2a831c9449b30b0e69f4349133",
68
+ "objectDetection/yolo26/openvino/camstack-yolo26l-256-int8.xml": "d9a65db447fa54dda9f039ed11861c12b8f88e9d9e3adb845afd3bf1a34ba2ff",
69
+ "objectDetection/yolo26/openvino/camstack-yolo26l-256.xml": "0c78828d4abe9858bb7ff543ee656adb874c11a76cbacbdcca7777d356be2ee3",
70
+ "objectDetection/yolo26/openvino/camstack-yolo26l-320-int8.xml": "9c441c07c7c2d47982b44a2f2d22af0d77ffd466f7279b843c9bbe21cd07a5d8",
71
+ "objectDetection/yolo26/openvino/camstack-yolo26l-320.xml": "0c78828d4abe9858bb7ff543ee656adb874c11a76cbacbdcca7777d356be2ee3",
72
+ "objectDetection/yolo26/openvino/camstack-yolo26l-fp16.xml": "653a3bf71753672f56a2c8dae65195c8c99029abb3d3d7a42e25860a2071df39",
73
+ "objectDetection/yolo26/openvino/camstack-yolo26l-int8.xml": "a6a760af97893569fa25bfac05bd3a65c70c643f232a0f24b380adcc2358efe4",
74
+ "objectDetection/yolo26/openvino/camstack-yolo26l.xml": "653a3bf71753672f56a2c8dae65195c8c99029abb3d3d7a42e25860a2071df39",
75
+ "objectDetection/yolo26/openvino/camstack-yolo26m-256-int8.xml": "01e7c969481cbe74ea21e137ce7a1dd04c7088557f95b0c4a6e618beb62aa5e0",
76
+ "objectDetection/yolo26/openvino/camstack-yolo26m-256.xml": "c5a4c729eceaec91f6af5077fa34b6f5cc17bc2130d07dc13ed883966e15902e",
77
+ "objectDetection/yolo26/openvino/camstack-yolo26m-320-int8.xml": "2b6be63ad9012c85976223ed46c63b80208479544f13221575f62c4b5a815314",
78
+ "objectDetection/yolo26/openvino/camstack-yolo26m-320.xml": "c5a4c729eceaec91f6af5077fa34b6f5cc17bc2130d07dc13ed883966e15902e",
79
+ "objectDetection/yolo26/openvino/camstack-yolo26m-fp16.xml": "4990e60c17e6e1158dca28750e7a50c3a6c72cac4fd1bbac73bba52ac3647c39",
80
+ "objectDetection/yolo26/openvino/camstack-yolo26m-int8.xml": "4aecf5a49612b372549b06b2d4075ef98abfa26d5aa1f7a665b785b9d5cf0074",
81
+ "objectDetection/yolo26/openvino/camstack-yolo26m.xml": "4990e60c17e6e1158dca28750e7a50c3a6c72cac4fd1bbac73bba52ac3647c39",
82
+ "objectDetection/yolo26/openvino/camstack-yolo26n-256-int8.xml": "6f5feaf3b5b6fa8d630af31a633ccba835f19686c22e8c6a43fc4c37329a91ea",
83
+ "objectDetection/yolo26/openvino/camstack-yolo26n-256.xml": "caf498d56ba2288a54734b4d2c73737f77261d1410357f25998e00655c661736",
84
+ "objectDetection/yolo26/openvino/camstack-yolo26n-320-int8.xml": "a3d2c76a0fb382f894830f049833c5e83c7ca6bcd83ff8a02b991dea9d76f409",
85
+ "objectDetection/yolo26/openvino/camstack-yolo26n-320.xml": "caf498d56ba2288a54734b4d2c73737f77261d1410357f25998e00655c661736",
86
+ "objectDetection/yolo26/openvino/camstack-yolo26n-fp16.xml": "77f9da9a6330b130d21e7d9d2338b8f82f3541491c24566b80b4ff2852559b2d",
87
+ "objectDetection/yolo26/openvino/camstack-yolo26n-int8.xml": "7effbdc301a965812ff6c1fa9df8ba50623dc43038ebbbceb2d325ff2afc1208",
88
+ "objectDetection/yolo26/openvino/camstack-yolo26n.xml": "77f9da9a6330b130d21e7d9d2338b8f82f3541491c24566b80b4ff2852559b2d",
89
+ "objectDetection/yolo26/openvino/camstack-yolo26s-256-int8.xml": "be5ade1dc4c0d295a1877f20ee4a4ab9ba8d4d1613e69381ede1a28f84ab4b04",
90
+ "objectDetection/yolo26/openvino/camstack-yolo26s-256.xml": "8e4c513ffe7d571ed1e9545a990a43f6683a8bde04bdc580fdfd8c62e4e3193f",
91
+ "objectDetection/yolo26/openvino/camstack-yolo26s-320-int8.xml": "c02030199cda5083e41599c7aa9dd64d03597e033f03b61c62194de49719de65",
92
+ "objectDetection/yolo26/openvino/camstack-yolo26s-320.xml": "8e4c513ffe7d571ed1e9545a990a43f6683a8bde04bdc580fdfd8c62e4e3193f",
93
+ "objectDetection/yolo26/openvino/camstack-yolo26s-fp16.xml": "bb9355b5e559d646256ad80e4fc2f965c1c1f4905da3c014b7f15bb3d48d9d34",
94
+ "objectDetection/yolo26/openvino/camstack-yolo26s-int8.xml": "4df51b87f65d930ec947d5e7fd2131a9289553083d311d353ed76662c3d47d41",
95
+ "objectDetection/yolo26/openvino/camstack-yolo26s.xml": "bb9355b5e559d646256ad80e4fc2f965c1c1f4905da3c014b7f15bb3d48d9d34",
96
+ "objectDetection/yolo26/openvino/camstack-yolo26x-fp16.xml": "053f64a4dc9c3b81d0b6c1a567c0d0b403eeb33a6771170712c4de1c09fc6f15",
97
+ "objectDetection/yolo26/openvino/camstack-yolo26x-int8.xml": "f0d1f7650af608ede2529fc8272e0db73a3585f46a2ae0d3f954ab8f34d5eda7",
98
+ "objectDetection/yolo26/openvino/camstack-yolo26x.xml": "053f64a4dc9c3b81d0b6c1a567c0d0b403eeb33a6771170712c4de1c09fc6f15",
99
+ "objectDetection/yolov9/coreml/camstack-yolov9c-320.mlpackage": "7999f25b805f92c732a450625021cda97b7185f8c9f98be28be82be1529fe171",
100
+ "objectDetection/yolov9/coreml/camstack-yolov9c-640.mlpackage": "9889ababc524db385a4305ebc1a42ada4dddc8028198d040fbba77c504228932",
101
+ "objectDetection/yolov9/coreml/camstack-yolov9m-320.mlpackage": "e0e0298051c71c79390f1a05f71a2bb882af52c096c70d69674afb84077f6de4",
102
+ "objectDetection/yolov9/coreml/camstack-yolov9m-640.mlpackage": "4c56eef689435b427c53e92e918be386781024c9b77492f9e486dcdd8ea3570c",
103
+ "objectDetection/yolov9/coreml/camstack-yolov9s-320.mlpackage": "6408badb44161268a337f87586ad82f40e4e315a58be460a648407cc38097675",
104
+ "objectDetection/yolov9/coreml/camstack-yolov9s-640.mlpackage": "9f68b8d418b0832e9788f115e2dfabc6ff54fbe5244815adafa0bd9f98204755",
105
+ "objectDetection/yolov9/coreml/camstack-yolov9t-320.mlpackage": "531aa2d14e7e321f2c90219b966cc3781781d0304c7bed7e6c3b75adaa2ada86",
106
+ "objectDetection/yolov9/coreml/camstack-yolov9t-640.mlpackage": "53dfec9857b3c9922fcbd5e9f88f34ed79de26d9bbcf0d705a1c7a4e5ac93398",
107
+ "objectDetection/yolov9/onnx/camstack-yolov9c-320.onnx": "41b48ef6b39f76340c9a2d40182eddf46ab311b68efbdf637148358f27f1f351",
108
+ "objectDetection/yolov9/onnx/camstack-yolov9c-640.onnx": "4b89e489c4f724ae6c7f271350c9bfd4c800c535e1699f2d6b2d7714293bb695",
109
+ "objectDetection/yolov9/onnx/camstack-yolov9m-320.onnx": "602acf6a2189ad713e5aa0393a3b47c04c8303d6907762f66424f168c3e1e55b",
110
+ "objectDetection/yolov9/onnx/camstack-yolov9m-640.onnx": "d0e69881f62ad156ccbe8699611ae2bd4e569431a9c020b3b6a681efdcd1cfea",
111
+ "objectDetection/yolov9/onnx/camstack-yolov9s-320.onnx": "e06ee6345026ab95f90f5f367b01164654376725fa8e263067ebb9f3417f89c3",
112
+ "objectDetection/yolov9/onnx/camstack-yolov9s-640.onnx": "9113734de682b6b9147b8ed331684d4dc65ddc58d33dd95a00d507c88e82b5c4",
113
+ "objectDetection/yolov9/onnx/camstack-yolov9t-320.onnx": "6c0b0a302a5aaabaf17749a3bda15588a0b196d6f16363198b678c68d2aa5d17",
114
+ "objectDetection/yolov9/onnx/camstack-yolov9t-640.onnx": "fd025ab7bf4d81d506a0561917813431dabe3d673aea4182ff61d7e5c803c2c8",
115
+ "objectDetection/yolov9/openvino/camstack-yolov9c-320-fp16.xml": "3bacbbd621df5570d25dc28b4371cd46847f252743a5246481efffbbc63b5c31",
116
+ "objectDetection/yolov9/openvino/camstack-yolov9c-320-int8.xml": "7b58212310486656775c46f94dddcc2b123e44a0eb1714fd83e629f76513e8a7",
117
+ "objectDetection/yolov9/openvino/camstack-yolov9c-640-fp16.xml": "702060a1904f8de7eb68b72ad5024976767ba546c3dc941f8b7c2e5d1a236d0d",
118
+ "objectDetection/yolov9/openvino/camstack-yolov9c-640-int8.xml": "efa8039469d645709b5e0d1df1ee5bad436ae9991daa0180acf3fae5320fd6c4",
119
+ "objectDetection/yolov9/openvino/camstack-yolov9m-320-fp16.xml": "d381e5981e08bad4b8333bba3db48b4c0885883eb1bd524c71e69e2d8b745eaf",
120
+ "objectDetection/yolov9/openvino/camstack-yolov9m-320-int8.xml": "255d49106c59b6974d8edd15dab73fecc33dd8f97a1701b5a75d8bdf98685e5e",
121
+ "objectDetection/yolov9/openvino/camstack-yolov9m-640-fp16.xml": "a64e8867a406c448e65fecea16932d759d85249427c6b43770387904d980d6aa",
122
+ "objectDetection/yolov9/openvino/camstack-yolov9m-640-int8.xml": "ae01a866b2daf2584799b4ee355e59fc83358360b94897d63b7c9765c61001b4",
123
+ "objectDetection/yolov9/openvino/camstack-yolov9s-320-fp16.xml": "d07a908f4e44d3b482fad99fd280e1eff7f12546848b3acdfd478407a12fbaf6",
124
+ "objectDetection/yolov9/openvino/camstack-yolov9s-320-int8.xml": "b8307a4e3cccd8dd784ec11eecf1a1314826d9d96940aa4e4fb425a9002deb81",
125
+ "objectDetection/yolov9/openvino/camstack-yolov9s-640-fp16.xml": "19448578cde92005a143b8de9655e767032e608cea496e154273ed05a97bed1f",
126
+ "objectDetection/yolov9/openvino/camstack-yolov9s-640-int8.xml": "9b87aad33816d9b6e27261f246ec651466c0a664b37e6122449ca83ecd8371fa",
127
+ "objectDetection/yolov9/openvino/camstack-yolov9t-320-fp16.xml": "2f4dc7d06d49af8008fb3da0cdc04a35fdfbc5fafbb2f069822edd826fcc49de",
128
+ "objectDetection/yolov9/openvino/camstack-yolov9t-320-int8.xml": "ee465e0ee5c6ad7c4edc481b506a076045b82236ada80efcf8601a6ba0a7ee86",
129
+ "objectDetection/yolov9/openvino/camstack-yolov9t-640-fp16.xml": "d4dd2278941ccb210d0763d822353f6d951c6a4f4f5a1604d7e3536ce6ffb954",
130
+ "objectDetection/yolov9/openvino/camstack-yolov9t-640-int8.xml": "be2c95951a9f3a6d408bbabd551c99b8a6190f9ff659ae614b9e58cf0e51202c",
131
+ "objectDetection/yolov9/tflite/yolov9-s-relu6-best_320_int8_edgetpu.tflite": "49a38e77439b475d0d259a6d9fe7ea32fcaa58de3748499dd120aceebad9c591",
132
+ "objectDetection/yolov9/tflite/yolov9-s-relu6-tpumax_512_int8_edgetpu.tflite": "f634f60259101556825fd69662f96282e74364b507f83e6382cc34d5d0e6170e",
133
+ "packageDetection/rfdetr-package/coreml/camstack-rfdetr-package.mlpackage": "73e42f03d66011a311bd83a0a3d1890e7eb1b9b2ba2b5688552a5d4fd60e0e72",
134
+ "packageDetection/rfdetr-package/onnx/camstack-rfdetr-package.onnx": "5af96c6b5936f179e317c9e3915b7c7f74ea3625355f97f6a071c3cd5af2475c",
135
+ "packageDetection/rfdetr-package/openvino/camstack-rfdetr-package.xml": "e2cb5bbccb7809d5c7e691a957bc5e008084119bdf29e2c95d6b6b0791e3061a",
136
+ "plateDetection/yolox-tiny-plate/coreml/camstack-yolox-tiny-plate.mlpackage": "a26ae8fe32e458f7396d56bed83b1243e6067f435b08cd6da134273b9151447d",
137
+ "plateDetection/yolox-tiny-plate/onnx/camstack-yolox-tiny-plate.onnx": "f57b5618eafe91bab19bbdcd9af9b0671dbdba30d76a6e0a3a86b0db24bb1ae6",
138
+ "plateDetection/yolox-tiny-plate/openvino/camstack-yolox-tiny-plate.xml": "83b808eb8fcda6f852477e2dbcdd5cad29ab6a8a58e90017714f167c6a345c27",
139
+ "plateDetection/yolox-tiny-plate/tflite/camstack-yolox-tiny-plate_edgetpu.tflite": "0e091263e9c93063f9da822387860a9cd21c0a554e714de276140921487b8e4d",
140
+ "plateRecognition/cct-s-v2-global/coreml/camstack-cct-s-v2-global.mlpackage": "31b9aba671d98ebd847f43a9e2555f7664c70ad11c3e42fdc0add528463fd3ee",
141
+ "plateRecognition/cct-s-v2-global/onnx/camstack-cct-s-v2-global.onnx": "79c3c00f906857e63453bc16cef6b4a0d34821dff685328eff565fd2da559d21",
142
+ "plateRecognition/cct-s-v2-global/openvino/camstack-cct-s-v2-global.xml": "7357db8b5f1c71a8af9376f2e35435bd0c0361f5193b7e02787f513514ecb8ab",
143
+ "segmentation/yolo26-seg/coreml/camstack-yolo26m-seg.mlpackage": "77ac5c932948df6c6d30f232b40302ccbdfc00f97f7fa78a90dbfb7cdb97608f",
144
+ "segmentation/yolo26-seg/coreml/camstack-yolo26n-seg.mlpackage": "81863a6503294d06063a3320de0a45d543d62b9a3d11009c8d54f5d626abd2a0",
145
+ "segmentation/yolo26-seg/coreml/camstack-yolo26s-seg.mlpackage": "47ee5d620a141bffd594afaf84c4362de2ccf74e036b71ec55ae53428ffbdde8",
146
+ "segmentation/yolo26-seg/onnx/camstack-yolo26m-seg.onnx": "c419fdc8cb8e65c8707586f461d59910487392a5b01711cac674559275df1f7b",
147
+ "segmentation/yolo26-seg/onnx/camstack-yolo26n-seg.onnx": "9f2480a359c8a44541b931d44c4a47898122a5b16ce78d8e5611351b1d4531b8",
148
+ "segmentation/yolo26-seg/onnx/camstack-yolo26s-seg.onnx": "88454cc2f5c2ebaf197536568ffb2ae146a48a85c5c053fd8c9f72f117262313",
149
+ "segmentation/yolo26-seg/openvino/camstack-yolo26m-seg.xml": "08eea0ff1ff6b66a03eb255b9a9ce6952908c92c4684347672d666731148b28f",
150
+ "segmentation/yolo26-seg/openvino/camstack-yolo26n-seg.xml": "d592be6c57fb6f0fc00277327b2421d7ec91fbc0da050bd97fab227df1158c5e",
151
+ "segmentation/yolo26-seg/openvino/camstack-yolo26s-seg.xml": "c4508b20dbfe644220850cfc294e99c9fc396bd61443fcc8db8801a4388e9d99",
152
+ "segmentationRefiner/u2netp/coreml/camstack-u2netp.mlpackage": "67a1172b99e8b34493482b0095bcfe9960d423315a9bfe619b149ea7ba187e05",
153
+ "segmentationRefiner/u2netp/onnx/camstack-u2netp.onnx": "309c8469258dda742793dce0ebea8e6dd393174f89934733ecc8b14c76f4ddd8",
154
+ "segmentationRefiner/u2netp/openvino/camstack-u2netp.xml": "d060dec1fd64855daef223f635cb280f174415785318d4dc78af0d86de025397",
155
+ "vehicleClassification/vehicle-type-v1/coreml/vehicle-type-v1.mlpackage": "26cf66168010daa0a1d33a2fc12305e0e7465c977840861b4bf470c8cae8a7b8",
156
+ "vehicleClassification/vehicle-type-v1/onnx/vehicle-type-v1.onnx": "5153b77de54286bcfefddfdfec9e3c1101b10c30bc33e9181cf8c04e0156818f",
157
+ "vehicleClassification/vehicle-type-v1/openvino/vehicle-type-v1.xml": "bf352f4a602d5e6ef5b6df5140972ef68e79076be397a90c10f1efdda59f4a1e"
158
+ };
159
+ //#endregion
160
+ //#region src/download/model-downloader.ts
161
+ function isNonEmptyFile(filePath) {
162
+ return fs$1.existsSync(filePath) && fs$1.statSync(filePath).size > 0;
163
+ }
164
+ /**
165
+ * Sibling files of a single-file (non-directory) format — extra files the
166
+ * format needs, fetched from the same remote directory as `url` and stored
167
+ * flat alongside the main file in `modelsDir`. Catalog-declared via
168
+ * `formatEntry.files`, e.g. OpenVINO IR lists its `.bin` weights next to the
169
+ * `.xml`. The downloader stays format-agnostic; the convention lives in the
170
+ * catalog data (like `MLPACKAGE_FILES` for the directory case).
171
+ */
172
+ function siblingFilesFor(formatEntry) {
173
+ return formatEntry.isDirectory ? [] : formatEntry.files ?? [];
174
+ }
175
+ /** Resolve a sibling's remote URL relative to the main file's directory. */
176
+ function siblingUrl(mainUrl, sibling) {
177
+ return mainUrl.replace(/[^/]+$/, sibling);
178
+ }
179
+ /**
180
+ * The relative filenames a model format occupies under `modelsDir` — the main
181
+ * file (URL basename, or `${id}.${format}` fallback), its declared siblings
182
+ * (e.g. the OpenVINO `.bin` next to the `.xml`), and any `extraFiles`. For a
183
+ * directory bundle the single entry is the bundle dir itself (tar/extract
184
+ * recurse into it).
185
+ *
186
+ * Used by model distribution (P2): the hub tars exactly these names from its
187
+ * `modelsDir` and the agent untars them into its own `modelsDir`, so both ends
188
+ * agree on the on-disk layout without re-deriving it.
189
+ */
190
+ function collectModelFiles(entry, format) {
191
+ const formatEntry = entry.formats[format];
192
+ if (!formatEntry) return [];
193
+ const names = [formatEntry.url.split("/").pop() ?? `${entry.id}.${format}`, ...siblingFilesFor(formatEntry)];
194
+ for (const extra of entry.extraFiles ?? []) names.push(extra.filename);
195
+ return names;
196
+ }
197
+ /**
198
+ * Fetch headers for a model download. No credential: the CamStack model repos
199
+ * are public, and no secret is ever read from the environment (operator rule —
200
+ * a token, if a gated source ever needs one, is a keychain-backed setting).
201
+ */
202
+ function buildHeaders(_url) {
203
+ return { "User-Agent": "CamStack/1.0" };
204
+ }
205
+ var huggingFaceObserver = null;
206
+ /**
207
+ * Register the one observer of Hugging Face reachability in THIS process (the
208
+ * hub wires it to the registry-unreachable alert). Pass `null` to clear. No
209
+ * polling: it only hears the downloads that were being made anyway.
210
+ */
211
+ function setHuggingFaceReachabilityObserver(observer) {
212
+ huggingFaceObserver = observer;
213
+ }
214
+ function isHuggingFaceUrl(url) {
215
+ try {
216
+ const host = new URL(url).hostname;
217
+ return host === "huggingface.co" || host.endsWith(".huggingface.co") || host.endsWith(".hf.co");
218
+ } catch {
219
+ return false;
220
+ }
221
+ }
222
+ function reportHuggingFace(url, outcome) {
223
+ if (huggingFaceObserver === null || !isHuggingFaceUrl(url)) return;
224
+ huggingFaceObserver(outcome);
225
+ }
226
+ function reportHuggingFaceResponse(url, status) {
227
+ reportHuggingFace(url, {
228
+ reached: status < 500,
229
+ detail: `HTTP ${String(status)}`
230
+ });
231
+ }
232
+ function reportHuggingFaceFailure(url, error) {
233
+ reportHuggingFace(url, {
234
+ reached: false,
235
+ detail: error instanceof Error ? error.message : String(error)
236
+ });
237
+ }
238
+ /**
239
+ * A download that the server ANSWERED with a non-2xx status. Typed so a caller
240
+ * can tell "the file is not there" (404/410 — nothing a retry changes) from
241
+ * "the server was unreachable" by the STATUS, never by matching the message:
242
+ * the embedding encoder's requirements gate (D649) sends the first to a
243
+ * terminal state after a bounded number of attempts and only cools down on
244
+ * the second.
245
+ */
246
+ var ModelDownloadHttpError = class extends Error {
247
+ status;
248
+ url;
249
+ constructor(status, url, verb) {
250
+ super(`HTTP ${String(status)} ${verb} ${url}`);
251
+ this.status = status;
252
+ this.url = url;
253
+ this.name = "ModelDownloadHttpError";
254
+ }
255
+ };
256
+ /** True when `err` is a {@link ModelDownloadHttpError} — same process only. */
257
+ function isModelDownloadHttpError(err) {
258
+ return err instanceof ModelDownloadHttpError;
259
+ }
260
+ var DEFAULT_MAX_REDIRECTS = 5;
261
+ function normalizeDownloadOptions(third) {
262
+ if (typeof third === "function") return { onProgress: third };
263
+ return third ?? {};
264
+ }
265
+ function isRedirectStatus(status) {
266
+ return status === 301 || status === 302 || status === 303 || status === 307 || status === 308;
267
+ }
268
+ function resolveRedirectUrl(current, location) {
269
+ return new URL(location, current);
270
+ }
271
+ async function downloadFile(url, destPath, onProgressOrOptions) {
272
+ if (fs$1.existsSync(destPath)) return destPath;
273
+ const opts = normalizeDownloadOptions(onProgressOrOptions);
274
+ const fetchImpl = opts.fetchImpl ?? fetch;
275
+ const maxRedirects = opts.maxRedirects ?? DEFAULT_MAX_REDIRECTS;
276
+ fs$1.mkdirSync(path$1.dirname(destPath), { recursive: true });
277
+ const tmpPath = destPath + ".downloading";
278
+ try {
279
+ let current = url;
280
+ const seen = /* @__PURE__ */ new Set();
281
+ let response;
282
+ const manual = opts.redirectPolicy !== void 0;
283
+ for (let hop = 0; hop <= maxRedirects; hop++) {
284
+ const parsed = new URL(current);
285
+ if (opts.redirectPolicy) opts.redirectPolicy(parsed, hop);
286
+ if (seen.has(parsed.href)) throw new Error(`Redirect loop detected at ${parsed.href}`);
287
+ seen.add(parsed.href);
288
+ const controller = opts.timeoutMs !== void 0 ? new AbortController() : void 0;
289
+ const timer = controller && opts.timeoutMs !== void 0 ? setTimeout(() => controller.abort(), opts.timeoutMs) : void 0;
290
+ try {
291
+ response = await fetchImpl(current, {
292
+ redirect: manual ? "manual" : "follow",
293
+ headers: buildHeaders(current),
294
+ ...controller ? { signal: controller.signal } : {}
295
+ });
296
+ reportHuggingFaceResponse(current, response.status);
297
+ } catch (fetchError) {
298
+ reportHuggingFaceFailure(current, fetchError);
299
+ throw fetchError;
300
+ } finally {
301
+ if (timer) clearTimeout(timer);
302
+ }
303
+ if (manual && isRedirectStatus(response.status)) {
304
+ const location = response.headers.get("location");
305
+ if (!location) throw new Error(`Redirect ${response.status} missing Location header`);
306
+ if (hop >= maxRedirects) throw new Error(`Too many redirects (max ${maxRedirects}) downloading ${url}`);
307
+ current = resolveRedirectUrl(current, location).href;
308
+ continue;
309
+ }
310
+ break;
311
+ }
312
+ if (!response) throw new Error(`No response downloading ${url}`);
313
+ if (manual && isRedirectStatus(response.status)) throw new Error(`Too many redirects (max ${maxRedirects}) downloading ${url}`);
314
+ if (!response.ok) throw new ModelDownloadHttpError(response.status, url, "downloading");
315
+ if (!response.body) throw new Error(`No response body from ${url}`);
316
+ const total = parseInt(response.headers.get("content-length") ?? "0", 10);
317
+ let downloaded = 0;
318
+ const fileStream = fs$1.createWriteStream(tmpPath);
319
+ const reader = response.body.getReader();
320
+ try {
321
+ for (;;) {
322
+ const { done, value } = await reader.read();
323
+ if (done || !value) break;
324
+ downloaded += value.length;
325
+ if (opts.maxBytes !== void 0 && downloaded > opts.maxBytes) throw new Error(`Downloaded ${downloaded} bytes exceeds the ${opts.maxBytes}-byte limit`);
326
+ fileStream.write(value);
327
+ opts.onProgress?.(downloaded, total);
328
+ }
329
+ } finally {
330
+ fileStream.end();
331
+ await new Promise((resolve, reject) => {
332
+ fileStream.on("finish", resolve);
333
+ fileStream.on("error", reject);
334
+ });
335
+ }
336
+ fs$1.renameSync(tmpPath, destPath);
337
+ return destPath;
338
+ } catch (err) {
339
+ try {
340
+ fs$1.unlinkSync(tmpPath);
341
+ } catch {}
342
+ throw err;
343
+ }
344
+ }
345
+ /**
346
+ * Fetch JSON from a URL using native fetch().
347
+ */
348
+ async function fetchJson(url) {
349
+ let response;
350
+ try {
351
+ response = await fetch(url, {
352
+ redirect: "follow",
353
+ headers: buildHeaders(url)
354
+ });
355
+ } catch (fetchError) {
356
+ reportHuggingFaceFailure(url, fetchError);
357
+ throw fetchError;
358
+ }
359
+ reportHuggingFaceResponse(url, response.status);
360
+ if (!response.ok) throw new ModelDownloadHttpError(response.status, url, "fetching");
361
+ return response.json();
362
+ }
363
+ /**
364
+ * Download a model with fallback URLs and optional SHA256 verification.
365
+ * Legacy API preserved for backward compatibility -- delegates to downloadFile().
366
+ */
367
+ async function downloadModel(options) {
368
+ const { url, fallbackUrls = [], destDir, filename, expectedSha256, onProgress } = options;
369
+ const fname = filename ?? url.split("/").pop() ?? "model.bin";
370
+ const destPath = path$1.join(destDir, fname);
371
+ if (fs$1.existsSync(destPath)) return {
372
+ filePath: destPath,
373
+ downloadedBytes: 0,
374
+ fromCache: true
375
+ };
376
+ fs$1.mkdirSync(destDir, { recursive: true });
377
+ const urls = [url, ...fallbackUrls];
378
+ let lastError = null;
379
+ for (const tryUrl of urls) try {
380
+ await downloadFile(tryUrl, destPath, onProgress);
381
+ if (expectedSha256) {
382
+ const hash = await computeSha256(destPath);
383
+ if (hash !== expectedSha256) {
384
+ fs$1.unlinkSync(destPath);
385
+ throw new Error(`SHA256 mismatch: expected ${expectedSha256}, got ${hash}`);
386
+ }
387
+ }
388
+ return {
389
+ filePath: destPath,
390
+ downloadedBytes: fs$1.statSync(destPath).size,
391
+ fromCache: false
392
+ };
393
+ } catch (e) {
394
+ lastError = e;
395
+ if (fs$1.existsSync(destPath)) fs$1.unlinkSync(destPath);
396
+ }
397
+ throw lastError ?? /* @__PURE__ */ new Error(`Failed to download model from ${url}`);
398
+ }
399
+ async function computeSha256(filePath) {
400
+ return new Promise((resolve, reject) => {
401
+ const hash = createHash("sha256");
402
+ const stream = fs$1.createReadStream(filePath);
403
+ stream.on("data", (chunk) => hash.update(chunk));
404
+ stream.on("end", () => resolve(hash.digest("hex")));
405
+ stream.on("error", reject);
406
+ });
407
+ }
408
+ /**
409
+ * Download every file in a HuggingFace directory bundle (e.g. `.mlpackage`)
410
+ * atomically. `knownFiles` lists the relative paths inside the directory; a
411
+ * bundle that declares none is listed through the Hugging Face tree API. The
412
+ * staging directory replaces `destDir` only when every file arrived, so a
413
+ * bundle already on disk keeps serving until then.
414
+ */
415
+ async function downloadDirectory(url, destDir, knownFiles, onProgress) {
416
+ const match = url.match(/huggingface\.co\/([^/]+\/[^/]+)\/resolve\/main\/(.+)/);
417
+ if (!match) throw new Error(`Cannot parse HuggingFace URL: ${url}`);
418
+ const [, repo, dirPath] = match;
419
+ if (repo === void 0 || dirPath === void 0) throw new Error(`Cannot parse HuggingFace URL: ${url}`);
420
+ const relativePaths = knownFiles !== void 0 && knownFiles.length > 0 ? knownFiles : (await listHfFiles(repo, dirPath)).map((f) => f.substring(dirPath.length + 1));
421
+ if (relativePaths.length === 0) throw new Error(`No files found in HuggingFace directory: ${dirPath}`);
422
+ const files = relativePaths.map((f) => ({
423
+ relativePath: f,
424
+ fileUrl: `https://huggingface.co/${repo}/resolve/main/${dirPath}/${f}`
425
+ }));
426
+ const tmpDir = destDir + ".downloading";
427
+ fs$1.rmSync(tmpDir, {
428
+ recursive: true,
429
+ force: true
430
+ });
431
+ fs$1.mkdirSync(tmpDir, { recursive: true });
432
+ let totalDownloaded = 0;
433
+ try {
434
+ for (const file of files) {
435
+ const destPath = path$1.join(tmpDir, file.relativePath);
436
+ fs$1.mkdirSync(path$1.dirname(destPath), { recursive: true });
437
+ await downloadFile(file.fileUrl, destPath, (downloaded, _total) => {
438
+ onProgress?.(totalDownloaded + downloaded, void 0);
439
+ });
440
+ totalDownloaded += fs$1.statSync(destPath).size;
441
+ }
442
+ fs$1.rmSync(destDir, {
443
+ recursive: true,
444
+ force: true
445
+ });
446
+ fs$1.renameSync(tmpDir, destDir);
447
+ } catch (err) {
448
+ fs$1.rmSync(tmpDir, {
449
+ recursive: true,
450
+ force: true
451
+ });
452
+ throw err;
453
+ }
454
+ }
455
+ function isHfTreeEntry(value) {
456
+ return typeof value === "object" && value !== null && "type" in value && typeof value.type === "string" && "path" in value && typeof value.path === "string";
457
+ }
458
+ /** Every file path (repo-relative) under `dirPath`, recursively, via the HF tree API. */
459
+ async function listHfFiles(repo, dirPath) {
460
+ const listing = await fetchJson(`https://huggingface.co/api/models/${repo}/tree/main/${dirPath}`);
461
+ if (!Array.isArray(listing)) throw new Error(`Unexpected HuggingFace tree for ${dirPath}`);
462
+ const files = [];
463
+ for (const entry of listing) {
464
+ if (!isHfTreeEntry(entry)) continue;
465
+ if (entry.type === "file") files.push(entry.path);
466
+ else if (entry.type === "directory") files.push(...await listHfFiles(repo, entry.path));
467
+ }
468
+ return files;
469
+ }
470
+ /**
471
+ * Where a node records the catalog `revision` of the format it downloaded:
472
+ * a sibling of the file or bundle, `<name>.revision` (D743). Outside the
473
+ * bundle, so a `.mlpackage` keeps exactly the hosted files.
474
+ */
475
+ function revisionRecordPath(modelPath) {
476
+ return `${modelPath}.revision`;
477
+ }
478
+ function readRevisionRecord(modelPath) {
479
+ try {
480
+ return fs$1.readFileSync(revisionRecordPath(modelPath), "utf8").trim();
481
+ } catch {
482
+ return null;
483
+ }
484
+ }
485
+ /** The CamStack model mirror. Every artefact under it has a generated revision. */
486
+ var HOSTED_MODEL_MIRROR_PREFIX = hfModelUrl(HF_REPO, "");
487
+ /**
488
+ * The revision a format must be at — the ONE rule every model download path
489
+ * reads (D743, D744). An inline `revision` wins; otherwise a format hosted on
490
+ * the CamStack mirror takes the revision generated for its path from the
491
+ * mirror's LFS metadata (`hosted-model-revisions.ts`); anything else has none.
492
+ */
493
+ function resolveFormatRevision(formatEntry) {
494
+ if (formatEntry.revision !== void 0) return formatEntry.revision;
495
+ if (!formatEntry.url.startsWith(HOSTED_MODEL_MIRROR_PREFIX)) return void 0;
496
+ return HOSTED_MODEL_REVISIONS[formatEntry.url.slice(HOSTED_MODEL_MIRROR_PREFIX.length)];
497
+ }
498
+ /** The member of a Core ML package that holds its weights. */
499
+ var COREML_WEIGHT_MEMBER = "Data/com.apple.CoreML/weights/weight.bin";
500
+ function revisionWeightFile(formatEntry) {
501
+ if (formatEntry.isDirectory) return formatEntry.url.endsWith(".mlpackage") ? {
502
+ in: "bundle",
503
+ member: COREML_WEIGHT_MEMBER
504
+ } : null;
505
+ const weights = siblingFilesFor(formatEntry).find((f) => f.endsWith(".bin"));
506
+ return weights !== void 0 ? {
507
+ in: "sibling",
508
+ name: weights
509
+ } : { in: "main" };
510
+ }
511
+ /** Where the revision's weight file is hosted — what the mirror's `lfs.oid` describes. */
512
+ function revisionWeightUrl(formatEntry) {
513
+ const weights = revisionWeightFile(formatEntry);
514
+ if (weights === null) return null;
515
+ switch (weights.in) {
516
+ case "bundle": return `${formatEntry.url}/${weights.member}`;
517
+ case "sibling": return siblingUrl(formatEntry.url, weights.name);
518
+ case "main": return formatEntry.url;
519
+ }
520
+ }
521
+ function revisionWeightPath(modelsDir, modelPath, formatEntry) {
522
+ const weights = revisionWeightFile(formatEntry);
523
+ if (weights === null) return null;
524
+ switch (weights.in) {
525
+ case "bundle": return path$1.join(modelPath, weights.member);
526
+ case "sibling": return path$1.join(modelsDir, weights.name);
527
+ case "main": return modelPath;
528
+ }
529
+ }
530
+ /**
531
+ * True when the copy at `modelPath` is RECORDED at the revision the format
532
+ * must be at. A format without a revision is current whenever it is present
533
+ * (the behaviour before revisions existed); with one, the node's record must
534
+ * match it — no record means the copy has not been proven current yet.
535
+ */
536
+ function isCurrentRevision(modelPath, formatEntry) {
537
+ const revision = resolveFormatRevision(formatEntry);
538
+ return revision === void 0 || readRevisionRecord(modelPath) === revision;
539
+ }
540
+ function writeRevisionRecord(modelPath, revision) {
541
+ if (revision === void 0) return;
542
+ const record = revisionRecordPath(modelPath);
543
+ const tmp = `${record}.tmp`;
544
+ fs$1.writeFileSync(tmp, `${revision}\n`);
545
+ fs$1.renameSync(tmp, record);
546
+ }
547
+ /**
548
+ * Prove an unrecorded (or differently recorded) copy current by hashing its
549
+ * weight file: when it IS the revision, record it and skip the download. This
550
+ * is what keeps a new revision from re-downloading every copy that already
551
+ * holds the right bytes — a copy fetched before revisions existed, one that a
552
+ * hub distributed, one fetched before the catalog caught up with the mirror.
553
+ */
554
+ async function adoptByHash(modelsDir, modelPath, formatEntry) {
555
+ const revision = resolveFormatRevision(formatEntry);
556
+ if (revision === void 0) return false;
557
+ const weights = revisionWeightPath(modelsDir, modelPath, formatEntry);
558
+ if (weights === null || !isNonEmptyFile(weights)) return false;
559
+ if (await computeSha256(weights) !== revision) return false;
560
+ writeRevisionRecord(modelPath, revision);
561
+ return true;
562
+ }
563
+ /** True when every file of the format is on disk, whatever revision it holds. */
564
+ function isCompleteCopy(modelsDir, modelPath, formatEntry) {
565
+ if (!fs$1.existsSync(modelPath)) return false;
566
+ if (formatEntry.isDirectory) return fs$1.existsSync(path$1.join(modelPath, "Manifest.json"));
567
+ if (fs$1.statSync(modelPath).size <= 0) return false;
568
+ return siblingFilesFor(formatEntry).every((f) => isNonEmptyFile(path$1.join(modelsDir, f)));
569
+ }
570
+ /**
571
+ * Replace a single-file format and its siblings that are already on disk.
572
+ * `downloadFile` keeps an existing file, so every file is fetched to a
573
+ * `.updating` name first and moved over the old one only when ALL of them
574
+ * arrived: a failed fetch leaves the old copy serving.
575
+ */
576
+ async function replaceSingleFileFormat(url, modelPath, modelsDir, siblings, onProgress) {
577
+ const parts = [{
578
+ url,
579
+ dest: modelPath
580
+ }, ...siblings.map((f) => ({
581
+ url: siblingUrl(url, f),
582
+ dest: path$1.join(modelsDir, f)
583
+ }))].map((p) => ({
584
+ ...p,
585
+ staged: `${p.dest}.updating`
586
+ }));
587
+ try {
588
+ for (const [i, part] of parts.entries()) {
589
+ fs$1.rmSync(part.staged, { force: true });
590
+ await downloadFile(part.url, part.staged, i === 0 ? (downloaded, total) => onProgress?.(downloaded, total === 0 ? void 0 : total) : void 0);
591
+ }
592
+ } catch (err) {
593
+ for (const part of parts) fs$1.rmSync(part.staged, { force: true });
594
+ throw err;
595
+ }
596
+ for (const part of parts) fs$1.renameSync(part.staged, part.dest);
597
+ }
598
+ /**
599
+ * Resolve a `ModelCatalogEntry` against `modelsDir`: download model file
600
+ * (or directory bundle) + extra files (labels JSON, charset dict, …),
601
+ * skip if already on disk. Returns the local model path.
602
+ */
603
+ async function ensureModel(modelsDir, entry, format, onProgress) {
604
+ const formatEntry = entry.formats[format];
605
+ if (!formatEntry) throw new Error(`Model "${entry.id}" has no ${format} format. Available: ${Object.keys(entry.formats).join(", ")}`);
606
+ if (entry.extraFiles) for (const extra of entry.extraFiles) await downloadFile(extra.url, path$1.join(modelsDir, extra.filename));
607
+ const filename = formatEntry.url.split("/").pop() ?? `${entry.id}.${format}`;
608
+ const modelPath = path$1.join(modelsDir, filename);
609
+ const siblings = siblingFilesFor(formatEntry);
610
+ let outdated = false;
611
+ if (fs$1.existsSync(modelPath)) if (formatEntry.isDirectory && !fs$1.existsSync(path$1.join(modelPath, "Manifest.json"))) fs$1.rmSync(modelPath, {
612
+ recursive: true,
613
+ force: true
614
+ });
615
+ else if (siblings.some((f) => !isNonEmptyFile(path$1.join(modelsDir, f)))) outdated = !isCurrentRevision(modelPath, formatEntry) && !await adoptByHash(modelsDir, modelPath, formatEntry);
616
+ else if (isCurrentRevision(modelPath, formatEntry) || await adoptByHash(modelsDir, modelPath, formatEntry)) return modelPath;
617
+ else outdated = true;
618
+ fs$1.mkdirSync(modelsDir, { recursive: true });
619
+ if (formatEntry.isDirectory) await downloadDirectory(formatEntry.url, modelPath, formatEntry.files, onProgress);
620
+ else if (outdated) await replaceSingleFileFormat(formatEntry.url, modelPath, modelsDir, siblings, onProgress);
621
+ else {
622
+ await downloadFile(formatEntry.url, modelPath, (downloaded, total) => onProgress?.(downloaded, total === 0 ? void 0 : total));
623
+ for (const sibling of siblings) await downloadFile(siblingUrl(formatEntry.url, sibling), path$1.join(modelsDir, sibling));
624
+ }
625
+ writeRevisionRecord(modelPath, resolveFormatRevision(formatEntry));
626
+ return modelPath;
627
+ }
628
+ /**
629
+ * Walk `entries` and record the revision of every complete copy on disk that
630
+ * hashes to it, so a node's listing reports present models as downloaded
631
+ * without waiting for something to `ensureModel` them. Offline: it reads
632
+ * files and never fetches. A copy already recorded current is not re-hashed.
633
+ */
634
+ async function adoptModelRevisions(modelsDir, entries) {
635
+ const adopted = [];
636
+ const stale = [];
637
+ const seen = /* @__PURE__ */ new Set();
638
+ for (const entry of entries) for (const format of Object.keys(entry.formats).filter(isModelFormat)) {
639
+ const formatEntry = entry.formats[format];
640
+ if (formatEntry === void 0 || resolveFormatRevision(formatEntry) === void 0) continue;
641
+ const modelPath = getModelFilePath(modelsDir, entry, format);
642
+ if (modelPath === null || seen.has(modelPath)) continue;
643
+ seen.add(modelPath);
644
+ if (!isCompleteCopy(modelsDir, modelPath, formatEntry)) continue;
645
+ if (isCurrentRevision(modelPath, formatEntry)) continue;
646
+ const key = `${entry.id}/${format}`;
647
+ if (await adoptByHash(modelsDir, modelPath, formatEntry)) adopted.push(key);
648
+ else stale.push(key);
649
+ }
650
+ return {
651
+ adopted,
652
+ stale
653
+ };
654
+ }
655
+ function isModelFormat(value) {
656
+ return MODEL_FORMATS.some((f) => f === value);
657
+ }
658
+ /** Compute the on-disk path for a given model + format, even when not yet downloaded. */
659
+ function getModelFilePath(modelsDir, entry, format) {
660
+ const formatEntry = entry.formats[format];
661
+ if (!formatEntry) return null;
662
+ const filename = formatEntry.url.split("/").pop() ?? `${entry.id}.${format}`;
663
+ return path$1.join(modelsDir, filename);
664
+ }
665
+ /**
666
+ * True iff the model file (or `Manifest.json` for directory bundles) exists and
667
+ * is non-empty, and — when the format has a revision ({@link
668
+ * resolveFormatRevision}) — the node recorded that same revision for it
669
+ * (D743). Synchronous, so it never hashes: a copy not yet proven current
670
+ * answers false until `ensureModel` or {@link adoptModelRevisions} records it.
671
+ */
672
+ function isModelDownloaded(modelsDir, entry, format) {
673
+ const formatEntry = entry.formats[format];
674
+ if (!formatEntry) return false;
675
+ const modelPath = getModelFilePath(modelsDir, entry, format);
676
+ if (!modelPath || !fs$1.existsSync(modelPath)) return false;
677
+ if (!isCurrentRevision(modelPath, formatEntry)) return false;
678
+ return isCompleteCopy(modelsDir, modelPath, formatEntry);
679
+ }
680
+ /** Remove the on-disk model file/directory. Returns true if something was deleted. */
681
+ function deleteModelFromDisk(modelsDir, entry, format) {
682
+ const modelPath = getModelFilePath(modelsDir, entry, format);
683
+ if (!modelPath || !fs$1.existsSync(modelPath)) return false;
684
+ fs$1.rmSync(revisionRecordPath(modelPath), { force: true });
685
+ const formatEntry = entry.formats[format];
686
+ if (formatEntry?.isDirectory) fs$1.rmSync(modelPath, {
687
+ recursive: true,
688
+ force: true
689
+ });
690
+ else {
691
+ fs$1.unlinkSync(modelPath);
692
+ if (formatEntry) for (const sibling of siblingFilesFor(formatEntry)) {
693
+ const sibPath = path$1.join(modelsDir, sibling);
694
+ if (fs$1.existsSync(sibPath)) fs$1.unlinkSync(sibPath);
695
+ }
696
+ }
697
+ return true;
698
+ }
699
+ //#endregion
700
+ //#region src/download/model-download-service.ts
701
+ /**
702
+ * A catalog-bound face over the shared downloader.
703
+ *
704
+ * Downloading, completeness and the revision contract (D743) are
705
+ * `ensureModel` / `isModelDownloaded`'s — this class only resolves a model id
706
+ * (and a default format) against its catalog and keys progress by model id.
707
+ * It used to carry its own copy of the download loop, which never learnt the
708
+ * revision; one rule now lives in one place.
709
+ *
710
+ * Addons use this via `context.models.ensure(modelId, format)`.
711
+ */
712
+ var ModelDownloadService = class {
713
+ modelsDir;
714
+ onProgress;
715
+ catalog;
716
+ constructor(modelsDir, catalog, onProgress) {
717
+ this.modelsDir = modelsDir;
718
+ this.onProgress = onProgress;
719
+ const map = /* @__PURE__ */ new Map();
720
+ for (const entry of catalog) map.set(entry.id, entry);
721
+ this.catalog = map;
722
+ }
723
+ /**
724
+ * Ensure a model (and its extra files) is downloaded and current.
725
+ * Returns the local filesystem path to the model file/directory.
726
+ */
727
+ async ensure(modelId, format) {
728
+ const entry = this.catalog.get(modelId);
729
+ if (!entry) throw new Error(`ModelDownloadService: unknown model "${modelId}"`);
730
+ const selectedFormat = format ?? this.pickDefaultFormat(entry);
731
+ if (!entry.formats[selectedFormat]) throw new Error(`ModelDownloadService: model "${modelId}" has no ${selectedFormat} format`);
732
+ const onProgress = this.onProgress;
733
+ return ensureModel(this.modelsDir, entry, selectedFormat, onProgress ? (downloaded, total) => onProgress(modelId, downloaded, total ?? 0) : void 0);
734
+ }
735
+ /**
736
+ * Ensure extra files for a model are downloaded.
737
+ * Returns the local paths of all extra files.
738
+ */
739
+ async ensureExtraFiles(modelId) {
740
+ const entry = this.catalog.get(modelId);
741
+ if (!entry) throw new Error(`ModelDownloadService: unknown model "${modelId}"`);
742
+ const extras = entry.extraFiles;
743
+ if (!extras || extras.length === 0) return [];
744
+ const paths = [];
745
+ for (const extra of extras) {
746
+ const destPath = path$1.join(this.modelsDir, extra.filename);
747
+ await downloadFile(extra.url, destPath);
748
+ paths.push(destPath);
749
+ }
750
+ return paths;
751
+ }
752
+ /** Absolute path to the shared models directory. */
753
+ getModelsDir() {
754
+ return this.modelsDir;
755
+ }
756
+ /** True when the model is on disk, complete, and at its revision (D743). */
757
+ isDownloaded(modelId, format) {
758
+ const entry = this.catalog.get(modelId);
759
+ if (!entry) return false;
760
+ return isModelDownloaded(this.modelsDir, entry, format ?? this.pickDefaultFormat(entry));
761
+ }
762
+ /** Get the catalog entry for a model by ID. */
763
+ getEntry(modelId) {
764
+ return this.catalog.get(modelId);
765
+ }
766
+ pickDefaultFormat(entry) {
767
+ for (const fmt of [
768
+ "onnx",
769
+ "coreml",
770
+ "openvino",
771
+ "tflite",
772
+ "pt"
773
+ ]) if (entry.formats[fmt]) return fmt;
774
+ const first = Object.keys(entry.formats)[0];
775
+ if (first) return first;
776
+ throw new Error(`ModelDownloadService: model "${entry.id}" has no formats`);
777
+ }
778
+ };
779
+ //#endregion
780
+ //#region src/http/authenticated-file-server.ts
781
+ /**
782
+ * Authenticated data-plane file-server — a shared host primitive for addons that
783
+ * must serve files (media segments, scrub-frame stores, exported clips) directly
784
+ * to browsers/players, node-direct (NOT through the hub tRPC, per the recording
785
+ * design's "no media bytes traverse the hub").
786
+ *
787
+ * It bundles the three things every such server needs so addons don't re-roll
788
+ * them: CORS (the data plane is cross-origin from the admin-ui — a native
789
+ * `<video src>` is exempt but hls.js / WebCodecs fetch via XHR and are blocked
790
+ * without it), HTTP `Range` (seeking / partial fetch), and a SCOPED TOKEN check.
791
+ *
792
+ * The token rides as the FIRST path segment (`<urlPrefix><token>/<relPath>`) so
793
+ * a player resolving a manifest's RELATIVE child URIs carries it on every
794
+ * sub-request automatically — no per-URI rewriting, no cookies/headers a dumb
795
+ * player can't set. The caller supplies `verifyToken(token, relPath)`; the
796
+ * primitive stays auth-scheme-agnostic.
797
+ *
798
+ * Pure helpers (`parseTokenizedUrl`, `resolveFilePath`, `contentTypeFor`,
799
+ * `parseRangeHeader`) are exported for unit testing; `createAuthenticatedFileServer`
800
+ * is the thin `node:http` glue.
801
+ */
802
+ function corsHeaders(origin) {
803
+ return {
804
+ "access-control-allow-origin": origin,
805
+ "access-control-allow-methods": "GET, HEAD, OPTIONS",
806
+ "access-control-allow-headers": "range",
807
+ "access-control-expose-headers": "content-length, content-range, accept-ranges",
808
+ "access-control-max-age": "86400"
809
+ };
810
+ }
811
+ /**
812
+ * Split a request URL (`<urlPrefix><token>/<relPath>`) into its token + rel
813
+ * path. Returns null for anything outside the prefix or missing either part.
814
+ * `relPath` is URL-decoded; a decode failure → null.
815
+ */
816
+ function parseTokenizedUrl(urlPrefix, urlPath) {
817
+ if (!urlPath.startsWith(urlPrefix)) return null;
818
+ const after = urlPath.slice(urlPrefix.length);
819
+ const slash = after.indexOf("/");
820
+ if (slash <= 0) return null;
821
+ const token = after.slice(0, slash);
822
+ let rel;
823
+ try {
824
+ rel = decodeURIComponent(after.slice(slash + 1));
825
+ } catch {
826
+ return null;
827
+ }
828
+ if (rel.length === 0) return null;
829
+ return {
830
+ token,
831
+ rel
832
+ };
833
+ }
834
+ /**
835
+ * Map a rel path to one candidate absolute path PER root, keeping only roots the
836
+ * path stays within (traversal guard). The handler serves the first candidate
837
+ * that exists. Rejects a path that escapes every root.
838
+ */
839
+ function resolveFilePath(roots, rel) {
840
+ if (rel.length === 0) return { error: "forbidden" };
841
+ const candidates = [];
842
+ for (const rootDir of roots) {
843
+ const root = path.resolve(rootDir);
844
+ const abs = path.resolve(root, rel);
845
+ if (abs === root || abs.startsWith(root + path.sep)) candidates.push(abs);
846
+ }
847
+ if (candidates.length === 0) return { error: "forbidden" };
848
+ return { candidates };
849
+ }
850
+ var DEFAULT_CONTENT_TYPES = {
851
+ ".m3u8": "application/vnd.apple.mpegurl",
852
+ ".m4s": "video/mp4",
853
+ ".mp4": "video/mp4",
854
+ ".idx": "application/octet-stream",
855
+ ".html": "text/html; charset=utf-8",
856
+ ".js": "application/javascript; charset=utf-8",
857
+ ".mjs": "application/javascript; charset=utf-8",
858
+ ".css": "text/css; charset=utf-8",
859
+ ".json": "application/json; charset=utf-8",
860
+ ".map": "application/json; charset=utf-8",
861
+ ".svg": "image/svg+xml",
862
+ ".png": "image/png",
863
+ ".jpg": "image/jpeg",
864
+ ".jpeg": "image/jpeg",
865
+ ".ico": "image/x-icon",
866
+ ".woff2": "font/woff2",
867
+ ".woff": "font/woff",
868
+ ".ttf": "font/ttf"
869
+ };
870
+ function contentTypeFor(filePath, overrides) {
871
+ const ext = path.extname(filePath).toLowerCase();
872
+ return overrides?.[ext] ?? DEFAULT_CONTENT_TYPES[ext] ?? "application/octet-stream";
873
+ }
874
+ /** Parse an HTTP `Range` header against a known size. Null = serve whole file. */
875
+ function parseRangeHeader(header, size) {
876
+ if (!header) return null;
877
+ const m = /^bytes=(\d*)-(\d*)$/.exec(header.trim());
878
+ if (!m) return null;
879
+ const [, rawStart, rawEnd] = m;
880
+ if (rawStart === "" && rawEnd === "") return null;
881
+ let start;
882
+ let end;
883
+ if (rawStart === "") {
884
+ const n = Number(rawEnd);
885
+ if (n <= 0) return null;
886
+ start = Math.max(0, size - n);
887
+ end = size - 1;
888
+ } else {
889
+ start = Number(rawStart);
890
+ end = rawEnd === "" ? size - 1 : Number(rawEnd);
891
+ }
892
+ if (!Number.isFinite(start) || !Number.isFinite(end) || start > end || start >= size) return null;
893
+ return {
894
+ start,
895
+ end: Math.min(end, size - 1)
896
+ };
897
+ }
898
+ /**
899
+ * Start an authenticated file-server. Returns the bound port so the caller can
900
+ * build URLs. `getRoots`/`verifyToken` are invoked per request, so they always
901
+ * reflect the live config.
902
+ */
903
+ async function createAuthenticatedFileServer(opts) {
904
+ const cors = corsHeaders(opts.corsOrigin ?? "*");
905
+ const server = createServer((req, res) => {
906
+ handle(opts, cors, req, res);
907
+ });
908
+ await new Promise((resolve, reject) => {
909
+ server.once("error", reject);
910
+ server.listen(opts.port, () => resolve());
911
+ });
912
+ const addr = server.address();
913
+ return {
914
+ port: typeof addr === "object" && addr ? addr.port : opts.port,
915
+ close: () => new Promise((resolve) => server.close(() => resolve()))
916
+ };
917
+ }
918
+ async function handle(opts, cors, req, res) {
919
+ if (req.method === "OPTIONS") {
920
+ res.writeHead(204, cors).end();
921
+ return;
922
+ }
923
+ if (req.method !== "GET" && req.method !== "HEAD") {
924
+ res.writeHead(405, cors).end();
925
+ return;
926
+ }
927
+ const urlPath = (req.url ?? "").split("?")[0] ?? "";
928
+ const parsed = parseTokenizedUrl(opts.urlPrefix, urlPath);
929
+ if (!parsed) {
930
+ res.writeHead(403, cors).end();
931
+ return;
932
+ }
933
+ if (!opts.verifyToken(parsed.token, parsed.rel)) {
934
+ res.writeHead(401, cors).end();
935
+ return;
936
+ }
937
+ const resolved = resolveFilePath(opts.getRoots(), parsed.rel);
938
+ if ("error" in resolved) {
939
+ res.writeHead(403, cors).end();
940
+ return;
941
+ }
942
+ let absPath = null;
943
+ let size = 0;
944
+ for (const candidate of resolved.candidates) try {
945
+ const st = await promises.stat(candidate);
946
+ if (st.isFile()) {
947
+ absPath = candidate;
948
+ size = st.size;
949
+ break;
950
+ }
951
+ } catch {}
952
+ if (absPath === null) {
953
+ res.writeHead(404, cors).end();
954
+ return;
955
+ }
956
+ const baseHeaders = {
957
+ ...cors,
958
+ "content-type": contentTypeFor(absPath, opts.contentTypes),
959
+ "accept-ranges": "bytes",
960
+ "cache-control": "no-cache"
961
+ };
962
+ const range = parseRangeHeader(req.headers.range, size);
963
+ if (range) {
964
+ res.writeHead(206, {
965
+ ...baseHeaders,
966
+ "content-range": `bytes ${range.start}-${range.end}/${size}`,
967
+ "content-length": String(range.end - range.start + 1)
968
+ });
969
+ if (req.method === "HEAD") {
970
+ res.end();
971
+ return;
972
+ }
973
+ createReadStream(absPath, {
974
+ start: range.start,
975
+ end: range.end
976
+ }).pipe(res);
977
+ return;
978
+ }
979
+ res.writeHead(200, {
980
+ ...baseHeaders,
981
+ "content-length": String(size)
982
+ });
983
+ if (req.method === "HEAD") {
984
+ res.end();
985
+ return;
986
+ }
987
+ createReadStream(absPath).pipe(res);
988
+ }
989
+ //#endregion
990
+ //#region src/http/asset-compression.ts
991
+ /**
992
+ * Content-coding for addon-served static assets: `Accept-Encoding` negotiation,
993
+ * an eligibility rule, and a BOUNDED cache of the compressed bytes.
994
+ *
995
+ * ## Why the ADDON owns the encoding
996
+ *
997
+ * The hub's `/addon/:addonId/*` bridge is registered `{ compress: false }`. That
998
+ * is not an oversight — on 2026-07-16 the global `@fastify/compress` was found
999
+ * emitting an EMPTY brotli stream (`content-encoding: br`, `content-length: 0`)
1000
+ * for any compressible body over its 1 KiB threshold once the body had crossed
1001
+ * the UDS route bridge of a FORKED addon. It silently broke the notifier SVG
1002
+ * icons; the deploy-bundle pull route had already dodged the same class with
1003
+ * `compress: false`. The resolution then, and the contract now, is that an addon
1004
+ * route owns its content-coding END TO END: it negotiates, it compresses, it
1005
+ * stamps `content-encoding` + `Vary`, and the hub pipes those bytes through
1006
+ * untouched (`proxyToUpstream` replays the upstream headers verbatim).
1007
+ *
1008
+ * So compression belongs HERE, in the shared file data-plane, and nowhere above
1009
+ * it. Anything that re-compresses on top of this reintroduces the empty-brotli
1010
+ * bug rather than doubling the ratio.
1011
+ *
1012
+ * ## Why the bytes are cached, and why the cache is bounded
1013
+ *
1014
+ * Measured on the stream-broker embed bundle (`index-<hash>.js`, 1,443,142 B):
1015
+ * gzip-6 → 360,868 B, brotli-5 → 327,419 B in 27 ms, brotli-11 → 293,677 B in
1016
+ * 2,233 ms. Quality 5 is the request-path choice: 77% off the wire for 27 ms
1017
+ * paid ONCE. Quality 11 buys another 2.3% for eighty times the CPU, on a path
1018
+ * where a real client is waiting.
1019
+ *
1020
+ * The cache is an LRU bounded by BOTH entry count and total bytes, and it
1021
+ * refuses assets over {@link COMPRESSION_MAX_ASSET_BYTES} outright. An unbounded
1022
+ * `Map` keyed by URL is how a long-lived process walks into an OOM, and this
1023
+ * repo has already spent a session on one.
1024
+ *
1025
+ * The key carries `mtimeMs` and `size`, so a rebuild that rewrites an asset in
1026
+ * place under an UNCHANGED name (an SPA shell, a service worker) can never be
1027
+ * served from the previous build's bytes.
1028
+ */
1029
+ var brotliAsync = promisify(brotliCompress);
1030
+ var gzipAsync = promisify(gzip);
1031
+ /** LRU bounds. Both are enforced; whichever binds first evicts. */
1032
+ var MAX_CACHE_ENTRIES = 64;
1033
+ var MAX_CACHE_BYTES = 32 * 1024 * 1024;
1034
+ /** Brotli quality — see the file header for the measured trade. */
1035
+ var BROTLI_QUALITY = 5;
1036
+ /**
1037
+ * Content types worth compressing. An ALLOW-list, not a deny-list: an unknown
1038
+ * type (`application/octet-stream`) is assumed to be opaque binary. This is what
1039
+ * keeps jpeg/png/webp/mp4/m4s/woff2 out — running brotli over them burns CPU to
1040
+ * make the body marginally BIGGER.
1041
+ */
1042
+ var COMPRESSIBLE_EXACT = new Set([
1043
+ "application/javascript",
1044
+ "application/ecmascript",
1045
+ "application/json",
1046
+ "application/manifest+json",
1047
+ "application/wasm",
1048
+ "application/xml",
1049
+ "application/xhtml+xml",
1050
+ "application/vnd.apple.mpegurl",
1051
+ "image/svg+xml"
1052
+ ]);
1053
+ /** Is a body of this content type worth compressing at all? */
1054
+ function isCompressibleContentType(contentType) {
1055
+ const base = contentType.split(";")[0]?.trim().toLowerCase() ?? "";
1056
+ if (base.length === 0) return false;
1057
+ if (base.startsWith("text/")) return true;
1058
+ if (base.endsWith("+json") || base.endsWith("+xml")) return true;
1059
+ return COMPRESSIBLE_EXACT.has(base);
1060
+ }
1061
+ /** Parse `Accept-Encoding` into tokens with their q-values (default 1). */
1062
+ function parseAcceptEncoding(header) {
1063
+ if (header === void 0 || header.trim().length === 0) return [];
1064
+ const out = [];
1065
+ for (const part of header.split(",")) {
1066
+ const [rawToken, ...params] = part.split(";");
1067
+ const token = rawToken?.trim().toLowerCase() ?? "";
1068
+ if (token.length === 0) continue;
1069
+ let q = 1;
1070
+ for (const param of params) {
1071
+ const [name, value] = param.split("=");
1072
+ if (name?.trim().toLowerCase() !== "q") continue;
1073
+ const parsed = Number(value?.trim());
1074
+ q = Number.isFinite(parsed) ? parsed : 1;
1075
+ }
1076
+ out.push({
1077
+ token,
1078
+ q
1079
+ });
1080
+ }
1081
+ return out;
1082
+ }
1083
+ function accepts(prefs, token) {
1084
+ const exact = prefs.find((p) => p.token === token);
1085
+ if (exact) return exact.q > 0;
1086
+ const wildcard = prefs.find((p) => p.token === "*");
1087
+ return wildcard !== void 0 && wildcard.q > 0;
1088
+ }
1089
+ /**
1090
+ * Pick a coding for this request: brotli when offered, else gzip, else identity.
1091
+ *
1092
+ * Returns `null` for identity — including when the header is ABSENT. A client
1093
+ * that offers nothing gets the raw bytes; guessing on its behalf is how a
1094
+ * non-negotiating consumer (a native fetch, a probe, an OTA puller) ends up with
1095
+ * a body it cannot read.
1096
+ */
1097
+ function negotiateContentEncoding(acceptEncoding) {
1098
+ const prefs = parseAcceptEncoding(acceptEncoding);
1099
+ if (prefs.length === 0) return null;
1100
+ if (accepts(prefs, "br")) return "br";
1101
+ if (accepts(prefs, "gzip")) return "gzip";
1102
+ return null;
1103
+ }
1104
+ var cache = /* @__PURE__ */ new Map();
1105
+ var inFlight = /* @__PURE__ */ new Map();
1106
+ var compressions = 0;
1107
+ var hits = 0;
1108
+ var cachedBytes = 0;
1109
+ function cacheKey(key) {
1110
+ return `${key.encoding}|${String(key.mtimeMs)}|${String(key.size)}|${key.path}`;
1111
+ }
1112
+ /** Evict least-recently-used entries until both bounds hold. */
1113
+ function evictToBounds() {
1114
+ for (const [k, buf] of cache) {
1115
+ if (cache.size <= MAX_CACHE_ENTRIES && cachedBytes <= MAX_CACHE_BYTES) return;
1116
+ cache.delete(k);
1117
+ cachedBytes -= buf.byteLength;
1118
+ }
1119
+ }
1120
+ async function compressBody(raw, encoding) {
1121
+ if (encoding === "gzip") return await gzipAsync(raw);
1122
+ return await brotliAsync(raw, { params: {
1123
+ [constants$1.BROTLI_PARAM_QUALITY]: BROTLI_QUALITY,
1124
+ [constants$1.BROTLI_PARAM_SIZE_HINT]: raw.byteLength
1125
+ } });
1126
+ }
1127
+ /**
1128
+ * Compressed bytes for one asset, compressing at most once per key.
1129
+ *
1130
+ * `null` means "send the original" — the asset is too large to buffer, the
1131
+ * source could not be read, or compression did not actually shrink it. Every
1132
+ * failure degrades to identity, so this can only ever be an optimisation.
1133
+ *
1134
+ * Concurrent callers for the same key share ONE compression: a cold cache hit by
1135
+ * a dozen parallel asset requests must not run zlib a dozen times.
1136
+ */
1137
+ async function getCompressedAsset(key, readSource) {
1138
+ if (key.size > 8388608) return null;
1139
+ const id = cacheKey(key);
1140
+ const cached = cache.get(id);
1141
+ if (cached) {
1142
+ cache.delete(id);
1143
+ cache.set(id, cached);
1144
+ hits += 1;
1145
+ return cached;
1146
+ }
1147
+ const pending = inFlight.get(id) ?? (async () => {
1148
+ let raw;
1149
+ try {
1150
+ raw = await readSource();
1151
+ } catch {
1152
+ return null;
1153
+ }
1154
+ const out = await compressBody(raw, key.encoding);
1155
+ compressions += 1;
1156
+ if (out.byteLength >= raw.byteLength) return null;
1157
+ cache.set(id, out);
1158
+ cachedBytes += out.byteLength;
1159
+ evictToBounds();
1160
+ return out;
1161
+ })();
1162
+ inFlight.set(id, pending);
1163
+ try {
1164
+ return await pending;
1165
+ } catch {
1166
+ return null;
1167
+ } finally {
1168
+ inFlight.delete(id);
1169
+ }
1170
+ }
1171
+ //#endregion
1172
+ //#region src/http/file-data-plane.ts
1173
+ /**
1174
+ * A ready-made data-plane request handler that serves files from a set of roots
1175
+ * with HTTP `Range`, for addons whose data-plane is "stream files off disk"
1176
+ * (recording playback, scrub-frame stores, exported clips).
1177
+ *
1178
+ * This is the addon-side handler the addon hands to `ctx.dataPlane.serve({ handler })`.
1179
+ * It receives the REAL Node `req`/`res`, resolves the request path against the
1180
+ * addon's roots (traversal-guarded), and streams the file. NO token and NO CORS:
1181
+ * the hub already authenticated the caller and the data plane is same-origin
1182
+ * through the hub's port. Reuses the shared Range/content-type/traversal helpers
1183
+ * so there is one implementation across the standalone file-server and this.
1184
+ *
1185
+ * It also owns its own CONTENT-CODING. The hub bridge is `{ compress: false }`
1186
+ * because the global compressor emits an empty brotli stream over the forked-
1187
+ * addon route bridge, so nothing above this layer will ever compress an addon
1188
+ * body — see `asset-compression.ts` for the incident and the contract.
1189
+ */
1190
+ /** Build a `(req, res)` handler that serves `getRoots()` files with Range. */
1191
+ function createFileDataPlaneHandler(opts) {
1192
+ return async (req, res) => {
1193
+ if (req.method !== "GET" && req.method !== "HEAD") {
1194
+ res.writeHead(405).end();
1195
+ return;
1196
+ }
1197
+ const urlPath = (req.url ?? "/").split("?")[0] ?? "/";
1198
+ let rel;
1199
+ try {
1200
+ rel = decodeURIComponent(urlPath.replace(/^\/+/, ""));
1201
+ } catch {
1202
+ res.writeHead(400).end();
1203
+ return;
1204
+ }
1205
+ if (rel.length === 0) {
1206
+ res.writeHead(404).end();
1207
+ return;
1208
+ }
1209
+ const resolved = resolveFilePath(opts.getRoots(), rel);
1210
+ if ("error" in resolved) {
1211
+ res.writeHead(403).end();
1212
+ return;
1213
+ }
1214
+ let absPath = null;
1215
+ let size = 0;
1216
+ let mtimeMs = 0;
1217
+ for (const candidate of resolved.candidates) try {
1218
+ const st = await promises.stat(candidate);
1219
+ if (st.isFile()) {
1220
+ absPath = candidate;
1221
+ size = st.size;
1222
+ mtimeMs = st.mtimeMs;
1223
+ break;
1224
+ }
1225
+ } catch {}
1226
+ if (absPath === null) {
1227
+ res.writeHead(404).end();
1228
+ return;
1229
+ }
1230
+ const contentType = contentTypeFor(absPath, opts.contentTypes);
1231
+ const compressible = isCompressibleContentType(contentType);
1232
+ const baseHeaders = {
1233
+ "content-type": contentType,
1234
+ "accept-ranges": "bytes",
1235
+ "cache-control": opts.cacheControl?.(rel) ?? "no-cache",
1236
+ ...compressible ? { vary: "accept-encoding" } : {}
1237
+ };
1238
+ const range = parseRangeHeader(req.headers.range, size);
1239
+ if (range) {
1240
+ res.writeHead(206, {
1241
+ ...baseHeaders,
1242
+ "content-range": `bytes ${range.start}-${range.end}/${size}`,
1243
+ "content-length": String(range.end - range.start + 1)
1244
+ });
1245
+ if (req.method === "HEAD") {
1246
+ res.end();
1247
+ return;
1248
+ }
1249
+ createReadStream(absPath, {
1250
+ start: range.start,
1251
+ end: range.end
1252
+ }).pipe(res);
1253
+ return;
1254
+ }
1255
+ const encoding = compressible ? negotiateContentEncoding(req.headers["accept-encoding"]) : null;
1256
+ if (encoding !== null && size >= 1024) {
1257
+ const filePath = absPath;
1258
+ const body = await getCompressedAsset({
1259
+ path: filePath,
1260
+ mtimeMs,
1261
+ size,
1262
+ encoding
1263
+ }, () => promises.readFile(filePath));
1264
+ if (body !== null) {
1265
+ res.writeHead(200, {
1266
+ ...baseHeaders,
1267
+ "content-encoding": encoding,
1268
+ "accept-ranges": "none",
1269
+ "content-length": String(body.byteLength)
1270
+ });
1271
+ if (req.method === "HEAD") {
1272
+ res.end();
1273
+ return;
1274
+ }
1275
+ res.end(body);
1276
+ return;
1277
+ }
1278
+ }
1279
+ res.writeHead(200, {
1280
+ ...baseHeaders,
1281
+ "content-length": String(size)
1282
+ });
1283
+ if (req.method === "HEAD") {
1284
+ res.end();
1285
+ return;
1286
+ }
1287
+ createReadStream(absPath).pipe(res);
1288
+ };
1289
+ }
1290
+ //#endregion
1291
+ //#region src/kernel/event-loop-stall-monitor.ts
1292
+ /**
1293
+ * event-loop-stall-monitor — names the thing that freezes the detection process.
1294
+ *
1295
+ * ## What this exists to settle
1296
+ *
1297
+ * On 2026-08-01/02 inference across the whole fleet stalled in bursts: 759
1298
+ * calls in 90 minutes crossed the runner's 20s deadline, p50 41s and max 80s,
1299
+ * and EVERY one of them eventually resolved. Six explanations were killed with
1300
+ * telemetry alone:
1301
+ *
1302
+ * - not a slow GPU or a wedged pool — the work completes, just enormously late;
1303
+ * - not CPU starvation — hosts sat at 8-48% during the freezes;
1304
+ * - not swap — `pswpin/pswpout` are flat zero on every host;
1305
+ * - not a logging artifact — Loki's timestamp trails the in-process one by
1306
+ * 0.1-1.0s at p95, so the gaps are real, not buffered delivery;
1307
+ * - not the v1.2.30 release — the stalls predate it by a day;
1308
+ * - not only the idle-pool recompile — that is real and hub-side, but the
1309
+ * agent stalls with no eviction and no compile at all.
1310
+ *
1311
+ * What IS established: the 10s stats timer — which touches no inference code —
1312
+ * stops firing for 22-88s and resumes at the same instant the abandoned calls
1313
+ * settle. The event loop itself freezes. From outside the process, GC and a
1314
+ * synchronous block are indistinguishable, and guessing between them is how
1315
+ * this investigation would go wrong. So measure it.
1316
+ *
1317
+ * ## How
1318
+ *
1319
+ * A 1s interval whose LATENESS is the freeze: a tick that arrives 40s late means
1320
+ * the loop was blocked ~39s, whatever blocked it. In the same window the GC
1321
+ * observer accumulates pause time. The two numbers together answer the question
1322
+ * outright:
1323
+ *
1324
+ * - `gcMs` ≈ `stallMs` → garbage collection. Look at heap growth.
1325
+ * - `gcMs` ≈ 0 → something SYNCHRONOUS blocked the loop, and GC is innocent.
1326
+ *
1327
+ * Heap and RSS ride along because if it is GC, the next question is always
1328
+ * "growing since when?".
1329
+ *
1330
+ * Deliberately not a histogram (`monitorEventLoopDelay`): that reports a
1331
+ * distribution, and the question here is about ONE outlier and what coincided
1332
+ * with it.
1333
+ */
1334
+ /** Tick period. Small enough to bound attribution error, large enough to cost
1335
+ * nothing on a process already doing frame work. */
1336
+ var STALL_TICK_MS = 1e3;
1337
+ /**
1338
+ * Report a freeze only past this. The runner's own inference deadline is 20s
1339
+ * and the observed freezes run 22-88s, so this is far below the signal while
1340
+ * staying clear of ordinary scheduling jitter (a busy frame path routinely
1341
+ * overruns a 1s timer by tens of ms).
1342
+ */
1343
+ var STALL_REPORT_MS = 2e3;
1344
+ /**
1345
+ * Attribute a freeze. Pure, because this is the ONE judgement the whole module
1346
+ * exists to make and it must be testable without freezing a real event loop.
1347
+ *
1348
+ * `gc` when garbage collection accounts for most of the stall; a
1349
+ * `synchronous-block` when it accounts for almost none — that verdict points
1350
+ * away from the heap entirely and at whatever ran without yielding.
1351
+ */
1352
+ function attributeStall(stallMs, gcMs, gcCount, longestGcMs) {
1353
+ const share = stallMs > 0 ? gcMs / stallMs : 0;
1354
+ return {
1355
+ stallMs,
1356
+ gcMs,
1357
+ gcCount,
1358
+ longestGcMs,
1359
+ cause: share >= .7 ? "gc" : share <= .2 ? "synchronous-block" : "mixed"
1360
+ };
1361
+ }
1362
+ /**
1363
+ * Start watching. Returns a stop function; safe to call twice.
1364
+ *
1365
+ * Never throws into the caller: a diagnostic that can take the detection
1366
+ * process down is worse than no diagnostic. `PerformanceObserver` for `gc` is
1367
+ * unavailable in some embedded runtimes, and that must degrade to
1368
+ * stall-detection-without-attribution rather than a boot failure.
1369
+ */
1370
+ function startEventLoopStallMonitor(logger, reportThresholdMs = STALL_REPORT_MS) {
1371
+ let gc = {
1372
+ totalMs: 0,
1373
+ count: 0,
1374
+ longestMs: 0
1375
+ };
1376
+ let observer = null;
1377
+ try {
1378
+ observer = new PerformanceObserver((list) => {
1379
+ for (const entry of list.getEntries()) {
1380
+ gc.totalMs += entry.duration;
1381
+ gc.count += 1;
1382
+ if (entry.duration > gc.longestMs) gc.longestMs = entry.duration;
1383
+ }
1384
+ });
1385
+ observer.observe({ entryTypes: ["gc"] });
1386
+ } catch {
1387
+ observer = null;
1388
+ }
1389
+ let expected = Date.now() + STALL_TICK_MS;
1390
+ const timer = setInterval(() => {
1391
+ const now = Date.now();
1392
+ const lateBy = now - expected;
1393
+ const window = gc;
1394
+ gc = {
1395
+ totalMs: 0,
1396
+ count: 0,
1397
+ longestMs: 0
1398
+ };
1399
+ expected = now + STALL_TICK_MS;
1400
+ if (lateBy < reportThresholdMs) return;
1401
+ const verdict = attributeStall(lateBy, Math.round(window.totalMs), window.count, Math.round(window.longestMs));
1402
+ const mem = process.memoryUsage();
1403
+ logger.warn("event loop stalled", { meta: {
1404
+ stallMs: verdict.stallMs,
1405
+ cause: verdict.cause,
1406
+ gcMs: verdict.gcMs,
1407
+ gcCount: verdict.gcCount,
1408
+ longestGcMs: verdict.longestGcMs,
1409
+ gcObserved: observer !== null,
1410
+ heapUsedMb: Math.round(mem.heapUsed / 1e6),
1411
+ heapTotalMb: Math.round(mem.heapTotal / 1e6),
1412
+ rssMb: Math.round(mem.rss / 1e6),
1413
+ externalMb: Math.round(mem.external / 1e6),
1414
+ arrayBuffersMb: Math.round(mem.arrayBuffers / 1e6)
1415
+ } });
1416
+ }, STALL_TICK_MS);
1417
+ timer.unref?.();
1418
+ let stopped = false;
1419
+ return () => {
1420
+ if (stopped) return;
1421
+ stopped = true;
1422
+ clearInterval(timer);
1423
+ observer?.disconnect();
1424
+ };
1425
+ }
1426
+ //#endregion
1427
+ //#region src/kernel/custom-action-registry.ts
1428
+ /**
1429
+ * CustomActionRegistry — per-process registry of addon custom actions.
1430
+ *
1431
+ * Populated at boot from each addon's `AddonInitResult.customActions` +
1432
+ * `handleCustomAction` handler. Rejects actions declared with scope other
1433
+ * than 'system' (today only 'system' is runtime-supported; the descriptor
1434
+ * allows future scopes for forward compat).
1435
+ */
1436
+ var CustomActionRegistry = class {
1437
+ byAddon = /* @__PURE__ */ new Map();
1438
+ registerAddon(addonId, catalog, handler) {
1439
+ const actions = /* @__PURE__ */ new Map();
1440
+ for (const [name, spec] of Object.entries(catalog)) {
1441
+ const scope = spec.scope ?? { kind: "system" };
1442
+ if (scope.kind !== "system") throw new Error(`custom action '${addonId}.${name}' declared scope '${scope.kind}' — not yet implemented`);
1443
+ actions.set(name, {
1444
+ spec,
1445
+ handler: (input, caller) => handler(name, input, caller)
1446
+ });
1447
+ }
1448
+ this.byAddon.set(addonId, actions);
1449
+ }
1450
+ unregisterAddon(addonId) {
1451
+ this.byAddon.delete(addonId);
1452
+ }
1453
+ resolve(addonId, action) {
1454
+ return this.byAddon.get(addonId)?.get(action) ?? null;
1455
+ }
1456
+ listActions(addonId) {
1457
+ return [...this.byAddon.get(addonId)?.keys() ?? []];
1458
+ }
1459
+ listAddons() {
1460
+ return [...this.byAddon.keys()];
1461
+ }
1462
+ /**
1463
+ * Every registered catalog with its schemas stripped, keyed by addon id —
1464
+ * what a runner puts in its register frame so the hub learns the catalogs
1465
+ * from the process that owns them (D444). `hostedAddonIds` are the addons
1466
+ * this runner hosts: each is present in the result, with an EMPTY catalog
1467
+ * when it registered none, so the parent can say "declares no actions" per
1468
+ * addon instead of guessing from an absent key.
1469
+ */
1470
+ describeAll(hostedAddonIds) {
1471
+ const out = {};
1472
+ for (const addonId of hostedAddonIds) out[addonId] = {};
1473
+ for (const [addonId, actions] of this.byAddon) {
1474
+ const catalog = {};
1475
+ for (const [name, entry] of actions) catalog[name] = entry.spec;
1476
+ out[addonId] = describeCustomActions(catalog);
1477
+ }
1478
+ return out;
1479
+ }
1480
+ };
1481
+ //#endregion
1482
+ export { isModelDownloaded as C, setHuggingFaceReachabilityObserver as E, isModelDownloadHttpError as S, revisionWeightUrl as T, downloadFile as _, startEventLoopStallMonitor as a, fetchJson as b, createAuthenticatedFileServer as c, resolveFilePath as d, ModelDownloadService as f, deleteModelFromDisk as g, collectModelFiles as h, attributeStall as i, parseRangeHeader as l, adoptModelRevisions as m, STALL_REPORT_MS as n, createFileDataPlaneHandler as o, ModelDownloadHttpError as p, STALL_TICK_MS as r, contentTypeFor as s, CustomActionRegistry as t, parseTokenizedUrl as u, downloadModel as v, resolveFormatRevision as w, getModelFilePath as x, ensureModel as y };