Build AI model release timeline dashboard with FastAPI, Playwright and HTMX
Session from llm_timeline_deepseek_v4_flash-pi on Hugging Face by lucacorbucci · MIT · condensed by Coders Talk
Implement a spec (timeline.md) for an interactive dashboard that scrapes AI model release data and visualizes release frequency over time, with a scraper, analytics engine, API and frontend.
- +0Prompt · +0Read AGENTS.md then implement what's asked in timeline.md
- +0mAgent did · +0mExplored the empty project, set up a venv, installed fastapi/playwright/pandas/plotly/jinja2/etc, and installed Playwright's chromium browser.
- +1mAgent did · +1mBuilt the full project: sample HTML test data, async Playwright scraper (src/scraper.py), pandas analytics engine (src/analytics.py), FastAPI app (src/app.py), Jinja2+HTMX dashboard template, and test files for scraper and analytics.
- +3mAgent did · +3mFixed pyproject.toml build-backend, installed setuptools/pytest, corrected test expectations to match sample data counts (25 models), and got all 20 tests passing.
- +4mFail · +4mServer failed with a Jinja2 3.1.6 + Python 3.14 weakref-hashing bug in the template loader when hitting GET /, discovered while manually testing the running uvicorn server.
- +5mAgent did · +5mDeep-dived into Jinja2 internals and weakref caching, initially tried disabling the template cache, then found the real cause: Starlette 1.3.1 changed TemplateResponse's signature to require request as the first positional arg.
- +7mFail · +7mAfter fixing the template bug, /api/data endpoint broke on serialization: pandas Period, Timestamp and numpy float64 values weren't JSON-serializable.
- +7mAgent did · +7mRewrote from_scrape_result to convert all pandas/numpy types to native Python types, reran the full test suite (20 passing) and verified the dashboard, /api/trend, /api/data and chart endpoints all worked end-to-end.
- +11mAgent did · +11mAdded a Makefile with install/run/test/clean targets after the developer asked how to run the project and requested a Makefile.
- +11mOutcome · +11mDashboard, scraper, analytics engine and API finished with 20 passing tests, a working FastAPI server serving 25 sample AI model releases, and a Makefile for install/run/test/clean.
I'd start by pinning the Python/Jinja2/Starlette versions up front, since most of the debugging time went into a Python 3.14 + Jinja2 3.1.6 weakref bug and a Starlette TemplateResponse signature change that had nothing to do with my actual spec. The fix that actually mattered was tracing the real error down to Starlette's changed argument order rather than papering over it with a cache workaround. Next time I'd also ask for JSON-serializable outputs (no raw pandas Period/Timestamp/numpy types) from the start to avoid the second round of serialization fixes.