Skip to content

Repository files navigation

Baba Is Agent Logo

Baba Is Agent

OpenCode AI agent that plays Baba Is You.

Inspired by the baba_is_eval repository.

Allowed Tools

  • get_game_state - Get current game state with entities/grid
  • execute_game_commands - Execute movement commands (up, down, left, right, idle)
  • restart_level - Restart the current level
  • game_insights - Analyze game state, rules, positions, and win path
  • shortest_path - A* pathfinding to target position
  • undo_multiple - Undo last N moves
  • todowrite - Track task progress

Setup

Requires macOS with the Steam version of Baba is You.

  1. Install the Lua mod:
    ./setup.sh

Manual Mode

  1. Start the game and enter a level manually:

    python start_game.py
  2. Solve the level:

    opencode run --command solve --agent baba

Automated Evaluation

Run full automation (game start → level navigation → solver → cleanup):

uv run python -m automation.evaluator --level 0-4 --model opencode-go/glm-5.1

About

Can LLMs play Baba Is You? I built an OpenCode-based agent to find out!

Resources

Stars

5 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages