create_agent
An API in LangChain 1.x for creating an agent. It returns a LangGraph graph in which the model determines the next action.
Core Facts
Timeline (last 90 days)
In LangChain's create_agent, when Anthropic returns pause_turn, the paused turn is returned directly as the final answer, with no error prompt (corresponding to issue #41625).
LangChain 1.0 consolidates all entry points for creating Agents into a single globally unified entry point, create_agent.
The core addition in ARCI v2.0 is the LangChain adapter, which can run create_agent configurations inside the fault-injection regression gate.
LangChain's `create_agent` API encapsulates model settings, tool list loading and System Prompt configuration together.
LangChain's create_agent + SqliteSaver default configuration amplifies untrusted input on disk by 10.4x
When creating an Agent with LangChain's create_agent, the model parameter specifies the large model and the tools parameter specifies the list of tools; get_stock_price and search_news in the course examples are LangChain built-in tools and have nothing to do with MCP.
In LangChain, the system prompt is passed via system_prompt configuration to convey identity, instructions, and output examples, then create_agent is used to bind the model and prompt, and finally invoke is used to trigger the call.
create_agent accepts the checkpointer, store, interrupt_before, interrupt_after, and middleware list parameters.
In LangChain 1.4.3, create_agent returns an object of type CompiledStateGraph (a LangGraph graph) rather than a chain.
The minimal graph built by create_agent has nodes ['__start__', 'model', 'tools', '__end__'], where the model node calls the large model, the tools node executes the tools requested by the model, and the loop repeats until the model no longer requests tools.
9 more timeline events
All Facts (20)
The create_react_agent in LangGraph is implemented based on the ReAct paradigm, allowing the model to reason at each step and decide whether to call a tool or output a final answer.
80%UnverifiedLangChain's `create_agent` API encapsulates model settings, tool list loading and System Prompt configuration together.
60%UnverifiedIn LangChain's create_agent, when Anthropic returns pause_turn, the paused turn is returned directly as the final answer, with no error prompt (corresponding to issue #41625).
50%UnverifiedLangChain 1.0 consolidates all entry points for creating Agents into a single globally unified entry point, create_agent.
50%UnverifiedLangChain's create_agent + SqliteSaver default configuration amplifies untrusted input on disk by 10.4x
50%UnverifiedWhen creating an Agent with LangChain's create_agent, the model parameter specifies the large model and the tools parameter specifies the list of tools; get_stock_price and search_news in the course examples are LangChain built-in tools and have nothing to do with MCP.
50%UnverifiedIn LangChain, the system prompt is passed via system_prompt configuration to convey identity, instructions, and output examples, then create_agent is used to bind the model and prompt, and finally invoke is used to trigger the call.
50%UnverifiedThe minimal graph built by create_agent has nodes ['__start__', 'model', 'tools', '__end__'], where the model node calls the large model, the tools node executes the tools requested by the model, and the loop repeats until the model no longer requests tools.
50%Unverifiedcreate_react_agent in langgraph.prebuilt has been marked as deprecated in the tested version, with create_agent recommended instead.
50%UnverifiedWhen using create_agent, checkpointing capability can be obtained directly just by passing the checkpointer parameter, without writing a graph by hand.
50%Unverifiedcreate_agent accepts the checkpointer, store, interrupt_before, interrupt_after, and middleware list parameters.
50%UnverifiedWhen using human approval, the first invoke causes the agent to pause, and a __interrupt__ key appears in the result, whose payload contains action_requests and review_configs.
50%UnverifiedLangChain's official documentation calls create_agent a "minimal, highly configurable harness," while LangGraph's documentation describes itself as a low-level orchestration framework and runtime for long-running, stateful agents.
50%UnverifiedIn LangChain 1.4.3, create_agent returns an object of type CompiledStateGraph (a LangGraph graph) rather than a chain.
50%UnverifiedThe create_agent() provided by LangChain is essentially a factory function, implemented internally based on LangGraph
50%Unverifiedcreate_agent() requires three parameters: tools, model, and system prompt
50%UnverifiedRunning the Agent is as simple as passing the user query via the agent.invoke() method, with message history maintenance and loop control handled internally by the framework
50%UnverifiedLangChain 1.4.3 adds logic to create_agent to fix invalid tool calls, which can automatically correct tool call parameters with formatting errors or missing fields.
50%UnverifiedLangChain 1.0 uniformly uses create_agent as the entry point for creating agents, ending the confusion caused by more than ten creation methods in older versions.
50%UnverifiedThe core addition in ARCI v2.0 is the LangChain adapter, which can run create_agent configurations inside the fault-injection regression gate.
50%