Can it use to translate from Korean to English

#1
by HungNguyen31 - opened

here is my code:
model = AutoModelForSeq2SeqLM.from_pretrained("esunn/nllb-200-ko-grammarly-3.3B", cache_dir="./pretrained_models", torch_dtype=torch.float16, device_map="auto", quantization_config=quantization_config)
tokenizer = AutoTokenizer.from_pretrained("esunn/nllb-200-ko-grammarly-3.3B", cache_dir="./pretrained_models")
translator = pipeline('translation', model=model,
tokenizer=tokenizer, src_lang=kor_Hang, tgt_lang=eng_Latn,
max_length=350,
do_sample=True,
temperature=0.3,
num_beams=20,
top_k=150,
top_p=1,
)
. But it always translates into Korean. Where did I do wrong?

sionic-ai org

This model is specifically fine-tuned to correct Korean grammar errors. It 'translates' incorrect Korean to correct Korean sentence.

Sign up or log in to comment