From 65d3e9e82c47ea109725fd6fb93b00eed7cd0aad Mon Sep 17 00:00:00 2001 From: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com> Date: Tue, 19 May 2026 07:54:52 -0500 Subject: [PATCH] preserve user-set min_score on attribute filters instead of bumping any 0.5 value use model_fields_set to distinguish "user explicitly set min_score" from "Pydantic applied the generic FilterConfig default of 0.5" --- frigate/config/config.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/frigate/config/config.py b/frigate/config/config.py index 04dd46a67a..7aa6dac59d 100644 --- a/frigate/config/config.py +++ b/frigate/config/config.py @@ -629,10 +629,11 @@ class FrigateConfig(FrigateBaseModel): # set default min_score for object attributes for attribute in self.model.all_attributes: - if not self.objects.filters.get(attribute): + existing = self.objects.filters.get(attribute) + if existing is None: self.objects.filters[attribute] = FilterConfig(min_score=0.7) - elif self.objects.filters[attribute].min_score == 0.5: - self.objects.filters[attribute].min_score = 0.7 + elif "min_score" not in existing.model_fields_set: + existing.min_score = 0.7 # auto detect hwaccel args if self.ffmpeg.hwaccel_args == "auto":