Spaces:
Runtime error
Runtime error
File size: 262 Bytes
cdc5783 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
from fastapi import FastAPI
from summary import summarize
app = FastAPI()
@app.get("/")
async def root():
return {"message": "Hello World"}
@app.post("/summary/")
async def summary(text_request):
text = text_request.text
return summarize(text)
|