[fel] Enhanced MCP Client and Server Interaction with Tool Management Improvements#141
Merged
CodeCasterX merged 1 commit intoModelEngine-Group:3.5.xfrom May 27, 2025
Conversation
… Improvements This commit introduces several enhancements to the MCP (Model Communication Protocol) client and server interaction, focusing on improving tool management and communication capabilities. Key changes include: 1. ToolInfo Interface Expansion: - Added a new static method parseIdentifier to parse tool identifiers into namespace and tool name components, enhancing tool identification and management. 2. MCP Client Enhancements: - Updated the DefaultMcpClient class to support more robust initialization and communication with the MCP server. - Introduced new methods for handling Server-Sent Events (SSE) and improved error handling for tool calls. - Enhanced the callTool method to return results directly and manage pending requests more efficiently. 3. MCP Server Adjustments: - Modified the McpServer interface and its implementations to better support tool addition and retrieval. - Updated the DefaultMcpServer to provide a more structured server schema and improved tool registration logic. 4. Weather Service Example: - Introduced a new weather service example (WeatherService and WeatherServiceImpl) to demonstrate tool implementation and usage within the MCP framework. 5. Code Structure and Cleanup: - Reorganized and cleaned up code in various classes to improve readability and maintainability. - Removed deprecated or unused code related to the MCP server entity. 6. Dependency and Plugin Updates: - Added new dependencies and updated plugins in the pom.xml file to support the enhanced MCP functionality. 7. Test Code Updates: - Expanded test cases for the MCP client and server to ensure compatibility and functionality of the new features. These changes collectively enhance the MCP framework's ability to manage and interact with tools, providing a more robust and flexible platform for model communication and execution.
Yager-42
pushed a commit
to Yager-42/fit-framework
that referenced
this pull request
Aug 16, 2025
… Improvements (ModelEngine-Group#141) This commit introduces several enhancements to the MCP (Model Communication Protocol) client and server interaction, focusing on improving tool management and communication capabilities. Key changes include: 1. ToolInfo Interface Expansion: - Added a new static method parseIdentifier to parse tool identifiers into namespace and tool name components, enhancing tool identification and management. 2. MCP Client Enhancements: - Updated the DefaultMcpClient class to support more robust initialization and communication with the MCP server. - Introduced new methods for handling Server-Sent Events (SSE) and improved error handling for tool calls. - Enhanced the callTool method to return results directly and manage pending requests more efficiently. 3. MCP Server Adjustments: - Modified the McpServer interface and its implementations to better support tool addition and retrieval. - Updated the DefaultMcpServer to provide a more structured server schema and improved tool registration logic. 4. Weather Service Example: - Introduced a new weather service example (WeatherService and WeatherServiceImpl) to demonstrate tool implementation and usage within the MCP framework. 5. Code Structure and Cleanup: - Reorganized and cleaned up code in various classes to improve readability and maintainability. - Removed deprecated or unused code related to the MCP server entity. 6. Dependency and Plugin Updates: - Added new dependencies and updated plugins in the pom.xml file to support the enhanced MCP functionality. 7. Test Code Updates: - Expanded test cases for the MCP client and server to ensure compatibility and functionality of the new features. These changes collectively enhance the MCP framework's ability to manage and interact with tools, providing a more robust and flexible platform for model communication and execution.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit introduces several enhancements to the MCP (Model Communication Protocol) client and server interaction, focusing on improving tool management and communication capabilities. Key changes include:
These changes collectively enhance the MCP framework's ability to manage and interact with tools, providing a more robust and flexible platform for model communication and execution.