ReAct Prompting
Domain: Prompt Engineering
π― Motivation
Reasoning + Acting: the model alternates between thinking (reasoning) and taking actions (calling tools, searching) to solve complex tasks.
π Concrete Example
Thought: βI need to know the weather.β Action: search_weather(βHong Kongβ). Observation: β28C, sunny.β Thought: βNow I can recommend outdoor activities.β Action: generate_response().
π Analogy
A detective solving a case - they think (reasoning), then act (interview a witness), then think again based on what they learned. ReAct makes the LLM alternate between thinking and acting.