Introduction
Hey everyone, I'm Oil. This postmortem walks through every real decision behind building Oil Book (book.oiloil.org) from scratch.
First, we'll look at why I built a custom site instead of using a hosted course platform, how I picked the tech stack, and how I explored visual directions, named the site, and refined the reader experience.
Then we'll move into full-stack architecture, lightweight login and Stripe billing, three-layer server-side paywall protection, and the content engineering pipeline—topic mining, interview-based writing, automated copy linting, editable art-plus-SVG illustrations, and automated PR releases.
Why Build Custom & Tech Stack Choices
Before writing a single line of code, I settled two foundational questions: why build from scratch, and what stack stays easiest to maintain long-term?
1. Why Skip Hosted Course Platforms
Plenty of hosted knowledge-base and paid-newsletter tools exist, yet I chose to build a standalone site for three reasons:
First: Frictionless public conversion + organic search (SEO)
Closed platforms make converting public video viewers painfully hard—funneling people into private WeChat groups hurts conversion and constantly risks platform traffic-diversion penalties.
On a public standalone website, anyone can open a link, sample half a guide, and purchase directly. As articles accumulate, SEO brings compounding organic search traffic that closed platforms simply can't match.
Second: Total control over reading experience and design
Third-party tools trap you inside their layout templates. Building my own site meant I could display courses like books on a warm paper shelf and give readers custom font-size and serif/sans toggles.
Third: With existing dev & billing experience, custom was actually simpler
I already had development experience and had integrated payments on earlier products. Spinning up a clean, fully owned site with AI was genuinely faster than fighting third-party platform workarounds.
2. Next.js, Neon Postgres & Local Markdown Files
I chose the stack I knew best—and the one AI Agents handle most cleanly:
Next.js(see Core Engineering & AI Concepts for Vibe Coding): Frontend UI and backend API routes live in one repo, so an AI Agent traces every button-to-API flow in one place.- Neon (serverless Postgres): Stores accounts, login sessions, and Pro entitlements. When no cloud DB URL is configured locally, the app automatically falls back to an embedded local database so cloning the repo runs immediately.
- Local
Markdown(.md) files for articles: Rather than building a heavy CMS rich-text editor in the database, every guide lives as a plain.mdfile in the repo—dead simple for me to edit directly and easy for AI Agents to read as context.
Initialization takes one clear kickoff prompt:
Visual Exploration & Reading Craft
Before building any backend plumbing, I locked down the site's visual identity and reading comfort.
1. Comparing Three Visual Directions & Naming the Site
I sketched three distinct concepts and used my open-source Skill oil-ui (see Designing Polished UI with AI) to render three live single-file HTML candidates side by side:

- Crisp modern blog: Clean editorial index of standalone posts.
- Light magazine zine: Thematic booklets arranged like magazine issues.
- Classic warm-paper bookshelf: Tactile paper aesthetic where each guide stands like a book on a shelf.
One prompt kicked off the divergence:
Seeing real rendered pages side by side made picking easy. As I refined the bookshelf direction, the model-recommendation widget at the top clashed with the book cards below, so I ran a second three-way exploration just for the shelf area:

Only after committing to the warm-paper bookshelf aesthetic did the name Oil Book (and book.oiloil.org) click—before that, I had been thinking of generic names like blog or knowledge (the title shown in the first-round comparison screenshot above was updated later when archiving under the final name).
2. Simplifying Chrome & Refining Article Readability
Early AI drafts almost always over-decorate with heavy nested borders. I immediately trimmed clutter using plain visual feedback:
On article pages, one priority ruled everything: long-form reading comfort.
I added font-size scaling, a serif (print-book feel) vs. sans-serif (clean screen feel) toggle, and tuned letter-spacing and line-height so long paragraphs breathe comfortably—then captured the whole design system into DESIGN.md with oil-ui:
Architecture Planning & Dev Workflow
With visuals set, I used oil-plan from my open-source suite oil-dev-skills to design the backend architecture.
Compared to default Agent Plan modes, oil-plan adds two key safeguards:
- Business-readable specs: Explains user-visible behavior, reused modules, and concrete tradeoffs in plain language instead of dumping raw file paths and function signatures.
- Automatic independent subagent review: Before showing me the plan, a fresh read-only subagent stress-tests it for gaps.
Critical boundaries like backend security and preventing paywalled text from leaking into frontend bundles belong in the initial plan—never patched on afterward:
I used the rest of oil-dev-skills selectively based on repo scale:
oil-explore&oil-delegate: Oil Book is lean enough that heavy multi-agent code exploration wasn't needed. During initial feature scaffolding, I usedoil-delegateto run parallel Codex modules; once daily article writing took over, I worked mostly inside Gemini directly.oil-code-review(non-negotiable after every feature): Every completed module gets an independent review pass for runtime bugs and security holes:
oil-govern(continuous rule refinement): Whenever an execution snag surfaced, I fixed it and updated the repo rules on the spot so it wouldn't repeat:


