htian01 commited on
Commit
13838ab
Β·
verified Β·
1 Parent(s): c9a2392

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -144,7 +144,7 @@ def model_inference(input_dict, history):
144
  padding=True,
145
  ).to("cuda")
146
  streamer = TextIteratorStreamer(processor, skip_prompt=True, skip_special_tokens=True)
147
- generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=4096)
148
  thread = Thread(target=model.generate, kwargs=generation_kwargs)
149
  thread.start()
150
  buffer = ""
 
144
  padding=True,
145
  ).to("cuda")
146
  streamer = TextIteratorStreamer(processor, skip_prompt=True, skip_special_tokens=True)
147
+ generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=1024)
148
  thread = Thread(target=model.generate, kwargs=generation_kwargs)
149
  thread.start()
150
  buffer = ""