Loading tools dynamically as JSON at runtime ? #1499
-
|
Hello everyone, From the documentation (https://strandsagents.com/latest/documentation/docs/user-guide/concepts/tools/#building-loading-tools) I understand that we have 2 ways to load tools for an agent : as function or as python module Is there any way to load tools "dynamically" at runtime directly with a JSON instead ? I have all of my tools configs currently stored and versioned outside the application, and that allow me to publish new tool configs without deploying code (and even A/B testing different version of the same tools dynamically). I was something I can do if I call directly the LLM provider (like converse API from Bedrock or OpenAI API) but I couldn't find a way to do it with Strand Agents. Any idea ? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Two related notes:
|
Beta Was this translation helpful? Give feedback.
Thanks for the quick feedback @zastrowm !
I found this section in the user guide:
https://strandsagents.com/latest/documentation/docs/user-guide/concepts/tools/#auto-loading-and-reloading-tools
From my understanding, it only supports module-based tools, which means I would need to generate a Python file from my JSON configuration.
And regarding
AgentConfig, it looks very promising! According to the documentation, the tools attribute also expects module-based or function-based tools. It could be a great enhancement to support direct JSON-based configuration as well.