Working notes
Short posts about things I had to figure out. Written for me, shared in case they save you a search.
View Transitions API in a Shopify theme
How I wired up AJAX page transitions in a Dawn-based Shopify theme with about 30 lines of vanilla JS and zero build tools.
Crash at boot, not on the first request
Why I validate all required env vars at server startup — and what it looks like in a Next.js App Router project.
Token accounting is the feature, not the chat
How we reconcile per-user token spend in MongoDB against Anthropic's monthly invoice — and why we do it server-side at tool-call boundaries.
Stop routing file uploads through your server
Presigned S3 PUT URLs for the warranty form — the file bytes never touch Next.js, and the UX is better for it.
MCP over SSE is easier than stdio for web workloads
Why I picked SSE transport for our FastMCP server, the one reconnection problem it creates, and how we handled auth.
Hybrid BM25 + dense retrieval that actually helps
Why parent-child chunking made the biggest difference for our docs RAG, and the cross-encoder reranker tuning that followed.