The Constraint That Forced Clarity

There was a hard deadline: launch before the spring homeschool season. That meant roughly six working days from the first git init to a live, paying product. No time for bikeshedding architecture, no time for half-done features. Every decision had to be right the first time.

Constraints are a gift. When you can't iterate on architecture, you think harder up front. When you can't afford bugs, you write tests. When you have one week, you cut scope ruthlessly and ship the 20% that delivers 80% of the value.

Architecture First, Code Second

Before writing a single line of application code, I spent half a day on the data model. Firestore collections, auth flows, Stripe webhook states, AI session management: all mapped in a single architecture doc. This saved me from a costly mistake: discovering you need to restructure your database at scale.

The stack: Next.js 15 App Router for the frontend (RSC + client components where needed), Firebase Auth with Google/Apple/Microsoft OAuth,Firestore as the primary database, Stripe for weekly subscriptions, a self-hosted model for AI (server-side only),Resend for transactional email, and Cloudinary for media.

The 17-Game Engine

The core product differentiator was an interactive game engine: 17 games across every subject and grade level (K–12), all built from scratch in TypeScript. No third-party game engines. No shortcuts. Each game has a complete state machine, adaptive difficulty, real-time scoring, and Firestore persistence.

The game engine was the hardest part of the build: 17 independent state machines, one per game, sharing a single type system instead of 17 one-off implementations. Building it in 3 days (days 2–4) was only possible because of heavy component reuse and a rigorous shared type system. Every game shares the same GameSession,Progress, and Achievement interfaces.

AI-Native, Not AI-Bolted-On

The AI engine powers lesson generation, progress analysis, and personalized learning plans. It runs entirely server-side. API keys never touch the client bundle. Responses stream to the UI via Server-Sent Events, giving users instant feedback even on complex 30-second generation tasks.

The most important architectural decision: multi-LLM routing. A self-hosted model for speed (lesson summaries, quick analysis), with fallback to longer context models for deep curriculum planning. A failure in one model doesn't cascade to the user.

What Shipped

By day 6, the build was a full production platform: auth, billing, an AI engine, and 17 production games spanning every K-12 subject and grade level.

What Made It Possible

Three things made this possible: deep focus (no meetings, no context switching), a consistent architecture pattern (same component structure throughout), and AI-assisted development used correctly: for boilerplate and repetitive patterns, not for architecture or business logic.

The lesson: velocity is a skill, not a circumstance. It compounds with every project. The more production systems you've shipped, the faster you can ship the next one.