[
https://issues.apache.org/jira/browse/CAMEL-23964?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18100116#comment-18100116
]
Guillaume Nodet commented on CAMEL-23964:
-----------------------------------------
Fixed via [PR #25209|https://github.com/apache/camel/pull/25209] (merged).
Added per-server {{toolNames}} include list for MCP tool filtering. When
{{mcpServer.<name>.toolNames}} is set (comma-separated), only the named tools
are registered from that server. The filter applies to both initial connection
and reconnection paths.
_Claude Code on behalf of gnodet_
> camel-openai: MCP tool filtering per endpoint
> ---------------------------------------------
>
> Key: CAMEL-23964
> URL: https://issues.apache.org/jira/browse/CAMEL-23964
> Project: Camel
> Issue Type: Improvement
> Components: camel-openai
> Affects Versions: 4.21.0
> Reporter: Federico Mariani
> Assignee: Guillaume Nodet
> Priority: Minor
> Labels: ai
> Fix For: 4.22.0
>
>
> camel-openai currently advertises *all* tools of every configured MCP server
> to the model. There is no way to restrict the tool set, unlike
> camel-langchain4j-agent which supports an {{mcpToolProviderFilter}} predicate
> (and whose filter-coverage gap is tracked in CAMEL-23948). Reasons users need
> filtering: reduce prompt size/cost, keep destructive tools away from the
> model, work around duplicate tool names across servers.
> Proposal: a per-server include list in the existing prefix notation, e.g.
> {noformat}
> mcpServer.fs.toolNames=read_file,list_directory
> {noformat}
> (and possibly a global {{mcpToolNames}} include/exclude), applied when tools
> are listed in {{OpenAIEndpoint.initializeMcpServers}} and in
> {{reconnectMcpServer}} so both the advertised list and the dispatch map are
> filtered consistently.
> Scope note: this concerns *external MCP tools* only, which remain native to
> camel-openai; Camel-route tools are arriving separately via the unified tool
> abstraction with its own {{tags}}-based selection (CAMEL-23382 step 6), so no
> overlap.
> _This issue was drafted by Claude Code on behalf of Federico Mariani_
--
This message was sent by Atlassian Jira
(v8.20.10#820010)