git404hub

what is diplomacy-ai fr?

brendenehlers/diplomacy-ai — explained in plain English

Analysis updated 2026-05-18

2PythonAudience · developerComplexity · 3/5Setup · moderate

tl;dr

A project that runs full games of the board game Diplomacy with all seven countries played and negotiated by AI language models instead of people.

vibe map

mindmap
  root((diplomacy-ai))
    What it does
      Seven AI powers
      Negotiation rounds
      Order validation
    Tech stack
      Python
      LiteLLM
      Diplomacy engine
    Use cases
      Watch AI games
      Compare models
      Replay in web UI
    Audience
      Developers
      AI hobbyists

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

what do people make with this?

VIBE 1

Watch AI agents negotiate and betray each other across a full game of Diplomacy.

VIBE 2

Pit different AI models or personas against each other by assigning one per power.

VIBE 3

Replay a finished game in the official Diplomacy web UI, including private per power reasoning.

what's the stack?

PythonLiteLLMdiplomacy engineGeminiReact

how it stacks up fr

brendenehlers/diplomacy-ai0-bingwu-0/live-interpreter010zx00x1/faresnipe
Stars222
LanguagePythonPythonPython
Setup difficultymoderatemoderateeasy
Complexity3/52/52/5
Audiencedevelopergeneralgeneral

Figures from each repo's GitHub metadata at analysis time.

how do i run it?

Difficulty · moderate time til it works · 30min

Needs either a free Gemini API key or a locally running LM Studio model to actually play a game.

in plain english

This project runs a full game of the board game Diplomacy where all seven countries are played by AI language models instead of people. It builds on an existing open source Diplomacy game engine and adds AI agents that negotiate with each other and submit moves each turn, just like human players would. Each round of the game has three parts. First, during movement phases, every AI power reads messages sent to it and can send its own messages back to a specific other power privately or to everyone at once, across a set number of negotiation rounds. Second, each power submits its moves as structured data, which get checked against the game's official rules, if a move is illegal the system asks that power's AI once to fix it, and if it is still illegal the unit simply does nothing that turn rather than breaking the game. Third, the engine applies everyone's moves and saves the full record, including private messages and each AI's internal reasoning, so a person can review the whole game afterward, including any scheming that never became public. To run it, someone needs Python 3.11 or newer and a tool called just to run setup commands. The quickest path uses Google's Gemini AI model, which has a free tier: a person gets an API key from Google AI Studio, puts it into a configuration file, and starts a game with one command. Any AI model supported by a library called LiteLLM can be used instead, including running a model entirely on your own computer for free through a program called LM Studio, so an API key is not strictly required. Each of the seven AI powers can even be assigned a different underlying model or a different personality, or persona, described in plain text. After a game runs, its full record is saved to a folder including a game file that can be loaded into Diplomacy's official web interface to watch the board and public messages, plus separate files showing each AI power's private messages and reasoning per turn, and a running log of progress. There is also a test suite that runs without any network access, plus an optional live test that actually calls the AI model and costs a small amount of money to run.

prompts (copy fr)

prompt 1
Walk me through setting up diplomacy-ai with a free Gemini API key and running my first game.
prompt 2
Show me how to run diplomacy-ai locally with LM Studio so I don't need an API key.
prompt 3
Explain how to assign a different model and persona to each of the seven powers in game.toml.
prompt 4
Help me set up the official web UI to replay a saved diplomacy-ai game.json file.

Frequently asked questions

what is diplomacy-ai fr?

A project that runs full games of the board game Diplomacy with all seven countries played and negotiated by AI language models instead of people.

What language is diplomacy-ai written in?

Mainly Python. The stack also includes Python, LiteLLM, diplomacy engine.

How hard is diplomacy-ai to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is diplomacy-ai for?

Mainly developer.

peek the repo → explain another one

This repo across BitVibe Labs

double-check against the repo, no cap.