How cwill713/movie-catalog works
Movie Catalog is a household-oriented movie and TV catalog with a signed-in web UI and REST API. The main workflow resolves a session to a profile, then serves catalog searches/details or watch-list operations through repositories backed by PostgreSQL; the browser UI complements the API. Separate maintenance scripts ingest IMDb data, enrich titles, and generate embeddings. The README describes a simpler SQLite version, while sampled runtime code shows Supabase authentication and PostgreSQL with row-level security. Script and frontend connections are included only where the supplied index or excerpts support them.
Main entry points: main.py FastAPI app · web.py Web pages · auth.py Session identity · db.py DB access and RLS
Components 22
Application runtime
- FastAPI app
app/main.py - Web pages
app/routes/web.py - Watch-list API
app/routes/api_movies.py - Catalog API
app/routes/catalog.py - Page templates
app/templates - Browser assets
app/static
Identity and access
- Login routes
app/routes/auth.py - Session identity
app/auth.py - Settings
app/config.py
Catalog and watch list
- Catalog queries
app/repositories/titles.py - Watch entries
app/repositories/watch_entries.py - API schemas
app/schemas.py - DB access and RLS
app/db.py
Catalog maintenance
- IMDb ingestion
scripts/ingest_imdb.py - OMDb enrichment
scripts/enrich_omdb.py - Embedding batches
scripts/db_embedding.py - Embedding ablation
scripts/embedding_ablation.py - Embedding evaluation
scripts/testing_embeddings.py
Other components
- Household user
- Supabase Auth
- PostgreSQL
- Ollama
Connections 29
- Household user → FastAPI app: uses
README.md - FastAPI app → Session identity: resolves identity
app/main.py - FastAPI app → Web pages: registers routes
app/main.py - FastAPI app → Watch-list API: registers routes
app/main.py - FastAPI app → Catalog API: registers routes
app/main.py - FastAPI app → Login routes: registers routes
app/main.py - Web pages → Watch entries: loads entries
app/routes/web.py - Web pages → Catalog queries: loads catalog
app/routes/web.py - Web pages → Page templates: renders pages
app/routes/web.py - Web pages → Browser assets: serves UI
README.md - Watch-list API → Watch entries: dispatches operations
app/routes/api_movies.py - Watch-list API → API schemas: validates payloads
app/routes/api_movies.py - Catalog API → Catalog queries: dispatches queries
app/routes/catalog.py - Catalog API → API schemas: uses response models
app/routes/catalog.py - Login routes → Session identity: signs in
app/routes/auth.py - Session identity → Supabase Auth: exchanges credentials
app/auth.py - Session identity → DB access and RLS: looks up profile
app/auth.py - Session identity → Settings: loads settings
app/auth.py - Watch entries → DB access and RLS: opens scoped connection
app/repositories/watch_entries.py - Catalog queries → DB access and RLS: opens scoped connection
app/repositories/titles.py - DB access and RLS → PostgreSQL: queries with RLS
app/db.py - DB access and RLS → Settings: gets connection settings
app/db.py - IMDb ingestion → Settings: loads settings
scripts/ingest_imdb.py - OMDb enrichment → Settings: loads settings
scripts/enrich_omdb.py - Embedding batches → Settings: loads settings
scripts/db_embedding.py - Embedding batches → PostgreSQL: reads and updates titles
scripts/db_embedding.py - Embedding batches → Ollama: requests vectors
scripts/db_embedding.py - Embedding ablation → Embedding batches: uses embedding module
scripts/embedding_ablation.py - Embedding ablation → Embedding evaluation: uses evaluation module
scripts/embedding_ablation.py