Update app.py
Browse files
app.py
CHANGED
@@ -1,4 +1,19 @@
|
|
1 |
import streamlit as st
|
|
|
2 |
|
3 |
-
|
4 |
-
st.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
import streamlit as st
|
2 |
+
from transformers import pipeline
|
3 |
|
4 |
+
# Load the model
|
5 |
+
st.title("PatientSeek AI Model")
|
6 |
+
st.write("This app uses the PatientSeek model for medical predictions.")
|
7 |
+
|
8 |
+
@st.cache_resource # Cache to speed up loading
|
9 |
+
def load_model():
|
10 |
+
return pipeline("text-classification", model="whyhow-ai/PatientSeek")
|
11 |
+
|
12 |
+
model = load_model()
|
13 |
+
|
14 |
+
# User input
|
15 |
+
user_input = st.text_area("Enter patient symptoms:")
|
16 |
+
|
17 |
+
if user_input:
|
18 |
+
result = model(user_input)
|
19 |
+
st.write("Prediction:", result)
|