Text Generation
Transformers
Safetensors
gpt_oss
vllm
conversational
Eval Results
8-bit precision
mxfp4
Instructions to use openai/gpt-oss-120b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use openai/gpt-oss-120b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="openai/gpt-oss-120b") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("openai/gpt-oss-120b") model = AutoModelForCausalLM.from_pretrained("openai/gpt-oss-120b", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Inference
- HuggingChat
- Notebooks
- Google Colab
- Kaggle
- AMD Developer Cloud
- Local Apps Settings
- vLLM
How to use openai/gpt-oss-120b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "openai/gpt-oss-120b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "openai/gpt-oss-120b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/openai/gpt-oss-120b
- SGLang
How to use openai/gpt-oss-120b 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 "openai/gpt-oss-120b" \ --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": "openai/gpt-oss-120b", "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 "openai/gpt-oss-120b" \ --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": "openai/gpt-oss-120b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use openai/gpt-oss-120b with Docker Model Runner:
docker model run hf.co/openai/gpt-oss-120b
Update README.md
#119 opened 12 months ago
by
Lorriea73
new version miss file,can't startup the model gpt-oss
1
#118 opened 12 months ago
by
aidenpan0x
Fine tune 120b at 8 H100s getting cuda OOM error
👀 1
6
#117 opened 12 months ago
by
jinxu88
68.4 on Aider Polyglot with reasoning_effort: high
🔥 2
#116 opened 12 months ago
by
Fernanda24
fix missing the `{% generation %}` keyword while using tokenizer.apply_chat_template(...return_assistant_tokens_mask=True)
#112 opened 12 months ago
by
lllIIIlIlIk
Two clarifications on gpt-oss-120B hardware (fine-tuning vs inference, MoE VRAM)
#110 opened 12 months ago
by
GazJ16
gpt-oss is actually good. even on less common benchmark
🤝👍 7
2
#109 opened 12 months ago
by
groupfairnessllm
Please restart openai/gpt-oss-120b endpoint + confirm logprobs support
2
#107 opened 12 months ago
by
Melfarser
Model output with FP16
#106 opened 12 months ago
by
AnujQCom
BEST open source 120b level model.. ever
❤️ 2
2
#104 opened 12 months ago
by
DOFOFFICIAL
Multimodal support missing
#101 opened 12 months ago
by
dashesy
LiveCodeBench evaluation
❤️👀 2
1
#100 opened 12 months ago
by
wasiuddina
How to reproduce the results on hle(Humanity's Last Exam)?
#95 opened 12 months ago
by
wenhanli
ImportError: /lib64/libc.so.6: version `GLIBC_2.32' not found
5
#86 opened 12 months ago
by
yueqiren
Why is the performance worse on the 20B than on the 120B
➕ 3
2
#84 opened 12 months ago
by
megabob
How to turn off thinking mode
2
#82 opened 12 months ago
by
Gierry
gpt-oss120b does not actually support 131072 output tokens due to openai policies embedded limiting ouput
❤️ 1
9
#81 opened 12 months ago
by
Theodophilus
Run GPT-OSS-120B with just Single A100 (80GB)
2
#80 opened 12 months ago
by
ghostplant
Please move metal/ and original/ to their own repos
➕ 2
2
#78 opened 12 months ago
by
ehartford
gp-oss-120b — Exceptional Reasoning, Not Yet AGI Scale
❤️ 3
#77 opened 12 months ago
by
BertrandCabotPro
Qwen3 beat gpt-oss with just 0.6B with good quality enough to be usable
4
#75 opened 12 months ago
by
yousef1727
Hallucinates System-promp
2
#74 opened 12 months ago
by
Gradois
Can gpt-oss support local vllm deployment on a100 GPU?
10
#73 opened 12 months ago
by
Cola-any
gpt_oss error when running on kaggle
2
#72 opened 12 months ago
by
thehai
is this guid prompt is still valid ?
#71 opened 12 months ago
by
gopi87
[Discussion] gpt-oss-120b hangs indefinitely ("thinking...") when using YaRN rope scaling to extend context length
5
#70 opened 12 months ago
by
RekklesAI
Errors in chat template compared to spec
14
#69 opened 12 months ago
by
zhuexe
Possible PEP 660 violation in `_build/gpt_oss_build_backend/backend.py`
#66 opened 12 months ago
by
kwojciechowski
Estimated Thinking/Reasoning Token Usages For Each Modes
1
#65 opened 12 months ago
by
asif00
running mxfp4 on H100 using tranformers with triton_kernel: make_default_matmul_mxfp4_w_layout not found
5
#64 opened 12 months ago
by
uillliu
🚀 Best Practices for Evaluating GPT-OSS Models: Speed & Benchmark Testing Guide
🚀❤️ 11
1
#62 opened 12 months ago
by
Yunxz
How do I serve a model in the original folder as bf16 in VLLM?
4
#60 opened 12 months ago
by
bakch92
Model Performance
😔🤗 6
1
#59 opened 12 months ago
by
Joe1998
Disgusting, maximally censored model!
👍 36
17
#56 opened 12 months ago
by
Lord-Kvento
Llama, Mistral, Gemma… and now OpenAI enters the hunger games. 🐎⚔️
🚀🔥 2
2
#54 opened 12 months ago
by
Stephen555
Request: FP8 / BF16 version of model?
👍 3
2
#53 opened 12 months ago
by
Epliz
how to disable the reasoning mode?
👍 13
11
#50 opened 12 months ago
by
szzzzz
Enterprise AI factory OS
#47 opened 12 months ago
by
DavidSteinbauer
How to use different reasoning effort in the example?
🔥👍 2
2
#45 opened 12 months ago
by
TianheWu
Structured Outputs
1
#44 opened 12 months ago
by
DykeF
Problems with Metal
3
#42 opened 12 months ago
by
Thalesian
[v1 engine][flash_attn backend] TypeError: flash_attn_varlen_func() got an unexpected keyword argument 's_aux' when running gpt-oss-120b on H200
👍 8
14
#41 opened 12 months ago
by
RekklesAI
openai_harmony.HarmonyError: error downloading or loading vocab file: failed to download or load vocab file
13
#39 opened 12 months ago
by
rsullenbLL
Cooooool !大模型本地部署,能力评测,幻觉评测微信交流群,欢迎感兴趣的朋友加入
#38 opened 12 months ago
by
jakyer
I feel unsafe
🤗 5
9
#37 opened 12 months ago
by
lmganon123
Deploy gpt-oss models in your own AWS account using vLLM and Tensorfuse
🔥 2
3
#36 opened 12 months ago
by
agam30
Local Installation Video and Testing - Step by Step
#34 opened 12 months ago
by
fahdmirzac
vLLM FlashAttention3 with A6000
👍 17
19
#33 opened 12 months ago
by
YieumYoon