Spaces:
Sleeping
Sleeping
Alex Amari Claude Opus 4.6 commited on
Commit Β·
d990b8a
1
Parent(s): 5eb5d20
Add Resources tab with CT hospital financial assistance info
Browse filesWraps the existing screener flow and a new Resources page in gr.Tabs.
The Resources tab covers eligibility, application process, patient
rights, and OHA contact information.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
app.py
CHANGED
|
@@ -984,6 +984,38 @@ hr {
|
|
| 984 |
border-radius: 4px !important;
|
| 985 |
}
|
| 986 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 987 |
/* ---------- MOBILE ---------- */
|
| 988 |
@media (max-width: 640px) {
|
| 989 |
.gradio-container { padding: 0 12px !important; }
|
|
@@ -1056,100 +1088,155 @@ def create_interface():
|
|
| 1056 |
container=False
|
| 1057 |
)
|
| 1058 |
|
| 1059 |
-
|
| 1060 |
-
|
| 1061 |
-
|
| 1062 |
-
|
| 1063 |
-
|
| 1064 |
-
|
| 1065 |
-
|
| 1066 |
-
|
|
|
|
|
|
|
| 1067 |
|
| 1068 |
-
|
| 1069 |
-
|
| 1070 |
-
|
| 1071 |
-
|
| 1072 |
-
|
| 1073 |
-
|
| 1074 |
-
|
| 1075 |
-
|
| 1076 |
-
|
| 1077 |
-
|
| 1078 |
-
|
| 1079 |
-
|
| 1080 |
-
|
| 1081 |
-
|
| 1082 |
-
|
| 1083 |
-
|
| 1084 |
-
|
| 1085 |
-
|
| 1086 |
-
|
| 1087 |
-
|
| 1088 |
-
|
| 1089 |
-
|
| 1090 |
-
|
| 1091 |
-
|
| 1092 |
-
|
| 1093 |
-
|
| 1094 |
-
|
| 1095 |
-
|
| 1096 |
-
|
| 1097 |
-
|
| 1098 |
-
|
| 1099 |
-
|
| 1100 |
-
|
| 1101 |
-
|
| 1102 |
-
|
| 1103 |
-
|
| 1104 |
-
|
| 1105 |
-
|
| 1106 |
-
|
| 1107 |
-
|
| 1108 |
-
|
| 1109 |
-
|
| 1110 |
-
|
| 1111 |
-
|
| 1112 |
-
|
| 1113 |
-
|
| 1114 |
-
|
| 1115 |
-
|
| 1116 |
-
|
| 1117 |
-
|
| 1118 |
-
|
| 1119 |
-
|
| 1120 |
-
|
| 1121 |
-
|
| 1122 |
-
|
| 1123 |
-
|
| 1124 |
-
|
| 1125 |
-
|
| 1126 |
-
|
| 1127 |
-
|
| 1128 |
-
|
| 1129 |
-
|
| 1130 |
-
|
| 1131 |
-
|
| 1132 |
-
|
| 1133 |
-
|
| 1134 |
-
)
|
| 1135 |
|
| 1136 |
-
|
| 1137 |
-
|
| 1138 |
-
|
| 1139 |
-
|
| 1140 |
-
|
| 1141 |
-
|
| 1142 |
-
|
| 1143 |
-
|
| 1144 |
-
|
| 1145 |
-
|
| 1146 |
-
|
| 1147 |
-
|
| 1148 |
-
|
| 1149 |
-
|
| 1150 |
-
|
| 1151 |
-
|
| 1152 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1153 |
|
| 1154 |
# --- Navigation functions ---
|
| 1155 |
|
|
|
|
| 984 |
border-radius: 4px !important;
|
| 985 |
}
|
| 986 |
|
| 987 |
+
/* ---------- RESOURCES TAB ---------- */
|
| 988 |
+
.resources-tab {
|
| 989 |
+
max-width: 820px;
|
| 990 |
+
padding: 24px 8px !important;
|
| 991 |
+
line-height: 1.75 !important;
|
| 992 |
+
}
|
| 993 |
+
.resources-tab h2 {
|
| 994 |
+
margin-top: 1.5rem !important;
|
| 995 |
+
}
|
| 996 |
+
.resources-tab ul {
|
| 997 |
+
padding-left: 1.25rem;
|
| 998 |
+
margin: 0.5rem 0 1rem 0;
|
| 999 |
+
}
|
| 1000 |
+
.resources-tab li {
|
| 1001 |
+
margin-bottom: 0.35rem;
|
| 1002 |
+
}
|
| 1003 |
+
|
| 1004 |
+
/* ---------- TABS ---------- */
|
| 1005 |
+
.gr-tab-nav {
|
| 1006 |
+
border-bottom: 2px solid #E0E0E0 !important;
|
| 1007 |
+
margin-bottom: 8px !important;
|
| 1008 |
+
}
|
| 1009 |
+
.gr-tab-nav button {
|
| 1010 |
+
font-size: 15px !important;
|
| 1011 |
+
font-weight: 500 !important;
|
| 1012 |
+
padding: 10px 20px !important;
|
| 1013 |
+
}
|
| 1014 |
+
.gr-tab-nav button.selected {
|
| 1015 |
+
border-bottom: 3px solid #0046AD !important;
|
| 1016 |
+
color: #0046AD !important;
|
| 1017 |
+
}
|
| 1018 |
+
|
| 1019 |
/* ---------- MOBILE ---------- */
|
| 1020 |
@media (max-width: 640px) {
|
| 1021 |
.gradio-container { padding: 0 12px !important; }
|
|
|
|
| 1088 |
container=False
|
| 1089 |
)
|
| 1090 |
|
| 1091 |
+
with gr.Tabs():
|
| 1092 |
+
with gr.Tab("Screener"):
|
| 1093 |
+
# Google Maps embed
|
| 1094 |
+
gr.HTML(
|
| 1095 |
+
'<div class="map-embed" style="margin-top:1rem;">'
|
| 1096 |
+
'<iframe src="https://www.google.com/maps/d/u/0/embed?mid=1UVO9r7ZS26kZr8Q62dY0147v3Milu_s&ll=41.508444988744984%2C-72.7719992&z=9" '
|
| 1097 |
+
'width="100%" height="480" style="border:0; border-radius: 6px;" '
|
| 1098 |
+
'allowfullscreen="" loading="lazy" title="Map: Connecticut Hospital Locations"></iframe>'
|
| 1099 |
+
'</div>'
|
| 1100 |
+
)
|
| 1101 |
|
| 1102 |
+
# Step 1: Choose path
|
| 1103 |
+
step1 = gr.Group(visible=True, elem_classes="step-group")
|
| 1104 |
+
with step1:
|
| 1105 |
+
gr.Markdown("### How would you like to start?")
|
| 1106 |
+
with gr.Row():
|
| 1107 |
+
help_btn = gr.Button("Find a Hospital by ZIP Code", variant="primary", size="lg")
|
| 1108 |
+
know_btn = gr.Button("I Know My Hospital", variant="secondary", size="lg")
|
| 1109 |
+
|
| 1110 |
+
# Step 2a: Find hospital by ZIP
|
| 1111 |
+
step2a = gr.Group(visible=False, elem_classes="step-group")
|
| 1112 |
+
with step2a:
|
| 1113 |
+
gr.Markdown("### Enter your ZIP code")
|
| 1114 |
+
zip_input = gr.Textbox(label="ZIP Code", placeholder="e.g., 06511", max_lines=1)
|
| 1115 |
+
num_hospitals_slider = gr.Slider(
|
| 1116 |
+
minimum=3, maximum=9, value=5, step=1,
|
| 1117 |
+
label="Number of hospitals to show"
|
| 1118 |
+
)
|
| 1119 |
+
search_btn = gr.Button("Search", variant="primary")
|
| 1120 |
+
|
| 1121 |
+
nearby_cards = gr.Markdown()
|
| 1122 |
+
hospital_radio = gr.Radio(label="Select a hospital", choices=[], visible=False)
|
| 1123 |
+
continue_btn_a = gr.Button("Continue", variant="primary", visible=False)
|
| 1124 |
+
back_btn_a = gr.Button("Back", size="sm")
|
| 1125 |
+
|
| 1126 |
+
# Step 2b: Select known hospital
|
| 1127 |
+
step2b = gr.Group(visible=False, elem_classes="step-group")
|
| 1128 |
+
with step2b:
|
| 1129 |
+
gr.Markdown("### Select your hospital")
|
| 1130 |
+
hospital_dropdown = gr.Dropdown(
|
| 1131 |
+
choices=list(HOSPITALS.keys()),
|
| 1132 |
+
label="Hospital"
|
| 1133 |
+
)
|
| 1134 |
+
continue_btn_b = gr.Button("Continue", variant="primary")
|
| 1135 |
+
back_btn_b = gr.Button("Back", size="sm")
|
| 1136 |
+
|
| 1137 |
+
# Step 3: Eligibility form
|
| 1138 |
+
step3 = gr.Group(visible=False, elem_classes="step-group")
|
| 1139 |
+
with step3:
|
| 1140 |
+
selected_hospital_display = gr.Markdown()
|
| 1141 |
+
|
| 1142 |
+
income_input = gr.Number(label="Annual Household Income ($)", minimum=1, value=35000)
|
| 1143 |
+
household_input = gr.Number(label="Household Size", minimum=1, value=3, precision=0)
|
| 1144 |
+
snap_radio = gr.Radio(choices=["Yes", "No"], label="Enrolled in SNAP or WIC?", value="No")
|
| 1145 |
+
insurance_radio = gr.Radio(choices=["Yes", "No"], label="Do you have health insurance?", value="No")
|
| 1146 |
+
|
| 1147 |
+
check_btn = gr.Button("Check Eligibility", variant="primary", size="lg")
|
| 1148 |
+
back_btn_c = gr.Button("Back", size="sm")
|
| 1149 |
+
|
| 1150 |
+
# Step 4: Results (with streaming) + follow-up chat
|
| 1151 |
+
step4 = gr.Group(visible=False, elem_classes="step-group")
|
| 1152 |
+
with step4:
|
| 1153 |
+
results_output = gr.Markdown(elem_classes="results-area")
|
| 1154 |
+
with gr.Row():
|
| 1155 |
+
restart_btn = gr.Button("Check Another Hospital", variant="secondary")
|
| 1156 |
+
download_btn = gr.Button("Download Results", variant="secondary")
|
| 1157 |
+
download_file = gr.File(visible=False, label="Download")
|
| 1158 |
+
|
| 1159 |
+
# --- Follow-up chat section ---
|
| 1160 |
+
gr.HTML('<hr style="border:none; border-top:1px solid #E0E0E0; margin:1.5rem 0 1rem 0;">')
|
| 1161 |
+
gr.Markdown("### Follow-Up Questions")
|
| 1162 |
+
gr.Markdown("Have additional questions? Ask about eligibility, the application process, required documents, or appeal rights.")
|
| 1163 |
+
|
| 1164 |
+
chatbot = gr.Chatbot(
|
| 1165 |
+
label="Conversation",
|
| 1166 |
+
height=350,
|
| 1167 |
+
)
|
|
|
|
| 1168 |
|
| 1169 |
+
# Suggested prompt buttons (pill-shaped via CSS)
|
| 1170 |
+
with gr.Row(elem_classes="prompt-pill"):
|
| 1171 |
+
prompt_btn_1 = gr.Button("What documents do I need to apply?", size="sm")
|
| 1172 |
+
prompt_btn_2 = gr.Button("Can I appeal if I'm denied?", size="sm")
|
| 1173 |
+
with gr.Row(elem_classes="prompt-pill"):
|
| 1174 |
+
prompt_btn_3 = gr.Button("Does this cover emergency visits?", size="sm")
|
| 1175 |
+
prompt_btn_4 = gr.Button("How do I contact the financial assistance office?", size="sm")
|
| 1176 |
+
|
| 1177 |
+
with gr.Row():
|
| 1178 |
+
chat_input = gr.Textbox(
|
| 1179 |
+
label="Your question",
|
| 1180 |
+
placeholder="Type your question here...",
|
| 1181 |
+
max_lines=2,
|
| 1182 |
+
scale=4,
|
| 1183 |
+
)
|
| 1184 |
+
chat_send_btn = gr.Button("Send", variant="primary", scale=1)
|
| 1185 |
+
chat_limit_msg = gr.Markdown(visible=False)
|
| 1186 |
+
|
| 1187 |
+
with gr.Tab("Resources"):
|
| 1188 |
+
gr.Markdown("""
|
| 1189 |
+
## What Is Hospital Financial Assistance in Connecticut?
|
| 1190 |
+
|
| 1191 |
+
Most Connecticut hospitals offer discounts or complete bill forgiveness based on your income and household size. This is called "hospital financial assistance," sometimes referred to as "charity care." A hospital bill for $15,000 could become $150 β or even $0. The Connecticut Office of the Healthcare Advocate can help you understand your options and navigate the process.
|
| 1192 |
+
|
| 1193 |
+
---
|
| 1194 |
+
|
| 1195 |
+
## Connecticut law sets a strong baseline β but hospitals can be even more generous
|
| 1196 |
+
|
| 1197 |
+
Connecticut **Public Act 24-81** requires hospitals to provide financial assistance to patients enrolled in **SNAP or WIC** whose household income is at or below **250% of the Federal Poverty Level (FPL)** β regardless of immigration status. That's currently about $51,100 for a family of two. Beyond this legal floor, most hospitals have their own policies that may cover patients at higher income levels or with different circumstances.
|
| 1198 |
+
|
| 1199 |
+
---
|
| 1200 |
+
|
| 1201 |
+
## Who Qualifies?
|
| 1202 |
+
|
| 1203 |
+
Under Connecticut law, you are **guaranteed** financial assistance if you receive SNAP or WIC benefits and your income is verified at or below 250% FPL. Many Connecticut hospitals go further and offer discounts to households earning significantly more than this threshold.
|
| 1204 |
+
|
| 1205 |
+
These examples give a general sense of who may qualify across Connecticut hospitals β individual hospitals may be more generous:
|
| 1206 |
+
|
| 1207 |
+
- **Household of 1** making up to ~$37,000 (250% FPL)
|
| 1208 |
+
- **Household of 2** making up to ~$51,100
|
| 1209 |
+
- **Household of 3** making up to ~$64,300
|
| 1210 |
+
- **Household of 4** making up to ~$77,500
|
| 1211 |
+
|
| 1212 |
+
Hospitals also consider factors like whether you have insurance, your county of residence, and the size of your bill.
|
| 1213 |
+
|
| 1214 |
+
---
|
| 1215 |
+
|
| 1216 |
+
## Applying for Financial Assistance in Connecticut
|
| 1217 |
+
|
| 1218 |
+
Connecticut now has a **uniform financial assistance application** developed by the Office of Health Strategy (OHS) that every hospital in the state must accept. You can find it on the OHS website. Hospitals are required to make this application available in their admissions office, emergency department, social services department, and billing office. It must also appear as a link on every billing statement you receive, and a paper copy must be included in your discharge paperwork.
|
| 1219 |
+
|
| 1220 |
+
If the hospital believes during admissions or billing review that you may not be able to afford your care, they are required to give you the application β you don't have to ask.
|
| 1221 |
+
|
| 1222 |
+
---
|
| 1223 |
+
|
| 1224 |
+
## Your Rights
|
| 1225 |
+
|
| 1226 |
+
- **Language access:** If a significant portion of the population in your hospital's service area speaks a language other than English, the hospital is required to make a plain-language, one-page summary of their financial assistance policy available in that language. Every Connecticut hospital must also provide this summary in Spanish.
|
| 1227 |
+
|
| 1228 |
+
- **Bills in collections:** Like federal law, Connecticut hospitals must consider applications for bills up to 240 days old. If your bill has been sent to collections, the hospital must still pull it back and review it for financial assistance.
|
| 1229 |
+
|
| 1230 |
+
- **No Medicaid requirement:** Under PA 24-81, hospitals cannot make you apply for HUSKY, Medicaid, Medicare, or Access Health CT coverage before giving you financial assistance β unless they have a reasonable belief you would qualify for one of those programs.
|
| 1231 |
+
|
| 1232 |
+
- **Refunds for payments already made:** If you're approved for financial assistance and you've already paid part of the bill, the hospital is required to refund those payments.
|
| 1233 |
+
|
| 1234 |
+
---
|
| 1235 |
+
|
| 1236 |
+
## Questions? Contact OHA.
|
| 1237 |
+
|
| 1238 |
+
The Connecticut Office of the Healthcare Advocate offers **free help** navigating hospital financial assistance. You can reach them at [portal.ct.gov/oha](https://portal.ct.gov/oha) or by calling **1-866-466-4446**.
|
| 1239 |
+
""", elem_classes="resources-tab")
|
| 1240 |
|
| 1241 |
# --- Navigation functions ---
|
| 1242 |
|