Download README.md from shfatime/Relevia: direct link, hf CLI and curl.
- Browser
- Download file 2.24 kB
-
https://huggingface.co/spaces/shfatime/Relevia/resolve/main/README.md
- Command line
-
hf download hf://spaces/shfatime/Relevia/README.md
-
curl -L -o README.md https://huggingface.co/spaces/shfatime/Relevia/resolve/main/README.md
title: Relevia
emoji: 🔎
colorFrom: blue
colorTo: purple
sdk: gradio
sdk_version: 6.32.0
python_version: 3.12.12
app_file: app.py
Relevia Gradio Space
This Space serves the existing React storefront, FastAPI routes, catalog, reviews, recommendations, and BM25/E5/CLIP search. Search uses CPU inference. The registered gpu_check Gradio API is retained for ZeroGPU detection and runs a tiny CUDA operation only when explicitly called; it is not used by search.
From the Relevia repository root, build the actual frontend and stage the existing artifacts:
cd frontend
npm run build
cd ..
python frontend/gradio_poc/prepare.py
The ignored .cache/relevia-space/ directory is the complete upload root. Upload its app.py, README.md, requirements.txt, backend/, dist/, data/, .cache/text_search/, and .cache/image_search/, preserving paths and including hidden directories. Use the staged dist/, not the original proof-of-concept frontend/gradio_poc/dist/. The bundle contains 1,120 images, four Parquet files, and both existing FAISS indexes and embedding caches. Do not upload other local caches, the virtual environment, or secrets. A public Space repository exposes its files; choose visibility and artifact storage accordingly.
The source-pinned E5 and CLIP models are downloaded from Hugging Face on the first startup if absent and cached in .cache/huggingface/. Space storage is ephemeral, so a restart or rebuild may require another download. The sentiment model is not needed at runtime: predictions are already in the Parquet files. Missing or mismatched indexes fail startup instead of being rebuilt. Spaces supplies PyTorch and the spaces package; do not replace them with CPU-only PyTorch, as the retained ZeroGPU check requires CUDA.
Select ZeroGPU in Space settings; free hosting requires an eligible personal account. After initialization, check /api/health, the storefront, text and image searches, product details, recommendations, and review sentiment. To reuse a local model cache when testing a staged bundle, set RELEVIA_MODEL_CACHE_ROOT to the local repository's .cache directory; do not set it on the Space. No models or embeddings are regenerated by staging.