Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -23,21 +23,24 @@ def main():
|
|
23 |
st.markdown("""Despite the simple themes and limited vocabulary present in the training data, the model is
|
24 |
quite effective at generating new short stories. **Try it out below!**""")
|
25 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
26 |
st.header("Let's make some stories! π")
|
27 |
|
28 |
# Input from user
|
29 |
user_input = st.text_input("Enter your prompt:", placeholder="Write a prompt to make a story of your own, or leave it empty for a random story!").strip()
|
30 |
|
31 |
-
if st.checkbox("Show Prompting Tips"):
|
32 |
-
st.markdown("The model can struggle with some prompts, especially those outside of its limited domain. If a response isn't satisfactory, try repeating the generation, or make the following modifications:")
|
33 |
-
st.markdown(
|
34 |
-
"""
|
35 |
-
- Use simple vocabulary - words and themes that would appear in a children's story
|
36 |
-
- Avoid using idioms - for example, instead of "hit the gym", say "went to the gym"
|
37 |
-
- Include plenty of descriptive adjectives
|
38 |
-
- The model often struggles with names. **Using common names and sticking with first names only can help.**
|
39 |
-
"""
|
40 |
-
)
|
41 |
## Default values for advanced settings
|
42 |
user_seed = None # Remove if we're not rigging the "random" demo
|
43 |
generation_method = "top-k"
|
|
|
23 |
st.markdown("""Despite the simple themes and limited vocabulary present in the training data, the model is
|
24 |
quite effective at generating new short stories. **Try it out below!**""")
|
25 |
|
26 |
+
st.header("Prompting Tips")
|
27 |
+
st.markdown(
|
28 |
+
"The model can struggle with some prompts, especially those outside of its limited domain. If a response isn't satisfactory, try repeating the generation, or make the following modifications:"
|
29 |
+
)
|
30 |
+
st.markdown(
|
31 |
+
"""
|
32 |
+
- Use simple vocabulary - words and themes that would appear in a children's story.
|
33 |
+
- Avoid using idioms - for example, instead of "hit the gym", say "went to the gym".
|
34 |
+
- Include plenty of descriptive adjectives.
|
35 |
+
- The model often struggles with names. **Using common names and sticking with first names only can help.**
|
36 |
+
"""
|
37 |
+
)
|
38 |
+
|
39 |
st.header("Let's make some stories! π")
|
40 |
|
41 |
# Input from user
|
42 |
user_input = st.text_input("Enter your prompt:", placeholder="Write a prompt to make a story of your own, or leave it empty for a random story!").strip()
|
43 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
44 |
## Default values for advanced settings
|
45 |
user_seed = None # Remove if we're not rigging the "random" demo
|
46 |
generation_method = "top-k"
|