Olivier-Truong commited on
Commit
2540bbb
1 Parent(s): d317910

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -6
app.py CHANGED
@@ -38,14 +38,11 @@ def generate(
38
  stream = client.text_generation(formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=False)
39
  output = ""
40
 
41
- print(stream, stream.__dir__())
42
- try:
43
- print(stream.__dict__)
44
- except:
45
- print("erreur sur le dict")
46
 
47
  for response in stream:
48
- print(response, response.__dir__())
 
 
49
 
50
  output += response.token.text
51
  yield output
 
38
  stream = client.text_generation(formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=False)
39
  output = ""
40
 
 
 
 
 
 
41
 
42
  for response in stream:
43
+ a = response
44
+ a = ""
45
+ print(a, end='')
46
 
47
  output += response.token.text
48
  yield output