# multi_agent_platform **Repository Path**: jiawy401/multi_agent_platform ## Basic Information - **Project Name**: multi_agent_platform - **Description**: 智能体协同平台 - **Primary Language**: Java - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-11-05 - **Last Updated**: 2025-11-07 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 智能体协同平台 一个支持Python智能体接入的协同工作平台,实现智能体的注册、管理、任务调度和协同编排。 ## 项目简介 智能体协同平台是一个企业级的多智能体管理系统,旨在解决智能体接入、任务分配、协同工作等问题。平台采用前后端分离架构,提供完善的Web管理界面和Python SDK,让开发者可以快速开发和接入智能体。 ### 核心特性 - ✅ **智能体管理**: 注册、注销、状态监控、心跳保活 - ✅ **任务调度**: 智能分配、自动重试、状态跟踪 - ✅ **Python SDK**: 简单易用、自动心跳、任务回调 - ✅ **Web界面**: 智能体管理、任务管理、监控大屏 - ✅ **实时监控**: 统计数据、可视化图表、自动刷新 ## 技术栈 ### 后端 - Spring Boot 3.2.0 - JDK 21 - MyBatis Plus 3.5.5 - MySQL 8.0 - Redis - Maven ### 前端 - Vue 3.4 - Vite 5.0 - Element Plus 2.5 - ECharts 5.4 - Pinia 2.1 ### 智能体SDK - Python 3.9+ - Requests ## 快速开始 ### 环境要求 - JDK 21 - Maven 3.6+ - Node.js 16+ - MySQL 8.0+ - Redis - Python 3.9+ ### 1. 数据库初始化 ```bash mysql -u root -p < sql/init.sql ``` ### 2. 启动后端 ```bash cd backend mvn spring-boot:run ``` 后端服务将在 http://localhost:8080 启动 ### 3. 启动前端 ```bash cd frontend npm install npm run dev ``` 前端服务将在 http://localhost:5173 启动 ### 4. 运行智能体示例 ```bash cd python-sdk pip install -e . python examples/simple_agent.py ``` ### 5. 访问系统 打开浏览器访问 http://localhost:5173 - 监控大屏:查看系统实时状态 - 智能体管理:管理所有智能体 - 任务管理:创建和查看任务 ## 项目结构 ``` multi_agent_platform/ ├── backend/ # 后端服务 │ ├── src/ │ │ └── main/ │ │ ├── java/ │ │ └── resources/ │ └── pom.xml ├── frontend/ # 前端服务 │ ├── src/ │ │ ├── api/ │ │ ├── views/ │ │ ├── router/ │ │ └── utils/ │ └── package.json ├── python-sdk/ # Python SDK │ ├── agent_sdk/ │ ├── examples/ │ └── README.md ├── sql/ # 数据库脚本 │ └── init.sql └── md/ # 文档 ├── product_main.md ├── product.md ├── development_plan.md └── dev/ ``` ## 使用指南 ### 开发智能体 1. 安装SDK ```bash cd python-sdk pip install -e . ``` 2. 创建智能体 ```python from agent_sdk import AgentSDK sdk = AgentSDK( platform_url="http://localhost:8080", agent_config={ "name": "MyAgent", "type": "ANALYSIS", "endpoint": "http://localhost:8001" } ) sdk.register() sdk.start_heartbeat() def handle_task(task): # 处理任务 result = {"status": "done"} sdk.submit_result(task["taskId"], "SUCCESS", result) sdk.receive_task(handle_task) ``` 3. 运行智能体 ```bash python my_agent.py ``` ### 创建任务 1. 访问任务管理页面 2. 点击"创建任务" 3. 填写任务信息 4. 提交后任务自动分配给匹配的智能体 ### 查看监控 访问监控大屏查看: - 智能体统计 - 任务统计 - 状态分布图表 ## API文档 ### 智能体接口 | 方法 | 路径 | 说明 | |------|------|------| | POST | /api/agent/register | 注册智能体 | | POST | /api/agent/unregister | 注销智能体 | | POST | /api/agent/heartbeat | 心跳上报 | | GET | /api/agent/list | 查询列表 | | GET | /api/agent/{id} | 查询详情 | ### 任务接口 | 方法 | 路径 | 说明 | |------|------|------| | POST | /api/task/create | 创建任务 | | POST | /api/task/callback | 任务回调 | | GET | /api/task/list | 查询列表 | | GET | /api/task/{id} | 查询详情 | ### 监控接口 | 方法 | 路径 | 说明 | |------|------|------| | GET | /api/dashboard/overview | 系统概览 | 详细API文档请参考:[API文档](md/api_documentation.md) ## 部署指南 ### 开发环境 参考"快速开始"章节 ### 生产环境 使用Docker Compose部署: ```bash docker-compose up -d ``` 详细部署文档请参考:[部署文档](md/deployment_guide.md) ## 文档 - [产品方案](md/product_main.md) - [技术方案](md/product.md) - [开发计划](md/development_plan.md) - [API文档](md/api_documentation.md) - [部署指南](md/deployment_guide.md) - [用户手册](md/user_manual.md) ## 开发进度 - ✅ Sprint 1: 项目初始化 - ✅ Sprint 2: 智能体管理模块 - ✅ Sprint 3: 任务调度模块 - ✅ Sprint 4: Python SDK开发 - ✅ Sprint 5: 基础监控模块 - ✅ Sprint 6: 集成测试与优化 **MVP版本已完成!** ## 贡献指南 1. Fork 本仓库 2. 创建特性分支 (`git checkout -b feature/AmazingFeature`) 3. 提交更改 (`git commit -m 'Add some AmazingFeature'`) 4. 推送到分支 (`git push origin feature/AmazingFeature`) 5. 开启 Pull Request ## 许可证 MIT License ## 联系方式 - 项目地址:https://gitee.com/xxx/multi_agent_platform - 问题反馈:https://gitee.com/xxx/multi_agent_platform/issues ## 致谢 感谢所有贡献者的付出!