Simon Salmon commited on
Commit
5012e22
·
1 Parent(s): 449de4f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -13,7 +13,7 @@ number_of_outputs = st.sidebar.slider("Number of Outputs", 1, 10)
13
 
14
  def translate_to_english(model, tokenizer, text):
15
  translated_text = []
16
- text = "paraphrase: " + text + " </s>"
17
  encoding = tokenizer.encode_plus(text,pad_to_max_length=True, return_tensors="pt")
18
  input_ids, attention_masks = encoding["input_ids"].to(device), encoding["attention_mask"].to(device)
19
  beam_outputs = model.generate(
 
13
 
14
  def translate_to_english(model, tokenizer, text):
15
  translated_text = []
16
+ text = text + " </s>"
17
  encoding = tokenizer.encode_plus(text,pad_to_max_length=True, return_tensors="pt")
18
  input_ids, attention_masks = encoding["input_ids"].to(device), encoding["attention_mask"].to(device)
19
  beam_outputs = model.generate(