This backend provides:
- /tryon endpoint (garment + selfie → IDM-VTON try-on generation)
- /reverse-search endpoint (temporary garment hosting → Google Lens search)
- Serves static files under /public/reverse/
- Falls back to a mock result when HF quota is exhausted
Built for the TryMe Chrome Extension.
See the TryMe repo: 🔗 TryMe
IDM-VTON runs on Hugging Face ZeroGPU free tier.
Key caveats:
- Daily GPU minutes are limited
- API calls may still behave as anonymous
- When quota is exceeded:
- Hugging Face returns 500 errors
- Backend automatically returns a mock preview
- Daily quota resets every 24 hours
- Recommended to fork IDM-VTON for your own quota pool
The /reverse-search endpoint:
- Accepts garmentDataUrl
- Converts it to a JPEG file
- Stores it in public/reverse/
- Returns a Google Lens upload-by-URL search link
Caveat:
- Lens URLs are undocumented
- Implementation works as of version 1.0 (2025-11)
- May break if Google changes Lens behavior
Input: garment image + selfie image
Output: generated try-on image or mock fallback
Input: garment image
Output: public URL + Google Lens search URL
All virtual try-on results are generated using the excellent open-source model licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 License:
🔗 https://huggingface.co/spaces/yisol/IDM-VTON
🔗 https://github.com/yisol/IDM-VTON
This extension does not modify or distribute model weights.
All inference calls go directly through the publicly available Hugging Face Space API using the @gradio/client library.
If you use or extend this project, please credit yisol et al. for their work.