Spaces:
Sleeping
Sleeping
Commit ·
f82a46a
1
Parent(s): be25975
Update app.py
Browse files
app.py
CHANGED
|
@@ -71,18 +71,18 @@ if st.button("Recommend AI Model"):
|
|
| 71 |
recommended_model = recommend_ai_model_via_gpt(description)
|
| 72 |
|
| 73 |
# Validate recommended model
|
| 74 |
-
if recommended_model not in KNOWN_MODELS:
|
| 75 |
-
st.warning("The recommendation is ambiguous. Please refine your description or consult an expert.")
|
| 76 |
-
else:
|
| 77 |
-
st.subheader(f"Recommended AI Model: {recommended_model}")
|
| 78 |
-
|
| 79 |
-
|
| 80 |
|
| 81 |
# Collecting rating and feedback through Streamlit
|
| 82 |
-
|
| 83 |
-
|
| 84 |
|
| 85 |
-
|
| 86 |
-
|
| 87 |
else:
|
| 88 |
st.warning("Please provide a description.")
|
|
|
|
| 71 |
recommended_model = recommend_ai_model_via_gpt(description)
|
| 72 |
|
| 73 |
# Validate recommended model
|
| 74 |
+
# if recommended_model not in KNOWN_MODELS:
|
| 75 |
+
# st.warning("The recommendation is ambiguous. Please refine your description or consult an expert.")
|
| 76 |
+
# else:
|
| 77 |
+
# st.subheader(f"Recommended AI Model: {recommended_model}")
|
| 78 |
+
explanation = explain_recommendation(recommended_model)
|
| 79 |
+
st.write("Reason:", explanation)
|
| 80 |
|
| 81 |
# Collecting rating and feedback through Streamlit
|
| 82 |
+
rating = st.slider("Rate the explanation from 1 (worst) to 5 (best):", 1, 5)
|
| 83 |
+
feedback = st.text_input("Any additional feedback?")
|
| 84 |
|
| 85 |
+
if st.button("Submit Feedback"):
|
| 86 |
+
st.success("Thank you for your feedback!")
|
| 87 |
else:
|
| 88 |
st.warning("Please provide a description.")
|