Text Generation
Transformers
Safetensors
PEFT
lora
bigcodebench
gpt-oss
code
causal-lm
conversational
Run this model with HF Jobs
Run unlimitedbytes/gptoss-bigcodebench-20b-lora on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/unlimitedbytes/gptoss-bigcodebench-20b-lora. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/unlimitedbytes/gptoss-bigcodebench-20b-lora on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/unlimitedbytes/gptoss-bigcodebench-20b-lora. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/unlimitedbytes/gptoss-bigcodebench-20b-lora. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use unlimitedbytes/gptoss-bigcodebench-20b-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use unlimitedbytes/gptoss-bigcodebench-20b-lora with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="unlimitedbytes/gptoss-bigcodebench-20b-lora") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("unlimitedbytes/gptoss-bigcodebench-20b-lora", device_map="auto") - PEFT
How to use unlimitedbytes/gptoss-bigcodebench-20b-lora with PEFT:
Task type is invalid.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use unlimitedbytes/gptoss-bigcodebench-20b-lora with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "unlimitedbytes/gptoss-bigcodebench-20b-lora" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "unlimitedbytes/gptoss-bigcodebench-20b-lora", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/unlimitedbytes/gptoss-bigcodebench-20b-lora
- SGLang
How to use unlimitedbytes/gptoss-bigcodebench-20b-lora with 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 "unlimitedbytes/gptoss-bigcodebench-20b-lora" \ --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": "unlimitedbytes/gptoss-bigcodebench-20b-lora", "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 "unlimitedbytes/gptoss-bigcodebench-20b-lora" \ --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": "unlimitedbytes/gptoss-bigcodebench-20b-lora", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use unlimitedbytes/gptoss-bigcodebench-20b-lora with Docker Model Runner:
docker model run hf.co/unlimitedbytes/gptoss-bigcodebench-20b-lora
Upload README.md with huggingface_hub
Browse files1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162---base_model: openai/gpt-oss-20blibrary_name: peftmodel_name: gptoss-bigcodebench-fulltags:- base_model:adapter:openai/gpt-oss-20b- lora- sft- transformers- trllicence: licensepipeline_tag: text-generation---# Model Card for gptoss-bigcodebench-fullThis model is a fine-tuned version of [openai/gpt-oss-20b](https://huggingface.co/openai/gpt-oss-20b).It has been trained using [TRL](https://github.com/huggingface/trl).## Quick start```pythonfrom transformers import pipelinequestion = "If you had a time machine, but could only go to the past or the future once and never return, which would you choose and why?"generator = pipeline("text-generation", model="None", device="cuda")output = generator([{"role": "user", "content": question}], max_new_tokens=128, return_full_text=False)[0]print(output["generated_text"])```## Training procedureThis model was trained with SFT.### Framework versions- PEFT 0.17.0- TRL: 0.20.0- Transformers: 4.55.0- Pytorch: 2.8.0.dev20250319+cu128- Datasets: 4.0.0- Tokenizers: 0.21.4## CitationsCite TRL as:```bibtex@misc{vonwerra2022trl,title = {{TRL: Transformer Reinforcement Learning}},author = {Leandro von Werra and Younes Belkada and Lewis Tunstall and Edward Beeching and Tristan Thrush and Nathan Lambert and Shengyi Huang and Kashif Rasul and Quentin Gallou{\'e}dec},year = 2020,journal = {GitHub repository},publisher = {GitHub},howpublished = {\url{https://github.com/huggingface/trl}}}```12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061---license: apache-2.0base_model: openai/gpt-oss-20blibrary_name: transformerspipeline_tag: text-generationtags:- peft- lora- bigcodebench- gpt-oss- code- causal-lminference: false---# GPT-OSS-20B BigCodeBench LoRA AdapterLoRA adapter weights fine-tuned from `openai/gpt-oss-20b` on BigCodeBench split `v0.1.4` (~1.1K samples).## Training Summary- Steps: 100- Final train_loss: 0.7833267974853516- Runtime (s): 3717.3139- Samples/sec: 0.43- Total FLOPs: 6.825417425085542e+16## Usage```pythonfrom transformers import AutoModelForCausalLM, AutoTokenizerfrom peft import PeftModelbase = 'openai/gpt-oss-20b'adapter = 'unlimitedbytes/gptoss-bigcodebench-20b-lora'model = AutoModelForCausalLM.from_pretrained(base, device_map='auto', torch_dtype='auto')model = PeftModel.from_pretrained(model, adapter)tokenizer = AutoTokenizer.from_pretrained(base)messages = [{'role': 'system', 'content': 'You are a helpful coding assistant.'},{'role': 'user', 'content': 'Write a Python function to add two numbers.'}]input_ids = tokenizer.apply_chat_template(messages, add_generation_prompt=True, return_tensors='pt').to(model.device)out = model.generate(input_ids, max_new_tokens=128)print(tokenizer.decode(out[0], skip_special_tokens=False))```Merge adapter:```pythonmodel = model.merge_and_unload()model.save_pretrained('merged-model')```## Limitations- 100 training steps only; not fully converged.- Adapter only, no merged full weights.- Outputs may include control tokens.## LicenseApache-2.0 (base) + dataset licenses.
README.md+44-45