@@ -133,6 +133,7 @@ def build_issue_chat_messages(
133133 "issue" : issue_chat_request .issue_type ,
134134 "toolsets" : ai .tool_executor .toolsets ,
135135 "cluster_name" : config .cluster_name ,
136+ "investigation_id" : ai .investigation_id ,
136137 },
137138 )
138139 messages = [
@@ -153,6 +154,7 @@ def build_issue_chat_messages(
153154 "issue" : issue_chat_request .issue_type ,
154155 "toolsets" : ai .tool_executor .toolsets ,
155156 "cluster_name" : config .cluster_name ,
157+ "investigation_id" : ai .investigation_id ,
156158 }
157159 system_prompt_without_tools = load_and_render_prompt (
158160 template_path , template_context_without_tools
@@ -186,6 +188,7 @@ def build_issue_chat_messages(
186188 "issue" : issue_chat_request .issue_type ,
187189 "toolsets" : ai .tool_executor .toolsets ,
188190 "cluster_name" : config .cluster_name ,
191+ "investigation_id" : ai .investigation_id ,
189192 }
190193 system_prompt_with_truncated_tools = load_and_render_prompt (
191194 template_path , truncated_template_context
@@ -227,6 +230,7 @@ def build_issue_chat_messages(
227230 "issue" : issue_chat_request .issue_type ,
228231 "toolsets" : ai .tool_executor .toolsets ,
229232 "cluster_name" : config .cluster_name ,
233+ "investigation_id" : ai .investigation_id ,
230234 }
231235 system_prompt_without_tools = load_and_render_prompt (
232236 template_path , template_context_without_tools
@@ -250,6 +254,7 @@ def build_issue_chat_messages(
250254 "issue" : issue_chat_request .issue_type ,
251255 "toolsets" : ai .tool_executor .toolsets ,
252256 "cluster_name" : config .cluster_name ,
257+ "investigation_id" : ai .investigation_id ,
253258 }
254259 system_prompt_with_truncated_tools = load_and_render_prompt (
255260 template_path , template_context
@@ -274,6 +279,7 @@ def add_or_update_system_prompt(
274279 context = {
275280 "toolsets" : ai .tool_executor .toolsets ,
276281 "cluster_name" : config .cluster_name ,
282+ "investigation_id" : ai .investigation_id ,
277283 }
278284
279285 system_prompt = load_and_render_prompt (template_path , context )
@@ -465,6 +471,7 @@ def build_workload_health_chat_messages(
465471 "resource" : resource ,
466472 "toolsets" : ai .tool_executor .toolsets ,
467473 "cluster_name" : config .cluster_name ,
474+ "investigation_id" : ai .investigation_id ,
468475 },
469476 )
470477 messages = [
@@ -485,6 +492,7 @@ def build_workload_health_chat_messages(
485492 "resource" : resource ,
486493 "toolsets" : ai .tool_executor .toolsets ,
487494 "cluster_name" : config .cluster_name ,
495+ "investigation_id" : ai .investigation_id ,
488496 }
489497 system_prompt_without_tools = load_and_render_prompt (
490498 template_path , template_context_without_tools
@@ -518,6 +526,7 @@ def build_workload_health_chat_messages(
518526 "resource" : resource ,
519527 "toolsets" : ai .tool_executor .toolsets ,
520528 "cluster_name" : config .cluster_name ,
529+ "investigation_id" : ai .investigation_id ,
521530 }
522531 system_prompt_with_truncated_tools = load_and_render_prompt (
523532 template_path , truncated_template_context
@@ -559,6 +568,7 @@ def build_workload_health_chat_messages(
559568 "resource" : resource ,
560569 "toolsets" : ai .tool_executor .toolsets ,
561570 "cluster_name" : config .cluster_name ,
571+ "investigation_id" : ai .investigation_id ,
562572 }
563573 system_prompt_without_tools = load_and_render_prompt (
564574 template_path , template_context_without_tools
@@ -582,6 +592,7 @@ def build_workload_health_chat_messages(
582592 "resource" : resource ,
583593 "toolsets" : ai .tool_executor .toolsets ,
584594 "cluster_name" : config .cluster_name ,
595+ "investigation_id" : ai .investigation_id ,
585596 }
586597 system_prompt_with_truncated_tools = load_and_render_prompt (
587598 template_path , template_context
0 commit comments