feat(provenance): ML stops surfacing the artist category

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-18 21:36:43 -04:00
parent e798302cfa
commit 592c665701
4 changed files with 34 additions and 4 deletions
+3 -2
View File
@@ -48,12 +48,13 @@ class SuggestionService:
).scalar_one()
def _threshold_for(self, s: MLSettings, category: str) -> float:
# 'artist' intentionally absent (FC-2d-vii-c) — falls through to
# the 1.01 "never surfaces" default like any unsurfaced category.
return {
"artist": s.suggestion_threshold_artist,
"character": s.suggestion_threshold_character,
"copyright": s.suggestion_threshold_copyright,
"general": s.suggestion_threshold_general,
}.get(category, 1.01) # 1.01 => never surfaces (unsurfaced category)
}.get(category, 1.01)
async def for_image(self, image_id: int) -> SuggestionList:
img = await self.session.get(ImageRecord, image_id)