Instructions to use Luigi/dict-xs-onnx with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers.js
How to use Luigi/dict-xs-onnx with Transformers.js:
// npm i @huggingface/transformers import { pipeline } from '@huggingface/transformers'; // Allocate pipeline const pipe = await pipeline('text-generation', 'Luigi/dict-xs-onnx');
Configuration Parsing Warning:Config file config.json cannot be fetched (too big)
Configuration Parsing Warning:Config file tokenizer_config.json cannot be fetched (too big)
dict-xs ONNX (int8)
ONNX weights of ikhou/dict-xs (Qwen3-0.6B dictionary fine-tune), quantized to int8 (dynamic), compatible with Transformers.js v4 on CPU/WASM.
Files
| File | Size | Notes |
|---|---|---|
onnx/model_quantized.onnx |
619 MB | int8 dynamic-quantized decoder (self-contained, no external data) |
config.json / tokenizer*.json |
โ | Qwen3 config + tokenizer (chat template embedded) |
Usage (browser / Node)
import { pipeline } from '@huggingface/transformers';
const generator = await pipeline('text-generation', 'Luigi/dict-xs-onnx', {
dtype: 'q8', // CPU/WASM
// device: 'webgpu', dtype: 'q4f16' // optional GPU path
});
const out = await generator([
{ role: 'system', content: 'You are a bilingual dictionary...' },
{ role: 'user', content: 'Expression: "maison"\nContext: ...' },
], { max_new_tokens: 50, temperature: 0.3, top_p: 0.9 });
Conversion notes
- Exported from
ikhou/dict-xs(bfloat16 safetensors, step 6568 = the repo'smainweights) into the fused decoder graph (GroupQueryAttention + RotaryEmbedding contrib ops, opset 18,position_idsinput) used byonnx-community/Qwen3-0.6B-ONNX, with the fine-tuned weights transplanted. - Numerically verified against the PyTorch checkpoint (max logit diff โ 5e-5 fp32; greedy decode matches the HF reference up to int8 noise).
- Generated with the repo's own export script:
scripts/export_onnx.py(seeikhou/dict-xs-demospace for the browser demo).
- Downloads last month
- -