How stidhagn/thrift-walk works
Thrift Walk is a community marketplace with user accounts, virtual stores, and a Godot game, plus a photo-to-3D scanning workflow for listing items. Users sign up and gain access through approval; they can browse stores, manage inventory, and attach completed scans to listings. Scans are stored and queued by the web app, reconstructed and previewed by a worker, then made available to the web and game. Edges reflect the shown source references and README; several web route implementations and UI components were not sampled, so their internal call paths are omitted.
Main entry points: service.ts Market service · route.ts Scan API · run_worker.py Worker queue loop · auth.ts Authentication
Components 24
Accounts
- Sign up
web/src/app/(auth)/sign-up/sign-up-form.tsx - Sign in
web/src/app/(auth)/sign-in/sign-in-form.tsx - Authentication
web/src/lib/auth.ts - Account approval
web/src/app/(auth)/approval/page.tsx - Profile
web/src/app/(site)/profile/page.tsx
Market and game
- Storefront UI
web/src/components/store-browser.tsx - Owner inventory
web/src/components/owner-inventory.tsx - Market API
web/src/app/api/market/[...path]/route.ts - Market service
web/src/lib/market/service.ts - Market procedures
web/src/lib/market/procedures.ts - Market validation
web/src/lib/market/validation.ts - Domain data
web/zenstack/schema.ts
Scan web workflow
- Scan upload and list
web/src/components/scan-dropzone.tsx - Scan API
web/src/app/api/scan/route.ts - Scan file endpoints
web/src/app/api/scan-transfer/[id]/[file]/route.ts - Scan storage
web/src/lib/scan-storage.ts - Job queue
web/src/lib/redis.ts
Scan reconstruction
- Worker queue loop
worker/run_worker.py - 3D reconstruction
worker/pipeline.py - Texture baking
worker/texture.py - Preview rendering
worker/preview.py - Runpod dispatcher
worker/runpod_dispatcher.py
Other components
- User
- Runpod GPU
Connections 25
- User → Sign up: creates account
README.md - Sign up → Authentication: uses auth
web/src/lib/auth.ts - User → Sign in: signs in
README.md - Sign in → Authentication: uses auth
web/src/lib/auth.ts - Authentication → Domain data: reads and writes
web/src/lib/auth.ts - User → Account approval: submits code
README.md - User → Storefront UI: browses stores
README.md - User → Owner inventory: manages items
README.md - Market API → Market service: delegates to
- Market service → Market procedures: dispatches operations
web/src/lib/market/service.ts - Market service → Market validation: validates input
web/src/lib/market/service.ts - Market service → Domain data: queries data
web/src/lib/market/service.ts - User → Scan upload and list: uploads photos
README.md - Scan API → Scan storage: stores photos
- Scan API → Job queue: queues job
- Scan API → Domain data: creates scan job
- Scan file endpoints → Scan storage: transfers files
- Job queue → Worker queue loop: delivers job
worker/run_worker.py - Worker queue loop → 3D reconstruction: runs reconstruction
worker/run_worker.py - 3D reconstruction → Texture baking: bakes texture
worker/pipeline.py - Worker queue loop → Preview rendering: generates preview
worker/run_worker.py - Runpod dispatcher → Runpod GPU: dispatches scans
- Runpod GPU → Scan file endpoints: transfers scan files
- Runpod GPU → 3D reconstruction: runs reconstruction
- Runpod GPU → Preview rendering: renders preview