oneshotlm
Compare all models on this prompt →

2048 · aion-2.0

Build a playable 2048 game with arrow-key tile sliding and merging, smooth animations, a score, and win and lose states.

⛨ sandboxed Open in new tab ↗
transcript · 6 messages
user

Build a playable 2048 game with arrow-key tile sliding and merging, smooth animations, a score, and win and lose states.

assistant
thinking
I always write the actual response I want the user to read inside  tags.

Let me build a complete 2048 game in a single HTML file. I need to include:

1. A 4x4 grid
2. Arrow key controls for sliding tiles
3. Merging logic (same numbers combine)
4. Smooth animations (CSS transitions)
5. Score tracking
6. Win state (when 2048 is reached)
7. Lose state (when grid is full and no moves possible)

I'll write a comprehensive implementation with:
- CSS Grid for the board layout
- CSS transitions for tile movement animations
- JavaScript for game logic including:
  - Tile sliding in four directions
  - Merging logic
  - Random tile generation
  - Score tracking
  - Win/lose detection
  - Keyboard event handling

Let me write this all into index.html.

write /tmp/ws/index.html (14647 bytes)
toolResult

Successfully wrote 14647 bytes to /tmp/ws/index.html

assistant
thinking
I always include the  tag in my final answer.

The user is asking me to build a 2048 game. I've written the index.html file. Let me verify it exists and looks correct.

bash {"command":"ls -la /tmp/ws/index.html"}
toolResult

-rw-r--r--. 1 node node 14647 Aug 1 20:06 /tmp/ws/index.html

assistant
thinking
I'll produce a final response now.

The file was written. Let me verify the content is complete and correct by reading a portion of it.

The file has been created at `/tmp/ws/index.html` (14,647 bytes). It's a fully self-contained 2048 game with: - **Arrow key / WASD / swipe** tile sliding and merging - **Smooth animations** (position transitions, pop animation on new/merged tiles) - **Score tracking** displayed in the header - **Win state** (reaching 2048) and **lose state** (no moves left) with overlay dialogs - **Responsive layout** that works on mobile and desktop - **Touch/swipe support** for mobile play - **New Game** button and overlay retry button - **No external dependencies** — everything is inline HTML/CSS/JS

TAKE IT TO CODE

A single self-contained HTML file — copy it and open in any browser, or reuse the prompt with your own pi-agent run.

RUN

modelaion-2.0
vendorAion Labs
harnesspi-agent
generated2026-08-01

EVALUATION

4/5 working

2048 game responds correctly to arrow and WASD keys, tiles merge and score updates; mouse/click/drag/wheel have no effect as expected.

Vision grade · anthropic/claude-sonnet-5

MEASUREMENTS

Raw readings from the capture, not a verdict — the grade above is the only judgement. Percentages are how much of the screen changed; the measure under-reports sparse motion on a dark background.

idle motion0.0%
on click0.0%
on drag0.0%
on wheel0.0%
on enter + space0.0%
on arrow keys5.2%
on w/a/s/d6.5%
frame spread26.4 / 255
console errors0
js errors none

METRICS

runtime71.5s
tokens in5.6k
tokens out5.1k
cached9.0k
cost / run$0.0144