RaushanTurganbay HF staff commited on
Commit
bfad488
·
verified ·
1 Parent(s): a32c019

200 tokens max

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -89,7 +89,7 @@ def bot_streaming(message, history):
89
 
90
  inputs = processor(text=prompt, images=image, videos=video, return_tensors="pt").to("cuda", torch.float16)
91
  streamer = TextIteratorStreamer(processor, **{"max_new_tokens": 200, "skip_special_tokens": True})
92
- generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=100)
93
  generated_text = ""
94
 
95
  thread = Thread(target=model.generate, kwargs=generation_kwargs)
 
89
 
90
  inputs = processor(text=prompt, images=image, videos=video, return_tensors="pt").to("cuda", torch.float16)
91
  streamer = TextIteratorStreamer(processor, **{"max_new_tokens": 200, "skip_special_tokens": True})
92
+ generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=200)
93
  generated_text = ""
94
 
95
  thread = Thread(target=model.generate, kwargs=generation_kwargs)