[Feature request] AgentCoreToolSearchPlugin: add tool_filters support to restrict tools resolved from AgentCore Gateway
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 68/100
Research direction
Start with AgentCoreToolSearchPlugin and its x_amz_bedrock_agentcore_search tool call, then compare how Strands MCPClient handles tool_filters. Add support for an allowed-tool filter so semantic search considers only permitted tools, and verify that AgentCoreToolSearchPlugin accepts the example tool_filters parameter and excludes disallowed results.
Written by the indexing model from the issue text.
Description
Is your feature request related to a problem? Please describe.
When using AgentCoreToolSearchPlugin with AgentCore Gateway, there is currently no way to restrict which tools are surfaced to the agent. The plugin performs semantic search over the full set of tools registered in the Gateway, which can include dozens of tools. Without filtering, the semantic search may surface unintended tools, which increases noise, wastes tokens, and can cause the agent to invoke tools it should not have access to.
Describe the solution you'd like
AgentCoreToolSearchPlugin should support a tool_filters parameter, mirroring the tool_filters parameter already available on Strands' MCPClient:
# Current Strands MCPClient — already supports filtering
MCPClient(
...,
tool_filters={"allowed": ["tool-1", "tool-2"]}
)
# Desired — AgentCoreToolSearchPlugin parity
AgentCoreToolSearchPlugin(
...,
tool_filters={"allowed": ["tool-1", "tool-2"]}
)
Ideally, the filter should be applied before (or at query time during) the semantic search, so that only candidate tools matching the allowlist are considered. If not possible, it can be done after query result I guess inside the x_amz_bedrock_agentcore_search tool call.
Describe alternatives you've considered
Post-filtering after semantic search with the post tool call hook and discarding results that don't match the allowlist. This works but should be natively supported by the plugin.
Additional context
N/A
- Dominant language
- Python
- Stars
- 764
- Forks
- 149
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 7
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from aws/bedrock-agentcore-sdk-python
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
aws/bedrock-agentcore-sdk-python#496 · 1 comment ·
-
Pydantic deprecation warning: Support for class-based `config` is deprecated, use ConfigDict instead Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
aws/bedrock-agentcore-sdk-python#320 · 2 comments · 3 reactions ·
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
All issues in aws/bedrock-agentcore-sdk-python
Similar issues
-
documentation help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
simonw/sqlite-utils#872 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100