학술

Multi-AGV cooperative scheduling in smart greenhouses via Hungarian-guided MAPPO with adaptive weighted A* priors

PLOS ONE
CC BY
이 매체는 공공·자유 라이선스로 본문을 직접 표시합니다.

Figures
Abstract
In response to the challenges of load imbalance, high collision rates, and slow convergence exhibited by the original MAPPO algorithm during collaborative inspection tasks involving multiple autonomous guided vehicles (AGVs) in narrow greenhouse environments, this work proposes an enhanced MAPPO framework that integrates Hungarian-based global task allocation with an adaptive weighted A* path planning module. Grounded in the centralized training with decentralized execution (CTDE) paradigm, a “perception–decision–execution” three-layer Markov decision process (MDP) architecture is established: (i) the Hungarian algorithm computes optimal task–agent assignments under dynamically updated cost-function constraints; (ii) the adaptive weighted A* algorithm generates risk-aware, collision-avoidant trajectories that adapt in real time to environmental congestion; and (iii) both the resulting task allocations and associated path-level risk metrics are encoded as prior features and injected into the policy network. Furthermore, a joint loss function is formulated to jointly optimize task allocation cost and path risk.Comparative experiments were conducted against the original MAPPO, MADDPG, IPPO, DQN, genetic algorithm (GA), and standard A* across nine baseline scenarios with varying gradient complexity (involving 3, 5, and 8 AGVs) and ten extended high-complexity scenarios with 10 AGVs. Results demonstrate that the proposed method reduces collision frequency by 68.3%, accelerates convergence by a factor of 3.1 × , and achieves a robust task completion rate of 97.8 ± 0.9% even under high-complexity conditions. Ablation studies confirm the synergistic benefits arising from the integration of Hungarian allocation and the adaptive weighted A* path module. Finally, physical validation using three AGVs in a ROS-based laboratory environment verifies the fundamental feasibility of the approach; further field validation in an operational greenhouse setting remains ongoing.
Citation: Zhang K, Yang F (2026) Multi-AGV cooperative scheduling in smart greenhouses via Hungarian-guided MAPPO with adaptive weighted A* priors. PLoS One 21(12): e0363865. https://doi.org/10.1371/journal.pone.0363865
Editor: Jinhao Liang, National University of Singapore, SINGAPORE
Received: September 21, 2026; Accepted: November 13, 2026; Published: December 1, 2026
Copyright: © 2026 Zhang, Yang. This is an open access article distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original author and source are credited.
Data Availability: All simulation code, training scripts, and the minimal dataset required to replicate the findings are publicly available at: https://github.com/mudacang/agri_multi_robot_mappo.
Funding: This work was supported by the High‑Level Talent Research Startup Project of Hechi University (Grant No. 2024GCC001). The funder provided support in the form of salaries for authors [KRZ, FY], but did not have any additional role in the study design, data collection and analysis, decision to publish, or preparation of the manuscript. The specific roles of these authors are articulated in the ‘Author contributions’ section.
Competing interests: The authors have declared that no competing interests exist.
1 Introduction
The global trend toward agricultural digitalization is accelerating rapidly, and the practical demand for multi-AGV collaborative inspection in facility-based greenhouses is growing increasingly urgent [1]. Task allocation and path planning constitute two core determinants of system performance. Greenhouse environments—characterized by confined spatial dimensions, densely distributed obstacles, and dynamically evolving task requirements—impose stringent demands on multi-robot collaborative scheduling. Significant progress has been made in multi-agent cluster collaborative control for intelligent vehicles and mobile robots [2,3], offering valuable methodological insights for greenhouse AGV scheduling.
Regarding task allocation, existing approaches primarily fall into two categories: global optimization and distributed methods. Global optimization techniques—such as the Hungarian algorithm and genetic algorithms—can yield static optimal solutions [4–6]; however, they require repeated recomputation under dynamic task conditions, leading to substantial computational overhead [7,8]. In contrast, distributed methods—including the auction algorithm and the contract net protocol—exhibit strong scalability [9–11], yet remain susceptible to convergence toward suboptimal local solutions. In recent years, reinforcement learning has begun to be explored for task allocation; nevertheless, most current implementations still rely on random assignment or rudimentary heuristic rules, lacking effective mechanisms for guiding solutions toward global optimality.
With respect to path planning, classical algorithms—such as Dijkstra’s and A*—demonstrate robust performance in static, pre-mapped environments. However, in greenhouse settings where obstacle configurations change frequently, these methods necessitate frequent global replanning, thereby compromising real-time responsiveness. Although certain studies have incorporated enhancements such as the dynamic window approach and time-window constraints, effective conflict resolution and coordinated path generation in multi-agent scenarios remain inadequately addressed [12,13].
Multi-agent reinforcement learning (MARL), exemplified by the Multi-Agent Proximal Policy Optimization (MAPPO) algorithm, demonstrates outstanding dynamic adaptability [14–16]. However, in confined greenhouse environments—where global prior information is inherently limited—MAPPO is susceptible to several critical challenges, including load imbalance, elevated collision rates, and prolonged convergence times. Moreover, existing studies seldom achieve effective integration of classical optimization techniques with reinforcement learning, thereby struggling to simultaneously guarantee solution optimality, adaptive responsiveness, and real-time execution performance [17–19].
In contrast to conventional hierarchical scheduling frameworks—which adopt a rigid, unidirectional pipeline wherein task allocation, path planning, and execution are performed sequentially—this work does not merely cascade the Hungarian algorithm, weighted A*, and MAPPO as isolated components. Instead, it directly incorporates the outcomes of global task allocation and path-risk priors into the observation space of the reinforcement learning agent. This design enables the agent to perceive both the holistic task distribution and real-time path congestion, thereby dynamically refining local actions. Consequently, a closed-loop, bidirectional interaction is established between the combinatorial optimization module and the reinforcement learning policy—replacing the static, feedforward pipeline with an adaptive, feedback-driven architecture.
Accordingly, this paper proposes an enhanced MAPPO algorithm that synergistically integrates the Hungarian algorithm for global task allocation and weighted A* for path-risk-informed trajectory generation. The resulting framework adopts a three-tier “perception–decision–execution” architecture. Built upon the centralized training with decentralized execution (CTDE) paradigm, it embeds globally optimized prior solutions into the policy network to provide stable, interpretable guidance during training. Furthermore, an adaptive variant of weighted A* is introduced to generate safety-aware paths; collision penalties and distribution-smoothing mechanisms are explicitly incorporated to significantly enhance system safety and improve load balancing across agents [20–22].
The main contributions of this paper are as follows: (1) An improved MAPPO method integrating Hungarian global assignment and weighted A* path priors is proposed, achieving effective integration of traditional optimization algorithms and reinforcement learning; (2) A joint loss function that accounts for both assignment cost and path risk is designed to alleviate the load imbalance and slow convergence problems of MAPPO in narrow greenhouse environments; (3) Collision penalty and assignment smoothing mechanisms are introduced to enhance the operational safety of multi-robot cooperative operations.
The remaining parts of this article are arranged as follows: Section 2 introduces the problem description and algorithm improvement; Section 3 presents the simulation experiments and result analysis; Section 4 discusses the issues mentioned; Section 5 summarizes the entire article and looks forward to future work.
2 Problem description and algorithm improvement
2.1 Problem description
Taking smart greenhouse multi-AGV cooperative inspection as the research scenario [23–25], and incorporating practical operational constraints, this study clarifies the problem definition, constraints, and evaluation metrics, thereby establishing a unified framework for algorithm design and simulation. The core parameters and constraint rules are presented in Table 1.
2.2 Construction of task dataset
To achieve joint optimization of task allocation and path planning, a standardized, encodable, and reproducible greenhouse inspection task dataset is constructed, with the core definitions presented in Table 2.
When any of the following conditions are met, the Hungarian re-allocation is triggered: ①A new task is activated; ②An AGV malfunctions; ③The distribution of obstacles undergoes a significant change (the proportion of high-risk grids changes by more than threshold Th; ④The variance of the current task allocation load exceeds threshold Tv. If none of the triggering conditions are met, the previous allocation result will remain unchanged.
2.3 Markov decision process modeling
By adopting the hierarchical decoupling MDP modeling approach, the entire decision-making process is divided into three layers: the high-level task selection layer, the intermediate path planning guidance layer, and the low-level AGV action control layer. The multi-AGV cooperative decision-making is modeled as a Markov decision process represented by a six-tuple , where S denotes the state space, G denotes the action space, O denotes the local observation space, P denotes the state transition function, R denotes the global reward function, and π denotes the agent policy.
High-level task selection layer: Hungarian module outputs AGV tasks for matching, determining the target task position for each AGV;
Intermediate path planning guidance layer: Adaptive weighted A* generates paths based on the allocation results and outputs the prior risk characteristics of the paths;
Low-level action control layer: The task allocation+path prior encoding is sent to the MAPPO Actor network, the Actor outputs 6 discrete low-level motion instructions to complete tracking of the path and obstacle avoidance. The high-level logical variables of MDP are the target task position, which is only used as prior input observation, and the actual output of the Actor network is 6-dimensional discrete motion actions, not directly outputting the task position.
State Space:
(1)This Lt,i represents the position of AGV i, and T is the global task code.
The high-level decision variable is the target task location. The underlying output of the Actor network is a 6-dim(ensional discrete motion action (up, down, left, right, inspection, fertilization).
Action Space:
(2)This gt,i indicates the target location of the task.
Local observation:
(3)Among them, represents the observation of grid obstacles around the i-th agent, represents the task observation within the local range of the i-th agent, represents the observation of the positions of other agents within the local range of the i-th agent, and is the Hungarian task allocation feature vector; is the path prior feature vector output by adaptive weighted A*, which is the output of the complete path node sequence of A*; for each node, it extracts the node risk coefficient, the remaining steps to reach the target, and performs normalization, then concatenates them into a fixed-dimensional vector and inputs it into the Actor network as an observation to assist in the dynamic adjustment of the global task allocation.
State transition:
(4)Among them, represents the probability of the agent’s position transfer, represents the probability of the task state transition, and represents the probability of the obstacle state transition (when it is a static obstacle, this probability is 1), which is the triggering condition for the re-decision that affects task allocation.
Global reward:
The global reward function is used to guide the optimization of the strategy, integrating multiple evaluation indicators. The mathematical expression is as follows:
(5)Among them, represents the reward weight, represents the task completion reward, represents the path length penalty, represents the collision penalty, and represents the task allocation balance reward, which is directly related to the balance of task allocation.
Strategic objective:
(6)Here, θ represents the strategy parameter and γ represents the discount factor.
2.4 Overall plan for improving the algorithm
The Hungarian global allocation algorithm and weighted A* path planning were embedded into the MAPPO CTDE framework. Through allocation encoding, path prior injection, and joint loss optimization, a “perception - decision - execution” three-layer collaborative architecture was established. The overall architecture is shown in Fig 1.
The environment and state perception layer uniformly encodes the environment, AGV status, global tasks, and conflict risk information, and outputs the global state vector for the Critic network and the local observation vector for the Actor network, constructing a unified information base. The core layer of global decision optimization no longer outputs results in a one-way manner. It redistributes and path risk information back to the reinforcement learning module to achieve closed-loop interaction. The core layer of global decision optimization completes global optimal task allocation through the Hungarian module and generates conflict-free safe paths using the adaptive weighted A* module. The strategy learning and execution layer continues to use the MAPPO’s CTDE framework; the Actor network receives local observations, encoded allocation results, and path guidance encoding to output actions; the Critic network performs value evaluation based on the global state, constrains the direction of strategy exploration, and improves the algorithm’s convergence speed and operational safety.
2.4.1 Hungarian task allocation module.
To address the load imbalance and low execution efficiency issues caused by the random allocation of the original MAPPO, the Hungarian task allocation module was introduced, and an integrated cost function was constructed to achieve the global optimal balanced matching between AGVs and inspection tasks under the predefined integrated cost function conditions at the current moment. The module builds an n × m dimensional integrated cost matrix based on the real-time global state and uses the Hungarian algorithm to solve the optimal allocation matrix and task allocation sequence. The allocation results are encoded as feature vectors and input into the Actor network to provide global optimal guidance for policy learning, thereby improving the load balancing performance of the multi-AGV system. The time complexity of the Hungarian algorithm is . When the number of AGVs increases significantly, a computational bottleneck may occur. The experimental scale of this study is controlled at 3–10 AGVs; the incremental Hungarian/approximate allocation for large-scale clusters is a future research direction, as detailed in Section 4 discussion.
The comprehensive cost function is defined as:
(7)In the formula: represents the weighted A * path cost; it is given by ; represents the Manhattan distance, which is given by ; represents the task priority coefficient; the higher the priority, the smaller the cost; represents the obstacle penalty, that is, the more obstacles, the higher the cost. The weights are based on the requirements of the greenhouse business scenario and are calibrated through multiple sets of pre-simulation tests; 3.5 Conduct a sensitivity analysis of the weights to evaluate the sensitivity of the allocation results to each weight parameter. The allocation constraint is . Allocation constraint: Each AGV can be assigned at most one task; Task constraint: One task can only be executed by one AGV; Safety constraint: Tasks in high-risk areas will not be included in the allocation for the time being. The algorithm flow of the task allocation module is shown in Fig 2.
2.4.2 Adaptiveweighted A* Path planning module.
To address the shortcomings of the traditional A algorithm, such as its insufficient adaptability and the high collision rate of the pure MAPPO path, an adaptive weighted A module is designed. The “adaptive” feature is reflected in the fact that the heuristic weight ωh and the node risk weight ωr will be updated online and dynamically according to the density of the grid obstacles and the congestion degree of the surrounding AGVs.
The path cost function is defined as:
(8)In the formula: Here, represents the actual cost from the starting point to the current node, represents the heuristic distance from the current node to the target node, represents the node risk coefficient (calculated based on the obstacle density), α and β are the heuristic weight and risk weight respectively. Calculate the path length and risk characteristics, encode them as the input of the Actor network, and provide safety prior guidance. The flowchart of the path planning module is shown in Fig 3.
2.4.3 Strategy learning and optimization.
The algorithm retains the CTDE framework of MAPPO. The Actor network takes in local observations, task allocation encoding, and path guidance encoding, and outputs the probability distribution of 6 types of discrete actions; before action execution, three checks for obstacles, AGV conflicts, and trajectory tracking are completed. The Critic network performs value evaluation based on the global state and provides guidance for policy optimization.
At the loss optimization level, the task allocation cost, path cost, and global reward are integrated into a unified loss function. Backpropagation updates are completed by combining the PPO Clip loss and the mean square error loss of the Critic network to alleviate training oscillations and accelerate convergence. The complete process of policy learning and execution is shown in Fig 4.
2.5 Performance evaluation index design
Construct the evaluation index system from three dimensions:
- (1) Convergence and stability: The convergence speed is measured by the minimum number of iterations required for the cumulative return to stabilize at 90% of the peak value; the training stability is determined by the standard deviation of returns over 100 consecutive rounds in the training period; the real-time performance of edge deployment is measured by the average time consumed for a single step of reasoning.
- (2) Task allocation efficiency: The level of load balancing is measured by the variance of AGV task allocation times; the global guidance effect is measured by the proportion of the Hungarian optimal allocation; the scheduling computing efficiency is measured by the average time consumed for a single global match.
- (3) Path planning quality and safety: Obstacle avoidance safety is measured by the total number of global collisions; the path economy and search efficiency are measured by the average path length and the number of expanded nodes; the obstacle avoidance rate in high-risk areas verifies the effectiveness of obstacle avoidance guidance; the overall execution efficiency of the system is evaluated by the completion rate within the time limit and the average completion time.
3 Simulation experiments and result analysis
To comprehensively verify the overall performance of the proposed improved MAPPO algorithm and the effectiveness of the “global optimization prior + reinforcement learning” integration architecture, a set of comparative experiments and ablation experiments were designed, strictly following the principles of single-variable control and reproducibility. The simulation scenarios were centered around the core constraints of the smart greenhouse, covering different spatial scales, AGV cluster sizes, obstacle densities, and task scale gradient complexity conditions; all comparative algorithms used exactly the same training environment and core hyperparameters to ensure the rigor and credibility of the experiments.
3.1 Simulation scenario design
A total of 9 simulation scenarios were set up, using 3, 5, and 8 AGVs respectively; the 10 AGV scenario was used as an extended high-complexity test case to further verify the algorithm’s scalability. The scenarios were controlled by 4 core variables: grid map size, number of AGVs, obstacle density, and number of tasks to be executed. The grid sizes were set as 10 × 10, 15 × 15, and 20 × 20, corresponding to local operation areas, single planting areas, and full coverage of the greenhouse respectively; the number of AGVs was set as 3, 5, 8 (the basic 9 scenarios) + 10 (the extended case); the obstacle density was set at 15%, 20%, and 25%, covering the obstacle characteristics of different areas in the greenhouse; the task scale was set as 20, 40, and 100, corresponding to daily inspection, key supplementary measurement, and full coverage inspection respectively.
3.2 Experimental setup
3.2.1. Platform and hyperparameters.
The experiment was implemented using Python 3.8 and PyTorch 1.13; the hardware platform was equipped with an AMD R5 5700X processor and a RTX 3060Ti graphics card; the simulation environment was a self-developed random obstacle grid map system specifically designed for multi-AGV collaboration; the core hyperparameters of the comparison algorithms were uniformly configured as shown in Table 3.
3.2.2 Comparison algorithm.
A variety of mainstream benchmark algorithms were selected for comparison, covering three technical paradigms: policy gradient, value function, and traditional optimization: multi-agent proximal policy optimization (MAPPO), single-agent PPO, multi-agent deep deterministic policy gradient based on deterministic policies (MADDPG), single-agent deep Q-network (DQN), as well as genetic algorithm (GA) and algorithm A. The key parameters of GA and A were tuned using grid search to ensure fair comparison. Currently, the comparison baseline does not include modern multi-agent path planning algorithms such as Conflict-Based Search (CBS); CBS will be added as a benchmark in subsequent simulations to improve the comparison.
3.2.3 Statistical testing methods.
To determine whether the observed performance differences are statistically significant, a paired statistical analysis was conducted based on 50 paired simulation runs. For each comparison, a Shapior-wilk test was first used to assess the normality of the paired differences. When the normality assumption (p > 0.05) was met, a paired t-test was performed; otherwise, a Wilcoxon signed rank test was used. The effect size of the paired t-test was measured using Cohen’sdz. To control the familywise error rate caused by multiple comparisons, the corresponding p-values in each group were corrected using Holm. The significance level was set at α = 0.05. All statistical tests were performed using Python 3.8’s SciPy 1.9 and statsmodels 0.13.
3.3 Comparison of experimental results and analysis
The convergence curves of the average number of tasks completed by each algorithm in different scenarios are shown in Fig 5, the convergence curve of the Actor loss is shown in Fig 6, and the convergence curve of the average reward is shown in Fig 7.
The experimental results show that the improved MAPPO has the best performance across all scenarios, with a stable performance ranking: Improved MAPPO > Original MAPPO ≈ MADDPG > IPPO > DQN > GA > A*, without abnormal fluctuations, and strong cross-scenario generalization ability.
In terms of convergence and training stability, the improved algorithm exhibits a distinct three-stage characteristic: rapid improvement in the early stage, steady growth in the middle stage, and gradual convergence in the later stage. The final performance can be achieved within approximately 50% after the first 100 training rounds; it exceeds 70% after 300 rounds; and achieves stable convergence after 600 rounds, with a small variance. The Critic loss converges the fastest, and the final loss value is reduced by 28% to 35% compared to the original MAPPO, and by approximately 50% compared to DQN. It can reach the cumulative return level of the original MAPPO after only 100 training rounds; in 10 × 10, 15 × 15, and 20 × 20 grid scenarios, the final cumulative return increases by 15%, 20%, and 25% respectively, and there is no policy degradation.
As the complexity of the environment and the task load increase, the performance advantage of the improved algorithm is further amplified. Under low, medium, and high load conditions, the number of tasks completed is 11% to 20% more than that of the original MAPPO, 13% to 20% more than that of the original MAPPO, and 11% to 22% more than that of the original MAPPO. Traditional optimization algorithms (GA, A*) have a task completion rate of less than 35% in high complexity environments; mainstream multi-agent reinforcement learning algorithms show a significant decline in performance under medium and high load conditions: completion rate decreases, collision times increase, and allocation time increases.
To verify the statistical significance of the aforementioned performance differences, paired statistical tests were conducted on three core indicators: task completion rate, average total reward, and average collision count. Taking a 10 × 10 grid, 5 AGVs, and 20 task scenarios as an example, the task completion rate of the improved MAPPO was 9.0 percentage points higher than that of the original MAPPO, and the paired t-test result was significant (t(49) = 8.42, p < 0.001, Holm correction p < 0.001, Cohen’s dz = 1.19); the average total reward increased by 99, and the paired t-test result was significant (t(49) = 6.87, p < 0.001, Holm correction p < 0.001, Cohen’s dz = 0.97); the average collision count decreased by 0.44, and the paired t-test result was significant (t(49) = 7.15, p < 0.001, Holm correction p < 0.001, Cohen’s dz = 1.01).
In a 15 × 15 grid, 8 AGVs, and 40 task scenarios, the task completion rate of the improved MAPPO was 16.0 percentage points higher than that of the original MAPPO (t(49) = 9.24, p < 0.001, Cohen’s dz = 1.31), the average total reward increased by 215 (t(49) = 7.63, p < 0.001, Cohen’s dz = 1.08), and the average collision count decreased by 1.38 (t(49) = 8.96, p < 0.001, Cohen’s dz = 1.27). In a 20 × 20 grid, 10 AGVs, and 100 task scenarios, the task completion rate of the improved MAPPO was 32.0 percentage points higher than that of the original MAPPO (t(49) = 11.45, p < 0.001, Cohen’s dz = 1.62), the average total reward increased by 1050 (t(49) = 9.82, p < 0.001, Cohen’s dz = 1.39), and the average collision count decreased by 3.67 (t(49) = 10.27, p < 0.001, Cohen’s dz = 1.45). The p-values of all Shapiro-wilk comparisons were greater than 0.05, satisfying the normality assumption; after correction, all p-values were still less than 0.001, indicating that the performance advantage of the improved algorithm is statistically significant, and the effect size was greater than 0.8, belonging to a large effect.
The comparison of core indicators of each algorithm under different complexity scenarios is shown in Table 4. Under low complexity conditions, the completion rate of the improved MAPPO task was 99.2 ± 0.5%; under high complexity, it still remained at 97.8 ± 0.9%, and the advantage became more significant as the complexity increased. Although the traditional algorithm had a lower number of collisions, even under low complexity scenarios, the task completion rate was not satisfactory, and the performance significantly declined under medium and high complexity; the mainstream multi-agent reinforcement learning methods outperformed the traditional baseline, but they had deficiencies such as insufficient completion rate, many collisions, and large allocation delay in high-load scenarios.
3.4 Results and analysis of the ablation experiment
A total of 4 variants were set up for the ablation experiment:
V1 (Baseline MAPPO): The original MAPPO, without Hungarian assignment module, without adaptive weighted A* path prior;
V2 (w/o Hungarian): Remove the Hungarian task assignment module; retain the adaptive weighted A* path prior; the tasks are randomly assigned;
V3 (w/o adaptive weighted A prior): Retain the Hungarian task assignment module; remove the path risk prior feature;
V4 (Full proposed method): The complete algorithm, Hungarian task assignment + adaptive weighted A* path prior, which is the improved MAPPO proposed in this paper.
The ablation experiment results based on the original MAPPO are shown in Fig 8. Under the unified hyperparameter configuration, Proposed MAPPO has achieved significant advantages in task completion rate and reduction of Actor Loss. This strongly validates that introducing “Hungarian global allocation + weighted A* path prior” can effectively improve the collaborative decision-making performance of the model in random obstacle grid maps.
To evaluate the generalization capability of the proposed architecture, ablation studies were conducted across low, medium, and high complexity scenarios (Figs 9–11). The complete model (V4) consistently outperforms the baseline (V1) and single-module variants (V2 and V3) in terms of order throughput, global reward, and collision performance. Notably, the performance gap widens as environmental complexity increases, demonstrating the robust synergistic effect of the dual-module design.
In low-complexity scenarios, the task completion rate of V4 is 9.8% higher than that of V1, the total return is 11.2% higher, and the collision rate is 35.2% lower. For medium-complexity tasks, the completion rate is 21.2% higher, and the collision rate is 48.2% lower. For high-complexity tasks, the completion rate is 50.5% higher, the total return is 36.8% higher, the collision rate is 65.3% lower, and the convergence speed is faster with less fluctuation. The combined benefits of the dual modules are greater than the simple linear superposition of the single module. Both complement and collaborate with each other in terms of load balancing and path security, and the greater the complexity of the environment, the more obvious the synergy gain. Quantitative evidence proves the rationality and superiority of the dual-prioritization fusion architecture.
3.5 Weight sensitivity simulation analysis
For the multiple sets of manually set weights within the cost function and reward function, multiple parameter scanning simulations were conducted.The was changed respectively, and the changes in task completion rate, collision frequency, and variance of load balancing indicators were observed.
The results show that when the weights change within a reasonable range, the overall performance of the algorithm remains stable; when the weights are extremely unbalanced, there will be severe load imbalance or obstacle avoidance failure phenomena. The weight combination finally adopted in this paper comprehensively considers the task completion efficiency, collision safety, and load balancing. The complete sensitivity results will be supplemented in the supplementary materials S1 text of the revised manuscript.
3.6 Physical platform demonstration experiment
This paper builds a multi-robot experimental platform consisting of three identical RIKIBOT differential AGVs based on Ubuntu 18.04 and ROS Melodic. The experimental robots are equipped with Jetson Nano onboard computing units and run the Ubuntu 18.04 system and ROS Melodic version as the ROS node controllers for the robot end. The underlying driver board uses the STM32F103RCT6 chip, with an onboard MPU6050 IMU gyroscope sensor, supporting 4 DC motor closed-loop drive control, one ultrasonic sensor control, two servo motor drive control, and communicating with the upper-level master controller via ROSSerial protocol. The experimental robots are equipped with Silean A1/A2 two-dimensional laser radars, achieving a range of 12 meters, a scanning frequency of 5.5 Hz, and a measurement frequency of 8000 times per second, suitable for indoor SLAM mapping and navigation obstacle avoidance applications; at the same time, an OBI Zhongguang Astra Pro depth camera is also equipped, with a depth field of 58.4° × 45.5° and a depth resolution of 1280 × 1024, and a RGB frame rate of 30 fps, with a resolution of 1280 × 720. High-precision positioning is achieved through extended Kalman filtering to fuse data from multiple sensors, and autonomous obstacle avoidance and motion control are completed using the move_base navigation framework. Physical experiments have phenomena such as odometer drift and wheel slipping; this experiment repeatedly conducts multiple trials to statistically calculate the position error at the destination point (see Table 5) as a quantitative indicator of drift; long-term continuous operation suppresses cumulative drift and position recovery strategies, which will be included as subsequent research content.This experiment was conducted in a smooth indoor floor environment measuring 2.3 meters by 4 meters.This environment can reproduce some core features of a greenhouse, such as the narrow passageways and the arrival of dynamic tasks. However, there are still significant differences from the real greenhouse environment: the ground is flat without any soil, there are no crops to block the view, and there are no complex agricultural site sensor interferences. This physical experiment is used to verify the feasibility of the basic logic of the algorithm.The performance of the algorithm in real greenhouses (with uneven ground, vegetation obstruction, and complex debris) needs to be verified through subsequent on-site experiments.Before the experiment, the robot was standardized and calibrated to effectively suppress the motion positioning error. At the same time, an environment grid map was constructed based on the Cartographer 2D laser SLAM algorithm. The experimental data was recorded throughout using rosbag for offline analysis and trajectory reproduction.
This paper set up three scheduling strategies for comparison experiments: the improved MAPPO, the original MAPPO, and the traditional FCFS. The same experimental scene, task points, and robot initial state were used. Due to physical environment disturbances such as wheel skidding, odometer drift, and communication delay, the experimental indicators showed reasonable deterioration compared to the simulation results. The physical comparison test results of the three algorithms are shown in Table 5.
Quantitative data show that the proposed improved algorithm can significantly shorten the task completion time, increase the task completion rate, greatly reduce the number of path conflicts among multiple robots, effectively optimize the load balance of multiple machine tasks, and the average arrival error of task positions is only 0.11 m, meeting the accuracy requirements for agricultural inspection operations. The visualized results of the multi-machine trajectories obtained through offline replay of rosbag are shown in Fig 12. The red, green and blue curves correspond to AGV1, AGV2 and AGV3 respectively, and the yellow dots represent the preset inspection task points.
The actual operation conditions of multi-AGV dynamic collaborative obstacle avoidance are shown in Fig 13. The visualization results indicate that the improved MAPPO algorithm can enable multiple robots to perform orderly division of labor and autonomous obstacle avoidance. In narrow passages, there is no collision, no deadlock, and no unnecessary detours. The experimental results of the physical device are highly consistent with the simulation results, demonstrating the feasibility of the proposed scheduling logic under laboratory conditions; the engineering applicability remains to be verified in future on-site experiments of this algorithm in real physical scenarios.
This image is an original photograph taken by the authors and is published under the Creative Commons Attribution License (CC BY 4.0)
4 Discussion
This study proposes an improved MAPPO framework that integrates Hungarian task allocation and adaptive weighted A* path prior, specifically for the multi-AGV inspection collaborative scheduling scenario in smart greenhouses. Simulation experiments show that this method can effectively reduce the frequency of collisions between multiple agents, improve the imbalance of cluster load, and significantly accelerate the model training convergence speed; a small-scale indoor physical platform further verified the basic feasibility of this scheduling scheme. Although the algorithm in this paper achieves good performance in complex multi-gradient simulation environments and laboratory physical conditions, there are still some idealized assumptions in modeling abstraction, simulation environment setting, and physical experiment conditions. This section discusses the boundaries of these assumptions, the choices made in this study, and the future expandable research directions.
- Simplification of robot kinematic modeling. The core research objective of this study focuses on upper-level task allocation and multi-agent reinforcement learning scheduling strategies. The simulation environment adopts a discrete grid abstraction and does not explicitly introduce the incomplete kinematic constraints and minimum turning radius of differential AGVs, which are the underlying motion characteristics. During the physical verification stage, the robot’s underlying motion control is accomplished by the ROS move_base navigation stack, which compensates for the differences between simulation and real motion. Future work can directly embed the incomplete kinematic constraints into the Markov Decision Process (MDP) to further narrow the gap between the simulation model and the actual robot’s motion behavior.
- The computational scale bottleneck of the Hungarian algorithm. The time complexity of the Hungarian task allocation algorithm is . When the number of AGVs expands to several dozen in a commercial greenhouse cluster scenario, it will bring significant computational costs. This research experiment is scaled to 3–10 AGVs, which can meet the requirements of small and medium-sized greenhouse inspection scenarios. For large-scale clusters, subsequent incremental Hungarian or approximate task allocation strategies can be introduced to reduce computational complexity and improve algorithm scalability.
- The limitations brought by the serial decoupling of task allocation and path planning. The current architecture adopts a serial process of first task allocation and then path generation. During the allocation stage, only distance risk heuristic information is relied upon, which cannot fully predict potential trajectory conflicts among multiple AGVs in the subsequent stage. This paper alleviates this defect by embedding path risk priori in the reinforcement learning observation space to some extent, but it has not achieved the joint solution of allocation and trajectory. Future research can study the joint optimization framework of task allocation and trajectory conflict to further reduce the potential conflict risks in the pre-allocation scheme.
- Dynamic obstacle modeling method. In the simulation, dynamic obstacles are simplified as randomly generated static blocking grids, without simulating continuous moving obstacles such as mobile personnel and agricultural machinery in the agricultural field. This simplification can test the algorithm’s robustness in static/sudden blocking scenarios, but there is still a gap compared to the real greenhouse dynamic environment. Further research can introduce motion prediction models to predict the trajectories of moving obstacles and improve the simulation of the dynamic environment.
- Constraints of physical experiment environment. The physical verification is all completed in a flat and smooth indoor laboratory, only reproducing some key features such as narrow passageways in the greenhouse and dynamic task arrivals; the experimental environment lacks typical conditions of a real greenhouse: uneven muddy ground, crop branches and leaves blocking, and interference from field debris. Therefore, the physical results can only prove the logical feasibility of the algorithm, but cannot directly equate to the performance of the real greenhouse site. Future plans include conducting field greenhouse site experiments to further verify.
- Centralized architecture communication assumption. This framework relies on centralized modules to obtain the global environment and the robot’s status. The experimental process assumes that the communication link is continuously stable and does not consider common problems in industrial sites such as network latency and data packet loss. Subsequent research can focus on decentralized scheduling architecture, and introduce communication noise and packet loss conditions to conduct robustness tests, which will be more in line with on-site deployment conditions.
- Simplification of inspection task model. The inspection task in the article is simplified to the robot’s short stop at the target grid position. It does not consider the adjustment of the mechanical arm’s posture, the duration of sensor shooting, and the timing constraints of image acquisition. This research focuses on solving the scheduling problem at multiple AGV levels. The mechanical operation and sensor timing constraints can be regarded as subsequent extension contents, and the above constraints can be incorporated into the task modeling.
- Manual selection of weight parameters. The cost function and reward function contain multiple sets of manually set weights. This paper also conducts a weight parameter scanning simulation to complete the parameter sensitivity analysis, and the relevant simulation results are placed in Supplementary Material S1 text. Future work can explore adaptive parameter tuning mechanisms to reduce the reliance of the algorithm on manual hyperparameter tuning.
- Selection of benchmark algorithms. In the comparative experiments, this paper selects mainstream baselines such as MAPPO, MADDPG, IPPO, DQN, GA, A *, but has not yet included conflict search CBS, which is a specialized multi-agent path planning algorithm. CBS focuses more on solving the optimal path in a static environment, while this paper focuses on dynamic and uncertain greenhouse scheduling driven by reinforcement learning. In subsequent simulation experiments, CBS will be added as a comparative baseline to improve the evaluation of benchmark algorithms.
- Dynamic re-allocation trigger conditions. This paper has defined quantitative threshold conditions for dynamic task re-allocation. When new tasks are generated, AGV malfunctions occur, the environment is subject to drastic changes, or the load variance exceeds the limit, the Hungarian re-allocation will be triggered. Further research can also be conducted on the adaptive adjustment strategy of thresholds to allow the re-allocation conditions to automatically change according to the congestion degree of the environment.
- Physical platform positioning drift problem. The quantitative statistical results of the position error of the task point obtained from multiple repeated experiments in physical experiments can reflect the impact of positioning drift. However, this study did not deeply investigate the drift suppression and position recovery strategies under long-term continuous operation. In the future, relevant research on positioning drift compensation can be focused on scenarios of long-term inspection.
- twelve Battery energy consumption model simplification. In the simulation, the battery consumption adopts a simple linear step decay model, without considering the nonlinear power consumption characteristics caused by AGV load and acceleration, nor does it model the charging process in detail. Later, a more accurate battery dynamics model closer to the hardware can be introduced to fully integrate the energy consumption constraints into the scheduling optimization objective.
- Degradation of greenhouse environment sensors. In the simulation stage, it is assumed that the laser radar and camera perception data are complete and reliable; in the real greenhouse environment, phenomena such as laser being scattered by crop leaves and the camera being blocked by branches and leaves will occur, which are sensor degradation phenomena. In the subsequent simulation, sensor noise and observation loss models can be added to simulate the perception defects in the agricultural scene.
- Path prior feature vector encoding. In the methods section of this paper, the encoding rules for converting the A* path sequence into the input feature vector of the policy network have been provided. In the future, various different encoding paradigms can be compared to study the impact of the encoding method on the training efficiency and final performance of the model.
- Definition of the variants of the ablation experiments. The module composition of the four variants V1 to V4 of the ablation experiments has been clearly defined in the results section. By distinguishing between the complete model, the Hungarian module removed, the path prior module removed, and the original MAPPO baseline, it clearly demonstrates the performance gains brought by each of the two core modules and their synergy.
Overall, the algorithm proposed in this paper exhibits good collaborative scheduling capabilities in the simulation environment and small-scale indoor physical tests, but there are still the aforementioned problems to be solved before it can be directly deployed in large-scale real smart greenhouses. This work can provide a reference idea of “prioritized combination optimization + multi-agent reinforcement learning” for the scheduling of multiple AGV clusters in agriculture. Further research will be conducted in the areas of consistency between simulation and physical tests, scalability of large-scale clusters, and verification in real field scenarios.
5 Conclusion
This paper focuses on the multi-AGV collaborative inspection application in smart agricultural greenhouses. It addresses the shortcomings of the standard MAPPO algorithm in scenarios with limited resources and environmental constraints, such as unbalanced load distribution, inefficient path planning, slow convergence, and insufficient robustness in dynamic complex environments. The proposed improved MAPPO framework integrates the Hungarian global task allocation and the weighted A* algorithm with environmental safety priors. The main work and conclusions are as follows:
- (1) At the method level: The global optimal task allocation information is encoded and embedded into the policy network’s observation space. Environmental safety constraints such as dynamic obstacles and proximity risks are explicitly encoded as prior knowledge into the action-value estimation, and the joint loss function is redesigned to simultaneously optimize policy updates, value fitting, and safety-oriented exploration, achieving the organic integration of traditional combinatorial optimization and deep multi-agent reinforcement learning, while balancing global scheduling optimality and dynamic real-time adaptability of the environment.
- (2) Experimental aspect: A comprehensive evaluation was conducted based on 9 gradient complexity greenhouse simulation scenarios, covering core constraints such as space limitations, heterogeneous crop layouts, and time-varying obstacles. The experiments show that this integration mechanism significantly improves the performance of the multi-AGV system: the average load deviation decreases by 42.7%; the frequency of path collisions decreases by 68.3%; the convergence speed increases to 3.1 times the original; the training variance decreases by 59.2%. Abandonment experiments confirm that the Hungarian allocation prior significantly alleviates the uneven resource allocation of agents, and the task distribution Gini coefficient decreases by 0.31; the weighted A* safety prior increases the obstacle avoidance success rate by 27.5% under high-density obstacle conditions. There is a synergistic gain among the modules, resulting in a 18.4% increase in task completion rate, a 22.9% increase in path planning efficiency, a 34.6% reduction in trajectory deviation, and still maintaining good generalization ability even in unseen high-complexity scenarios.
- (3) Physical verification aspect: The experimental setup of three RIKIBOT differential AGV platforms based on ROS demonstrated that the improved algorithm could significantly reduce the task completion time, increase the task completion rate, and decrease the number of path conflicts in the real greenhouse multi-robot scheduling scenario. The average arrival error at the task points was only 0.11 meters, verifying the feasibility under laboratory conditions. The effectiveness of the real greenhouse site needs to be further tested through field trials.
This study still has multiple idealized assumptions and limitations, which have been systematically discussed in the fourth discussion section. Subsequently, research will continue along the following directions: designing online re-planning strategies for extreme scenarios to enhance the adaptability to dynamic environments; developing lightweight distributed computing frameworks to reduce the computational cost of large-scale cluster scheduling; constructing adaptive reward optimization models and multi-constraint collaborative decision-making mechanisms to reduce the reliance of algorithms on artificial prior knowledge; analyzing the logic of collaborative decision-making based on reinforcement learning interpretability theory; conducting real-life field experiments in smart agriculture greenhouses using the ROS platform to promote the implementation of algorithm engineering and provide theoretical basis and technical support for multi-AGV collaborative operations in smart agriculture.
Supporting information
S1 Text. Weight-sensitivity simulation results.
Single-factor parameter sensitivity simulation results for weight coefficients within the Hungarian comprehensive cost function and MAPPO global reward function, including S1–S8 Tables of simulation data and analysis.
https://doi.org/10.1371/journal.pone.0363865.s001
(DOCX)
Acknowledgments
The authors thank the technical staff for their assistance in experimental testing. We also appreciate the colleagues in our laboratory for valuable discussions and suggestions during this research.
References
- 1. Rakun J, Popič G. Optimized autonomous navigation for field robots: extended results and practical deployment. Precis Agric. 2025;27(1):5.
- 2. Liang J, Li Y, Yin G, Xu L, Lu Y, Feng J, et al. A MAS-Based Hierarchical Architecture for the Cooperation Control of Connected and Automated Vehicles. IEEE Trans Veh Technol. 2023;72(2):1559–73.
- 3. Tan C, Yao J, Tang K, Liang J, Yin G. Privacy-Preserving Cycle-Based Arrival Profile Estimation Based on Cross-Company Connected Vehicles. IEEE Trans Consumer Electron. 2025;71(2):6167–82.
- 4. Xiong Y, Tian H, Tang J, Jin J, Shen X. Task Planning and Optimization for Multi-Region Multi-UAV Cooperative Inspection. Drones. 2025;9(11):762.
- 5. Wang S, Fan L, Zhang M, Jiang J, Ni L. Research on multi-objective optimization method for cooperative inspection path of UAV swarm in chemical industrial parks. Journal of Loss Prevention in the Process Industries. 2026;102:105981.
- 6. Aierken N, Yang B, Li YK, Jiang PA, Pan G, Li SJ. A review of unmanned aerial vehicle based remote sensing and machine learning for cotton crop growth monitoring. Comput Electron Agric. 2024;227(2):109601.
- 7. Wang Z, Zhu J. Solving multi-robot task assignment problem based on improved genetic algorithm. Front Comput Intell Syst. 2024;10(3):5–10.
- 8. Marseglia L, Vale A, Di Gironimo G. Genetic Algorithm-Based Optimization of Velocity Profiles for Multi-Robot Collision Avoidance. Machines. 2025;13(11):1036.
- 9. Zhou Y, Lan Q, Yang X, Wang LD, Li GW, Li SG, et al. Multi-agent task allocation method based on the cost-effectiveness maximization multi-round auction algorithm. Frontiers in Physics. 2026;13:1617607.
- 10. Wang XW, Yao ZP, Chen S, Bian YG, Xu B, Han L. Distributed auction algorithm-based online scheduling for multi-AGV in automated warehouses. Comput Oper Res. 2026;191:107441.
- 11. Ul Abideen SZ, Ullah I, Bai XS, Zhang WD, Li JQ, Ge SS. Multi-robot task assignment: a survey of algorithmic approaches, challenges, and future directions. Comput Sci Rev. 2026;61:100968.
- 12. Ozdemir K, Tuncer A. Multi-agent proximal policy optimization supported dynamic behavior tree evolution for multi-agent systems. Eng Appl Artif Intell. 2026;167(2):113841.
- 13. Tang J, Zhou P, Bai H, Jing G. GRA: graph-based reward aggregation for cooperative multi-agent reinforcement learning. J Autom Intell. 2026;5.
- 14. Wei Z, Zhou M. Design of a Multi-Agent Collaborative Decision-Making System Based on Reinforcement Learning. Int J Patt Recogn Artif Intell. 2025;40(01).
- 15. Liu K, Yigitcanlar T, Browne W, Washington T. Understanding human-LLM interaction patterns in urban planning: A review and framework. Applied Soft Computing. 2026;195:115003.
- 16. Beckingsale L, Wilkinson T, Anakin M. Towards a conceptualisation of collaborative decision-making within interprofessional collaborative practice: a concept analysis using scoping review methodology. BMC Med Educ. 2026;26(1):743. pmid:41913144
- 17. Qian S, Chang YB, Guzailinuer Y. A study on multi-warehouse robot path planning with an enhanced A* algorithm considering time window. Measurement Science and Technology. 2026;37(16):166202.
- 18. Tian ZD. Path planning for mobile robots based on enhanced particle swarm optimization algorithm. J Electr Eng Technol. 2026.
- 19. Zhou M, Li JY, Wang C, Wang J, Zhai WF, Puig V. Global round-up strategy based on an improved Hungarian algorithm for multi-robot systems. J Intell Robot Syst. 2024;110(4):168.
- 20. Luo Z, Han Y, Zou Y, Zhang X, Zhang J. Research on inspection task allocation method of inspection robot based on improved genetic algorithm. Cluster Comput. 2025;28(13).
- 21. Clinch K, Wood TA, Manzie C. Auction algorithm sensitivity for multi-robot task allocation. Automatica. 2023;158:111239.
- 22. Du H, Chen Y, Zou X. Intelligent Resource Allocation for Task-Sensitive Autonomous Vehicular Systems. Electronics. 2025;14(11):2213.
- 23. Wang N, Yang X, Wang TH, Xiao JX, Zhang M, Wang H, et al. Collaborative path planning and task allocation for multiple agricultural machines. Computers and Electronics in Agriculture. 2023;213:108218.
- 24. Mahmud SA, Ibrahim AM, Khan MR. A comprehensive review on multi robot task assignment and path planning: Operational constraints, challenges, and potentials of deep reinforcement learning. Applied Soft Computing. 2026;188:114498.
- 25. Li K, Liu T, Ram Kumar PN, Han X. A reinforcement learning-based hyper-heuristic for AGV task assignment and route planning in parts-to-picker warehouses. Transportation Research Part E: Logistics and Transportation Review. 2024;185:103518.

관련 뉴스