How to use from
SGLang
Install from pip and serve model
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
    --model-path "deburky/gpt-oss-claude-code" \
    --host 0.0.0.0 \
    --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "deburky/gpt-oss-claude-code",
		"messages": [
			{
				"role": "user",
				"content": "What is the capital of France?"
			}
		]
	}'
Use Docker images
docker run --gpus all \
    --shm-size 32g \
    -p 30000:30000 \
    -v ~/.cache/huggingface:/root/.cache/huggingface \
    --env "HF_TOKEN=<secret>" \
    --ipc=host \
    lmsysorg/sglang:latest \
    python3 -m sglang.launch_server \
        --model-path "deburky/gpt-oss-claude-code" \
        --host 0.0.0.0 \
        --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "deburky/gpt-oss-claude-code",
		"messages": [
			{
				"role": "user",
				"content": "What is the capital of France?"
			}
		]
	}'
Quick Links

gpt-oss-claude-code

Fine-tuned openai/gpt-oss-20b for tool-use and agentic coding tasks. LoRA adapters merged into base weights.

Quick start

import re, torch
from transformers import AutoModelForCausalLM, AutoTokenizer

model = AutoModelForCausalLM.from_pretrained(
    "deburky/gpt-oss-claude-code",
    torch_dtype=torch.bfloat16,
    device_map="auto",
)
tokenizer = AutoTokenizer.from_pretrained("deburky/gpt-oss-claude-code")

messages = [{"role": "user", "content": "Who is Alan Turing?"}]
inputs = tokenizer.apply_chat_template(
    messages, add_generation_prompt=True,
    return_tensors="pt", return_dict=True,
).to(model.device)

with torch.no_grad():
    out = model.generate(**inputs, max_new_tokens=256)
response = tokenizer.decode(out[0][inputs["input_ids"].shape[-1]:])

if "<|channel|>final<|message|>" in response:
    response = response.split("<|channel|>final<|message|>")[-1]
print(re.sub(r"<\\|[^>]+\\|>", "", response).strip())

Apple Silicon (MLX)

A fused MLX version is available at deburky/gpt-oss-claude-mlx.

Training

  • Data: ~280 tool-use conversation examples in gpt-oss harmony format
  • Method: LoRA (rank 8, alpha 16) on attention + MoE expert layers, merged after training
  • LR: 1e-4, cosine schedule
  • Final val loss: ~0.48
  • Hardware: Google Colab
Downloads last month
14
Safetensors
Model size
21B params
Tensor type
F32
·
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for deburky/gpt-oss-claude-code

Adapter
(454)
this model