camparchimedes commited on
Commit
fece0d8
·
verified ·
1 Parent(s): 954c17e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -6
app.py CHANGED
@@ -120,16 +120,13 @@ async def handle_message(message: cl.Message):
120
 
121
  if re.search(booking_pattern, user_message):
122
  booking_id = re.search(booking_pattern, user_message).group(0)
123
- headers = {"Authorization": f"Bearer {auth_token}", "Content-Type": "application/json"}
124
- question = f"Retrieve information for booking ID {booking_id}"
125
 
126
  # --------------------------------AD VAL.III--------------------------------
127
 
128
- response = await api_chain.ainvoke(
129
  {
130
- "question": question,
131
- "url": endpoint_url,
132
- "method": "POST",
133
  "headers": headers,
134
  "body": {
135
  "booking_id": booking_id
 
120
 
121
  if re.search(booking_pattern, user_message):
122
  booking_id = re.search(booking_pattern, user_message).group(0)
123
+ headers = {"Authorization": f"{auth_token}"
124
+ #question = f"Retrieve information for booking ID {booking_id}"
125
 
126
  # --------------------------------AD VAL.III--------------------------------
127
 
128
+ response = await api_chain.acall(
129
  {
 
 
 
130
  "headers": headers,
131
  "body": {
132
  "booking_id": booking_id