Skip to content
khanhthanhdev edited this page Jun 2, 2026 · 1 revision

Lore: The History of Stukit

The Six-Day Build

Stukit was built in six days. Between May 6 and May 11, 2026, a single developer (khanhthanhdev) went from an empty repository to a fully functional AI tool directory with semantic search, an admin dashboard, background job processing, and a Docker deployment pipeline — 23 commits, 36,000+ lines of TypeScript, one person.

There is no long history here. No refactors born from years of technical debt. No legendary outages that became cautionary tales. This is the story of a greenfield project that moved fast.

Timeline

Day 1 — May 6, 2026: Foundation

The repository was born at 17:06 UTC+7 with a single initial commit. Within the first three hours, three commits landed. The basic structure was in place: Next.js App Router, Prisma schema, Qdrant vector search configuration. A SubmitError class was added along with input sanitization using a honeypot field — security was a concern from the start.

Day 2 — May 7, 2026: Hardening

Four commits across the early morning hours (02:49–04:56 UTC+7). The theme of the day was removing surface area:

  • Public PostgREST and Qdrant API routes were removed. Database permissions were hardened.
  • The Inngest dashboard proxy was removed; the service was bound to localhost only.
  • Rate limiting and same-origin guard utilities were added.
  • Security headers and rate limiting with hardened IP handling were deployed.

By the end of Day 2, the attack surface had been significantly reduced. The application was no longer exposing internal services publicly.

Day 3 — May 10, 2026: Polish

A quieter day with two commits. Locale cookie settings were configured with secure attributes. Constants were extracted into dedicated modules. The Inngest SDK version was updated. The Tool database query was refactored from include to select with typed payloads — a performance-conscious change to avoid over-fetching.

Days 4–5 — May 11, 2026: The Big Push

Fourteen commits in a single day. This was the shipping sprint:

  • Validation: Honeypot validation was updated. A null check was added for slug in form submission.
  • CSP & Performance: Content Security Policy was updated for Cloudflare. Production source maps were enabled. Legacy JS polyfills were removed. S3 cache headers were configured.
  • Observability tradeoff: Sentry was removed in favor of simpler static caching. Conditional logging was added — development-only console output.
  • Rendering: Slug pages were forced to dynamic rendering. The migration to Next.js cacheLife and cacheTag was completed.
  • UX: A loading state was added. A tools page was built with enhanced caching.
  • Search: Search scoring was enhanced with cache versioning.
  • Docker: The Docker Compose setup was reworked — single app stage, pre-built images, and finally a build memory optimization to prevent OOM on small VPS hosts.

What Got Built

In six days, the project delivered:

  • Tool Directory: A searchable catalog of AI tools with category and collection organization
  • Semantic Search: Hybrid vector + keyword search powered by Qdrant with 768-dimension embeddings
  • AI Chat: Streaming conversational interface with semantic caching (0.92 similarity threshold)
  • Admin Dashboard: Full CRUD management for tools, categories, collections, and tags
  • Background Jobs: Inngest-powered pipeline for tool submission, scraping, screenshot generation, and publishing
  • Authentication: NextAuth.js with Google OAuth
  • Deployment: Docker Compose setup optimized for small VPS hosts

Patterns in the History

Security-first mindset. The first batch of post-launch commits was entirely about reducing attack surface. No public database proxies. No exposed dashboards. Rate limiting from the start.

Performance-conscious. The include → select refactor, cache versioning, cacheLife/cacheTag migration, and the final OOM prevention commit all show a developer thinking about production performance early.

Minimal dependencies, maximum leverage. 69 npm packages to build a full-stack application with AI, vector search, background jobs, and email. The stack choices (Next.js + Prisma + Qdrant + Inngest) are opinionated but efficient.

One person, no process overhead. No pull requests. No code review. No CI/CD pipeline history in the commit log. This was a solo sprint from idea to deployment-ready application.

Clone this wiki locally