earakely-scale's picture
REA computer-use environment, v0.1.0
39a4490 verified
|
Raw History Blame Contribute Delete
6.46 kB
metadata
license: apache-2.0
pretty_name: MyPaint computer-use environment from a one-line request (REA)
tags:
  - computer-use
  - cua
  - gui-agent
  - rl-environment
  - agentenv
  - desktop
  - linux
  - rea
  - painting
  - raster-graphics
  - openraster
  - from-request

MyPaint: a computer-use environment built from a one-line request

An agent solving the task in MyPaint

The real MyPaint 2.0 painting app running on an Ubuntu 24.04 desktop, as an agentenv computer environment. An agent completes the task only through screenshots, mouse and keyboard, and a verifier grades the saved files with no model.

Claude Code built this environment from a one-line request in about 28 minutes, with only REA's build skill and MCP tools; How it was made has the request and the steps. MyPaint opens a small drawing, Documents/sunny-day.ora, at launch, with its Layers panel closed: three layers, Night Sky, Sketch and Ground, over a background. The agent has to rename the Sketch layer to Crescent Moon and save. It sees only the screen and acts only with the mouse and keyboard.

Watch

  • Agent runs (Claude Code with Claude Sonnet 5.5): run 1, run 2, run 3
  • Witness, which proves the task can be done through the computer: witness.mp4

Each video is the computer's own screen recording at 10 frames per second.

The task

In my drawing Documents/sunny-day.ora, rename the layer called Sketch to Crescent Moon and save it.

bundle/artifacts/rename-sketch-layer-check/verify.py reads the app's files through the computer's data/get view and passes only if every check holds:

Check Kind File
renamed value_equals Documents/sunny-day.ora
sketch-gone value_absent Documents/sunny-day.ora
ground-kept value_equals Documents/sunny-day.ora
night-sky-kept value_equals Documents/sunny-day.ora
layer-count member_count Documents/sunny-day.ora

An .ora file (OpenRaster) is a zip, and REA reads stack.xml inside it, which lists the layers. The checks find layers by their name: a layer named Crescent Moon must exist and none named Sketch, Ground and Night Sky must keep their names, and the drawing must still have four layers, counting the background. REA's draft paired the renamed layer correctly but keyed it by its image file name, which MyPaint rewrites by stack position on every save; Claude Code found it by its new name instead and added the layer count.

Results

3 of 3 runs passed, about $0.68 per run.

Run Outcome Turns Cost Video
1 passed 14 $0.60 video
2 passed 14 $0.85 video
3 passed 14 $0.60 video

Run it

You need Docker. agentenv-framework builds the computer: Ubuntu 24.04 with the app installed from Ubuntu's archive (mypaint 2.0.1, with librsvg2-common).

pip install agentenv-framework==0.9.1431
hf download earakely-scale/MyPaintFromRequestComputerEnv-REA --repo-type dataset --local-dir mypaint-request
agent-env run mypaint-request/bundle --task rename-sketch-layer --agent claude-code --model <model>

The agent needs a model provider configured for agentenv. --task smoke only boots the computer, with no agent. bundle/README.md describes the bundle in detail.

How it was made

Claude Code built this environment from a one-line request, given only REA's build skill and REA's MCP tools:

Build me a MyPaint environment where the agent renames a layer in a small drawing and saves it.

It asked only the skill's upfront questions, wrote no app-specific scripts, and finished in about 28 minutes.

MyPaint crashed on brush strokes during the build, which cost about 7.5 minutes, so Claude Code made the seed drawing with the flood fill tool. The steps were REA's usual ones:

  1. Capture. REA launched MyPaint on a Linux desktop and recorded its package, windows and opened files while the edit was made. It also recorded the app's state folders before and after.
  2. Export. REA turned the capture into an agentenv computer_app. It installs the app, seeds the starting files, starts the app, and waits for its main window. It also serves typed views of the app's files for verifiers.
  3. Task. The task's checks were validated against the capture: they fail on the starting state and pass on the captured end state.
  4. Witness. In a fresh computer, the layer was renamed through computer actions alone, and the checks were read at four stages. They held on the first try:
Stage Checks
seed fail, as expected: the layer is still named Sketch; the kept-layer checks pass
after_edit pass
near_miss fail, as expected: the layer was renamed "Cresent Moon"
after_reset fail, as expected: data/reset restored the seed

The agent runs came after the build: Claude Code with Claude Sonnet 5.5 (--model anthropic/claude-sonnet-5-5 --no-emulate, on an amd64 host) solved the task 3 times, each run recorded.

What's inside

bundle/      the agentenv bundle: envs/ (app module, seed files), tasks/, artifacts/ (verifier), evals/
media/       witness and agent-run recordings (MP4) with short GIF previews
results.json the runs above, with each check's result

Limits

  • MyPaint 2.0.1 crashes on brush strokes in this computer: an agent that paints on the canvas will crash the app. Renaming a layer needs no painting, and none of the three runs painted.
  • The checks read layer names only, not pixels: deleting Sketch and adding a new layer named Crescent Moon passes too.
  • The bundle installs librsvg2-common, the SVG image loader MyPaint's icons need, beside the app as an extra package.
  • The computer installs whatever mypaint Ubuntu 24.04's archive holds at build time (2.0.1 for these runs); it is not pinned.
  • Three runs is a small sample: the solve rate shows the task is solvable, not how hard it is.

Licences

The bundle code, the task and the synthetic seed files are Apache-2.0. MyPaint itself is not included: the computer installs it from Ubuntu's archive (mypaint 2.0.1, with librsvg2-common) at build time, under its own licence (GPL-2.0-or-later).