SuperAPIAI Directory

chatarena

github.com · AI agents

ChatArena is a multi-agent language game environment library for large language models (LLMs), aimed at researching and improving AI communication and collaboration capabilities. It provides a flexible abstraction framework based on Markov decision processes, allowing the definition of multiple players, environments, and their interactions, and includes a variety of built-in language game environments (such as NLP Classroom, Werewolf-style Chameleon, Tic-tac-toe, Rock-paper-scissors, etc.) for understanding, benchmarking, or training agent LLMs. The project provides both a Web UI and a CLI interface, facilitating development and prompt engineering. The library supports installation via pip and optionally integrates the OpenAI API as a language backend. It should be noted that the project ceased maintenance on August 11, 2025 due to insufficient community usage and no longer receives updates or support.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)
PlatformsLinux

About this tool

ChatArena (also known as Chat Arena) is a multi-agent language game environment library for large language models (LLMs), maintained by Farama-Foundation. Its goal is to develop AI communication and collaboration capabilities and to facilitate research on autonomous LLM agents and their social interactions.

Purpose

ChatArena is mainly used to research, benchmark, or train LLM-based agents, observing and evaluating interaction behavior between agents through multi-agent language game environments. It is suitable for research scenarios that require simulating multi-player dialogue, social reasoning, or strategic games.

Main Capabilities

  • Abstraction Framework: Based on Markov decision processes, it provides a flexible framework to define multiple players, environments, and the interactions between them.
  • Language Game Environments: A set of built-in environments to help understand, benchmark, or train agent LLMs. Specific environments include:
    • Conversation: A multi-player language game environment that simulates conversation.
    • NLP Classroom: A 3-player language game environment that simulates a classroom scenario, taking turns asking or answering questions, ending after all players have completed asking and answering.
    • Moderator Conversation: Based on Conversation, but with a moderator controlling the game dynamics.
    • Rock-paper-scissors: A 2-player language game environment that simulates rock-paper-scissors with moderator conversation, with both sides acting in parallel, ending when one side wins 2 rounds.
    • Tic-tac-toe: A 2-player language game environment that simulates tic-tac-toe with moderator conversation, taking turns requesting moves or moving, ending when one side wins or the board is full.
    • Chameleon: A multi-player social deduction game that includes two roles, chameleon and non-chameleon, divided into three phases: giving clues, accusations, and guessing.
    • PettingZooChess: A two-player chess game environment using the PettingZoo Chess environment.
    • PettingZoo TicTacToe: A two-player tic-tac-toe game environment using the PettingZoo TicTacToe environment, driven by hardcoded rules rather than an LLM moderator.
  • User-Friendly Interface: Provides a Web UI and CLI for developing/prompt engineering the behavior of LLM agents in environments.

Usage

  • Installation: Can be installed via pip (pip install chatarena), or install from source. By default, only the dependencies required for core functionality are installed; optional dependencies require an additional command to install.
  • Configure API key: If using GPT-3 etc. as the LLM agent, you need to set the OpenAI API key.
  • Run the demo locally: Install chatarena with the gradio extra dependency, clone the repository, and run app.py in the root directory to access the demo server in a browser (port 8080).
  • Run a game with the Python API: Load an Arena from a configuration file (e.g., examples/nlp-classroom-3players.json), then run the game in an interactive CLI interface.
  • Customization: You can override Arena (write your own main loop), Environment (define new game dynamics), Backend (change how observations are formatted into queries), and Player (customize how it interacts with the language backend). To create a custom environment, inherit from the Environment class, set type_name, add it to ALL_ENVIRONMENTS, implement methods such as init, step, reset, get_observation, is_terminal, and get_rewards, and develop role description prompts.

Applicable scenarios

Suitable for academic or experimental scenarios such as multi-agent LLM research, social interaction simulation, language game benchmarking, and agent training.

Limitations

  • This project was deprecated on August 11, 2025 due to lack of widespread community use, and no further updates or support are planned.
  • Using GPT-3.5-turbo or GPT-4 etc. as the LLM agent requires an OpenAI API key (optional).
  • By default, pip installation includes only core functionality dependencies; some features require installing optional dependencies.
  • Specific information such as fees, pricing, and platforms is not provided at this time.
Up/Down to navigate · Enter to open · ESC to closeBrowse all tools