The archive.
Every essay, newest first. Rails and Postgres at scale, AWS cost and access-log forensics, Go tooling, LLM systems that know when to abstain, and a running interest in designing software that fails loudly instead of quietly.
- The Agent Wanted to Call It Healthy. I Made It Abstain.
Shipping real software with coding agents, where the value is the judgment layer on top.
- Is It a Regression, or Just a Flaky Test? Teach Your CI to Tell the Difference
A red build tells you something failed. It doesn't tell you the thing that matters — whether a human needs to fix it now, or whether the test will be green next run. Here's a small, dependency-free flake engine that answers that from run history.
- A False Signal Is Worse Than a Missed One: Citing and Abstaining in LLM Document Extraction
When you turn public documents into sales signals with an LLM, the expensive failure isn't the signal you miss — it's the one you invent. Two disciplines fix it: cite every signal to a verbatim source span, and abstain when the document supports nothing.
- Data Sovereignty Is an Access-Control Pattern (and It Should Fail Closed)
Turning ‘the community owns its data’ into enforceable, audited code: default-deny access, owner-granted sharing, no super-role, and an append-only audit trail — over a territorial-monitoring dataset.
- When ‘Compliant’ Is a Legal Claim: Computing EUDR Deforestation Risk — and Knowing When to Abstain
Scoring forest loss inside a plot boundary is the easy half. The engineering that matters is refusing to certify on bad geodata.
- The Number Was Green, So the Agent Stayed Quiet
Putting an eval harness and an abstain gate around an LLM analysis agent so it's trustworthy on noisy marketing data
- Never Bill a Sentence the Chart Didn't Write: Evidence Gates for Clinical Charge Capture
Why an AI that finds missed hospital reimbursement has to cite the chart and abstain — and why that guardrail belongs in deterministic code, not in a prompt.
- Designing a Fail-Closed Access Gate in TypeScript
A worker walks up to a turnstile. Should it open? The safe answer to that question is a small, pure, boring function — and a tamper-evident record of every time you asked.
- Fail-Open or Fail-Closed: The One Decision Every Piece of Edge Middleware Has to Make
When the edge state store goes down, your middleware has to choose between letting traffic through and blocking it. That choice is a design decision, not a default — and the right answer flips depending on what the middleware is for.
- The Audit Log That Can't Have Holes
Building a gap-free, append-only compliance ledger in Elixir/Phoenix — why the obvious approaches all fail, and the one pattern that survives a regulator.
- Knowing When Not to Make the Highlight Reel
Ranking, dedup, and the senior instinct to refuse — building a camera-roll video picker.
- The LLM Suggests. The Rules Engine Decides.
Why a compliance or money classifier keeps a deterministic core — and puts the model behind an abstain gate.
- The Authorization Gate: Modeling Multi-Party Workflows in Rails
Four parties, one work order, and the single invariant that keeps money and compliance from leaking out of the seams.
- Never Trust the Model's Answer Key
Validating LLM-generated assessment content deterministically before it reaches a student
- The Best Thing an Observability Agent Can Say Is 'I Don't Know'
Giving an LLM observability assistant an eval harness and an abstain gate so it never invents a root cause on noise.
- Measure the Aggregate, Never the Person: Privacy-Preserving Analytics with a k-Anonymity Gate
Most analytics ships a re-identifiable event log to a server and aggregates there. Here's the inversion — aggregate on-device, and refuse to report any cohort small enough to single someone out.
- The Query That Got 30× Faster Without Changing Its Answer
A patient-journey analytic over a claims graph, taken from a naive plan to a materialized-view rollup — with the one rule that separates an optimization from a bug.
- The Self-Healing Scraper That Refuses to Trust Itself
Letting an LLM repair a broken selector is easy. The engineering is in refusing to believe it.
- A Staffing Forecast Without a Confidence Interval Is a Liability
Why a next-shift census model has to ship uncertainty, defer on thin data, and prove itself against a naive baseline before anyone staffs a floor from it.
- Streaming a Conversational-AI Trainer — and Teaching It to Say 'I Don't Know'
How to stream an LLM roleplayer over Server-Sent Events, and why the debrief that scores a trainee should abstain instead of inventing a number.
- Flip One Byte and the Whole Chain Knows
Building a tamper-evident, hash-chained log and the verifier that makes it worth anything — and what real end-to-end voting adds on top.
- The Honest Answer Is Sometimes 'Not Enough Data'
Normalizing heterogeneous financial data with provenance — and building a gate that refuses to score a thin file.
- When Not to Answer: Building a Voice-Over-Email Loop With a Consent Gate
A small, runnable prototype of a voice product over email — transcribe, LLM reply, synthesize, thread back — and why the most important line of code is the one that refuses to speak.
- Building an SEO Dashboard in React
How we built Beacon — a responsive React SEO & Core Web Vitals dashboard with hand-coded SVG gauges, no chart library, and a theme system that never flashes.
- A Sans-I/O SSE Parser for Python
Server-Sent Events are small but fiddly to parse correctly, and the existing Python libraries couple parsing to one HTTP client. sansio-sse is just the state machine — the WHATWG event-stream algorithm, reusable on httpx, requests, aiohttp, or a raw socket.
- Retry Backoff You Can Actually Test
Every remote call needs retries with jitter, but jitter is randomness, and randomness is where retry code flakes. backofflite keeps the backoff math pure and seedable and makes time.sleep injectable, so you can assert the exact delay schedule and no test ever really sleeps.
- Property-Based Testing in PHP, at Last
Haskell has QuickCheck, Python has Hypothesis, JavaScript has fast-check. PHP never got a good, maintained one — so we built forall: property-based testing with automatic shrinking, for Pest and PHPUnit.
- The Same App, Built in Six PHP Frameworks
We built one small application — a public message board — idiomatically in Laravel, Symfony, CodeIgniter, CakePHP, Slim, and WordPress, and deployed every one. A live tour of what each framework is actually good at.
- Triaging Claim Denials, and Designing for the Moment It's Wrong
A healthcare denial-triage tool built on Django, Celery, and Postgres: webhook ingest, a background LLM classifier with structured output, transient-failure retries, PHI-free logging, and an abstain path that parks uncertain claims for a human.
- Triage at the Loan-Tape Boundary
A production-shaped LLM classifier for mortgage servicing: structured JSON output, idempotent loan-tape import, an append-only audit log, and the abstain path that keeps a confident-wrong answer off a borrower's mortgage.
- A Drupal 10/11 Migrate Module, End to End
Building an idiomatic Drupal 10/11 custom module end to end: Migrate API source + process plugins, content type/fields/taxonomy via configuration management, Twig theming, and Drush commands.
- Compiling Bash Globs into Ruby Regexps
JavaScript has picomatch and minimatch; Ruby doesn't. picoglob compiles bash-style glob patterns into reusable Ruby Regexps so you can match arbitrary strings — S3 keys, routes, log lines, branch names — not just files on disk.
- Durable Invoice-to-Provisioning Workflows in Python
A durable invoice intake to provisioning workflow engine in pure Python: an async orchestrator with retries/backoff, a dead-letter queue, structured logging, SLO reporting, and pluggable ERP/ticketing connectors.
- Enterprise IAM: RBAC, ABAC, Federation & Non-Human Identity
A pure-Python reference for enterprise IAM: RBAC + ABAC authorization, federation/SSO claim mapping, non-human identity governance, segregation-of-duties, access certification, and a hash-chained audit log.
- Fuzzy-Match Scoring in Ruby
A dependency-free Ruby port of fzy's fuzzy-match scoring that returns both a relevance score and the matched character positions for highlighting — exactly what you need to build a command palette, quick-open, or CLI picker.
- Pixel-Perfect, Responsive Marketing Pages in HTML5 & CSS3
Building a pixel-perfect, fully responsive marketing landing page in semantic HTML5 and modern CSS3 with ES6 JavaScript (and a jQuery variant) — mobile-first, accessible, cross-browser, zero build step.
- A Ruby Backend for the Vercel AI SDK
The Vercel AI SDK's useChat hook speaks a specific Server-Sent-Events wire format. The official backends are JavaScript and Python — Ruby had nothing. Here is the gem that lets a Rails or Rack app drive useChat from Ruby.
- Building a Multilingual Speech Corpus, Verified by Whisper
How we built a clean, machine-verified speech corpus across 38 languages from messy public audio — the dedup, the Whisper verification gate, and the edge-served manifest behind LinguaGuessr.
- Saying "Hey Claude" Out Loud, On-Device
Could you say 'Hey Claude' out loud and have a coding agent start working — fully on-device, without piping your microphone to the cloud all day? Here is the pipeline, the wake word we trained from scratch, and the macOS permission story underneath it.
- Hunting N+1 Queries Systematically
A practical workflow for finding and killing N+1 queries in a large Rails app, using bullet, prosopite, and strict_loading together rather than one at a time.
- Postgres Indexing for Rails at Scale
Partial indexes, EXPLAIN ANALYZE, composite-index column order, and counter caches — the Postgres indexing patterns that matter once a Rails table gets large.
- Rails Caching Done Right
Russian-doll fragment caching, low-level Rails.cache, cache key versioning, and why you almost never write an explicit expire. The caching patterns that stay correct as the app changes.
- Sidekiq Idempotency and Reliability Patterns
Exactly-once is a lie, so design for at-least-once. Idempotency keys, dedup, retries with backoff, poison jobs, and the dead set — the Sidekiq patterns that keep background work correct under failure.
- Real-Time UI Without React
A production Turbo Streams + Stimulus pattern for real-time Rails UI — no React, no API layer, no client-side state to keep in sync.
- Zero-Downtime Migrations at Scale
Locks, backfills, CONCURRENTLY, and dual-writes — how to change a large Postgres schema under a live Rails app without taking it down, and why strong_migrations belongs in every project.
- The Page That Counted 800 Million Rows
When aggressive denormalization is the right answer.
- One Commit, Six Lessons
A Salesforce sync, a read follower, and the audit that reshaped a credentials posture.
- The ERP That Will Only Talk to You by Email
A production integration built on AWS SES, a job queue, and compound indexes.
- Skills, Not Chatbots
Building an internal AI plugin system for an engineering team.
- The Support Tool That Replaced Itself
Building an MCP server so Claude Desktop could edit production data safely.
- The Monorepo Was for the Agents
Cross-team context for AI agents without a real migration.
- The Support Tool That Edits Five Tables Atomically
A reparent-user workflow with a dry-run diff.
- 319 N+1s, 5,940ms Wasted
Auditing a decade of Rails code in one afternoon.
- The Hidden Cost of `mount Admin::Engine`
What we learned migrating a generated admin to React + GraphQL.
- The Question the AWS Console Will Not Answer
RDS IOPS pattern detection with Ruby and a spreadsheet.
- S3 Access Log Archaeology
Turning a year of access logs into an archival policy.
- A Petabyte, a Bill, and a Tiering Decision
How we cut an S3 line item ~60% without breaking a single user workflow.
- One UIConfig, Four Runtimes
A production server-driven UI across iOS, Android, React, and React Native.