You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For now you could just add code there to create any of the 8 'official' tools whose class names are stored and whose 'required environment variables' (in the README) are defined properly.
P.S.
Actually it looks like if you just fix the Google and Weather tools to have defaults in their initalize like NewsRetriever below, you should be all set just doing ToolName.new on each.
I created an ApplicationTool in my application, and all tools inherit from it. It has a unified initialization signature. This allows a strong convention for retrieving API keys and other information from the environment. This allows us to store the tools as an array ([langchain/tool/name, ...]) on the assistant.
Currently when using the
langchainrb_rails:assistant
generator, we just store the class names of tools: https://github.com/patterns-ai-core/langchainrb_rails/blob/main/lib/langchainrb_overrides/assistant.rb#L27. This is problematic as tools are oftentimes instantiated with various environment variables. Should we store the initialization info as well?The text was updated successfully, but these errors were encountered: