A 311 triage agent must always call the classify_request tool first, before any other tool, on every incoming resident message. Which mechanism most reliably enforces that on a given turn?
Select an answer to reveal the explanation.
Short Explanation
tool_choice is the script that says press this button first, no exceptions. A prompt sentence is a suggestion the model can drift from; forcing the tool makes the first call deterministic.
Full Explanation
Ordering guarantees in an agent come from API-level constraints, not from persuasion. A 311 triage flow where classification must precede every other action needs a mechanism that holds under ambiguous resident phrasing, unusual message lengths, and long conversations—exactly the conditions where a merely stated preference is most likely to slip.
Tool_choice constrains which tool the model may call on a given turn. Forcing classify_request makes that invocation a property of the request itself rather than of the model's judgment, so triage happens before anything else regardless of how the incoming message reads. The remaining tools stay declared and available for the turns that follow.
A system-prompt instruction to call the tool first is a strong hint but not a hard constraint, and the model can still deviate under prompt pressure or ambiguity. Permanently removing every other tool would guarantee ordering by removing the work itself—the agent could classify and then do nothing. Increasing max_tokens governs how much output the model may produce, which has no bearing on which tool it selects or when.
Exam caveat: forcing a tool applies to that turn only, so a multi-turn triage loop must re-apply the constraint or relax it deliberately once classification is done. Operational check: send several deliberately vague resident messages with tool_choice forced and confirm the first tool_use block is classify_request in every trace.