Skip to content

Commit

Permalink
Merge branch 'feature/banchmark' into spannerflow
Browse files Browse the repository at this point in the history
  • Loading branch information
techofer committed Dec 15, 2024
2 parents 6d1c579 + f8aaa4a commit 6155ca0
Show file tree
Hide file tree
Showing 10,060 changed files with 11,851 additions and 0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
1,121 changes: 1,121 additions & 0 deletions nbs/banchmark/001_covid.ipynb

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions nbs/banchmark/covid_data/covid_logic.pl
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Lemmas(P,D,Word,Lem)<-Docs(P,D,"raw_text"),lemma(D)->(Word,Lem).

19 changes: 19 additions & 0 deletions nbs/banchmark/covid_data/rules_data/concept_tags_rules.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
(?i)(?:hcov|covid(?:(?:-)?(?:\s)?19|10)?|2019-cov|cov2|ncov-19|covd 19|no-cov|sars cov|covid),COVID-19,lemma
(?i)(?:coivid|(?:novel )?corona(?:virus)?(?: (?:20)?19)?|sars(?:\s)?(?:-)?(?:\s)?cov(?:id)?(?:-)?(?:2|19)),COVID-19,lemma
(?i)(?:\+(?: ve)?|\(\+\)|positive|\bpos\b|active|confirmed),positive,lemma
(?i)(?:pneum(?:onia)?|pna|hypoxia|septic shoc|ards\(?(?:(?:[12])/2)\)?|(?:hypoxemic|acute|severe)? resp(?:iratory)? failure(?:\(?(?:[12]/2)\)?)?)",associated_diagnosis,lemma
(?i)(?:(?:diagnos(?:is|ed)|dx(?:\.)?)(?:of|with)?),diagnosis,lemma
(?i)(?:^screen),screening,lemma
(?i)(?:in contact with|any one|co-worker|at work|(?:the|a)(?:wo)?man|(?:another|a) (?:pt|patient|pt\.)),other_experiencer,lemma
(?i)(?:patient|pt(?:\.)?|vt|veteran),patient,lemma
(?i)(?:like_num (?:days|day|weeks|week|months|month) (?:ago|prior)),timesx,lemma
(?i)(?:(?:antibody|antibodies|ab) test),antibody test,lemma
(?i)(?:(?:coronavirus|hcovs?|ncovs?|covs?)(?:\s)?(?:-)?(?:\s)?(?: infection)?(?: strain)?(?:\s)?(?:229(?:e)?|oc(?:-)?(?:43)?|o43|0c43|43|nl(?:16(?:3|5))?|hku(?:t|-)?1|hkui|emc|63)),OTHER_CORONAVIRUS,lemma
(?i)(?:(?:229(?:e)?|oc(?:-)?(?:43)?|o43|0c43|43|nl(?:16(?:3|5))?|hku(?:t|-)?1|hkui|emc|63) (?:coronavirus|hcovs?|ncovs?|covs?)),OTHER_CORONAVIRUS,lemma
(?i)(?:non(?:\s)?(?:-)?(?:\s)?(?:novel|covid|ncovid|covid-19)(?: coronavirus)?|other coronavirus),OTHER_CORONAVIRUS,lemma
(?i)(?:wife|husband|spouse|family|member|girlfriend|boyfriend|mother|father|nephew|niece|grandparent|grandparents|granddaughter|relative|relatives|caregiver),family,pos
(?i)(?:grandchild|grandson|cousin|grandmother|grandfather|parent|son|daughter|mom|dad|brother|sister|aunt|uncle|child|children|sibling|siblings),family,pos
(?i)(?:someone|somebody|person|anyone|anybody|people|individual|individuals|teacher|anybody|employees|employer|customer|client|residents),other_experiencer,pos
(?i)(?:resident|pts|patients|coworker|coworkers|workers|colleague|captain|captains|pilot|pilots|sailor|sailors|meeting),other_experiencer,pos
(?i)(?:boyfriend|persons|person|church|convention|guest|party|attendee|conference|roommate|friend|friends|coach|player|neighbor|manager|boss),other_experiencer,pos
(?i)(?:cashier|landlord|worked|works|^mate|nobody|mates|housemate|housemates|hotel|soldier|airport|tsa|lady|ladies|lobby|staffer|staffers),other_experiencer,pos
35 changes: 35 additions & 0 deletions nbs/banchmark/covid_data/rules_data/lemma_words.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
be
man
woman
have
do
emergency
epidemic
outbreak
crisis
breakout
pandemic
spread
confirm
person
patient
veteran
limit
reduce
factor
contact
case
lower
minimize
risk
chance
possibility
care
clean
desire
flight
trip
plan
reschedule
postpone
barrier
4 changes: 4 additions & 0 deletions nbs/banchmark/covid_data/rules_data/positive_section_tags.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
diagnoses
observation_and_plan
past_medical_history
problem_list
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.*pending.*#negated#no_negated
.*(?:should|unless|either|if comes back|if returns|if s?he tests positive).*#positive#uncertain
.*precaution.*#positive#no_future
.*(?:re[ -]?test|second test|repeat).*#negated#no_negated
.*(?:sign|symptom|s/s).*#positive#uncertain
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
(?i)(?:^(?:positive|detected)|results?(?: be)? positive),positive
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.*education.*#IGNORE
.* \?#IGNORE
(?=.*\b(?:deny|denies|denied)\b)(?=.*\b(?:contact|confirm)\b).*#IGNORE
(?=.*\b(?:setting of|s/o)\b)(?!.*\b(?:COVID-19 infection|COVID-19 ards)\b).*#no_positive
(?i)(.*benign.*)#uncertain
admitted to COVID-19 unit#positive
22 changes: 22 additions & 0 deletions nbs/banchmark/covid_data/rules_data/section_rules.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
(?i)(?:Lab results :),labs :
(?i)(?:Addendum :),addendum :
(?i)(?:(?:ALLERGIC REACTIONS|ALLERGIES) :),allergies :
(?i)(?:(?:CC|Chief Complaint) :),chief_complaint :
(?i)(?:COMMENTS :),comments :
(?i)(?:(?:(?:ADMISSION )?DIAGNOSES|Diagnosis|Primary Diagnosis|Primary|Secondary(?: (?:Diagnoses|Diagnosis))) :),diagnoses :
(?i)(?:(?:Brief Hospital Course|CONCISE SUMMARY OF HOSPITAL COURSE BY ISSUE/SYSTEM|HOSPITAL COURSE|SUMMARY OF HOSPITAL COURSE) :),hospital_course :
(?i)(?:(?:Imaging|MRI|INTERPRETATION|Radiology) :),imaging :
(?i)(?:(?:ADMISSION LABS|Discharge Labs|ECHO|Findings|INDICATION|Labs|Micro|Microbiology|Studies|Pertinent Results) :),labs_and_studies :
(?i)(?:(?:ACTIVE MEDICATIONS(?: LIST)|ADMISSION MEDICATIONS|CURRENT MEDICATIONS|DISCHARGE MEDICATIONS|HOME MEDICATIONS|MEDICATIONS) :),medications :
(?i)(?:(?:MEDICATIONS AT HOME|MEDICATIONS LIST|MEDICATIONS ON ADMISSION|MEDICATIONS ON DISCHARGE|MEDICATIONS ON TRANSFER|MEDICATIONS PRIOR TO ADMISSION) :),medications :
(?i)(?:Neuro :),neurological :
(?i)(?:(?:A/P|MEDICATIONS LIST|ASSESSMENT/PLAN|ASSESSMENT|Clinical Impression|DISCHARGE DIAGNOSES|DISCHARGE DIAGNOSIS) :),observation_and_plan :
(?i)(?:(?:Discharge Condition|Discharge Disposition|FINAL DIAGNOSES|FINAL DIAGNOSIS|IMPRESSION|Impression and Plan|Impression and Recommendation) :),observation_and_plan :
(?i)(?:(?:Facility|Service) :),other :
(?i)(?:(?:Current Medical Problems|History of Chronic Illness|MHx|PAST HISTORY|PAST MEDICAL Hx|PAST SURGICAL HISTORY|PMH|PMHx|PAST MEDICAL HISTORY|UNDERLYING MEDICAL CONDITION) :),past_medical_history :
(?i)(?:(?:Education|Patient Education|DISCHARGE INSTRUCTIONS/FOLLOWUP|DISCHARGE INSTRUCTIONS|Followup Instructions) :),patient_education :
(?i)(?:(?:PE|PHYSICAL EXAM|PHYSICAL EXAMINATION) :),physical_exam :
(?i)(?:(?:Active Problem List|Current Problems|Medical Problems|PROBLEM LIST) :),problem_list :
(?i)(?:REASON FOR THIS EXAMINATION :),reason_for_examination :
(?i)(?:(?:Electronic Signature|Signed electronically by) :),signature :
(?i)(?:(?:PMHSx|PSH|SH|Sexual History:|Social History) :),social_history :
111 changes: 111 additions & 0 deletions nbs/banchmark/covid_data/rules_data/section_tags.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
Lab results:,labs
ADDENDUM:,addendum
Addendum:,addendum
ALLERGIC REACTIONS:,allergies
ALLERGIES:,allergies
CC:,chief_complaint
CHIEF COMPLAINT:,chief_complaint
Chief Complaint:,chief_complaint
COMMENTS:,comments
ADMISSION DIAGNOSES:,diagnoses
DIAGNOSES:,diagnoses
Diagnosis:,diagnoses
Primary Diagnosis:,diagnoses
Primary:,diagnoses
SECONDARY DIAGNOSES:,diagnoses
Secondary Diagnoses:,diagnoses
Secondary Diagnosis:,diagnoses
Secondary:,diagnoses
Family History:,family_history
Brief Hospital Course:,hospital_course
CONCISE SUMMARY OF HOSPITAL COURSE BY ISSUE/SYSTEM:,hospital_course
HOSPITAL COURSE:,hospital_course
SUMMARY OF HOSPITAL COURSE:,hospital_course
IMAGING:,imaging
INTERPRETATION:,imaging
Imaging:,imaging
MRI:,imaging
Radiology:,imaging
ADMISSION LABS:,labs_and_studies
Admission Labs:,labs_and_studies
Discharge Labs:,labs_and_studies
ECHO:,labs_and_studies
FINDINGS:,labs_and_studies
Findings:,labs_and_studies
INDICATION:,labs_and_studies
LABS:,labs_and_studies
Labs:,labs_and_studies
MICRO:,labs_and_studies
Micro:,labs_and_studies
Microbiology:,labs_and_studies
Pertinent Results:,labs_and_studies
STUDIES:,labs_and_studies
Studies:,labs_and_studies
ACTIVE MEDICATIONS LIST:,medications
ACTIVE MEDICATIONS:,medications
ADMISSION MEDICATIONS:,medications
CURRENT MEDICATIONS:,medications
DISCHARGE MEDICATIONS:,medications
Discharge Medications:,medications
HOME MEDICATIONS:,medications
MEDICATIONS AT HOME:,medications
MEDICATIONS LIST:,medications
MEDICATIONS ON ADMISSION:,medications
MEDICATIONS ON DISCHARGE:,medications
MEDICATIONS ON TRANSFER:,medications
MEDICATIONS PRIOR TO ADMISSION:,medications
MEDICATIONS:,medications
MEDICATIONS:,medications
Neuro:,neurological
A/P:,observation_and_plan
ASSESSMENT/PLAN:,observation_and_plan
ASSESSMENT:,observation_and_plan
Assessment/Plan:,observation_and_plan
Clinical Impression:,observation_and_plan
DISCHARGE DIAGNOSES:,observation_and_plan
DISCHARGE DIAGNOSIS:,observation_and_plan
Discharge Condition:,observation_and_plan
Discharge Diagnoses:,observation_and_plan
Discharge Diagnosis:,observation_and_plan
Discharge Disposition:,observation_and_plan
FINAL DIAGNOSES:,observation_and_plan
FINAL DIAGNOSIS:,observation_and_plan
IMPRESSION:,observation_and_plan
Impression and Plan:,observation_and_plan
Impression and Recommendation:,observation_and_plan
Facility:,other
Service:,other
Current Medical Problems:,past_medical_history
History of Chronic Illness:,past_medical_history
MHx:,past_medical_history
PAST HISTORY:,past_medical_history
PAST MEDICAL HISTORY:,past_medical_history
PAST MEDICAL Hx:,past_medical_history
PAST SURGICAL HISTORY:,past_medical_history
PMH:,past_medical_history
PMHx:,past_medical_history
Past Medical History:,past_medical_history
UNDERLYING MEDICAL CONDITION:,past_medical_history
Education:,patient_education
Patient Education:,patient_education
DISCHARGE INSTRUCTIONS/FOLLOWUP:,patient_instructions
DISCHARGE INSTRUCTIONS:,patient_instructions
Discharge Instructions:,patient_instructions
Followup Instructions:,patient_instructions
PE:,physical_exam
PHYSICAL EXAM:,physical_exam
PHYSICAL EXAMINATION:,physical_exam
Physical Exam:,physical_exam
Active Problem List:,problem_list
Current Problems:,problem_list
Medical Problems:,problem_list
PROBLEM LIST:,problem_list
Problem List:,problem_list
REASON FOR THIS EXAMINATION:,reason_for_examination
Electronic Signature:,signature
Signed electronically by:,signature
PMHSx:,social_history
PSH:,social_history
SH:,social_history
Sexual History:,social_history
Social History:,social_history
Loading

0 comments on commit 6155ca0

Please sign in to comment.