BEACOF: Belief-Driven Multi-Agent Collaboration
January 21, 2026 ยท View on GitHub
Official implementation for the paper: > Belief-Driven Multi-Agent Collaboration via Approximate Perfect Bayesian Equilibrium for Social Simulation > Weiwei Fang, Lin Li, Kaize Shi, Yu Yang, and Jianwei Zhang > The Web Conference (WWW) 2026
๐ Overview
High-fidelity social simulation demands agents capable of authentically replicating the dynamic spectrum of human interaction. Current Multi-Agent Systems (MAS) often adhere to static interaction topologies, leading to "groupthink" (in pure cooperation) or deadlocks (in pure competition).
BEACOF (Belief-Driven Adaptive Collaboration Framework) is a novel framework that models social interaction as a dynamic game of incomplete information. Inspired by Approximate Perfect Bayesian Equilibrium (PBE), BEACOF enables agents to:
- Maintain Beliefs: Iteratively refine probabilistic beliefs about peer capabilities based on interaction history.
- Adaptive Strategy: Autonomously switch between Cooperation, Competition, and Coopetition (collaborative competition).
- Ensure Rationality: Make sequentially rational decisions under uncertainty without needing full information.

๐ Key Features
- Dynamic Strategy Switching: Agents are not fixed to a single role; they transition dynamically between cooperative knowledge synthesis and competitive critical reasoning.
- Gaussian Belief Updates: Implements a tractable parametric Bayesian update mechanism with a forgetting factor to track non-stationary peer capabilities.
- Meta-Agent Coordination: A centralized coordinator estimates contextual payoffs and evaluates message quality to drive belief evolution.
- Multi-Scenario Generalization: Validated across three distinct social interaction archetypes:
- โ๏ธ Adversarial: Judicial/Court Debate.
- ๐ฅ Mixed: Medical Q&A (MedQA).
- ๐ฃ๏ธ Open-Ended: Persona-based Social Chat.
๐ ๏ธ Installation
Prerequisites
- Python 3.9+
- Ollama (for local LLM inference as described in the paper)
Setup
-
Clone the repository
git clone [https://github.com/WUT-IDEA/BEACOF.git](https://github.com/WUT-IDEA/BEACOF.git) cd BEACOF -
Install dependencies
pip install -r requirements.txt -
Model Setup (Ollama) Ensure you have the backbone models pulled via Ollama. We utilize the following models in our experiments:
ollama pull llama3.1 ollama pull gemma2:9b # (Check specific tag for Gemma3 equivalent) ollama pull qwen2.5:32b # (Check specific tag for Qwen3 equivalent)
๐ Project Structure
BEACOF/
โโโ data/
โโโ src/
โ โโโ AgentsCourt/
โ โโโ mechanism/
โ โโโ prompts/
โ โโโ interaction.py # Entry point for simulations
โ โโโ ollama.py
โโโ README.md
๐ Usage
You can run simulations for different scenarios using main.py.
Start Simulation
# 1. Court Debate Simulation
python main.py court
# 2. Medical Consultation Simulation
python main.py medqa
# 3. Daily Chat Simulation
python main.py persona
๐งฉ Methodology Highlights
The Loop
- Payoff Generation: The Meta-Agent generates contextual payoffs based on interaction history.
- Action Prediction: Probability distributions over collaboration types are predicted.
- Strategic Action: Participant agents calculate an approximate Best Response () maximizing expected utility.
- Belief Update: Agents update Gaussian beliefs about peers using the evaluation and confidence , modulated by a forgetting factor .
Equation: Belief Update
๐ Citation
If you find this code or our paper useful, please cite:
@inproceedings{fang2026beacof,
title={Belief-Driven Multi-Agent Collaboration via Approximate Perfect Bayesian Equilibrium for Social Simulation},
author={Fang, Weiwei and Li, Lin and Shi, Kaize and Yang, Yu and Zhang, Jianwei},
booktitle={Proceedings of the ACM Web Conference 2026 (WWW '26)},
year={2026},
publisher={ACM},
address={Dubai, United Arab Emirates}
}
๐ง Contact
For any questions, please contact:
- Weiwei Fang:
311137@whut.edu.cn - Lin Li:
cathylilin@whut.edu.cn