Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Builds a LangGraph 1.0 ReAct agent with create_react_agent, typed tools, recursion caps, and error propagation.
68% 100%+32 ptsof test cases passed
Passed 22 of 22 test cases with the skill, and 15 of 22 without it.
When invoking a LangGraph ReAct agent created with create_react_agent, what is the required top-level dictionary key for sending conversation history or new user prompts?
The response states that the messages value is a list.
3 of 3 safety checks passed
Two failure modes hit every team writing their first LangGraph 1.0 ReAct agent:
Loop-to-cap on vague prompts (P10). create_react_agent defaults to
recursion_limit=25. A prompt like "help me with my account" never converges —
the model calls a retrieval tool, gets irrelevant results, calls another tool,
and repeats until GraphRecursionError: Recursion limit of 25 reached without hitting a stop condition fires. Cost dashboards show the damage after the
fact: $5-$15 per runaway loop on Sonnet with a 3-tool agent, assuming no tool
is itself expensive.
Silent tool errors on legacy AgentExecutor (P09). The legacy executor
defaults handle_parsing_errors=True and catches tool exceptions, feeding the
error string back as the next observation. When the error serializes to empty
(e.g., a ValueError("") or an HTTP 500 with no body), the loop continues with
no signal. The agent says "I couldn't find the answer" — which was actually a
silent crash three tool calls ago.
This skill walks through defining typed tools with @tool + Pydantic; building
an agent with create_react_agent(model, tools, checkpointer=MemorySaver());
invoking with {"messages": [...]} and a thread-scoped config; setting
recursion_limit per expected agent depth (5-10 interactive, 20-30 planner);
adding middleware for a per-session token budget; and raise-by-default error
propagation. Pin: langgraph >= 1.0, < 2.0, langchain-core >= 1.0, < 2.0.
Pain-catalog anchors: P09, P10, P11, P32, P41, P42, P63.
langgraph >= 1.0, < 2.0 and langchain-core >= 1.0, < 2.0pip install langchain-anthropic or langchain-openailangchain-langgraph-basics (L25) — you already know StateGraph,
MessagesState, and checkpointersANTHROPIC_API_KEY or OPENAI_API_KEYSkills that do similar work, with their benchmark result.
Next to this one in the catalogue, plus more from the same author.