For Agents
Living index of themes for this project. Each H2 is a topic; bullets are wikilinks to related notes. Updated by
obsidian-documenterwhen documenting work. Read byhistorianat bootstrap. Topics kept alphabetical.
Architecture & Design
- txArchive 2025 Rewrite — the unified full-stack rewrite: target system topology, component responsibilities, key decisions, status.
- txArchive Frontend Architecture — the new Vite/React 18/TanStack SPA: stack, routing, data layer, realtime integration, theming, rebuilt features.
Backend Contract (Supabase)
- txArchive Supabase Contract — §6 of the unified design: old Rust REST → new Supabase (PostgREST tables/views + RPCs + Realtime channels + 3 Edge Functions + cdn.txarchive.org/{file_key}); data shapes; backend deltas over the approved design; the OCR pipeline. Supersedes the obsolete frontend spec §8.
- txArchive 2025 Rewrite — points to the contract; lists the backend design doc as authoritative for backend internals.
Backend Services (Fastify/Prisma impl)
- Decision - Discord Integration via discord.js —
DiscordService, the IoC service pattern (binder.ts/bindServices), lazyensureReady()login, env + intents. - Fix - IoC Container Keyed on prototype.name — IoC bug:
src/core/ioc.tskeyed ont.prototype.name(undefined) → all services collided; fix keys ont.name. Gotcha: services keyed byClass.name, so minification mangling breaks DI. Context:UsersService.provision()+GET /users.
Debugging & Gotchas
- Fix - IoC Container Keyed on prototype.name — DI container keyed on
t.prototype.name(always undefined); fixed tot.name. Gotcha:Class.namekeys are fragile under minification; use named class expressions.
Decisions
- Decision - Discord Integration via discord.js — use discord.js v14 (not raw REST) for gateway-readiness; lazy gateway login via
ensureReady();GatewayIntentBits.Guilds-only. - txArchive 2025 Rewrite — the ~20 resolved open questions (unified plan, frontend stack, OCR engine = Google Cloud Vision, Supabase Auth UUIDs, frontend-talks-Supabase-directly, guild gate in complete-login, real /members admin page, optimistic likes + Realtime, Yorick page kept (JSON catalog), light/dark/system theme, /post/:id deep-links, split repos, CF Pages + Railway hosting, full-text search added).
Frontend (the SPA)
- txArchive Frontend Architecture — stack, directory structure, routing, app shell, data layer, realtime, theming, PWA, the rebuilt feature set (§8.1–§8.14), the parity checklist coverage.
Migration & Cutover
- txArchive 2025 Rewrite — the one-time Postgres→Postgres ETL (R2 untouched), staging-first / idempotent / maintenance window / rollback discipline; the cutover runbook ending in a DNS flip and retiring the Rust.
OCR & Search
- txArchive Supabase Contract — the OCR pipeline (Google Cloud Vision TEXT_DETECTION, pluggable behind runOcr(), pg_cron-drained ocr_jobs, ocr.search tsvector) and the search_archive RPC backing the new /search page.