Parser error with claude code w/ or w/o shared template

#5
by xantrk - opened

API Error: 400 Unable to generate parser for this template. Automatic parser generation failed:

While executing CallExpression at line 85, column 32 in source:
...first %}↵ {{- raise_exception('System message must be at the beginnin...
^
Error: Jinja Exception: System message must be at the beginning.

Claude code is unable to respond to any message from this model. Normal chat is okay. don't have the same problem with qwen with or without updated template. Tried both original qwen's template and the one on this repo to no avail.

image

This comment has been hidden (marked as Low Quality)
Kwaipilot org

You can change Line 85 in chat_template.jinja

from

{{- raise_exception('System message must be at the beginning.') }}

into

{{- '<|im_start|>system\n' + content + '<|im_end|>' + '\n' }}

Sign up or log in to comment