Small genai fix (#14850)

* Ensure the regenerate button shows when genai is only enabled at the camera level

* update docs
This commit is contained in:
Josh Hawkins
2024-11-07 14:27:55 -06:00
committed by GitHub
parent 15bd26c9b1
commit 0d59754be2
5 changed files with 21 additions and 9 deletions

View File

@@ -477,7 +477,7 @@ function ObjectDetailsTab({
onChange={(e) => setDesc(e.target.value)}
/>
<div className="flex w-full flex-row justify-end gap-2">
{config?.genai.enabled && (
{config?.cameras[search.camera].genai.enabled && (
<div className="flex items-center">
<Button
className="rounded-r-none border-r-0"

View File

@@ -77,6 +77,13 @@ export interface CameraConfig {
cmd: string;
roles: string[];
}[];
genai: {
enabled: string;
prompt: string;
object_prompts: { [key: string]: string };
required_zones: string[];
objects: string[];
};
live: {
height: number;
quality: number;