Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -12,6 +12,9 @@ subscription_key = os.getenv("COMTRADE_API_KEY", "")
|
|
12 |
# توکن Hugging Face
|
13 |
hf_token = os.getenv("HF_API_TOKEN")
|
14 |
|
|
|
|
|
|
|
15 |
# تنظیم کوانتسازی
|
16 |
quantization_config = BitsAndBytesConfig(load_in_4bit=True)
|
17 |
|
|
|
12 |
# توکن Hugging Face
|
13 |
hf_token = os.getenv("HF_API_TOKEN")
|
14 |
|
15 |
+
# تعریف مترجم
|
16 |
+
translator = GoogleTranslator(source='en', target='fa')
|
17 |
+
|
18 |
# تنظیم کوانتسازی
|
19 |
quantization_config = BitsAndBytesConfig(load_in_4bit=True)
|
20 |
|