Generated output — this is a static snapshot rendered from .vibekb/. The .vibekb/ content is the source of truth. See Reference for provenance.

AI handoff

Start here before you change anything

Everything the next human or AI session needs to avoid reconstructing the project incorrectly.

Verification: mixed Updated 2026-07-21

What Arcana currently is

AI Saga Arcana / You Are The Song Now generates cinematic song-based images via Gemini, asynchronously through arcana_queue, billed by users.image_credits, stored in arcana_renders + Backblaze B2, shown in a personal gallery. Auth is invite-code registration + email verification. Plans gate features via users.plan_type. Stripe sells packs/subscriptions through tables that are not created by in-repo schema helpers.

Source analyzed

  • Repository: https://github.com/cubixmeow-commits/youarethesongnow
  • Branch: main
  • Commit: 3d7f6a08304ce5a48c6628f04eacb1094fbd5c0d
  • VibeKB tooling source commit: dbd9c08566e57d4b57ce2cc2bb4b0cf66d1afaeb

Where to begin reading

  1. README.md
  2. .vibekb/project/identity.md and system/mental-model.md
  3. Diagrams view (app overview + generation pipeline)
  4. auth_lib.php + auth_check.php
  5. arcana.image.generator.php
  6. arcana.queue.processor.cron.parallel.v3.dynamicstyle.php
  7. arcana.image.gallery.php
  8. arcana.plan_tiers.php
  9. stripe_lib.php + arcana.stripe.endpoint.php + webhook.php
  10. includes/b2_helpers.php

Critical execution paths

  • Register → verify → login
  • Generate → queue → worker → render → credit consume → gallery
  • Pricing → Checkout → webhook/success → credits/subscription

Active warnings (read these)

See memory warnings for: missing arcana_queue / notifications / Stripe / access-codes schemas; dual Stripe webhook paths; possible double credit grant; duplicate login pages; debug files exposed; plan model inconsistency; status not enforced at login; email change without re-verify.

Known uncertainties

  • Which cron worker script is actually scheduled on Hostinger
  • Which Stripe webhook URL is registered in the Stripe dashboard
  • Whether production DB migrations match what auth_lib vs stripe_lib expect for credit_transactions
  • Which landing variant (index.php vs index.four.tiers.php / index.gemini.php) is mapped in production

How to update VibeKB after code changes

  1. Trace the changed behaviour in source (do not invent)
  2. Update affected functionality/records/*.md, files, diagrams/topology if the picture changed
  3. Add memory warnings/discoveries/changes only when meaningful
  4. Update manifest.json provenance (source_commit, last_verified)
  5. Run:

``bash php tools/validate.php php tools/test-topology.php php tools/generate-static.php ``

  1. Commit .vibekb/, generated /docs, and any guide/tools changes — never hand-edit generated HTML

Next recommended action

Confirm on the production host: (1) which queue processor cron runs, (2) which Stripe webhook endpoint is registered, (3) that arcana_queue, Stripe tables, user_notifications, and access_codes exist with the columns the code assumes. Promote those three items from inferred/not-verified once confirmed.

Backup of prior model

Pre-rebootstrap .vibekb/ and /docs were copied to VibeKBbackup/ at the repository root and must not be modified.

Recent work sessions

  • Arcana VibeKB initialization (static HTML)

    Verified from source 2026-07-21

  • VibeKB rebootstrap onto current main tooling

    Inferred from source 2026-07-21