new_game
Play demoTry asking
- Start a chess game as white
- play chess against the computer
- new chess game as black, level 5
- start an easy chess game
ghost skill run ghost/chess new_game Square Chess (F-Droid): start a game (side, engine level 1-9), play moves like e2e4 one at a time or as a list, read the position (placement, status, opening, move list), take back a move or resign. Offline engine, no account.
Agent run: finished without the skill, finished with it (not independently checked).
One recorded run each way, claude-haiku-5-5, same phone and same prompt. Watch it in the Before / after tab.
25× fewer tokens, 2.3× slower with the skill. Agent run: finished without the skill, finished with it (not independently checked).
| Run | Time | Tokens | Tool calls | Result |
|---|---|---|---|---|
| No skill: agent drives by hand | 57.5 s | 739,454 | 18 | finished |
| With skill: find_skill, run_skill | 131 s | 29,666 | 4 | finished |
Prompt: Start a chess game as white and play the opening moves e2e4 and g1f3.
Same prompt, same phone, clean app state per side. Left: no skill, the agent drives the UI by hand. Right: find_skill + run_skill. 'ok' means the agent finished its turn; the result was not independently checked.
One recorded pair on samsung-a03s, claude-haiku-5-5; tokens count every input, cache and output token once per assistant message. Not a signed run: it adds no run evidence.
Control Square Chess on Android with an AI agent. Play chess against the computer on your phone: an agent starts a game, plays moves like e2e4, reads the position and the engine's replies, takes back or resigns.
Target search phrase: AI agent plays chess on Android
Demo shows: new_game (side=white, level=3)
Ghost in the Droid seed skill for Square Chess (
com.dataespresso.squarechess), an offline chess game against a built-in engine from F-Droid (DroidFish was blocked by Google Play Protect on the test phone, so this skill uses Square Chess). Offline, no account.
| Action | What it does | Params |
|---|---|---|
new_game | Start a game against the computer (white/black, level 1-9) | side, level |
make_move | Play one UCI move (e2e4, e7e8q to promote) and wait for the reply | move |
make_moves | Play several of your moves in a row | moves |
undo_move | Take back your last move | none |
resign | Resign the running game | none |
get_board | Read FEN placement, status, opening, SAN moves, last move | none |
An agent can drive the whole app with these; compose them.
| Role | Action |
|---|---|
| Entry | new_game |
| Primitives | make_move, make_moves, undo_move, resign |
| Read state | get_board |
The app: F-Droid, or https://f-droid.org/packages/com.dataespresso.squarechess/. The skill:
pip install "ghost-in-the-droid>=1.6.0" # 1.6.0 is not on PyPI yet: until it ships, git clone the repo and `pip install -e .`
ghost skill install ghost/chess
ghost skill run ghost/chess new_game --param side=white --device <serial>
ghost skill run ghost/chess make_moves --param moves=e2e4,g1f3,f1c4 --device <serial>
run_skill(name="ghost/chess", action="get_board")
# {"board": {"placement": "rnbqkb1r/pppppppp/5n2/8/4P3/8/PPPP1PPP/RNBQKBNR", "status": "Your move", "opening": "B02 Alekhine Defense", "moves": ["e4", "Nf6"], "last_move": "Nf6"}}
Try asking: "Start a chess game as white and play the Italian opening: e2e4, g1f3, f1c4."
Real Samsung phone, Android 13 (720x1600, 300 dpi, en-GB), Square Chess 1.4.1. License: MIT.
| App version | Android | Device | Skill version | Dates |
|---|---|---|---|---|
| 1.4.1 | 13 | Samsung real phone (720x1600, 300 dpi, en-GB) | 1.0.0 | 2026-11-02 |
SOFT.md is the narrative an agent reads when the exact steps no longer match your app version and it has to adapt the skill.
What each action means, which UI landmarks it relies on and how success is recognised, so an agent can adapt it to another app of this kind or another version.
Package: com.dataespresso.squarechess (Square Chess, GPL-3.0, version 1.4.1 from the official F-Droid repository, sha256-verified)
Verified: 2026-11-02 on a real Samsung phone, Android 13, 720x1600 @ 300 dpi, en-GB. Offline, no account.
Skill class: HARD. No login, no checkpoints.
Play against computer, Puzzles, Over the board, Record physical game, Chess clock. The new-game dialog has a level slider (9 dots at x 122 + 52.7 per level, y 458), White/Black, hints and evaluation checkboxes and Start game.e2, white pawn or a6, empty (squares become readable text). A move is two taps: from-square, then to-square.Your move, Game over) plus the opening name on a second line; the SAN move list is real text ("1. e4 Nf6"); Menu opens Undo / take back, Resign, Review game, Move list, Flip board, Share FEN/PGN, Save & home.e4, empty, legal destination). a piece is selected, older Portal builds dropped the legal-target squares (e4, empty, legal destination); the helpers now read the Portal tree only.new_game(side, level)Home > Play against computer > set the level slider and side > Start game. As black the computer opens.
make_move(move)Tap the from square, then the to square, wait until the status is Your move again and the position changed. Returns before/after board and the computer's reply (SAN).
make_moves(moves)make_move for each UCI move; stops when the game is over. Returns the reply after each.
undo_move()Menu > Undo / take back. Fails with a clear error when no move was played.
resign()Menu > Resign > confirm. The game stays in the app's history.
get_board()Parses the 64 square descriptions and the header/move list.
Any chess app that labels squares (or pieces) in the accessibility tree can reuse the parser; otherwise map square bounds from the board frame. SAN input would need a move generator: the skill takes UCI squares on purpose.
Try a sample prompt or run an action by name. Replace any parameters in braces with your own values.
new_gameTry asking
ghost skill run ghost/chess new_game make_moveTry asking
ghost skill run ghost/chess make_move make_movesTry asking
ghost skill run ghost/chess make_moves undo_moveTry asking
ghost skill run ghost/chess undo_move resignTry asking
ghost skill run ghost/chess resign get_boardTry asking
ghost skill run ghost/chess get_board Each release is an immutable git tag. The tree hash pins the exact skill directory the installer verifies.
| Version | Released | App versions | Tree | Size | Provenance |
|---|---|---|---|---|---|
1.0.0latest | never | >=1.4.1 | pending | 26.5 KB | untagged |