Skip to content
Projects

About

The fastest inference engine for the NPU of AMD Ryzen AI processors: LLMs, vision, speech and Stable Diffusion on XDNA 2, with an OpenAI- and Anthropic-compatible server

AI & Machine Learning

How these counts are measured

32 stars5 Forks +1 in 24h

Measured star growth

in 24h
+1
in 7 days
Collecting history
in 15 days
Collecting history
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

README.md

Original

Artlite

The fastest inference engine for the NPU of AMD Ryzen AI processors

License: LGPL-2.1-or-later Python 3.12-3.14 Linux, Windows NPU: XDNA 2 (AIE2P)

Artlite runs language, vision and speech models and Stable Diffusion on the XDNA 2 NPU of AMD Strix Point, Krackan Point and Strix Halo processors, and serves them to apps and coding agents.

  • Fast prompts and generation. Artlite processes prompts 1.7-11x faster than FastFlowLM, the next fastest engine, and generates text 1.1-2.3x faster (Performance).
  • A local server for apps and agents. OpenAI- and Anthropic-compatible APIs with tool calls, structured output, a prompt cache and several requests at a time. Claude Code, Codex and opencode work with it.
  • Text, images, video and speech. Chat, questions about images and videos, transcripts with speakers, text to speech, voice conversations, embeddings and image generation.
  • Built for XDNA 2. Artlite's own JIT toolchain generates every NPU kernel for the model's shapes and weight formats and compiles it at run time.

Quick start

You need a Ryzen AI processor with an XDNA 2 NPU, Linux with the amdxdna driver, libdrm, CMake, a C++23 compiler and uv. Windows 11, NixOS and the details are in Installation.

git clone https://github.com/artlite-project/artlite && cd artlite
uv venv && source .venv/bin/activate
uv sync --no-dev

Download a model into the models directory (~/.artlite/models, laid out as on Hugging Face) and run it:

uvx --from huggingface_hub hf download ggml-org/gemma-4-E4B-it-GGUF \
    gemma-4-E4B-it-Q4_0.gguf mtp-gemma-4-E4B-it-Q4_0.gguf --local-dir ~/.artlite/models/ggml-org/gemma-4-E4B-it-GGUF

M=ggml-org/gemma-4-E4B-it-GGUF/gemma-4-E4B-it-Q4_0.gguf
artlite-cli -m $M -p "Factorize x^2 + x - 6"     # answer in the terminal
artlite-server -m $M -rea on                     # API and web chat on http://127.0.0.1:8080
artlite-server                                   # every downloaded model, with a model picker
artlite-bench -m $M -p 1024,8192 -n 128          # prompt and generation speeds, as llama-bench
The web chat on Gemma 4 E4B: a question, its collapsed reasoning, the answer and its speed

Documentation

Installation hardware, driver, build on Linux, Windows 11 and NixOS, troubleshooting
artlite-cli text, images and transcripts from the command line
artlite-server the API server and web chat, coding agents
artlite-bench, artlite-probe prompt and generation speeds; the NPU's clock and memory rates
Models supported models and files, how each model runs on the NPU
Benchmark methodology how the charts are measured
Where the NPU fits the NPU vs. the iGPU: memory bandwidth, power, workloads
Design, Development how Artlite works; tests, operators and kernel tools

All pages: docs/.

Models

model what it does
Llama 3.2 1B, 3B, Llama 3.1 8B text
Qwen3 0.6B, Qwen3-Embedding, Qwen3-Reranker text, embeddings, rerank, decisions
Gemma 4 E4B text
Qwen3.5 9B, Qwen3.6 27B, Qwen3.8 27B, Qwen3.6 35B-A3B, MiniCPM-V 4.7 text, images, decisions
LFM3 1.7B, LFM3-VL, LFM3-Audio, LFM3-Omni text, images, video, speech in and out, decisions
Spark-X2.6 4B, 1.7B text
Flint text
Inkling 2 Mini text, images
MOSS-Transcribe-Diarize transcripts with timestamps and speakers
Stable Diffusion 1.5 image generation

Artlite loads GGUF files, Hugging Face checkpoints and ParoQuant checkpoints. The tested files of each model and the planned models are listed in Models.

Performance

How these are measured: Benchmark methodology.

Decode speed in tokens/s after a 1k- and a 32k-token prompt, one bar per model and GGUF file, FastFlowLM's and OpenFlowLM's bars under the comparable Artlite file Prefill speed in tokens/s for a 1k- and a 32k-token prompt, one bar per model and GGUF file, FastFlowLM's and OpenFlowLM's bars under the comparable Artlite file Time to first token against prompt length from 1k to 128k tokens on log-log axes, one panel per model, Artlite, FastFlowLM and OpenFlowLM Time to first token of MiniCPM-V 4.7 1B with an image, for four images with their slice grids and the 16x and 4x vision encoders: Artlite, FastFlowLM and llama.cpp on the iGPU (Vulkan)

How it works

The host builds each operator's design once (C++ and an IRON design per shape, compiled by Peano and aiecc into an ELF that configures the NPU), packs a GGUF file's weights once into a weight image in DRAM, and dispatches a transaction every step through the runtime and the amdxdna driver; the NPU's 8 columns stream the weights and the KV cache from DRAM through one 32-byte-per-cycle port, about 57 GB/s

Each operator renders a C++ kernel and an IRON design of the array's data movement for its shapes. Peano (LLVM for AI Engine) and aiecc compile them once into the ELF that configures the array, and the build cache keeps the result. At load, the weights are packed into one buffer in DRAM. For every step the host builds a transaction and dispatches it to the NPU through the amdxdna driver (through XRT on Windows). A decode step runs on an overlay design whose cores read their work from that transaction, and a prompt runs as chunk programs assembled from a library of compiled designs. Details: Design.

Explore related projects

Loading…