Instructions to use cbc-528a/BamiBERT-ViMedNER with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use cbc-528a/BamiBERT-ViMedNER with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("token-classification", model="cbc-528a/BamiBERT-ViMedNER")# Load model directly from transformers import AutoTokenizer, AutoModelForTokenClassification tokenizer = AutoTokenizer.from_pretrained("cbc-528a/BamiBERT-ViMedNER") model = AutoModelForTokenClassification.from_pretrained("cbc-528a/BamiBERT-ViMedNER", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Upload folder using huggingface_hub
Browse files- config.json +55 -0
- model.safetensors +3 -0
- tokenizer.json +0 -0
- tokenizer_config.json +13 -0
config.json
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_cross_attention": false,
|
| 3 |
+
"architectures": [
|
| 4 |
+
"RobertaForTokenClassification"
|
| 5 |
+
],
|
| 6 |
+
"attention_probs_dropout_prob": 0.1,
|
| 7 |
+
"bos_token_id": 0,
|
| 8 |
+
"classifier_dropout": null,
|
| 9 |
+
"dtype": "float32",
|
| 10 |
+
"eos_token_id": 2,
|
| 11 |
+
"hidden_act": "gelu",
|
| 12 |
+
"hidden_dropout_prob": 0.1,
|
| 13 |
+
"hidden_size": 768,
|
| 14 |
+
"id2label": {
|
| 15 |
+
"0": "B-bien_phap_chan_doan",
|
| 16 |
+
"1": "B-bien_phap_dieu_tri",
|
| 17 |
+
"2": "B-nguyen_nhan_benh",
|
| 18 |
+
"3": "B-ten_benh",
|
| 19 |
+
"4": "B-trieu_chung_benh",
|
| 20 |
+
"5": "I-bien_phap_chan_doan",
|
| 21 |
+
"6": "I-bien_phap_dieu_tri",
|
| 22 |
+
"7": "I-nguyen_nhan_benh",
|
| 23 |
+
"8": "I-ten_benh",
|
| 24 |
+
"9": "I-trieu_chung_benh",
|
| 25 |
+
"10": "O"
|
| 26 |
+
},
|
| 27 |
+
"initializer_range": 0.02,
|
| 28 |
+
"intermediate_size": 3072,
|
| 29 |
+
"is_decoder": false,
|
| 30 |
+
"label2id": {
|
| 31 |
+
"B-bien_phap_chan_doan": 0,
|
| 32 |
+
"B-bien_phap_dieu_tri": 1,
|
| 33 |
+
"B-nguyen_nhan_benh": 2,
|
| 34 |
+
"B-ten_benh": 3,
|
| 35 |
+
"B-trieu_chung_benh": 4,
|
| 36 |
+
"I-bien_phap_chan_doan": 5,
|
| 37 |
+
"I-bien_phap_dieu_tri": 6,
|
| 38 |
+
"I-nguyen_nhan_benh": 7,
|
| 39 |
+
"I-ten_benh": 8,
|
| 40 |
+
"I-trieu_chung_benh": 9,
|
| 41 |
+
"O": 10
|
| 42 |
+
},
|
| 43 |
+
"layer_norm_eps": 1e-05,
|
| 44 |
+
"max_position_embeddings": 2050,
|
| 45 |
+
"model_type": "roberta",
|
| 46 |
+
"num_attention_heads": 12,
|
| 47 |
+
"num_hidden_layers": 12,
|
| 48 |
+
"pad_token_id": 1,
|
| 49 |
+
"position_embedding_type": "absolute",
|
| 50 |
+
"tie_word_embeddings": true,
|
| 51 |
+
"transformers_version": "5.5.0",
|
| 52 |
+
"type_vocab_size": 1,
|
| 53 |
+
"use_cache": false,
|
| 54 |
+
"vocab_size": 20481
|
| 55 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:54abff93ff348f85573c883528330a1d167dad6959a396d13209904a3c9793f7
|
| 3 |
+
size 409500004
|
tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"backend": "tokenizers",
|
| 3 |
+
"bos_token": "<s>",
|
| 4 |
+
"cls_token": "<s>",
|
| 5 |
+
"eos_token": "</s>",
|
| 6 |
+
"is_local": false,
|
| 7 |
+
"mask_token": "<mask>",
|
| 8 |
+
"model_max_length": 1000000000000000019884624838656,
|
| 9 |
+
"pad_token": "<pad>",
|
| 10 |
+
"sep_token": "</s>",
|
| 11 |
+
"tokenizer_class": "TokenizersBackend",
|
| 12 |
+
"unk_token": "<unk>"
|
| 13 |
+
}
|