CORTEX

Full-stack · Backend · GenAI

Ujjwal Jain

I build products end to end: backends and data pipelines, LLM features with guardrails around them, and the web or extension interfaces people use. I go deep where it matters, down to a database engine or a wire protocol. Each project below links to its code and says what it doesn't do yet.

Bachelor's in Computer Science · BITS Pilani · 8.82 CGPA · 2024–2028

Now

Updated

  • In review

    Apache Superset #43985: Vary SQL Lab ad-hoc query cache key by effective RLS predicates. Open and approved by a reviewer; not merged yet. Pull request

  • In review

    Apache Superset #44248: Fall back to the lean Dockerfile target when publishing a pre-#44100 release. Open and approved by a reviewer; not merged yet. Pull request

  • In review

    Vitest #9662: Add mergeTests utility to compose TestAPI fixtures. Open. The maintainer has requested changes to the tests. Pull request

  • Active development

    LEXIS, a retrieval-augmented generation (RAG) system that is still a work in progress. Recent work replaces a placeholder entailment check with a real model and wires in cross-encoder reranking, which is off by default. Repository

  • Active development

    OSS Hunter, an engine that scores a repository's issues for complexity with an LLM and ranks them by graph-propagated importance. Early stage, and the repository is private for now.

  • Just published

    FlashFlow, a Go lab that replays routing policies on identical traffic to show why one collapses under load. Project page →

  • Just fixed

    A security and honesty pass over CampusSync, VaultTabs, RecoveryOS and AgentBrake, including AgentBrake's fail-open bugs. The AgentBrake record →

Featured projects

The 5 projects with the most verifiable engineering. Each page shows the evidence, links to the source files, and says what isn't done.

RecoveryOS

PROTOTYPE

Recovers failed payments: an LLM may recommend, but only a deterministic policy engine may act.

Razorpay Buildathon, Track 03 · Aug–Sep 2026

  • Execution is idempotent: an idempotency key plus a PostgreSQL advisory lock, with a unique-constraint backstop. An integration test races two real threads against it.
  • A test walks the syntax tree to prove that execution code cannot reference the AI recommendation.
  • Python
  • FastAPI
  • PostgreSQL
  • Alembic
  • Redis Streams
  • Next.js
  • +4

MiniDB

PROTOTYPE

A relational database built from scratch: B+ tree, buffer pool, SQL, optimizer, locking and crash recovery.

Course capstone (two people) · Jun 2026

  • 133 tests in 26 suites pass. They include a crash matrix that simulates failures between a WAL flush and a page flush, a 1,000-operation SQL fuzz test against a reference model, and deadlock tests.
  • A 683-line disk-backed B+ tree with split, merge, borrow and bulk-load, and its root persisted through the catalog.
  • TypeScript
  • Node.js
  • Jest
  • sql-parser-cst

Fuze

ONGOING

Semantic bookmark manager: pgvector search, a worker pipeline, and recommendations gated by regression tests.

Personal project, ongoing · Jul 2025 – present · 455 commits

  • HNSW indexes (m=16, ef_construction=64) built with CREATE INDEX CONCURRENTLY inside an Alembic migration.
  • A golden-set regression test in CI requires NDCG@10 and MRR of at least 0.85 on four queries. It compares paths that share one engine, so it is a regression guard, not a quality measurement.
  • Python
  • Flask
  • PostgreSQL
  • pgvector
  • Redis
  • RQ
  • +4

SSE-Observatory

PROTOTYPE

A browser-based debugger for Server-Sent Events: query language, replay, and multi-tab stream sharing.

Personal project · Feb–Mar 2026

  • One shared SSE connection per stream across tabs, with reconnect backoff.
  • Interceptors are isolated in workers and killed on timeout.
  • TypeScript
  • React
  • Vite
  • Web Workers
  • SharedWorker
  • IndexedDB
  • +3

FlashFlow

PROTOTYPE

A Go lab that replays routing policies on identical traffic and classifies why one of them collapses under load.

Personal project · Aug–Sep 2026 · 226 commits on 5 days

  • go test ./... on a fresh clone: 24 packages pass, 503 top-level tests, 0 failures. go build, go vet and gofmt are clean. About 46,900 lines of Go, of which 20,284 are 89 single-file experiment programs.
  • Six policies are compared: round-robin, weighted round-robin, least-connections, EWMA, power-of-two-choices by in-flight count, and an adaptive weighted policy.
  • Go
  • net/http
  • GitHub Actions
  • JavaScript dashboard
  • Prometheus text format
All 14 projects

Open source

10 merged pull requests to projects I don't own: 7 in Apache Superset, 1 in Appwrite and 2 in Vitest. Mostly bug fixes with tests, and each was reviewed and merged by a maintainer.

What didn't go to plan

I keep the misses in the record rather than tidying them away. Two examples; the decisions and investigations pages have the rest.

A circuit breaker that could never trip

In AgentBrake I wrote a circuit-breaker policy with open, half-open and reset logic, and unit-tested it. Then I found that nothing in the proxy ever reports a failure to it, because the child's output is piped straight through. I fixed it months later by parsing the server's responses. The lesson: wire the signal before writing the policy.

Read the full record

A 10× target that reached 1.2–2.2×

In MiniDB I expected the vectorized executor to beat the Volcano-style one by about ten times. It reached roughly 1.2 to 2.2×, and the benchmark doc explains the overhead instead of hiding the miss. The lesson: measure first, and publish the number you got.

Read the full record

Writing

All posts

Explore CORTEX

The rest of the site is a small control-plane for my engineering notes. Press Ctrl/⌘ K to search it.