
LFM3-VL-2B with an SFT-trained LoRA adapter performing the MiniWoB++ click-button-sequence task on a held-out seed. The red ring marks each click location.
The animation shows LFM3-VL-2B performing the MiniWoB++ click-button-sequence task. The instruction is
Click button ONE, then click button TWO. The model receives a screenshot of the page, without a DOM representation
or element IDs. At each turn, the model is prompted to output one click position. BrowserGym executes a valid click.
The next model input contains the updated screenshot and a text record of earlier click coordinates. In the illustrated
layout, the buttons overlap, so the first click must target the visible portion of ONE.
That’s LFM3-VL-2B, a 2-billion-parameter vision model from Liquid AI, with a small LoRA adapter trained using supervised fine-tuning (SFT) on free T4 GPUs from Google Colab and Kaggle. On the initial held-out set of 100 tasks, the SFT model completed 95 sequences with greedy decoding (always choosing the highest-probability next token). Under the same evaluation protocol, the base model completed 0 of 100 sequences in this experiment.
I then added reinforcement learning with Group Relative Policy Optimization (GRPO) to improve robustness when sampling actions. On a second, fresh set of 100 tasks, using the same sampling decoder at temperature 1 and top-p 0.95, SFT alone scored 26/100 and SFT followed by GRPO scored 83/100. On that same fresh set, greedy success was 91/100 before GRPO and 92/100 after it. These matched comparisons distinguish the training effect from differences in decoding and task cohorts.
Try the live demo to compare the base model, SFT adapter and SFT-then-GRPO adapter on a task seed you choose. The Space also includes the text-model tasks.
This post covers how I got there, along with two other small models and the mistakes along the way. It’s the companion to the code and evidence in browser-control, and to a Space where you can step through every episode shown here.
| Model | Task | Training | Evaluation result |
|---|---|---|---|
| LFM3-VL-2B | Click two buttons in order, from screenshots | SFT on 234 expert clicks, then GRPO on reward | 92/100 greedy, 83/100 sampled on the fresh cohort; base model 0/100 on the initial cohort |
| LFM3-1.7B | Book the cheapest or shortest flight, about ten steps | Supervised fine-tuning (SFT) on scripted traces | 160/200; base model 0/100 on a separate cohort |
| LFM2-350M | Click a button | GRPO with a decaying formatting curriculum | 2/50 → 50/50 sampled completions of one fixed prompt, for each of three training seeds |
The baseline counts describe observations under the reported evaluation harness. The vision base model was evaluated on the initial 100-task cohort; the SFT-versus-GRPO comparison used a fresh cohort of 100 tasks. The book-flight base model and SFT adapter were evaluated on separate cohorts of 100 and 200 tasks, respectively, rather than a paired task set.
The setup
MiniWoB++ is a collection of more than a hundred small web pages, each with an instruction and its own scorer: click the button, book the flight, click the cyan box. Each task is generated from a seed, so seed 10100 always produces the same airports, dates and flights. When an episode ends, the task’s own scorer returns a reward: 1 for success, 0 for failure. BrowserGym runs these pages in a real Chromium browser and turns each into a turn-by-turn exchange with a model.
The model never touches the browser directly. Each turn it gets the instruction and a description of the page, and it must answer with exactly one action in the required format. A strict parser reads that action; any other answer ends the episode with reward zero, whether it’s an explanation, two actions, or a call that’s almost right. Nothing is repaired or retried.
For the text models, the page arrives as an accessibility tree: one line per element, with an ID on each interactive
one. Here is the entire click-test page, as a person sees it, then as the model receives it:

The click-test page: a single button.
Goal: Click the button.
RootWebArea 'Click Test Task', focused
[13] button 'Click Me!'
And the start of a book-flight page:

The book-flight form.
Goal: Book the shortest one-way flight from: HOT to: PIE on 10/24/2016.
[17] heading 'Book Your One-Way Flight'
[19] textbox 'From:'
[21] textbox 'To:'
StaticText 'Departure Date'
[25] textbox ''
[27] button 'Search'
The vision model receives a screenshot rather than an accessibility tree, along with the task instruction and, on subsequent turns, a text record of earlier click coordinates. Click positions use coordinates from 0 to 1000 on each axis across the whole image:

Lesson one: format comes before skill
The click-test task measures output formatting: whether a model returns a click action that the environment can
execute. The task uses one fixed prompt and requires no multi-step reasoning. The page contains a single button with
ID 13; the expected response is click('13'), which also appears in the prompt as an example of the action format.
Under this output contract, the base LFM2-350M model completed the task in
2 of 50 sampled responses. Other responses included click('Click Test Task'), using the page title in place of the
element ID, and click(<button id="13">Click Me!</button>), placing the button’s HTML inside the call.
I trained the model with GRPO and a temporary formatting curriculum: early in training, unsuccessful responses received partial credit for valid syntax or similarity to the expected action. This extra reward decayed to zero after group 40, leaving only the task’s success reward. All three runs reached perfect training groups while the curriculum was active and retained that performance during the later strict-reward phase.
GRPO samples a group of answers to the same prompt, scores each one, and favors answers with rewards above the group mean. With samples and rewards , the group mean reward and each answer’s advantage are
The policy-gradient update favors answers with positive advantage over those with negative advantage. If every answer in a group receives the same reward, the group-relative advantages are zero.
My first GRPO pilot looked like a failure: 0 of 50 after training. It wasn’t. My evaluation decoder used a repetition penalty of 1.05, while training sampled without one. Under the decoder the model actually trained with, the same checkpoint scored 16 of 50 against the base model’s 2. One mismatched setting had hidden the whole effect. Since then I evaluate with exactly the decoder I train with and say which one it is.
With complete groups of eight samples, all three training seeds reached 50 of 50 sampled completions of the fixed prompt:
| Base LFM2-350M | After GRPO |
|---|---|
![]() | ![]() |
This is alignment to an output format on one fixed prompt, not general browsing.
Booking flights from text
book-flight is a real sequence of decisions. Type the origin and choose it from an autocomplete list. Do the same for
the destination. Open a read-only date picker, page to the right month, pick the day. Search, compare the flights, and
book the cheapest or shortest one. That’s about ten dependent turns, and one wrong turn usually ends the task.
LFM3-1.7B writes tools in its own format, one call per turn. Here is the first turn of an episode, and the page afterwards:
<tool_call>
<function=fill>
<parameter=bid>
19
</parameter>
<parameter=value>
HOT
</parameter>
</function>
</tool_call>

The From box filled with HOT, with the autocomplete list open.
Under this evaluation setup, the base model completed 0 of 100 tasks. The evaluation required exactly one tool call per turn, with thinking disabled, a limit of 128 generated tokens per response and a strict action parser. In 97 of the 100 episodes, the base model’s last turn was prose reasoning that hit the token cap before any call. On probes that started it at a known step, 105 of 120 calls were well-formed, but only 24 selected an action that advances the tested step. With thinking enabled and a 512-token limit, 32 of 120 calls selected such an action.
On the 30 development tasks I tuned on, with an identical setup, the base model completed 0/30 tasks and the adapter completed 25/30. One of them, side by side:

Development task 71. Left: the base model answers with prose, not an action. Right: the SFT adapter fills the form, works the date picker and books.
After supervised fine-tuning: 160 of 200. I wrote a scripted solver and trained a LoRA adapter on its traces. Then I locked the adapter, the decoder and a list of 200 reserved tasks, and evaluated once. It booked correctly 160 times (95% Wilson confidence interval 74–85%). All 1,823 of its tool calls were well-formed.

LFM3-1.7B with the SFT adapter booking the shortest flight on a reserved task.
The failures are instructive. The agent reached the results page in 197 of 200 episodes; the misses are almost all at the last step. In 35 of the 40 failures, it booked a flight visibly worse than the best one shown:

Task 10108: the shortest flight, 7h 29m, is listed first, and the agent booked a 10h 41m flight further down.
Under this setup, the model often completed the form but sometimes selected a longer flight than the shortest option shown.
Book-flight GRPO. An earlier 24-group run from a weaker SFT checkpoint changed development success from 20/30 to 21/30. This small change does not establish an improvement.
Before training the final SFT checkpoint further, I checked whether sampled episodes differed in reward. Each of 12 fresh tasks was sampled four times: six tasks at temperature 1.25 with top-p 0.95, and six at temperature 1 without truncation. All four episodes in each group had the same reward, leaving no group-relative learning signal in these samples. Training did not proceed from the final checkpoint.
Clicking from pixels
White-image control. Each vision evaluation also uses a plain white image in place of the screenshot, while retaining the task instruction and image dimensions. This tests whether success persists when screenshot content is removed.

One-click output formatting. On click-color (“click the cyan box”), a supervised adapter went
from 30 to 100 successes on 100 unseen tasks. The base model chose the correct box in 30 of its 31 valid calls;
most of the improvement was associated with valid output formatting. A GRPO adapter scored 100/100 with screenshots
and 6/100 with white images, compared with a predeclared white-image limit of 5/100.
Then the sequence. click-button-sequence requires two clicks in order. The one-click adapter completed 1 of
40 development sequences. I then trained on sequence examples generated by a scripted expert, which used browser
geometry and hit-testing to label the visible part of each button. Those browser queries were used only to construct
training labels; the policy received the screenshot, task instruction and earlier click coordinates.
In 14 of 120 training layouts, the buttons overlapped and clicking the center of ONE hit TWO. The expert instead searched for a visible point on the requested button. Three layouts yielded no valid labeled sequence and were excluded from training. The remaining 117 layouts produced 234 expert turns, each with the screenshot and prompt for that turn. All 100 reserved evaluation seeds were retained.
The vision baseline used the specified prompt, a strict action parser, a four-turn limit and a maximum of 128 generated tokens per turn. The result does not establish performance under other prompting or inference configurations.
On 100 reserved tasks, locked before the run:
| Base LFM3-VL-2B | With the adapter | |
|---|---|---|
| Greedy | 0/100 | 95/100 |
| Sampled at temperature 1 | 0/100 | 21/100 |
| White image | 0/100 | 0/100 |
The sampled row was my declared primary test: 21 wins over the base model, no losses, by an exact sign test. The SFT adapter completed no sequences with white-image inputs in this evaluation. This supports dependence on screenshot information under the tested conditions. With greedy decoding, the adapter succeeded on 95 of 100 tasks.
Here is one of those held-out tasks, with the base model and the adapter side by side:

The same held-out task, greedy. Left: the base model’s first answer isn’t a valid click. Right: the SFT adapter clicks ONE, then TWO.
Under sampling, 78 of 100 episodes ended on a malformed call. Among episodes with valid calls throughout, 95% succeeded. Output formatting remained a common source of failure, and the sampled episodes varied in reward, providing a learning signal for GRPO.
GRPO improves sampled action validity
I ran a simplified GRPO over whole episodes. For each training task it samples four episodes at temperature 1 and scores each only by the task’s own reward. Every turn of an episode is weighted by that episode’s advantage from the formula above, with one on-policy update per group. Groups where all four episodes scored the same are skipped; 39 of 120 varied.
The SFT adapter and its GRPO continuation were then evaluated on a fresh held-out cohort of 100 tasks:
| SFT | SFT, then GRPO | |
|---|---|---|
| Sampled at temperature 1 (locked test) | 26/100 | 83/100 |
| Every call well-formed, sampled | 30 | 94 |
| Greedy | 91/100 | 92/100 |
| White image | 0/100 | 0/100 |
Under the fixed generation-seed rule, GRPO succeeded on 57 tasks where the SFT adapter failed, with no reverse outcomes ( by a paired sign test). On the same cohort, greedy success was 91/100 before GRPO and 92/100 afterward. Neither adapter completed a sequence with white-image inputs.
Sampled episodes with valid calls throughout increased from 30/100 to 94/100. Within those subsets, success was 26/30 (86.7%) before GRPO and 83/94 (88.3%) afterward. The improvement therefore appears to come largely from more reliable output formatting. These subsets contain different episodes, so the conditional rates do not isolate changes in visual decision quality.

A fresh held-out task, sampled. Left: the SFT adapter’s answer isn’t a valid action. Right: after GRPO it clicks ONE, then TWO.
This vision comparison evaluates one GRPO training run on held-out layouts from one MiniWoB++ task family.
Checks on result validity
Small-model results can be overstated without careful controls. The evaluation used the following checks:
- Test settings are fixed in advance. Models, decoding settings and scoring rules were fixed before testing. Each planned evaluation was run once. Paired comparisons used the same tasks for both models. Any further model tuning was evaluated on a new test set.
- Analysis rules are specified in advance. Success criteria and the white-image acceptance threshold were recorded before the evaluation.
- Invalid output is a failure. No repair, no retry, no lenient parsing.
- White-image controls and matched decoders. Vision evaluations include a white-image condition. Sampled comparisons use matched decoding settings; greedy decoding is evaluated separately.
- Results can be recounted. The evidence dataset contains the recorded episodes, screenshots and training records. The verification script recomputes reported metrics from the released episodes and checks artifact hashes against the pinned manifest.
The animations in this post follow the same rule. They aren’t screen recordings of a live run. MiniWoB is seeded, so resetting a task and replaying the actions the model recorded during evaluation redraws exactly what it did, and a replay that doesn’t reach the recorded reward is rejected.
Lessons learned
- Measure action validity alongside task success. Invalid tool calls accounted for many failures in these experiments.
- Check within-group reward variation before GRPO training. Groups with identical rewards provide no group-relative learning signal.
- Controls are cheap and decisive. A white image, a matched decoder and a locked task list each changed a conclusion in this project.
- SFT followed by GRPO improved sampled success on the vision sequence task. The book-flight diagnostics found little reward variation after SFT, limiting the available learning signal.
- The reported 0.35B–2B LoRA training runs fit on a T4. These runs used the free GPU allocations on Colab and Kaggle.
The code, the three adapters, the evidence and the step-through Space are all linked from browser-control.
Related work: Liquid AI’s cookbook trains LFM2-350M on click-test with GRPO
(example,
write-up by Pau Labarta Bajo) and names
book-flight and vision models as next steps. This project measures that result across seeds and takes both natural next steps,
with held-out evaluation on book-flight and vision layouts.

