google-deepmind /open_spiel
OpenSpiel is a collection of environments and algorithms for research in general reinforcement learning and search/planning in games.
★ 5,592⑂ 1,217👁 104⑃ 955● 666▤ 31
+2
日增长
5,592
stars
1,217
forks
104
watchers
955
prs
666
issues
31
releases
README
OpenSpiel: A Framework for Reinforcement Learning in Games
!build_and_test
OpenSpiel is a collection of environments and algorithms for research in general
reinforcement learning and search/planning in games. OpenSpiel supports n-player
(single- and multi- agent) zero-sum, cooperative and general-sum, one-shot and
sequential, strictly turn-taking and simultaneous-move, perfect and imperfect
information games, as well as traditional multiagent environments such as
(partially- and fully- observable) grid worlds and social dilemmas. OpenSpiel
also includes tools to analyze learning dynamics and other common evaluation
metrics. Games are represented as procedural extensive-form games, with some
natural extensions. The core API and games are implemented in C++ and exposed to
Python. Algorithms and tools are written both in C++ and Python.
To try OpenSpiel in Google Colaboratory, please refer to open_spiel/colabs subdirectory or start here.
Index
Please choose among the following options:
Installing OpenSpiel (for Linux and MacOS; see separate
Windows Installation instructions.)
Introduction to OpenSpiel
API Overview and First Example
API Reference
Overview of Implemented Games
Overview of Implemented Algorithms
Playing Games in a Browser
Developer Guide
Using OpenSpiel as a C++ Library
Guidelines and Contributing
Authors
For a longer introduction to the core concepts, formalisms, and terminology,
including an overview of the algorithms and some results, please see
OpenSpiel: A Framework for Reinforcement Learning in Games.
For an overview of OpenSpiel and example uses of the core API, please check out
our tutorials:
Motivation, Core API, Brief Intro to Replictor Dynamics and Imperfect
Information Games by Marc
Lanctot.
(slides)
(colab)
Motivation, Core API, Implementing CFR and REINFORCE on Kuhn poker, Leduc
poker, and Goofspiel by Edward
Lockhart.
(slides)
(colab)
If you use OpenSpiel in your research, please cite the paper using the following
BibTeX:
bibtex
@article{LanctotEtAl2019OpenSpiel,
title = {{OpenSpiel}: A Framework for Reinforcement Learning in Games},
author = {Marc Lanctot and Edward Lockhart and Jean-Baptiste Lespiau and
Vinicius Zambaldi and Satyaki Upadhyay and Julien P\'{e}rolat and
Sriram Srinivasan and Finbarr Timbers and Karl Tuyls and
Shayegan Omidshafiei and Daniel Hennes and Dustin Morrill and
Paul Muller and Timo Ewalds and Ryan Faulkner and J\'{a}nos Kram\'{a}r
and Bart De Vylder and Brennan Saeta and James Bradbury and David Ding
and Sebastian Borgeaud and Matthew Lai and Julian Schrittwieser and
Thomas Anthony and Edward Hughes and Ivo Danihelka and Jonah Ryan-Davis},
year = {2019},
eprint = {1908.09453},
archivePrefix = {arXiv},
primaryClass = {cs.LG},
journal = {CoRR},
volume = {abs/1908.09Top issues
#843Call for New Games81 comments · 2022-05-23#1431Add Parameterized N-Player Social Dilemma Games with Dynamic and Stochastic Payoffs16 comments · 2026-01-04#1586Feature proposal10 comments · 2026-08-07#966Cannot Compile with libtorch6 comments · 2022-11-21#1452Feature request: Add method that returns the max length of a serialization string.5 comments · 2026-01-20#1607Document Bots and RL agents4 comments · 2026-09-02#1658Support X-FEN and Shredder-FEN castling rights for Chess9603 comments · 2026-10-28#1596Implement NashPG (Nash Policy Gradient): a Simple PPO-Based Nash Solver3 comments · 2026-08-29
Discussions
#1611Bayesian repeated normal form games.0 comments · 2026-09-04#1545Live HU NLHE bot competition platform — anyone interested in joining alpha testing?0 comments · 2026-05-13#1451Style1 comments · 2026-01-19#1415Recommendations for Crazy Eights1 comments · 2025-12-20#1329Solving Hearts with Deep CFR0 comments · 2025-04-05#1327Applicable games for the open spiel framework0 comments · 2025-03-28#1313Continuous Action Game -- Implementation Help0 comments · 2025-02-25#1270About the Design of the Training Steps in the AlphaZero Algorithm0 comments · 2024-08-20
Latest release
OpenSpiel 2.0.2 v2.0.2 2026-08-12This is a minor release for testing purposes. There are no substantial changes from 2.0.1. Acknowledgments Thanks to Google DeepMind for continued support of development and maintenance of OpenSpiel. Thanks to all of our contributors: - Core Team: https://github.com/deepmind/open_spiel/blob/master/docs/authors.md - All Contributors: https://github.com/deepmind/open_spiel/graphs/contributors