awacke1 commited on
Commit
eda61c7
·
0 Parent(s):

Duplicate from awacke1/AI-ChatGPT-EACN

Browse files
Files changed (3) hide show
  1. .gitattributes +34 -0
  2. README.md +133 -0
  3. app.py +126 -0
.gitattributes ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
5
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
12
+ *.model filter=lfs diff=lfs merge=lfs -text
13
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
14
+ *.npy filter=lfs diff=lfs merge=lfs -text
15
+ *.npz filter=lfs diff=lfs merge=lfs -text
16
+ *.onnx filter=lfs diff=lfs merge=lfs -text
17
+ *.ot filter=lfs diff=lfs merge=lfs -text
18
+ *.parquet filter=lfs diff=lfs merge=lfs -text
19
+ *.pb filter=lfs diff=lfs merge=lfs -text
20
+ *.pickle filter=lfs diff=lfs merge=lfs -text
21
+ *.pkl filter=lfs diff=lfs merge=lfs -text
22
+ *.pt filter=lfs diff=lfs merge=lfs -text
23
+ *.pth filter=lfs diff=lfs merge=lfs -text
24
+ *.rar filter=lfs diff=lfs merge=lfs -text
25
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
26
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
27
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
28
+ *.tflite filter=lfs diff=lfs merge=lfs -text
29
+ *.tgz filter=lfs diff=lfs merge=lfs -text
30
+ *.wasm filter=lfs diff=lfs merge=lfs -text
31
+ *.xz filter=lfs diff=lfs merge=lfs -text
32
+ *.zip filter=lfs diff=lfs merge=lfs -text
33
+ *.zst filter=lfs diff=lfs merge=lfs -text
34
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,133 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ title: AI ChatGPT EACN
3
+ emoji: 🏃
4
+ colorFrom: yellow
5
+ colorTo: yellow
6
+ sdk: streamlit
7
+ sdk_version: 1.19.0
8
+ app_file: app.py
9
+ pinned: false
10
+ license: mit
11
+ duplicated_from: awacke1/AI-ChatGPT-EACN
12
+ ---
13
+
14
+ EACN - EDI, ADT, CCD, Note
15
+
16
+ ## EDI Sample with All DX and Services
17
+
18
+
19
+ EDI:
20
+
21
+
22
+ ISA*00* *00* *ZZ*EMRSENDER *ZZ*RECEIVER *230504*1345*^*00501*000000001*0*P*:~
23
+ GS*HS*EMRSENDER*RECEIVER*20230504*1345*1*X*005010X221A1~
24
+ ST*278*0001~
25
+ BHT*0078*11*100012345*20230504*1345~
26
+ HL*1**20*1~
27
+ NM1*X3*2*RECEIVER*****46*123456789~
28
+ HL*2*1*21*1~
29
+ NM1*1P*2*DOE*JANE****46*987654321~
30
+ HL*3*2*19*1~
31
+ TRN*1*100012345*987654321~
32
+ UM*HS*100012345*987654321~
33
+ HCR*A*1*ZZZ001~
34
+ HI*BF:7295:::3~
35
+ HI*BF:72148:::1~
36
+ HI*BF:72156:::1~
37
+ HI*BF:72158:::1~
38
+ HI*BF:S72.0:::1~
39
+ HI*BF:M16.10:::1~
40
+ SE*13*0001~
41
+ GE*1*1~
42
+ IEA*1*000000001~
43
+
44
+
45
+ ## ADT A08 Event
46
+
47
+ ADT:
48
+
49
+
50
+ MSH|^~\&|EMRSENDER|FACILITY_A|RECEIVER|FACILITY_A|20230504||ADT^A08^ADT_A01|0001|P|2.5
51
+ EVN|A08|20230504|||BROWN^SARAH|20230504
52
+ PID|||100012345^^^FACILITY_A^MRN||PATIENT^JOHN^M||||||||||||100012345
53
+ PV1||I|FLOOR^1001^1^FACILITY_A||||987654321^DOE^JANE|||||||||||||||||||||||||20230504
54
+ PV2|||^^^FACILITY_A|||||||||||||||||||||||||||||||||||||3
55
+ PV3|3|ICD10|S72.0^M16.10^Z96.649
56
+ PV4||O
57
+ AL1|1|||^^^72148^72156^72158
58
+ DG1|1|ICD10|S72.0|Fracture of neck of femur|20230504
59
+ DG1|2|ICD10|M16.10|Bilateral primary osteoarthritis of hip|20230504
60
+ ZCD|3|CPT|72148^72156^72158
61
+
62
+
63
+ ## Clinical Document
64
+
65
+ CCD:
66
+
67
+ Clinical Document
68
+
69
+ **Patient:** John Patient
70
+
71
+ **Date:** 2023-05-04
72
+
73
+ **Chief Complaint:**
74
+ John experienced a fall, resulting in a **hip injury**. The patient complains of severe pain and difficulty in walking.
75
+
76
+ **History of Present Illness:**
77
+ The patient has a history of **bilateral primary osteoarthritis of the hip (M16.10)**. The fall exacerbated the existing condition, causing **fracture of the neck of femur (S72.0)**.
78
+
79
+ **Physical Examination:**
80
+ Upon examination, the patient had severe pain, limited range of motion, and swelling of the affected hip. Imaging studies were ordered to assess the extent of the damage.
81
+
82
+ **Imaging Studies:**
83
+ 1. **MRI of the pelvis (CPT 72148)**
84
+ 2. **MRI of the bilateral hips (CPT 72156)**
85
+ 3. **MRI of the bilateral femurs (CPT 72158)**
86
+
87
+ The MRI scans revealed significant damage to the hip joint, confirming the **fracture of the neck of femur (S72.0)** and worsening of the **bilateral primary osteoarthritis of the hip (M16.10)**.
88
+
89
+ **Assessment:**
90
+ Based on the clinical findings and imaging results, it is evident that the patient requires immediate surgical intervention to repair the hip joint and prevent further complications.
91
+
92
+ **Plan:**
93
+ 1. Admit the patient to the hospital for surgical treatment.
94
+ 2. Perform an emergent **hip replacement surgery (Z96.649)** to repair the hip joint and restore function.
95
+ 3. Postoperative rehabilitation and physical therapy to regain strength and mobility.
96
+
97
+ **Medical Necessity:**
98
+ The emergent hip replacement surgery is medically necessary due to the following factors:
99
+ - Severe pain and functional impairment caused by the **fracture of the neck of femur (S72.0)**
100
+ - Worsening of pre-existing **bilateral primary osteoarthritis of the hip (M16.10)**
101
+ - High risk of complications if left untreated
102
+
103
+ Based on the clinical evidence, the patient's condition warrants immediate surgical intervention to alleviate pain, restore function, and prevent further complications. The surgery is deemed medically necessary to improve the patient's quality of life and long-term prognosis.
104
+
105
+ **Attending Physician:** Dr. Sarah Brown
106
+
107
+ ## Note and Summary Index by Code Type
108
+
109
+ | Code Value | Code Description | Code Type | Decision Relevance | Additional Information |
110
+ |------------|-----------------------------------------------|-----------------|------------------------------------|---------------------------------------------|
111
+ | 7295 | Authorization and Referral Services | EDI | Required for authorization | |
112
+ | 72148 | MRI of the pelvis | CPT | Medical necessity for imaging | |
113
+ | 72156 | MRI of the bilateral hips | CPT | Medical necessity for imaging | |
114
+ | 72158 | MRI of the bilateral femurs | CPT | Medical necessity for imaging | |
115
+ | S72.0 | Fracture of the neck of femur | ICD10 | Diagnosis, treatment decision | |
116
+ | M16.10 | Bilateral primary osteoarthritis of the hip | ICD10 | Diagnosis, treatment decision | |
117
+ | Z96.649 | Presence of unspecified artificial hip joint | ICD10 | Procedure, treatment decision | |
118
+ | A08 | Update Patient Information | ADT Event | Patient update after surgery | |
119
+ | 72148 | MRI of the pelvis | ZCD | Diagnostic code for imaging | |
120
+ | 72156 | MRI of the bilateral hips | ZCD | Diagnostic code for imaging | |
121
+ | 72158 | MRI of the bilateral femurs | ZCD | Diagnostic code for imaging | |
122
+ | 987654321 | Dr. Jane Doe - Initial Attending Physician | NPI | Patient care provider | Taxonomy: 207Q00000X (Family Medicine) |
123
+ | 123456789 | Dr. Robert Smith - Second Attending Physician | NPI | Patient care provider | Taxonomy: 207Q00000X (Family Medicine) |
124
+ | 000000001 | Dr. Sarah Brown - Surgeon | NPI | Patient care provider, surgery | Taxonomy: 207XS0106X (Orthopedic Surgery) |
125
+ | 555444333 | Facility A | Facility NPI | Patient care facility | Name: Facility A |
126
+ | | | Facility Address| | Address: 123 Main St, City, State, Zip Code |
127
+ | J7325 | Hyaluronan or derivative, Synvisc or Synvisc-One, for intra-articular injection, 1 mg | HCPCS | Medication used during treatment | |
128
+ | Q4081 | Injection, dexamethasone sodium phosphate, 1 mg | HCPCS | Medication used during treatment | |
129
+ | 99238 | Hospital discharge day management, 30 minutes or less | CPT | Follow-up plan | |
130
+ | 99239 | Hospital discharge day management, more than 30 minutes | CPT | Follow-up plan | |
131
+
132
+
133
+
app.py ADDED
@@ -0,0 +1,126 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import streamlit as st
2
+
3
+ st.set_page_config(layout="wide")
4
+
5
+ st.markdown("""
6
+ EACN - EDI, ADT, CCD, Note
7
+
8
+ ## EDI Sample with All DX and Services
9
+
10
+
11
+ EDI:
12
+
13
+
14
+ ISA*00* *00* *ZZ*EMRSENDER *ZZ*RECEIVER *230504*1345*^*00501*000000001*0*P*:~
15
+ GS*HS*EMRSENDER*RECEIVER*20230504*1345*1*X*005010X221A1~
16
+ ST*278*0001~
17
+ BHT*0078*11*100012345*20230504*1345~
18
+ HL*1**20*1~
19
+ NM1*X3*2*RECEIVER*****46*123456789~
20
+ HL*2*1*21*1~
21
+ NM1*1P*2*DOE*JANE****46*987654321~
22
+ HL*3*2*19*1~
23
+ TRN*1*100012345*987654321~
24
+ UM*HS*100012345*987654321~
25
+ HCR*A*1*ZZZ001~
26
+ HI*BF:7295:::3~
27
+ HI*BF:72148:::1~
28
+ HI*BF:72156:::1~
29
+ HI*BF:72158:::1~
30
+ HI*BF:S72.0:::1~
31
+ HI*BF:M16.10:::1~
32
+ SE*13*0001~
33
+ GE*1*1~
34
+ IEA*1*000000001~
35
+
36
+
37
+ ## ADT A08 Event
38
+
39
+ ADT:
40
+
41
+
42
+ MSH|^~\&|EMRSENDER|FACILITY_A|RECEIVER|FACILITY_A|20230504||ADT^A08^ADT_A01|0001|P|2.5
43
+ EVN|A08|20230504|||BROWN^SARAH|20230504
44
+ PID|||100012345^^^FACILITY_A^MRN||PATIENT^JOHN^M||||||||||||100012345
45
+ PV1||I|FLOOR^1001^1^FACILITY_A||||987654321^DOE^JANE|||||||||||||||||||||||||20230504
46
+ PV2|||^^^FACILITY_A|||||||||||||||||||||||||||||||||||||3
47
+ PV3|3|ICD10|S72.0^M16.10^Z96.649
48
+ PV4||O
49
+ AL1|1|||^^^72148^72156^72158
50
+ DG1|1|ICD10|S72.0|Fracture of neck of femur|20230504
51
+ DG1|2|ICD10|M16.10|Bilateral primary osteoarthritis of hip|20230504
52
+ ZCD|3|CPT|72148^72156^72158
53
+
54
+
55
+ ## Clinical Document
56
+
57
+ CCD:
58
+
59
+ Clinical Document
60
+
61
+ **Patient:** John Patient
62
+
63
+ **Date:** 2023-05-04
64
+
65
+ **Chief Complaint:**
66
+ John experienced a fall, resulting in a **hip injury**. The patient complains of severe pain and difficulty in walking.
67
+
68
+ **History of Present Illness:**
69
+ The patient has a history of **bilateral primary osteoarthritis of the hip (M16.10)**. The fall exacerbated the existing condition, causing **fracture of the neck of femur (S72.0)**.
70
+
71
+ **Physical Examination:**
72
+ Upon examination, the patient had severe pain, limited range of motion, and swelling of the affected hip. Imaging studies were ordered to assess the extent of the damage.
73
+
74
+ **Imaging Studies:**
75
+ 1. **MRI of the pelvis (CPT 72148)**
76
+ 2. **MRI of the bilateral hips (CPT 72156)**
77
+ 3. **MRI of the bilateral femurs (CPT 72158)**
78
+
79
+ The MRI scans revealed significant damage to the hip joint, confirming the **fracture of the neck of femur (S72.0)** and worsening of the **bilateral primary osteoarthritis of the hip (M16.10)**.
80
+
81
+ **Assessment:**
82
+ Based on the clinical findings and imaging results, it is evident that the patient requires immediate surgical intervention to repair the hip joint and prevent further complications.
83
+
84
+ **Plan:**
85
+ 1. Admit the patient to the hospital for surgical treatment.
86
+ 2. Perform an emergent **hip replacement surgery (Z96.649)** to repair the hip joint and restore function.
87
+ 3. Postoperative rehabilitation and physical therapy to regain strength and mobility.
88
+
89
+ **Medical Necessity:**
90
+ The emergent hip replacement surgery is medically necessary due to the following factors:
91
+ - Severe pain and functional impairment caused by the **fracture of the neck of femur (S72.0)**
92
+ - Worsening of pre-existing **bilateral primary osteoarthritis of the hip (M16.10)**
93
+ - High risk of complications if left untreated
94
+
95
+ Based on the clinical evidence, the patient's condition warrants immediate surgical intervention to alleviate pain, restore function, and prevent further complications. The surgery is deemed medically necessary to improve the patient's quality of life and long-term prognosis.
96
+
97
+ **Attending Physician:** Dr. Sarah Brown
98
+
99
+ ## Note and Summary Index by Code Type
100
+
101
+ | Code Value | Code Description | Code Type | Decision Relevance | Additional Information |
102
+ |------------|-----------------------------------------------|-----------------|------------------------------------|---------------------------------------------|
103
+ | 7295 | Authorization and Referral Services | EDI | Required for authorization | |
104
+ | 72148 | MRI of the pelvis | CPT | Medical necessity for imaging | |
105
+ | 72156 | MRI of the bilateral hips | CPT | Medical necessity for imaging | |
106
+ | 72158 | MRI of the bilateral femurs | CPT | Medical necessity for imaging | |
107
+ | S72.0 | Fracture of the neck of femur | ICD10 | Diagnosis, treatment decision | |
108
+ | M16.10 | Bilateral primary osteoarthritis of the hip | ICD10 | Diagnosis, treatment decision | |
109
+ | Z96.649 | Presence of unspecified artificial hip joint | ICD10 | Procedure, treatment decision | |
110
+ | A08 | Update Patient Information | ADT Event | Patient update after surgery | |
111
+ | 72148 | MRI of the pelvis | ZCD | Diagnostic code for imaging | |
112
+ | 72156 | MRI of the bilateral hips | ZCD | Diagnostic code for imaging | |
113
+ | 72158 | MRI of the bilateral femurs | ZCD | Diagnostic code for imaging | |
114
+ | 987654321 | Dr. Jane Doe - Initial Attending Physician | NPI | Patient care provider | Taxonomy: 207Q00000X (Family Medicine) |
115
+ | 123456789 | Dr. Robert Smith - Second Attending Physician | NPI | Patient care provider | Taxonomy: 207Q00000X (Family Medicine) |
116
+ | 000000001 | Dr. Sarah Brown - Surgeon | NPI | Patient care provider, surgery | Taxonomy: 207XS0106X (Orthopedic Surgery) |
117
+ | 555444333 | Facility A | Facility NPI | Patient care facility | Name: Facility A |
118
+ | | | Facility Address| | Address: 123 Main St, City, State, Zip Code |
119
+ | J7325 | Hyaluronan or derivative, Synvisc or Synvisc-One, for intra-articular injection, 1 mg | HCPCS | Medication used during treatment | |
120
+ | Q4081 | Injection, dexamethasone sodium phosphate, 1 mg | HCPCS | Medication used during treatment | |
121
+ | 99238 | Hospital discharge day management, 30 minutes or less | CPT | Follow-up plan | |
122
+ | 99239 | Hospital discharge day management, more than 30 minutes | CPT | Follow-up plan | |
123
+
124
+
125
+
126
+ """)