How to use from
llama.cpp
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh
# Start a local OpenAI-compatible server with a web UI:
llama serve -hf jaweed123/Qwen3.5-0.8B-Python-SFT:
# Run inference directly in the terminal:
llama cli -hf jaweed123/Qwen3.5-0.8B-Python-SFT:
Install from WinGet (Windows)
winget install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama serve -hf jaweed123/Qwen3.5-0.8B-Python-SFT:
# Run inference directly in the terminal:
llama cli -hf jaweed123/Qwen3.5-0.8B-Python-SFT:
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git
cd llama.cpp
cmake -B build
cmake --build build -j --target llama-app
# Start a local OpenAI-compatible server with a web UI:
./build/bin/llama serve -hf jaweed123/Qwen3.5-0.8B-Python-SFT:
# Run inference directly in the terminal:
./build/bin/llama cli -hf jaweed123/Qwen3.5-0.8B-Python-SFT:
Use Docker
docker model run hf.co/jaweed123/Qwen3.5-0.8B-Python-SFT:
Quick Links

Qwen3.5-0.8B-Python-SFT

Python code generation model โ€” Qwen3.5-0.8B-Base fine-tuned with QLoRA (Supervised Fine-Tuning) on CodeSearchNet (Python): docstring โ†’ function code pairs.

Model Details

Property Value
Base model Qwen/Qwen3.5-0.8B-Base
Method QLoRA (4-bit base + LoRA r=16, alpha=32)
Trainable params 6.4M / 759M (0.84%)
Dataset CodeSearchNet Python โ€” 408K samples (13,590 repos)
Task Docstring โ†’ Python function code
Sequence length 2048
Precision BF16
Hardware NVIDIA RTX 4060 8GB

Training Results

Metric Value
Train loss 0.330
Eval loss 1.214
Steps 25,524 (1 epoch)
Runtime ~25.7h

Evaluation

pass@1 (temperature 0.2), official test harness, both models in bf16.

Benchmark Base Fine-tuned Improvement
HumanEval 1.2% 17.7% 14.5x
MBPP 0.0% 0.2% 0 โ†’ 1

Full report with example solutions: reports/evaluation_report.md in the training repo.

Training Details

  • Method: QLoRA โ€” 4-bit quantized base + LoRA (r=16, alpha=32, dropout=0)
  • Target modules: q_proj, k_proj, v_proj, o_proj, gate_proj, up_proj, down_proj
  • Optimizer: adamw_8bit (bitsandbytes), cosine schedule, 3% warmup
  • Batch: 2 per device ร— 8 grad accumulation (effective 16)
  • Max sequence length: 2048
  • Hardware: NVIDIA RTX 4060 8GB, ~25.7h
  • Data: CodeSearchNet Python filtered to โ‰ค2048 tokens (408,377 train samples)

Usage

Transformers (LoRA adapter)

from unsloth import FastLanguageModel

model, tokenizer = FastLanguageModel.from_pretrained(
    "Qwen/Qwen3.5-0.8B-Base",
    max_seq_length=2048,
    load_in_4bit=True,
)
model, tokenizer = FastLanguageModel.from_pretrained(
    "jaweed123/Qwen3.5-0.8B-Python-SFT",
    max_seq_length=2048,
    load_in_4bit=True,
)

GGUF (ollama / llama.cpp / vLLM)

# llama.cpp
llama-cli -m qwen3.5-0.8b-python-sft-q4_k_m.gguf -p "Write a Python function that..."

# Ollama
ollama create qwen3.5-python -f Modelfile
# Modelfile
FROM qwen3.5-0.8b-python-sft-q4_k_m.gguf
TEMPLATE "{{ if .System }}<|im_start|>system
{{ .System }}<|im_end|>
{{ end }}<|im_start|>user
{{ .Prompt }}<|im_end|>
<|im_start|>assistant
"

Files

File Description
adapter_model.safetensors LoRA adapter (small, ~13MB)
model.safetensors Merged 16-bit model
qwen3.5-0.8b-python-sft-q4_k_m.gguf GGUF Q4_K_M (~0.5GB)
qwen3.5-0.8b-python-sft-q8_0.gguf GGUF Q8_0 (~0.9GB)
qwen3.5-0.8b-python-sft-f16.gguf GGUF F16

Limitations

  • Fine-tuned for Python function generation from docstrings
  • Trained on 2019-era open-source code
  • 0.8B scale โ€” limited reasoning; best for straightforward code tasks
Downloads last month
184
Safetensors
Model size
0.8B params
Tensor type
F32
ยท
BF16
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for jaweed123/Qwen3.5-0.8B-Python-SFT

Quantized
(57)
this model

Dataset used to train jaweed123/Qwen3.5-0.8B-Python-SFT