Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -90,8 +90,10 @@ agent_executor = AgentExecutor(agent=agent, tools=tools, verbose=True,handle_par
|
|
90 |
# agent = initialize_agent(
|
91 |
# tools, llm, agent=AgentType.ZERO_SHOT_REACT_DESCRIPTION, verbose=True
|
92 |
# )
|
|
|
|
|
93 |
|
94 |
-
with st.chat_message("assistant"):
|
95 |
-
|
96 |
-
|
97 |
-
|
|
|
90 |
# agent = initialize_agent(
|
91 |
# tools, llm, agent=AgentType.ZERO_SHOT_REACT_DESCRIPTION, verbose=True
|
92 |
# )
|
93 |
+
prompt = st.chat_input("Say something")
|
94 |
+
if prompt:
|
95 |
|
96 |
+
with st.chat_message("assistant"):
|
97 |
+
st_callback = StreamlitCallbackHandler(st.container())
|
98 |
+
response = agent_executor.invoke({"input":prompt},callbacks=[st_callback])
|
99 |
+
st.write(response)
|