Kefir 1
Kefir 1 is the final conversational checkpoint of an English mixture-of-experts decoder by Edoardo Avenia and Rocco Angelella. It has 144,074,648 parameters, 9,987,992 of them active per token, and a 2,048-token context shared by the conversation and the reply. It supports research on small-model training, chat formatting and stopping behavior.
Use the checkpoint
The weights run through the Kefir CLI in the GitHub repository, not through transformers. The CLI consumes model.safetensors with embedded model configuration and tokenizer identity. Use Python 3.12 or newer and uv. The chat command runs on CPU by default.
git clone https://github.com/ABCastor/kefir-1 && cd kefir-1
uv sync --locked --extra hf
uv run hf download abcastor/kefir-1 model.safetensors --local-dir weights/kefir-1
uv run kefir chat --weights weights/kefir-1/model.safetensors --prompt "What is the capital of Japan?"
Output of the chat command, run once on 2026-11-25 on a 4-core CPU with the released file (SHA-256 below):
Loading Kefir 1 weights...
Assistant> The capital of Japan is Tokyo.
The expected SHA-256 of the released file is 5d5bcb0d13b1df69c2625f336e724a4387126c2cef39e6d16a6aded2912758fe. Leave out --prompt for an interactive chat. Pass --system-prompt "" to disable the default System message. A prompt and its reserved reply tokens share a 2,048-token budget. The CLI drops older whole exchanges as needed and rejects a prompt if the System message and latest User message still cannot fit.
Architecture
Each layer applies a sequence mixer and then a routed feed-forward block. The table gives the configuration shared by the pretrained and fine-tuned checkpoints.
| Property | Configuration |
|---|---|
| Decoder | 8 layers, two repeats of three Gated DeltaNet 2 layers and one gated causal attention layer |
| Width and attention | Model width 256, four attention heads of width 64 |
| Feed-forward | 64 SwiGLU experts per layer, hidden width 352, top-2 routing |
| Parameters | 144,074,648 total, 9,987,992 active per token |
| Vocabulary | 8,000 SuperBPE token IDs, 8,192 padded embedding rows |
The detailed diagram is in the architecture page of the GitHub repository.
Training
- Pretraining. Kefir 1 Base: 310,000 updates on the Kefir 1 pretraining corpus, tokenized with the SuperBPE 8k English tokenizer.
- First fine-tuning. Kefir 1 SFT-15k: 15,000 conversations, flat batch 32, seed 17.
- Continuation. 40,490 further conversations from the SFT conversations, each seen once (55,490 in total, 39,355,420 assistant targets). Two arms used the same conversations in the same order; in one, System text was added to 16,193 of them (about 40%). Kefir 1 is the end of the added-System arm.
Fine-tuning ran on two NVIDIA T4s in FP16 with hybrid Muon/AdamW and a constant learning rate of 3e-5. Only Assistant text and its end token contribute to the loss.
Evaluation
In a zero-shot comparison with lm-evaluation-harness 0.4.13, scored as raw text without the chat format, Kefir 1 averages 47.2 over nine tasks, against 47.7 for Kefir 1 Base, 47.6 for GPT-2 124M FineWeb-Edu, 43.8 for TinyBrainBot 61M-A10M, 41.0 for Cerebras-GPT-111M, 39.3 for Pythia-70M at step 3,000, 54.0 for SmolLM2-135M and 60.0 for Qwen3-0.6B-Base (benchmarks).
Native prompts throughout. Assistant NLL covers the 512 validation conversations. Benchmark counts are from the frozen kefir-bench/1 development split, evaluated on CPU in FP32.
| Measure | Shared 15,000-chat checkpoint | Added System prompts (Kefir 1) | No added System prompts |
|---|---|---|---|
| Assistant NLL, nats per target ↓ | 1.787421 | 1.688240 | 1.674787 |
| BLiMP, grammatical pairs ↑ | 52/64 | 49/64 | 49/64 |
| ARC-Easy, raw likelihood ↑ | 16/30 | 17/30 | 18/30 |
| Instruction constraints met ↑ | 16/36 | 13/36 | 13/36 |
Each continuation is one training run. The released arm (Kefir 1) did not score better than the arm without added System text on any of the four measures: its assistant NLL is higher (1.688240 against 1.674787), it got one fewer ARC-Easy item right, and its BLiMP and instruction-constraint counts are equal. Against the shared 15,000-chat parent, NLL and ARC-Easy improved, while BLiMP and instruction constraints fell. Exact-match knowledge, contextual answers and reasoning scores were zero on the development probes. These development measurements establish no external-model ranking. The training corpus may overlap benchmark text.
Chat format
Renderer C uses these token boundaries. Role names and their following newlines are tokenized as text.
[7993] system\n <text> [7994] optional opening message
[7993] user\n <text> [7994]
[7993] assistant\n <text> [7992]
User and Assistant messages alternate. Generation starts after the Assistant header and stops at token 7992 or the reply cap.
Limits and licence
Use this checkpoint for research. It can produce incorrect or incoherent English and has received no safety tuning.
The weights are licensed CC BY-NC 4.0; the code and tokenizer are MIT. The pretraining text comes from NVIDIA Nemotron-ClimbMix (CC BY-NC 4.0), filtered and re-tokenized. The fine-tuning conversations keep their source terms, including 569 Dolly conversations under CC BY-SA 3.0. Details are in this repository's NOTICE.
Questions: GitHub issues.
Related: GitHub · Kefir 1 Base · Kefir 1 SFT-15k · SFT conversations
- Downloads last month
- -

