lmsys-analyzer-9b

Qwen3.5-9B trained with reinforcement learning to act as a performance analyst for LLM-serving engines (vLLM / SGLang): given an engine checkout and a workload, it investigates with tools and writes an analysis that a separate implementer model turns into a patch. The reward was the measured, paired speedup of that patch (log speedup, clipped at 2.0; no delivery = 0).

Usage

import torch
from transformers import AutoModelForImageTextToText, AutoTokenizer

repo = "chengjunyan1/lmsys-analyzer-9b"
tokenizer = AutoTokenizer.from_pretrained(repo)
model = AutoModelForImageTextToText.from_pretrained(repo, dtype=torch.bfloat16, device_map="auto")  # device_map needs `accelerate`

messages = [{"role": "user", "content": "Why can prefix caching cut time-to-first-token?"}]
inputs = tokenizer.apply_chat_template(messages, add_generation_prompt=True, tokenize=True,
                                       return_dict=True, return_tensors="pt").to(model.device)
out = model.generate(**inputs, max_new_tokens=512)
print(tokenizer.decode(out[0][inputs["input_ids"].shape[1]:], skip_special_tokens=True))

For image or video inputs use AutoProcessor.from_pretrained(repo) instead of the tokenizer (as for the base Qwen3.5 model, its video processor needs torchvision). The model was trained on text-only agent sessions.

vLLM:

vllm serve chengjunyan1/lmsys-analyzer-9b --dtype bfloat16

Training

  • Base: Qwen/Qwen3.5-9B, all parameters trained.
  • Asynchronous GRPO: 8 prompt groups x 24 rollouts per step (at least 8 valid groups), failure-clipped advantages, an over-length penalty, loss masks on tool-call header and closing-tag names, and a guard that trains down empty tool calls. Learning rate 5e-7 at these steps.
  • Rewards come from measuring the delivered patches on GPUs; confirmed reward hacks were audited hourly.

License

Apache-2.0, as the base model.

Downloads last month
15
Safetensors
Model size
10B params
Tensor type
F32
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for chengjunyan1/lmsys-analyzer-9b

Finetuned
Qwen/Qwen3.5-9B
Finetuned
(1,400)
this model