Back to all writing

Field notes

Hayate's WebUI Also Drives PI Agents

Hayate's WebUI is a dashboard that belongs to no agent. This is how it shows Hayate and PI agents from different machines in one window, and where it is heading.

Hayate's WebUI Also Drives PI Agents

窓ひとつ
はやてとパイの
冬の朝

One window.
Hayate and PI
on a winter morning.

This morning the agents panel in my browser window said 2 running. Hayate agents and PI agents were listed side by side, on different machines, and I could follow all of them from a single tab.

I open this window every day. It is where I see what the agents are doing and where I step in when one of them needs steering. We build it ourselves, and this post is a look at how it is put together and where it goes next.

Cover in the Hayate style on an indigo-black background with a faint wave pattern: small slate logo 疾風 and Hayate Agent at the top, the red Japanese headline HayateのWebUIでPIエージェントも動かせる in two lines, below it the white English headline Hayate's WebUI Also Drives PI Agents, and github.com/hayate-agent at the bottom.

Here is the window during a working session. The conversation in the middle is called WebUI Development. On the right, the agents panel lists what runs at the moment and what finished before, and one of the finished runs is a rework of that very panel.

Screenshot of the Hayate WebUI: a running task with its tool calls in the middle, a steer control and the message field labelled PI and Hayate, and on the right an agents panel with two running entries and a list of finished runs. Previews of other conversations are blurred.

Too Many Places to Look

Every agent wants to show you something. A Hayate agent can serve a page of its own. PI, by default, has only a terminal UI, so a PI session lives in the terminal of the machine it runs on.

Run several agents on several machines like that and you end up with one window per agent and no overview. If one of the agents serves the dashboard, that agent becomes the owner and every other agent is a guest.

We wanted a window that belongs to none of them.

One Window, No Owner

The Hayate WebUI is a separate project for exactly that reason. Its README is blunt about it: no core imports, no agent runtime, no project store, no vault and no model execution live inside it1.

Illustration of six separate workstations, each linked by a red cable to one large glowing window.

Every agent keeps its own identity, history and credentials. The dashboard asks for them through the agent's API and stores none of them. That is why the window can show a Hayate agent in the morning and a PI agent a minute later without caring which one it met first.

What an Agent Brings

It brings little. On the Hayate side it is a plugin. The dashboard API gateway turns the conversations of an agent into HTTP and server-sent events, and its README lists what it does not contain: no HTML, no CSS, no browser JavaScript2. Pairing goes through AgentLink and AgentHub, with expiring codes, scoped access and revocation3.

The WebUI itself is small as well. The server that delivers it is a Node process of 187 lines in three files. It checks Host and Origin and forwards /api/* and nothing else1. The example compose file runs the container read-only with every Linux capability dropped1.

The Agent Calls the Dashboard

Not every machine can be reached from outside, and none of them should have to open a port for a dashboard. So the agent calls the dashboard, not the other way around.

Illustration of a computer inside a brick-walled room with a red cable running out through a hole in the wall to a glowing window.

In the central dashboard I create an invitation. The code works once and expires after five minutes. I enter it on the target machine, and the agent opens a single WebSocket to the dashboard's normal HTTPS address. Nothing is registered at that point. The connection shows up as an incoming one, I look at the identity and the capabilities it asks for, and only then I approve it4.

If the line drops, the agent reconnects with a bounded backoff. A request that was in flight is never replayed behind my back, and its outcome shows as unknown until I decide what to do with it4. For a window that sends real work to real machines, I would rather click twice than run something twice.

PI Takes the Same Door

A PI host gets a thin adapter inside the PI process and a small user service. It pairs with the same kind of invitation, uses the same outbound WebSocket and appears in the dashboard as "PI · host name". From there I can create sessions, send messages, steer a running one or stop it, as with a Hayate agent5. The documentation says the central backend needs no API changes for this5.

Illustration of two desks, a plain terminal on one and a graphical screen on the other, both connected to one glowing window above them.

In daily use the two behave alike, but not identically. Here is a PI conversation with an everyday request, checking the free disk space of a machine. The message field carries the label PI · Hayate.

Screenshot of the Hayate WebUI: conversation list on the left with some entries blurred, a running disk-space task in the middle with a steer control and the label PI · Hayate in the message field, and a pane on the right listing one running agent and its tool calls.

Many Runs at Once

Agents work in parallel, and so do their sub-agents, so the panel has to keep track. Every run gets a card with its state, a task summary where there is one, and its latest tool calls, with the rest behind a show-all link. Finished runs move into a list below.

The details of a run open in a window of their own. This is the one for the current turn: 17 of 19 steps done, each step with its own status, and the failed ones sit right next to the successful ones.

Screenshot of the Hayate WebUI with a Run details window open over the chat: the steps of the current turn with their status, 17 of 19 done, a few failed, and the agents panel on the right. Previews of other conversations are blurred.

This view is still young. In the next rounds it gets a detailed view of single tool calls.

A Dashboard for One Agent

The central window is not the only way to look at an agent. The same WebUI can be started against the API of a single agent, and then it is the dashboard of that agent and nobody else's6.

An agent can also build one inside a conversation. It writes a block in OpenUI Lang, and the WebUI renders live cards, figures and tables above the chat and refreshes their data on a timer without asking the model again. Reads run on their own. Anything that writes needs my confirmation every single time, unless I switch that off deliberately7.

It Keeps Growing

The screenshot with the disk-space request carries the footer 0.2.26+307, the two newer ones 0.2.26+310. The number after the plus counts commits8, so the window moved by three commits between those screenshots.

Illustration of a glowing central window with small square modules growing outward in all directions, newer ones red.

Around the window, other pieces grow as well. A bridge extension for Chromium and Firefox was pushed to GitHub on 2026-12-019. Agent swarms exist in the Hayate Agent, switched off by default, and a swarm only starts after an admin answers the proposal of the planner with /swarm <executionId> <vN> ja10. Decision models can act as the independent check that decides whether an order is complete11.

The view of single tool calls comes next. It will arrive in a window that does not care which agent it belongs to.

Sources used