thedeba commited on
Commit
1ff1004
·
verified ·
1 Parent(s): b599ed5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -44,11 +44,11 @@ def generate(query: Query):
44
  # Decode & extract assistant response
45
  output_string = tokenizer.batch_decode(outputs, skip_special_tokens=True)[0]
46
  response = output_string.split("assistant")[-1].strip()
47
- return response
48
 
49
  @app.get("/")
50
  def root():
51
- return {"debai API is running!"}
52
 
53
  if __name__ == "__main__":
54
  import uvicorn
 
44
  # Decode & extract assistant response
45
  output_string = tokenizer.batch_decode(outputs, skip_special_tokens=True)[0]
46
  response = output_string.split("assistant")[-1].strip()
47
+ return {"response": response}
48
 
49
  @app.get("/")
50
  def root():
51
+ return {"debai": "API is running!"}
52
 
53
  if __name__ == "__main__":
54
  import uvicorn