Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -30,7 +30,7 @@ def attribution(text):
|
|
30 |
# Translate the input in german if necessary
|
31 |
if language == 'fr':
|
32 |
translator = pipeline("translation", model="Helsinki-NLP/opus-mt-fr-de")
|
33 |
-
translatedText = translator(text)
|
34 |
text = translatedText[0]["translation_text"]
|
35 |
|
36 |
# Set the bars of the bar chart
|
|
|
30 |
# Translate the input in german if necessary
|
31 |
if language == 'fr':
|
32 |
translator = pipeline("translation", model="Helsinki-NLP/opus-mt-fr-de")
|
33 |
+
translatedText = translator(text[0:511])
|
34 |
text = translatedText[0]["translation_text"]
|
35 |
|
36 |
# Set the bars of the bar chart
|