ONNX Model Zoo

rishiikc/openai-gpt-oss-20b-onnx-bf16

By rishiikc · ↓ 0 · ♥ 0 · Updated 2025-08-28

What's in this repo

This page lists the files in rishiikc/openai-gpt-oss-20b-onnx-bf16, including model.onnx.

  • 1 ONNX models (.onnx files)
  • 9 files, including 4 .json, 1 .md, 1 .jinja, 1 .onnx, 1 .data
  • Last updated 2025-08-28

ONNX files

File Size Download
model.onnx — Download

How to use

These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.

README

gpt-oss-20b ONNX model (deqauntized to BF16)

This repository contains an ONNX export of the openai/gpt-oss-20b from Hugging Face, generated using the official onnxruntime-genai builder. The choice of setting the precision to BF16 was mainly out of lack of resources on my M4 mini followed by my limited knowledge of the GenAI engineering ecosystem.

Model Overview

  • Source Model: openai/gpt-oss-20b from 🤗
  • Exported Format: ONNX
  • Precision: BF16 (dequantized from MXFP4 for GPU compatibility)
  • Layers: 24 decoder layers, embedding layer, final normalization, and language modeling (LM) head

This repository includes all files: tokenizer, chat templates and configuration files.

Generation Details

The ONNX model was generated using the builder.py script from the onnxruntime-genai toolkit. The process involved:

  • Loading the original gpt-oss-20b checkpoint from 🤗
  • Reading and converting all model layers (embedding, decoder, final norm, LM head)
  • Saving the ONNX model and associated external data file
  • Exporting tokenizer and configuration files
  • Model layers and weights were successfully read and converted
  • MXFP4 quantized weights were dequantized to BF16
  • All necessary files for GenAI runtime and Hugging Face integration were generated

Usage

To use this ONNX model:

  1. Download the model files and tokenizer assets from this repository.
  2. Load the ONNX model using onnxruntime or compatible inference engines.

Acknowledgements


Model info

transformers
transformers onnx base_model:openai/gpt-oss-20b base_model:quantized:openai/gpt-oss-20b license:apache-2.0 endpoints_compatible region:us
↓ 0 ♥ 0

Created: 2025-08-28

Updated: 2025-08-28

View on Hugging Face

Files (9)

.gitattributes
README.md
chat_template.jinja
genai_config.json
model.onnx ONNX
model.onnx.data
special_tokens_map.json
tokenizer.json
tokenizer_config.json

Related models