LiamKhoaLe commited on
Commit
a6bd5c0
·
1 Parent(s): e6eaeb3

Upd agent action

Browse files
helpers/coder.py CHANGED
@@ -49,7 +49,7 @@ async def generate_code_artifacts(
49
  await tracker.track_agent_usage(
50
  user_id=user_id,
51
  agent_name="coding",
52
- action="generate_code",
53
  context="report_coding",
54
  metadata={"subsection_id": subsection_id, "model": NVIDIA_CODER}
55
  )
 
49
  await tracker.track_agent_usage(
50
  user_id=user_id,
51
  agent_name="coding",
52
+ action="code",
53
  context="report_coding",
54
  metadata={"subsection_id": subsection_id, "model": NVIDIA_CODER}
55
  )
helpers/diagram.py CHANGED
@@ -79,7 +79,7 @@ async def generate_mermaid_diagram(
79
  await tracker.track_agent_usage(
80
  user_id=user_id,
81
  agent_name="diagram",
82
- action="generate_mermaid",
83
  context="report_diagram",
84
  metadata={"retry": retry}
85
  )
 
79
  await tracker.track_agent_usage(
80
  user_id=user_id,
81
  agent_name="diagram",
82
+ action="diagram",
83
  context="report_diagram",
84
  metadata={"retry": retry}
85
  )
routes/chats.py CHANGED
@@ -742,7 +742,7 @@ async def _chat_impl(
742
  await tracker.track_agent_usage(
743
  user_id=user_id,
744
  agent_name="chat",
745
- action="generate_answer",
746
  context="chat",
747
  metadata={"project_id": project_id, "session_id": session_id}
748
  )
@@ -942,7 +942,7 @@ async def chat_with_search(
942
  await tracker.track_agent_usage(
943
  user_id=user_id,
944
  agent_name="chat",
945
- action="generate_web_augmented_answer",
946
  context="chat_web_augmented",
947
  metadata={"project_id": project_id, "session_id": session_id}
948
  )
 
742
  await tracker.track_agent_usage(
743
  user_id=user_id,
744
  agent_name="chat",
745
+ action="chat",
746
  context="chat",
747
  metadata={"project_id": project_id, "session_id": session_id}
748
  )
 
942
  await tracker.track_agent_usage(
943
  user_id=user_id,
944
  agent_name="chat",
945
+ action="chat",
946
  context="chat_web_augmented",
947
  metadata={"project_id": project_id, "session_id": session_id}
948
  )
routes/reports.py CHANGED
@@ -131,7 +131,7 @@ async def generate_report(
131
  await tracker.track_agent_usage(
132
  user_id=user_id,
133
  agent_name="report",
134
- action="generate_report",
135
  context="report_generation",
136
  metadata={"project_id": project_id, "session_id": session_id, "filename": filename}
137
  )
@@ -145,7 +145,7 @@ async def generate_report(
145
  await tracker.track_agent_usage(
146
  user_id=user_id,
147
  agent_name="planning",
148
- action="plan_report",
149
  context="report_planning",
150
  metadata={"project_id": project_id, "session_id": session_id}
151
  )
@@ -171,7 +171,7 @@ async def generate_report(
171
  await tracker.track_agent_usage(
172
  user_id=user_id,
173
  agent_name="report",
174
- action="synthesize_report",
175
  context="report_synthesis",
176
  metadata={"project_id": project_id, "session_id": session_id}
177
  )
 
131
  await tracker.track_agent_usage(
132
  user_id=user_id,
133
  agent_name="report",
134
+ action="report",
135
  context="report_generation",
136
  metadata={"project_id": project_id, "session_id": session_id, "filename": filename}
137
  )
 
145
  await tracker.track_agent_usage(
146
  user_id=user_id,
147
  agent_name="planning",
148
+ action="plan",
149
  context="report_planning",
150
  metadata={"project_id": project_id, "session_id": session_id}
151
  )
 
171
  await tracker.track_agent_usage(
172
  user_id=user_id,
173
  agent_name="report",
174
+ action="report",
175
  context="report_synthesis",
176
  metadata={"project_id": project_id, "session_id": session_id}
177
  )
routes/search.py CHANGED
@@ -35,7 +35,7 @@ Return only the keywords, separated by spaces, no other text."""
35
  await tracker.track_agent_usage(
36
  user_id="system", # Search is system-level
37
  agent_name="search",
38
- action="extract_keywords",
39
  context="web_search",
40
  metadata={"query": user_query}
41
  )
 
35
  await tracker.track_agent_usage(
36
  user_id="system", # Search is system-level
37
  agent_name="search",
38
+ action="search",
39
  context="web_search",
40
  metadata={"query": user_query}
41
  )