Views
No views yet
| Subgraph | Precision | Notes |
|---|---|---|
Vision encoder (vision.onnx) | FP32 | Unquantized |
Token embedding (embedding.onnx) | FP32 | Unquantized; bit-exact vs PyTorch |
Text decoder (text.onnx) | INT4 | Olive ModelBuilder k_quant, group/block size 128, accuracy_level=4. All 497 MatMulNBits weights are 4-bit. |
embedding.onnx + embedding.onnx.data # FP32 token embedding + image-feature scatter (~5.1 GB)
vision.onnx + vision.onnx.data # FP32 vision encoder (~3.7 GB)
text.onnx + text.onnx.data # INT4 hybrid decoder (~12.9 GB)
genai_config.json
processor_config.json
tokenizer.json
tokenizer_config.json
chat_template.jinja
config.json
generation_config.jsonmodel.type: qwen3_5) support.1pip install onnxruntime-genai huggingface_hub
2huggingface-cli download amd/Qwen3.8-27B-fp32-ve-fp32-int4-k_quant-gs128-text-cpu-onnx --local-dir ./qwen38-27b-cpu-onnx1import json
2import onnxruntime_genai as og
3
4model = og.Model("./qwen38-27b-cpu-onnx")
5tokenizer = og.Tokenizer(model)
6processor = model.create_multimodal_processor()
7stream = processor.create_stream()
8
9messages = [{"role": "user", "content": "What is the capital of France?"}]
10prompt = tokenizer.apply_chat_template(json.dumps(messages), add_generation_prompt=True)
11inputs = processor(prompt)
12
13params = og.GeneratorParams(model)
14params.set_search_options(max_length=256)
15generator = og.Generator(model, params)
16generator.set_inputs(inputs)
17
18while not generator.is_done():
19 generator.generate_next_token()
20 print(stream.decode(generator.get_next_tokens()[0]), end="", flush=True)images=og.Images.open("photo.jpg") into the processor with a chat message that includes {"type": "image"}.genai_config.json uses the default CPU execution provider (empty provider_options).genai_config.json are greedy (do_sample: false, top_k: 1).<|im_end|> (248046) and <|endoftext|> (248044).use_regex=true) so ONNX Runtime GenAI's C++ std::regex can load them.is not defined instead of Jinja is undefined for ORT GenAI minja.int4_algo_config: k_quant, int4_block_size: 128) from Qwen/Qwen3.8-27B. Vision and embedding were exported unquantized FP32.