Skip to content
Discussion options

You must be logged in to vote

Have you tried using a pre-built agent with the json tools?

from langgraph.prebuilt import create_react_agent
...
son_spec = JsonSpec(dict_=data, max_value_length=4000)
json_toolkit = JsonToolkit(spec=json_spec)
...
graph = create_react_agent(model, tools=json_toolkit.get_tools())

https://langchain-ai.github.io/langgraph/how-tos/create-react-agent/#setup
https://python.langchain.com/docs/integrations/tools/json/

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@sherryxiao1988
Comment options

Answer selected by sherryxiao1988
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants