This is a Flask-based API that helps users find nearby food banks based on their location and needs.
- Method: POST
- Description: Processes user input to find relevant food banks
- Request Body:
{ "input": "I need help finding food banks near 123 Main St, New York" } - Response:
{ "feature_extractor_llm_output": { /* Extracted features */ }, "coder_llm_output": "SQL query", "nearest_locations": [ /* List of nearby locations */ ], "summary_llm_output": "Summary text" }
- Method: GET
- Description: Confirms the API is running properly
- Response:
{ "status": "healthy" }
- Method: GET
- Description: Provides basic API information
- Response:
{ "message": "Food Bank LLM API", "endpoints": { "/api/process": "POST - Process text input to find nearby food banks", "/api/health": "GET - Health check" } }
-
Install dependencies:
pip install -r requirements.txt -
Run the Flask app:
python main.py -
The API will be available at
http://localhost:5000
-
Build the Docker image:
docker build -t food-bank-llm . -
Run the container:
docker run -p 5000:5000 food-bank-llm -
The API will be available at
http://localhost:5000