Update app.py
Browse files
app.py
CHANGED
@@ -5,7 +5,6 @@ from langchain import FewShotPromptTemplate
|
|
5 |
from langchain.prompts.example_selector import LengthBasedExampleSelector
|
6 |
from dotenv import load_dotenv
|
7 |
|
8 |
-
load_dotenv() # load the env-sample.txt file
|
9 |
|
10 |
def getLLMResponse(query, age_option,tasktype_option):
|
11 |
examples = []
|
@@ -56,17 +55,6 @@ def getLLMResponse(query, age_option,tasktype_option):
|
|
56 |
return response
|
57 |
|
58 |
#UI Starts here
|
59 |
-
|
60 |
-
st.set_page_config(page_title="PitchPal: Your Friendly Copy Assistant",
|
61 |
-
page_icon='💻',
|
62 |
-
layout='centered',
|
63 |
-
initial_sidebar_state='collapsed')
|
64 |
-
|
65 |
-
|
66 |
-
st.markdown("<h1 style='text-align: center'>PitchPal</h1>", unsafe_allow_html=True)
|
67 |
-
st.markdown("<h3 style='text-align: center'>Your Efficient Sales Copy Assistant</h2>", unsafe_allow_html=True)
|
68 |
-
st.markdown("<p style='text-align: right'>By <a href='https://entzyeung.github.io/portfolio/index.html'>Lorentz Yeung</a></p>", unsafe_allow_html=True)
|
69 |
-
|
70 |
# Load environment variables
|
71 |
load_dotenv() # Make sure your .env file path is correct
|
72 |
|
@@ -120,4 +108,7 @@ submit = st.button("Generate Sales Copy")
|
|
120 |
if submit:
|
121 |
response = getLLMResponse(form_input, age_option, tasktype_option)
|
122 |
st.markdown("## Generated Sales Copy")
|
123 |
-
st.write(response) # Display the LLM response
|
|
|
|
|
|
|
|
5 |
from langchain.prompts.example_selector import LengthBasedExampleSelector
|
6 |
from dotenv import load_dotenv
|
7 |
|
|
|
8 |
|
9 |
def getLLMResponse(query, age_option,tasktype_option):
|
10 |
examples = []
|
|
|
55 |
return response
|
56 |
|
57 |
#UI Starts here
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
58 |
# Load environment variables
|
59 |
load_dotenv() # Make sure your .env file path is correct
|
60 |
|
|
|
108 |
if submit:
|
109 |
response = getLLMResponse(form_input, age_option, tasktype_option)
|
110 |
st.markdown("## Generated Sales Copy")
|
111 |
+
st.write(response) # Display the LLM response
|
112 |
+
|
113 |
+
# Note: Ensure that all functions and logic related to LLM response generation are correctly implemented
|
114 |
+
# and replace placeholder texts and functions with your actual application code.
|