MCPcopy Index your code
hub / github.com/AI45Lab/Code / tool_context_for_plan

Method tool_context_for_plan

core/src/agent/tool_execution_runtime.rs:26–34  ·  view source on GitHub ↗
(&self, session_id: Option<&str>)

Source from the content-addressed store, hash-verified

24 }
25
26 fn tool_context_for_plan(&self, session_id: Option<&str>) -> ToolContext {
27 let mut ctx = self.tool_context.clone();
28 if ctx.session_id.is_none() {
29 if let Some(session_id) = session_id.filter(|id| !id.is_empty()) {
30 ctx = ctx.with_session_id(session_id);
31 }
32 }
33 ctx
34 }
35
36 pub(super) async fn execute_delegated_plan_tool(
37 &self,

Callers 1

Calls 3

cloneMethod · 0.45
is_emptyMethod · 0.45
with_session_idMethod · 0.45

Tested by

no test coverage detected