The Postgres ORM that ships light and locks tight. One runtime dependency, a read-only Studio no other ORM has, and error messages that never leak PII. v0.14 routes generated type metadata and bulk-insert array casts through the dialect contract without changing Postgres imports.
What Prisma and Drizzle don't ship
Turbine ships pg and nothing else. No WASM engine (Prisma: 1.6 MB), no adapter chain, no lockstep package upgrades. 110 KB on npm, 5 KB on the edge entry.
npx turbine studio launches a loopback-bound web UI. Every query runs inside BEGIN READ ONLY. 192-bit auth token, statement-stacking guard, X-Frame-Options: DENY. No other TS ORM ships this.
Turbine errors show WHERE keys, not values. A UniqueConstraintError says which column violated the constraint — never the actual user data. Safe to log, safe to surface to monitoring, no scrubbing needed.
Write real SQL. SHA-256 checksums catch modified migrations. pg_try_advisory_lock() prevents concurrent runs. Each migration in its own transaction. No magic DSL between you and your database.
turbineHttp(pool, schema) — same API on Neon, Vercel Postgres, Cloudflare Hyperdrive, Supabase. No WASM bundle to ship, no adapter package to install, no separate serverless build step.
Real Parse/Bind/Execute pipeline — not queries wrapped in a transaction. N independent queries in one round-trip. Deep with clauses compile to one SQL statement using json_agg.
How it works
Every ORM claims single-query nested loads now. Turbine uses the same json_agg approach as Prisma 7 and Drizzle v2. The difference isn't the query strategy — it's everything around it: the 110 KB footprint, the read-only Studio, and the error messages that never expose user data.
SELECT "users".*,
(SELECT COALESCE(json_agg(json_build_object(
'id', t0."id",
'title', t0."title",
'comments', (SELECT COALESCE(json_agg(json_build_object(
'id', t1."id",
'body', t1."body"
)), '[]'::json) FROM "comments" t1
WHERE t1."post_id" = t0."id")
)), '[]'::json)
FROM (SELECT * FROM "posts"
WHERE "posts"."user_id" = "users"."id"
ORDER BY "posts"."created_at" DESC
LIMIT 5) t0
) AS "posts"
FROM "users"
WHERE "users"."org_id" = $1Comparison
One install, one generate, one query. Get a typed Postgres client in under two minutes.