GitHub - Vladislav-Kalinkin/ullis: Ullis Engine — reasoning ternary KAN in Rust · GitHub
/" data-turbo-transient="true" />
Skip to content
Search/
Sign in<br>Sign upAppearance settings
You signed in with another tab or window. Reload to refresh your session.<br>You signed out in another tab or window. Reload to refresh your session.<br>You switched accounts on another tab or window. Reload to refresh your session.
Dismiss alert
{{ message }}
Vladislav-Kalinkin
ullis
Public
Notifications<br>You must be signed in to change notification settings
Fork
Star
main
BranchesTags
Go to file
CodeOpen more actions menu
Latest commit
History<br>4 Commits<br>4 Commits
Folders and files<br>NameNameLast commit message<br>Last commit date<br>.cargo
.cargo
assets
assets
checkpoints
checkpoints
data
data
src
src
tests
tests
.gitignore
.gitignore
Cargo.lock
Cargo.lock
Cargo.toml
Cargo.toml
DESIGN.md
DESIGN.md
LICENSE
LICENSE
README.md
README.md
View all files
Repository files navigation
Ullis
Standalone ternary Mixture-of-Bumps Kolmogorov–Arnold engine.<br>Zero Python at runtime. One binary: train, chat, smoke.
tokens → embed → L × (causal mixer + TernaryKanLinear) → RMSNorm → tied logits
Thinking is no longer silent. The REPL streams the hidden trajectory in<br>dim italic gray, prints └──, then streams the output block in bold green.<br>Ephemeral GC (ReasoningScratch::clear) wipes the think ring the instant<br>the output stream ends.
Absolute 8 GB Mac M1 benchmarks
Surface<br>Number<br>Notes
Pre-training throughput<br>~7500 tok/s<br>4-phase ternary QAT, Metal, defaults d=32 L=3 G=4→12 T=96 B=4
Deep inference RSS
xhigh resonance included; think scratch is ephemeral
Unified memory<br>8 GB M1<br>SGD (no Adam states); JSONL I/O independent of corpus size
Working set is designed to stay flat : dialogue cache never stores<br>thinking tokens, the token ring is capped at 32 768 ids (~128 KB),<br>and Gauss–Jordan grid projection stays on Metal (G ≤ 12).
Quick start
cargo build --release<br>./target/release/ullis train --data data/thinking-train.jsonl --steps 200 --out checkpoints/<br>./target/release/ullis chat --model checkpoints/packed.bin --thinking medium<br>./target/release/ullis chat --model checkpoints/packed.bin --thinking xhigh --prompt "fn add("<br>./target/release/ullis smoke
--thinking low|medium|high|xhigh sets the KAN eval budget. low masks<br>routed (thinking) weights and emits output immediately. xhigh runs three<br>residual KAN loops per block on the G=12 MoE stack, streamed live.
Data — strict 4-key JSONL
Every training line is exactly:
{ "system": "...", "user": "...", "thinking": "...", "output": "..." }
Packed as:
… … … …"> … … … …
Loss is masked onto thinking + output so the KAN layer learns the<br>logical chain (bracket matching, import tracking, lifetime ownership,<br>pipeline quoting). A verified sample corpus lives at<br>data/thinking-train.jsonl (Rust, Python, Bash).
Legacy {"text","lang"} lines are still lifted in-stream.
Visual reasoning UI
Lane<br>ANSI<br>Marker
thinking<br>\x1b[2;3m dim + italic<br>[Ullis is thinking...]
close<br>reset<br>└──
output<br>\x1b[1;32m bold green<br>code stream
Colors honor NO_COLOR and non-TTY stdout. Persistent dialogue keeps only<br>system / user / output.
Crate map
Module<br>Role
quant<br>TWN threshold, STE, 2-bit pack/unpack
gauss<br>G×G Gauss–Jordan (matmul / broadcast / cat, Metal-safe)
kan<br>TernaryKanLinear + ReLU-bump basis + MoB router
mixers<br>CausalShift (0 params) / tiny causal attention
model<br>UllisKan: embed → L × (shift + KAN) → RMSNorm → tied logits
tokenizer<br>Byte-level BPE, vocab 4096, code-seeded merges
data<br>4-key JSONL, VecDeque token ring
think<br>budgets, ephemeral GC, dialogue cache
train<br>4-phase QAT, G = 4→8→12 projection, masked CE
checkpoint<br>packed.bin (magic ULLIS03)
chat<br>ANSI token streamer
telemetry<br>RSS / tok/s / ternary histogram
Design matrix: DESIGN.md.
License — MIT
Ullis is open-source software licensed under the MIT License . See LICENSE.
About<br>Ullis Engine — reasoning ternary KAN in Rust<br>Topics<br>ai-enginekanrust<br>Resources<br>Readme<br>MIT license<br>Activity<br>Stars<br>0 stars<br>Watchers<br>0 watching<br>Forks<br>0 forks<br>Report repository
Releases
Packages
Contributors
Languages
You can’t perform that action at this time.