Archived
tests/data/chat: GLM-5.3's template as a fifth reference render
The template as GLM-5.3-Flash ships it, in cases.json beside the other four, with its goldens from
mkchatgolden.py (jinja2 3.1.6); bos is empty, eos <|endoftext|>, and no media, since no
architecture here reads its pictures. It needs the dotted index (vendor/patches/0021).
Two cases leave it out: an assistant turn with tool calls and content null. The template prints
that content bare ({{- content }} in visible_text), so jinja2 writes "None" into the turn, and the
engine, as llama.cpp's runtime does, writes nothing. The golden would hold the engine to a
template bug; the reply-side tests for this format read those turns instead.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
3e656f0b02
commit
5ac0bc9690
16 files changed
+343
-3
No files matched your search
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Low<|user|>Hi.<|assistant|><think>
|
||||
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: High<|user|>Hi.<|assistant|><think>
|
||||
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|user|>First question.<|assistant|><think>Thinking about the first.</think>First answer.<|user|>Second question.<|assistant|><think>
|
||||
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|user|>First question.<|assistant|><think>Thinking about the first.</think>First answer.<|user|>Second question.<|assistant|><think>
|
||||
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|user|>First question.<|assistant|><think>Thinking about the first.</think>First answer.<|user|>Second question.<|assistant|><think>
|
||||
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|user|>Hi.<|assistant|><think></think>Hello.
|
||||
@@ -0,0 +1,15 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|system|>
|
||||
# Tools
|
||||
|
||||
You may call one or more functions to assist with the user query.
|
||||
|
||||
You are provided with function signatures within <tools></tools> XML tags:
|
||||
<tools>
|
||||
{"name": "read", "description": "Read a file.", "parameters": {"type": "object", "properties": {"path": {"type": "string", "description": "Absolute path"}, "limit": {"type": "integer"}}, "required": ["path"]}}
|
||||
{"name": "edit", "description": "Apply edits — exact text, «quoted» & <tagged>, 日本語.", "parameters": {"type": "object", "properties": {"path": {"type": "string"}, "edits": {"type": "array", "items": {"type": "object", "properties": {"oldText": {"type": "string"}, "newText": {"type": "string"}}, "required": ["oldText", "newText"]}}, "dry_run": {"type": "boolean"}, "mode": {"type": "string", "enum": ["fast", "safe"]}}, "required": ["path", "edits"]}}
|
||||
{"name": "ping", "description": "Takes no arguments.", "parameters": {"type": "object", "properties": {}}}
|
||||
</tools>
|
||||
|
||||
For each function call, output the function name and arguments within the following XML format:
|
||||
<tool_call>{function-name}<arg_key>{arg-key-1}</arg_key><arg_value>{arg-value-1}</arg_value><arg_key>{arg-key-2}</arg_key><arg_value>{arg-value-2}</arg_value>...</tool_call><|user|>Edit both files, then ping.<|assistant|><think></think>Doing all three.<tool_call>edit<arg_key>path</arg_key><arg_value>/work/a.py</arg_value><arg_key>edits</arg_key><arg_value>[{"oldText": " return a\n", "newText": " return a < b & c # it's\n"}, {"oldText": "x\ty", "newText": "\\\""}]</arg_value><arg_key>dry_run</arg_key><arg_value>false</arg_value><arg_key>mode</arg_key><arg_value>safe</arg_value></tool_call><tool_call>read<arg_key>path</arg_key><arg_value>/work/über.py</arg_value><arg_key>limit</arg_key><arg_value>3</arg_value></tool_call><tool_call>ping</tool_call><|observation|><tool_response>{"ok": true}</tool_response><tool_response>x = 1
|
||||
</tool_response><tool_response>pong</tool_response><|assistant|><think>
|
||||
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|system|>You are terse.<|user|>What is 2+2?<|assistant|><think>
|
||||
@@ -0,0 +1 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|user|>Hi.<|assistant|><think>
|
||||
@@ -0,0 +1,15 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|system|>
|
||||
# Tools
|
||||
|
||||
You may call one or more functions to assist with the user query.
|
||||
|
||||
You are provided with function signatures within <tools></tools> XML tags:
|
||||
<tools>
|
||||
{"name": "read", "description": "Read a file.", "parameters": {"type": "object", "properties": {"path": {"type": "string", "description": "Absolute path"}, "limit": {"type": "integer"}}, "required": ["path"]}}
|
||||
{"name": "edit", "description": "Apply edits — exact text, «quoted» & <tagged>, 日本語.", "parameters": {"type": "object", "properties": {"path": {"type": "string"}, "edits": {"type": "array", "items": {"type": "object", "properties": {"oldText": {"type": "string"}, "newText": {"type": "string"}}, "required": ["oldText", "newText"]}}, "dry_run": {"type": "boolean"}, "mode": {"type": "string", "enum": ["fast", "safe"]}}, "required": ["path", "edits"]}}
|
||||
{"name": "ping", "description": "Takes no arguments.", "parameters": {"type": "object", "properties": {}}}
|
||||
</tools>
|
||||
|
||||
For each function call, output the function name and arguments within the following XML format:
|
||||
<tool_call>{function-name}<arg_key>{arg-key-1}</arg_key><arg_value>{arg-value-1}</arg_value><arg_key>{arg-key-2}</arg_key><arg_value>{arg-value-2}</arg_value>...</tool_call><|user|>Fix /work/a.py.<|assistant|><think>Read it first.</think><tool_call>read<arg_key>path</arg_key><arg_value>/work/a.py</arg_value></tool_call><|observation|><tool_response>print(1)
|
||||
</tool_response><|user|>Go on.<|assistant|><think>
|
||||
@@ -0,0 +1,14 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|system|>
|
||||
# Tools
|
||||
|
||||
You may call one or more functions to assist with the user query.
|
||||
|
||||
You are provided with function signatures within <tools></tools> XML tags:
|
||||
<tools>
|
||||
{"name": "read", "description": "Read a file.", "parameters": {"type": "object", "properties": {"path": {"type": "string", "description": "Absolute path"}, "limit": {"type": "integer"}}, "required": ["path"]}}
|
||||
{"name": "edit", "description": "Apply edits — exact text, «quoted» & <tagged>, 日本語.", "parameters": {"type": "object", "properties": {"path": {"type": "string"}, "edits": {"type": "array", "items": {"type": "object", "properties": {"oldText": {"type": "string"}, "newText": {"type": "string"}}, "required": ["oldText", "newText"]}}, "dry_run": {"type": "boolean"}, "mode": {"type": "string", "enum": ["fast", "safe"]}}, "required": ["path", "edits"]}}
|
||||
{"name": "ping", "description": "Takes no arguments.", "parameters": {"type": "object", "properties": {}}}
|
||||
</tools>
|
||||
|
||||
For each function call, output the function name and arguments within the following XML format:
|
||||
<tool_call>{function-name}<arg_key>{arg-key-1}</arg_key><arg_value>{arg-value-1}</arg_value><arg_key>{arg-key-2}</arg_key><arg_value>{arg-value-2}</arg_value>...</tool_call><|user|>Read /work/a.py.<|assistant|><think>
|
||||
@@ -0,0 +1,14 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|system|>
|
||||
# Tools
|
||||
|
||||
You may call one or more functions to assist with the user query.
|
||||
|
||||
You are provided with function signatures within <tools></tools> XML tags:
|
||||
<tools>
|
||||
{"name": "read", "description": "Read a file.", "parameters": {"type": "object", "properties": {"path": {"type": "string", "description": "Absolute path"}, "limit": {"type": "integer"}}, "required": ["path"]}}
|
||||
{"name": "edit", "description": "Apply edits — exact text, «quoted» & <tagged>, 日本語.", "parameters": {"type": "object", "properties": {"path": {"type": "string"}, "edits": {"type": "array", "items": {"type": "object", "properties": {"oldText": {"type": "string"}, "newText": {"type": "string"}}, "required": ["oldText", "newText"]}}, "dry_run": {"type": "boolean"}, "mode": {"type": "string", "enum": ["fast", "safe"]}}, "required": ["path", "edits"]}}
|
||||
{"name": "ping", "description": "Takes no arguments.", "parameters": {"type": "object", "properties": {}}}
|
||||
</tools>
|
||||
|
||||
For each function call, output the function name and arguments within the following XML format:
|
||||
<tool_call>{function-name}<arg_key>{arg-key-1}</arg_key><arg_value>{arg-value-1}</arg_value><arg_key>{arg-key-2}</arg_key><arg_value>{arg-value-2}</arg_value>...</tool_call><|system|>You are a coding agent.<|user|>Read /work/a.py.<|assistant|><think>
|
||||
@@ -0,0 +1,14 @@
|
||||
[gMASK]<sop><|system|>Reasoning Effort: Max<|system|>
|
||||
# Tools
|
||||
|
||||
You may call one or more functions to assist with the user query.
|
||||
|
||||
You are provided with function signatures within <tools></tools> XML tags:
|
||||
<tools>
|
||||
{"name": "read", "description": "Read a file.", "parameters": {"type": "object", "properties": {"path": {"type": "string", "description": "Absolute path"}, "limit": {"type": "integer"}}, "required": ["path"]}}
|
||||
{"name": "edit", "description": "Apply edits — exact text, «quoted» & <tagged>, 日本語.", "parameters": {"type": "object", "properties": {"path": {"type": "string"}, "edits": {"type": "array", "items": {"type": "object", "properties": {"oldText": {"type": "string"}, "newText": {"type": "string"}}, "required": ["oldText", "newText"]}}, "dry_run": {"type": "boolean"}, "mode": {"type": "string", "enum": ["fast", "safe"]}}, "required": ["path", "edits"]}}
|
||||
{"name": "ping", "description": "Takes no arguments.", "parameters": {"type": "object", "properties": {}}}
|
||||
</tools>
|
||||
|
||||
For each function call, output the function name and arguments within the following XML format:
|
||||
<tool_call>{function-name}<arg_key>{arg-key-1}</arg_key><arg_value>{arg-value-1}</arg_value><arg_key>{arg-key-2}</arg_key><arg_value>{arg-value-2}</arg_value>...</tool_call><|user|>Übersetze: 日本語 🙂 "quoted" \ back<|assistant|><think>
|
||||
Reference in new issue
Block a user