From 9c3c47d861d2c121d8d8180e21b9527aa0a099be Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Fri, 20 Dec 2024 02:59:44 +0700 Subject: [PATCH 01/18] Add model 2024-12-19-medication_resolver_transform_pipeline_en --- ...dication_resolver_transform_pipeline_en.md | 137 ++++++++++++++++++ 1 file changed, 137 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md new file mode 100644 index 0000000000..0bc6e5dec7 --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md @@ -0,0 +1,137 @@ +--- +layout: model +title: Pipeline to Resolve Medication Codes(Transform) +author: John Snow Labs +name: medication_resolver_transform_pipeline +date: 2024-12-19 +tags: [licensed, en, resolver, snomed, umls, rxnorm, ndc, ade, pipeline] +task: [Pipeline Healthcare, Named Entity Recognition] +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +A pretrained resolver pipeline to extract medications and resolve their adverse reactions (ADE), RxNorm, UMLS, NDC, SNOMED CT codes, and action/treatments in clinical text. + +Action/treatments are available for branded medication, and SNOMED codes are available for non-branded medication. + +This pipeline can be used with Spark transform. You can use `medication_resolver_pipeline` as Lightpipeline (with `annotate/fullAnnotate`). + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/medication_resolver_transform_pipeline_en_5.5.1_3.4_1734638332532.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/medication_resolver_transform_pipeline_en_5.5.1_3.4_1734638332532.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +medication_resolver_pipeline = PretrainedPipeline("medication_resolver_transform_pipeline", "en", "clinical/models") + +text = """The patient was prescribed Amlodopine Vallarta 10-320mg, Eviplera. +The other patient is given Lescol 40 MG and Everolimus 1.5 mg tablet.""" + +data = spark.createDataFrame([[text]]).toDF("text") + +result = medication_resolver_pipeline.transform(data) + +``` + +{:.jsl-block} +```python + +medication_resolver_pipeline = nlp.PretrainedPipeline("medication_resolver_transform_pipeline", "en", "clinical/models") + +text = """The patient was prescribed Amlodopine Vallarta 10-320mg, Eviplera. +The other patient is given Lescol 40 MG and Everolimus 1.5 mg tablet.""" + +data = spark.createDataFrame([[text]]).toDF("text") + +result = medication_resolver_pipeline.transform(data) + + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val medication_resolver_pipeline = new PretrainedPipeline("medication_resolver_transform_pipeline", "en", "clinical/models") + +val data = Seq("""The patient was prescribed Amlodopine Vallarta 10-320mg, Eviplera. +The other patient is given Lescol 40 MG and Everolimus 1.5 mg tablet.""").toDS.toDF("text") + +val result = medication_resolver_pipeline.fit(data).transform(data) + +``` +
+ +## Results + +```bash + + ++----------------------------+---------+---------------------------+-------+--------------------------+------------------------------------------+--------+----------------+-----------+-------------+ +|chunk |ner_label|ADE |RxNorm |Action |Treatment |UMLS |SNOMED_CT |NDC_Product|NDC_Package | ++----------------------------+---------+---------------------------+-------+--------------------------+------------------------------------------+--------+----------------+-----------+-------------+ +|Amlodopine Vallarta 10-320mg|DRUG |Gynaecomastia |722131 |NONE |NONE |C1949334|1153435009 |00093-7693 |00093-7693-56| +|Eviplera |DRUG |Anxiety |217010 |Inhibitory Bone Resorption|Osteoporosis |C0720318|NONE |NONE |NONE | +|Lescol 40 MG |DRUG |NONE |103919 |Hypocholesterolemic |Heterozygous Familial Hypercholesterolemia|C0353573|NONE |00078-0234 |00078-0234-05| +|Everolimus 1.5 mg tablet |DRUG |Acute myocardial infarction|2056895|NONE |NONE |C4723581|1029521000202102|00054-0604 |00054-0604-21| ++----------------------------+---------+---------------------------+-------+--------------------------+------------------------------------------+--------+----------------+-----------+-------------+ + + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|medication_resolver_transform_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|3.3 GB| + +## Included Models + +- DocumentAssembler +- SentenceDetectorDLModel +- TokenizerModel +- WordEmbeddingsModel +- MedicalNerModel +- NerConverterInternalModel +- TextMatcherInternalModel +- ChunkMergeModel +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperFilterer +- Chunk2Doc +- BertSentenceEmbeddings +- SentenceEntityResolverModel +- ResolverMerger +- Doc2Chunk +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperModel +- Doc2Chunk +- ChunkMapperModel +- Finisher \ No newline at end of file From 7ed476f7ff7ba9194be91f5d52acdb4bd41d4e0d Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Thu, 19 Dec 2024 21:02:07 +0100 Subject: [PATCH 02/18] Update 2024-12-19-medication_resolver_transform_pipeline_en.md --- ...2024-12-19-medication_resolver_transform_pipeline_en.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md index 0bc6e5dec7..a2be9270db 100644 --- a/docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_transform_pipeline_en.md @@ -24,6 +24,10 @@ Action/treatments are available for branded medication, and SNOMED codes are ava This pipeline can be used with Spark transform. You can use `medication_resolver_pipeline` as Lightpipeline (with `annotate/fullAnnotate`). +## Predicted Entities + +`DRUG` + {:.btn-box} @@ -36,6 +40,7 @@ This pipeline can be used with Spark transform. You can use `medication_resolver
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -134,4 +139,4 @@ val result = medication_resolver_pipeline.fit(data).transform(data) - ChunkMapperModel - Doc2Chunk - ChunkMapperModel -- Finisher \ No newline at end of file +- Finisher From 6f78109ba456aa06c49dc0a1f513e71c8160e85e Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Fri, 20 Dec 2024 03:58:56 +0700 Subject: [PATCH 03/18] Add model 2024-12-19-medication_resolver_pipeline_en --- ...4-12-19-medication_resolver_pipeline_en.md | 131 ++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md new file mode 100644 index 0000000000..bb55e00151 --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md @@ -0,0 +1,131 @@ +--- +layout: model +title: Pipeline to Resolve Medication Codes +author: John Snow Labs +name: medication_resolver_pipeline +date: 2024-12-19 +tags: [licensed, en, resolver, snomed, umls, rxnorm, ndc, ade, pipeline] +task: [Pipeline Healthcare, Named Entity Recognition] +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +A pretrained resolver pipeline to extract medications and resolve their adverse reactions (ADE), RxNorm, UMLS, NDC, SNOMED CT codes, and action/treatments in clinical text. + +Action/treatments are available for branded medication, and SNOMED codes are available for non-branded medication. + +This pipeline can be used as Lightpipeline (with `annotate/fullAnnotate`). You can use `medication_resolver_transform_pipeline` for Spark transform. + +## Predicted Entities + +`DRUG` + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/medication_resolver_pipeline_en_5.5.1_3.4_1734641720568.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/medication_resolver_pipeline_en_5.5.1_3.4_1734641720568.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +ner_pipeline = PretrainedPipeline("medication_resolver_pipeline", "en", "clinical/models") + +result = ner_pipeline.annotate("""The patient was prescribed Amlodopine Vallarta 10-320mg, Eviplera. +The other patient is given Lescol 40 MG and Everolimus 1.5 mg tablet. +""") + +``` + +{:.jsl-block} +```python + +ner_pipeline = nlp.PretrainedPipeline("medication_resolver_pipeline", "en", "clinical/models") + +result = ner_pipeline.annotate("""The patient was prescribed Amlodopine Vallarta 10-320mg, Eviplera. +The other patient is given Lescol 40 MG and Everolimus 1.5 mg tablet. +""") + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val ner_pipeline = PretrainedPipeline("medication_resolver_pipeline", "en", "clinical/models") + +val result = ner_pipeline.annotate("""The patient was prescribed Amlodopine Vallarta 10-320mg, Eviplera. +The other patient is given Lescol 40 MG and Everolimus 1.5 mg tablet. +""") + +``` +
+ +## Results + +```bash + + ++----------------------------+---------+---------------------------+-------+--------------------------+------------------------------------------+--------+----------------+-----------+-------------+ +|chunk |ner_label|ADE |RxNorm |Action |Treatment |UMLS |SNOMED_CT |NDC_Product|NDC_Package | ++----------------------------+---------+---------------------------+-------+--------------------------+------------------------------------------+--------+----------------+-----------+-------------+ +|Amlodopine Vallarta 10-320mg|DRUG |Gynaecomastia |722131 |NONE |NONE |C1949334|1153435009 |00093-7693 |00093-7693-56| +|Eviplera |DRUG |Anxiety |217010 |Inhibitory Bone Resorption|Osteoporosis |C0720318|NONE |NONE |NONE | +|Lescol 40 MG |DRUG |NONE |103919 |Hypocholesterolemic |Heterozygous Familial Hypercholesterolemia|C0353573|NONE |00078-0234 |00078-0234-05| +|Everolimus 1.5 mg tablet |DRUG |Acute myocardial infarction|2056895|NONE |NONE |C4723581|1029521000202102|00054-0604 |00054-0604-21| ++----------------------------+---------+---------------------------+-------+--------------------------+------------------------------------------+--------+----------------+-----------+-------------+ + + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|medication_resolver_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|3.3 GB| + +## Included Models + +- DocumentAssembler +- SentenceDetectorDLModel +- TokenizerModel +- WordEmbeddingsModel +- MedicalNerModel +- NerConverterInternalModel +- TextMatcherInternalModel +- ChunkMergeModel +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperFilterer +- Chunk2Doc +- BertSentenceEmbeddings +- SentenceEntityResolverModel +- ResolverMerger +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperModel +- Finisher \ No newline at end of file From cbf832a4886c18253c2ded65bee5cbcfa8592b2c Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Thu, 19 Dec 2024 22:00:00 +0100 Subject: [PATCH 04/18] Update 2024-12-19-medication_resolver_pipeline_en.md --- .../gokhanturer/2024-12-19-medication_resolver_pipeline_en.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md index bb55e00151..8d8bc38131 100644 --- a/docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-19-medication_resolver_pipeline_en.md @@ -40,6 +40,7 @@ This pipeline can be used as Lightpipeline (with `annotate/fullAnnotate`). You c
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -128,4 +129,4 @@ The other patient is given Lescol 40 MG and Everolimus 1.5 mg tablet. - ChunkMapperModel - ChunkMapperModel - ChunkMapperModel -- Finisher \ No newline at end of file +- Finisher From 99401b5c006c1dd6e54b0aa4aaba063ffba71670 Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Mon, 23 Dec 2024 19:56:46 +0700 Subject: [PATCH 05/18] Add model 2024-12-23-snomed_multi_mapper_pipeline_en --- ...4-12-23-snomed_multi_mapper_pipeline_en.md | 99 +++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md new file mode 100644 index 0000000000..4c70deb955 --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md @@ -0,0 +1,99 @@ +--- +layout: model +title: SNOMED Code Mapping Pipeline +author: John Snow Labs +name: snomed_multi_mapper_pipeline +date: 2024-12-23 +tags: [licensed, en, snomed, pipeline] +task: Pipeline Healthcare +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +This pretrained pipeline maps SNOMED codes to their corresponding ICD-10, ICD-O, and UMLS codes. + +## Predicted Entities + +`snomed_code` + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/snomed_multi_mapper_pipeline_en_5.5.1_3.4_1734958604723.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/snomed_multi_mapper_pipeline_en_5.5.1_3.4_1734958604723.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +mapper_pipeline = PretrainedPipeline("snomed_multi_mapper_pipeline", "en", "clinical/models") + +result = mapper_pipeline.fullAnnotate(["10000006", "128501000"]) + +``` + +{:.jsl-block} +```python + +mapper_pipeline = nlp.PretrainedPipeline("snomed_multi_mapper_pipeline", "en", "clinical/models") + +result = mapper_pipeline.fullAnnotate(["10000006", "128501000"]) + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val mapper_pipeline = PretrainedPipeline("snomed_multi_mapper_pipeline", "en", "clinical/models") + +val result = mapper_pipeline.fullAnnotate(["10000006", "128501000"]) + +``` +
+ +## Results + +```bash + ++-----------+------------+---------+---------+ +|snomed_code|icd10cm_code|icdo_code|umls_code| ++-----------+------------+---------+---------+ +| 10000006| R07.9| NONE| C0232289| +| 128501000| NONE| C49.5| C0448606| ++-----------+------------+---------+---------+ + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|snomed_multi_mapper_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|9.4 MB| + +## Included Models + +- DocumentAssembler +- DocMapperModel +- DocMapperModel +- DocMapperModel \ No newline at end of file From b9283a5ac9de2add3bfcd6532fd5d34e6bb14a62 Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Mon, 23 Dec 2024 13:58:23 +0100 Subject: [PATCH 06/18] Update 2024-12-23-snomed_multi_mapper_pipeline_en.md --- .../gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md index 4c70deb955..443b54ec4f 100644 --- a/docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-23-snomed_multi_mapper_pipeline_en.md @@ -36,6 +36,7 @@ This pretrained pipeline maps SNOMED codes to their corresponding ICD-10, ICD-O,
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -96,4 +97,4 @@ val result = mapper_pipeline.fullAnnotate(["10000006", "128501000"]) - DocumentAssembler - DocMapperModel - DocMapperModel -- DocMapperModel \ No newline at end of file +- DocMapperModel From 9719cda2ebd2500ffecbb0514f697abef9359317 Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Mon, 23 Dec 2024 22:01:16 +0700 Subject: [PATCH 07/18] Add model 2024-12-23-umls_drug_substance_resolver_pipeline_en --- ...mls_drug_substance_resolver_pipeline_en.md | 109 ++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md new file mode 100644 index 0000000000..871a15b1c5 --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md @@ -0,0 +1,109 @@ +--- +layout: model +title: Drug Substance to UMLS Code Pipeline +author: John Snow Labs +name: umls_drug_substance_resolver_pipeline +date: 2024-12-23 +tags: [licensed, en, resolver, clinical, umls, drug, subtance, pipeline] +task: [Pipeline Healthcare, Chunk Mapping] +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +This pretrained pipeline maps entities (Drug Substances) with their corresponding UMLS CUI codes. You’ll just feed your text and it will return the corresponding UMLS codes. + +## Predicted Entities + +`DRUG` + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/umls_drug_substance_resolver_pipeline_en_5.5.1_3.4_1734965744594.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/umls_drug_substance_resolver_pipeline_en_5.5.1_3.4_1734965744594.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +resolver_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") + +``` + +{:.jsl-block} +```python + +resolver_pipeline = nlp.PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val resolver_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") + +val result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") + +``` +
+ +## Results + +```bash + ++-----------------------------+---------+---------+ +|chunk |ner_label|umls_code| ++-----------------------------+---------+---------+ +|metformin |DRUG |C0025598 | +|lenvatinib |DRUG |C2986924 | +|Magnesium hydroxide 100mg/1ml|DRUG |C1134402 | ++-----------------------------+---------+---------+ + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|umls_drug_substance_resolver_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|5.1 GB| + +## Included Models + +- DocumentAssembler +- SentenceDetector +- TokenizerModel +- WordEmbeddingsModel +- MedicalNerModel +- NerConverter +- ChunkMapperModel +- ChunkMapperModel +- ChunkMapperFilterer +- Chunk2Doc +- BertSentenceEmbeddings +- SentenceEntityResolverModel +- ResolverMerger \ No newline at end of file From d2c475d2e957968af3ba45c70d8d36cffb3861bc Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Mon, 23 Dec 2024 16:03:56 +0100 Subject: [PATCH 08/18] Update 2024-12-23-umls_drug_substance_resolver_pipeline_en.md --- .../2024-12-23-umls_drug_substance_resolver_pipeline_en.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md index 871a15b1c5..6ad37dfeab 100644 --- a/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md @@ -36,6 +36,7 @@ This pretrained pipeline maps entities (Drug Substances) with their correspondin
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -106,4 +107,4 @@ val result = resolver_pipeline.annotate("""The patient was given metformin, len - Chunk2Doc - BertSentenceEmbeddings - SentenceEntityResolverModel -- ResolverMerger \ No newline at end of file +- ResolverMerger From 96c2b2fb43cce3f0cbc83699733d2a914b1782fd Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Mon, 23 Dec 2024 21:00:57 +0100 Subject: [PATCH 09/18] Update 2024-12-23-umls_drug_substance_resolver_pipeline_en.md --- ...12-23-umls_drug_substance_resolver_pipeline_en.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md index 6ad37dfeab..eb19a4b194 100644 --- a/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md @@ -41,27 +41,27 @@ This pretrained pipeline maps entities (Drug Substances) with their correspondin from sparknlp.pretrained import PretrainedPipeline -resolver_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") +mapper_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") -result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") +result = mapper_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") ``` {:.jsl-block} ```python -resolver_pipeline = nlp.PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") +mapper_pipeline = nlp.PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") -result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") +result = mapper_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") ``` ```scala import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline -val resolver_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") +val mapper_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") -val result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") +val result = mapper_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") ```
From e93ba20b42e1d2d101fd1feb201537eb20810a81 Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Mon, 23 Dec 2024 21:08:13 +0100 Subject: [PATCH 10/18] Update 2024-12-23-umls_drug_substance_resolver_pipeline_en.md --- ...12-23-umls_drug_substance_resolver_pipeline_en.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md index eb19a4b194..6ad37dfeab 100644 --- a/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-23-umls_drug_substance_resolver_pipeline_en.md @@ -41,27 +41,27 @@ This pretrained pipeline maps entities (Drug Substances) with their correspondin from sparknlp.pretrained import PretrainedPipeline -mapper_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") +resolver_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") -result = mapper_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") +result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") ``` {:.jsl-block} ```python -mapper_pipeline = nlp.PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") +resolver_pipeline = nlp.PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") -result = mapper_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") +result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") ``` ```scala import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline -val mapper_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") +val resolver_pipeline = PretrainedPipeline("umls_drug_substance_resolver_pipeline", "en", "clinical/models") -val result = mapper_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") +val result = resolver_pipeline.annotate("""The patient was given metformin, lenvatinib and Magnesium hydroxide 100mg/1ml""") ```
From c552b0d2120868bb8a0e51640dccf5b52aac0e57 Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Tue, 24 Dec 2024 03:58:09 +0700 Subject: [PATCH 11/18] Add model 2024-12-23-umls_clinical_findings_resolver_pipeline_en --- ..._clinical_findings_resolver_pipeline_en.md | 108 ++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md new file mode 100644 index 0000000000..d6aa8f328e --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md @@ -0,0 +1,108 @@ +--- +layout: model +title: Clinical Findings to UMLS Code Pipeline +author: John Snow Labs +name: umls_clinical_findings_resolver_pipeline +date: 2024-12-23 +tags: [licensed, en, resolver, clinical, umls, pipeline] +task: [Pipeline Healthcare, Chunk Mapping] +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +This pretrained pipeline maps entities (Clinical Findings) with their corresponding UMLS CUI codes. You’ll just feed your text and it will return the corresponding UMLS codes. + +## Predicted Entities + +`PROBLEM` + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/umls_clinical_findings_resolver_pipeline_en_5.5.1_3.4_1734987348525.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/umls_clinical_findings_resolver_pipeline_en_5.5.1_3.4_1734987348525.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +resolver_pipeline = PretrainedPipeline("umls_clinical_findings_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""HTG-induced pancreatitis associated with an acute hepatitis, and obesity""") + +``` + +{:.jsl-block} +```python + +resolver_pipeline = nlp.PretrainedPipeline("umls_clinical_findings_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""HTG-induced pancreatitis associated with an acute hepatitis, and obesity""") + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val resolver_pipeline = PretrainedPipeline("umls_clinical_findings_resolver_pipeline", "en", "clinical/models") + +val result = resolver_pipeline.annotate("""HTG-induced pancreatitis associated with an acute hepatitis, and obesity""") + +``` +
+ +## Results + +```bash + ++------------------------+---------+---------+ +|chunk |ner_label|umls_code| ++------------------------+---------+---------+ +|HTG-induced pancreatitis|PROBLEM |C3808945 | +|an acute hepatitis |PROBLEM |C4750596 | +|obesity |PROBLEM |C4759928 | ++------------------------+---------+---------+ + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|umls_clinical_findings_resolver_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|4.4 GB| + +## Included Models + +- DocumentAssembler +- SentenceDetector +- TokenizerModel +- WordEmbeddingsModel +- MedicalNerModel +- NerConverter +- ChunkMapperModel +- ChunkMapperFilterer +- Chunk2Doc +- BertSentenceEmbeddings +- SentenceEntityResolverModel +- ResolverMerger \ No newline at end of file From 6747f44e3d3c3a598b26ea33a0f18e932d4ba7d0 Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Mon, 23 Dec 2024 21:59:46 +0100 Subject: [PATCH 12/18] Update 2024-12-23-umls_clinical_findings_resolver_pipeline_en.md --- .../2024-12-23-umls_clinical_findings_resolver_pipeline_en.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md index d6aa8f328e..a880b98f27 100644 --- a/docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-23-umls_clinical_findings_resolver_pipeline_en.md @@ -36,6 +36,7 @@ This pretrained pipeline maps entities (Clinical Findings) with their correspond
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -105,4 +106,4 @@ val result = resolver_pipeline.annotate("""HTG-induced pancreatitis associated w - Chunk2Doc - BertSentenceEmbeddings - SentenceEntityResolverModel -- ResolverMerger \ No newline at end of file +- ResolverMerger From dc5c69f7f62d10da657b64edbc503f2dac9b38f3 Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Tue, 24 Dec 2024 18:16:57 +0700 Subject: [PATCH 13/18] Add model 2024-12-24-umls_drug_resolver_pipeline_en --- ...24-12-24-umls_drug_resolver_pipeline_en.md | 107 ++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md new file mode 100644 index 0000000000..b0c71b61c0 --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md @@ -0,0 +1,107 @@ +--- +layout: model +title: Clinical Drugs to UMLS Code Mapping +author: John Snow Labs +name: umls_drug_resolver_pipeline +date: 2024-12-24 +tags: [licensed, en, resolver, clinical, umls, pipeline] +task: [Pipeline Healthcare, Chunk Mapping] +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +This pretrained pipeline maps entities (Clinical Drugs) with their corresponding UMLS CUI codes. You’ll just feed your text and it will return the corresponding UMLS codes. + +## Predicted Entities + +`DRUG` + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/umls_drug_resolver_pipeline_en_5.5.1_3.4_1735038964492.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/umls_drug_resolver_pipeline_en_5.5.1_3.4_1735038964492.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +resolver_pipeline = PretrainedPipeline("umls_drug_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""The patient was given Adapin 10 MG, coumadn 5 mg.""") + +``` + +{:.jsl-block} +```python + +resolver_pipeline = nlp.PretrainedPipeline("umls_drug_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""The patient was given Adapin 10 MG, coumadn 5 mg.""") + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val resolver_pipeline = PretrainedPipeline("umls_drug_resolver_pipeline", "en", "clinical/models") + +val result = resolver_pipeline.annotate("""The patient was given Adapin 10 MG, coumadn 5 mg.""") + +``` +
+ +## Results + +```bash + ++------------+---------+---------+ +|chunk |ner_label|umls_code| ++------------+---------+---------+ +|Adapin 10 MG|DRUG |C1382178 | +|coumadn 5 mg|DRUG |C1368171 | ++------------+---------+---------+ + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|umls_drug_resolver_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|4.0 GB| + +## Included Models + +- DocumentAssembler +- SentenceDetector +- TokenizerModel +- WordEmbeddingsModel +- MedicalNerModel +- NerConverter +- ChunkMapperModel +- ChunkMapperFilterer +- Chunk2Doc +- BertSentenceEmbeddings +- SentenceEntityResolverModel +- ResolverMerger \ No newline at end of file From 9e6ac05daf70f4ad68c928cf51cb8b47a81bf9dd Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Tue, 24 Dec 2024 12:17:46 +0100 Subject: [PATCH 14/18] Update 2024-12-24-umls_drug_resolver_pipeline_en.md --- .../gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md index b0c71b61c0..2c2779801c 100644 --- a/docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-24-umls_drug_resolver_pipeline_en.md @@ -36,6 +36,7 @@ This pretrained pipeline maps entities (Clinical Drugs) with their corresponding
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -104,4 +105,4 @@ val result = resolver_pipeline.annotate("""The patient was given Adapin 10 MG, c - Chunk2Doc - BertSentenceEmbeddings - SentenceEntityResolverModel -- ResolverMerger \ No newline at end of file +- ResolverMerger From c3259b6452c4e17c236d714bee9af8f4f8bc0c52 Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Tue, 24 Dec 2024 20:07:50 +0700 Subject: [PATCH 15/18] Add model 2024-12-24-umls_disease_syndrome_resolver_pipeline_en --- ...s_disease_syndrome_resolver_pipeline_en.md | 112 ++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md new file mode 100644 index 0000000000..caca0c3184 --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md @@ -0,0 +1,112 @@ +--- +layout: model +title: Diseases and Syndromes to UMLS Code Pipeline +author: John Snow Labs +name: umls_disease_syndrome_resolver_pipeline +date: 2024-12-24 +tags: [licensed, en, resolver, clinical, umls, pipeline] +task: [Pipeline Healthcare, Chunk Mapping] +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +This pretrained pipeline maps entities (Diseases and Syndromes) with their corresponding UMLS CUI codes. You’ll just feed your text and it will return the corresponding UMLS codes. + +## Predicted Entities + +`PROBLEM` + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/umls_disease_syndrome_resolver_pipeline_en_5.5.1_3.4_1735045618511.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/umls_disease_syndrome_resolver_pipeline_en_5.5.1_3.4_1735045618511.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +resolver_pipeline = PretrainedPipeline("umls_disease_syndrome_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""A 34-year-old female with a history of poor appetite, gestational diabetes mellitus, acyclovir allergy and polyuria.""") + +``` + +{:.jsl-block} +```python + +resolver_pipeline = nlp.PretrainedPipeline("umls_disease_syndrome_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""A 34-year-old female with a history of poor appetite, gestational diabetes mellitus, acyclovir allergy and polyuria.""") + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val resolver_pipeline = PretrainedPipeline("umls_disease_syndrome_resolver_pipeline", "en", "clinical/models") + +val result = resolver_pipeline.annotate("""A 34-year-old female with a history of poor appetite, gestational diabetes mellitus, acyclovir allergy and polyuria.""") + +``` +
+ +## Results + +```bash + ++-----------------------------+---------+---------+ +|chunk |ner_label|umls_code| ++-----------------------------+---------+---------+ +|poor appetite |PROBLEM |C0003123 | +|gestational diabetes mellitus|PROBLEM |C0085207 | +|acyclovir allergy |PROBLEM |C0571297 | +|polyuria |PROBLEM |C0011848 | ++-----------------------------+---------+---------+ + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|umls_disease_syndrome_resolver_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|3.4 GB| + +## Included Models + +- DocumentAssembler +- SentenceDetector +- TokenizerModel +- WordEmbeddingsModel +- MedicalNerModel +- NerConverter +- MedicalNerModel +- NerConverter +- ChunkMergeModel +- ChunkMapperModel +- ChunkMapperFilterer +- Chunk2Doc +- BertSentenceEmbeddings +- SentenceEntityResolverModel +- ResolverMerger \ No newline at end of file From 424a5ec177a4ad222bc4a8bd20609f958ac5260a Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Tue, 24 Dec 2024 14:10:23 +0100 Subject: [PATCH 16/18] Update 2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md --- .../2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md index caca0c3184..32776e0082 100644 --- a/docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-24-umls_disease_syndrome_resolver_pipeline_en.md @@ -36,6 +36,7 @@ This pretrained pipeline maps entities (Diseases and Syndromes) with their corre
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -109,4 +110,4 @@ val result = resolver_pipeline.annotate("""A 34-year-old female with a history o - Chunk2Doc - BertSentenceEmbeddings - SentenceEntityResolverModel -- ResolverMerger \ No newline at end of file +- ResolverMerger From 83a28c9b9899eac949c5a9910f4b94fe8f459235 Mon Sep 17 00:00:00 2001 From: gokhanturer Date: Tue, 24 Dec 2024 21:50:59 +0700 Subject: [PATCH 17/18] Add model 2024-12-24-umls_major_concepts_resolver_pipeline_en --- ...mls_major_concepts_resolver_pipeline_en.md | 109 ++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md diff --git a/docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md new file mode 100644 index 0000000000..e083c93b5a --- /dev/null +++ b/docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md @@ -0,0 +1,109 @@ +--- +layout: model +title: Clinical Major Concepts to UMLS Code Pipeline +author: John Snow Labs +name: umls_major_concepts_resolver_pipeline +date: 2024-12-24 +tags: [licensed, en, resolver, clinical, umls, pipeline] +task: [Pipeline Healthcare, Chunk Mapping] +language: en +edition: Healthcare NLP 5.5.1 +spark_version: 3.4 +supported: true +annotator: PipelineModel +article_header: + type: cover +use_language_switcher: "Python-Scala-Java" +--- + +## Description + +This pretrained pipeline maps entities (Clinical Major Concepts) with their corresponding UMLS CUI codes. You’ll just feed your text and it will return the corresponding UMLS codes. + +## Predicted Entities + +`Qualitative_Concept`, `Mental_Process`, `Health_Care_Activity`, `Professional_or_Occupational_Group`, `Population_Group`, `Group`, `Pharmacologic_Substance`, `Research_Activity`, `Medical_Device`, `Diagnostic_Procedure`, `Molecular_Function`, `Spatial_Concept`, `Organic_Chemical`, `Amino_Acid`, `Peptide_or_Protein`, `Disease_or_Syndrome`, `Daily_or_Recreational_Activity`, `Quantitative_Concept`, `Biologic_Function`, `Organism_Attribute`, `Clinical_Attribute`, `Pathologic_Function`, `Eukaryote`, `Body_Part`, `Organ_or_Organ_Component`, `Anatomical_Structure`, `Cell_Component`, `Geographic_Area`, `Manufactured_Object`, `Tissue`, `Plant`, `Nucleic_Acid`, `Nucleoside_or_Nucleotide`, `Indicator`, `Reagent_or_Diagnostic_Aid`, `Prokaryote`, `Chemical`, `Therapeutic_or_Preventive_Procedure`, `Gene_or_Genome`, `Mammal`, `Laboratory_Procedure`, `Substance`, `Molecular_Biology_Research_Technique`, `Neoplastic_Process`, `Cell`, `Food`, `Genetic_Function`, `Mental_or_Behavioral_Dysfunction`, `Body_Substance`, `Sign_or_Symptom`, `Injury_or_Poisoning`, `Body_Location_or_Region`, `Organization`, `Body_System`, `Fungus`, `Virus`, `Nucleotide_Sequence`, `Biomedical_or_Dental_Material` + +{:.btn-box} + + +[Download](https://s3.amazonaws.com/auxdata.johnsnowlabs.com/clinical/models/umls_major_concepts_resolver_pipeline_en_5.5.1_3.4_1735051413295.zip){:.button.button-orange.button-orange-trans.arr.button-icon.hidden} +[Copy S3 URI](s3://auxdata.johnsnowlabs.com/clinical/models/umls_major_concepts_resolver_pipeline_en_5.5.1_3.4_1735051413295.zip){:.button.button-orange.button-orange-trans.button-icon.button-copy-s3} + +## How to use + + + +
+{% include programmingLanguageSelectScalaPythonNLU.html %} +```python + +from sparknlp.pretrained import PretrainedPipeline + +resolver_pipeline = PretrainedPipeline("umls_major_concepts_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""The patient complains of pustules after falling from stairs. She has been advised Arthroscopy by her primary care pyhsician""") + +``` + +{:.jsl-block} +```python + +resolver_pipeline = nlp.PretrainedPipeline("umls_major_concepts_resolver_pipeline", "en", "clinical/models") + +result = resolver_pipeline.annotate("""The patient complains of pustules after falling from stairs. She has been advised Arthroscopy by her primary care pyhsician""") + +``` +```scala + +import com.johnsnowlabs.nlp.pretrained.PretrainedPipeline + +val resolver_pipeline = PretrainedPipeline("umls_major_concepts_resolver_pipeline", "en", "clinical/models") + +val result = resolver_pipeline.annotate("""The patient complains of pustules after falling from stairs. She has been advised Arthroscopy by her primary care pyhsician""") + +``` +
+ +## Results + +```bash + ++----------------------+-----------------------------------+---------+ +|chunk |ner_label |umls_code| ++----------------------+-----------------------------------+---------+ +|pustules |Sign_or_Symptom |C0241157 | +|stairs |Daily_or_Recreational_Activity |C4300351 | +|Arthroscopy |Therapeutic_or_Preventive_Procedure|C0179144 | +|primary care pyhsician|Health_Care_Activity |C3266804 | ++----------------------+-----------------------------------+---------+ + +``` + +{:.model-param} +## Model Information + +{:.table-model} +|---|---| +|Model Name:|umls_major_concepts_resolver_pipeline| +|Type:|pipeline| +|Compatibility:|Healthcare NLP 5.5.1+| +|License:|Licensed| +|Edition:|Official| +|Language:|en| +|Size:|6.4 GB| + +## Included Models + +- DocumentAssembler +- SentenceDetector +- TokenizerModel +- WordEmbeddingsModel +- MedicalNerModel +- NerConverter +- ChunkMapperModel +- ChunkMapperFilterer +- Chunk2Doc +- BertSentenceEmbeddings +- SentenceEntityResolverModel +- ResolverMerger \ No newline at end of file From 8d0f42247c9e7b3c10ecaf9179f62b5e7ac693ac Mon Sep 17 00:00:00 2001 From: Akar <67700732+akrztrk@users.noreply.github.com> Date: Tue, 24 Dec 2024 15:53:01 +0100 Subject: [PATCH 18/18] Update 2024-12-24-umls_major_concepts_resolver_pipeline_en.md --- .../2024-12-24-umls_major_concepts_resolver_pipeline_en.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md b/docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md index e083c93b5a..f6b23e8bab 100644 --- a/docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md +++ b/docs/_posts/gokhanturer/2024-12-24-umls_major_concepts_resolver_pipeline_en.md @@ -36,6 +36,7 @@ This pretrained pipeline maps entities (Clinical Major Concepts) with their corr
{% include programmingLanguageSelectScalaPythonNLU.html %} + ```python from sparknlp.pretrained import PretrainedPipeline @@ -106,4 +107,4 @@ val result = resolver_pipeline.annotate("""The patient complains of pustules aft - Chunk2Doc - BertSentenceEmbeddings - SentenceEntityResolverModel -- ResolverMerger \ No newline at end of file +- ResolverMerger