edbeeching HF staff commited on
Commit
4f20b85
·
verified ·
1 Parent(s): 5f87faa

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -37,7 +37,7 @@ def bot_streaming(message, history):
37
  inputs = processor(prompt, image, return_tensors="pt").to("cuda:0")
38
 
39
  streamer = TextIteratorStreamer(processor, **{"skip_special_tokens": True})
40
- generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=100)
41
  generated_text = ""
42
 
43
  thread = Thread(target=model.generate, kwargs=generation_kwargs)
 
37
  inputs = processor(prompt, image, return_tensors="pt").to("cuda:0")
38
 
39
  streamer = TextIteratorStreamer(processor, **{"skip_special_tokens": True})
40
+ generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=512)
41
  generated_text = ""
42
 
43
  thread = Thread(target=model.generate, kwargs=generation_kwargs)