diff --git a/extensions/google-translate/script.py b/extensions/google-translate/script.py index aa388110..c7f56d6c 100644 --- a/extensions/google-translate/script.py +++ b/extensions/google-translate/script.py @@ -12,11 +12,11 @@ def input_modifier(string): they are fed into the model. """ - return translator.translate(string, dest='en').text + return translator.translate(string, src=params['language string'], dest='en').text def output_modifier(string): """ This function is applied to the model outputs. """ - return translator.translate(string, dest=params['language string']).text + return translator.translate(string, src="en", dest=params['language string']).text