Bonsai Pot — AI skill for Claude Code
From-scratch, dependency-light LLM inference engines for the Bonsai model family, running on wgpu compute shaders.
How to install Bonsai Pot
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open ruihe774/bonsai-pot and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Bonsai Pot does
From-scratch, dependency-light LLM inference engines for the Bonsai model family, running on wgpu compute shaders.
Alternatives in AI
- Inference Serving — ai-research-skills vLLM, SGLang, TensorRT-LLM, llama.cpp 5.4k ★
- Deepreasoning — A high-performance LLM inference API and Chat UI that integrates DeepSeek R1's CoT reasoning traces with Anthr 5.4k ★
- Vllm Mlx — High-performance OpenAI and Anthropic compatible LLM inference server for Apple Silicon 1.5k ★
README
bonsai-pot
From-scratch, dependency-light LLM inference engines for the **Bonsai** model family, running on **wgpu compute shaders**. This repository is a Cargo workspace with two independent crates, one per model generation:
| Crate | Models | Quantization | Backends | Docs |
|---|---|---|---|---|
| `bonsai-pot` | Bonsai 4B / 8B (Qwen3 architecture) | Q1_0 (binary), Q2_0 (ternary), Q8_0 | Vulkan, Metal | README · CLAUDE.md |
| `bonsai2-pot` | Ternary-Bonsai-2-27B (Qwen3.5 hybrid attention) | PTQ1_0 (1.75 bits/weight) | Vulkan | README · CLAUDE.md |
Pick the crate that matches your model; the two do not depend on each other and use different weight layouts, so a model directory produced for one is not valid for the other.
Highlights
- Weights are never dequantized. Packed weights are consumed directly by the matvec/matmul kernels, with no intermediate FP16 weight tensor.
bonsai-pot: Q1_0 is one sign bit selecting+x/-x, Q2_0 a 2-bit ternary code, and Q8_0 an i8 fed todot4I8Packed. One FP16 scale multiply closes each 128-weight block, so the inner loop has zero float multiplications per weight.bonsai2-pot: PTQ1_0 packs five base-3 trits per byte. Decode matvec unpacks trits on the fly and usesdotPacked4x8EXTagainst Q8 activations. Prefill decodes each tile once into workgroup memory and multiplies with int8 cooperative matrices (WMMA), falling back to DP4a.
- No
llama.cpp,ggmlor PyTorch on the hot path. Weights come from a flat-file layout produced from a GGUF byscripts/extract.py, every kernel is hand-rolled GLSL compiled to SPIR-V at build time, and the host side is plain Rust + wgpu. - Fast on consumer GPUs, with realistic numbers. End-to-end throughput includes stochastic sampling and encode pipelining, not just bare-forward microbenchmarks.
bonsai-poton an RX 9070: Bonsai-
Related Skills
Brainrouter
LLM routing proxy for coding harnesses. Auto-routes to cloud or local inference via Bonsai LLM classification.
Aiproxer
Connect any LLM-powered client app, such as a coding agent, to any supported inference backend/model.
Yunshu
Fast local LLM / VLM inference engine for Apple Silicon (MLX). OpenAI- and Anthropic-compatible, lossless spec
Codeimage Skill
Images drawn in code — HTML · CSS · SVG plus GPU shaders, real 3D (three.js), textures, device mockups and ske
07 Link Building Model
Compute link gap per target keyword and generate Reddit placement and outreach lists (as suggestions, not prom
Oh My Dag
The orchestration layer under your coding agent. Turns work into a typed graph, runs one model per node, and t
Related Agents
Lemonade Specialist
Lemonade Server and SDK specialist for local LLM on AMD hardware. Use PROACTIVELY for Lemonade setup, model ma
LLM Engineer
Use when designing or implementing LLM inference pipelines, prompt engineering, context management, model sele
Inference Architect
You are the system Inference Architect — a senior ML infrastructure engineer specializing in local LLM serving