Keep history extension tools out of Guardian reviews (#41861)

## What changed

- Initialize Guardian reviewer subthreads with empty extension data.
- Remove the special registration that exposed inherited read-only `history`
  tools in the Guardian tool plan.

GitOrigin-RevId: 7700f033faab125d59d11bc2d82955c67689e3c3
This commit is contained in:
jif
2026-08-31 15:19:38 +00:00
committed by copyberry
parent 09f4c45068
commit 2c8cfbf44f
3 changed files with 1 additions and 215 deletions
-12
View File
@@ -153,18 +153,6 @@ pub(crate) fn build_tool_router(
add_core_tool_sources(&context, &mut registry);
let hosted_specs = if crate::guardian::is_basic_session_source(&turn_context.session_source) {
if let Some(history_tools) = session
.services
.thread_extension_data
.get::<crate::codex_delegate::GuardianReadOnlyHistoryTools>()
{
append_extension_tool_executors(
turn_context,
model_info,
history_tools.0.iter().cloned(),
&mut registry,
);
}
Vec::new()
} else {
let registered_mcp_tools = session.services.mcp_handler_cache.append_mcp_tools(