Spaces:
Running
Running
Upload folder using huggingface_hub
Browse files- backend/main.py +4 -0
backend/main.py
CHANGED
|
@@ -106,6 +106,10 @@ def parse_llm_response(response_text: str) -> dict:
|
|
| 106 |
|
| 107 |
# API Endpoints
|
| 108 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 109 |
@app.get("/", response_model=HealthResponse)
|
| 110 |
async def root():
|
| 111 |
"""Root endpoint - API health check"""
|
|
|
|
| 106 |
|
| 107 |
# API Endpoints
|
| 108 |
|
| 109 |
+
@app.get("/ping")
|
| 110 |
+
async def keep_alive():
|
| 111 |
+
return {"status": "healthy", "message": "Hugging Face Space is awake!"}
|
| 112 |
+
|
| 113 |
@app.get("/", response_model=HealthResponse)
|
| 114 |
async def root():
|
| 115 |
"""Root endpoint - API health check"""
|