Concurrency Model of BDI Programming Frameworks: Why Should We Control It?

Martina Baiardi, Samuele Burattini, Giovanni Ciatto, Danilo Pianini, Andrea Omicini, Alessandro RicciarXiv 2024

This paper, an extended abstract from AAMAS 2024, explores the often-overlooked "plumbing" of multi-agent systems: how Belief-Desire-Intention (BDI) frameworks handle concurrency. The authors propose a new taxonomy for these models and evaluate how popular BDI technologies stack up, arguing that developers need more control over how agents are mapped to hardware resources.

TL;DR

The paper introduces a taxonomy of "external" concurrency models for BDI frameworks, highlighting the trade-offs between raw performance and execution determinism. By analyzing six major BDI technologies, the authors reveal a lack of customizability and argue for a strict separation between agent logic and its underlying execution model.

What Problem Does This Paper Address?

BDI agents are designed to be autonomous and capable of handling multiple "intentions" (tasks) at once. While researchers have spent decades defining how an individual agent interleaves these intentions (internal concurrency), they often ignore external concurrency: how a system of many agents is mapped onto the underlying operating system primitives like threads, processes, or event loops.

Currently, most BDI frameworks hide these details "under the hood." This is a problem because different applications have conflicting needs. A high-performance MAS might need maximum parallelism, while a scientific simulation requires strict determinism to ensure results are reproducible. Without explicit control over the concurrency model, developers are stuck with whatever trade-offs the framework designers chose for them.

Methods

The authors developed a taxonomy of five primary external concurrency models:

  1. One-Agent-One-Thread (1A1T): Simple but scales poorly and lacks determinism.
  2. All-Agents-One-Thread (AA1T): Perfectly deterministic (no parallelism) but slow on multi-core systems.
  3. All-Agents-One-Event-Loop (AA1EL): Similar to AA1T but uses a task queue for fairness.
  4. All-Agents-One-Executor (AA1E): Agents share a pool of threads. This offers a balance of control and performance.
  5. One-Agent-One-Process (1A1P): Useful for distributed systems where agents don't share memory.

To see how these models are used in the wild, the authors analyzed six active BDI technologies: Jason, Astra, JaKtA, Phidias, Spade-BDI, and Jadex. They combined source code analysis with empirical benchmarks—running MAS instances and counting active threads—to verify the actual behavior of each framework.

Datasets

As a taxonomy and survey paper, it does not use a traditional training dataset. Instead, the "subjects" of the study are the source code and runtime behavior of the six BDI frameworks mentioned above.

Key Insights and Ideas

  • The Determinism-Performance Trade-off: There is no "one size fits all" model. AA1T is essential for debugging and reproducible simulations, while AA1E is generally superior for production environments because it allows developers to cap the total thread count.
  • AA1E is the "Sweet Spot": The authors highlight that "All-Agents-One-Executor" is technologically preferable to "One-Agent-One-Thread" because it provides finer control over parallelism without the overhead of creating thousands of OS threads.
  • The Need for "Late Binding": A key recommendation is that the MAS specification (the "what") should be separate from the concurrency model (the "how"). Ideally, a developer should write their agent logic once and choose the execution model at launch time based on the environment.

Key Results

The analysis revealed that support for different concurrency models is highly heterogeneous across the industry.

Table 1: Comparison of BDI technologies and their supported concurrency models. Checkmarks indicate out-of-the-box support, while asterisks indicate customizability.

As shown in Figure 1:

  • Jason and JaKtA emerged as the most flexible frameworks, supporting or allowing customization for almost all models in the taxonomy.
  • Phidias and Spade-BDI are more rigid, favoring specific models (like 1A1T or 1A1P) that align with their underlying languages (Python/XMPP).
  • Jadex focuses heavily on thread pools (AA1E) and single-threaded execution (AA1T), skipping the more basic 1A1T approach.

Limitations and Future Work

The authors acknowledge that this is an initial study. While they have provided a taxonomy and a snapshot of the current landscape, they suggest that more work is needed to develop a "general concurrency blueprint" for BDI technologies. Future research could involve deeper performance profiling to quantify exactly how much overhead different models introduce in large-scale agent systems.

Summary updated

Abstract

We provide a taxonomy of concurrency models for BDI frameworks, elicited by analysing state-of-the-art technologies, and aimed at helping both BDI designers and developers in making informed decisions. Comparison among BDI technologies w.r.t. concurrency models reveals heterogeneous support, and low customisability.
BibTeX
@misc{baiardi2024concurrency,
  author = {Martina Baiardi and Samuele Burattini and Giovanni Ciatto and Danilo Pianini and Andrea Omicini and Alessandro Ricci},
  title = {{Concurrency Model of BDI Programming Frameworks: Why Should We Control It?}},
  year = {2024},
  eprint = {2404.10421},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2404.10421},
}

Loading related content...

Figure