mesa / mesa/mesa-examples

Add climate negotiation LLM example

Open
#454 1 comment 1 reaction 0 assignees View on GitHub
Dominant language
Python
Stars
252
Forks
279
Avg merge
8d 9h
Merged PRs (30d)
2

Description

## Summary

I built a multi-agent climate treaty negotiation simulation using mesa-llm and am contributing it here as a learning/exploration example for the community. Originally I created it to explore and test mesa-llm's features in a realistic multi-party negotiation setting. It turned out to be a good showcase of several mesa-llm capabilities together, so I thought it would be a useful addition to the `llm/` examples directory.

## What the model does

Six country agents (USA, EU, China, India, Brazil, Russia), each powered by an LLM, negotiate a shared emissions-reduction target over multiple rounds. A treaty is reached when at least 2/3 of countries formally accept a common proposal.

## Mesa-LLM features it demonstrates

- `STLTMemory` - short-term stores recent proposals; long-term consolidates committed positions
- `ReActReasoning` - agents reason about economic interests before acting
- `speak_to` (inbuilt tool) - targeted diplomatic messaging between agents
- Custom `@tool` functions - `make_proposal`, `accept_proposal`, `form_coalition`, `reject_and_counter`
- `vision=-1` - full-room awareness with no spatial grid
- `DataCollector` - tracks proposals, acceptances, average pledge, coalition size, treaty status per round

Contributor guide

Open the contributing guide

Research direction

Review the existing examples in the llm/ directory and the mesa-llm APIs used there before adding the climate negotiation simulation. The example should cover six negotiating country agents, the listed memory, reasoning, messaging, tool, vision, and DataCollector features, and report treaty status across rounds.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
ai
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.