Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -9,12 +9,16 @@ def main():
|
|
9 |
os.environ['OPENAI_API_KEY'] = openai_api_key
|
10 |
|
11 |
st.title("Personal Assistant")
|
12 |
-
|
|
|
13 |
uploaded_file = st.file_uploader("Upload CSV file", type=["csv"])
|
14 |
if uploaded_file is None:
|
15 |
st.warning("Please upload a CSV file.")
|
16 |
st.stop() # Stop execution if no file uploaded
|
17 |
-
|
|
|
|
|
|
|
18 |
from langchain.llms.openai import OpenAI
|
19 |
from langchain.agents.agent_types import AgentType
|
20 |
#from langchain.agents import create_csv_agent
|
@@ -40,8 +44,7 @@ def main():
|
|
40 |
st.write(answer)
|
41 |
st.write(f"Answer (took {round(end - start, 2)} s.)")
|
42 |
|
43 |
-
|
44 |
-
st.image("chatbot.jpg", caption="Chatbot", use_column_width=True)
|
45 |
|
46 |
if __name__ == "__main__":
|
47 |
main()
|
|
|
9 |
os.environ['OPENAI_API_KEY'] = openai_api_key
|
10 |
|
11 |
st.title("Personal Assistant")
|
12 |
+
st.text("A BR CREATION")
|
13 |
+
|
14 |
uploaded_file = st.file_uploader("Upload CSV file", type=["csv"])
|
15 |
if uploaded_file is None:
|
16 |
st.warning("Please upload a CSV file.")
|
17 |
st.stop() # Stop execution if no file uploaded
|
18 |
+
|
19 |
+
# Add the image
|
20 |
+
st.image("chatbot.jpg", caption="Chatbot", use_column_width=True)
|
21 |
+
|
22 |
from langchain.llms.openai import OpenAI
|
23 |
from langchain.agents.agent_types import AgentType
|
24 |
#from langchain.agents import create_csv_agent
|
|
|
44 |
st.write(answer)
|
45 |
st.write(f"Answer (took {round(end - start, 2)} s.)")
|
46 |
|
47 |
+
|
|
|
48 |
|
49 |
if __name__ == "__main__":
|
50 |
main()
|