You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Instead of maintaining a separate compiledConditions slice indexed by
tool position, embed the *CompiledCondition directly in each ServerTool.
This eliminates the index alignment issue where filtering to a single
tool (ForMCPRequest with ToolsCall) would break the mapping between
tools and their compiled conditions.
Benefits:
- Compiled condition travels with the tool during any filtering
- No index bookkeeping needed
- Simpler code in filters.go (no toolIndex parameter)
- ForMCPRequest works correctly for single-tool lookups
- Same O(1) bitmask evaluation performance
0 commit comments