gijl commited on
Commit
72d7222
·
verified ·
1 Parent(s): 70a3062

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -34,7 +34,9 @@ def generate_response(message, history):
34
  ]
35
 
36
  response = pipe(messages)
37
- return response[0][0]['generated_text'][2]['content']
 
 
38
 
39
  demo = gr.ChatInterface(
40
  generate_response,
 
34
  ]
35
 
36
  response = pipe(messages)
37
+ for new_text in streamer:
38
+ partial_text += new_text
39
+ yield partial_text # هذا هو السطر المطلوب
40
 
41
  demo = gr.ChatInterface(
42
  generate_response,