Downloads · 30 days
160
6% of all-time downloads
ngocthanhdoan/phobert-cccd-ner
phobert-cccd-ner is a machine learning model from ngocthanhdoan. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as mit.
PhoBERT-based Named Entity Recognition model for Vietnamese Căn cước công dân documents.
Downloads · 30 days
160
6% of all-time downloads
All-time downloads
2.5K
Public
Parameters
134M
538 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors538 MB · 100%
From the Hugging Face model README
PhoBERT-based Named Entity Recognition model for Vietnamese Căn cước công dân documents.
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.
This model is fine-tuned from 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_residencefrom vietnerm import VietNerm
ner = VietNerm(doc_type="cccd", model_path="ngocthanhdoan/phobert-cccd-ner")
result = ner.extract("your document text here")
print(result)
from transformers import AutoTokenizer, AutoModelForTokenClassification
import torch
tokenizer = AutoTokenizer.from_pretrained("ngocthanhdoan/phobert-cccd-ner")
model = AutoModelForTokenClassification.from_pretrained("ngocthanhdoan/phobert-cccd-ner")
text = "your document text here"
inputs = tokenizer(text, return_tensors="pt")
with torch.no_grad():
outputs = model(**inputs)
predictions = torch.argmax(outputs.logits, dim=-1)
This model is built for research and development purposes only:
VietNerm is a Document AI Factory for Vietnamese documents. It provides a complete pipeline from template-based synthetic data generation to model training and deployment.
pip install vietnerm