2f4c44fe83
The internal class is now SearchToolsTool but the wire name stays "search_tool_bm25" so persisted MCP selections in user session files continue to resolve correctly. The BM25 corpus is now drawn from the generic DiscoverableTool list (built-ins, MCP, extension, custom) rather than only MCP tools. createIf fires when either tools.discoveryMode !== "off" or the legacy mcp.discoveryMode is true. AgentSession gains generic discovery methods (isToolDiscoveryEnabled, getDiscoverableTools, getDiscoverableToolSearchIndex, getSelectedDiscoveredToolNames, activateDiscoveredTools). The existing MCP-named methods are kept as thin shims that filter by source === "mcp" so existing callers continue to work. Updated the tool's prompt copy to advertise discovery across all sources rather than MCP only. Tests extended for the new shape.