Classifier for adverse drug reactions

Description

This model can be used to detect clinical events in medical text.

Predicted Entities

Negative, Neutral

Download

How to use

Use as part of an nlp pipeline with the following stages: DocumentAssembler, SentenceDetector, Tokenizer, WordEmbeddingsModel, NerDLModel. Add the NerConverter to the end of the pipeline to convert entity tokens into full entity chunks.


clinical_ner = ClassifierDLModel.pretrained("classifierdl_biobert_ade", "en", "clinical/models") \
  .setInputCols(["sentence_embeddings"]) \
  .setOutputCol("class")

nlp_pipeline = Pipeline(stages=[document_assembler, tokenizer, word_embeddings, sentence_embeddings])

light_pipeline = LightPipeline(nlp_pipeline.fit(spark.createDataFrame([['']]).toDF("text")))

annotations = light_pipeline.fullAnnotate(text)

Results

A dictionary containing class labels for each sentence.

Model Information

Model Name: classifierdl_biobert_ade
Type: ClassifierDLModel
Compatibility: Spark NLP for Healthcare 2.6.2 +
Edition: Official
License: Licensed
Input Labels: [sentence_embeddings]
Output Labels: [class]
Language: [en]
Case sensitive: false