Wajahat698 commited on
Commit
06bf0d1
·
verified ·
1 Parent(s): 6ec2c87

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -3
app.py CHANGED
@@ -1819,11 +1819,17 @@ def chatbot_response(message, history):
1819
  + top_scoring_statements
1820
  + "\n\nUser Input:\n"
1821
  + message
1822
-
1823
- )
 
 
 
 
 
 
 
1824
 
1825
  # Generate AI output using agent_executor
1826
- output = agent_executor.invoke({"input": Combined_prompt, "chat_history": history})
1827
 
1828
  # Append the generated output to the response
1829
  response = f"**Selected Dataset: {selected_dataset_ai}**\n\n"
 
1819
  + top_scoring_statements
1820
  + "\n\nUser Input:\n"
1821
  + message
1822
+ )
1823
+
1824
+ structured_input = {
1825
+ "input": combined_prompt,
1826
+ "chat_history": history,
1827
+ }
1828
+
1829
+ # Generate AI output using the agent pipeline
1830
+ agent_output = agent_executor.invoke(structured_input)
1831
 
1832
  # Generate AI output using agent_executor
 
1833
 
1834
  # Append the generated output to the response
1835
  response = f"**Selected Dataset: {selected_dataset_ai}**\n\n"