from fastapi import FastAPI from app.rag import generate_response from app.classification import classify_text app = FastAPI() @post("/rag") async def rag_endpoint(prompt: str): response = generate_response(prompt) return {"response": response} @post("/classification") async def classification_endpoint(text: str): category = classify_text(text) return {"category": category}