2026-03-14 19:20:56 -07:00
|
|
|
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] = []
|
2026-03-14 20:07:05 -07:00
|
|
|
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
|
2026-03-14 19:20:56 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
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
|