symfony-mcp-server
by klapaudius·★ 30·综合分 44
一个 Symfony 包,用于构建具有实时通信和 AI 代理功能的企业级 MCP 服务器。
概述
Symfony MCP Server 是一个基于 PHP 的 Model Context Protocol 实现,允许开发者在 Symfony 应用程序中构建智能 AI 代理。它通过 Server-Sent Events (SSE) 和 StreamableHTTP 支持实时通信,适合生产环境使用。该包提供了一个完整的工具系统,具有采样功能用于 AI 推理、提示工程用于代理行为以及资源管理用于代理内存等特性。
试试问 AI
装完之后,这里有 5 个你可以让 AI 做的事:
什么时候选它
当需要在 Symfony 应用程序中构建企业级 AI 智能体,并要求安全实时通信和通过 LLM 集成的智能工具行为时,选择它。
什么时候不要选它
如果您在技术栈中没有使用 Symfony 或 PHP,请避免使用它,因为它与 Symfony 框架紧密耦合,无法与其他后端技术集成。
此 server 暴露的工具
从 README 抽取出 12 个工具CodeAnalyzerToolAnalyzes code for patterns, security, and suggests improvements
HelloWorldToolA basic tool for greeting and demonstrating functionality
ProfileGeneratorToolGenerates user profiles based on input parameters
SearchResultsToolSearches for and returns relevant information based on query
StreamingDataToolProvides real-time streaming data for long-running operations
VersionCheckToolChecks and reports version information for components
DataInsightAgentPerforms intelligent analysis of datasets with AI reasoning
CustomerSupportAgentHandles customer inquiries with AI-powered support
CodeReviewAgentReviews code for security, best practices, and improvements
IntelligentAnalyzerAnalyzes complex data using AI reasoning for decision making
SupportAgentProvides personalized customer support with AI assistance
StreamingDataToolProvides real-time streaming data with progress notifications
可对比工具
安装
安装
- 通过 Composer 安装包:
composer require klapaudius/symfony-mcp-server- 在您的
config/bundles.php中配置包:
return [
// ...
Klapaudius\SymfonyMcpServer\SymfonyMcpServerBundle::class => ['all' => true],
];- 在您的
config/packages/symfony_mcp_server.yaml中配置 MCP 服务器:
symfony_mcp_server:
transport: 'sse' # 或 'streamable_http'
tools:
- App\Tools\IntelligentAnalyzer
- App\Tools\CodeReviewAgent- 启动服务器:
php bin/console server:start对于 Claude Desktop 集成,请添加到您的 claude_desktop_config.json:
{
"mcpServers": {
"symfony-mcp": {
"command": "php",
"args": ["bin/console", "mcp:server"],
"env": {
"APP_ENV": "dev"
}
}
}
}FAQ
- 这个包与其他 MCP 服务器有什么不同?
- 这个包专为 Symfony 应用程序设计,专注于构建 AI 代理而不仅仅是暴露工具。它具有用于实时 AI 推理的采样功能、多结果支持和企业级安全功能。
- 我可以将它与 Claude 以外的 AI 模型一起使用吗?
- 是的,该包被设计为与模型无关。虽然示例显示 Claude 集成,但采样系统可以通过适当的适配器实现与任何兼容的 AI 模型一起工作。
symfony-mcp-server 对比
最后更新于 · 由 README + GitHub 公开数据自动生成。