Spaces:
No application file
No application file
| from fastapi import FastAPI | |
| from pydantic import BaseModel | |
| app = FastAPI() | |
| class Question(BaseModel): | |
| question_text: str | |
| def home(): | |
| return {"message": "🚀 Feedback Chatbot API is live!"} | |
| def generate_response(data: Question): | |
| answer = f"Llama Response: {data.question_text}" | |
| recommendation = "Recommendation: Reflect and take one positive step today." | |
| return { | |
| "answer": answer, | |
| "recommendation": recommendation | |
| } | |