ghost/sgt-puzzles

Simon Tatham's Puzzles (F-Droid): open a puzzle (Net by default), start a new game, rotate tiles, undo, show the solution, read the status line. Offline, no account.

Proven 36× fewer tokens Score 41/100 Official hard skill python

Token savings

97% fewer tokens
Tokenswithout1,413,843with39,684 (97% fewer)
Timewithout49.9 swith34.7 s (30% less time)
Tool callswithout29with5 (83% fewer)

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.

Recorded: open_puzzle · live agent session on a real phone

Control Simon Tatham's Puzzles on Android with an AI agent — play logic puzzles

Control Simon Tatham's Puzzles on Android with an AI agent. Play and auto-solve logic puzzles on your phone: an agent opens Net, rotates tiles and reads the progress.

Target search phrase: AI agent solves logic puzzles on Android

Demo shows: open_puzzle (name=Net)

Ghost in the Droid seed skill for Simon Tatham's Puzzles (name.boyle.chris.sgtpuzzles), Simon Tatham's collection of 40 logic puzzles from F-Droid (this skill plays Net and can open any other puzzle). Offline, no account.

ActionWhat it doesParams
open_puzzleOpen any puzzle from the list by name (default Net)name
new_gameOpen Net and generate a fresh board (optionally a size/type)type
tap_tileRotate a tile of the running Net boardrow, col, times, size
undo_moveTake back the last rotationnone
show_solutionLet the app auto-solve the puzzlenone
get_stateRead screen, puzzle name, status, active/total tiles, solvednone

Toolkit

An agent can drive the whole app with these; compose them.

RoleAction
Entryopen_puzzle, new_game
Primitivestap_tile, undo_move, show_solution
Read stateget_state

Install

The app: F-Droid, or https://f-droid.org/packages/name.boyle.chris.sgtpuzzles/. 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/sgt-puzzles

Use

ghost skill run ghost/sgt-puzzles open_puzzle --param name=Net --device <serial>
ghost skill run ghost/sgt-puzzles show_solution --device <serial>
run_skill(name="ghost/sgt-puzzles", action="get_state")
# {"state": {"screen": "puzzle", "puzzle": "Net", "status": "Active: 7/25", "active": 7, "total": 25, "solved": false}}

Try asking: "Open the Net puzzle, start a new game and solve it."

Tested on

Real Samsung phone, Android 13 (720x1600, 300 dpi, en-GB), Simon Tatham's Puzzles 2025-09-12 (build 149). License: MIT.

Known failure modes and versions tested

Versions tested

App versionAndroidDeviceSkill versionDates
2025-09-12 (build 149)13Samsung real phone (720x1600, 300 dpi, en-GB)1.0.02026-11-02

Recorded failures

  • Net boards are random: never assert the starting Active count, assert that it changes or that the status reads Auto-solved.
  • The board is a canvas: tap_tile uses computed coordinates for a 5x5 board; other sizes need the size param and a visible board.
  • Opening the app reopens the puzzle in progress, so the puzzle-list subroutine presses BACK first.

Popups and first-run screens handled

  • None: no first-run screens, no permissions.

Try a sample prompt or run an action by name. Replace any parameters in braces with your own values.

open_puzzle

Play demo

Try asking

  • Open the Net puzzle
  • play a logic puzzle
  • open Light Up
  • start Simon Tatham's Net
ghost skill run ghost/sgt-puzzles open_puzzle

new_game

Play demo

Try asking

  • Start a new Net puzzle
  • new puzzle
  • give me a fresh net board
ghost skill run ghost/sgt-puzzles new_game

tap_tile

Play demo

Try asking

  • Rotate the centre tile of the Net puzzle
  • turn the top left tile
  • tap tile row 2 column 4 twice
ghost skill run ghost/sgt-puzzles tap_tile

undo_move

Play demo

Try asking

  • Undo my last move in the puzzle
  • take that move back
ghost skill run ghost/sgt-puzzles undo_move

show_solution

Play demo

Try asking

  • Solve the puzzle
  • show me the solution
  • auto-solve this net
ghost skill run ghost/sgt-puzzles show_solution

get_state

Play demo

Try asking

  • How far along is my puzzle?
  • is the net solved
  • what is the puzzle status
ghost skill run ghost/sgt-puzzles get_state