Every objective below maps to a question in the retrieval set and to the mastery gate. You don't advance on time spent — you advance when you can do these.
stop_reason instead of reading the model's prose for tool intent.As a senior, your instinct is to own control flow: if this, call that. In an agent, you hand the branching decision to the model and your code becomes the loop harness around it. That single inversion is the whole mindset shift — everything else follows from it.
# the harness you write — not the intelligence, the plumbing while True: resp = model.send(messages, tools) if resp.stop_reason == "tool_use": # model decided to act result = run_tool(resp.tool_calls) # YOU execute + validate messages.append(tool_result(result)) # feed it back continue # loop again if resp.stop_reason == "end_turn": # model is done break
Read it as a sentence: send → check stop_reason → if it wants a tool, run it and feed the result back → repeat → stop when it's done. The model never touches your systems directly; it requests, your harness executes. That gap is where all your leverage (and all the risk) lives.
if statements. You've written this control structure a hundred times; only the decider changed.
stop_reason + tool_use blocks. Parsing prose is guessing.account_id can still be the wrong account. You validate values in the tool.Items you missed resurface sooner; items you nailed return on a longer interval. That's the forgetting curve being managed for you — recall right before you'd forget.
| Objective / item | Result | Next review |
|---|
Illustrative transcript: a learner picks "lower the temperature" to stop a runaway loop (a very common senior conflation). A good tutor doesn't say "wrong" — it finds the misconception, ties it to what you already know, and hands the loop back.