vllm.parser.ergo
¶
Ergo parser for reasoning and tool calls.
An Ergo assistant turn, after the <ctrl0><ctrl1> opening of the prompt::
...reasoning...<ctrl2>content<ctrl3>{"name":"f","arguments":{...}}<ctrl4>
Stray CONTROL tokens are dropped, and a <ctrl1> in content reopens reasoning.
Classes:
ErgoParser
¶
Bases: ParserEngine
Methods:
-
adjust_initial_state_from_prompt–Start in content when the prompt tail closes reasoning (thinking
adjust_initial_state_from_prompt(prompt_token_ids)
¶
Start in content when the prompt tail closes reasoning (thinking off or a continued final message), as the Rust parser does.