agent-mcp 0.1.4__py3-none-any.whl → 0.1.5__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- agent_mcp/__init__.py +66 -12
- agent_mcp/a2a_protocol.py +316 -0
- agent_mcp/agent_lightning_library.py +214 -0
- agent_mcp/claude_mcp_adapter.py +195 -0
- agent_mcp/google_ai_mcp_adapter.py +183 -0
- agent_mcp/llamaindex_mcp_adapter.py +410 -0
- agent_mcp/microsoft_agent_framework.py +591 -0
- agent_mcp/missing_frameworks.py +435 -0
- agent_mcp/openapi_protocol.py +616 -0
- agent_mcp/payments.py +804 -0
- agent_mcp/pydantic_ai_mcp_adapter.py +628 -0
- agent_mcp/registry.py +768 -0
- agent_mcp/security.py +864 -0
- {agent_mcp-0.1.4.dist-info → agent_mcp-0.1.5.dist-info}/METADATA +174 -52
- {agent_mcp-0.1.4.dist-info → agent_mcp-0.1.5.dist-info}/RECORD +19 -6
- {agent_mcp-0.1.4.dist-info → agent_mcp-0.1.5.dist-info}/WHEEL +1 -1
- agent_mcp-0.1.5.dist-info/entry_points.txt +4 -0
- demos/comprehensive_framework_demo.py +202 -0
- agent_mcp-0.1.4.dist-info/entry_points.txt +0 -2
- {agent_mcp-0.1.4.dist-info → agent_mcp-0.1.5.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,435 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Missing Framework Implementations for AgentMCP
|
|
3
|
+
Adding BeeAI, AgentGPT, SuperAGI, and Fractal frameworks
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import asyncio
|
|
7
|
+
import json
|
|
8
|
+
from typing import Dict, Any, List, Optional, Callable
|
|
9
|
+
from dataclasses import dataclass, asdict
|
|
10
|
+
import logging
|
|
11
|
+
|
|
12
|
+
logger = logging.getLogger(__name__)
|
|
13
|
+
|
|
14
|
+
# Try to import the missing frameworks
|
|
15
|
+
try:
|
|
16
|
+
# Note: These would require actual installation and API access
|
|
17
|
+
# For now, we'll create placeholder implementations
|
|
18
|
+
|
|
19
|
+
# Import existing frameworks for reference
|
|
20
|
+
from .mcp_decorator import mcp_agent
|
|
21
|
+
from .mcp_agent import MCPAgent
|
|
22
|
+
from .mcp_transport import HTTPTransport
|
|
23
|
+
|
|
24
|
+
except ImportError as e:
|
|
25
|
+
logger.warning(f"Some imports not available: {e}")
|
|
26
|
+
# Continue with available frameworks
|
|
27
|
+
|
|
28
|
+
@dataclass
|
|
29
|
+
class BeeAIAgent:
|
|
30
|
+
"""BeeAI Framework Agent - Placeholder Implementation"""
|
|
31
|
+
|
|
32
|
+
def __init__(self, agent_id: str, name: str, description: str = ""):
|
|
33
|
+
self.agent_id = agent_id
|
|
34
|
+
self.name = name
|
|
35
|
+
self.description = description
|
|
36
|
+
self.tasks = []
|
|
37
|
+
self.agent_tools = {}
|
|
38
|
+
self.mcp_id = agent_id
|
|
39
|
+
self.mcp_version = "0.1.0"
|
|
40
|
+
|
|
41
|
+
# Add basic tools similar to other frameworks
|
|
42
|
+
self._register_basic_tools()
|
|
43
|
+
|
|
44
|
+
def _register_basic_tools(self):
|
|
45
|
+
"""Register basic agent tools"""
|
|
46
|
+
|
|
47
|
+
async def bee_create_task(task: str) -> Dict[str, Any]:
|
|
48
|
+
"""Create a task in BeeAI"""
|
|
49
|
+
self.tasks.append({"task": task, "status": "created", "created_at": self._get_timestamp()})
|
|
50
|
+
return {"status": "success", "task_id": f"task_{len(self.tasks)}"}
|
|
51
|
+
|
|
52
|
+
async def bee_execute_task(task_id: str, inputs: Dict[str, Any]) -> Dict[str, Any]:
|
|
53
|
+
"""Execute a task"""
|
|
54
|
+
return {"status": "success", "result": f"Executed {task_id} with inputs: {inputs}"}
|
|
55
|
+
|
|
56
|
+
async def bee_list_tasks() -> Dict[str, Any]:
|
|
57
|
+
"""List all tasks"""
|
|
58
|
+
return {"status": "success", "tasks": self.tasks}
|
|
59
|
+
|
|
60
|
+
self.mcp_tools.update({
|
|
61
|
+
"bee_create_task": {
|
|
62
|
+
"description": "Create a new task",
|
|
63
|
+
"parameters": [
|
|
64
|
+
{"name": "task", "type": "string", "required": True, "description": "Task description"}
|
|
65
|
+
],
|
|
66
|
+
"function": bee_create_task
|
|
67
|
+
},
|
|
68
|
+
"bee_execute_task": {
|
|
69
|
+
"description": "Execute a task",
|
|
70
|
+
"parameters": [
|
|
71
|
+
{"name": "task_id", "type": "string", "required": True, "description": "Task ID to execute"},
|
|
72
|
+
{"name": "inputs", "type": "object", "required": False, "description": "Task inputs"}
|
|
73
|
+
],
|
|
74
|
+
"function": bee_execute_task
|
|
75
|
+
},
|
|
76
|
+
"bee_list_tasks": {
|
|
77
|
+
"description": "List all tasks",
|
|
78
|
+
"parameters": [],
|
|
79
|
+
"function": bee_list_tasks
|
|
80
|
+
}
|
|
81
|
+
})
|
|
82
|
+
|
|
83
|
+
@dataclass
|
|
84
|
+
class AgentGPTAgent:
|
|
85
|
+
"""AgentGPT Framework Agent - Placeholder Implementation"""
|
|
86
|
+
|
|
87
|
+
def __init__(self, agent_id: str, name: str, description: str = ""):
|
|
88
|
+
self.agent_id = agent_id
|
|
89
|
+
self.name = name
|
|
90
|
+
self.description = description
|
|
91
|
+
self.conversations = []
|
|
92
|
+
self.agent_tools = {}
|
|
93
|
+
self.mcp_id = agent_id
|
|
94
|
+
self.mcp_version = "0.1.0"
|
|
95
|
+
|
|
96
|
+
self._register_basic_tools()
|
|
97
|
+
|
|
98
|
+
def _register_basic_tools(self):
|
|
99
|
+
"""Register basic agent tools"""
|
|
100
|
+
|
|
101
|
+
async def agentgpt_create_conversation(conversation_id: str = None) -> Dict[str, Any]:
|
|
102
|
+
"""Create a conversation"""
|
|
103
|
+
conv_id = conversation_id or f"conv_{len(self.conversations)}"
|
|
104
|
+
self.conversations.append({"id": conv_id, "created_at": self._get_timestamp(), "messages": []})
|
|
105
|
+
return {"status": "success", "conversation_id": conv_id}
|
|
106
|
+
|
|
107
|
+
async def agentgpt_send_message(conversation_id: str, message: str) -> Dict[str, Any]:
|
|
108
|
+
"""Send a message in conversation"""
|
|
109
|
+
for conv in self.conversations:
|
|
110
|
+
if conv["id"] == conversation_id:
|
|
111
|
+
conv["messages"].append({"role": "user", "content": message, "timestamp": self._get_timestamp()})
|
|
112
|
+
return {"status": "success", "message": "Message sent"}
|
|
113
|
+
return {"status": "error", "message": "Conversation not found"}
|
|
114
|
+
|
|
115
|
+
async def agentgpt_list_conversations() -> Dict[str, Any]:
|
|
116
|
+
"""List all conversations"""
|
|
117
|
+
return {"status": "success", "conversations": self.conversations}
|
|
118
|
+
|
|
119
|
+
self.mcp_tools.update({
|
|
120
|
+
"agentgpt_create_conversation": {
|
|
121
|
+
"description": "Create a conversation",
|
|
122
|
+
"parameters": [
|
|
123
|
+
{"name": "conversation_id", "type": "string", "required": False, "description": "Conversation ID (optional)"},
|
|
124
|
+
{"name": "message", "type": "string", "required": True, "description": "Message to send"}
|
|
125
|
+
],
|
|
126
|
+
"function": agentgpt_create_conversation
|
|
127
|
+
},
|
|
128
|
+
"agentgpt_send_message": {
|
|
129
|
+
"description": "Send a message",
|
|
130
|
+
"parameters": [
|
|
131
|
+
{"name": "conversation_id", "type": "string", "required": True, "description": "Conversation ID"},
|
|
132
|
+
{"name": "message", "type": "string", "required": True, "description": "Message to send"}
|
|
133
|
+
],
|
|
134
|
+
"function": agentgpt_send_message
|
|
135
|
+
},
|
|
136
|
+
"agentgpt_list_conversations": {
|
|
137
|
+
"description": "List all conversations",
|
|
138
|
+
"parameters": [],
|
|
139
|
+
"function": agentgpt_list_conversations
|
|
140
|
+
}
|
|
141
|
+
})
|
|
142
|
+
|
|
143
|
+
def _get_timestamp(self) -> str:
|
|
144
|
+
"""Get current timestamp"""
|
|
145
|
+
import datetime
|
|
146
|
+
return datetime.now().isoformat()
|
|
147
|
+
|
|
148
|
+
@dataclass
|
|
149
|
+
class SuperAGIAgent:
|
|
150
|
+
"""SuperAGI Framework Agent - Placeholder Implementation"""
|
|
151
|
+
|
|
152
|
+
def __init__(self, agent_id: str, name: str, description: str = ""):
|
|
153
|
+
self.agent_id = agent_id
|
|
154
|
+
self.name = name
|
|
155
|
+
self.description = description
|
|
156
|
+
self.agent_tools = {}
|
|
157
|
+
self.mcp_id = agent_id
|
|
158
|
+
self.mcp_version = "0.1.0"
|
|
159
|
+
|
|
160
|
+
self._register_basic_tools()
|
|
161
|
+
|
|
162
|
+
def _register_basic_tools(self):
|
|
163
|
+
"""Register basic agent tools"""
|
|
164
|
+
|
|
165
|
+
async def superagi_create_agent(agent_config: Dict[str, Any]) -> Dict[str, Any]:
|
|
166
|
+
"""Create a super-agent"""
|
|
167
|
+
agent_id = f"agent_{len(self.agent_tools) + 1}"
|
|
168
|
+
return {"status": "success", "agent_id": agent_id, "config": agent_config}
|
|
169
|
+
|
|
170
|
+
async def superagi_run_workflow(workflow_config: Dict[str, Any]) -> Dict[str, Any]:
|
|
171
|
+
"""Run a workflow"""
|
|
172
|
+
return {"status": "success", "workflow_id": f"workflow_{len(self.agent_tools) + 1}", "result": "Workflow executed"}
|
|
173
|
+
|
|
174
|
+
async def superagi_list_agents() -> Dict[str, Any]:
|
|
175
|
+
"""List all agents"""
|
|
176
|
+
return {"status": "success", "agents": list(self.agent_tools.keys())}
|
|
177
|
+
|
|
178
|
+
self.mcp_tools.update({
|
|
179
|
+
"superagi_create_agent": {
|
|
180
|
+
"description": "Create a super-agent",
|
|
181
|
+
"parameters": [
|
|
182
|
+
{"name": "config", "type": "object", "required": True, "description": "Agent configuration"}
|
|
183
|
+
],
|
|
184
|
+
"function": superagi_create_agent
|
|
185
|
+
},
|
|
186
|
+
"superagi_run_workflow": {
|
|
187
|
+
"description": "Run a workflow",
|
|
188
|
+
"parameters": [
|
|
189
|
+
{"name": "workflow", "type": "object", "required": True, "description": "Workflow configuration"}
|
|
190
|
+
],
|
|
191
|
+
"function": superagi_run_workflow
|
|
192
|
+
},
|
|
193
|
+
"superagi_list_agents": {
|
|
194
|
+
"description": "List all agents",
|
|
195
|
+
"parameters": [],
|
|
196
|
+
"function": superagi_list_agents
|
|
197
|
+
}
|
|
198
|
+
})
|
|
199
|
+
|
|
200
|
+
@dataclass
|
|
201
|
+
class FractalAgent:
|
|
202
|
+
"""Fractal Framework Agent - Placeholder Implementation"""
|
|
203
|
+
|
|
204
|
+
def __init__(self, agent_id: str, name: str, description: str = ""):
|
|
205
|
+
self.agent_id = agent_id
|
|
206
|
+
self.name = name
|
|
207
|
+
self.description = description
|
|
208
|
+
self.contracts = []
|
|
209
|
+
self.agent_tools = {}
|
|
210
|
+
self.mcp_id = agent_id
|
|
211
|
+
self.mcp_version = "0.1.0"
|
|
212
|
+
|
|
213
|
+
self._register_basic_tools()
|
|
214
|
+
|
|
215
|
+
def _register_basic_tools(self):
|
|
216
|
+
"""Register basic agent tools"""
|
|
217
|
+
|
|
218
|
+
async def fractal_create_contract(contract_data: Dict[str, Any]) -> Dict[str, Any]:
|
|
219
|
+
"""Create a smart contract"""
|
|
220
|
+
contract_id = f"contract_{len(self.contracts) + 1}"
|
|
221
|
+
self.contracts.append({"id": contract_id, "data": contract_data, "created_at": self._get_timestamp()})
|
|
222
|
+
return {"status": "success", "contract_id": contract_id}
|
|
223
|
+
|
|
224
|
+
async def fractal_execute_contract(contract_id: str, params: Dict[str, Any]) -> Dict[str, Any]:
|
|
225
|
+
"""Execute a contract"""
|
|
226
|
+
return {"status": "success", "contract_id": contract_id, "result": "Contract executed"}
|
|
227
|
+
|
|
228
|
+
async def fractal_list_contracts() -> Dict[str, Any]:
|
|
229
|
+
"""List all contracts"""
|
|
230
|
+
return {"status": "success", "contracts": self.contracts}
|
|
231
|
+
|
|
232
|
+
async def fractal_deploy_agent(agent_id: str, network: str) -> Dict[str, Any]:
|
|
233
|
+
"""Deploy agent to network"""
|
|
234
|
+
return {"status": "success", "agent_id": agent_id, "network": network, "result": "Agent deployed"}
|
|
235
|
+
|
|
236
|
+
self.mcp_tools.update({
|
|
237
|
+
"fractal_create_contract": {
|
|
238
|
+
"description": "Create a smart contract",
|
|
239
|
+
"parameters": [
|
|
240
|
+
{"name": "contract_data", "type": "object", "required": True, "description": "Contract data"},
|
|
241
|
+
{"name": "params", "type": "object", "required": False, "description": "Contract parameters"}
|
|
242
|
+
],
|
|
243
|
+
"function": fractal_create_contract
|
|
244
|
+
},
|
|
245
|
+
"fractal_execute_contract": {
|
|
246
|
+
"description": "Execute a contract",
|
|
247
|
+
"parameters": [
|
|
248
|
+
{"name": "contract_id", "type": "string", "required": True, "description": "Contract ID"},
|
|
249
|
+
{"name": "params", "type": "object", "required": False, "description": "Contract parameters"}
|
|
250
|
+
],
|
|
251
|
+
"function": fractal_execute_contract
|
|
252
|
+
},
|
|
253
|
+
"fractal_list_contracts": {
|
|
254
|
+
"description": "List all contracts",
|
|
255
|
+
"parameters": [],
|
|
256
|
+
"function": fractal_list_contracts
|
|
257
|
+
},
|
|
258
|
+
"fractal_deploy_agent": {
|
|
259
|
+
"description": "Deploy agent to network",
|
|
260
|
+
"parameters": [
|
|
261
|
+
{"name": "agent_id", "type": "string", "required": True, "definirion": "Agent ID to deploy"},
|
|
262
|
+
{"name": "network", "type": "string", "required": True, "description": "Network to deploy to"}
|
|
263
|
+
],
|
|
264
|
+
"function": fractal_deploy_agent
|
|
265
|
+
}
|
|
266
|
+
})
|
|
267
|
+
|
|
268
|
+
@dataclass
|
|
269
|
+
class SwarmAgent:
|
|
270
|
+
"""OpenAI Swarm Framework Agent - Placeholder Implementation"""
|
|
271
|
+
|
|
272
|
+
def __init__(self, agent_id: str, name: str, description: str = ""):
|
|
273
|
+
self.agent_id = agent_id
|
|
274
|
+
self.name = name
|
|
275
|
+
self.description = description
|
|
276
|
+
self.agents = []
|
|
277
|
+
self.agent_tools = {}
|
|
278
|
+
self.mcp_id = agent_id
|
|
279
|
+
self.mcp_version = "0.1.0"
|
|
280
|
+
|
|
281
|
+
self._register_basic_tools()
|
|
282
|
+
|
|
283
|
+
def _register_basic_tools(self):
|
|
284
|
+
"""Register basic agent tools"""
|
|
285
|
+
|
|
286
|
+
async def swarm_create_agent(agent_config: Dict[str, Any]) -> Dict[str, Any]:
|
|
287
|
+
"""Create a Swarm agent"""
|
|
288
|
+
agent_id = f"agent_{len(self.agents) + 1}"
|
|
289
|
+
return {"status": "success", "agent_id": agent_id, "config": agent_config}
|
|
290
|
+
|
|
291
|
+
async def swarm_handoff(agent_id: str, target_agent_id: str) -> Dict[str, Any]:
|
|
292
|
+
"""Hand off to another agent"""
|
|
293
|
+
return {"status": "success", "handoff_from": agent_id, "handoff_to": target_agent_id}
|
|
294
|
+
|
|
295
|
+
async def swarm_coordinate_agents(agent_ids: List[str], task: str) -> Dict[str, Any]:
|
|
296
|
+
"""Coordinate multiple agents"""
|
|
297
|
+
return {"status": "success", "coordinated_agents": agent_ids, "task": task}
|
|
298
|
+
|
|
299
|
+
self.mcp_tools.update({
|
|
300
|
+
"swarm_create_agent": {
|
|
301
|
+
"description": "Create a Swarm agent",
|
|
302
|
+
"parameters": [
|
|
303
|
+
{"name": "config", "type": "object", "required": True, "description": "Agent configuration"},
|
|
304
|
+
{"name": "handoff_to", "type": "string", "required": True, "description": "Target agent ID for handoff"},
|
|
305
|
+
{"name": "agent_ids", "type": "array", "required": True, "definirion": "Agent IDs to coordinate"},
|
|
306
|
+
{"name": "task", "type": "string", "required": True, "description": "Task to coordinate"}
|
|
307
|
+
],
|
|
308
|
+
"function": swarm_create_agent
|
|
309
|
+
},
|
|
310
|
+
"swarm_handoff": {
|
|
311
|
+
"description": "Hand off to another agent",
|
|
312
|
+
"parameters": [
|
|
313
|
+
{"name": "agent_id", "type": "string", "required": True, "description": "Source agent ID"},
|
|
314
|
+
{"name": "target_agent_id", "type": "string", "required": True, "description": "Target agent ID for handoff"}
|
|
315
|
+
],
|
|
316
|
+
"function": swarm_handoff
|
|
317
|
+
},
|
|
318
|
+
"swarm_coordinate_agents": {
|
|
319
|
+
"description": "Coordinate multiple agents",
|
|
320
|
+
"parameters": [
|
|
321
|
+
{"name": "agent_ids", "type": "array", "required": True, "definirion": "Agent IDs to coordinate"},
|
|
322
|
+
{"name": "task", "type": "string", "required": True, "description": "Task to coordinate"}
|
|
323
|
+
],
|
|
324
|
+
"function": swarm_coordinate_agents
|
|
325
|
+
}
|
|
326
|
+
})
|
|
327
|
+
|
|
328
|
+
def _get_timestamp(self) -> str:
|
|
329
|
+
"""Get current timestamp"""
|
|
330
|
+
import datetime
|
|
331
|
+
return datetime.now().isoformat()
|
|
332
|
+
|
|
333
|
+
# Factory functions for easy creation
|
|
334
|
+
def create_beeai_agent(agent_id: str, name: str, description: str = "") -> BeeAIAgent:
|
|
335
|
+
"""Create a BeeAI agent with MCP integration"""
|
|
336
|
+
return BeeAIAgent(agent_id, name, description)
|
|
337
|
+
|
|
338
|
+
def create_agentgpt_agent(agent_id: str, name: str, description: str = "") -> AgentGPTAgent:
|
|
339
|
+
"""Create an AgentGPT agent with MCP integration"""
|
|
340
|
+
return AgentGPTAgent(agent_id, name, description)
|
|
341
|
+
|
|
342
|
+
def create_superagi_agent(agent_id: str, name: str, description: str = "") -> SuperAGIAgent:
|
|
343
|
+
"""Create a SuperAGI agent with MCP integration"""
|
|
344
|
+
return SuperAGIAgent(agent_id, name, description)
|
|
345
|
+
|
|
346
|
+
def create_fractal_agent(agent_id: str, name: str, description: str = "") -> FractalAgent:
|
|
347
|
+
"""Create a Fractal agent with MCP integration"""
|
|
348
|
+
return FractalAgent(agent_id, name, description)
|
|
349
|
+
|
|
350
|
+
def create_swarm_agent(agent_id: str, name: str, description: str = "") -> SwarmAgent:
|
|
351
|
+
"""Create a Swarm agent with MCP integration"""
|
|
352
|
+
return SwarmAgent(agent_id, name, description)
|
|
353
|
+
|
|
354
|
+
# Registry for the new frameworks
|
|
355
|
+
MISSING_FRAMEWORKS = {
|
|
356
|
+
"BeeAI": {
|
|
357
|
+
"name": "BeeAI",
|
|
358
|
+
"class": BeeAIAgent,
|
|
359
|
+
"description": "BeeAI agent framework for autonomous workflow orchestration",
|
|
360
|
+
"website": "https://framework.beeai.dev",
|
|
361
|
+
"category": "autonomous_workflows",
|
|
362
|
+
"maturity": "growing",
|
|
363
|
+
"use_cases": ["task_decomposition", "multi_agent_coordination", "autonomous_execution"]
|
|
364
|
+
},
|
|
365
|
+
"AgentGPT": {
|
|
366
|
+
"name": "AgentGPT",
|
|
367
|
+
"class": AgentGPTAgent,
|
|
368
|
+
"description": "AgentGPT framework for conversation-based AI agents",
|
|
369
|
+
"website": "https://agentgpt.com",
|
|
370
|
+
"category": "conversational_agents",
|
|
371
|
+
"maturity": "stable",
|
|
372
|
+
"use_cases": ["customer_support", "personal_assistants", "task_coordination", "content_generation"]
|
|
373
|
+
},
|
|
374
|
+
"SuperAGI": {
|
|
375
|
+
"name": "SuperAGI",
|
|
376
|
+
"class": SuperAGIAgent,
|
|
377
|
+
"description": "SuperAGI framework for autonomous multi-agent systems",
|
|
378
|
+
"website": "https://superagi.com",
|
|
379
|
+
"category": "autonomous_platforms",
|
|
380
|
+
"maturity": "rapidly_developing",
|
|
381
|
+
"use_cases": ["enterprise_automation", "research_tasks", "multi_agent_orchestration", "long_running_tasks"]
|
|
382
|
+
},
|
|
383
|
+
"Fractal": {
|
|
384
|
+
"name": "Fractal",
|
|
385
|
+
"class": FractalAgent,
|
|
386
|
+
"description": "Fractal framework for smart contract-based multi-agent systems",
|
|
387
|
+
"website": "https://fractal.ai",
|
|
388
|
+
"category": "blockchain_agents",
|
|
389
|
+
"maturity": "production_ready",
|
|
390
|
+
"use_cases": ["defi_decentralized_applications", "automated_trading", "multi_agent_economics", "token_gated_services"]
|
|
391
|
+
},
|
|
392
|
+
"Swarm": {
|
|
393
|
+
"name": "Swarm",
|
|
394
|
+
"class": SwarmAgent,
|
|
395
|
+
"description": "OpenAI Swarm framework for agent handoff and coordination",
|
|
396
|
+
"website": "https://openai.com/swarm",
|
|
397
|
+
"category": "agent_coordination",
|
|
398
|
+
"maturity": "experimental",
|
|
399
|
+
"use_cases": ["task_specialization", "agent_handoff", "parallel_processing", "workflow_orchestration"]
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
# Example usage for the enhanced agent framework
|
|
404
|
+
def create_multi_framework_agent(
|
|
405
|
+
agent_id: str,
|
|
406
|
+
name: str,
|
|
407
|
+
framework: str,
|
|
408
|
+
description: str = "",
|
|
409
|
+
**kwargs
|
|
410
|
+
):
|
|
411
|
+
"""Create an agent with the specified framework"""
|
|
412
|
+
if framework == "beeai":
|
|
413
|
+
return create_beeai_agent(agent_id, name, description)
|
|
414
|
+
elif framework == "agentgpt":
|
|
415
|
+
return create_agentgpt_agent(agent_id, name, description)
|
|
416
|
+
elif framework == "superagi":
|
|
417
|
+
return create_superagi_agent(agent_id, name, description)
|
|
418
|
+
elif framework == "fractal":
|
|
419
|
+
return create_fractal_agent(agent_id, name, description)
|
|
420
|
+
elif framework == "swarm":
|
|
421
|
+
return create_swarm_agent(agent_id, name, description)
|
|
422
|
+
else:
|
|
423
|
+
# Default to existing behavior
|
|
424
|
+
return mcp_agent(agent_id, name, description)
|
|
425
|
+
|
|
426
|
+
# Export for easy access
|
|
427
|
+
__all__ = [
|
|
428
|
+
'BeeAIAgent',
|
|
429
|
+
'AgentGPTAgent',
|
|
430
|
+
'SuperAGIAgent',
|
|
431
|
+
'FractalAgent',
|
|
432
|
+
'SwarmAgent',
|
|
433
|
+
'create_multi_framework_agent',
|
|
434
|
+
'MISSING_FRAMEWORKS'
|
|
435
|
+
]
|