fn read_max_tokens(
obj: &Map<String, Value>,
issues: &mut Vec<FieldIssue>,
) -> Option<u32>Expand description
Read max_tokens, which is u32 internally and -1 on the wire.
-1 is llama.cpp’s own idiom for “no limit”, and omitting the key means
exactly that here — see
with_hardcoded_defaults,
which deliberately leaves max_tokens unset. So -1 is not an error to
be reported, it is a spelling of a value this type already has. Any other
negative is a client bug.