mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-10-18 20:52:48 +03:00
Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9d99e28d6f | ||
|
|
b80a8bbf2b |
@@ -72,10 +72,10 @@ Variables prefixed with `FRIGATE_` can be referenced in config fields that suppo
|
|||||||
|
|
||||||
Navigate to <NavPath path="Settings > System > Environment variables" /> to add or edit environment variables.
|
Navigate to <NavPath path="Settings > System > Environment variables" /> to add or edit environment variables.
|
||||||
|
|
||||||
| Field | Description |
|
| Field | Description |
|
||||||
| ----------------- | --------------------------------------------------------- |
|
| --------- | --------------------------------------------------------- |
|
||||||
| **Variable name** | The environment variable name (e.g., `FRIGATE_MQTT_USER`) |
|
| **Key** | The environment variable name (e.g., `FRIGATE_MQTT_USER`) |
|
||||||
| **Value** | The value for the variable |
|
| **Value** | The value for the variable |
|
||||||
|
|
||||||
Variables defined here can be referenced elsewhere in your configuration using the `{FRIGATE_VARIABLE_NAME}` syntax.
|
Variables defined here can be referenced elsewhere in your configuration using the `{FRIGATE_VARIABLE_NAME}` syntax.
|
||||||
|
|
||||||
|
|||||||
Generated
+510
-26
@@ -9,7 +9,7 @@
|
|||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@docusaurus/core": "^3.7.0",
|
"@docusaurus/core": "^3.7.0",
|
||||||
"@docusaurus/plugin-content-docs": "^3.7.0",
|
"@docusaurus/plugin-content-docs": "^3.10.1",
|
||||||
"@docusaurus/preset-classic": "^3.7.0",
|
"@docusaurus/preset-classic": "^3.7.0",
|
||||||
"@docusaurus/theme-mermaid": "^3.7.0",
|
"@docusaurus/theme-mermaid": "^3.7.0",
|
||||||
"@inkeep/docusaurus": "^2.0.16",
|
"@inkeep/docusaurus": "^2.0.16",
|
||||||
@@ -3710,20 +3710,20 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@docusaurus/plugin-content-docs": {
|
"node_modules/@docusaurus/plugin-content-docs": {
|
||||||
"version": "3.9.2",
|
"version": "3.10.1",
|
||||||
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-docs/-/plugin-content-docs-3.9.2.tgz",
|
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-docs/-/plugin-content-docs-3.10.1.tgz",
|
||||||
"integrity": "sha512-C5wZsGuKTY8jEYsqdxhhFOe1ZDjH0uIYJ9T/jebHwkyxqnr4wW0jTkB72OMqNjsoQRcb0JN3PcSeTwFlVgzCZg==",
|
"integrity": "sha512-2jRVrtzjf8LClGTHQlwlwuD3wQXRx3WEoF7XUarJ8Ou+0onV+SLtejsyfY9JLpfUh9hPhXM4pbBGkyAY4Bi3HQ==",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@docusaurus/core": "3.9.2",
|
"@docusaurus/core": "3.10.1",
|
||||||
"@docusaurus/logger": "3.9.2",
|
"@docusaurus/logger": "3.10.1",
|
||||||
"@docusaurus/mdx-loader": "3.9.2",
|
"@docusaurus/mdx-loader": "3.10.1",
|
||||||
"@docusaurus/module-type-aliases": "3.9.2",
|
"@docusaurus/module-type-aliases": "3.10.1",
|
||||||
"@docusaurus/theme-common": "3.9.2",
|
"@docusaurus/theme-common": "3.10.1",
|
||||||
"@docusaurus/types": "3.9.2",
|
"@docusaurus/types": "3.10.1",
|
||||||
"@docusaurus/utils": "3.9.2",
|
"@docusaurus/utils": "3.10.1",
|
||||||
"@docusaurus/utils-common": "3.9.2",
|
"@docusaurus/utils-common": "3.10.1",
|
||||||
"@docusaurus/utils-validation": "3.9.2",
|
"@docusaurus/utils-validation": "3.10.1",
|
||||||
"@types/react-router-config": "^5.0.7",
|
"@types/react-router-config": "^5.0.7",
|
||||||
"combine-promises": "^1.1.0",
|
"combine-promises": "^1.1.0",
|
||||||
"fs-extra": "^11.1.1",
|
"fs-extra": "^11.1.1",
|
||||||
@@ -3742,6 +3742,382 @@
|
|||||||
"react-dom": "^18.0.0 || ^19.0.0"
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/babel": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/babel/-/babel-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-DZzFO1K3v/GoEt1fx1DiYHF4en+PuhtQf1AkQJa5zu3CoeKSpr5cpQRUlz3jr0m44wyzmSXu9bVpfir+N4+8bg==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@babel/core": "^7.25.9",
|
||||||
|
"@babel/generator": "^7.25.9",
|
||||||
|
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
|
||||||
|
"@babel/plugin-transform-runtime": "^7.25.9",
|
||||||
|
"@babel/preset-env": "^7.25.9",
|
||||||
|
"@babel/preset-react": "^7.25.9",
|
||||||
|
"@babel/preset-typescript": "^7.25.9",
|
||||||
|
"@babel/runtime": "^7.25.9",
|
||||||
|
"@babel/traverse": "^7.25.9",
|
||||||
|
"@docusaurus/logger": "3.10.1",
|
||||||
|
"@docusaurus/utils": "3.10.1",
|
||||||
|
"babel-plugin-dynamic-import-node": "^2.3.3",
|
||||||
|
"fs-extra": "^11.1.1",
|
||||||
|
"tslib": "^2.6.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/bundler": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/bundler/-/bundler-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-HIqQPvbqnnQRe4NsBd1774KRarjXqS6wHsWELtyuSs1gCfvixJO2jUGH/OEBtr1Gvzpw+ze5CjGMvSJ8UE1KUw==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@babel/core": "^7.25.9",
|
||||||
|
"@docusaurus/babel": "3.10.1",
|
||||||
|
"@docusaurus/cssnano-preset": "3.10.1",
|
||||||
|
"@docusaurus/logger": "3.10.1",
|
||||||
|
"@docusaurus/types": "3.10.1",
|
||||||
|
"@docusaurus/utils": "3.10.1",
|
||||||
|
"babel-loader": "^9.2.1",
|
||||||
|
"clean-css": "^5.3.3",
|
||||||
|
"copy-webpack-plugin": "^11.0.0",
|
||||||
|
"css-loader": "^6.11.0",
|
||||||
|
"css-minimizer-webpack-plugin": "^5.0.1",
|
||||||
|
"cssnano": "^6.1.2",
|
||||||
|
"file-loader": "^6.2.0",
|
||||||
|
"html-minifier-terser": "^7.2.0",
|
||||||
|
"mini-css-extract-plugin": "^2.9.2",
|
||||||
|
"null-loader": "^4.0.1",
|
||||||
|
"postcss": "^8.5.4",
|
||||||
|
"postcss-loader": "^7.3.4",
|
||||||
|
"postcss-preset-env": "^10.2.1",
|
||||||
|
"terser-webpack-plugin": "^5.3.9",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"url-loader": "^4.1.1",
|
||||||
|
"webpack": "^5.95.0",
|
||||||
|
"webpackbar": "^7.0.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"@docusaurus/faster": "*"
|
||||||
|
},
|
||||||
|
"peerDependenciesMeta": {
|
||||||
|
"@docusaurus/faster": {
|
||||||
|
"optional": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/core": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/core/-/core-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-3pf2fXXw0eVk8WnC3T4LIigRDupcpvngpKo9Vy7mYyBhuddc0klDUuZAIfzMoK6z05pdlk6EFC/vBSX43+1O5w==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/babel": "3.10.1",
|
||||||
|
"@docusaurus/bundler": "3.10.1",
|
||||||
|
"@docusaurus/logger": "3.10.1",
|
||||||
|
"@docusaurus/mdx-loader": "3.10.1",
|
||||||
|
"@docusaurus/utils": "3.10.1",
|
||||||
|
"@docusaurus/utils-common": "3.10.1",
|
||||||
|
"@docusaurus/utils-validation": "3.10.1",
|
||||||
|
"boxen": "^6.2.1",
|
||||||
|
"chalk": "^4.1.2",
|
||||||
|
"chokidar": "^3.5.3",
|
||||||
|
"cli-table3": "^0.6.3",
|
||||||
|
"combine-promises": "^1.1.0",
|
||||||
|
"commander": "^5.1.0",
|
||||||
|
"core-js": "^3.31.1",
|
||||||
|
"detect-port": "^1.5.1",
|
||||||
|
"escape-html": "^1.0.3",
|
||||||
|
"eta": "^2.2.0",
|
||||||
|
"eval": "^0.1.8",
|
||||||
|
"execa": "^5.1.1",
|
||||||
|
"fs-extra": "^11.1.1",
|
||||||
|
"html-tags": "^3.3.1",
|
||||||
|
"html-webpack-plugin": "^5.6.0",
|
||||||
|
"leven": "^3.1.0",
|
||||||
|
"lodash": "^4.17.21",
|
||||||
|
"open": "^8.4.0",
|
||||||
|
"p-map": "^4.0.0",
|
||||||
|
"prompts": "^2.4.2",
|
||||||
|
"react-helmet-async": "npm:@slorber/react-helmet-async@1.3.0",
|
||||||
|
"react-loadable": "npm:@docusaurus/react-loadable@6.0.0",
|
||||||
|
"react-loadable-ssr-addon-v5-slorber": "^1.0.3",
|
||||||
|
"react-router": "^5.3.4",
|
||||||
|
"react-router-config": "^5.1.1",
|
||||||
|
"react-router-dom": "^5.3.4",
|
||||||
|
"semver": "^7.5.4",
|
||||||
|
"serve-handler": "^6.1.7",
|
||||||
|
"tinypool": "^1.0.2",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"update-notifier": "^6.0.2",
|
||||||
|
"webpack": "^5.95.0",
|
||||||
|
"webpack-bundle-analyzer": "^4.10.2",
|
||||||
|
"webpack-dev-server": "^5.2.2",
|
||||||
|
"webpack-merge": "^6.0.1"
|
||||||
|
},
|
||||||
|
"bin": {
|
||||||
|
"docusaurus": "bin/docusaurus.mjs"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"@docusaurus/faster": "*",
|
||||||
|
"@mdx-js/react": "^3.0.0",
|
||||||
|
"react": "^18.0.0 || ^19.0.0",
|
||||||
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
|
},
|
||||||
|
"peerDependenciesMeta": {
|
||||||
|
"@docusaurus/faster": {
|
||||||
|
"optional": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/cssnano-preset": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/cssnano-preset/-/cssnano-preset-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-eNfHGcTKCSq6xmcavAkX3RRclHaE2xRCMParlDXLdXVP01/a2e/jKXMj/0ULnLFQSNwwuI62L0Ge8J+nZsR7UQ==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"cssnano-preset-advanced": "^6.1.2",
|
||||||
|
"postcss": "^8.5.4",
|
||||||
|
"postcss-sort-media-queries": "^5.2.0",
|
||||||
|
"tslib": "^2.6.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/logger": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/logger/-/logger-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-oPjNFnfJsRCkePVjkGrxWGq4MvJKRQT0r9jOP0eRBTZ7Wr9FAbzdP/Gjs0I2Ss6YRkPoEgygKG112OkE6skvJw==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"chalk": "^4.1.2",
|
||||||
|
"tslib": "^2.6.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/mdx-loader": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/mdx-loader/-/mdx-loader-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-GRmeb/wQ+iXRrFwcHBfgQhrJxGElgCsoTWZYDhccjsZVne1p8MK/EpQVIloXttz76TCe78kKD5AEG9n1xc1oxQ==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/logger": "3.10.1",
|
||||||
|
"@docusaurus/utils": "3.10.1",
|
||||||
|
"@docusaurus/utils-validation": "3.10.1",
|
||||||
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
|
"@slorber/remark-comment": "^1.0.0",
|
||||||
|
"escape-html": "^1.0.3",
|
||||||
|
"estree-util-value-to-estree": "^3.0.1",
|
||||||
|
"file-loader": "^6.2.0",
|
||||||
|
"fs-extra": "^11.1.1",
|
||||||
|
"image-size": "^2.0.2",
|
||||||
|
"mdast-util-mdx": "^3.0.0",
|
||||||
|
"mdast-util-to-string": "^4.0.0",
|
||||||
|
"rehype-raw": "^7.0.0",
|
||||||
|
"remark-directive": "^3.0.0",
|
||||||
|
"remark-emoji": "^4.0.0",
|
||||||
|
"remark-frontmatter": "^5.0.0",
|
||||||
|
"remark-gfm": "^4.0.0",
|
||||||
|
"stringify-object": "^3.3.0",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"unified": "^11.0.3",
|
||||||
|
"unist-util-visit": "^5.0.0",
|
||||||
|
"url-loader": "^4.1.1",
|
||||||
|
"vfile": "^6.0.1",
|
||||||
|
"webpack": "^5.88.1"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": "^18.0.0 || ^19.0.0",
|
||||||
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/module-type-aliases": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/module-type-aliases/-/module-type-aliases-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-YoOZKUdGlp8xSYhuAkGdSo5Ydkbq4V4eK3sD8v0a2hloxCWdQbNBhkc+Ko9QyjpESc0BYcIGM5iHVAy5hdFV6w==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/types": "3.10.1",
|
||||||
|
"@types/history": "^4.7.11",
|
||||||
|
"@types/react": "*",
|
||||||
|
"@types/react-router-config": "*",
|
||||||
|
"@types/react-router-dom": "*",
|
||||||
|
"react-helmet-async": "npm:@slorber/react-helmet-async@1.3.0",
|
||||||
|
"react-loadable": "npm:@docusaurus/react-loadable@6.0.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": "*",
|
||||||
|
"react-dom": "*"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/theme-common": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/theme-common/-/theme-common-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-0YtmIeoNo1fIw65LO8+/1dPgmDV86UmhMkow37gzjytuiCSQm9xob6PJy0L4kuQEMTLfUOGvkXvZr7GPrHquMA==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/mdx-loader": "3.10.1",
|
||||||
|
"@docusaurus/module-type-aliases": "3.10.1",
|
||||||
|
"@docusaurus/utils": "3.10.1",
|
||||||
|
"@docusaurus/utils-common": "3.10.1",
|
||||||
|
"@types/history": "^4.7.11",
|
||||||
|
"@types/react": "*",
|
||||||
|
"@types/react-router-config": "*",
|
||||||
|
"clsx": "^2.0.0",
|
||||||
|
"parse-numeric-range": "^1.3.0",
|
||||||
|
"prism-react-renderer": "^2.3.0",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"utility-types": "^3.10.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"@docusaurus/plugin-content-docs": "*",
|
||||||
|
"react": "^18.0.0 || ^19.0.0",
|
||||||
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/types": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/types/-/types-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-XYMK8k1szDCFMw2V+Xyen0g7Kee1sP3dtFnl7vkGkZOkeAJ/oPDQPL8iz4HBKOo/cwU8QeV6onVjMqtP+tFzsw==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
|
"@types/history": "^4.7.11",
|
||||||
|
"@types/mdast": "^4.0.2",
|
||||||
|
"@types/react": "*",
|
||||||
|
"commander": "^5.1.0",
|
||||||
|
"joi": "^17.9.2",
|
||||||
|
"react-helmet-async": "npm:@slorber/react-helmet-async@1.3.0",
|
||||||
|
"utility-types": "^3.10.0",
|
||||||
|
"webpack": "^5.95.0",
|
||||||
|
"webpack-merge": "^5.9.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": "^18.0.0 || ^19.0.0",
|
||||||
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/types/node_modules/webpack-merge": {
|
||||||
|
"version": "5.10.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/webpack-merge/-/webpack-merge-5.10.0.tgz",
|
||||||
|
"integrity": "sha512-+4zXKdx7UnO+1jaN4l2lHVD+mFvnlZQP/6ljaJVb4SZiwIKeUnrT5l0gkT8z+n4hKpC+jpOv6O9R+gLtag7pSA==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"clone-deep": "^4.0.1",
|
||||||
|
"flat": "^5.0.2",
|
||||||
|
"wildcard": "^2.0.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=10.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/utils": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/utils/-/utils-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-3ojeJry9xBYdJO6qoyyzqeJFSJBVx2mXhyDzSdjwL2+URFQMf+h25gG38iswGImicK0ELjTd1EL2xzk8hf3QPw==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/logger": "3.10.1",
|
||||||
|
"@docusaurus/types": "3.10.1",
|
||||||
|
"@docusaurus/utils-common": "3.10.1",
|
||||||
|
"escape-string-regexp": "^4.0.0",
|
||||||
|
"execa": "^5.1.1",
|
||||||
|
"file-loader": "^6.2.0",
|
||||||
|
"fs-extra": "^11.1.1",
|
||||||
|
"github-slugger": "^1.5.0",
|
||||||
|
"globby": "^11.1.0",
|
||||||
|
"gray-matter": "^4.0.3",
|
||||||
|
"jiti": "^1.20.0",
|
||||||
|
"js-yaml": "^4.1.0",
|
||||||
|
"lodash": "^4.17.21",
|
||||||
|
"micromatch": "^4.0.5",
|
||||||
|
"p-queue": "^6.6.2",
|
||||||
|
"prompts": "^2.4.2",
|
||||||
|
"resolve-pathname": "^3.0.0",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"url-loader": "^4.1.1",
|
||||||
|
"utility-types": "^3.10.0",
|
||||||
|
"webpack": "^5.88.1"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/utils-common": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/utils-common/-/utils-common-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-5mFSgEADtnFxFH7RLw02QA5MpU5JVUCj0MPeIvi/aF4Fi45tQRIuTwXoXDqJ+1VfQJuYJGz3SI63wmGz4HvXzA==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/types": "3.10.1",
|
||||||
|
"tslib": "^2.6.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/utils-validation": {
|
||||||
|
"version": "3.10.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/utils-validation/-/utils-validation-3.10.1.tgz",
|
||||||
|
"integrity": "sha512-cRv1X69jwaWv47waglllgZVWzeBFLhl53XT/XED/83BerVBTC5FTP8WTcVl8Z6sZOegDSwitu/wpCSPCDOT6lg==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/logger": "3.10.1",
|
||||||
|
"@docusaurus/utils": "3.10.1",
|
||||||
|
"@docusaurus/utils-common": "3.10.1",
|
||||||
|
"fs-extra": "^11.2.0",
|
||||||
|
"joi": "^17.9.2",
|
||||||
|
"js-yaml": "^4.1.0",
|
||||||
|
"lodash": "^4.17.21",
|
||||||
|
"tslib": "^2.6.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@docusaurus/plugin-content-docs/node_modules/webpackbar": {
|
||||||
|
"version": "7.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/webpackbar/-/webpackbar-7.0.0.tgz",
|
||||||
|
"integrity": "sha512-aS9soqSO2iCHgqHoCrj4LbfGQUboDCYJPSFOAchEK+9psIjNrfSWW4Y0YEz67MKURNvMmfo0ycOg9d/+OOf9/Q==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"ansis": "^3.2.0",
|
||||||
|
"consola": "^3.2.3",
|
||||||
|
"pretty-time": "^1.1.0",
|
||||||
|
"std-env": "^3.7.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=14.21.3"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"@rspack/core": "*",
|
||||||
|
"webpack": "3 || 4 || 5"
|
||||||
|
},
|
||||||
|
"peerDependenciesMeta": {
|
||||||
|
"@rspack/core": {
|
||||||
|
"optional": true
|
||||||
|
},
|
||||||
|
"webpack": {
|
||||||
|
"optional": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@docusaurus/plugin-content-pages": {
|
"node_modules/@docusaurus/plugin-content-pages": {
|
||||||
"version": "3.9.2",
|
"version": "3.9.2",
|
||||||
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-pages/-/plugin-content-pages-3.9.2.tgz",
|
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-pages/-/plugin-content-pages-3.9.2.tgz",
|
||||||
@@ -3937,6 +4313,39 @@
|
|||||||
"react-dom": "^18.0.0 || ^19.0.0"
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@docusaurus/preset-classic/node_modules/@docusaurus/plugin-content-docs": {
|
||||||
|
"version": "3.9.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-docs/-/plugin-content-docs-3.9.2.tgz",
|
||||||
|
"integrity": "sha512-C5wZsGuKTY8jEYsqdxhhFOe1ZDjH0uIYJ9T/jebHwkyxqnr4wW0jTkB72OMqNjsoQRcb0JN3PcSeTwFlVgzCZg==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/core": "3.9.2",
|
||||||
|
"@docusaurus/logger": "3.9.2",
|
||||||
|
"@docusaurus/mdx-loader": "3.9.2",
|
||||||
|
"@docusaurus/module-type-aliases": "3.9.2",
|
||||||
|
"@docusaurus/theme-common": "3.9.2",
|
||||||
|
"@docusaurus/types": "3.9.2",
|
||||||
|
"@docusaurus/utils": "3.9.2",
|
||||||
|
"@docusaurus/utils-common": "3.9.2",
|
||||||
|
"@docusaurus/utils-validation": "3.9.2",
|
||||||
|
"@types/react-router-config": "^5.0.7",
|
||||||
|
"combine-promises": "^1.1.0",
|
||||||
|
"fs-extra": "^11.1.1",
|
||||||
|
"js-yaml": "^4.1.0",
|
||||||
|
"lodash": "^4.17.21",
|
||||||
|
"schema-dts": "^1.1.2",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"utility-types": "^3.10.0",
|
||||||
|
"webpack": "^5.88.1"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": "^18.0.0 || ^19.0.0",
|
||||||
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@docusaurus/theme-classic": {
|
"node_modules/@docusaurus/theme-classic": {
|
||||||
"version": "3.9.2",
|
"version": "3.9.2",
|
||||||
"resolved": "https://registry.npmjs.org/@docusaurus/theme-classic/-/theme-classic-3.9.2.tgz",
|
"resolved": "https://registry.npmjs.org/@docusaurus/theme-classic/-/theme-classic-3.9.2.tgz",
|
||||||
@@ -3977,6 +4386,39 @@
|
|||||||
"react-dom": "^18.0.0 || ^19.0.0"
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@docusaurus/theme-classic/node_modules/@docusaurus/plugin-content-docs": {
|
||||||
|
"version": "3.9.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-docs/-/plugin-content-docs-3.9.2.tgz",
|
||||||
|
"integrity": "sha512-C5wZsGuKTY8jEYsqdxhhFOe1ZDjH0uIYJ9T/jebHwkyxqnr4wW0jTkB72OMqNjsoQRcb0JN3PcSeTwFlVgzCZg==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/core": "3.9.2",
|
||||||
|
"@docusaurus/logger": "3.9.2",
|
||||||
|
"@docusaurus/mdx-loader": "3.9.2",
|
||||||
|
"@docusaurus/module-type-aliases": "3.9.2",
|
||||||
|
"@docusaurus/theme-common": "3.9.2",
|
||||||
|
"@docusaurus/types": "3.9.2",
|
||||||
|
"@docusaurus/utils": "3.9.2",
|
||||||
|
"@docusaurus/utils-common": "3.9.2",
|
||||||
|
"@docusaurus/utils-validation": "3.9.2",
|
||||||
|
"@types/react-router-config": "^5.0.7",
|
||||||
|
"combine-promises": "^1.1.0",
|
||||||
|
"fs-extra": "^11.1.1",
|
||||||
|
"js-yaml": "^4.1.0",
|
||||||
|
"lodash": "^4.17.21",
|
||||||
|
"schema-dts": "^1.1.2",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"utility-types": "^3.10.0",
|
||||||
|
"webpack": "^5.88.1"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": "^18.0.0 || ^19.0.0",
|
||||||
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@docusaurus/theme-common": {
|
"node_modules/@docusaurus/theme-common": {
|
||||||
"version": "3.9.2",
|
"version": "3.9.2",
|
||||||
"resolved": "https://registry.npmjs.org/@docusaurus/theme-common/-/theme-common-3.9.2.tgz",
|
"resolved": "https://registry.npmjs.org/@docusaurus/theme-common/-/theme-common-3.9.2.tgz",
|
||||||
@@ -4064,6 +4506,39 @@
|
|||||||
"react-dom": "^18.0.0 || ^19.0.0"
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@docusaurus/theme-search-algolia/node_modules/@docusaurus/plugin-content-docs": {
|
||||||
|
"version": "3.9.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-docs/-/plugin-content-docs-3.9.2.tgz",
|
||||||
|
"integrity": "sha512-C5wZsGuKTY8jEYsqdxhhFOe1ZDjH0uIYJ9T/jebHwkyxqnr4wW0jTkB72OMqNjsoQRcb0JN3PcSeTwFlVgzCZg==",
|
||||||
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
|
"@docusaurus/core": "3.9.2",
|
||||||
|
"@docusaurus/logger": "3.9.2",
|
||||||
|
"@docusaurus/mdx-loader": "3.9.2",
|
||||||
|
"@docusaurus/module-type-aliases": "3.9.2",
|
||||||
|
"@docusaurus/theme-common": "3.9.2",
|
||||||
|
"@docusaurus/types": "3.9.2",
|
||||||
|
"@docusaurus/utils": "3.9.2",
|
||||||
|
"@docusaurus/utils-common": "3.9.2",
|
||||||
|
"@docusaurus/utils-validation": "3.9.2",
|
||||||
|
"@types/react-router-config": "^5.0.7",
|
||||||
|
"combine-promises": "^1.1.0",
|
||||||
|
"fs-extra": "^11.1.1",
|
||||||
|
"js-yaml": "^4.1.0",
|
||||||
|
"lodash": "^4.17.21",
|
||||||
|
"schema-dts": "^1.1.2",
|
||||||
|
"tslib": "^2.6.0",
|
||||||
|
"utility-types": "^3.10.0",
|
||||||
|
"webpack": "^5.88.1"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": "^18.0.0 || ^19.0.0",
|
||||||
|
"react-dom": "^18.0.0 || ^19.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@docusaurus/theme-translations": {
|
"node_modules/@docusaurus/theme-translations": {
|
||||||
"version": "3.9.2",
|
"version": "3.9.2",
|
||||||
"resolved": "https://registry.npmjs.org/@docusaurus/theme-translations/-/theme-translations-3.9.2.tgz",
|
"resolved": "https://registry.npmjs.org/@docusaurus/theme-translations/-/theme-translations-3.9.2.tgz",
|
||||||
@@ -6475,6 +6950,15 @@
|
|||||||
"url": "https://github.com/chalk/ansi-styles?sponsor=1"
|
"url": "https://github.com/chalk/ansi-styles?sponsor=1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/ansis": {
|
||||||
|
"version": "3.17.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/ansis/-/ansis-3.17.0.tgz",
|
||||||
|
"integrity": "sha512-0qWUglt9JEqLFr3w1I1pbrChn1grhaiAR2ocX1PP/flRmxgtwTzPFFFnfIlD6aMOLQZgSuCRlidD70lvx8yhzg==",
|
||||||
|
"license": "ISC",
|
||||||
|
"engines": {
|
||||||
|
"node": ">=14"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/any-promise": {
|
"node_modules/any-promise": {
|
||||||
"version": "1.3.0",
|
"version": "1.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz",
|
"resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz",
|
||||||
@@ -18818,9 +19302,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/react-loadable-ssr-addon-v5-slorber": {
|
"node_modules/react-loadable-ssr-addon-v5-slorber": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/react-loadable-ssr-addon-v5-slorber/-/react-loadable-ssr-addon-v5-slorber-1.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/react-loadable-ssr-addon-v5-slorber/-/react-loadable-ssr-addon-v5-slorber-1.0.3.tgz",
|
||||||
"integrity": "sha512-lq3Lyw1lGku8zUEJPDxsNm1AfYHBrO9Y1+olAYwpUJ2IGFBskM0DMKok97A6LWUpHm+o7IvQBOWu9MLenp9Z+A==",
|
"integrity": "sha512-GXfh9VLwB5ERaCsU6RULh7tkemeX15aNh6wuMEBtfdyMa7fFG8TXrhXlx1SoEK2Ty/l6XIkzzYIQmyaWW3JgdQ==",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.10.3"
|
"@babel/runtime": "^7.10.3"
|
||||||
@@ -20601,24 +21085,24 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/serve-handler": {
|
"node_modules/serve-handler": {
|
||||||
"version": "6.1.6",
|
"version": "6.1.7",
|
||||||
"resolved": "https://registry.npmjs.org/serve-handler/-/serve-handler-6.1.6.tgz",
|
"resolved": "https://registry.npmjs.org/serve-handler/-/serve-handler-6.1.7.tgz",
|
||||||
"integrity": "sha512-x5RL9Y2p5+Sh3D38Fh9i/iQ5ZK+e4xuXRd/pGbM4D13tgo/MGwbttUk8emytcr1YYzBYs+apnUngBDFYfpjPuQ==",
|
"integrity": "sha512-CinAq1xWb0vR3twAv9evEU8cNWkXCb9kd5ePAHUKJBkOsUpR1wt/CvGdeca7vqumL1U5cSaeVQ6zZMxiJ3yWsg==",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"bytes": "3.0.0",
|
"bytes": "3.0.0",
|
||||||
"content-disposition": "0.5.2",
|
"content-disposition": "0.5.2",
|
||||||
"mime-types": "2.1.18",
|
"mime-types": "2.1.18",
|
||||||
"minimatch": "3.1.2",
|
"minimatch": "3.1.5",
|
||||||
"path-is-inside": "1.0.2",
|
"path-is-inside": "1.0.2",
|
||||||
"path-to-regexp": "3.3.0",
|
"path-to-regexp": "3.3.0",
|
||||||
"range-parser": "1.2.0"
|
"range-parser": "1.2.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/serve-handler/node_modules/brace-expansion": {
|
"node_modules/serve-handler/node_modules/brace-expansion": {
|
||||||
"version": "1.1.12",
|
"version": "1.1.14",
|
||||||
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz",
|
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.14.tgz",
|
||||||
"integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==",
|
"integrity": "sha512-MWPGfDxnyzKU7rNOW9SP/c50vi3xrmrua/+6hfPbCS2ABNWfx24vPidzvC7krjU/RTo235sV776ymlsMtGKj8g==",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"balanced-match": "^1.0.0",
|
"balanced-match": "^1.0.0",
|
||||||
@@ -20647,9 +21131,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/serve-handler/node_modules/minimatch": {
|
"node_modules/serve-handler/node_modules/minimatch": {
|
||||||
"version": "3.1.2",
|
"version": "3.1.5",
|
||||||
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz",
|
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz",
|
||||||
"integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==",
|
"integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"brace-expansion": "^1.1.7"
|
"brace-expansion": "^1.1.7"
|
||||||
|
|||||||
+1
-1
@@ -19,7 +19,7 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@docusaurus/core": "^3.7.0",
|
"@docusaurus/core": "^3.7.0",
|
||||||
"@docusaurus/plugin-content-docs": "^3.7.0",
|
"@docusaurus/plugin-content-docs": "^3.10.1",
|
||||||
"@docusaurus/preset-classic": "^3.7.0",
|
"@docusaurus/preset-classic": "^3.7.0",
|
||||||
"@docusaurus/theme-mermaid": "^3.7.0",
|
"@docusaurus/theme-mermaid": "^3.7.0",
|
||||||
"@inkeep/docusaurus": "^2.0.16",
|
"@inkeep/docusaurus": "^2.0.16",
|
||||||
|
|||||||
@@ -200,9 +200,6 @@ class EmbeddingMaintainer(threading.Thread):
|
|||||||
)
|
)
|
||||||
|
|
||||||
for model_config in self.config.classification.custom.values():
|
for model_config in self.config.classification.custom.values():
|
||||||
if not model_config.enabled:
|
|
||||||
continue
|
|
||||||
|
|
||||||
self.realtime_processors.append(
|
self.realtime_processors.append(
|
||||||
CustomStateClassificationProcessor(
|
CustomStateClassificationProcessor(
|
||||||
self.config, model_config, self.requestor, self.metrics
|
self.config, model_config, self.requestor, self.metrics
|
||||||
@@ -335,25 +332,6 @@ class EmbeddingMaintainer(threading.Thread):
|
|||||||
for processor in self.post_processors:
|
for processor in self.post_processors:
|
||||||
processor.update_config(topic, payload)
|
processor.update_config(topic, payload)
|
||||||
|
|
||||||
def _remove_custom_classification_processor(self, model_name: str) -> None:
|
|
||||||
"""Shut down and drop any running processor for a custom model."""
|
|
||||||
remaining = []
|
|
||||||
for processor in self.realtime_processors:
|
|
||||||
if (
|
|
||||||
isinstance(
|
|
||||||
processor,
|
|
||||||
(
|
|
||||||
CustomStateClassificationProcessor,
|
|
||||||
CustomObjectClassificationProcessor,
|
|
||||||
),
|
|
||||||
)
|
|
||||||
and processor.model_config.name == model_name
|
|
||||||
):
|
|
||||||
processor.shutdown()
|
|
||||||
else:
|
|
||||||
remaining.append(processor)
|
|
||||||
self.realtime_processors = remaining
|
|
||||||
|
|
||||||
def _handle_custom_classification_update(
|
def _handle_custom_classification_update(
|
||||||
self, topic: str, model_config: Any
|
self, topic: str, model_config: Any
|
||||||
) -> None:
|
) -> None:
|
||||||
@@ -361,7 +339,23 @@ class EmbeddingMaintainer(threading.Thread):
|
|||||||
model_name = topic.split("/")[-1]
|
model_name = topic.split("/")[-1]
|
||||||
|
|
||||||
if model_config is None:
|
if model_config is None:
|
||||||
self._remove_custom_classification_processor(model_name)
|
remaining = []
|
||||||
|
for processor in self.realtime_processors:
|
||||||
|
if (
|
||||||
|
isinstance(
|
||||||
|
processor,
|
||||||
|
(
|
||||||
|
CustomStateClassificationProcessor,
|
||||||
|
CustomObjectClassificationProcessor,
|
||||||
|
),
|
||||||
|
)
|
||||||
|
and processor.model_config.name == model_name
|
||||||
|
):
|
||||||
|
processor.shutdown()
|
||||||
|
else:
|
||||||
|
remaining.append(processor)
|
||||||
|
self.realtime_processors = remaining
|
||||||
|
|
||||||
logger.info(
|
logger.info(
|
||||||
f"Successfully removed classification processor for model: {model_name}"
|
f"Successfully removed classification processor for model: {model_name}"
|
||||||
)
|
)
|
||||||
@@ -369,13 +363,6 @@ class EmbeddingMaintainer(threading.Thread):
|
|||||||
|
|
||||||
self.config.classification.custom[model_name] = model_config
|
self.config.classification.custom[model_name] = model_config
|
||||||
|
|
||||||
# A disabled model must not run; tear down any existing processor and
|
|
||||||
# do not register a new one.
|
|
||||||
if not model_config.enabled:
|
|
||||||
self._remove_custom_classification_processor(model_name)
|
|
||||||
logger.info(f"Disabled classification processor for model: {model_name}")
|
|
||||||
return
|
|
||||||
|
|
||||||
# Check if processor already exists
|
# Check if processor already exists
|
||||||
for processor in self.realtime_processors:
|
for processor in self.realtime_processors:
|
||||||
if isinstance(
|
if isinstance(
|
||||||
@@ -715,11 +702,7 @@ class EmbeddingMaintainer(threading.Thread):
|
|||||||
and "license_plate" not in camera_config.objects.track
|
and "license_plate" not in camera_config.objects.track
|
||||||
)
|
)
|
||||||
|
|
||||||
has_enabled_custom = any(
|
if not dedicated_lpr_enabled and len(self.config.classification.custom) == 0:
|
||||||
c.enabled for c in self.config.classification.custom.values()
|
|
||||||
)
|
|
||||||
|
|
||||||
if not dedicated_lpr_enabled and not has_enabled_custom:
|
|
||||||
# no active features that use this data
|
# no active features that use this data
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
@@ -1,106 +0,0 @@
|
|||||||
"""Tests that disabled custom classification models are not registered or run."""
|
|
||||||
|
|
||||||
import sys
|
|
||||||
import unittest
|
|
||||||
from unittest.mock import MagicMock
|
|
||||||
|
|
||||||
# Mock TFLite before importing the maintainer / classification modules
|
|
||||||
_MOCK_MODULES = [
|
|
||||||
"tflite_runtime",
|
|
||||||
"tflite_runtime.interpreter",
|
|
||||||
"ai_edge_litert",
|
|
||||||
"ai_edge_litert.interpreter",
|
|
||||||
]
|
|
||||||
for mod in _MOCK_MODULES:
|
|
||||||
if mod not in sys.modules:
|
|
||||||
sys.modules[mod] = MagicMock()
|
|
||||||
|
|
||||||
from frigate.data_processing.real_time.custom_classification import ( # noqa: E402
|
|
||||||
CustomObjectClassificationProcessor,
|
|
||||||
)
|
|
||||||
from frigate.embeddings.maintainer import EmbeddingMaintainer # noqa: E402
|
|
||||||
|
|
||||||
|
|
||||||
class TestCustomClassificationEnabledGating(unittest.TestCase):
|
|
||||||
"""A model with enabled: false must not keep a processor registered."""
|
|
||||||
|
|
||||||
def _make_maintainer(self) -> EmbeddingMaintainer:
|
|
||||||
# Bypass the heavy __init__; only the attributes touched by the
|
|
||||||
# config update path are needed for these tests.
|
|
||||||
maintainer = EmbeddingMaintainer.__new__(EmbeddingMaintainer)
|
|
||||||
maintainer.realtime_processors = []
|
|
||||||
maintainer.config = MagicMock()
|
|
||||||
maintainer.config.classification.custom = {}
|
|
||||||
maintainer.requestor = MagicMock()
|
|
||||||
maintainer.metrics = MagicMock()
|
|
||||||
maintainer.event_metadata_publisher = MagicMock()
|
|
||||||
return maintainer
|
|
||||||
|
|
||||||
def _make_model_config(self, name: str, enabled: bool) -> MagicMock:
|
|
||||||
model_config = MagicMock()
|
|
||||||
model_config.name = name
|
|
||||||
model_config.enabled = enabled
|
|
||||||
model_config.state_config = None
|
|
||||||
return model_config
|
|
||||||
|
|
||||||
def _make_processor(self, name: str) -> MagicMock:
|
|
||||||
processor = MagicMock(spec=CustomObjectClassificationProcessor)
|
|
||||||
processor.model_config = MagicMock()
|
|
||||||
processor.model_config.name = name
|
|
||||||
return processor
|
|
||||||
|
|
||||||
def test_disabled_update_tears_down_existing_processor(self):
|
|
||||||
"""Toggling a running model to disabled shuts down and drops its processor."""
|
|
||||||
maintainer = self._make_maintainer()
|
|
||||||
processor = self._make_processor("atli")
|
|
||||||
maintainer.realtime_processors = [processor]
|
|
||||||
|
|
||||||
maintainer._handle_custom_classification_update(
|
|
||||||
"config/classification/custom/atli",
|
|
||||||
self._make_model_config("atli", enabled=False),
|
|
||||||
)
|
|
||||||
|
|
||||||
processor.shutdown.assert_called_once()
|
|
||||||
self.assertEqual(maintainer.realtime_processors, [])
|
|
||||||
|
|
||||||
def test_disabled_update_does_not_register_processor(self):
|
|
||||||
"""A disabled model that has no processor is never registered."""
|
|
||||||
maintainer = self._make_maintainer()
|
|
||||||
|
|
||||||
maintainer._handle_custom_classification_update(
|
|
||||||
"config/classification/custom/atli",
|
|
||||||
self._make_model_config("atli", enabled=False),
|
|
||||||
)
|
|
||||||
|
|
||||||
self.assertEqual(maintainer.realtime_processors, [])
|
|
||||||
|
|
||||||
def test_disabled_update_leaves_other_processors_untouched(self):
|
|
||||||
"""Disabling one model must not affect other running processors."""
|
|
||||||
maintainer = self._make_maintainer()
|
|
||||||
other = self._make_processor("simbi")
|
|
||||||
maintainer.realtime_processors = [other]
|
|
||||||
|
|
||||||
maintainer._handle_custom_classification_update(
|
|
||||||
"config/classification/custom/atli",
|
|
||||||
self._make_model_config("atli", enabled=False),
|
|
||||||
)
|
|
||||||
|
|
||||||
other.shutdown.assert_not_called()
|
|
||||||
self.assertEqual(maintainer.realtime_processors, [other])
|
|
||||||
|
|
||||||
def test_removed_model_tears_down_processor(self):
|
|
||||||
"""A None payload (model deleted) still shuts down its processor."""
|
|
||||||
maintainer = self._make_maintainer()
|
|
||||||
processor = self._make_processor("atli")
|
|
||||||
maintainer.realtime_processors = [processor]
|
|
||||||
|
|
||||||
maintainer._handle_custom_classification_update(
|
|
||||||
"config/classification/custom/atli", None
|
|
||||||
)
|
|
||||||
|
|
||||||
processor.shutdown.assert_called_once()
|
|
||||||
self.assertEqual(maintainer.realtime_processors, [])
|
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
|
||||||
unittest.main()
|
|
||||||
@@ -1490,14 +1490,7 @@
|
|||||||
"keyLabel": "Key",
|
"keyLabel": "Key",
|
||||||
"valueLabel": "Value",
|
"valueLabel": "Value",
|
||||||
"keyPlaceholder": "New key",
|
"keyPlaceholder": "New key",
|
||||||
"remove": "Remove",
|
"remove": "Remove"
|
||||||
"providerNameLabel": "Provider name",
|
|
||||||
"providerNamePlaceholder": "e.g., openai",
|
|
||||||
"variableNameLabel": "Variable name",
|
|
||||||
"variableNamePlaceholder": "e.g., MY_VARIABLE",
|
|
||||||
"loggerNameLabel": "Logger name",
|
|
||||||
"loggerNamePlaceholder": "e.g., frigate.record",
|
|
||||||
"keyPatternError": "Use only letters, numbers, hyphens, and underscores (no spaces)"
|
|
||||||
},
|
},
|
||||||
"knownPlates": {
|
"knownPlates": {
|
||||||
"namePlaceholder": "e.g., Wife's Car",
|
"namePlaceholder": "e.g., Wife's Car",
|
||||||
|
|||||||
@@ -7,13 +7,7 @@ const environmentVars: SectionConfigOverrides = {
|
|||||||
advancedFields: [],
|
advancedFields: [],
|
||||||
uiSchema: {
|
uiSchema: {
|
||||||
additionalProperties: {
|
additionalProperties: {
|
||||||
"ui:options": {
|
"ui:options": { size: "lg" },
|
||||||
size: "lg",
|
|
||||||
additionalPropertyKeyLabel:
|
|
||||||
"configForm.additionalProperties.variableNameLabel",
|
|
||||||
additionalPropertyKeyPlaceholder:
|
|
||||||
"configForm.additionalProperties.variableNamePlaceholder",
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -9,15 +9,7 @@ const genai: SectionConfigOverrides = {
|
|||||||
uiSchema: {
|
uiSchema: {
|
||||||
"ui:options": { disableNestedCard: true },
|
"ui:options": { disableNestedCard: true },
|
||||||
"*": {
|
"*": {
|
||||||
"ui:options": {
|
"ui:options": { disableNestedCard: true },
|
||||||
disableNestedCard: true,
|
|
||||||
additionalPropertyKeyLabel:
|
|
||||||
"configForm.additionalProperties.providerNameLabel",
|
|
||||||
additionalPropertyKeyPlaceholder:
|
|
||||||
"configForm.additionalProperties.providerNamePlaceholder",
|
|
||||||
additionalPropertyKeyPattern: "^[a-zA-Z0-9_-]+$",
|
|
||||||
preventKeyRename: true,
|
|
||||||
},
|
|
||||||
"ui:order": [
|
"ui:order": [
|
||||||
"provider",
|
"provider",
|
||||||
"api_key",
|
"api_key",
|
||||||
|
|||||||
@@ -12,13 +12,7 @@ const logger: SectionConfigOverrides = {
|
|||||||
},
|
},
|
||||||
logs: {
|
logs: {
|
||||||
additionalProperties: {
|
additionalProperties: {
|
||||||
"ui:options": {
|
"ui:options": { enumI18nPrefix: "logger.logLevel" },
|
||||||
enumI18nPrefix: "logger.logLevel",
|
|
||||||
additionalPropertyKeyLabel:
|
|
||||||
"configForm.additionalProperties.loggerNameLabel",
|
|
||||||
additionalPropertyKeyPlaceholder:
|
|
||||||
"configForm.additionalProperties.loggerNamePlaceholder",
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -6,14 +6,12 @@ import {
|
|||||||
StrictRJSFSchema,
|
StrictRJSFSchema,
|
||||||
WrapIfAdditionalTemplateProps,
|
WrapIfAdditionalTemplateProps,
|
||||||
} from "@rjsf/utils";
|
} from "@rjsf/utils";
|
||||||
import { useEffect, useMemo, useState, type FocusEvent } from "react";
|
|
||||||
import { Input } from "@/components/ui/input";
|
import { Input } from "@/components/ui/input";
|
||||||
import { Button } from "@/components/ui/button";
|
import { Button } from "@/components/ui/button";
|
||||||
import { Label } from "@/components/ui/label";
|
import { Label } from "@/components/ui/label";
|
||||||
import { cn } from "@/lib/utils";
|
import { cn } from "@/lib/utils";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { LuTrash2 } from "react-icons/lu";
|
import { LuTrash2 } from "react-icons/lu";
|
||||||
import type { ConfigFormContext } from "@/types/configForm";
|
|
||||||
|
|
||||||
export function WrapIfAdditionalTemplate<
|
export function WrapIfAdditionalTemplate<
|
||||||
T = unknown,
|
T = unknown,
|
||||||
@@ -32,7 +30,6 @@ export function WrapIfAdditionalTemplate<
|
|||||||
onKeyRenameBlur,
|
onKeyRenameBlur,
|
||||||
readonly,
|
readonly,
|
||||||
required,
|
required,
|
||||||
registry,
|
|
||||||
schema,
|
schema,
|
||||||
uiSchema,
|
uiSchema,
|
||||||
} = props;
|
} = props;
|
||||||
@@ -41,55 +38,6 @@ export function WrapIfAdditionalTemplate<
|
|||||||
|
|
||||||
const additional = ADDITIONAL_PROPERTY_FLAG in schema;
|
const additional = ADDITIONAL_PROPERTY_FLAG in schema;
|
||||||
|
|
||||||
const uiOptions = getUiOptions(uiSchema);
|
|
||||||
const keyIsReadonly = uiOptions.additionalPropertyKeyReadonly === true;
|
|
||||||
|
|
||||||
const keyLabelKey =
|
|
||||||
typeof uiOptions.additionalPropertyKeyLabel === "string"
|
|
||||||
? uiOptions.additionalPropertyKeyLabel
|
|
||||||
: undefined;
|
|
||||||
const keyPlaceholderKey =
|
|
||||||
typeof uiOptions.additionalPropertyKeyPlaceholder === "string"
|
|
||||||
? uiOptions.additionalPropertyKeyPlaceholder
|
|
||||||
: undefined;
|
|
||||||
const keyPattern =
|
|
||||||
typeof uiOptions.additionalPropertyKeyPattern === "string"
|
|
||||||
? uiOptions.additionalPropertyKeyPattern
|
|
||||||
: undefined;
|
|
||||||
const preventKeyRename = uiOptions.preventKeyRename === true;
|
|
||||||
|
|
||||||
const formContext = registry?.formContext as ConfigFormContext | undefined;
|
|
||||||
|
|
||||||
// optionally, lock the key once it's been saved
|
|
||||||
const baseline = formContext?.baselineFormData;
|
|
||||||
const keyLocked =
|
|
||||||
preventKeyRename &&
|
|
||||||
typeof label === "string" &&
|
|
||||||
!!baseline &&
|
|
||||||
Object.prototype.hasOwnProperty.call(baseline, label);
|
|
||||||
|
|
||||||
// controlled key value so we can validate live and block invalid renames.
|
|
||||||
const [keyValue, setKeyValue] = useState<string>(label ?? "");
|
|
||||||
useEffect(() => {
|
|
||||||
setKeyValue(label ?? "");
|
|
||||||
}, [label]);
|
|
||||||
|
|
||||||
const keyRegex = useMemo(
|
|
||||||
() => (keyPattern ? new RegExp(keyPattern) : undefined),
|
|
||||||
[keyPattern],
|
|
||||||
);
|
|
||||||
const keyError = useMemo(() => {
|
|
||||||
if (!keyRegex || keyLocked) return null;
|
|
||||||
if (!keyRegex.test(keyValue)) {
|
|
||||||
return t("configForm.additionalProperties.keyPatternError", {
|
|
||||||
ns: "views/settings",
|
|
||||||
defaultValue:
|
|
||||||
"Use only letters, numbers, hyphens, and underscores (no spaces)",
|
|
||||||
});
|
|
||||||
}
|
|
||||||
return null;
|
|
||||||
}, [keyRegex, keyLocked, keyValue, t]);
|
|
||||||
|
|
||||||
if (!additional) {
|
if (!additional) {
|
||||||
return (
|
return (
|
||||||
<div className={classNames} style={style}>
|
<div className={classNames} style={style}>
|
||||||
@@ -99,26 +47,20 @@ export function WrapIfAdditionalTemplate<
|
|||||||
}
|
}
|
||||||
|
|
||||||
const keyId = `${id}-key`;
|
const keyId = `${id}-key`;
|
||||||
const keyLabel = keyLabelKey
|
const keyLabel = t("configForm.additionalProperties.keyLabel", {
|
||||||
? t(keyLabelKey, { ns: "views/settings" })
|
ns: "views/settings",
|
||||||
: t("configForm.additionalProperties.keyLabel", { ns: "views/settings" });
|
});
|
||||||
const valueLabel = t("configForm.additionalProperties.valueLabel", {
|
const valueLabel = t("configForm.additionalProperties.valueLabel", {
|
||||||
ns: "views/settings",
|
ns: "views/settings",
|
||||||
});
|
});
|
||||||
const keyPlaceholder = keyPlaceholderKey
|
const keyPlaceholder = t("configForm.additionalProperties.keyPlaceholder", {
|
||||||
? t(keyPlaceholderKey, { ns: "views/settings" })
|
ns: "views/settings",
|
||||||
: t("configForm.additionalProperties.keyPlaceholder", {
|
});
|
||||||
ns: "views/settings",
|
|
||||||
});
|
|
||||||
const removeLabel = t("configForm.additionalProperties.remove", {
|
const removeLabel = t("configForm.additionalProperties.remove", {
|
||||||
ns: "views/settings",
|
ns: "views/settings",
|
||||||
});
|
});
|
||||||
|
const uiOptions = getUiOptions(uiSchema);
|
||||||
const commitKeyRename = (e: FocusEvent<HTMLInputElement>) => {
|
const keyIsReadonly = uiOptions.additionalPropertyKeyReadonly === true;
|
||||||
if (readonly) return;
|
|
||||||
if (keyError) return;
|
|
||||||
onKeyRenameBlur?.(e);
|
|
||||||
};
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
@@ -128,30 +70,23 @@ export function WrapIfAdditionalTemplate<
|
|||||||
{!keyIsReadonly && (
|
{!keyIsReadonly && (
|
||||||
<div className="col-span-12 space-y-2 md:col-span-2">
|
<div className="col-span-12 space-y-2 md:col-span-2">
|
||||||
{displayLabel && <Label htmlFor={keyId}>{keyLabel}</Label>}
|
{displayLabel && <Label htmlFor={keyId}>{keyLabel}</Label>}
|
||||||
{keyLocked ? (
|
{keyIsReadonly ? (
|
||||||
<div
|
<div
|
||||||
id={keyId}
|
id={keyId}
|
||||||
className="flex items-center break-all text-sm text-primary-variant"
|
className="flex items-center text-sm text-muted-foreground"
|
||||||
>
|
>
|
||||||
{label}
|
{label}
|
||||||
</div>
|
</div>
|
||||||
) : (
|
) : (
|
||||||
<>
|
<Input
|
||||||
<Input
|
id={keyId}
|
||||||
id={keyId}
|
name={keyId}
|
||||||
name={keyId}
|
required={required}
|
||||||
required={required}
|
defaultValue={label}
|
||||||
value={keyValue}
|
placeholder={keyPlaceholder}
|
||||||
placeholder={keyPlaceholder}
|
disabled={disabled || readonly}
|
||||||
disabled={disabled || readonly}
|
onBlur={!readonly ? onKeyRenameBlur : undefined}
|
||||||
onChange={(e) => setKeyValue(e.target.value)}
|
/>
|
||||||
onBlur={!readonly ? commitKeyRename : undefined}
|
|
||||||
aria-invalid={keyError ? true : undefined}
|
|
||||||
/>
|
|
||||||
{keyError && (
|
|
||||||
<p className="text-xs text-destructive">{keyError}</p>
|
|
||||||
)}
|
|
||||||
</>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|||||||
Reference in New Issue
Block a user