Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -26,7 +26,6 @@ async def generate(prompt: str):
|
|
| 26 |
except requests.RequestException as e:
|
| 27 |
raise HTTPException(status_code=500, detail=f"Error communicating with Ollama: {str(e)}")
|
| 28 |
|
| 29 |
-
# Optional: Add more endpoints as needed
|
| 30 |
@app.post("/chat")
|
| 31 |
async def chat(prompt: str, context: str = ""):
|
| 32 |
try:
|
|
|
|
| 26 |
except requests.RequestException as e:
|
| 27 |
raise HTTPException(status_code=500, detail=f"Error communicating with Ollama: {str(e)}")
|
| 28 |
|
|
|
|
| 29 |
@app.post("/chat")
|
| 30 |
async def chat(prompt: str, context: str = ""):
|
| 31 |
try:
|