Views
No views yet
Model này được train hoàn toàn trên dữ liệu giả lập (synthetic/mockup data), KHÔNG sử dụng dữ liệu cá nhân thật.
vinai/phobert-base for token-level NER on Vietnamese administrative/medical documents. It extracts structured fields from OCR text output.B-date_of_birthB-date_of_expiryB-full_nameB-genderB-id_numberB-nationalityB-place_of_originB-place_of_residenceI-full_nameI-nationalityI-place_of_originI-place_of_residence1from vietnerm import VietNerm
2
3ner = VietNerm(doc_type="cccd", model_path="phatdatpq/phobert-cccd-ner")
4result = ner.extract("your document text here")
5print(result)1from transformers import AutoTokenizer, AutoModelForTokenClassification
2import torch
3
4tokenizer = AutoTokenizer.from_pretrained("phatdatpq/phobert-cccd-ner")
5model = AutoModelForTokenClassification.from_pretrained("phatdatpq/phobert-cccd-ner")
6
7text = "your document text here"
8inputs = tokenizer(text, return_tensors="pt")
9
10with torch.no_grad():
11 outputs = model(**inputs)
12 predictions = torch.argmax(outputs.logits, dim=-1)pip install vietnerm