File size: 2,360 Bytes
d9c2461 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
"""kwest.dev is a saas tool to craft stories for your ideas."""
import streamlit as st
from api import check_if_input_is_valid
RECIPES = ["sell", "motivate", "convince", "connect", "explain", "lead", "impress"]
VALID_EMOJIS = {"yes": "β
", "no": "β"}
st.title("kwest.dev")
st.subheader("Leverage the power of storytelling for any idea. π‘")
with st.expander(label="How to present your idea to get the best story π", expanded=True):
st.markdown(
"""
- π― Explain the **main objective** of your idea. What is the **main goal** you are trying to achieve?
- π Give as much **context** as possible. For example, what is the problem you are trying to solve? If you have a good name for your idea, share it.
- π€ What is the **audience** for your idea? Who are the people that should be interested in it?
Once you have shared this information, we will propose 2 recipes for your story. Choose the one you like the most between the two.
The different recipes available are: `sell`, `motivate`, `convince`, `connect`, `explain`, `lead`, `impress`
If you aren't satisfied with the recipes proposed, you can choose a different one below.
__Examples of good and bad inputs:__
β
`I need a pitch for a new app that helps people find the best restaurants in town. I will present it to angel investors. The name of the app is "Foodie".`
β `I need a pitch for a new app. It's cool.`
"""
)
input_col, btn_col = st.columns([3, 1], vertical_alignment="bottom")
with input_col:
input_str = st.text_area("Your idea that needs a story", "", placeholder="I need a pitch for ...")
with btn_col:
input_is_valid = st.button(
label="βΆοΈ",
key="check_input",
help="Check if the input is valid",
on_click=check_if_input_is_valid,
kwargs={"input_str": input_str}
)
if input_is_valid:
st.write(
f"Objective: {VALID_EMOJIS[input_is_valid['objective']]} | "
f"Context: {VALID_EMOJIS[input_is_valid['context']]} | "
f"Audience: {VALID_EMOJIS[input_is_valid['audience']]}"
)
if input_is_valid["objective"] == "yes" and input_is_valid["context"] == "yes" and input_is_valid["audience"] == "yes":
st.write("Choose the recipe you want to use for your story.")
|