← work
data · Q1 2026 — present

ChatAEC — QA dashboard, no warehouse

PostgREST + Caddy + versioned SQL views directly on the operational database. Zero ETL, zero freshness lag, four days to first dashboard.

roleQA Data Engineer (solo)
timespanQ1 2026 — present
stackpostgrestpostgrescaddysql-viewsreact
statusoperational

The problem

The zoning-compliance pipeline produces QA signals continuously — hallucinated section numbers, citation drift, missing references. The team needed a real-time dashboard to surface these before they reached end-users.

The obvious answer — stand up a data warehouse, run an ETL job, build a BI layer — would have taken weeks and added three new services to operate.

The architecture

postgres → versioned SQL views (qa.qa_v1_*) → postgrest → caddy → react

The operational Postgres database already held all the QA data. Instead of moving it, we exposed it directly:

  1. Versioned SQL views (qa_v1_citation_drift, qa_v1_hallucination_rate, …) computed QA metrics as pure SQL. The v1 namespace prefix lets us evolve views without breaking the React frontend.
  2. PostgREST auto-generates a REST API from the qa schema. Adding a new view = a new endpoint, no code changes.
  3. Caddy handles TLS termination and JWT authentication — the same Caddyfile that fronts everything else on the VPS.
  4. React frontend reads from the PostgREST endpoints. No ORM, no API server, no custom middleware.

What I built

Tradeoffs

| Decision | What we gained | What we gave up | |---|---|---| | No warehouse | Zero new services, zero ETL lag | Can't join across Iceberg tables | | PostgREST API | Instant endpoints, no API code | Less control over query shape | | Versioned views | Safe evolution, rollback by alias swap | More view aliases to manage | | Caddy vs Nginx | Simple auth config | Slightly less flexible routing |

Outcomes