yentinglin commited on
Commit
d766ef4
1 Parent(s): 94ed6bd

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -31,7 +31,7 @@ with gr.Blocks() as demo:
31
  prompt_tokens = tokenizer.encode(msg)
32
  length_of_prompt = len(prompt_tokens)
33
  if length_of_prompt > max_prompt_length:
34
- msg = tokenizer.decode(prompt_tokens[-max_prompt_length-1:])
35
 
36
  history[-1][1] = ""
37
  for response in client.generate_stream(
 
31
  prompt_tokens = tokenizer.encode(msg)
32
  length_of_prompt = len(prompt_tokens)
33
  if length_of_prompt > max_prompt_length:
34
+ msg = tokenizer.decode(prompt_tokens[-max_prompt_length+1:])
35
 
36
  history[-1][1] = ""
37
  for response in client.generate_stream(