Spaces:
Sleeping
Sleeping
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +1 -1
src/streamlit_app.py
CHANGED
|
@@ -14,7 +14,7 @@ if task == "Text Generation":
|
|
| 14 |
prompt = st.text_area("Enter a prompt", "Once upon a time in a land far away,")
|
| 15 |
if st.button("Generate Text"):
|
| 16 |
with st.spinner("Generating..."):
|
| 17 |
-
generator = pipeline("text-generation", model="
|
| 18 |
output = generator(prompt, max_length=100, num_return_sequences=1)
|
| 19 |
st.success("Generated Text:")
|
| 20 |
st.write(output[0]['generated_text'])
|
|
|
|
| 14 |
prompt = st.text_area("Enter a prompt", "Once upon a time in a land far away,")
|
| 15 |
if st.button("Generate Text"):
|
| 16 |
with st.spinner("Generating..."):
|
| 17 |
+
generator = pipeline("text-generation", model="gpt2")
|
| 18 |
output = generator(prompt, max_length=100, num_return_sequences=1)
|
| 19 |
st.success("Generated Text:")
|
| 20 |
st.write(output[0]['generated_text'])
|