Bijoy09 commited on
Commit
d2281db
1 Parent(s): 473261b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -31,7 +31,7 @@ class BatchTextRequest(BaseModel):
31
  texts: list[str]
32
 
33
 
34
- @app.post("/predict")
35
  async def predict(request: TextRequest):
36
  try:
37
  model.eval()
@@ -53,7 +53,7 @@ async def predict(request: TextRequest):
53
  raise HTTPException(status_code=500, detail=f"Prediction failed: {e}")
54
 
55
 
56
- @app.post("/batch_predict")
57
  async def batch_predict(request: BatchTextRequest):
58
  try:
59
  model.eval()
 
31
  texts: list[str]
32
 
33
 
34
+ @app.post("/predict/")
35
  async def predict(request: TextRequest):
36
  try:
37
  model.eval()
 
53
  raise HTTPException(status_code=500, detail=f"Prediction failed: {e}")
54
 
55
 
56
+ @app.post("/batch_predict/")
57
  async def batch_predict(request: BatchTextRequest):
58
  try:
59
  model.eval()