lgrobol commited on
Commit
b07f85b
1 Parent(s): 481878e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -4,7 +4,7 @@ from transformers import pipeline
4
  pipeline = pipeline(task="translation", model="lgrobol/m2m100_418M_br_fr")
5
 
6
  def predict(texts):
7
- predictions = pipeline(text.splitlines(), src_lang="br", tgt_lang="fr")
8
  return "\n".join(p["translation_text"] for p in predictions)
9
 
10
  gr.Interface(
 
4
  pipeline = pipeline(task="translation", model="lgrobol/m2m100_418M_br_fr")
5
 
6
  def predict(texts):
7
+ predictions = pipeline(texts.splitlines(), src_lang="br", tgt_lang="fr")
8
  return "\n".join(p["translation_text"] for p in predictions)
9
 
10
  gr.Interface(