llama.cpp fork supporting the tardits model family
  • C++ 55.6%
  • C 16.3%
  • Python 7.7%
  • Cuda 5%
  • TypeScript 4.5%
  • Other 10.7%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
dsh 337629e96b
Some checks failed
ui-publish.yml / docs: log AGENTS.d split, README hero and quantization sweep (push) Failing after 0s
Code Style Checker / model-naming (push) Has been cancelled
EditorConfig Checker / editorconfig (push) Has been cancelled
docs: log AGENTS.d split, README hero and quantization sweep
2026-11-18 19:50:18 +01:00
.devops ci: update oneAPI 2026.2, oneDNN 2026.1 and Level Zero SDK 1.34.0 (#31540) 2026-11-10 01:18:44 -05:00
.gemini
.github ci : remove dead snakes (#32084) 2026-11-11 15:13:14 +01:00
.pi/gg pi : turn .pi/gg into a system prompt addendum (#30762) 2026-10-19 09:11:13 +03:00
app cmake : use PROJECT_SOURCE_DIR instead of CMAKE_SOURCE_DIR (#28771) 2026-09-15 05:26:09 +02:00
benches benches : add Nemotron 3 Nano on DGX Spark (#20652) 2026-03-16 21:50:43 +02:00
ci llama : Add FP8 KV-cache support (#28392) 2026-11-10 18:08:32 +02:00
cmake cmake : generate RC file directly without win-app.rc.in (#31718) 2026-11-06 11:02:47 +01:00
common chat : fix Muse Spark ignoring response_format json_schema (#32017) 2026-11-10 23:30:14 +01:00
conversion ci : bump ty to 0.0.100 (#32030) 2026-11-10 21:54:14 +01:00
docs docs: README fork header with TARDITS hero (RAT @ llama.cpp) 2026-11-18 19:44:43 +01:00
examples ci : bump ty to 0.0.100 (#32030) 2026-11-10 21:54:14 +01:00
ggml feat(tardits): CD levels 1-7 (128 dims), analytic spreads, exact vectorized CD tables 2026-11-13 07:01:43 +01:00
gguf-py ci : bump ty to 0.0.100 (#32030) 2026-11-10 21:54:14 +01:00
grammars common : implement common_schema internal representation for JSON schemas (#28736) 2026-09-12 16:14:50 -05:00
include llama_moe_cache: run missed experts on CPU, add tuning script (#30966) 2026-11-08 00:20:58 +08:00
licenses refactor : remove libcurl, use OpenSSL when available (#18828) 2026-01-14 18:02:47 +01:00
media ui: update the README banner to the new llama.cpp cover and remove the legacy brand assets (#31789) 2026-11-10 22:43:27 +01:00
models model : add LiquidAI/LFM3-1.7B and LiquidAI/LFM3-VL-2B (#31252) 2026-10-27 17:06:40 +01:00
pocs cmake : fix build when GGML_CPU=OFF and GGML_CUDA=ON (#29026) 2026-09-18 11:44:03 +03:00
requirements requirements : minor adjustments for python 3.14 wheels (#31534) 2026-11-02 11:34:45 +01:00
scripts vendor: update cpp-httplib to 0.66.0 (#32049) 2026-11-11 20:07:30 +08:00
skills mtmd: refactoring: remove clip.h, consolidate code into mtmd (#31865) 2026-11-08 15:49:06 +01:00
src feat(quantize): quantize TARDITS split planes, keep attn_gamma F32 2026-11-18 19:48:50 +01:00
tardits2gguf chore: move private notes to agentic/llama.cpp, retarget input box to AGENTS.d/ 2026-11-18 19:44:02 +01:00
tests feat(tesseract): WereRAT/Tessa arch - hijacked SmolLM2 E/head + real bridge around a level-1 RAT 2026-11-18 19:16:58 +01:00
tools quantize: fix imatrix GGUF filepath metadata leak (#32000) 2026-11-11 19:13:28 +08:00
vendor vendor: update cpp-httplib to 0.66.0 (#32049) 2026-11-11 20:07:30 +08:00
.clang-format
.clang-tidy clang-tidy : disable warning about performance enum size (#16127) 2025-09-22 19:57:46 +02:00
.dockerignore docker : prebuild web UI for s390x build [no release] (#24829) 2026-06-20 05:54:42 -05:00
.ecrc cmake : use PROJECT_SOURCE_DIR instead of CMAKE_SOURCE_DIR (#28771) 2026-09-15 05:26:09 +02:00
.editorconfig vendor: apply deep nested json patch from upstream (#30253) 2026-10-10 00:07:44 +02:00
.flake8 ci : re-enable type/lint-check for skills (#30713) 2026-10-20 01:03:03 +02:00
.gitignore chore: move private notes to agentic/llama.cpp, retarget input box to AGENTS.d/ 2026-11-18 19:44:02 +01:00
.gitmodules
.pre-commit-config.yaml convert.py : add python logging instead of print() (#6511) 2024-05-03 22:36:41 +03:00
AGENTS.md docs: quantization, upstream PR and Tesseract-mobile pointers in the map 2026-11-18 19:49:43 +01:00
AUTHORS llama.cpp : bump version to 0.9.0 (#31646) 2026-11-04 14:06:26 +02:00
build-xcframework.sh metal : add metallib build support for xcframework (#28163) 2026-09-02 07:45:56 +08:00
CLAUDE.md
CMakeLists.txt llama.cpp : bump version to 0.9.0 (#31646) 2026-11-04 14:06:26 +02:00
CMakePresets.json
CODEOWNERS llama_moe_cache: run missed experts on CPU, add tuning script (#30966) 2026-11-08 00:20:58 +08:00
CONTRIBUTING.md docs: Rule of thumb for AI review time [no ci] (#28945) 2026-09-15 14:11:16 +02:00
convert_hf_to_gguf.py feat: external PLE file loading (#31185) 2026-11-09 19:41:01 +01:00
convert_hf_to_gguf_update.py ci : bump ty to 0.0.100 (#32030) 2026-11-10 21:54:14 +01:00
convert_llama_ggml_to_gguf.py ci : switch from pyright to ty (#20826) 2026-03-21 08:54:34 +01:00
convert_lora_to_gguf.py ci : bump ty to 0.0.100 (#32030) 2026-11-10 21:54:14 +01:00
flake.nix nix : update deprecated expressions (#28145) 2026-09-07 15:59:45 +02:00
input chore: move private notes to agentic/llama.cpp, retarget input box to AGENTS.d/ 2026-11-18 19:44:02 +01:00
LICENSE docs : Minor cleanups (#19252) 2026-02-02 08:38:55 +02:00
LOG.md docs: log AGENTS.d split, README hero and quantization sweep 2026-11-18 19:50:18 +01:00
Makefile
mypy.ini convert : partially revert PR #4818 (#5041) 2024-01-20 18:14:18 -05:00
pyproject.toml gguf-py: fix np_roundf dropping the sign (#31310) 2026-10-28 14:03:59 +01:00
pyrightconfig.json ci : switch from pyright to ty (#20826) 2026-03-21 08:54:34 +01:00
README.md docs: quantization, upstream PR and Tesseract-mobile pointers in the map 2026-11-18 19:49:43 +01:00
requirements.txt
SECURITY.md security : clarify about AI-generated reports (#26579) 2026-08-05 13:27:06 +02:00
TARDITS.md chore: move private notes to agentic/llama.cpp, retarget input box to AGENTS.d/ 2026-11-18 19:44:02 +01:00
ty.toml ci : bump ty to 0.0.100 (#32030) 2026-11-10 21:54:14 +01:00

RAT @ LLAMA.CPP
the TARDITS model family, running on llama.cpp

Home repo - https://git.pvlb.dev/ml-lab/llama.cpp
Model lab: ml-lab/tardits · TARDITS.md · AGENTS.md

RAT @ llama.cpp: a neon cybernetic rat riding a llama, surrounded by hypercomplex wireframes and the caption RAT @ LLAMA.CPP.

This is ml-lab's fork of llama.cpp. It adds the TARDITS model family to llama.cpp: complex- and hypercomplex-valued language models (Cayley-Dickson levels 1-7, up to 128 real dimensions) and RAT, a recurrent attention with a linear fast-weight memory and O(1) decode.

What is in here on top of upstream:

  • Three arch strings: tardits (RAT, recurrent), tardits-hyper (HyperFormer, attention with GyRoPE + SAIL) and tesseract (WereRAT: a RAT trunk with a borrowed SmolLM2 embedding/head behind a real bridge, for latent-distillation students).
  • Custom ggml ops: ggml_cd_mul (elementwise Cayley-Dickson product) and ggml_tardits_scan[_cd] (the RAT recurrence), with CPU kernels.
  • GGUF conversion (tardits2gguf/): split real/imag plane layout for levels 1-7, SmolLM2 BPE or char-level tokenizer, tied or hijacked embedding/head.
  • Parity-tested: logits match the PyTorch reference from the step/recurrence path to ~1e-6-1e-5, with the drift of the training scan documented. A real trained quaternion model speaks through it.
  • Quantization-aware: llama-quantize understands the split complex planes; the RAT decay (attn_gamma) stays F32 by design, because the scan kernel reads it as raw floats and 4-bit decay was the one thing that measurably broke the recurrence.

The goal is to make these models shareable as GGUF and runnable on consumer hardware and phones. The TARDITS-native story, commands and honest results are in TARDITS.md; the engineering map is AGENTS.md.

Status: early but working - complex/hypercomplex levels run at 1e-6 parity, a real trained quaternion model (49M params, SmolLM2 tokenizer) converts and speaks English, and a WereRAT/Tessa checkpoint runs at 1.9e-5 parity. Upstream compatibility is a work in progress: treat this as a model-family fork, not a general llama.cpp replacement.

Everything below this line is the upstream llama.cpp README.


llama.cpp

llama.cpp

Quick start

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

# curl
curl -LsSf https://llama.app/install.sh | sh

# powershell
irm https://llama.app/install.ps1 | iex

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 Huawei 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