UI-Mate 9B and 27B as a local computer use agent on DGX Spark
I tested Tencent's UI-Mate 9B and 27B as a local computer use agent on two DGX Sparks. Timings, vLLM flags and the trick with a parallel "reader".
This article in other languages:Polski
In this article
At the end of November I tested UI-Mate, Tencent’s new models for operating graphical interfaces, as a local computer use agent on two DGX Sparks. The 9B model with thinking turned off and a parallel “reader” finished the easy task in 44 s, which beats my earlier Qwen setup (52.6 s). On the longer task it lost its way, and only the 27B model got through it, fastest when split across both Sparks.
What did I test UI-Mate on?
For a while now I have been building a local agent tuned for low latency. The loop is simple: screenshot, one action, execute. The agent drives a real Windows laptop through PiKVM (HDMI capture plus keyboard and mouse over USB), so nothing is installed on the laptop itself.
My best result so far was Qwen3.8-27B (NVFP4 and MTP speculative decoding on vLLM), which I described in the post about a local computer use agent on DGX Spark. UI-Mate comes in two sizes: 9B, built on Qwen3.5-9B, and 27B, built on Qwen3.6-27B. I used the official agent code unchanged and wrote an adapter of about 200 lines for it (pyautogui → PiKVM HID / xdotool).
The hardware is 2× DGX Spark (GB10, 128 GB of unified memory each), linked with a 200G QSFP cable, plus vLLM nightly (0.34 dev) and PiKVM v4.
Every run was read-only. I blocked typing, Enter and keyboard shortcuts in the adapter, so the laptop only ever received clicks, scrolling and navigation keys (Esc, Tab, arrows).
There were two tasks:
- Task A (easy). Bring the work messenger to the front, open the chat list, go into the 5 most recent conversations one by one and write a 2–3 sentence note about each.
- Task B (harder). In the mail client, find the 3 newest emails from one sender. The client has several windows, so clicking it on the taskbar opens a window picker instead of switching, and a reminders pop-up gets in the way too. The main window has no preview pane, so each email has to be opened with a double-click in its own window, read, closed with Esc, and then on to the next one.
How does the “reader” trick work?
By default UI-Mate thinks before every action. That makes it accurate but slow: on 9B it came to 14–19 s per step. With thinking turned off it is fast, but it has nowhere to write down what it read, so at the end we get “task complete” and no information at all.
So I split the two roles. UI-Mate clicks with thinking off. After every click, the new screenshot also goes, in a separate background thread, to an ordinary vision request on the same server, with an instruction along the lines of “if an email or a chat is open, summarize it, otherwise answer SKIP”.
The clicking model never waits for that answer, and the notes are merged by title at the end. The “reader” made nothing up along the way: when nothing was open, it answered SKIP.
What were the timings?
| Configuration | Task A (5 chats) | Task B (3 emails, open and close) |
|---|---|---|
| Qwen3.8-27B NVFP4 + MTP, 1 Spark (my old baseline, the app was already open) | 11 steps, 52.6 s | not run |
| UI-Mate-9B, thinking on (the official default) | 9 steps, 150–237 s | not run |
| UI-Mate-9B, thinking off + “reader”, FP8, 1 Spark | 8 steps, 44 s, passed | failed: 7 scrolls, then opening the same emails over and over until the 30-step limit (212 s) |
| UI-Mate-27B, thinking off + “reader”, FP8, 1 Spark | 7 steps, 96 s, passed | 9 steps, 133 s, no mistakes |
| UI-Mate-27B, thinking off + “reader”, FP8, TP=2 across both Sparks | 8 steps, 70 s, passed | 9 steps, 76 s, no mistakes |
Model time per step looked like this:
- 9B in FP8: about 4.5–6 s,
- 27B in FP8 on one Spark: about 12–17 s,
- 27B in FP8 on two Sparks: about 6–9 s (decoding at 14.4 tok/s).
How do 9B and 27B differ in practice?
On short lists both models clicked accurately, and 9B is roughly 2× faster there. What separates them is memory of progress, meaning whether the model knows what it has already done.
The emails showed it. 9B forgot what it had already opened and fell into a loop, while 27B ran the open → Esc → next sequence without a mistake on the first try, including picking the right window from the pop-up window list.
The notes from 27B were more accurate too. In chats where 9B swapped the two speakers around, 27B attributed who said what correctly.
What limits the speed of a step?
The bottleneck is decoding speed, and image size makes no difference here: shrinking the 1920×1080 screenshot to 1280 px left the step time unchanged and cost one missed click.
The Spark is limited by memory bandwidth, so 9B in BF16 generates about 13 tok/s, and a tool call in UI-Mate’s format is about 80 tokens even with thinking off. FP8 quantization (--quantization fp8) helped, cutting a step from about 6.1 s to about 4.5 s with the same clicks.
I could not get speculative decoding to work. UI-Mate’s config mentions an MTP layer, but the checkpoint has no weights for it, so mtp mode is not available (unlike in the base Qwen).
How do you split 27B across two Sparks?
Tensor-parallel on two Sparks works today on plain vLLM, without Ray. The server flags:
--tensor-parallel-size 2 --nnodes 2 --node-rank 0|1 --master-addr <link-ip> --master-port 29511
Node 1 also gets --headless. NCCL runs over RoCE:
NCCL_SOCKET_IFNAME=<qsfp-if> NCCL_IB_HCA=rocep1s0f0
Add --device /dev/infiniband and the same model path on both machines. The whole thing comes up in about 2 minutes.
In return, 27B takes a step 1.4–1.75× faster than on one Spark, and the harder email task dropped from 133 s to 76 s.
What should you watch out for?
First, the side effects of autonomy. Even in read-only mode, 27B closed a chat window with the X button because it was in the way, and 9B closed the reminders pop-up. Just opening chats and emails also marks them as read. Let’s run an agent like this on a machine where that does no harm (I write more about the risks in the piece on AI agent security).
Second, the usual rules for working with GUI agents, because they still apply:
- One action per model response.
- A short system prompt.
- The last 3 screenshots stay in context, and older steps are summarized as text.
- A hardware KVM (PiKVM) instead of remote desktop software: a screenshot takes 0.13–0.2 s and sessions never drop.
Which configuration should you pick?
For short, simple lists of clicks I take UI-Mate-9B with thinking off and the parallel “reader”. It is the fastest variant, and faster than my Qwen setup as well.
For anything with many steps, UI-Mate-27B in tensor-parallel on two Sparks does better: it runs reliably at about 8 s per step.
Thinking mode only pays off when the agent has to reason. For plain information gathering, the “reader” is about 4× cheaper.
If we are only getting started with models on our own hardware, I described an easier way in with the guide on how to run AI locally.