Agents / Advanced

Run Bonsai 2 as a Hermes agent

Follow PrismML’s published Bonsai 2 and Hermes demo: install the supported runtime, launch its agent-profile server, run a browser-verified coding task, and inspect the output.

Verified sourceSource checked 9/24/2026
LOCALRENTED GPU

Before you begin

Difficulty
Advanced
Software
PrismML Bonsai Demo, Hermes, git, uv, Node.js 24+
Hardware
The publisher recorded this agent run on a single H200 GPU with a 131K context. Agent context and browser tools need more headroom than the short-chat guide. Mac and other GPU paths are documented, but their agent speed and memory fit are not measured here.
LOCAL AGENT / MAC · LINUX · RENTED GPUSOURCE-LINKED SETUP

Bonsai 2 and Hermes, from install to inspected output.

Run the publisher’s complete Hermes example with the official PQ2_0 package. This agent writes files and uses a headless browser; inspect its output and logs before adapting the demo to your own task.

Choose a package Run its commands Check the result
01
BEFORE YOU BEGIN

The documented package

This setup uses the package documented for this task. Review its source and supported platforms before starting.

The publisher has not provided a complete memory target for this task. Check its hardware guidance before starting.

CURRENT SETUP

Bonsai 2 PQ2_0 · official

The publisher’s recorded run used an H200 at 131K context. No device-specific memory or speed rating is claimed for this agent setup.

View weight source
02
THE WORKFLOW

Set up Bonsai 2 PQ2_0 on your machine

Pick your operating system and GPU path. Every command below is for the selected package and runtime.

The publisher documents this shell-script route. Large agent context can need substantially more unified memory than ordinary short chat and may be slow.

01

Clone the supported runtime

Use the PrismML demo repository and its matching llama.cpp fork, not a stock Ollama or llama.cpp install.

git clone https://github.com/PrismML-Eng/Bonsai-demo.git cd Bonsai-demo
02

Install Bonsai 2 and its runtime

The publisher setup selects binaries for your Mac and downloads the official Bonsai 2 PQ2_0 package plus projector.

./setup.sh
03

Install the publisher agent demo

From the cloned Bonsai-demo folder, run its installer. It pins Hermes and installs the headless browser used by the official demo. You also need git, uv, and Node.js 24 or newer.

./scripts/agent/install_hermes.sh
04

Start the agent-profile model server

Keep this terminal open. The publisher agent profile uses the official PQ2_0 weights, tool calling, a large context, and a fixed seed.

./scripts/start_agent_server.sh
05

Run the publisher’s first agent task

In a second terminal in the same Bonsai-demo folder, run the documented first round. Hermes creates a single-file skateboard game, checks it in a browser, and saves the workspace and logs.

./scripts/agent/run_agent_demo.sh round0
06

Inspect the result and log

Open agent-runs/<run name>/workspace/skateboard.html and the matching stdout.log. The generated game should load and respond to its controls. Review files and commands before adapting this demo to your own task.

03
SUCCESS CHECK · Bonsai 2 PQ2_0

Inspect the generated game

The runner writes a skateboard.html file under agent-runs and the file plays in a browser. Read the run log to confirm the model completed its browser check and inspect the generated code.

The Hermes demo runs with --yolo: model-selected commands execute as your user without confirmation. The run workspace separates files but is not a security sandbox. Use a machine or rented instance where that level of access is acceptable. This source-backed guide does not claim a Windows Hermes route or an uncensored Hermes package.

Back to setup steps

When it doesn’t go to plan

The agent cannot connect to the model server

Start ./scripts/start_agent_server.sh in a separate terminal and keep it running before launching the Hermes task. Check that the server loaded the official PQ2_0 model.

The browser tool or installer fails

Check git, uv, and Node.js 24 or newer, then rerun the publisher installer. Inspect the agent-runs log and the publisher walkthrough for the pinned browser-tool version.

The Mac or GPU runs out of memory during the task

The agent profile uses much more context than short chat. Reduce the context and task size using the publisher settings, or use a rented GPU with more memory; do not rely on the chat memory table for this run.

REFERENCE LIBRARY

Sources and files

Original instructions, model files, and compatibility notes behind this setup.

4 SOURCES

The model behind this workflow

Bonsai 2 · 27B
MY HARDWARE

Will it run on your machine?

Save your machine to see a personalized rating and its reasoning.

Add my hardware

Keep exploring