---
title: "Computer use"
url: https://www.daytona.com/compute-glossary/agents/computer-use
---

# Computer use

Part of the [Compute Glossary](https://www.daytona.com/compute-glossary.md), section [Agents](https://www.daytona.com/compute-glossary/agents.md).

Also called Computer-use agent, GUI agent.

Computer use is the operation of a graphical desktop by an [AI agent](https://www.daytona.com/compute-glossary/agents/agent.md), which sees the screen and acts on it as a person would. The agent receives a screenshot and replies with an action, such as a click at a point or a line of typed text. It works through buttons and menus rather than through files and commands. Any program with a graphical interface can therefore be driven, even one that offers no other way in.

Computer use exists because much software can only be reached through its screen. Older business applications and websites with no public interface are common examples. Writing an integration for each one is slow, and some vendors do not allow it. A model that reads screens can use such software the way its human users do, at the cost of speed and reliability.

The desktop the agent drives usually runs inside a sandbox, not on the computer of a person. The sandbox then needs a full desktop, from a display server up to the applications the task needs. Such a sandbox uses more memory than one that only runs commands. Each step also sends an image to the model, which takes more time and more tokens than a line of text. The sandbox separates the agent from real accounts and files not exposed to it, and can be deleted once the task ends.

## Action loop

The action loop is the cycle in which a computer-use agent looks at the screen and then acts on it. Each turn, the host program takes a screenshot and sends it to the model with the goal and the history so far. The model replies with a [tool call](https://www.daytona.com/compute-glossary/agents/tool-call.md) that names one action, such as a click or a key press. The host program performs the action on the desktop and then takes the next screenshot. The loop ends when the model reports that the task is done or a step limit is reached.

Actions point at the screen by pixel coordinates, so the model has to find each target in the image. Screenshots are often scaled down before they reach the model, and the host program scales the coordinates back up. A small error in a coordinate can hit the wrong button, which only the next screenshot reveals. Some agents also read the accessibility tree of the desktop, which names each element on screen and gives its position.

## Virtual desktop

A virtual desktop is a graphical desktop that runs on a machine with no monitor attached. A virtual framebuffer stands in for the screen, holding the image of the desktop in memory. Xvfb is a common choice, an X11 display server that draws into memory instead of onto a monitor. A window manager places the windows, and the applications run on top as they would on any desktop.

Input reaches the desktop as synthetic events, injected into the display server as if they came from a real mouse or keyboard. Tools such as xdotool send these events on X11. Applications cannot easily tell them from real input, so they behave as they would for a person. Many setups keep the screen small, around 1024 by 768 pixels, so that each screenshot stays cheap to send and easy to read.

## Screen streaming

Screen streaming is the sending of a live view of the desktop to a person while the agent works. VNC is the usual protocol for it, with a VNC server that reads the framebuffer and sends the parts that changed to a viewer. noVNC is a viewer that runs in a web browser and connects over WebSockets, so no separate program has to be installed. The stream is separate from the screenshots the model sees, and the server sends nothing when no viewer is connected.

A live view lets a person follow each step and stop the agent when it goes wrong. VNC also carries input the other way, so the person can take over the mouse and keyboard. That handover suits steps an agent should not take alone, such as logins or payments. Once the person is done, control goes back to the agent, which continues from the new screen.

## Security

Security for computer use is the problem of an agent acting with whatever access the desktop gives it. Anything on the screen reaches the model as input, including text that others placed there. A web page can carry a prompt injection, text that tells the model to do something its user never asked for. The agent can click anything a person could, so it can submit a form or delete data by mistake.

Running the desktop in a sandbox limits the damage to that sandbox and the accounts it is logged into. [Egress control](https://www.daytona.com/compute-glossary/networking/egress-control.md) keeps the browser away from sites the task does not need. Logins on the desktop usually get only the access the task needs, since the model sees anything typed or shown on screen. A [snapshot](https://www.daytona.com/compute-glossary/sandboxes/snapshot.md) of a desktop that is already logged in lets each task start from the same state without typing secrets at all.

## Use cases

Computer use lets an agent reach software that only a screen exposes.

- **Legacy applications.** Older business applications are often reachable only through their screens. A computer-use agent drives them the way their human users do, with no integration to write.

- **Web tasks.** Websites with no public interface can still be used through a browser on the desktop. Egress control keeps that browser away from sites the task does not need.

- **Supervised work.** A person follows the desktop through a VNC viewer while the agent works. The person can take over the mouse and keyboard for steps such as logins or payments.

- **Repeatable starts.** A snapshot of a desktop that is already logged in lets each task start from the same state. No secrets then need to be typed on screen, where the model would see them.

## Related terms

- [AI agent](https://www.daytona.com/compute-glossary/agents/agent.md)
- [Tool call](https://www.daytona.com/compute-glossary/agents/tool-call.md)
- [Sandbox](https://www.daytona.com/compute-glossary/sandboxes/sandbox.md)
- [Egress control](https://www.daytona.com/compute-glossary/networking/egress-control.md)
- [Snapshot](https://www.daytona.com/compute-glossary/sandboxes/snapshot.md)
