Tool-Use Agent Loop for Stock Questions
Asked at Anthropic · LLMs & Prompt Engineering · Difficulty: Medium · Last asked Jun 29, 2026
Build the loop that turns a language model into a tool-using agent for stock questions. The model cannot look up prices itself. Instead it asks for tool calls, your code runs them and sends back the results, and the model keeps going until it can answer. A question such as "Which performed better since 2024-01-02: Apple or Nvidia?" needs several calls over more than one turn.
Loading the problem…