The build commands are in the README. Windows: platforms.
src/,include/: the engine (basalt,basalt-bench,basalt-probe,basalt-vision).serve/: the Python server with the OpenAI and Anthropic API and the stats page.tools/: the converter (tools/convert/convert.py), the.basaltreader (model_file.py), the quality gate (ppl_gate.py), the greedy-identity check and the tokenizer.tests/: parity and unit tests.data/: expert profiles (data/profiles) and benchmark fixtures (data/bench).
The build fetches nothing. The ggml and llama.cpp parts Basalt uses (quantization formats, CPU dot products, MMQ) are in src/ and
include/basalt/ggml/, under the MIT licence in THIRD_PARTY_LICENSES.
-DWERROR=ON makes project warnings errors (CI sets it on Linux).
-DBASALT_MODELS=<ids> is a semicolon list of architecture ids, or all (the default), which builds every model and follows the
models a later version adds. A model left out is not compiled at
all: its C++ and CUDA sources, its kernels and its tests are skipped, which is most of the build time for DeepSeek.
| Model | Id |
|---|---|
| Qwen3.8-Flash-Next | qwen4exp |
| DeepSeek-V4.1-Flash | deepseek41 |
| Qwen3.8-27B | qwen35 |
| Hy4-flash | hy4flash |
| Inkling 2 Mini | inkling2 |
cmake -S . -B build -DBASALT_MODELS=qwen4exp # Flash-Next only
cmake -S . -B build -DBASALT_MODELS=deepseek41 # DeepSeek only
cmake -S . -B build -DBASALT_MODELS=qwen35 # the 27B only
cmake -S . -B build -DBASALT_MODELS=hy4flash # Hy4-flash only
cmake -S . -B build -DBASALT_MODELS=inkling2 # Inkling 2 Mini only
cmake -S . -B build "-DBASALT_MODELS=qwen4exp;deepseek41" # two of them; quote the semicolonAn unknown id or an empty list stops the configure and names the valid ids. A pack of a model the build left out fails at load with
architecture is 'deepseek41', a Basalt model this build left out (built with BASALT_MODELS=qwen4exp); rebuild with cmake -DBASALT_MODELS="qwen4exp;deepseek41;qwen35" to load it. The value is kept in the build folder's cache: to change it, pass the option again (-DBASALT_MODELS=all goes back to every
model). A folder configured by 0.4 holds that version's default list, qwen4exp;deepseek41;qwen35; the configure reads it as all.
Configure with -DBUILD_TESTING=ON, build, and run ctest --test-dir build.
- Kernel parity tests need the GPU.
expert_parityandpool_testuse a synthetic fixture;--file experts.binchecks real blobs. - Server tests:
python -m unittest discover -s serve/tests -t .afterpip install -r requirements-test.txt. - Tokenizer parity: register
tokenizer_paritywith-DBASALT_TOKENIZER_DIR=<a pack's tokenizer/ directory>.
basalt-bench reads its prompts from data/bench (run from the repository root, or pass --fixtures DIR).
Manual microbenches: avx_bench compares CPU expert kernels; transfer_bench checks RAM/GPU and
multi-GPU transfers without loading a model.