Abstract
Multi-agent reinforcement learning (MARL) faces a significant challenge in the "combinatorial explosion" of action spaces as the number of agents increases. This often leads to algorithmic instability and poor convergence. We present eSpark (Evolutionary action SPAce Reduction with Knowledge), a framework that utilizes Large Language Models (LLMs) to automatically generate and refine exploration functions that prune redundant or suboptimal actions. By leveraging the reasoning capabilities of LLMs, eSpark identifies irrelevant state-action pairs in a zero-shot manner and improves autonomously through policy feedback. Our evaluation across 15 scenarios in inventory management and traffic control demonstrates that eSpark consistently outperforms standard MARL algorithms, achieving average performance gains of up to 34.4% and maintaining scalability for systems with over 500 agents.
Introduction
In complex multi-agent environments, agents must learn to coordinate to achieve global objectives. However, as the agent count grows, the joint action space expands exponentially—the "curse of dimensionality." While humans intuitively ignore illogical actions based on prior knowledge, standard RL agents must learn these constraints from scratch through trial and error. Previous attempts to prune action spaces relied on manual, task-specific heuristics, which are difficult to scale. eSpark addresses this by using LLMs to translate high-level task descriptions into executable Python-based "exploration functions" that mask irrelevant actions, effectively guiding the agents toward more promising regions of the search space.
The eSpark Framework
The eSpark framework integrates LLMs into the MARL training loop through a three-stage evolutionary process:
- Exploration Function Generation: A "Generator" LLM receives a zero-shot prompt describing the environment rules and goals. It produces a set of Python functions that act as binary action masks, hiding actions that are logically harmful or irrelevant given the current state.
- Evolutionary Search: To account for potential logic errors in LLM-generated code, eSpark generates a batch of $K$ candidate functions. These are tested in parallel MARL training sessions to identify the most effective pruning strategy.
- Reflection and Feedback: A "Checker" LLM validates the code for syntax and logic errors. Subsequently, a reflection loop allows the LLM to analyze performance feedback (e.g., specific cost metrics) to refine the pruning rules for the next iteration.
A critical component of this framework is Retention Training, which allows agents to maintain learned knowledge when transitioning between different pruning functions across evolutionary cycles, preventing the need to restart the learning process from scratch.
Experimental Evaluation
We evaluated eSpark on two high-dimensional industrial simulators:
- MABIM (Multi-Agent Benchmark for Inventory Management): A supply chain environment where agents manage stock-keeping units across multiple warehouse echelons. Scenarios involved between 100 and 1,500 agents.
- SUMO (Simulation of Urban MObility): A traffic signal control simulator tested on both synthetic grids and real-world maps (e.g., Cologne and Ingolstadt).
Key Results
eSpark demonstrated superior performance and robustness across all tested scenarios. In the MABIM benchmark, it achieved an average profit increase of 34.4% over the base IPPO algorithm and outperformed specialized heuristic pruning methods. In traffic control tasks (SUMO), eSpark reduced average delay and waiting times by approximately 9.9%.
Notably, the framework showed exceptional scalability. In a massive 500-agent MABIM scenario where standard decentralized RL methods typically struggle to converge, eSpark secured a 29.7% improvement in performance. This confirms that "knowing what not to do" is a powerful mechanism for managing high-dimensional complexity.
Discussion and Insights
The success of eSpark highlights the potential of LLMs as "common sense" filters for reinforcement learning. By identifying basic constraints (e.g., "do not restock if the warehouse is full"), the LLM allows the RL agent to focus its exploration on optimizing complex coordination strategies. The inclusion of a "Checker" LLM was found to be essential, as it significantly improved the reliability of the generated code by catching logical inconsistencies before they impacted training.
While highly effective for homogeneous agents, future work will focus on extending eSpark to heterogeneous environments where agents have distinct roles and require specialized pruning functions. Additionally, improving the reflection mechanism for sparse-reward environments remains a key area for development.
Conclusion
eSpark represents a significant step toward autonomous, knowledge-driven MARL. By automating the design of action space constraints, it removes a major bottleneck in the deployment of multi-agent systems to complex, real-world industrial tasks.
Summary updated