Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core[patch]: Allow runnable tools to take single string/ToolCall inputs #6096

Merged
merged 14 commits into from
Jul 17, 2024

Conversation

bracesproul
Copy link
Collaborator

@bracesproul bracesproul commented Jul 16, 2024

  • Rename ZodAny to ZodObjectAny
  • Update .asTool to handle converting ToolCall inputs to the proper input for the runnable
  • Update .asTool input typing to accept T or ToolCall

Copy link

vercel bot commented Jul 16, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
langchainjs-api-refs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 17, 2024 5:46pm
langchainjs-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 17, 2024 5:46pm

@bracesproul bracesproul marked this pull request as ready for review July 16, 2024 22:53
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. auto:improvement Medium size change to existing code to handle new use-cases labels Jul 16, 2024
@jacoblee93
Copy link
Collaborator

What does this look like if passed to an agent?

@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. and removed size:M This PR changes 30-99 lines, ignoring generated files. labels Jul 16, 2024
@bracesproul bracesproul marked this pull request as draft July 16, 2024 23:46
@bracesproul bracesproul marked this pull request as ready for review July 17, 2024 01:00
@@ -48,6 +48,7 @@
"@langchain/google-vertexai": "workspace:*",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey there! 👋 I noticed that this PR adds a new peer dependency for "@langchain/langgraph". This comment is just to flag this change for the maintainers to review. Keep up the great work! 🚀

@bracesproul bracesproul changed the title core[patch]: Allow runnable tools to take single string inputs core[patch]: Allow runnable tools to take single string/ToolCall inputs Jul 17, 2024
@jacoblee93
Copy link
Collaborator

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto:improvement Medium size change to existing code to handle new use-cases size:L This PR changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants