Skip to content
Discussion options

You must be logged in to vote

Answering the question directly: no, nothing else guarantees continuation, and the sequence you describe reproduces.

I built the case you reasoned out — a step that ends max-tokens, a steer carrying the turn forward, then an ordinary tool call — and got two model calls where there should be three. The tool result is committed to the session log and no step ever reads it. Your reading of lines 285–299 is exactly right.

Why

One variable is answering two different questions.

step() returns null to mean "another step is required so the model can read the tool result". That null is the only continuation signal the loop has. It also returns a reason, which is what the turn should report, and ma…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@ShikangL
Comment options

Answer selected by ShikangL
Comment options

You must be logged in to vote
1 reply
@ShikangL
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants