qwen3-8b / README.md
IMvision12's picture
Fix Collection badge link to the current zeromodels collection slug
ffbb788 verified
|
Raw
History Blame Contribute Delete
3.4 kB
metadata
pipeline_tag: text-generation
license: apache-2.0
base_model: Qwen/Qwen3-8B
library_name: zeromodels
language:
  - en
tags:
  - keras
  - zeromodels
  - qwen3
  - qwen3-dense
  - text-generation
  - pytorch
  - jax
  - tf

Run Qwen3 with Keras 3: JAX, PyTorch, or TensorFlow

GitHub Docs HuggingFace

zeromodels/qwen3-8b

Pure-Keras 3 conversion of Qwen/Qwen3-8B for zeromodels. One implementation runs unmodified on TensorFlow / Torch / JAX. This is a dense Qwen3; weights are stored in bfloat16.

For model details, license, and usage terms, see the upstream model card.

Paper: Qwen3 Technical Report (arXiv:2505.09388) · HF Papers

Paper: YaRN: Efficient Context Window Extension of Large Language Models (arXiv:2309.00071) · HF Papers

✨ Quick start

import os
os.environ["KERAS_BACKEND"] = "torch"  # or "jax" / "tensorflow"

from zeromodels.models.qwen3 import Qwen3TextGenerate, Qwen3Tokenizer

model = Qwen3TextGenerate.from_weights("zeromodels/qwen3-8b")
tokenizer = Qwen3Tokenizer.from_weights("zeromodels/qwen3-8b")

inputs = tokenizer("Give me a short introduction to large language models.")
outputs = model.generate(**inputs, max_new_tokens=128)
print(tokenizer.decode(outputs[0]))

Load any Qwen3 variant the same way with from_weights("zeromodels/<variant>"):

Special Thanks

A huge thank you to the Qwen team at Alibaba for creating and releasing these models.

License: Apache 2.0.