Nick088 commited on
Commit
e42b84a
1 Parent(s): 42f9f00

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -24,7 +24,9 @@ def generate_response(input_text):
24
 
25
  response = ""
26
  for chunk in stream:
27
- response += chunk.choices[0].delta.content
 
 
28
 
29
  return response
30
 
 
24
 
25
  response = ""
26
  for chunk in stream:
27
+ delta_content = chunk.choices[0].delta.content
28
+ if delta_content is not None:
29
+ response += delta_content
30
 
31
  return response
32