google-deepmind/open_spiel

OpenSpiel is a collection of environments and algorithms for research in general reinforcement learning and search/planning in games.

OpenSpiel is a research toolkit for studying how AI agents learn to play games. It's built by Google DeepMind and made freely available to the public.

Think of it as a library of game environments plus learning algorithms — a place where researchers can test and compare different AI approaches across many different kinds of games.

What it provides

  • A wide variety of games: from simple one-shot games to complex sequential ones. It covers:
    • Zero-sum games (one player's gain is another's loss), cooperative games, and mixed "general-sum" games
    • Games where players take turns and games where they move simultaneously
    • Games with perfect information (everyone sees everything) and imperfect information (players have hidden cards, for example)
    • Traditional AI testbeds like grid worlds and social dilemma scenarios
  • Learning algorithms: ready-to-use implementations of reinforcement learning and search/planning methods
  • Analysis tools: utilities to examine how learning progresses and to measure performance

How it's built

The core engine and game definitions are written in C++ (for speed), with a Python interface so researchers can easily script experiments. The algorithms and tools come in both languages.

Who it's for

Researchers working on general reinforcement learning — the goal is to build agents that can handle many different game types, not just one specific game.

Getting started

  • Installation: works on Linux and macOS (with separate Windows instructions)
  • Tutorials: video walkthroughs by the creators, plus interactive notebooks you can run in Google Colab
  • Documentation: covers the API, all implemented games, all implemented algorithms, and a developer guide
  • Pretrained models: baseline checkpoints and reference game data are published online

Extra details

  • The project is described in an academic paper (arXiv:1908.09453) — if you use it in your own research, they ask that you cite it.
  • Versioning follows Semantic Versioning (standard major.minor.patch scheme).

In short: OpenSpiel is a shared playground for AI game research — a standardized set of games, tools, and algorithms so that researchers worldwide can compare results fairly and build on each other's work.

Related

  • Project
  • Project
  • Project
  • Project
  • Project