From d5bfef33ca97d5dab09679ed591f9094d0a11e38 Mon Sep 17 00:00:00 2001 From: Cyber MacGeddon Date: Wed, 16 Jul 2025 22:01:23 +0100 Subject: [PATCH] Fix agent tools, now all tested --- trustgraph-flow/trustgraph/agent/react/agent_manager.py | 2 +- trustgraph-flow/trustgraph/agent/react/tools.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/trustgraph-flow/trustgraph/agent/react/agent_manager.py b/trustgraph-flow/trustgraph/agent/react/agent_manager.py index 7405d7e1..391f188b 100644 --- a/trustgraph-flow/trustgraph/agent/react/agent_manager.py +++ b/trustgraph-flow/trustgraph/agent/react/agent_manager.py @@ -39,7 +39,7 @@ class AgentManager: "type": arg.type, "description": arg.description } - for arg in tool.arguments.values() + for arg in tool.arguments ] } for tool in self.tools.values() diff --git a/trustgraph-flow/trustgraph/agent/react/tools.py b/trustgraph-flow/trustgraph/agent/react/tools.py index 09c6cd92..80b5ba9a 100644 --- a/trustgraph-flow/trustgraph/agent/react/tools.py +++ b/trustgraph-flow/trustgraph/agent/react/tools.py @@ -95,7 +95,7 @@ class PromptImpl: async def invoke(self, **arguments): client = self.context("prompt-request") print(f"Prompt template invocation: {self.template_id}...", flush=True) - return await client.template( - template_id=self.template_id, + return await client.prompt( + id=self.template_id, variables=arguments )