A Claude Code-level coding model built by fine-tuning
Qwen2.5-Coder-7B-Instruct using state-of-the-art training recipes from published research.
This model's recipe is derived from deep literature analysis of the top code LLM papers:
1from transformers import AutoModelForCausalLM, AutoTokenizer
2from peft import PeftModel
3
4# Load base + adapter
5base_model = AutoModelForCausalLM.from_pretrained(
6 "Qwen/Qwen2.5-Coder-7B-Instruct",
7 torch_dtype="auto",
8 device_map="auto",
9)
10model = PeftModel.from_pretrained(base_model, "ashhhhhh26/qwen25-coder-32b-mythos")
11tokenizer = AutoTokenizer.from_pretrained("Qwen/Qwen2.5-Coder-7B-Instruct")
12
13# Generate
14messages = [
15 {"role": "system", "content": "You are an elite software engineer..."},
16 {"role": "user", "content": "Implement a red-black tree in Python with insert, delete, and search operations."}
17]
18text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
19inputs = tokenizer(text, return_tensors="pt").to(model.device)
20outputs = model.generate(**inputs, max_new_tokens=4096, temperature=0.1, do_sample=True)
21print(tokenizer.decode(outputs[0], skip_special_tokens=True))
1# Single GPU (T4/L4/A10G with 16-24GB VRAM)
2python train.py
3
4# Multi-GPU with DeepSpeed ZeRO-2
5accelerate launch --config_file deepspeed_zero2.yaml --num_processes 4 train.py
1# Via HF Jobs API
2huggingface-cli jobs run train.py \
3 --hardware t4-small \
4 --timeout 8h \
5 --dependencies torch transformers trl peft datasets bitsandbytes accelerate trackio flash-attn
1@article{qwen2.5-coder,
2 title={Qwen2.5-Coder Technical Report},
3 author={Hui, Binyuan and Yang, Jian and others},
4 journal={arXiv:2409.12186},
5 year={2024}
6}
7
8@article{kodcode,
9 title={KodCode: A Diverse, Challenging, and Verifiable Synthetic Dataset for Coding},
10 author={Zheng, Zhangchen and others},
11 journal={arXiv:2503.02951},
12 year={2025}
13}
14
15@article{rstar-coder,
16 title={rStar-Coder: Scaling Competitive Code Reasoning},
17 author={Li, Xinyu and others},
18 journal={arXiv:2505.21297},
19 year={2025}
20}