Enhance Docker configuration by adding HUGGING_FACE_HUB_TOKEN as a build argument in docker-compose.yml and Dockerfile. Update Dockerfile to install CPU-only PyTorch and adjust thread counts for reduced memory usage during builds. Modify docker_build_assets.py to support both HF_TOKEN and HUGGING_FACE_HUB_TOKEN for model caching. Update README.md to clarify token usage and build instructions.
be705e8 | # Copy to .env and fill in values. Never commit .env. | |
| # | |
| # Azure endpoint is the resource base URL only (no /deployments/... path), e.g. | |
| # https://YOUR_RESOURCE.openai.azure.com/ | |
| # https://YOUR_RESOURCE.cognitiveservices.azure.com/ | |
| AZURE_OPENAI_ENDPOINT=https://YOUR_RESOURCE.openai.azure.com/ | |
| AZURE_OPENAI_API_KEY= | |
| AZURE_OPENAI_API_VERSION=2024-06-01 | |
| # Task A — fine-tuned chat deployment name (exact string from Azure / Foundry) | |
| AZURE_OPENAI_DEPLOYMENT_TASK_A=yelp-reviewer-v1 | |
| TASK_A_MAX_TOKENS=1024 | |
| TASK_A_TEMPERATURE=0.35 | |
| # Optional: Azure embeddings for catalog build / Task B retrieval. | |
| # Leave blank to use local sentence-transformers (TASK_B_EMBEDDING_BACKEND=auto picks local). | |
| AZURE_OPENAI_DEPLOYMENT_EMBEDDINGS= | |
| # Task B Azure reranking only: chat deployment name. If blank, Task A deployment is used. | |
| AZURE_OPENAI_DEPLOYMENT_CHAT= | |
| # Task B retrieval: azure | local | auto (auto = azure if AZURE_OPENAI_DEPLOYMENT_EMBEDDINGS set) | |
| TASK_B_EMBEDDING_BACKEND=auto | |
| TASK_B_LOCAL_EMBEDDING_MODEL=all-MiniLM-L6-v2 | |
| # Task B reranking: azure | local (local uses Hugging Face model below; no Azure chat quota needed) | |
| TASK_B_RANK_BACKEND=local | |
| TASK_B_LOCAL_LLM_MODEL=Qwen/Qwen2.5-1.5B-Instruct | |
| TASK_B_EMBEDDED_CATALOG=data/business_catalog_embedded.jsonl | |
| # Hugging Face Hub token — optional for public models; use either name (Docker build sees HF_TOKEN if passed as build-arg). | |
| # HF_TOKEN= | |
| # HUGGING_FACE_HUB_TOKEN= | |
| # Optional: bind-mount Yelp business JSON inside image build context at this path to bake a real catalog. | |
| # YELP_BUSINESS_JSON=/code/yelp_dataset/extracted/yelp_academic_dataset_business.json | |
| # Docker catalog size cap when Yelp present: | |
| # DOCKER_CATALOG_MAX_ROWS=15000 | |
| # Container listens on 7860 (Hugging Face Spaces default); override locally if needed. | |
| # PORT=7860 | |
| HF_TOKEN=hf.... |