Kashish commited on
Commit ·
1923da9
1
Parent(s): 6f1e05b
startup re-evaluation
Browse files123456730 unmodified lines383940414243444546from __future__ import annotationsfrom fastapi import FastAPI, HTTPExceptionfrom fastapi.responses import RedirectResponsefrom pydantic import BaseModel, Fieldimport logging30 unmodified lines@app.get("/", include_in_schema=False)async def root() -> RedirectResponse:"""Redirect root to the Swagger UI so Spaces shows the API docs at '/'."""return RedirectResponse(url="/docs")@app.post("/chat", response_model=ChatResponse)12345630 unmodified lines3738394041424344from __future__ import annotationsfrom fastapi import FastAPI, HTTPExceptionfrom pydantic import BaseModel, Fieldimport logging30 unmodified lines@app.get("/", include_in_schema=False)async def root() -> dict[str, str]:return {"status": "ready", "message": "FAQ RAG Chatbot is running"}@app.post("/chat", response_model=ChatResponse)
app.py+2-4