Pipeline for National Drug Codes (NDC) Sentence Entity Resolver

Description

This advanced pipeline extracts medication entities from clinical texts and utilizes the sbiobert_base_cased_mli Sentence Bert Embeddings to map these entities to their corresponding National Drug Codes (NDC) codes.

Predicted Entities

DRUG

Copy S3 URI

How to use


from sparknlp.pretrained import PretrainedPipeline

ner_pipeline = PretrainedPipeline("ndc_resolver_pipeline", "en", "clinical/models")

result = ner_pipeline.annotate("""The patient was given aspirin 81 mg and metformin 500 mg""")


import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline

val ner_pipeline = PretrainedPipeline("ndc_resolver_pipeline", "en", "clinical/models")

val result = ner_pipeline.annotate("""The patient was given aspirin 81 mg and metformin 500 mg""")

Results

+----------------+-----+---+---------+----------+-------------------+--------------------------------------------------------------------------------+
|           chunk|begin|end|ner_label|       ndc|        description|                                                                      aux_labels|
+----------------+-----+---+---------+----------+-------------------+--------------------------------------------------------------------------------+
|   aspirin 81 mg|   22| 34|     DRUG|41250-0780|      aspirin 81 mg|{'packages': "['1 BOTTLE, PLASTIC in 1 PACKAGE (41250-780-01)  > 120 TABLET, ...|
|metformin 500 mg|   40| 55|     DRUG|62207-0491|metformin er 500 mg|{'packages': "['5000 TABLET in 1 POUCH (62207-491-31)', '25000 TABLET in 1 CA...|
+----------------+-----+---+---------+----------+-------------------+--------------------------------------------------------------------------------+

Model Information

Model Name: ndc_resolver_pipeline
Type: pipeline
Compatibility: Healthcare NLP 5.2.1+
License: Licensed
Edition: Official
Language: en
Size: 3.0 GB

Included Models

  • DocumentAssembler
  • SentenceDetectorDLModel
  • TokenizerModel
  • WordEmbeddingsModel
  • MedicalNerModel
  • NerConverter
  • Chunk2Doc
  • BertSentenceEmbeddings
  • SentenceEntityResolverModel