mirror of
https://github.com/hasso5703/alzeo.git
synced 2026-12-06 12:54:19 +01:00
CI: the template check hands each template what its engine hands it, and reads the installers closely
The check rendered a tool's answer as a list of parts, which neither engine hands a template (vLLM's
_parse_chat_message_content and SGLang's normalize_tool_content make it one string), and an empty
assistant content as a string where vLLM hands a template that takes OpenAI's content format a list.
Its port of vLLM's reading of a template followed messages put into a namespace, which no vLLM the
lanes pin does, so such a template read as taking lists where vLLM hands it strings (a false green
the second review showed on a toy template). It now renders what a client sends, strings and lists of
parts, as each engine hands it on, both engines' code read in their sources at the versions the lanes
pin: vLLM 8244d1c4 and 77154ca6, and v0.29.0 for Kolibri, whose reading follows no macro; SGLang
v0.5.22 and the flash lane's nightly 53295c6, whose code for it is the same. Where vLLM's own
assertions fail, its reading gives its default, strings, as vLLM's does. transformers' {% generation %}
tag renders, and the named templates of a repo's additional_chat_templates/ join its default, as
transformers reads them (none of the 13 targets has one), where a patched lane serves its patched
file alone, as --chat-template hands it to the engine for every request. And it stops on an installer
that names patch-template.py anywhere but in its preflight's list of files, however the call is
written, one whose calls of vlane_template leave its fixes out, and a fix it cannot pass on: each
read as serving the template as published. So does a call of patch-template.py with fixes of its own
in install.sh or switch-model.sh, whose 27B and flash targets it renders with the four. The canary
goes through each engine's conversion too, which a fault of the check no longer reads as a refusal,
and a tool call sent as parts carries null content, as the OpenAI API returns it (the second review).
It renders no request's own parameters yet (a reasoning effort, thinking on or off), nor a vision
lane's processor template, which is the tokenizer's own on the Nemotron lanes today.
On the reference box: 13 targets, 364 renders, 0 refusals, each identical to transformers 5.12.1's
own, and the Ornith checkpoint's published template refuses 16 of its 28. The port gives the reading
vLLM's own code gives, run from its sources at each pinned version, on the 13 templates and on 8
written to tell them apart. tests/test_lane_templates_check.py fails on the old check (25 of 35).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
54a094e84f
commit
d7a6737751
3 files changed
+387
-111
No files matched your search
@@ -1610,16 +1610,17 @@ jobs:
|
||||
echo " $listed " | grep -q " $name " || { echo "$f is in the repo and install-image.sh never applies it"; exit 1; }
|
||||
done
|
||||
|
||||
- name: Every text lane's chat template takes what the real clients send
|
||||
- name: Every text lane's chat template takes the message shapes the real clients send
|
||||
# opencode 1.19.4 sends two system messages before the user's, and the Ornith lane's
|
||||
# published template refused the second: a 400 on every opencode request from v1.38.6 to
|
||||
# v1.40.1, as each release proved the clients on the lane that served (found 2026-10-24).
|
||||
# This fetches each text target's template at its pin (each of switch-model.sh's targets
|
||||
# but the image and video lanes), patches it as its installer does, and renders the shapes
|
||||
# the real clients send (tests/fixtures/client-shapes.json), with tools and without, each
|
||||
# content in the form its engine hands it (vLLM's and SGLang's own reading of the template),
|
||||
# the way transformers does (280 renders identical to its own on the reference box). A
|
||||
# template that raises fails here, and so does a text target the check does not know.
|
||||
# the real clients send (tests/fixtures/client-shapes.json), with tools and without, sent as
|
||||
# strings and as lists of parts and handed on as each engine hands them (vLLM's and SGLang's
|
||||
# own reading of the template and conversion of the messages), the way transformers does
|
||||
# (364 renders identical to its own on the reference box). A template that raises fails
|
||||
# here, and so do a text target the check does not know and an installer it cannot read.
|
||||
run: |
|
||||
pip install 'jinja2==3.1.6'
|
||||
"$(./tests/testpy.sh jinja2)" tests/lane-templates-check.py
|
||||
|
||||
Reference in new issue
Block a user