Update app.py
Browse files
app.py
CHANGED
@@ -13,7 +13,7 @@ prefix = "Translate this text from English to uzbek: "
|
|
13 |
def translator(input_text,history):
|
14 |
if not input_text.strip():
|
15 |
return "Iltimos Gap kiriting"
|
16 |
-
input_text = str(
|
17 |
inputs = tokenizer(input_text, return_tensors="pt")
|
18 |
outputs = model.generate(**inputs, max_length=256)
|
19 |
translated_text = tokenizer.decode(outputs[0], skip_special_tokens=True)
|
|
|
13 |
def translator(input_text,history):
|
14 |
if not input_text.strip():
|
15 |
return "Iltimos Gap kiriting"
|
16 |
+
input_text = str(input_text)
|
17 |
inputs = tokenizer(input_text, return_tensors="pt")
|
18 |
outputs = model.generate(**inputs, max_length=256)
|
19 |
translated_text = tokenizer.decode(outputs[0], skip_special_tokens=True)
|