Yoram-Jacobs/DressAppV1

JavaScript

0

1,538 commits

updated Oct 14, 2026

See the code

README

DressApp

Your AI fashion editor: photograph any garment, get weather + calendar-aware outfits, scan EU DPP QR tags, and resell from a polished marketplace β€” all in your pocket.

Live demo


What it does

DressApp turns a closet of physical clothes into a structured, quarriable wardrobe and uses that wardrobe to drive everyday styling decisions.

Core flows

FlowWhat it does
CaptureSnap or upload photos. The vision pipeline crops each garment, removes the background, and auto-fills 20+ attributes (category, fabric, fit, season, dress-code, colours, condition, repair advice…).
Auto-fill & Re-analyseFalls back to local SegFormer + rembg + Gemini. The Re-analyse Photo card features an interactive AI prompt box allowing users to ask The Eyes for specific modifications ("Remove the shoes", "Complete the hole where the hand was", "Remove metal studs") executing photorealistic inpainting via Nano Banana (gemini-3.1-flash-lite-image).
DPP QR scanScans EU Digital Product Passport QR codes (JSON-LD or inline JSON), imports brand, fibre composition, supply-chain trace and care info β€” even without a photo.
AI Stylist & AudioConversational chat (text or voice) that pulls weather, your calendar, your closet, and your cultural context to suggest complete outfits. Speaks 13 languages. Integrated STT/TTS routes between Gemma4 and Gemini 2.5 Flash, with native Web Speech transcription fallback and mobile offline VITS models (Piper/Sherpa-ONNX).
MarketplaceSell, swap or donate pieces. Region-matched feed, Live PayPal checkout, transparent platform fee (7% after processing).
Experts directoryFind vetted stylists, tailors and designers. Self-serve promotion campaigns (Draft/Pending/Active/Paused/Rejected lifecycles) with daily billing options ($1.00 USD/day PayPal checkout), customizable notification timing, and detailed performance reports drive a region-aware ticker on the home screen. Includes a dedicated My Campaigns dashboard for active expert tracking.
Trend ScoutDaily and monthly background scheduler curating 7 distinct channels across Men's and Women's fashion ecosystems β€” Local News, Runway, Street Style, Sustainability, Influencers & Icons, Vintage / Archival, and Care & Repairs. Employs web scraping (httpx + BeautifulSoup), Gemini JSON synthesis, strict anti-commerce/anti-paywall heuristic shields, dynamic translation across 13 locales, 1-tap "Style with My Closet" outfit handoff, and personalized demographic ranking.
Shopping AssistantChrome extension that reads size charts on partner stores (Zara, Asos, etc.) and recommends sizes based on your stored measurements.
SuitcaseIntelligent travel packing assistant that generates daily outfits and a packing list based on trip context, weather, and calendar events, with an interactive refinement chat.
Group TaggingBulk categorize multiple closet garments instantly to speed up wardrobe organization and improve AI Stylist reasoning.
Outfit Canvas & 2D AvatarAdaptive dual-canvas interactive avatar (real-body photo cutout with U2-Net matting vs dynamic SVG vector mannequin DynamicAvatar.jsx) with calibrated landmark positioning (top-[14.5%] collar-to-neckline and top-[36.5%] waistband-to-waistline), scikit-learn ANSUR II physical sizing predictor, proportional scaling, and interactive layer click details.
Wardrobe SchedulerAutomated daily push notifications with 3 styled outfit recommendations generated from your closet history, preventing wear repetition.
State & Network OptimizationuseSyncExternalStore thread-safe state architecture across Stylist, Daily Suggestions, Closet, and Marketplace, with in-flight deduplication, 15-min caching, and visibilitychange tab revalidation (0 idle background GET requests).
Monetization & LimitsGated closet space (50-item baseline limit for Free users) with a paid Pro upgrade path via PayPal Subscriptions REST API (mock-testing supported) or free expansion (+10 slots) via invite referral loops. Pre-paid credit bucket billing (10 free credits daily with 30-day expiry, and purchased credit packs that never expire) with soft/hard exhaustion thresholds and a pause-and-resume execution pattern.

Tech stack

Backend β€” FastAPI (Python 3.11) Β· Motor async MongoDB driver Β· Pydantic v2

Frontend β€” React 19 Β· useSyncExternalStore custom stores Β· React Router Β· Tailwind Β· Shadcn/UI Β· react-i18next (13 locales) Β· Sonner toasts Β· Lucide icons

Vision pipeline β€” full stack:

  • Hetzner / dev: rembg (U2-Net) for matting Β· HuggingFace SegFormer-b2-clothes for clothing parsing Β· Fashion-CLIP for embeddings β€” all CPU-local. See requirements-ml.txt and the auto-detection in app/config.py.
  • Inference Server: Optional self-hosted GPU endpoint (Modal/RunPod) wrapping SegFormer-b3 and BiRefNet for fast background matting and parsing.

Voice / Audio β€” Deepgram (STT/TTS fallback), Gemini 2.5 Flash native modulations (prebuilt voice configs puck/aoede/charon), Web Speech API browser integration, and local Piper ONNX support.

LLM / Inference Engine β€” Multi-tier production routing:

  • Primary Production Engine (Google Gemini 3.5 Flash-Lite): Powers all 6 interactive and core pipelines (Stylist Brain, Wardrobe Migration, Suitcase Planner, Trend Scout localization, Session Titles, and Closet Ingestion) via backend/app/services/llm_gateway.py with native google-genai SDK and sub-350ms TTFT.
  • On-Premises VPS Eyes (gemma-4-E4B) β€” Free Tier & Quota Safety Net: Self-hosted dressapp-eyes container running fine-tuned Gemma-4-E4B (gemma-4-E4B-it-Q3_K_M.gguf via llama-server on port 7860). Serves as the zero-cost baseline for offline/free usage and transparently intercepts quota exhaustion (429 / RESOURCE_EXHAUSTED) with zero downtime.
  • High-Cost Generative Features: Trend Scout and Nano Banana photorealistic inpainting strictly require validated user keys.

External APIs β€” OpenWeather Β· PayPal Live Β· Google OAuth + Google Calendar Β· HuggingFace Inference API

Hosting β€” Docker Compose Β· Caddy 2 (auto Let's Encrypt) Β· MongoDB Atlas

Extension β€” Manifest V3 Shopping Assistant (React popup + content scripts)


Architecture at a glance

                  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ HTTPS ────────────┐
                  β”‚                                β”‚
        β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”              β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”
        β”‚  Caddy (TLS)     β”‚              β”‚ Browser (PWA)    β”‚
        β”‚  /api/* β†’ backendβ”‚              β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
        β”‚  /*    β†’ frontendβ”‚
        β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”˜
             β”‚        β”‚
   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”    β”Œβ”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
   β”‚ FastAPI  β”‚    β”‚ Nginx (static SPA) β”‚
   β”‚  :8001   β”‚    β”‚  React build       β”‚
   β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
        β”‚
        β”œβ”€ MongoDB Atlas (users, closet, listings, trends, …)
        β”œβ”€ Vision pipeline: local SegFormer + rembg + Fashion-CLIP
        β”œβ”€ Primary Engine: Google Gemini 3.5 Flash-Lite (native google-genai)
        β”œβ”€ On-prem Eyes (:7860): llama-server + Gemma-4-E4B (Free Tier & Quota Safety Net)
        β”œβ”€ Deepgram & Gemini Audio (STT/TTS over HTTPS)
        β”œβ”€ OpenWeather, PayPal Live, Google OAuth/Calendar
        └─ High-cost generative cloud endpoints (BYOK keys for Nano Banana & Trend Scout)

In-depth documentation

  • Technical Architecture: docs/ARCHITECTURE.md β€” Monorepo structure, FARM runtime, ML vision stack, and Hetzner VPS topology.
  • Database Schema: docs/MONGODB_SCHEMA.md β€” Complete 15-collection MongoDB Atlas schema, indexes, and credit bucket definitions.
  • Domain Context & ADRs: CONTEXT.md and docs/adr/ β€” Bounded contexts, architectural decision records, and deep module boundaries.
  • Modular Wiki: wiki/en/overview.md β€” 40 detailed feature guides localized into 13 languages.
  • Deployment Facts: CONCRETE_FACTS.md β€” Authoritative hardware, container layouts, and operational reference commands.

Repository layout

.
β”œβ”€β”€ apps/
β”‚   β”œβ”€β”€ web/                     # React 19 Web SPA (CRA + Craco, Tailwind, i18next)
β”‚   β”œβ”€β”€ mobile/                  # Expo 53 / React Native 0.79 Mobile App (iOS / Android)
β”‚   └── android-twa/             # Android Trusted Web Activity packaging wrapper
β”‚
β”œβ”€β”€ packages/
β”‚   β”œβ”€β”€ api-client/              # Shared isomorphic REST & streaming NDJSON client
β”‚   β”œβ”€β”€ i18n/                    # Canonical translation catalogs across 13 locales
β”‚   └── types/                   # Shared TypeScript definitions for domain models
β”‚
β”œβ”€β”€ backend/                     # FastAPI Python 3.11 Backend Service
β”‚   β”œβ”€β”€ server.py                # ASGI application root & CORS configuration
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ api/v1/              # Versioned API routes (auth, closet, stylist, marketplace, etc.)
β”‚   β”‚   β”œβ”€β”€ core/                # Configuration, JWT security, and dependency injection
β”‚   β”‚   β”œβ”€β”€ db/                  # Motor MongoDB client and index initialization
β”‚   β”‚   β”œβ”€β”€ models/              # Pydantic v2 schemas (schemas.py, credit.py)
β”‚   β”‚   └── services/            # Business logic, vision matting, stylist agent, and billing
β”‚   β”œβ”€β”€ scripts/                 # Seeding and maintenance utilities
β”‚   β”œβ”€β”€ requirements.txt         # Production backend dependencies
β”‚   └── requirements-ml.txt     # Local ML stack (torch, transformers, rembg)
β”‚
β”œβ”€β”€ chrome-extension/            # Manifest V3 Shopping Assistant Extension
β”œβ”€β”€ inference-server/            # Optional standalone GPU inference server (BiRefNet / Gemma-4)
β”œβ”€β”€ deploy/                      # Production Docker Compose, Caddyfile, and Dockerfiles
β”‚   β”œβ”€β”€ docker-compose.yml
β”‚   β”œβ”€β”€ Dockerfile.backend
β”‚   β”œβ”€β”€ Dockerfile.frontend
β”‚   β”œβ”€β”€ Caddyfile
β”‚   β”œβ”€β”€ nginx-frontend.conf
β”‚   └── DEPLOY.md                # Step-by-step VPS deployment guide
β”œβ”€β”€ docs/                        # Technical documentation, ADRs, and schema references
β”‚   β”œβ”€β”€ ARCHITECTURE.md          # Full system architecture
β”‚   β”œβ”€β”€ MONGODB_SCHEMA.md        # MongoDB Atlas collection schemas
β”‚   β”œβ”€β”€ adr/                     # Architectural Decision Records (0001 - 0004)
β”‚   └── agents/                  # AI agent guidelines and domain documentation
β”œβ”€β”€ .agents/                     # AI agent skills & workflows
β”‚   └── workFlows/               # Core workflows (deploy, labrrerian, translator, user-manual)
β”œβ”€β”€ quarantine/                  # Archived historical session notes and debug logs
└── wiki/                        # Localized two-layer user documentation (13 languages)

Getting started β€” local dev

Monorepo Setup

# Install workspace dependencies from the repo root:
yarn install

Backend

cd backend

# Create and activate a Python 3.11 virtual environment:
python -m venv .venv
# On Linux/macOS:
source .venv/bin/activate
# On Windows PowerShell:
.\.venv\Scripts\Activate.ps1

# Install dependencies:
pip install -r requirements.txt

# Run the FastAPI development server:
python server.py   # Or: uvicorn server:app --reload --port 8001

Required environment variables in backend/.env: MONGO_URL, DB_NAME, JWT_SECRET, GEMINI_API_KEY, GOOGLE_OAUTH_CLIENT_ID, GOOGLE_OAUTH_CLIENT_SECRET, DEEPGRAM_API_KEY, OPENWEATHER_API_KEY, PAYPAL_LIVE_CLIENT_ID, PAYPAL_LIVE_CLIENT_SECRET, PAYPAL_ENV.

Web Frontend

# Start the React 19 web application:
yarn --cwd apps/web start
# Access at http://localhost:3000 (REACT_APP_BACKEND_URL defaults to http://localhost:8001)

Mobile App (Expo)

# Start the Expo development server:
yarn --cwd apps/mobile start

Seed demo data (optional)

For a fresh database, populate listings, professionals, trend cards and a demo user:

cd backend
python -m scripts.seed_demo   # idempotent β€” re-running upserts

Production deployment

4-container Docker Compose stack on Hetzner Cloud CPX32 VPS (4 AMD vCPUs, 8 GB RAM, running on dressapp.co):

  • backend β€” FastAPI + local SegFormer + rembg + Fashion-CLIP (~1.5 GB RAM at idle)
  • eyes β€” Self-hosted inference server (llama-server + FastAPI proxy) running fine-tuned gemma-4-E4B-it-Q3_K_M.gguf on port 7860 (~2.85 GB RAM)
  • frontend β€” Nginx serving the built React 19 SPA
  • caddy β€” TLS termination, automatic Let's Encrypt, HTTPβ†’HTTPS redirect

deploy/Dockerfile.backend installs requirements.txt and requirements-ml.txt so torch / transformers / rembg are all present. app/config.py auto-detects them and turns USE_LOCAL_CLOTHING_PARSER and AUTO_MATTE_CROPS to true.

Step-by-step instructions: deploy/DEPLOY.md.

# After cloning on the VPS:
cd deploy
cp .env.example .env   # then edit
docker compose up -d --build

Routine update:

git pull origin main
docker compose up -d --build

Contributing

  1. Fork β†’ branch off main
  2. Run lint before pushing:
    • Python β€” ruff check backend/
    • TypeScript / Web β€” yarn --cwd apps/web lint
    • Mobile β€” yarn --cwd apps/mobile lint
  3. Open a PR. CI runs the full test suite.

License

Β© 2025–2026 DressApp. All rights reserved. The trademarks, product designs, and content displayed in the app are the property of their respective owners.

Yoram-Jacobs/DressAppV1

JavaScript

0

1,538 commits

updated Oct 14, 2026

See the code

README

DressApp

Your AI fashion editor: photograph any garment, get weather + calendar-aware outfits, scan EU DPP QR tags, and resell from a polished marketplace β€” all in your pocket.

Live demo


What it does

DressApp turns a closet of physical clothes into a structured, quarriable wardrobe and uses that wardrobe to drive everyday styling decisions.

Core flows

FlowWhat it does
CaptureSnap or upload photos. The vision pipeline crops each garment, removes the background, and auto-fills 20+ attributes (category, fabric, fit, season, dress-code, colours, condition, repair advice…).
Auto-fill & Re-analyseFalls back to local SegFormer + rembg + Gemini. The Re-analyse Photo card features an interactive AI prompt box allowing users to ask The Eyes for specific modifications ("Remove the shoes", "Complete the hole where the hand was", "Remove metal studs") executing photorealistic inpainting via Nano Banana (gemini-3.1-flash-lite-image).
DPP QR scanScans EU Digital Product Passport QR codes (JSON-LD or inline JSON), imports brand, fibre composition, supply-chain trace and care info β€” even without a photo.
AI Stylist & AudioConversational chat (text or voice) that pulls weather, your calendar, your closet, and your cultural context to suggest complete outfits. Speaks 13 languages. Integrated STT/TTS routes between Gemma4 and Gemini 2.5 Flash, with native Web Speech transcription fallback and mobile offline VITS models (Piper/Sherpa-ONNX).
MarketplaceSell, swap or donate pieces. Region-matched feed, Live PayPal checkout, transparent platform fee (7% after processing).
Experts directoryFind vetted stylists, tailors and designers. Self-serve promotion campaigns (Draft/Pending/Active/Paused/Rejected lifecycles) with daily billing options ($1.00 USD/day PayPal checkout), customizable notification timing, and detailed performance reports drive a region-aware ticker on the home screen. Includes a dedicated My Campaigns dashboard for active expert tracking.
Trend ScoutDaily and monthly background scheduler curating 7 distinct channels across Men's and Women's fashion ecosystems β€” Local News, Runway, Street Style, Sustainability, Influencers & Icons, Vintage / Archival, and Care & Repairs. Employs web scraping (httpx + BeautifulSoup), Gemini JSON synthesis, strict anti-commerce/anti-paywall heuristic shields, dynamic translation across 13 locales, 1-tap "Style with My Closet" outfit handoff, and personalized demographic ranking.
Shopping AssistantChrome extension that reads size charts on partner stores (Zara, Asos, etc.) and recommends sizes based on your stored measurements.
SuitcaseIntelligent travel packing assistant that generates daily outfits and a packing list based on trip context, weather, and calendar events, with an interactive refinement chat.
Group TaggingBulk categorize multiple closet garments instantly to speed up wardrobe organization and improve AI Stylist reasoning.
Outfit Canvas & 2D AvatarAdaptive dual-canvas interactive avatar (real-body photo cutout with U2-Net matting vs dynamic SVG vector mannequin DynamicAvatar.jsx) with calibrated landmark positioning (top-[14.5%] collar-to-neckline and top-[36.5%] waistband-to-waistline), scikit-learn ANSUR II physical sizing predictor, proportional scaling, and interactive layer click details.
Wardrobe SchedulerAutomated daily push notifications with 3 styled outfit recommendations generated from your closet history, preventing wear repetition.
State & Network OptimizationuseSyncExternalStore thread-safe state architecture across Stylist, Daily Suggestions, Closet, and Marketplace, with in-flight deduplication, 15-min caching, and visibilitychange tab revalidation (0 idle background GET requests).
Monetization & LimitsGated closet space (50-item baseline limit for Free users) with a paid Pro upgrade path via PayPal Subscriptions REST API (mock-testing supported) or free expansion (+10 slots) via invite referral loops. Pre-paid credit bucket billing (10 free credits daily with 30-day expiry, and purchased credit packs that never expire) with soft/hard exhaustion thresholds and a pause-and-resume execution pattern.

Tech stack

Backend β€” FastAPI (Python 3.11) Β· Motor async MongoDB driver Β· Pydantic v2

Frontend β€” React 19 Β· useSyncExternalStore custom stores Β· React Router Β· Tailwind Β· Shadcn/UI Β· react-i18next (13 locales) Β· Sonner toasts Β· Lucide icons

Vision pipeline β€” full stack:

  • Hetzner / dev: rembg (U2-Net) for matting Β· HuggingFace SegFormer-b2-clothes for clothing parsing Β· Fashion-CLIP for embeddings β€” all CPU-local. See requirements-ml.txt and the auto-detection in app/config.py.
  • Inference Server: Optional self-hosted GPU endpoint (Modal/RunPod) wrapping SegFormer-b3 and BiRefNet for fast background matting and parsing.

Voice / Audio β€” Deepgram (STT/TTS fallback), Gemini 2.5 Flash native modulations (prebuilt voice configs puck/aoede/charon), Web Speech API browser integration, and local Piper ONNX support.

LLM / Inference Engine β€” Multi-tier production routing:

  • Primary Production Engine (Google Gemini 3.5 Flash-Lite): Powers all 6 interactive and core pipelines (Stylist Brain, Wardrobe Migration, Suitcase Planner, Trend Scout localization, Session Titles, and Closet Ingestion) via backend/app/services/llm_gateway.py with native google-genai SDK and sub-350ms TTFT.
  • On-Premises VPS Eyes (gemma-4-E4B) β€” Free Tier & Quota Safety Net: Self-hosted dressapp-eyes container running fine-tuned Gemma-4-E4B (gemma-4-E4B-it-Q3_K_M.gguf via llama-server on port 7860). Serves as the zero-cost baseline for offline/free usage and transparently intercepts quota exhaustion (429 / RESOURCE_EXHAUSTED) with zero downtime.
  • High-Cost Generative Features: Trend Scout and Nano Banana photorealistic inpainting strictly require validated user keys.

External APIs β€” OpenWeather Β· PayPal Live Β· Google OAuth + Google Calendar Β· HuggingFace Inference API

Hosting β€” Docker Compose Β· Caddy 2 (auto Let's Encrypt) Β· MongoDB Atlas

Extension β€” Manifest V3 Shopping Assistant (React popup + content scripts)


Architecture at a glance

                  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ HTTPS ────────────┐
                  β”‚                                β”‚
        β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”              β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”
        β”‚  Caddy (TLS)     β”‚              β”‚ Browser (PWA)    β”‚
        β”‚  /api/* β†’ backendβ”‚              β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
        β”‚  /*    β†’ frontendβ”‚
        β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”˜
             β”‚        β”‚
   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”    β”Œβ”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
   β”‚ FastAPI  β”‚    β”‚ Nginx (static SPA) β”‚
   β”‚  :8001   β”‚    β”‚  React build       β”‚
   β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
        β”‚
        β”œβ”€ MongoDB Atlas (users, closet, listings, trends, …)
        β”œβ”€ Vision pipeline: local SegFormer + rembg + Fashion-CLIP
        β”œβ”€ Primary Engine: Google Gemini 3.5 Flash-Lite (native google-genai)
        β”œβ”€ On-prem Eyes (:7860): llama-server + Gemma-4-E4B (Free Tier & Quota Safety Net)
        β”œβ”€ Deepgram & Gemini Audio (STT/TTS over HTTPS)
        β”œβ”€ OpenWeather, PayPal Live, Google OAuth/Calendar
        └─ High-cost generative cloud endpoints (BYOK keys for Nano Banana & Trend Scout)

In-depth documentation

  • Technical Architecture: docs/ARCHITECTURE.md β€” Monorepo structure, FARM runtime, ML vision stack, and Hetzner VPS topology.
  • Database Schema: docs/MONGODB_SCHEMA.md β€” Complete 15-collection MongoDB Atlas schema, indexes, and credit bucket definitions.
  • Domain Context & ADRs: CONTEXT.md and docs/adr/ β€” Bounded contexts, architectural decision records, and deep module boundaries.
  • Modular Wiki: wiki/en/overview.md β€” 40 detailed feature guides localized into 13 languages.
  • Deployment Facts: CONCRETE_FACTS.md β€” Authoritative hardware, container layouts, and operational reference commands.

Repository layout

.
β”œβ”€β”€ apps/
β”‚   β”œβ”€β”€ web/                     # React 19 Web SPA (CRA + Craco, Tailwind, i18next)
β”‚   β”œβ”€β”€ mobile/                  # Expo 53 / React Native 0.79 Mobile App (iOS / Android)
β”‚   └── android-twa/             # Android Trusted Web Activity packaging wrapper
β”‚
β”œβ”€β”€ packages/
β”‚   β”œβ”€β”€ api-client/              # Shared isomorphic REST & streaming NDJSON client
β”‚   β”œβ”€β”€ i18n/                    # Canonical translation catalogs across 13 locales
β”‚   └── types/                   # Shared TypeScript definitions for domain models
β”‚
β”œβ”€β”€ backend/                     # FastAPI Python 3.11 Backend Service
β”‚   β”œβ”€β”€ server.py                # ASGI application root & CORS configuration
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ api/v1/              # Versioned API routes (auth, closet, stylist, marketplace, etc.)
β”‚   β”‚   β”œβ”€β”€ core/                # Configuration, JWT security, and dependency injection
β”‚   β”‚   β”œβ”€β”€ db/                  # Motor MongoDB client and index initialization
β”‚   β”‚   β”œβ”€β”€ models/              # Pydantic v2 schemas (schemas.py, credit.py)
β”‚   β”‚   └── services/            # Business logic, vision matting, stylist agent, and billing
β”‚   β”œβ”€β”€ scripts/                 # Seeding and maintenance utilities
β”‚   β”œβ”€β”€ requirements.txt         # Production backend dependencies
β”‚   └── requirements-ml.txt     # Local ML stack (torch, transformers, rembg)
β”‚
β”œβ”€β”€ chrome-extension/            # Manifest V3 Shopping Assistant Extension
β”œβ”€β”€ inference-server/            # Optional standalone GPU inference server (BiRefNet / Gemma-4)
β”œβ”€β”€ deploy/                      # Production Docker Compose, Caddyfile, and Dockerfiles
β”‚   β”œβ”€β”€ docker-compose.yml
β”‚   β”œβ”€β”€ Dockerfile.backend
β”‚   β”œβ”€β”€ Dockerfile.frontend
β”‚   β”œβ”€β”€ Caddyfile
β”‚   β”œβ”€β”€ nginx-frontend.conf
β”‚   └── DEPLOY.md                # Step-by-step VPS deployment guide
β”œβ”€β”€ docs/                        # Technical documentation, ADRs, and schema references
β”‚   β”œβ”€β”€ ARCHITECTURE.md          # Full system architecture
β”‚   β”œβ”€β”€ MONGODB_SCHEMA.md        # MongoDB Atlas collection schemas
β”‚   β”œβ”€β”€ adr/                     # Architectural Decision Records (0001 - 0004)
β”‚   └── agents/                  # AI agent guidelines and domain documentation
β”œβ”€β”€ .agents/                     # AI agent skills & workflows
β”‚   └── workFlows/               # Core workflows (deploy, labrrerian, translator, user-manual)
β”œβ”€β”€ quarantine/                  # Archived historical session notes and debug logs
└── wiki/                        # Localized two-layer user documentation (13 languages)

Getting started β€” local dev

Monorepo Setup

# Install workspace dependencies from the repo root:
yarn install

Backend

cd backend

# Create and activate a Python 3.11 virtual environment:
python -m venv .venv
# On Linux/macOS:
source .venv/bin/activate
# On Windows PowerShell:
.\.venv\Scripts\Activate.ps1

# Install dependencies:
pip install -r requirements.txt

# Run the FastAPI development server:
python server.py   # Or: uvicorn server:app --reload --port 8001

Required environment variables in backend/.env: MONGO_URL, DB_NAME, JWT_SECRET, GEMINI_API_KEY, GOOGLE_OAUTH_CLIENT_ID, GOOGLE_OAUTH_CLIENT_SECRET, DEEPGRAM_API_KEY, OPENWEATHER_API_KEY, PAYPAL_LIVE_CLIENT_ID, PAYPAL_LIVE_CLIENT_SECRET, PAYPAL_ENV.

Web Frontend

# Start the React 19 web application:
yarn --cwd apps/web start
# Access at http://localhost:3000 (REACT_APP_BACKEND_URL defaults to http://localhost:8001)

Mobile App (Expo)

# Start the Expo development server:
yarn --cwd apps/mobile start

Seed demo data (optional)

For a fresh database, populate listings, professionals, trend cards and a demo user:

cd backend
python -m scripts.seed_demo   # idempotent β€” re-running upserts

Production deployment

4-container Docker Compose stack on Hetzner Cloud CPX32 VPS (4 AMD vCPUs, 8 GB RAM, running on dressapp.co):

  • backend β€” FastAPI + local SegFormer + rembg + Fashion-CLIP (~1.5 GB RAM at idle)
  • eyes β€” Self-hosted inference server (llama-server + FastAPI proxy) running fine-tuned gemma-4-E4B-it-Q3_K_M.gguf on port 7860 (~2.85 GB RAM)
  • frontend β€” Nginx serving the built React 19 SPA
  • caddy β€” TLS termination, automatic Let's Encrypt, HTTPβ†’HTTPS redirect

deploy/Dockerfile.backend installs requirements.txt and requirements-ml.txt so torch / transformers / rembg are all present. app/config.py auto-detects them and turns USE_LOCAL_CLOTHING_PARSER and AUTO_MATTE_CROPS to true.

Step-by-step instructions: deploy/DEPLOY.md.

# After cloning on the VPS:
cd deploy
cp .env.example .env   # then edit
docker compose up -d --build

Routine update:

git pull origin main
docker compose up -d --build

Contributing

  1. Fork β†’ branch off main
  2. Run lint before pushing:
    • Python β€” ruff check backend/
    • TypeScript / Web β€” yarn --cwd apps/web lint
    • Mobile β€” yarn --cwd apps/mobile lint
  3. Open a PR. CI runs the full test suite.

License

Β© 2025–2026 DressApp. All rights reserved. The trademarks, product designs, and content displayed in the app are the property of their respective owners.