Qwen3.5-4B · Pareto Curriculum SFT

This is the best checkpoint from a three-stage Pareto curriculum SFT run on Qwen3.5-4B. It was trained with ordinary unweighted token cross-entropy and without Error Tool-Call Mask.

Training summary

  • Base model: Qwen/Qwen3.5-4B
  • Selected checkpoint: Stage 3, global step 105
  • Training data: Qwen3.5-122B distilled trajectories with reward >= 0.3
  • Curriculum: reward 0.3-0.5 -> case-wise Pareto 0.3-0.7 -> highest band per case 0.3-1.0
  • Loss: unweighted assistant-token cross-entropy
  • Error Tool-Call Mask: disabled

Custom chat template

The repository includes chat_template.jinja, a custom Qwen3.5 template used for both SFT rendering and inference. Unlike the stock history behavior, it always replays non-empty assistant reasoning_content inside <think> blocks. It also renders parallel tool calls with the XML-style Qwen tool-call format and groups tool responses into the following user turn.

AutoProcessor.from_pretrained() loads the bundled template. When serving with SGLang, pass it explicitly to ensure training/inference parity:

python -m sglang.launch_server \
  --model-path /path/to/model \
  --chat-template /path/to/model/chat_template.jinja \
  --reasoning-parser qwen3 \
  --tool-call-parser qwen3_coder

Thinking is enabled by default. To render a generation prompt without an open reasoning block, pass enable_thinking=False in the chat-template kwargs.

Transformers loading

import torch
from transformers import AutoProcessor, Qwen3_5ForConditionalGeneration

model_id = "/path/to/model"
processor = AutoProcessor.from_pretrained(model_id)
model = Qwen3_5ForConditionalGeneration.from_pretrained(
    model_id,
    torch_dtype=torch.bfloat16,
    device_map="auto",
)

text = processor.apply_chat_template(
    [{"role": "user", "content": "Describe the video."}],
    tokenize=False,
    add_generation_prompt=True,
    enable_thinking=True,
)

The checkpoint is stored as Hugging Face safetensors. Optimizer, scheduler, trainer, and RNG states are intentionally excluded.

Downloads last month
62
Safetensors
Model size
5B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for JianhuiWei/qwen35_4b_sft_VE

Finetuned
Qwen/Qwen3.5-4B
Finetuned
(908)
this model
Finetunes
1 model