# Spark-X2.6-4B-Base

> A little over a month has passed since Spark-X2.5. In the rapidly evolving world of AI agents, that is enough time to rethink, refine, and move the frontier forward.

- **Organisation:** XHToken
- **Category:** Chat & Text Generation
- **Parameters:** 4.1B
- **Context length:** 1,048,576 tokens
- **Licence:** Apache 2.0 (Commercial use OK)
- **Released:** 2026-10-19
- **Hugging Face:** 2.5K downloads (30 days), 48 likes

## Estimated memory

| Quant | ≈ GB |
|---|---|
| Q2_K | 2.95 |
| Q3_K_M | 3.59 |
| Q4_K_M | 4.06 |
| Q5_K_M | 4.49 |
| Q6_K | 4.94 |
| Q8_0 | 5.9 |
| F16 | 9.67 |

## Runs with

- [llama.cpp](https://selfhost.directory/project/llamacpp)
- [SGLang](https://selfhost.directory/project/sglang)
- [Transformers](https://github.com/huggingface/transformers)
- [Jan](https://jan.ai) (community)
- [KoboldCpp](https://selfhost.directory/project/koboldcpp) (community)
- [LM Studio](https://lmstudio.ai) (community)
- [LocalAI](https://selfhost.directory/project/localai) (community)
- [Ollama](https://selfhost.directory/project/ollama) (community)

## About

A little over a month has passed since Spark-X2.5. In the rapidly evolving world of AI agents, that is enough time to rethink, refine, and move the frontier forward. Building on the Spark-X2.5-4B, we introduce Spark-X2.6-4B, the latest generation of our compact, general-purpose language models for on-device deployment.

Spark-X2.6-4B retains exactly the same architecture as Spark-X2.5-4B, achieving its capability gains through improved post-training. It delivers substantial improvements in coding, agent, long-context, multilingual, reasoning, etc. These advances enable more capable and practical on-device AI for developers and users tackling real-world tasks.

Technical Highlights: - Stronger Coding, Agentic, and Long-Context Capabilities: The models deliver substantial improvements in agentic workflows involving complex tool use, multi-step planning, and software engineering. They achieve state-of-the-art performance among similarly sized open-source models, matching or even surpassing models with approximately 9B parameters. - Controllable Thinking Budget: The models provide three configurable thinking levels—none, low, high—allowing applications to balance reasoning quality, latency, and inference cost dynamically.

We recommend using Llama-Factory to fine-tune the model.

## Alternatives

- [nvidia/NVIDIA-Nemotron-3-Nano-4B-BF16](https://selfhost.directory/models/nvidia/nvidia-nemotron-3-nano-4b-bf16) (4B, nvidia-nemotron-open-model-license, ≈4.17 GB at Q4): NVIDIA-Nemotron-3-Nano-4B-BF16 is a small language model (SLM) trained from scratch by NVIDIA, and designed as a unified model for both reasoning and non-reasoning tasks. It responds to user queries and tasks by first generating a reasoning trace and then concluding with a final response.
- [Qwen/Qwen3-4B-Instruct-2507](https://selfhost.directory/models/qwen/qwen3-4b-instruct-2507) (4B, Apache 2.0, ≈4.01 GB at Q4): We introduce the updated version of the Qwen3-4B non-thinking mode, named Qwen3-4B-Instruct-2507, featuring the following key enhancements:
- [Qwen/Qwen3-4B](https://selfhost.directory/models/qwen/qwen3-4b) (4B, Apache 2.0, ≈4.01 GB at Q4): Qwen3 is the latest generation of large language models in Qwen series, offering a comprehensive suite of dense and mixture-of-experts (MoE) models.
- [Nanbeige/Nanbeige4.2-3B](https://selfhost.directory/models/nanbeige/nanbeige4.2-3b) (4.2B, Apache 2.0, ≈3.66 GB at Q4): Nanbeige4.2-3B is a compact agentic model built on Nanbeige4.2-3B-Base, designed to combine strong agentic behavior with broad reasoning and alignment capabilities. Its Looped Transformer architecture reuses the transformer layers to increase model capacity without adding parameters.
- [empero-ai/Qwen3.8-4B-Distill](https://selfhost.directory/models/empero-ai/qwen3.8-4b-distill) (4.7B, Apache 2.0, ≈4.26 GB at Q4): Qwen3.8-4B is a full-parameter distillation of Qwen3.8 2.4T A95B into the Qwen3.5-4B architecture. The student was trained on ~45,000 curated teacher traces from our internal Qwen3.8 distillation datasets — dense chain-of-thought spanning mathematics, general reasoning, and instruction following…
- [ibm-granite/granite-4.1-3b](https://selfhost.directory/models/ibm-granite/granite-4.1-3b) (3.4B, Apache 2.0, ≈3.14 GB at Q4): Model Summary: Granite-4.1-3B is a 3B parameter long-context instruct model finetuned from Granite-4.1-3B-Base using a combination of open source instruction datasets with permissive license and internally collected synthetic datasets.

More: https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base/alternatives

## Runs well on

- [GeForce RTX 4060](https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base/on/rtx-4060): Q8_0, est. 34 tok/s
- [Apple M4 (16 GB)](https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base/on/apple-m4-16gb): F16, est. 8 tok/s
- [Radeon RX 6700 XT](https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base/on/rx-6700-xt): F16, est. 26 tok/s
- [GeForce RTX 3060 12GB](https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base/on/rtx-3060): F16, est. 24 tok/s
- [Arc B580](https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base/on/arc-b580): F16, est. 30 tok/s
- [Tesla T4](https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base/on/tesla-t4): F16, est. 21 tok/s

## Similar size

- [meta-llama/Llama-3.2-3B-Instruct](https://selfhost.directory/models/meta-llama/llama-3.2-3b-instruct) (3.2B)
- [Qwen/Qwen3-4B](https://selfhost.directory/models/qwen/qwen3-4b) (4B)
- [Qwen/Qwen2.5-3B-Instruct](https://selfhost.directory/models/qwen/qwen2.5-3b-instruct) (3.1B)
- [microsoft/Phi-4-mini-instruct](https://selfhost.directory/models/microsoft/phi-4-mini-instruct) (3.8B)
- [Qwen/Qwen3-4B-Instruct-2507](https://selfhost.directory/models/qwen/qwen3-4b-instruct-2507) (4B)
- [XHToken/Spark-X2.6-4B](https://selfhost.directory/models/xhtoken/spark-x2.6-4b) (4.1B)

## FAQ

**How much VRAM does Spark-X2.6-4B-Base need?**
About 4.1 GB at Q4_K_M with an 8K context. Q8_0 needs about 5.9 GB and full precision about 9.7 GB. Longer contexts need more memory for the KV cache.

**Can Spark-X2.6-4B-Base run on the RTX 4060?**
Yes. It fits at Q8_0 (about 5.9 GB), at an estimated 34 tokens/s. It fits comfortably on the Apple M4 (16 GB), Radeon RX 6700 XT, RTX 3060 12GB.

**Can I use Spark-X2.6-4B-Base commercially?**
Yes. It is released under Apache 2.0. Permissive: use, modify and sell freely; keep the notice and licence text.

**What is the context length of Spark-X2.6-4B-Base?**
1,048,576 tokens (1M). The full window needs far more memory than an 8K context.

**How do I run Spark-X2.6-4B-Base with Ollama or llama.cpp?**
With Ollama: ollama run hf.co/mradermacher/Spark-X2.6-4B-Base-i1-GGUF:Q4_K_M. With llama.cpp: llama-server -hf mradermacher/Spark-X2.6-4B-Base-i1-GGUF:Q4_K_M, which starts an OpenAI-compatible server.

## Links

- huggingface: https://huggingface.co/XHToken/Spark-X2.6-4B-Base
- github: https://github.com/XHToken/LlamaFactory

---
Source: https://selfhost.directory/models/xhtoken/spark-x2.6-4b-base