Bonsai-demo: Chat with a 27B model on a laptop, compressed to under 6 GB
Added · Updated
Made by PrismML-Eng
View profile on GitHub (opens in a new tab)Bonsai Demo is the official runner for PrismML's Bonsai family of heavily compressed language models, letting you run a 27-billion-parameter class model on a Mac, a single GPU, or plain CPU.
Its default model, Bonsai 2 27B, is compressed to ternary weights (each stored as one of just three values) at 5.9 gigabytes, and the creator reports it keeps 98.2% of the accuracy a full-precision version would have. Two setup commands download the right build for your machine and start a local chat server with vision (it can read photos, screenshots and PDFs), tool calling, and an adjustable reasoning effort.
What it does
The setup script detects your hardware (Metal on Mac, CUDA, Vulkan or ROCm elsewhere, or plain CPU) and downloads the matching packing of the compressed model plus a PrismML fork of llama.cpp built specifically to run these ternary-weight files, since stock llama.cpp cannot read them. Once running, the demo's web and command-line interfaces expose vision input, native tool calling with full round-trips, MCP server support, and a 262,000-token context window kept practical on ordinary hardware through a hybrid-attention design.
You could use it to…
- Chat with a 27B-class model on a laptop, under 6GB
- Show it a screenshot or PDF and ask about it
- Turn tool calling on with full round-trips, on-device
Can I use this?
You'll need A Mac, GPU, or capable CPU, and disk space for the model · Setup needed
Worth knowing The near-full-precision accuracy figures and benchmark comparisons are the creator's own reported numbers, and this demo requires the project's own modified llama.cpp build rather than a stock installation. Apache-2.0 licence.
Why it's here
Not trending this week
Last seen on the GitHub trending list on 25 September 2026. It stays on BuildTube so you can still find it.
- 3,495 people have starred it on GitHub.
Numbers checked on 8 November 2026; not refreshed since.
Behind it
View setup guideBuildTube has not run or verified this project. Everything above is written from what the creator published.
Made this?
Quick questions
- What is Bonsai-demo?
- The setup script detects your hardware (Metal on Mac, CUDA, Vulkan or ROCm elsewhere, or plain CPU) and downloads the matching packing of the compressed model plus a PrismML fork of llama.cpp built specifically to run these ternary-weight files, since stock llama.cpp cannot read them.
- What can I use Bonsai-demo for?
- Chat with a 27B-class model on a laptop, under 6GB; Show it a screenshot or PDF and ask about it; Turn tool calling on with full round-trips, on-device
- Can I run Bonsai-demo on my computer?
- It runs from a terminal on your own computer. A Mac, GPU, or capable CPU, and disk space for the model.
- What do I need to use Bonsai-demo?
- A Mac (Metal), a Windows/Linux machine with a CUDA, Vulkan or ROCm GPU, or a capable CPU, plus about 6 to 7 gigabytes of free disk space for the model file.
- What license does Bonsai-demo use?
- Apache-2.0 licence.
More from this week
- kimi-k3-in-c Run a 2.78-trillion-parameter model on 8 GB of RAM
Get text answers from the huge Kimi K3 AI model using one CPU and no graphics card.
- agent-desktop Let AI agents read and click desktop apps
For developers building computer-use agents: agent-desktop lets an AI agent read and operate desktop apps on Mac, Windows or Linux from a command line.
- Auto-Ontology Give AI agents checked business meanings for your database
Help AI agents answer questions about company databases using reviewed definitions and SQL, with each answer showing its steps.
Explore by topic
Post this
Download share imageFor makers
Made this? Show it’s on BuildTube — add the badge to your README or embed the card on your site.
README badge (Markdown)
[](https://buildtube.app/p/gh-prismml-eng-bonsai-demo/)Embed card (HTML)
<iframe src="https://buildtube.app/embed/gh-prismml-eng-bonsai-demo/" width="560" height="240" style="border:0;max-width:100%" loading="lazy" title="Bonsai-demo on BuildTube"></iframe>