Prompt

0 copies · 0 said it worked

Tugrul Erdem@ted2xmen·
Coding· Chat UI

Design a cold-start safe Expo and Supabase generation architecture

Asks the model to act as a senior Expo and Supabase architect and produce a minimal, production-friendly design with schema migrations, Edge Functions for gating and enqueue, an Expo client flow with optimistic UI, and a separate worker for AI generation.

People use this for

  • expo supabase architecture prompt
  • supabase edge functions job queue
  • expo react native optimistic ui
  • supabase schema migrations generation jobs
  • cold start safe app architecture
role assignmentstructured output specificationexplicit constraints
Imported · UnclaimedCC0

Imported on Nov 29, 2026 from Cold Start Safe Architecture . License observed at the source on Nov 29, 2026: CC0.

Are you the author?Claim this profileRequest removal

Prompt

Act as a Senior Expo + Supabase Architect.

Implement a “cold-start safe” architecture using:
- Expo (React Native) client
- Supabase Postgres + Storage + Realtime
- Supabase Edge Functions ONLY for lightweight gating + job enqueue
- A separate Worker service for heavy AI generation and storage writes

Deliver:
1) Database schema (SQL migrations) for: jobs, generations, entitlements (credits/is_paid), including indexes and RLS notes
2) Edge Functions:
   - ping (HEAD/GET)
   - enqueue_generation (validate auth, check is_paid/credits, create job, return jobId)
   - get_job_status (light read)
   Keep imports minimal; no heavy SDKs.
3) Expo client flow:
   - non-blocking warm ping on app start
   - Generate button uses optimistic UI + placeholder
   - subscribe to job updates via Realtime or implement polling fallback
   - final generation replaces placeholder in gallery list
4) Worker responsibilities (describe interface and minimal endpoints/logic, do not overbuild):
   - fetch queued jobs
   - run AI generation
   - upload to storage
   - update jobs + insert generations
   - retry policy and idempotency

Constraints:
- Do NOT block app launch on any Edge call
- Do NOT run AI calls inside Edge Functions
- Ensure failed jobs still create a generation record with original input visible
- Keep the solution production-friendly but minimal

Output must be structured as:
A) Architecture summary
B) Migrations (SQL)
C) Edge function file structure + key code blocks
D) Expo integration notes + key code blocks
E) Worker outline + pseudo-code

No result recorded for this import yet. Tried it? File a report so the next person knows how it went.

Tried it

Structured reports from people who ran this prompt. They roll up into the per-model badges above.

No one has filed a report yet. Try the prompt and be the first.

License: CC0v1 · published Nov 29, 2026

Comments

No comments yet. If you tried this prompt, say how it went.