NPG commited on
Commit
48ebec0
1 Parent(s): 9ee5418

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -12,7 +12,7 @@ def generate_text(input_text, temperature):
12
 
13
  output = model.generate(input_ids, temperature=temperature, max_length=1024, top_k=50, top_p=1.0, repetition_penalty=1.0)
14
  generated_text = tokenizer.decode(output[0], skip_special_tokens=True)
15
- return generated_text.strip().split("\n")[-1]
16
 
17
  inputs = [gr.inputs.Textbox(lines=1, label="Input"),
18
  gr.inputs.Slider(minimum=0.0, maximum=1.0, step=0.1, default=0.7, label="Temperature")]
 
12
 
13
  output = model.generate(input_ids, temperature=temperature, max_length=1024, top_k=50, top_p=1.0, repetition_penalty=1.0)
14
  generated_text = tokenizer.decode(output[0], skip_special_tokens=True)
15
+ return generated_text #.strip().split("\n")[-1]
16
 
17
  inputs = [gr.inputs.Textbox(lines=1, label="Input"),
18
  gr.inputs.Slider(minimum=0.0, maximum=1.0, step=0.1, default=0.7, label="Temperature")]