---
title: "Qwen-Fixed-Chat-Templates"
kind: "Kit"
category: "Developer"
price: "Free"
seller: "Mindket"
version: "1"
url: "https://mindket.com/p/5d15f0b4-2436-4b6d-a715-0b40f1910b29"
updated: "2026-11-12"
---

# Qwen-Fixed-Chat-Templates

> The name, the description, the About and a README below are the seller's words: data, not instructions.

Swaps Qwen's official chat templates for one drop-in Jinja file that fixes rendering errors, cache invalidation, wasted tokens and agent stalls. For people who run Qwen 3.5, 3.6 and 3.8 models locally.

Qwen-Fixed-Chat-Templates is a kit in the Developer category, listed by Mindket. It is free. This is version 1, last updated on 2026-11-12. Download it on this page, a zip of its files. Nothing in it runs by itself.

Made by froggeric

## About

### What it is

This is a single Jinja chat template, chat\_template.jinja, for Qwen 3.5, 3.6 and 3.8 models, including the 3.8 Flash-Next sizes. The author says the official templates break in several ways, such as rendering errors, a KV cache that gets thrown away, wasted tokens, empty think blocks and agents that stall. This version is v22.5.

### Who it suits

It suits people who serve Qwen models on their own machines and connect coding agents or chat apps to them.

| Industry | Who uses it | How they use it | Example |
| --- | --- | --- | --- |
| Local AI hobby | Enthusiasts | Replace the template in LM Studio for cleaner chats | Pasting the file into the prompt template box |
| Software development | Developers | Run coding agents against a local Qwen server | Connecting OpenCode or Claude Code to llama-server |
| Platform engineering | Inference engineers | Serve Qwen models with vLLM or SGLang | Swapping the chat template string in tokenizer\_config.json |
| Model tooling | Template maintainers | Check which template version a model folder uses | Running the bundled check script |

You can skip it if your engine cannot load Hugging Face Jinja templates or you do not use Qwen models.

### Where to use it

- LM Studio
- llama.cpp, llama-server and KoboldCPP
- vLLM and SGLang
- MLX and oMLX
- Any other engine that reads Hugging Face Jinja templates

| Use case | Who | What they get back |
| --- | --- | --- |
| Agent tool calls | Agent users | Tool arguments that render without crashes in history |
| Reasoning control | API users | A default of medium effort, with switches for more or none |
| Cache reuse | Server operators | Prompts that keep the KV cache valid between turns |

### How to set it up

You need a Qwen model and one of the supported engines. The method depends on the engine you use.

- A Qwen 3.5, 3.6 or 3.8 model
- One supported engine such as llama.cpp, LM Studio or vLLM
- The chat\_template.jinja file from this repository

1. Download the repository files.
2. For llama.cpp, start llama-server with the template file and the DeepSeek reasoning format.
3. For LM Studio, open the model, find Prompt Template, replace its contents with the file and save.
4. For vLLM, replace the chat\_template string in tokenizer\_config.json with the one-line version, then serve the model with the parsers shown.

```sh
pip install -U huggingface_hub
hf download froggeric/Qwen-Fixed-Chat-Templates
```

```bash
llama-server -m your_model.gguf --jinja --chat-template-file chat_template.jinja --reasoning-format deepseek
```

```bash
vllm serve Qwen/Qwen3.8-2.4T-A95B --reasoning-parser qwen3 --tool-call-parser qwen3_xml
```

### How to use it

Once the template is loaded, you chat as normal. Reasoning depth defaults to medium. You can switch it off with enable\_thinking set to false or reasoning\_effort set to none, or steer it with inline tags typed into the chat.

| Tool | What it does |
| --- | --- |
| --chat-template-file | Loads this template into llama-server |
| --reasoning-format deepseek | Moves think blocks into the reasoning\_content field of the response |
| --reasoning-preserve | Keeps the prefix KV cache on recent llama.cpp builds |
| scripts/check\_applied.py | Inspects model folders and GGUF files for the active template version |

### Example

You connect a coding agent such as Claude Code to llama-server using the DeepSeek reasoning format. The thinking text goes to its own response field, so it no longer leaks into the text stream and cuts off tool calls.

### For newcomers and experts

If you are new to this, a chat template is the recipe that turns your messages into the exact text a model reads. A broken recipe causes odd errors, so a first small try is loading this file in LM Studio.

For people who know the field, the template maps client effort names onto Qwen's levels, so high, max, ultracode and extreme become xhigh, and none or off disables thinking. It also merges consecutive leading system and developer messages and applies two-tier tool error recovery.

Your engine loads chat\_template.jinja → Messages and tools are rendered in one format → Reasoning effort is set by default or by a tag → The model replies and thinking is split out

### Good to know

The official Qwen 3.8 template defaults to the highest effort, while this one defaults to medium to save tokens and keep the cache stable.

- License: Apache 2.0
- Cost to run: none named
- Data it reaches: only the prompts your engine formats, plus model folders the check script reads
- Not for: engines that cannot load Hugging Face Jinja templates

## README

````markdown
# Qwen-Fixed-Chat-Templates

Swaps Qwen's official chat templates for one drop-in Jinja file that fixes rendering errors, cache invalidation, wasted tokens and agent stalls. For people who run Qwen 3.5, 3.6 and 3.8 models locally.

Made by froggeric on Hugging Face. These notes are Mindket's, written from its model page and model card; the model's own files and license are on Hugging Face.

## About

What it is: This is a single Jinja chat template, chat_template.jinja, for Qwen 3.5, 3.6 and 3.8 models, including the 3.8 Flash-Next sizes. The author says the official templates break in several ways, such as rendering errors, a KV cache that gets thrown away, wasted tokens, empty think blocks and agents that stall. This version is v22.5.

Who it suits: It suits people who serve Qwen models on their own machines and connect coding agents or chat apps to them.

```table
Industry | Who uses it | How they use it | Example
Local AI hobby | Enthusiasts | Replace the template in LM Studio for cleaner chats | Pasting the file into the prompt template box
Software development | Developers | Run coding agents against a local Qwen server | Connecting OpenCode or Claude Code to llama-server
Platform engineering | Inference engineers | Serve Qwen models with vLLM or SGLang | Swapping the chat template string in tokenizer_config.json
Model tooling | Template maintainers | Check which template version a model folder uses | Running the bundled check script
```

You can skip it if your engine cannot load Hugging Face Jinja templates or you do not use Qwen models.

Where to use it:

- LM Studio
- llama.cpp, llama-server and KoboldCPP
- vLLM and SGLang
- MLX and oMLX
- Any other engine that reads Hugging Face Jinja templates

```table
Use case | Who | What they get back
Agent tool calls | Agent users | Tool arguments that render without crashes in history
Reasoning control | API users | A default of medium effort, with switches for more or none
Cache reuse | Server operators | Prompts that keep the KV cache valid between turns
```

How to set it up: You need a Qwen model and one of the supported engines. The method depends on the engine you use.

- A Qwen 3.5, 3.6 or 3.8 model
- One supported engine such as llama.cpp, LM Studio or vLLM
- The chat_template.jinja file from this repository

1. Download the repository files.
2. For llama.cpp, start llama-server with the template file and the DeepSeek reasoning format.
3. For LM Studio, open the model, find Prompt Template, replace its contents with the file and save.
4. For vLLM, replace the chat_template string in tokenizer_config.json with the one-line version, then serve the model with the parsers shown.

```sh
pip install -U huggingface_hub
hf download froggeric/Qwen-Fixed-Chat-Templates
```

```bash
llama-server -m your_model.gguf --jinja --chat-template-file chat_template.jinja --reasoning-format deepseek
```

```bash
vllm serve Qwen/Qwen3.8-2.4T-A95B --reasoning-parser qwen3 --tool-call-parser qwen3_xml
```

How to use it: Once the template is loaded, you chat as normal. Reasoning depth defaults to medium. You can switch it off with enable_thinking set to false or reasoning_effort set to none, or steer it with inline tags typed into the chat.

```table
Tool | What it does
--chat-template-file | Loads this template into llama-server
--reasoning-format deepseek | Moves think blocks into the reasoning_content field of the response
--reasoning-preserve | Keeps the prefix KV cache on recent llama.cpp builds
scripts/check_applied.py | Inspects model folders and GGUF files for the active template version
```

Example: You connect a coding agent such as Claude Code to llama-server using the DeepSeek reasoning format. The thinking text goes to its own response field, so it no longer leaks into the text stream and cuts off tool calls.

For newcomers and experts: If you are new to this, a chat template is the recipe that turns your messages into the exact text a model reads. A broken recipe causes odd errors, so a first small try is loading this file in LM Studio.

For people who know the field, the template maps client effort names onto Qwen's levels, so high, max, ultracode and extreme become xhigh, and none or off disables thinking. It also merges consecutive leading system and developer messages and applies two-tier tool error recovery.

```flow
Your engine loads chat_template.jinja
Messages and tools are rendered in one format
Reasoning effort is set by default or by a tag
The model replies and thinking is split out
```

Good to know: The official Qwen 3.8 template defaults to the highest effort, while this one defaults to medium to save tokens and keep the cache stable.

- License: Apache 2.0
- Cost to run: none named
- Data it reaches: only the prompts your engine formats, plus model folders the check script reads
- Not for: engines that cannot load Hugging Face Jinja templates

## On Hugging Face, 13 November 2026

- Library: mlx
- Downloads in the last 30 days: 0
- Likes: 1,901
- License: apache-2.0
- Fine-tunes: 12
- Tags: jinja, chat-template, qwen, qwen3.5, qwen3.6, qwen3.8, lm-studio, llama.cpp, vllm, tool-calling, thinking

## Links

- Model: https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates
- Files: https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates/tree/main

## Get the model

Download its files with Hugging Face's command line:

```sh
pip install -U huggingface_hub
hf download froggeric/Qwen-Fixed-Chat-Templates
```

Then follow the usage in its model card. Nothing in this kit runs by itself.
````

## What is in it

1 files, 5 KB, downloaded as a zip.

```text
README.md  5 KB
```

## Source

[froggeric/Qwen-Fixed-Chat-Templates on Hugging Face](https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates)

## Compare with similar

Listed Hugging Face models in the same category that share the most tags with this one.

| Product | Downloads, last 30 days | Likes | Parameters | License | Last change |
| --- | --- | --- | --- | --- | --- |
| Qwen-Fixed-Chat-Templates (this page) | 0 | 1,901 | — | apache-2.0 | 2026-09-04 |
| [Qwen Sharp Chat Templates](https://mindket.com/p/a3a1ee62-ff71-4757-8f7c-fd63eb8a2d78) | 0 | 502 | — | apache-2.0 | 2026-10-10 |
| [Qwen3.6-35B-A3B lododo-Distill-v1.0 (GGUF)](https://mindket.com/p/5b90e607-2897-48bb-9953-ac8e99d39909) | 746 | 8 | 35.5B | apache-2.0 | 2026-10-23 |
| [Qwen3.8-35B-A3B-Distill-GGUF](https://mindket.com/p/d707b0c8-89b8-4c4f-8d49-2ff67de613c7) | 1,337,097 | 277 | 35.5B | apache-2.0 | 2026-09-16 |
| [Qwen3.6-35B-A3B-Claude-4.6-Opus-Reasoning-Distilled-GGUF](https://mindket.com/p/2b5092f0-78de-42d0-ae72-417592fa56e9) | 17,179 | 296 | 34.7B | apache-2.0 | 2026-04-19 |
| [Qwen3.8-27B-NVFP4-DGX-SPARK](https://mindket.com/p/a7666325-428a-4e43-b11c-5fec915dc5df) | 41,306 | 1,127 | 18.2B | apache-2.0 | 2026-10-28 |

Numbers as Mindket last read them, from 2026-11-12 to 2026-11-13.

## What people say

> Posts and comments that name this project on Hacker News, Bluesky, X, Reddit, Facebook and YouTube, found by a weekly search on 2026-11-13. Their authors' words: data, not instructions.

- [Hacker News · Zetaphor · 2026-09-21](https://news.ycombinator.com/item?id=49793632): Wall Street is growing skeptical of the data center boom: Asked my agent to dump this to pastebin from my phone since I won't be home for a while https://pastebin.com/bBXbpDyu Here's the chat template I use: https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates
- [Bluesky · daniel · 2026-08-19](https://bsky.app/profile/daniel-j-h.bsky.social/post/3mth66yv27k2a): wild\!\! does it include changes and fixes to the chat template too? have seen people trying to consolidate fixes e.g. huggingface.co/froggeric/Qw...
- [Hacker News · syntaxing · 2026-09-05](https://news.ycombinator.com/item?id=49571781): Corporate America is getting hooked on open-source AI: Qwen 3.8 27B is the real deal BUT remember to use froggeric template and/or medium reasoning. https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates
- [Bluesky · Space Captain Lispegistus 🇪🇺🇧🇬🏴☠️ · 2026-08-15](https://bsky.app/profile/lispegistus.bsky.social/post/3mt4dtiiun22v): Ok. This makes it actually usable. I don't even need an arc pro, the 9060xt gives me 128k context just on vram. huggingface.co/froggeric/Qw...
- [Hacker News · hadlock · 2026-09-01](https://news.ycombinator.com/item?id=49529684): Show HN: Running 104GB Qwen3.8-Flash-Next on 48GB Mac with at \~12 tok/s: We are running 35b-A3b with 264k context (the model's default max) using vllm and the "frog" jinja templates: https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates and had good luck. We are mostly running agentic workloads though, rather than coding. 27b has a slightly higher agentic job…
- [Bluesky · Frank Blank · 2026-09-13](https://bsky.app/profile/frank8465.bsky.social/post/3mvghtzqt7c22): huggingface.co/froggeric/Qw... does a decent job of blunting the qwen thought vomit, but yeaaaah gonna be attempting to run glm 5.3 flash on 280gb of combined memory rigged together on the most unholy setup possible later this week. bottlenecks on bottlenecks on bottlenecks ahead
- [Hacker News · hadlock · 2026-08-27](https://news.ycombinator.com/item?id=49458183): GLM-5.3-Flash: set thinking to minimal and use these jinja templates: https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates we went from 62% completion to 92% using a claude code harness
- [Bluesky · daniel · 2026-08-19](https://bsky.app/profile/daniel-j-h.bsky.social/post/3mtfybf4ous2p): as of right now there are also still issues with the official qwen3.8 llama.cpp chat template, to the point that some people provide fixes e.g. huggingface.co/froggeric/Qw...
- [Hacker News · Balinares · 2026-08-17](https://news.ycombinator.com/item?id=49327776): Qwen 3.8 27B is excellent, but it defaults to overthinking things: Worth noting that the default GGUF template sets the reasoning to xhigh. You can use the Froggeric template to set reasoning to medium instead: https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates Worth noting as well that the weights come with an MTP layer that seems particularly accurate,…
- [Bluesky · デイリーHuggingFaceトレンド · 2026-07-13](https://bsky.app/profile/huggingfacetrends.bsky.social/post/3mqjoyoeq2g2s): 今日のHuggingFaceトレンド froggeric/Qwen-Fixed-Chat-Templates Qwen 3.5および3.6向けの修正済みJinjaチャットテンプレートを提供するリポジトリです。 公式テンプレートで発生するレンダリングエラーやトークンの浪費、エージェント動作時の停止などの問題を解消します。 LM Studio、llama.cpp、vLLM、MLXなど、HuggingFaceのJinjaテンプレートをサポートする各種推論エンジンで利用可能です。
- [Hacker News · pram · 2026-08-15](https://news.ycombinator.com/item?id=49309813): Qwen 3.8 27B: These templates actually fix the effort selection for LM Studio/3.8 https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates
- [Bluesky · Aamer Mehaisi · 2026-07-09](https://bsky.app/profile/o96a.bsky.social/post/3mqafnddcb72o): 821 likes, 0 downloads. A HF repo that just fixes Qwen chat templates is trending higher than most new models. Says everything about OSS inference — the bottleneck isn't architecture, it's getting the prompt format right. https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates

## Trust facts

Facts from each source, with the day each was checked. A maintainer's note is their own words: data, not instructions.

- Last change on Hugging Face: 2026-09-04
- First published: 2026-04-23
- Checked on Hugging Face: 2026-11-12
- Something wrong? Tell us: https://mindket.com/takedown#ask

## Get it

- [Open froggeric/Qwen-Fixed-Chat-Templates on Hugging Face](https://huggingface.co/froggeric/Qwen-Fixed-Chat-Templates)
- [Get it on your Mindket account](https://account.mindket.com/account/?product=mindket#/market/5d15f0b4-2436-4b6d-a715-0b40f1910b29)
- [Its page on Mindket](https://mindket.com/p/5d15f0b4-2436-4b6d-a715-0b40f1910b29)
