Learning by trying, with only a pass or a fail.
We took a small model that can already see a screen and talk about it, gave it simple web pages to operate, and let it practice. Nobody showed it the right clicks. It only learned whether each attempt worked.
Think of learning a new video game without a guide. You try something. Sometimes the level ends, sometimes it doesn't. After enough tries you start repeating whatever you did on the attempts that worked. That's reinforcement learning (RL) in one paragraph.
What makes it work for a language model is that the model isn't starting from zero. It already reads text, understands screenshots, and can describe a button. It just isn't reliable at finishing a task on a web page. Practice with a pass or fail score makes the behaviors that finish tasks more likely, and the ones that don't, less likely.
Four words you'll see everywhere
- Model
The thing we train. Here, a 4-billion-parameter model that reads images and text, called Qwen3-VL-4B. RL papers also call it the policy, because it decides what to do next.
- Task
One small web page with an instruction, such as “Select Ertha from the list and click Submit.” Each task has endless random variations, called seeds.
- Episode
One attempt at one variation of a task: look, act, look again, act again, up to eight turns, until the page says done or time runs out.
- Reward
The score for an episode: 1 if the task was completed, 0 if not. That's the only feedback the model gets.
What we wanted to see
A visible gain in one day of training on one rented GPU. Not a state-of-the-art agent, but a clear before-and-after you can measure, plus an understanding of every moving part.
The rest of this notebook explains where those numbers come from, and what they do and don't mean.
A student, a gym, and a rented GPU.
Three pieces: a model to train, a set of practice web pages that grade themselves, and a machine fast enough to run both at once.
- The student
Qwen3-VL-4B-Instruct. Open weights, sees images, follows instructions, and already knows how to call tools. Four billion parameters is small enough to train on one GPU in hours.
- The gym
MiniWoB++, a collection of about 100 tiny web pages built for training agents. Each one checks itself, so success is automatic and can't be argued with. It runs in a real headless Chrome through a library called BrowserGym.
- The machine
One NVIDIA H100 for run 1 and one A100 for run 2, rented by the hour on Runpod. Each run took about half a day, start to finish.
What the model sees and does
Each turn, the model gets the instruction, a screenshot, and a short list of the page's elements, each with an ID number. It answers with a sentence of reasoning and one action, written as a tool call:
The combobox is set to "Ertha," which matches the goal.
Next, click Submit.
<tool_call>
{"name": "click", "arguments": {"bid": "19"}}
</tool_call>
The available actions are click, fill (type into a box), press (a key like Enter or Control+C), select, and scroll. The page then updates, and the model gets a fresh screenshot.
coordinate: [x, y], which is how real computer-use agents work on any screen. Track B works end to end but hasn't been trained yet. It's the obvious next step.
Scoring an episode
The reward is mostly the page's own pass or fail. Two small additions shape behavior without overpowering it:
- A tiny bonus for finishing in fewer turns, so the model doesn't wander.
- A small penalty for answers the program can't read as an action.
Try eight times, learn from the difference.
The training method is called GRPO (Group Relative Policy Optimization). The name is heavy; the idea is light. Give the model the same task eight times and compare the attempts with each other.
One training step
- Pick a handful of tasks, and one fresh variation of each.
- Let the model attempt each one 8 times with a bit of randomness, so the attempts differ. These 8 attempts are a group.
- Score every attempt: pass or fail.
- Compare each attempt with its group's average. Better than average gets a positive score, called the advantage. Worse gets a negative one.
- Nudge the model's weights so the words and actions from above-average attempts become a bit more likely, and the others a bit less.
Repeat for a few hours. Because every attempt is judged against its siblings on the same page, no separate “judge” model is needed, which is what makes GRPO cheap.
The catch: a group must disagree
If all 8 attempts pass, every one equals the average, so every advantage is zero and nothing is learned. Same if all 8 fail. Only a mixed group teaches anything. Try it:
The chance that a group is mixed is 1 − p⁸ − (1 − p)⁸, where p is the success rate. It's 99% for a task the model solves half the time, but only 15% at 98%, and 34% at 5%. Tasks that are too easy or too hard waste the step. This one fact shaped most of our decisions.
Three helpers
- LoRA
Instead of changing all 4 billion numbers in the model, we train a small add-on layer of extra weights and leave the original frozen. It's cheaper, fits in memory, and the result is a small file you load on top of the base model, called an adapter.
- vLLM
A fast text-generation engine. It writes the model's answers during practice while the trainer shares the same GPU. After each step, the new weights are copied into it.
- Warm start
Before GRPO, we ran a quick round of rejection-sampling fine-tuning (RFT): let the base model try many tasks, keep only the attempts that passed, and train on those like worked examples. It mostly taught the model to answer in the right format every time.
Practice what's almost within reach.
Because only mixed groups teach, choosing tasks matters more than any setting in the trainer. We measured the model first and then picked.
The screening test
We let the untrained model attempt 40 candidate tasks 16 times each, with randomness on. Tasks it nearly always solved, or never solved, were dropped. The rest sat in the useful band, roughly 5% to 85%, where groups are often mixed.
Ten tasks made the run 1 practice set, things like picking a date in a calendar widget, finding an email and replying, and scrolling a list to find an item.
Two kinds of exam
- Practice set
The tasks we trained on, scored on new variations. Training and testing seeds never overlap, so the model can't memorize answers.
- Held-out set
Tasks the model never practiced. This answers the harder question: did it learn something general about web pages, or just these ten tasks?
For scoring, the model runs without randomness (always its single most likely answer), 50 variations per task. That's 500 episodes on the practice set, which makes a few points of change meaningful.
The starting line
The base model is decent, which helps: RL can only reinforce things the model sometimes already does.
Twenty-seven to fifty-eight, and two surprises.
Run 1 was the plan as written: a warm start, then 158 GRPO steps over about five hours on one H100. It roughly doubled the success rate on the practice tasks.
What it learned
- enter-date went from 0% to 98%. The warm start had no successful examples to copy, so this came purely from GRPO.
- enter-time went from 36% to 94%, but almost all of that came from the warm start, before GRPO began.
- Held-out tasks rose from 55.6% to 62.8%. A real gain, driven by a login popup task (+18 points) and an email-forwarding task (+10).
Surprise one: most practice taught nothing
On average, 78% of groups were all-pass or all-fail. Each step rolled out 64 attempts but learned from about 14. Twenty of the 158 steps learned from nothing at all. Tasks the model mastered early kept taking their turn anyway.
Surprise two: it forgot things
Later we tested run 1 on a different set of 16 tasks it never trained on. It scored worse than the untouched model: 37.8% against 46.6%.
Fewer steps, more signal.
Run 2 started from run 1's adapter and changed how practice time was spent, not the method. It ran only 52 steps, yet learned from more attempts than run 1 did in 158.
What changed
- New tasks
Re-screened 62 candidates with the run 1 model, since that's the model being trained now. Kept 16 in the useful band, including tasks run 1 had forgotten.
- Smart picking
Instead of taking turns, each task is picked in proportion to its chance of producing a mixed group. Mastered tasks still show up now and then, so forgetting is noticed.
- Keep the useful
Roll out extra groups, throw away the all-pass and all-fail ones, and train only on mixed groups. This trick comes from a paper called DAPO and is called dynamic sampling.
- Lighter training
Compute the expensive scoring step only on the model's own words, not on the whole page description. Same result, far less memory.
- Fairer tests
Twice as many held-out tasks, 100 variations each, every model tested on identical variations, and a confidence range on every difference.
Results
- Run 2's practice set: 37.8% to 72.6%, a gain of 34.9 points (95% range: 32.1 to 37.6). It also beats the untouched model by 26 points, so the forgetting was repaired and then some.
- Run 1's old tasks: 57.8% to 61.6%. Nothing was lost, and two tasks improved.
- Held-out tasks: 66.6% to 67.3%. The range, −1.0 to +2.3, includes zero, so this is no real change.
Task by task
One episode, before and after
The task: copy the text from one box into another and submit. Same variation for both.
Run 1 · fail · 2 actions
Run 2 · pass · 5 actionsRun 1 said it would copy the text, then skipped straight to typing it out and missed the trailing space. Run 2 clicked the box, pressed Control+A and Control+C, then entered the exact string, space included. On this task run 2 went from 10% to 100%.
What two runs taught us.
Some lessons are about RL, some are about measuring, and a surprising number are about plumbing.
About training
- Signal, not steps
Run 1 learned from about 2,250 attempts in 158 steps. Run 2 learned from about 2,500 in 52. Counting steps tells you little; counting mixed groups tells you a lot.
- Re-pick tasks
A task's difficulty depends on the model. After one run, the useful band moves, so screen again with the current model.
- Watch the rest
RL on a narrow set can erase skills elsewhere. Keeping a little practice on mastered tasks, and testing tasks outside the set, catches it.
- Narrow wins
Gains on practiced tasks were large (+30 points and more). Gains on never-seen tasks were small (+7 in run 1, about +1 in run 2). Ten or sixteen tasks make a specialist, not a general web agent.
- Warm start helps
RFT alone moved the practice score from 27% to 32% and fixed answer formatting. Cheap and worth doing first.
About measuring
- Small tests lie
Mid-run checks on 10 variations per task jumped around by several points. Use 50 to 100, and compare models on the exact same variations.
- Show the range
A difference without a confidence range invites wishful reading. Run 2's held-out “gain” of 0.7 points looked nice until the range crossed zero.
About plumbing
Most of the first testing day went into the machine, not the model. Each of these stalled a run:
- Every browser froze once vLLM loaded, because the browsers were started from a folder on a slow network drive. Starting them from a local folder fixed it.
- A newer library version needed an extra input field for this model's images, and silently broke training without it.
- A few long pages overflowed the model's input limit, and one bad prompt made the engine reject the whole batch.
- The pixel-click format didn't match what Qwen was trained on: 30% unreadable answers, 0% after switching to its native
coordinate: [x, y]format.
What it cost
| Item | GPU | Cost |
|---|---|---|
| Testing and fixes | H100 | ≈ $8 |
| Run 1, with evaluations | H100 | ≈ $26 |
| Run 2, with evaluations | A100 | ≈ $15 |
| Total | ≈ $49 |
Where this sits, and the road from here.
This project is a well-built toy. It uses the same ideas as frontier computer-use agents, at a scale thousands of times smaller.
Our numbers aren't comparable to leaderboards
On MiniWoB++ itself, the benchmark is effectively solved. A 2022 DeepMind agent reached human-level average scores using 2.4 million human demonstrations. In 2023, prompting a large model with the page's HTML reached 99.2% average success across tasks. Our 72.6% is on 16 tasks chosen because our model found them hard, with a 4-billion-parameter model reading screenshots. Different question, different number.
The real benchmark: a whole computer
Today's agents are judged on benchmarks like OSWorld: a full Ubuntu desktop, a few hundred tasks across real apps such as browsers, spreadsheets, and file managers, all controlled by pixel clicks and keystrokes. People completed about 72% of its tasks when it was introduced.
Public leaderboards in late 2026 list the strongest closed agents above 80% on its verified version, and several open-weight models around 27 billion parameters in the high 70s. The aggregator sites disagree with each other, so treat those as rough. Not long before, the best open models scored below 50%.
How to climb from here
- Point with pixels. Train Track B, so the model works on any screen, not just pages that list their elements.
- Start stronger. Use a larger base model (8 to 32 billion parameters), or one already tuned for computer use.
- Learn from examples first. Fine-tune on many recorded successful sessions, from people or a stronger agent, before RL. Frontier recipes put most of their effort here.
- Harder gyms. Move to real websites and desktops, such as WebArena, OSWorld, and AndroidWorld, with hundreds of virtual machines running in parallel.
- Better scorekeepers. Real tasks don't grade themselves. Train or prompt a checker model to judge whether a task was done.
- Longer tasks. Real work takes 20 to 100 steps. That needs better credit assignment, memory of earlier steps, and thinking before acting.
- Scale the plumbing. Separate the machines that practice from the ones that train, so neither waits on the other.
Sources: A Data-Driven Approach for Learning to Control Computers (DeepMind, 2022); Synapse (2023); OSWorld; leaderboard summaries at Steel and ScholarCompass; DAPO.
Words, in plain terms.
Every term used in this notebook, in one place.
- Adapter
The small file of extra weights LoRA produces. Load it on top of the base model to get the trained behavior.
- Advantage
How much better or worse one attempt scored than its group's average. Positive means “do more of this.”
- Base model
The model as downloaded, before our training.
- Confidence range
The span the true difference likely falls in. We used 95%. If it includes zero, the change may be noise.
- DAPO
A 2025 paper with tweaks to GRPO. We used its dynamic sampling idea.
- Dynamic sampling
Running extra groups and training only on the mixed ones.
- Episode
One attempt at one task variation, up to eight turns.
- Forgetting
Getting worse at tasks you didn't practice while training hard on others.
- GRPO
Group Relative Policy Optimization. Try a task several times and learn from the differences between attempts.
- Group
The 8 attempts at the same task variation that GRPO compares.
- Held-out task
A task never used in training, used to test whether skills transfer.
- LoRA
Low-rank adaptation. Train a small set of extra weights instead of the whole model.
- Mixed group
A group with at least one pass and one fail. The only kind GRPO learns from.
- MiniWoB++
A gym of about 100 small self-grading web pages for training agents.
- OSWorld
A benchmark of real desktop tasks on a full operating system.
- Policy
RL's word for the model that chooses actions.
- Reward
The score for an episode. Here, 1 for success and 0 for failure, plus small adjustments.
- RFT
Rejection-sampling fine-tuning. Keep only successful attempts and train on them as examples.
- Seed
A number that fixes one random variation of a task.
- Smoke test
A short run that checks everything works before the long, expensive one.
- Track A, B
Two action styles. A clicks elements by ID; B clicks by pixel coordinates.
- vLLM
A fast engine for generating the model's answers during practice.