subashpoudel commited on
Commit
03ef145
·
1 Parent(s): da7bd22

next commit

Browse files
logs/access.log CHANGED
@@ -1609,3 +1609,34 @@
1609
  2025-11-03 13:25:53,572 | INFO | access_logger | app.py:20 | Response status: 200
1610
  2025-11-03 13:26:16,008 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/api/analytics-chatbot?msg=Give%20me%20basic%20information%20about%20divya%20dhakal
1611
  2025-11-03 13:26:30,251 | INFO | access_logger | app.py:20 | Response status: 200
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1609
  2025-11-03 13:25:53,572 | INFO | access_logger | app.py:20 | Response status: 200
1610
  2025-11-03 13:26:16,008 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/api/analytics-chatbot?msg=Give%20me%20basic%20information%20about%20divya%20dhakal
1611
  2025-11-03 13:26:30,251 | INFO | access_logger | app.py:20 | Response status: 200
1612
+ 2025-11-03 13:40:22,957 | INFO | access_logger | app.py:18 | Request: POST http://127.0.0.1:8000/api/token/refresh/
1613
+ 2025-11-03 13:40:22,958 | INFO | access_logger | app.py:20 | Response status: 404
1614
+ 2025-11-12 12:07:39,680 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/
1615
+ 2025-11-12 12:07:39,681 | INFO | access_logger | app.py:20 | Response status: 200
1616
+ 2025-11-12 12:07:39,695 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/favicon.ico
1617
+ 2025-11-12 12:07:39,696 | INFO | access_logger | app.py:20 | Response status: 404
1618
+ 2025-11-12 12:07:43,615 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/docs
1619
+ 2025-11-12 12:07:43,616 | INFO | access_logger | app.py:20 | Response status: 200
1620
+ 2025-11-12 12:07:43,791 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/openapi.json
1621
+ 2025-11-12 12:07:43,798 | INFO | access_logger | app.py:20 | Response status: 200
1622
+ 2025-11-12 12:08:11,706 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/api/analytics-chatbot?msg=I%20want%20to%20view%20overall%20analytics%20of%20divya
1623
+ 2025-11-12 12:09:13,361 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/api/analytics-chatbot?msg=I%20want%20to%20view%20overall%20analytics%20of%20divya
1624
+ 2025-11-12 12:20:17,693 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/
1625
+ 2025-11-12 12:20:17,694 | INFO | access_logger | app.py:20 | Response status: 200
1626
+ 2025-11-12 12:20:17,695 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/
1627
+ 2025-11-12 12:20:17,695 | INFO | access_logger | app.py:20 | Response status: 200
1628
+ 2025-11-12 12:20:19,895 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/favicon.ico
1629
+ 2025-11-12 12:20:19,896 | INFO | access_logger | app.py:20 | Response status: 404
1630
+ 2025-11-12 12:20:19,898 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/favicon.ico
1631
+ 2025-11-12 12:20:19,899 | INFO | access_logger | app.py:20 | Response status: 404
1632
+ 2025-11-12 12:20:27,668 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/docs
1633
+ 2025-11-12 12:20:27,669 | INFO | access_logger | app.py:20 | Response status: 200
1634
+ 2025-11-12 12:20:28,025 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/openapi.json
1635
+ 2025-11-12 12:20:28,032 | INFO | access_logger | app.py:20 | Response status: 200
1636
+ 2025-11-12 12:20:28,431 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/doca
1637
+ 2025-11-12 12:20:28,432 | INFO | access_logger | app.py:20 | Response status: 404
1638
+ 2025-11-12 12:20:31,582 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/docs
1639
+ 2025-11-12 12:20:31,582 | INFO | access_logger | app.py:20 | Response status: 200
1640
+ 2025-11-12 12:20:31,658 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/openapi.json
1641
+ 2025-11-12 12:20:31,659 | INFO | access_logger | app.py:20 | Response status: 200
1642
+ 2025-11-12 12:21:21,920 | INFO | access_logger | app.py:18 | Request: GET http://127.0.0.1:8000/api/analytics-chatbot?msg=I%20want%20to%20view%20the%20overall%20audience%20analytics%20of%20divya
src/genai/analytics_chatbot/utils/nodes.py CHANGED
@@ -99,7 +99,7 @@ class FetchParametersNode:
99
  if state['method']=='GET':
100
  template = fetch_parameters_prompt
101
  messages=[SystemMessage(content=template),HumanMessage(content=f'''The query is: {state['latest_message']}\n. The needed parameters: {str(state['needed_parameters'])}''')]
102
- print('messages:', messages)
103
  result = self.llm.with_structured_output(ParameterFormatter, method='function_calling').invoke(messages)
104
  parameters_values = {k: (process_query(v) if isinstance(v, str) else v) for k, v in result.parameters_values.items()}
105
 
@@ -174,6 +174,8 @@ class FetchDataNode:
174
  results[username] = response.json() # Store influencer-wise response
175
 
176
  return {"response": results}
 
 
177
 
178
  except Exception as e:
179
  print('Error occoured:', e)
 
99
  if state['method']=='GET':
100
  template = fetch_parameters_prompt
101
  messages=[SystemMessage(content=template),HumanMessage(content=f'''The query is: {state['latest_message']}\n. The needed parameters: {str(state['needed_parameters'])}''')]
102
+ # print('messages:', messages)
103
  result = self.llm.with_structured_output(ParameterFormatter, method='function_calling').invoke(messages)
104
  parameters_values = {k: (process_query(v) if isinstance(v, str) else v) for k, v in result.parameters_values.items()}
105
 
 
174
  results[username] = response.json() # Store influencer-wise response
175
 
176
  return {"response": results}
177
+
178
+ print('Data from api:', response)
179
 
180
  except Exception as e:
181
  print('Error occoured:', e)