No description
  • C++ 55.7%
  • C 16.1%
  • Python 7.4%
  • Cuda 5.5%
  • TypeScript 4.1%
  • Other 11%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-10-06 22:05:25 +00:00
.devops llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.gemini llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.github llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.pi/gg llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
app llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
benches llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
ci llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
cmake llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
common Control vector projection mode, llama-resid-dump, refusal_direction.py 2026-10-06 20:53:22 +00:00
conversion llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
docs llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
examples llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
ggml Mirai S support (Qwen3.8-27B, 2.4-bit trellis) and long-context fixes 2026-09-26 17:47:06 +03:00
gguf-py Mirai S support (Qwen3.8-27B, 2.4-bit trellis) and long-context fixes 2026-09-26 17:47:06 +03:00
grammars llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
include Control vector projection mode, llama-resid-dump, refusal_direction.py 2026-10-06 20:53:22 +00:00
licenses llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
media llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
models llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
pocs llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
requirements llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
scripts llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
skills llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
src cvec projection: bounds guard on the per-layer flag (from professorpalmer/llama.cpp-ada-mirai be00bbdc1) 2026-10-06 21:39:52 +00:00
tests Mirai S support (Qwen3.8-27B, 2.4-bit trellis) and long-context fixes 2026-09-26 17:47:06 +03:00
tools README: mirai-s-ada numbers of 10-06 evening 2026-10-06 22:05:25 +00:00
vendor llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.clang-format llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.clang-tidy llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.dockerignore llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.ecrc llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.editorconfig llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.flake8 llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.gitignore llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.gitmodules llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
.pre-commit-config.yaml llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
AGENTS.md llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
AUTHORS llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
CLAUDE.md llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
CMakeLists.txt llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
CMakePresets.json llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
CODEOWNERS llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
CONTRIBUTING.md llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
convert_hf_to_gguf.py llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
convert_hf_to_gguf_update.py llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
convert_llama_ggml_to_gguf.py llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
convert_lora_to_gguf.py llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
flake.nix llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
LICENSE llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
Makefile llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
mypy.ini llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
pyproject.toml llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
pyrightconfig.json llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
README.md README: removing refusals, the 12 GB limits, and mirai-s-ada for the 262K window 2026-10-06 20:53:22 +00:00
requirements.txt llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
SECURITY.md llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00
ty.toml llama.cpp d834d44e6 (upstream snapshot) 2026-09-26 17:46:42 +03:00

llama.cpp-mirai-s

llama.cpp with support for Mirai S, Mirai Labs' 2.4-bit Qwen3.8-27B. The compressed trellis codes load from a GGUF bit for bit and run on CUDA, and the model fits a 12 GB GPU with 128K context. The fork also speeds up long-context decode with a q8_0/q4_0 KV cache, adds a chunked DeltaNet prefill kernel, and keeps the prompt cache when an agent's history re-tokenizes differently. With a 1.3 MB vector file it can also remove the model's refusals at run time (--cvec-mode project).

This is the reference fork: close to upstream, and the one the GGUF was verified on. For daily use on a 12 GB card look at mirai-s-ada by Cary Palmer first. It ports this codec to a serving engine with the full 262K window at q8_0 KV and MTP drafting, and it ships a Windows bundle. If that project changes or breaks, this fork still runs the same file.


llama.cpp

llama

Quick start

A few options to get llama.cpp installed on your machine:

Once installed:

# Download and run a model directly from Hugging Face
llama cli -hf ggml-org/Qwen3.5-0.8B-GGUF

# Launch OpenAI-compatible API server
llama serve -hf ggml-org/Qwen3.5-0.8B-GGUF
VLM session with `llama cli` VLM session with llama cli Built-in web UI against `llama serve` running Qwen 3.6 Built-in web UI against llama serve

Description

The main goal of llama.cpp is to enable LLM (and VLM) inference with minimal setup and state-of-the-art performance on a wide range of hardware - locally and in the cloud.

  • Plain C/C++ implementation without any dependencies
  • Apple silicon is a first-class citizen - optimized via ARM NEON, Accelerate and Metal frameworks
  • AVX, AVX2, AVX512 and AMX support for x86 architectures
  • RVV, ZVFH, ZFH, ZICBOP and ZIHINTPAUSE support for RISC-V architectures
  • 1.5-bit, 2-bit, 3-bit, 4-bit, 5-bit, 6-bit, and 8-bit integer quantization for faster inference and reduced memory use
  • Custom CUDA kernels for running LLMs on NVIDIA GPUs (support for AMD GPUs via HIP and Moore Threads GPUs via MUSA)
  • Vulkan and SYCL backend support
  • CPU+GPU hybrid inference to partially accelerate models larger than the total VRAM capacity

The llama.cpp project is build on top of the ggml library.

Supported backends

Backend Target devices
BLAS All
BLIS All
CANN Ascend NPU
CUDA Nvidia GPU
HIP AMD GPU
Hexagon Snapdragon
IBM zDNN IBM Z & LinuxONE
MUSA Moore Threads GPU
Metal Apple Silicon
OpenCL Adreno GPU
OpenVINO [In Progress] Intel CPUs, GPUs, and NPUs
RPC All
SYCL Intel GPU
VirtGPU VirtGPU APIR
Vulkan GPU
WebGPU All
ZenDNN AMD CPU

Documentation

Tools

Development

Contributing

  • Contributors can open PRs
  • Collaborators will be invited based on contributions
  • Maintainers can push to branches in the llama.cpp repo and merge PRs into the master branch
  • Any help with managing issues, PRs and projects is very appreciated!
  • Read the CONTRIBUTING.md for more information

Acknowledgements

  • yhirose/cpp-httplib - Single-header HTTP server, used by llama-server - MIT license
  • nothings/stb - Single-header image format decoder, used by multimodal subsystem - Public domain
  • nlohmann/json - Single-header JSON library, used by various tools/examples - MIT License
  • mackron/miniaudio - Single-header audio format decoder, used by multimodal subsystem - Public domain
  • sheredom/subprocess.h - Single-header process launching solution for C and C++ - Public domain