# 🚀 Quick Deploy to Hugging Face Spaces ## Prerequisites - Python 3.8+ - Git installed - Hugging Face account ## Step 1: Setup ```bash # Install requirements pip install -r requirements.txt # Run setup script python setup_hf_space.py ``` ## Step 2: Deploy ```bash # Option A: Automated deployment python deploy_final.py # Option B: Manual deployment huggingface-cli login huggingface-cli repo create textilindo-ai-assistant --type space --sdk gradio ``` ## Step 3: Manual Upload (if automated fails) 1. Go to https://huggingface.co/spaces/[your-username]/textilindo-ai-assistant 2. Upload these files: - `app.py` - `requirements.txt` - `README.md` - `configs/system_prompt.md` - `data/textilindo_training_data.jsonl` ## Step 4: Test - Wait for build to complete (2-5 minutes) - Test your application - Share the link! ## Files Structure ``` textilindo-ai-assistant/ ├── app.py # Main Gradio application ├── requirements.txt # Dependencies ├── README.md # Space configuration ├── configs/ │ └── system_prompt.md # System prompt └── data/ └── textilindo_training_data.jsonl ``` ## Troubleshooting - **Build fails**: Check requirements.txt versions - **App doesn't start**: Check app.py for errors - **Data not loading**: Verify data files are uploaded - **Memory issues**: Use smaller dataset or optimize code ## Support Check the DEPLOYMENT_GUIDE.md for detailed instructions.