awacke1 commited on
Commit
bb2c28c
Β·
1 Parent(s): 91273a0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -18
app.py CHANGED
@@ -2,11 +2,9 @@ import streamlit as st
2
 
3
  # Set the page configuration to use the full width of the screen
4
  st.set_page_config(layout="wide")
5
- st.markdown("""
6
-
7
-
8
- ## Content for Letter Generator AI UI UX
9
 
 
 
10
  | πŸ₯ **Letter Type** | πŸ“ **Definition** | πŸ“‹ **Fields Usually Needed** |
11
  |-----------------------|-----------------------------------------|-----------------------------|
12
  | 1️⃣ Referral Letters | 🀝 Letters asking for more help or treatment | πŸ“„ Patient info, Referral details |
@@ -19,15 +17,10 @@ st.markdown("""
19
  | 8️⃣ Follow-up Appointment Letters | πŸ“… Letters reminding about appointments | πŸ“„ Patient info, Appointment details |
20
  | 9️⃣ Disability Support Letters | β™Ώ Letters about a patient's disability | πŸ“„ Patient info, Disability details |
21
  | πŸ”Ÿ Health Education Letters | 🍎 Letters teaching about health | πŸ“„ Patient info, Education topic |
22
-
23
  """)
24
 
25
-
26
-
27
-
28
  RL="""
29
  ### 🀝 Referral Letters
30
-
31
  | **Referral Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
32
  |---------------------|------------------------------------|---------------------------------------|--------------------------------------|
33
  | πŸ“¨ State the request for consultation/treatment | - Urgent need for further diagnostic testing for Mrs. Smith, who has persistent stomach issues 🀒 | - The patient has symptoms that suggest a more comprehensive review is required πŸ” | - Patient demographics, Referral details πŸ—‚οΈ |
@@ -36,7 +29,6 @@ RL="""
36
 
37
  MCL="""
38
  ### πŸ“œ Medical Certificate Letters
39
-
40
  | **Medical Certificate Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
41
  |--------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
42
  | πŸ“¨ State the reason for certification | - To certify Mr. Brown's condition and advise on work restrictions πŸ’Ό | - Mr. Brown has suffered from a heart attack and is under medication πŸ’”πŸ’Š | - No driving should be allowed for 6 months πŸš«πŸš— |
@@ -45,7 +37,6 @@ MCL="""
45
 
46
  PL="""
47
  ### πŸ’Š Prescription Letters
48
-
49
  | **Prescription Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
50
  |-------------------------|------------------------------------|---------------------------------------|--------------------------------------|
51
  | πŸ“¨ Introduce prescription request | - Request for prescription for Mr. Clarke πŸ’Š | - Mr. Clarke requires medication for hypertension - Lisinopril 10mg BD with food 🩺 | - Medication details, allergies and any known side effects 🚫 |
@@ -63,7 +54,6 @@ DL="""
63
 
64
  TPL="""
65
  ### 🩹 Treatment Plan Letters
66
-
67
  | **Treatment Plan Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
68
  |---------------------------|------------------------------------|---------------------------------------|--------------------------------------|
69
  | πŸ“¨ Introduce treatment plan | - Outline treatment and testing plan for Mr. Smith πŸ“‹ | - Mr. Smith's treatment will involve IV medication and chest x-ray πŸ’‰πŸ“Έ | - Recommend follow-up visits for monitoring and periodic testing πŸ“† |
@@ -72,7 +62,6 @@ TPL="""
72
 
73
  SRL="""
74
  ### πŸ₯ Surgery Recommendation Letters
75
-
76
  | **Surgery Recommendation Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
77
  |-----------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
78
  | πŸ“¨ Introduce surgical procedure | - Recommend endoscopy procedure for Mr. Baker πŸ”¬ | - Mr. Baker needs endoscopy for the diagnosis of GI tract abnormalities 🫁 | - Suggest to take extra measures regarding allergies or post-procedural appointments πŸš«βš•οΈ |
@@ -81,7 +70,6 @@ SRL="""
81
 
82
  MCL="""
83
  ### πŸƒβ€β™‚οΈ Medical Clearance Letters
84
-
85
  | **Medical Clearance Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
86
  |-------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
87
  | πŸ“¨ State clearance conditions | - Allow Mrs. Anderson to safely participate in a marathon πŸƒβ€β™€οΈ | - The patient has been tested and has no chronic medical conditions or injuries 🚫🩺 | - Encourage gradual progression and cautious approach to intense activity πŸ“ˆ |
@@ -90,7 +78,6 @@ MCL="""
90
 
91
  FAL="""
92
  ### πŸ“… Follow-up Appointment Letters
93
-
94
  | **Follow-up Appointment Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
95
  |-----------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
96
  | πŸ“¨ Remind of the appointment | - This is a reminder for Mrs. Rodriguez's appointment on Friday, 17th September, at 11:00 am πŸ“† | - Review the date, time, and location of appointment πŸ“ | - Provide contact information and phone numbers in case of schedule change or emergency ☎️ |
@@ -99,7 +86,6 @@ FAL="""
99
 
100
  DSL="""
101
  ### β™Ώ Disability Support Letters
102
-
103
  | **Disability Support Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
104
  |--------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
105
  | πŸ“¨ State the purpose of the letter | - The purpose of this letter is to validate Mr. Williams' disability so that he can receive disability benefits β™Ώ | - Detail the patient's physical or cognitive condition and how it affects their daily life 🧠 | - Outline the assistive equipment or technology necessary for the patient πŸ› οΈ |
@@ -108,14 +94,12 @@ DSL="""
108
 
109
  HEL="""
110
  ### 🍎 Health Education Letters
111
-
112
  | **Health Education Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
113
  |------------------------------|---------------------------------|------------------------------------|-----------------------------------|
114
  | 🍎 Introduce the health education topic | - This letter is to provide Ms. Prince with information on healthy eating habits πŸ₯— | - Outline the benefits of specific health practices for overall health 🌟 | - Provide handouts, online resources, or any relevant materials to supplement the information πŸ“š |
115
  | | - This letter offers suggestions for stress management to Mr. Martin 😌 | - Detail steps that can be taken to manage specific health conditions properly πŸšΆβ€β™€οΈ | - Encourage patients to schedule follow-up appointments to discuss any questions or concerns πŸ—“οΈ |
116
  """
117
 
118
-
119
  def generate_letter_menu_ui():
120
  st.title("πŸ₯ Letter Type Selection")
121
 
 
2
 
3
  # Set the page configuration to use the full width of the screen
4
  st.set_page_config(layout="wide")
 
 
 
 
5
 
6
+ st.markdown("""
7
+ ## Generative AI for Letters - Managing Information Overload (GAL-MIO)
8
  | πŸ₯ **Letter Type** | πŸ“ **Definition** | πŸ“‹ **Fields Usually Needed** |
9
  |-----------------------|-----------------------------------------|-----------------------------|
10
  | 1️⃣ Referral Letters | 🀝 Letters asking for more help or treatment | πŸ“„ Patient info, Referral details |
 
17
  | 8️⃣ Follow-up Appointment Letters | πŸ“… Letters reminding about appointments | πŸ“„ Patient info, Appointment details |
18
  | 9️⃣ Disability Support Letters | β™Ώ Letters about a patient's disability | πŸ“„ Patient info, Disability details |
19
  | πŸ”Ÿ Health Education Letters | 🍎 Letters teaching about health | πŸ“„ Patient info, Education topic |
 
20
  """)
21
 
 
 
 
22
  RL="""
23
  ### 🀝 Referral Letters
 
24
  | **Referral Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
25
  |---------------------|------------------------------------|---------------------------------------|--------------------------------------|
26
  | πŸ“¨ State the request for consultation/treatment | - Urgent need for further diagnostic testing for Mrs. Smith, who has persistent stomach issues 🀒 | - The patient has symptoms that suggest a more comprehensive review is required πŸ” | - Patient demographics, Referral details πŸ—‚οΈ |
 
29
 
30
  MCL="""
31
  ### πŸ“œ Medical Certificate Letters
 
32
  | **Medical Certificate Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
33
  |--------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
34
  | πŸ“¨ State the reason for certification | - To certify Mr. Brown's condition and advise on work restrictions πŸ’Ό | - Mr. Brown has suffered from a heart attack and is under medication πŸ’”πŸ’Š | - No driving should be allowed for 6 months πŸš«πŸš— |
 
37
 
38
  PL="""
39
  ### πŸ’Š Prescription Letters
 
40
  | **Prescription Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
41
  |-------------------------|------------------------------------|---------------------------------------|--------------------------------------|
42
  | πŸ“¨ Introduce prescription request | - Request for prescription for Mr. Clarke πŸ’Š | - Mr. Clarke requires medication for hypertension - Lisinopril 10mg BD with food 🩺 | - Medication details, allergies and any known side effects 🚫 |
 
54
 
55
  TPL="""
56
  ### 🩹 Treatment Plan Letters
 
57
  | **Treatment Plan Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
58
  |---------------------------|------------------------------------|---------------------------------------|--------------------------------------|
59
  | πŸ“¨ Introduce treatment plan | - Outline treatment and testing plan for Mr. Smith πŸ“‹ | - Mr. Smith's treatment will involve IV medication and chest x-ray πŸ’‰πŸ“Έ | - Recommend follow-up visits for monitoring and periodic testing πŸ“† |
 
62
 
63
  SRL="""
64
  ### πŸ₯ Surgery Recommendation Letters
 
65
  | **Surgery Recommendation Letter** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
66
  |-----------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
67
  | πŸ“¨ Introduce surgical procedure | - Recommend endoscopy procedure for Mr. Baker πŸ”¬ | - Mr. Baker needs endoscopy for the diagnosis of GI tract abnormalities 🫁 | - Suggest to take extra measures regarding allergies or post-procedural appointments πŸš«βš•οΈ |
 
70
 
71
  MCL="""
72
  ### πŸƒβ€β™‚οΈ Medical Clearance Letters
 
73
  | **Medical Clearance Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
74
  |-------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
75
  | πŸ“¨ State clearance conditions | - Allow Mrs. Anderson to safely participate in a marathon πŸƒβ€β™€οΈ | - The patient has been tested and has no chronic medical conditions or injuries 🚫🩺 | - Encourage gradual progression and cautious approach to intense activity πŸ“ˆ |
 
78
 
79
  FAL="""
80
  ### πŸ“… Follow-up Appointment Letters
 
81
  | **Follow-up Appointment Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
82
  |-----------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
83
  | πŸ“¨ Remind of the appointment | - This is a reminder for Mrs. Rodriguez's appointment on Friday, 17th September, at 11:00 am πŸ“† | - Review the date, time, and location of appointment πŸ“ | - Provide contact information and phone numbers in case of schedule change or emergency ☎️ |
 
86
 
87
  DSL="""
88
  ### β™Ώ Disability Support Letters
 
89
  | **Disability Support Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
90
  |--------------------------------|------------------------------------|---------------------------------------|--------------------------------------|
91
  | πŸ“¨ State the purpose of the letter | - The purpose of this letter is to validate Mr. Williams' disability so that he can receive disability benefits β™Ώ | - Detail the patient's physical or cognitive condition and how it affects their daily life 🧠 | - Outline the assistive equipment or technology necessary for the patient πŸ› οΈ |
 
94
 
95
  HEL="""
96
  ### 🍎 Health Education Letters
 
97
  | **Health Education Letters** | πŸ“ **First** | πŸ“ **Middle** | πŸ“ **Last** |
98
  |------------------------------|---------------------------------|------------------------------------|-----------------------------------|
99
  | 🍎 Introduce the health education topic | - This letter is to provide Ms. Prince with information on healthy eating habits πŸ₯— | - Outline the benefits of specific health practices for overall health 🌟 | - Provide handouts, online resources, or any relevant materials to supplement the information πŸ“š |
100
  | | - This letter offers suggestions for stress management to Mr. Martin 😌 | - Detail steps that can be taken to manage specific health conditions properly πŸšΆβ€β™€οΈ | - Encourage patients to schedule follow-up appointments to discuss any questions or concerns πŸ—“οΈ |
101
  """
102
 
 
103
  def generate_letter_menu_ui():
104
  st.title("πŸ₯ Letter Type Selection")
105