Instructions to use obi/deid_bert_i2b2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use obi/deid_bert_i2b2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("token-classification", model="obi/deid_bert_i2b2")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForTokenClassification tokenizer = AutoTokenizer.from_pretrained("obi/deid_bert_i2b2") model = AutoModelForTokenClassification.from_pretrained("obi/deid_bert_i2b2", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit ·
32d00e6
1
Parent(s): 1c9a57f
Trying a different aggregation strategy
Browse files
README.md
CHANGED
|
@@ -16,6 +16,9 @@ widget:
|
|
| 16 |
- text: "Home Address: 123 Park Drive, San Diego, CA, 03245. Home Phone: 202-555-0199 (home)."
|
| 17 |
- text: "Hospital Care Team Service: Orthopedics Inpatient Attending: Roger C Kelly, MD Attending phys phone: (634)743-5135 Discharge Unit: HCS843 Primary Care Physician: Hassan V Kim, MD 512-832-5025."
|
| 18 |
---
|
|
|
|
|
|
|
|
|
|
| 19 |
|
| 20 |
|
| 21 |
# BERT-based deidentification model
|
|
|
|
| 16 |
- text: "Home Address: 123 Park Drive, San Diego, CA, 03245. Home Phone: 202-555-0199 (home)."
|
| 17 |
- text: "Hospital Care Team Service: Orthopedics Inpatient Attending: Roger C Kelly, MD Attending phys phone: (634)743-5135 Discharge Unit: HCS843 Primary Care Physician: Hassan V Kim, MD 512-832-5025."
|
| 18 |
---
|
| 19 |
+
inference:
|
| 20 |
+
parameters:
|
| 21 |
+
aggregation_strategy: "first"
|
| 22 |
|
| 23 |
|
| 24 |
# BERT-based deidentification model
|