Update app.py
Browse files
app.py
CHANGED
@@ -66,7 +66,7 @@ def single_translate(target_lang, text):
|
|
66 |
language = language_names.get(target_lang, "Arabic") # Default to Arabic if not found
|
67 |
|
68 |
# Construct prompt dynamically based on the selected language
|
69 |
-
prompt = f"Make sure you don't output anything else other than the {language} translation requested for the upcoming text:{text} also dont use curly brackets or such just the translation."
|
70 |
try:
|
71 |
output = client.text_generation(prompt)
|
72 |
# Handle different possible response types and return the translated text directly
|
|
|
66 |
language = language_names.get(target_lang, "Arabic") # Default to Arabic if not found
|
67 |
|
68 |
# Construct prompt dynamically based on the selected language
|
69 |
+
prompt = f"You are a professional Translator: don't say a greeting or anything just jump into the translation: Make sure you don't output anything else other than the {language} translation requested for the upcoming text:{text} also dont use curly brackets or such just the translation."
|
70 |
try:
|
71 |
output = client.text_generation(prompt)
|
72 |
# Handle different possible response types and return the translated text directly
|