gala / app.py
Leolx's picture
Create app.py
15ea71e verified
raw
history blame contribute delete
423 Bytes
from fastapi import FastAPI
import requests
app = FastAPI()
# ---------- SIMPLE AGENT ----------
def solve(question: str):
# TEMPORARY: basic logic first
return question # we improve this later
# ---------- API ----------
@app.get("/")
def home():
return {"status": "agent running"}
@app.get("/predict")
def predict(question: str):
answer = solve(question)
return {
"answer": answer
}