# 🚀 Quick Deployment to Hugging Face Spaces ## Files for Deployment Upload these 4 files to your Hugging Face Space: ``` 📁 Your Hugging Face Space Repository ├── 📄 app.py # Main FastAPI application ├── 📄 Dockerfile # Container configuration ├── 📄 README.md # Space description (rename README_HF.md) ├── 📄 requirements.txt # Python dependencies └── 📄 test.py # Test script (optional) ``` ## Deployment Steps ### 1. Create Hugging Face Space - Go to [huggingface.co/spaces](https://huggingface.co/spaces) - Click "Create new Space" - Choose **SDK: Docker** - Set your space name ### 2. Upload Files - Upload: `app.py`, `Dockerfile`, `requirements.txt` - **Rename** `README_HF.md` to `README.md` and upload - Optionally upload `test.py` ### 3. Deploy - Hugging Face automatically builds and deploys - Your API will be available at: `https://your-space-name.hf.space` ## Testing 1. Update `test.py` with your Space URL 2. Set environment variable: `export OPENAI_API_KEY="your_key"` 3. Run: `python test.py` ## Your API Endpoints - **Base**: `https://your-space-name.hf.space` - **Health**: `GET /health` - **Address Detection**: `POST /address-detection` - **Summarization**: `POST /summarize` - **Docs**: `GET /docs` That's it! 🎉