razent commited on
Commit
1e7647a
1 Parent(s): 04d9605

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +1 -1
README.md CHANGED
@@ -23,7 +23,7 @@ tokenizer = AutoTokenizer.from_pretrained("VietAI/vit5-base")
23
  model = AutoModelForSeq2SeqLM.from_pretrained("VietAI/vit5-base")
24
 
25
  sentence = "VietAI là tổ chức phi lợi nhuận với sứ mệnh ươm mầm tài năng về trí tuệ nhân tạo và xây dựng một cộng đồng các chuyên gia trong lĩnh vực trí tuệ nhân tạo đẳng cấp quốc tế tại Việt Nam."
26
- text = "summarize: " + sentence + " </s>"
27
  encoding = tokenizer.encode_plus(text, pad_to_max_length=True, return_tensors="pt")
28
  input_ids, attention_masks = encoding["input_ids"].to("cuda"), encoding["attention_mask"].to("cuda")
29
  outputs = model.generate(
 
23
  model = AutoModelForSeq2SeqLM.from_pretrained("VietAI/vit5-base")
24
 
25
  sentence = "VietAI là tổ chức phi lợi nhuận với sứ mệnh ươm mầm tài năng về trí tuệ nhân tạo và xây dựng một cộng đồng các chuyên gia trong lĩnh vực trí tuệ nhân tạo đẳng cấp quốc tế tại Việt Nam."
26
+ text = "vi: " + sentence
27
  encoding = tokenizer.encode_plus(text, pad_to_max_length=True, return_tensors="pt")
28
  input_ids, attention_masks = encoding["input_ids"].to("cuda"), encoding["attention_mask"].to("cuda")
29
  outputs = model.generate(