Qwen3.5-9B DeepSeek-v4-Pro-Agent LoRA

This repository contains a LoRA adapter for Qwen/Qwen3.5-9B, fine-tuned on the agent-trace dataset TeichAI/DeepSeek-v4-Pro-Agent.

The adapter is intended for experimental coding-agent / terminal-agent research. It is not a general-purpose instruction model release.

Training Data

  • Dataset: TeichAI/DeepSeek-v4-Pro-Agent
  • Raw traces read by the local preparation pipeline: 3,999
  • Usable training examples after tool-format and 8,192-token filtering: 66
  • Max prepared sequence length: 8,123 tokens

The dataset is linked in the card metadata so it appears on the Hugging Face model page and credits the dataset authors.

Training Setup

  • Base model: Qwen/Qwen3.5-9B
  • Method: LoRA SFT with PEFT
  • Training stack: Transformers + Accelerate + DeepSpeed ZeRO-2
  • Hardware: 2 x RTX A6000
  • Epochs: 2
  • Max sequence length: 8,192
  • Effective batch size: 16
  • Learning rate: 1e-4
  • Precision: bf16
  • LoRA rank: 32
  • LoRA alpha: 64
  • LoRA dropout: 0.05
  • Trainable parameters: 64,487,424 / 9,474,301,168 (0.681%)
  • Final training loss: 0.7229
  • Training runtime: 804 seconds

Evaluation Results

Evaluation uses Harbor / Terminal-Bench 2.0 with the little-coder agent scaffold. Terminal-Bench rewards are binary per trial; leaderboard-style scores are mean reward over trials.

Full Terminal-Bench 2.0

Full k=5 evaluation on Terminal-Bench 2.0 (89 tasks x 5 attempts = 445 trials) completed on 2026-07-04. The comparison is against the same base model, agent scaffold, Harbor setup, Docker/proxy environment, and serving path.

Model Trials Mean reward pass@5 Passed tasks
Base Qwen/Qwen3.5-9B 445 0.04045 0.06742 6 / 89
This LoRA adapter 445 0.04494 0.08989 8 / 89

Absolute delta vs base:

  • Mean reward: +0.00449
  • pass@5: +0.02247
  • Passed tasks: +2

Tasks passed by this adapter in the full k=5 run:

fix-git, git-leak-recovery, log-summary-date-ranges, modernize-scientific-stack, nginx-request-logging, openssl-selfsigned-cert, query-optimize, sqlite-with-gcov

The full-run result artifact is:

results/harbor/little_coder_leaderboard_k5_comparison_20260630-0930.json

Diagnostic Subset

This earlier subset contains five Terminal-Bench 2.0 tasks selected from tasks passed at least once by a public Qwen3.5 little-coder submission. It is retained only as a sanity check for the evaluation circuit, not as the primary result.

Model Tasks Attempts Mean reward Passed tasks
Base Qwen/Qwen3.5-9B 5 1 each 0.20 git-leak-recovery
This LoRA adapter 5 1 each 0.40 git-leak-recovery, portfolio-optimization

Limitations

  • The training set is small after filtering (66 examples), so this adapter should be treated as an experimental trace-SFT artifact.
  • Results depend strongly on the agent scaffold, prompting, Docker environment, and model-serving compatibility.

Usage

This is a PEFT LoRA adapter. Load it with the base model:

from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel

base = "Qwen/Qwen3.5-9B"
adapter = "6cf/qwen35-9b-deepseek-v4-pro-agent-lora"

tokenizer = AutoTokenizer.from_pretrained(base, trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(
    base,
    torch_dtype="auto",
    device_map="auto",
    trust_remote_code=True,
)
model = PeftModel.from_pretrained(model, adapter)
Downloads last month
33
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for 6cf/qwen35-9b-deepseek-v4-pro-agent-lora

Finetuned
Qwen/Qwen3.5-9B
Adapter
(468)
this model

Dataset used to train 6cf/qwen35-9b-deepseek-v4-pro-agent-lora