9f96a91986
- Runtime quick-select buttons (Any/90m/2h/2.5h) filter movies by length - Kid-friendly toggle forces PG-13 max and boosts Family/Animation genres - Surprise Me picks a random mood prompt from 20 curated options - Show Me More re-rolls same mood excluding already-shown movies - Re-roll appends new results to the existing search history entry Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
56 lines
1.4 KiB
Python
56 lines
1.4 KiB
Python
from pydantic import BaseModel
|
|
|
|
|
|
class Movie(BaseModel):
|
|
jellyfin_id: str
|
|
title: str
|
|
sort_title: str | None = None
|
|
year: int | None = None
|
|
genres: list[str] = []
|
|
overview: str | None = None
|
|
community_rating: float | None = None
|
|
critic_rating: float | None = None
|
|
runtime_minutes: int | None = None
|
|
content_rating: str | None = None
|
|
studios: list[str] = []
|
|
people: list[dict] = []
|
|
tags: list[str] = []
|
|
|
|
|
|
class MoodRequest(BaseModel):
|
|
mood: str
|
|
additional_user_ids: list[str] = []
|
|
max_runtime: int | None = None # Max runtime in minutes (None = no limit)
|
|
kid_friendly: bool = False # Force PG-13 max rating + boost family genres
|
|
exclude_ids: list[str] = [] # Jellyfin IDs to exclude (for re-roll)
|
|
history_id: int | None = None # If set, append results to this history entry
|
|
|
|
|
|
class Recommendation(BaseModel):
|
|
jellyfin_id: str
|
|
title: str
|
|
year: int | None = None
|
|
genres: list[str] = []
|
|
community_rating: float | None = None
|
|
runtime_minutes: int | None = None
|
|
content_rating: str | None = None
|
|
poster_url: str
|
|
deep_link: str
|
|
reasoning: str
|
|
match_score: float
|
|
|
|
|
|
class MoodResponse(BaseModel):
|
|
recommendations: list[Recommendation]
|
|
meta: dict
|
|
|
|
|
|
class LoginRequest(BaseModel):
|
|
username: str
|
|
password: str
|
|
|
|
|
|
class UserInfo(BaseModel):
|
|
id: str
|
|
name: str
|