Instructions to use ZAQERIS/ZAQERIS_AXIOM with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ZAQERIS/ZAQERIS_AXIOM with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="ZAQERIS/ZAQERIS_AXIOM", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("ZAQERIS/ZAQERIS_AXIOM", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use ZAQERIS/ZAQERIS_AXIOM with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ZAQERIS/ZAQERIS_AXIOM" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ZAQERIS/ZAQERIS_AXIOM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/ZAQERIS/ZAQERIS_AXIOM
- SGLang
How to use ZAQERIS/ZAQERIS_AXIOM 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 "ZAQERIS/ZAQERIS_AXIOM" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ZAQERIS/ZAQERIS_AXIOM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "ZAQERIS/ZAQERIS_AXIOM" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ZAQERIS/ZAQERIS_AXIOM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use ZAQERIS/ZAQERIS_AXIOM with Docker Model Runner:
docker model run hf.co/ZAQERIS/ZAQERIS_AXIOM
AXIOM (ZAQERIS/ZAQERIS_AXIOM)
Developed by ZAQERIS AI, an independent open-source AI research group in Egypt.
AXIOM is a sparse Mixture-of-Experts language model trained from scratch and released under Apache License 2.0. The public checkpoint is packed with ZAQERIS-M3, a sub-3-bit vector quantization format, so the full model fits in 36 .safetensors shards totaling 29.20 GiB.
| Total parameters | 79.43B (79,425,295,488) |
| Active parameters per token | 12.39B (12,390,618,240) |
| License | Apache License 2.0 |
| Weights on disk | 29.20 GiB (31,355,872,804 bytes, 36 shards) |
| Quantization | ZAQERIS-M3, 3.16 bits per parameter (3.1583 bpp) |
Links: Model · GitHub · X · Patreon · Architecture explorer
Why the Hub badge shows ~30B. Hugging Face counts stored tensor elements, not unpacked logical parameters. ZAQERIS-M3 packs weights mainly as
uint8bytes, so the scanner reports about30.26Bstored elements (29.78BU8+0.31BI32+0.17BF16). After unpacking, the architecture is 79.43B total / 12.39B active. Standard FP16 storage for 79.43B parameters would be about 147.94 GiB.
نبذة
AXIOM نموذج لغوي تأسيسي من مجموعة ZAQERIS AI البحثية المستقلة في مصر. يضم 79.43 مليار معامل (MoE)، و12.39 مليار معامل نشط لكل توكن، ودُرِّب من الصفر. الأوزان المنشورة بصيغة ZAQERIS-M3 بحجم 29.20 غيغابايت ثنائية (GiB) على 36 ملفًا، بمعدل 3.16 بت لكل معامل، ومرخّصة برخصة Apache 2.0.
- المستودع: ZAQERIS/ZAQERIS_AXIOM
- GitHub: ZAQERIS/ZAQERIS
- X: @ZAQERIS_Ai
- Patreon: ZAQERISAI
Architecture
These figures match config.json in this repository.
| Parameter | Value |
|---|---|
| Model class | ZaqerisAxiomForCausalLM (model_type: zaqeris_axiom) |
| Total / active parameters | 79.43B / 12.39B per token |
| Decoder layers | 36 |
| Experts | 16 per layer, top-2 routing |
| Hidden size / expert FFN | 4224 / 10496 |
| Attention | GQA, 32 query heads / 8 key-value heads, head dim 128 |
| Context | 131,072 native; extendable to 1,048,576 with YaRN (factor 8.0) |
| RoPE | theta = 5,000,000.0 |
| Vocabulary | 148,480 tokens (ZaqerisAxiomTokenizer) |
| Quantization | ZAQERIS-M3 at 3.16 bpp |
| Package size | 29.20 GiB in 36 shards |
The tokenizer runtime is a radix-trie prefix matcher implemented in tokenization_zaqeris_axiom.py. vocab.json ships 148,458 base entries (ids 0–148457). Official special-token ids from config.json sit just above that range: pad 148458 (<|axiom_pad_0|>), bos 148459 (<|im_start|>), eos 148460 (<|im_end|>). The configured vocab_size is 148,480.
Size and hardware
The published weights occupy 29.20 GiB on disk. You need enough GPU memory, or a mix of GPU plus system RAM via device_map="auto", to hold that footprint plus activations and the KV cache.
The native context is 131,072 tokens. YaRN (factor = 8.0) extends the positional range to 1,048,576 tokens. A 1M-token KV cache is large relative to a 48 GB card; plan memory for the context length you actually use, not only for the packed weights.
A walkthrough of the architecture is in the AXIOM Architecture Explorer. A live chat Space is planned once GPU hosting is available; it is not running today.
Quickstart (Transformers)
trust_remote_code=True is required because the model, config, and tokenizer classes live in this repository.
import torch
from transformers import AutoTokenizer, AutoModelForCausalLM
model_id = "ZAQERIS/ZAQERIS_AXIOM"
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(
model_id,
device_map="auto",
trust_remote_code=True,
)
messages = [
{"role": "user", "content": "Write a Python function for binary search and explain its complexity."}
]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer(prompt, return_tensors="pt")
inputs = {k: v.to(model.device) for k, v in inputs.items()}
with torch.no_grad():
outputs = model.generate(
**inputs,
max_new_tokens=512,
temperature=0.7,
top_p=0.9,
do_sample=True,
pad_token_id=tokenizer.pad_token_id,
eos_token_id=tokenizer.eos_token_id,
)
print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[1]:], skip_special_tokens=True))
Download is about 29.20 GiB. The first load will take a while.
Serving with vLLM
vllm_axiom_plugin.py registers ZaqerisAxiomForCausalLM and the zaqeris_m3 quantization method with vLLM on Linux/CUDA. If vLLM is not installed, the same script can expose a local /v1/chat/completions endpoint:
python vllm_axiom_plugin.py --model ZAQERIS/ZAQERIS_AXIOM --host 0.0.0.0 --port 8000
from vllm_axiom_plugin import register_zaqeris_axiom_with_vllm
from vllm import LLM
register_zaqeris_axiom_with_vllm()
llm = LLM(model="ZAQERIS/ZAQERIS_AXIOM", trust_remote_code=True)
Technical reports
More detail on the architecture and ZAQERIS-M3 is in this repository:
- English:
AXIOM_WHITEPAPER_EN.md - العربية:
AXIOM_WHITEPAPER_AR.md - Provenance notes:
PROVENANCE_AND_AUDIT.md
This card does not publish official full-suite benchmark scores. Please run and report your own evaluations if you use AXIOM.
License and citation
AXIOM is released under the Apache License, Version 2.0. See LICENSE and NOTICE. Commercial use, modification, and redistribution are allowed under those terms, including attribution.
@misc{zaqeris_axiom_2026,
title={AXIOM: 3-Stage 8D Vector Quantization for a 79.43B Sparse Mixture-of-Experts Language Model},
author={ZAQERIS AI Research Group},
year={2026},
howpublished={\url{https://huggingface.co/ZAQERIS/ZAQERIS_AXIOM}},
note={Also available at https://github.com/ZAQERIS/ZAQERIS}
}
- Downloads last month
- 2,229