distributed-a2a 0.1.9rc10__tar.gz → 0.1.9rc12__tar.gz
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.
- {distributed_a2a-0.1.9rc10/distributed_a2a.egg-info → distributed_a2a-0.1.9rc12}/PKG-INFO +1 -1
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/executors.py +8 -4
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12/distributed_a2a.egg-info}/PKG-INFO +1 -1
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/pyproject.toml +1 -1
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/LICENSE +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/MANIFEST.in +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/README.md +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/__init__.py +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/agent.py +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/client.py +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/model.py +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/registry.py +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/router.py +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a/server.py +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a.egg-info/SOURCES.txt +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a.egg-info/dependency_links.txt +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a.egg-info/requires.txt +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a.egg-info/top_level.txt +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/requirements.txt +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/setup.cfg +0 -0
- {distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/setup.py +0 -0
|
@@ -30,7 +30,7 @@ class RoutingAgentExecutor(AgentExecutor):
|
|
|
30
30
|
api_key = os.environ.get(agent_config.agent.llm.api_key_env)
|
|
31
31
|
if api_key is None:
|
|
32
32
|
raise ValueError("No API key found for LLM.")
|
|
33
|
-
self.mcp_registry = McpRegistryLookup(registry_url=agent_config.registry.mcp.url)
|
|
33
|
+
self.mcp_registry = McpRegistryLookup(registry_url=agent_config.agent.registry.mcp.url)
|
|
34
34
|
self.agent_config = agent_config
|
|
35
35
|
self.registered_tools = {}
|
|
36
36
|
self.api_key = api_key
|
|
@@ -63,7 +63,7 @@ class RoutingAgentExecutor(AgentExecutor):
|
|
|
63
63
|
final=False,
|
|
64
64
|
context_id=context.context_id,
|
|
65
65
|
task_id=context.task_id))
|
|
66
|
-
self.reinitialize_agent_with_tools()
|
|
66
|
+
await self.reinitialize_agent_with_tools()
|
|
67
67
|
agent_response: StringResponse = await self.agent(message=context.get_user_input(),
|
|
68
68
|
context_id=context.context_id)
|
|
69
69
|
|
|
@@ -104,12 +104,16 @@ class RoutingAgentExecutor(AgentExecutor):
|
|
|
104
104
|
context_id=context.context_id,
|
|
105
105
|
task_id=context.task_id))
|
|
106
106
|
|
|
107
|
-
def reinitialize_agent_with_tools(self):
|
|
107
|
+
async def reinitialize_agent_with_tools(self):
|
|
108
108
|
mcp_tools = self.mcp_registry.get_mcp_tool_for_agent(self.agent_config.agent.card.name)
|
|
109
|
+
if not mcp_tools:
|
|
110
|
+
#no mcp tool found no need to reinitialize Agent
|
|
111
|
+
return
|
|
112
|
+
|
|
109
113
|
logger.info(f"Agent {self.agent_config.agent.card.name} has access to the following tools: {mcp_tools}")
|
|
110
114
|
tools = {tool["name"]: {"url": tool["url"], "transport": tool["protocol"]} for tool in mcp_tools}
|
|
111
115
|
mcp_client = MultiServerMCPClient(tools)
|
|
112
|
-
mcp_tools = mcp_client.get_tools()
|
|
116
|
+
mcp_tools = await mcp_client.get_tools()
|
|
113
117
|
|
|
114
118
|
self.agent = StatusAgent[StringResponse](
|
|
115
119
|
llm_config=self.agent_config.agent.llm,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
{distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a.egg-info/requires.txt
RENAMED
|
File without changes
|
{distributed_a2a-0.1.9rc10 → distributed_a2a-0.1.9rc12}/distributed_a2a.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|