Alisa-Leung commited on
Commit
e00a58f
·
verified ·
1 Parent(s): ab8c379

mayyybe works?

Browse files
Files changed (1) hide show
  1. app.py +1 -2
app.py CHANGED
@@ -15,8 +15,7 @@ def respond(message, history):
15
  })
16
  response = ""
17
  for msg in client.chat_completion(messages, max_tokens=200, temperature=1, top_p=0.5):
18
- token = msg.choices[0].delta.content
19
- response += token
20
  yield response.choices[0].message.content.strip()
21
 
22
  chatbot = gr.ChatInterface(fn=respond, title="Magic 8 Ball", description="Discover your fortune...", editable=True)
 
15
  })
16
  response = ""
17
  for msg in client.chat_completion(messages, max_tokens=200, temperature=1, top_p=0.5):
18
+ response += msg
 
19
  yield response.choices[0].message.content.strip()
20
 
21
  chatbot = gr.ChatInterface(fn=respond, title="Magic 8 Ball", description="Discover your fortune...", editable=True)