Spaces:
Sleeping
Sleeping
Commit
·
8a84c88
1
Parent(s):
6b0827b
Add comment about request body
Browse files
app.py
CHANGED
|
@@ -128,7 +128,7 @@ def form_request_body():
|
|
| 128 |
|
| 129 |
def predict_callback():
|
| 130 |
"""Callback function to call the prediction endpoint"""
|
| 131 |
-
request_body = form_request_body()
|
| 132 |
st.session_state.exp = None
|
| 133 |
with st.spinner("Loading prediction and explanation..."):
|
| 134 |
# Call the explain endpoint as it also includes the prediction
|
|
|
|
| 128 |
|
| 129 |
def predict_callback():
|
| 130 |
"""Callback function to call the prediction endpoint"""
|
| 131 |
+
request_body = form_request_body() # Make sure we have the latest values after user input
|
| 132 |
st.session_state.exp = None
|
| 133 |
with st.spinner("Loading prediction and explanation..."):
|
| 134 |
# Call the explain endpoint as it also includes the prediction
|