langgraph/how-tos/create-react-agent-system-prompt/ #1060
Replies: 7 comments 4 replies
-
Is there a way a system prompt can be added to a self-discover model? Also, how does one integrate the human-in-the-loop in self-discover so that the model allows self updates. |
Beta Was this translation helpful? Give feedback.
-
Caught me out the state_modifier was removed see below:
|
Beta Was this translation helpful? Give feedback.
-
I try to use this react agent in a FastAPI server where I create an endpoint with langserve. Problem is data validation. Currently deploying the endpoint with: Is there any documentation on what the data model has to look like for LangGraph if you want to do input validation? |
Beta Was this translation helpful? Give feedback.
-
Is there a way to integrate ReAct agent with StateGraph? |
Beta Was this translation helpful? Give feedback.
-
Why no use of |
Beta Was this translation helpful? Give feedback.
-
What is the difference between 'tool calling agent'? |
Beta Was this translation helpful? Give feedback.
-
I have a simple use of def state_modifier(state: AgentState) -> Sequence[BaseMessage]:
# Track the number of calls to the agent
llm_calls = state.get("llm_calls", 0)
state["llm_calls"] = llm_calls + 1 # problem, this does NOT update state
# Add the adequate system message to the beginning of the messages
messages = list(state.get("messages", []))
content = (
SystemMessages.lg_react_last()
if llm_calls > 0
else SystemMessages.lg_react_first(self.seeq_context)
)
messages.insert(0, SystemMessage(content))
# Return the messages
return messages So my question is how can I mutate the |
Beta Was this translation helpful? Give feedback.
-
langgraph/how-tos/create-react-agent-system-prompt/
Build language agents as graphs
https://langchain-ai.github.io/langgraph/how-tos/create-react-agent-system-prompt/
Beta Was this translation helpful? Give feedback.
All reactions