Spaces:
Sleeping
Sleeping
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +2 -2
src/streamlit_app.py
CHANGED
|
@@ -12,7 +12,7 @@ st.set_page_config(page_title="FitPlan AI", layout="centered")
|
|
| 12 |
@st.cache_resource
|
| 13 |
def load_model():
|
| 14 |
return pipeline(
|
| 15 |
-
"
|
| 16 |
model="google/flan-t5-base"
|
| 17 |
)
|
| 18 |
|
|
@@ -186,7 +186,7 @@ if st.button("🚀 Submit Profile"):
|
|
| 186 |
"""
|
| 187 |
|
| 188 |
with st.spinner("Generating your AI workout plan..."):
|
| 189 |
-
response = generator(prompt,
|
| 190 |
result = response[0]["generated_text"]
|
| 191 |
|
| 192 |
st.subheader("🏋️ Your Personalized Workout Plan")
|
|
|
|
| 12 |
@st.cache_resource
|
| 13 |
def load_model():
|
| 14 |
return pipeline(
|
| 15 |
+
"text2text-generation",
|
| 16 |
model="google/flan-t5-base"
|
| 17 |
)
|
| 18 |
|
|
|
|
| 186 |
"""
|
| 187 |
|
| 188 |
with st.spinner("Generating your AI workout plan..."):
|
| 189 |
+
response = generator(prompt,max_length=512)
|
| 190 |
result = response[0]["generated_text"]
|
| 191 |
|
| 192 |
st.subheader("🏋️ Your Personalized Workout Plan")
|