el-imperfecto.com Architecture

Spanish-reading web app · FastAPI / SQLAlchemy async · single-user workload

Edge / DNS Reader Browser Cloudflare DNS · TLS robots.txt noindex · blocks bots Render · Web Service FastAPI App async · uvicorn SQLAlchemy async NullPool per-request el-imperfecto.com commit 06f34fe HTMX Frontend poll endpoints SSR templates crawler-blocked LLM Rewrite / Gloss provider-neutral config LLM_PROVIDER switch Anthropic (default) | OpenRouter gemini-flash · flash-lite Neon Postgres · Launch plan Neon Compute PostgreSQL 16 autoscale 0.25 - 1.0 CU scale-to-zero @ 5 min single-user workload Neon Storage separated · pay-per-use External LLM Providers Anthropic default provider Claude OpenRouter gemini-3.5-flash gemini-3.1-flash-lite Cost Controls (commit 06f34fe) NullPool drains conns per-request → Neon compute suspends robots.txt blocks crawlers from HTMX poll endpoints HTTPS proxy block async SQL · NullPool API call Legend Frontend / HTMX Backend / Render Edge / Cloud Database / Neon Security / Cost-control Blocked flow External API Cloud region

Application Layer

  • • FastAPI async on Render web service
  • • SQLAlchemy async ORM
  • • NullPool drains DB conns per-request
  • • HTMX server-rendered templates
  • • Private repo on GitHub

Neon Postgres

  • • Launch (paid) plan, not Free
  • • Scale-to-zero fixed @ 5 min
  • • Autoscale capped 0.25–1.0 CU
  • • Separated storage, pay-per-use
  • • Single-user workload

Cost Controls

  • • NullPool → Neon compute can suspend
  • • robots.txt blocks crawlers
  • • noindex on HTMX poll endpoints
  • • OpenRouter cheaper models for LLM
  • • Applied in commit 06f34fe