DeliveryGym: An RL Environment for Long-Horizon Embodied Agent Planning with Adaptive Curriculum
Abstract: Executable environments enable LLM agents to learn from the consequences of their actions. For embodied agents, those consequences extend beyond whether the current task succeeds: completing a delivery can consume the time, energy, or money needed for later work. Learning to plan therefore requires environments that preserve these dependencies and turn them into feedback across a complete trajectory. We introduce DeliveryGym, a 3D environment for evaluating and training agents on continuous courier shifts. It couples multimodal tool interaction with persistent world dynamics and computes trajectory rewards from simulator events, making the costs of an agent's decisions available for reinforcement learning (RL). The environment also adapts future training shifts to the policy's observed weaknesses while keeping evaluation fixed. Across six models and 13 city maps, evaluation exposes a gap between reliably executing assigned deliveries and choosing and sequencing work over a shift. On the unseen-city test set, RL improves Qwen3-VL-4B's net income by 54.3%, showing that learning from complete shifts improves performance under these coupled constraints. Adapting the training environment improves evaluation income by 18% over uniform sampling at 100 updates, indicating that which situations an agent practices also matters. DeliveryGym provides an executable setting for studying how agents learn to coordinate deliveries and preserve resources for later orders within an episode.
Paper Prompts
Sign up for free to create and run prompts on this paper.
Explain it Like I'm 14
1. What is this paper about?
The paper introduces DeliveryGym, a virtual 3D world where an AI agent works as a food courier during a complete work shift.
The agent must:
- Choose which orders to accept
- Find restaurants and customers
- Plan routes
- Manage time, energy, money, and food quality
- Avoid traffic violations and obstacles
- Decide how one delivery will affect later deliveries
The main idea is that an AI should not only learn how to complete one delivery. It should learn how to make good decisions across an entire shift, where every choice changes what is possible later.
2. What questions does the research ask?
The paper focuses on four main questions:
- How well can current AI models perform as couriers? Can they choose and complete deliveries successfully?
- Can reinforcement learning improve their planning? Reinforcement learning, or
RL, means an AI learns by trying actions and receiving rewards or penalties based on the results. - Does an adaptive curriculum help the AI learn faster? An adaptive curriculum is a training system that gives the AI more practice with the problems it currently struggles with.
- Does giving the AI more maps and situations improve learning? The researchers test whether a wider variety of cities, routes, orders, and problems helps the AI become better at planning.
3. How was the research carried out?
The virtual courier world
DeliveryGym is built as a 3D city simulation using Unreal Engine 5. It includes 13 city maps, including cities such as Paris and New York.
The world contains:
- Streets and buildings
- Restaurants and customers
- Traffic lights
- Obstacles and blocked roads
- Walking routes
- Energy or resource stations
- Different food types and delivery requirements
The AI sees information such as a street image, a map, its current location, available orders, remaining energy, money, and the result of its last action.
It controls the world through tools. For example, it can accept an order, pick up food, choose a destination, move, wait, buy supplies, or deliver food.
One long episode instead of many short ones
A major feature is that the whole shift is treated as one continuous episode. The world does not reset after each order.
For example:
- Taking a long-distance order uses time.
- Walking uses energy.
- A late delivery may reduce the payment.
- Buying supplies costs money.
- A traffic accident can cause a fine and hospital delay.
- Accepting one order may prevent the AI from completing a better order later.
This is similar to playing a strategy game where resources and decisions carry over from one level to the next.
Measuring success
The main score is net income:
Costs and penalties can come from:
- Late or damaged food
- Buying resources
- Hospital recovery
- Traffic violations
- Collisions
- Poor delivery ratings
The simulator calculates these results automatically from what happened in the virtual world. This means the researchers do not need a person or another AI to judge whether the agent did well.
Testing different AI models
The researchers tested six AI models on 130 fixed delivery shifts. These shifts used maps and situations that were kept separate from the training data.
This is important because it checks whether the AI learned useful skills rather than simply memorizing the practice routes.
The researchers used two movement systems:
- Waypoint control: The AI chooses from known destinations, such as a restaurant or street point.
- Any-Point control: The AI chooses a location by pointing to a pixel in an image.
Any-Point control is harder because the AI must understand the image accurately and select a safe place to move.
Reinforcement learning and adaptive training
The researchers trained one smaller model, Qwen3-VL-4B, using reinforcement learning.
The model tried complete shifts. After each shift, it received a score based on its earnings and, in some experiments, penalties for unsafe behavior.
The researchers also tested an adaptive curriculum. Every so often, they checked what the AI was doing badly, such as:
- Running red lights
- Failing to find another route around a blockage
- Choosing poor combinations of orders
The training system then created more situations involving those weaknesses.
4. What did the researchers discover?
Current AI models can deliver orders, but they struggle with full-shift planning
The strongest tested model earned about $18.30 per shift**, while the search-based planning reference earned **$24.00.
This shows that the AI models were able to complete many deliveries, but they still made poor long-term choices.
For example, an AI might successfully complete one high-paying order but spend so much time traveling that it misses two nearby orders that would have earned more money together.
The paper describes this as a difference between:
- Single-order execution: completing an assigned delivery
- Shift-level planning: choosing and organizing several deliveries profitably
A model can be good at the first skill but weak at the second.
Image-based movement is much harder
When the models had to choose movement targets directly from images, their performance dropped sharply.
Depending on the model, income fell by around 50% to 89% compared with waypoint control.
The AI often:
- Missed traffic signals
- Chose the wrong direction
- Tried to move through blocked streets
- Collided with obstacles
This shows that having a good plan is not enough. The AI must also correctly understand the visual scene and turn its plan into safe movements.
Reinforcement learning improved performance
Online reinforcement learning substantially improved the smaller Qwen3-VL-4B model.
On the fixed test set, its net income increased by 54.3% compared with its starting performance.
The model also completed more deliveries. This suggests that learning from the consequences of complete shifts helped it understand how choices affect later opportunities.
Safety rewards helped both safety and income
When the AI was rewarded only for making money, it still sometimes ran red lights or hit obstacles.
Adding penalties for unsafe behavior reduced:
- Red-light violations by 62%
- Obstacle collisions by 54%
Surprisingly, safer behavior also increased income by about 14% compared with training based only on earnings.
This makes sense because accidents and traffic problems waste time and money. Being safe helps the AI keep enough time and resources for later deliveries.
The adaptive curriculum improved learning
The adaptive curriculum performed better than giving the AI random or evenly mixed practice.
Compared with uniform sampling, it improved test income by 16.5%. It also improved the AI’s performance on:
- Traffic safety
- Recovering from blocked routes
- Planning several deliveries together
The lesson is that training is more useful when it focuses on the learner’s current weaknesses instead of repeatedly practicing skills it already knows.
More maps and situations made training more effective
Even when the researchers kept the total number of training shifts the same, giving the AI a larger variety of possible situations improved its results.
The research found that:
- A larger task pool improved income by about 47%
- Training on eight maps instead of one improved income by about 61%
This suggests that varied practice can be more valuable than simply repeating a small number of similar situations.
5. Why is this research important?
DeliveryGym provides a realistic way to study AI planning over long periods.
Many AI tests ask an agent to complete one simple task. However, real life often works differently. Decisions have consequences that appear later:
- Using energy now may leave too little for later.
- Choosing one job may block a better job.
- Taking a shortcut may cause an accident.
- Spending money on recovery may make a delivery unprofitable.
DeliveryGym helps researchers study these connected decisions in a safe, repeatable virtual environment.
Conclusion and possible impact
The paper shows that AI agents are often better at carrying out individual instructions than at planning a whole sequence of actions.
It also shows that:
- Reinforcement learning can improve long-term planning.
- Safety should be part of the reward, not treated as an unrelated problem.
- Training should focus on the AI’s weaknesses.
- A wider variety of maps and situations can make practice more effective.
In the future, ideas from DeliveryGym could help train AI systems for other long-term tasks, such as robot delivery, warehouse work, rescue missions, household assistance, or self-driving vehicles.
The main message is simple: to make AI better at real-world jobs, we should train it in environments where its choices have lasting consequences, just as they do in real life.
Practical Applications
Immediate Applications
- Embodied-agent benchmarking for logistics and robotics
- Organizations can use DeliveryGym as a reproducible benchmark for comparing multimodal agents on long-horizon delivery planning rather than isolated navigation or task completion.
- Applicable sectors include robotics, autonomous vehicles, last-mile logistics, and software engineering for agents.
- A practical workflow would evaluate an agent on fixed, replayable shifts using net income, on-time delivery, safety violations, collisions, resource use, and recovery behavior.
- The fixed harness, seeded scenarios, held-out maps, and simulator-derived rewards support fair comparisons across models.
- Dependencies: Results depend on the realism of the simulator, the quality of registered maps and navigation data, and the degree to which simulated traffic, food degradation, energy use, and costs match deployment conditions.
- Training long-horizon delivery and dispatch agents with online RL
- Logistics companies could train agents to select, accept, reject, and sequence delivery jobs while accounting for deadlines, travel distance, battery or stamina, operating costs, and future earning opportunities.
- The paper shows that training on complete shift outcomes is more useful than optimizing only individual delivery success. Qwen3-VL-4B achieved a reported 54.3% test-income improvement after RL.
- A potential product is a dispatch assistant that recommends which orders a courier should accept and in what sequence, while preserving resources for later orders.
- Dependencies: Effective deployment requires a sufficiently accurate simulator, a reliable reward model, representative order distributions, and safeguards against optimizing income at the expense of customer service or worker welfare.
- Safety-aware optimization for autonomous mobility
- The reward-design results can be used to train delivery robots, scooters, or autonomous vehicles to treat traffic violations, collisions, and unsafe route choices as explicit optimization constraints.
- Adding safety penalties reduced red-light violations by 62% and obstacle collisions by 54% in the reported experiments, while also improving net income relative to earnings-only RL.
- This suggests a practical training workflow: optimize operational performance while separately penalizing safety-critical events, then evaluate using unmodified economic metrics.
- Dependencies: Penalty weights must reflect legal and organizational priorities. Poorly calibrated penalties could produce overly conservative behavior or encourage agents to exploit unmodeled safety gaps.
- Failure diagnosis and targeted agent testing
- The simulator’s event traces and deterministic assertions can provide automated diagnostics for traffic compliance, obstacle recovery, deadline reasoning, resource management, food care, order rejection, and multi-order planning.
- Developers can integrate these tests into continuous evaluation pipelines for multimodal agents, similar to executable tests in software engineering.
- Potential tools include agent “failure atlases,” regression dashboards, scenario replay systems, and release gates that block models whose safety or planning performance degrades.
- Dependencies: Failure categories must be explicitly defined, and simulator assertions must accurately distinguish planning failures from perception, interface, or low-level control failures.
- Curriculum-based training for multimodal foundation models
- The adaptive curriculum can be applied immediately to other tool-using agents by measuring recurring weaknesses and increasing exposure to corresponding scenarios.
- For example, an agent that frequently misses blocked routes can receive more detour tasks, while one that accepts incompatible orders can receive more overlapping-order scenarios.
- This is relevant to robotics, autonomous web agents, industrial control, and interactive assistants, where a static training distribution may overrepresent easy cases.
- Dependencies: The curriculum requires reliable skill-level probes, a feasible task generator, and safeguards preventing the model from overfitting to diagnostic scenarios.
- Simulation-based training for courier operations and workforce decision support
- Logistics firms could use the environment to train human dispatchers or couriers through scenario-based simulation involving deadlines, resource shortages, hazards, and competing orders.
- The simulator could support “what-if” analysis: comparing the financial and safety consequences of accepting a distant high-paying order versus several nearby orders.
- It could also be used in onboarding or certification workflows for delivery personnel and fleet managers.
- Dependencies: Human-facing use requires realistic compensation, fatigue, traffic, weather, and labor-policy models; otherwise, recommendations may be operationally efficient but socially or economically unrealistic.
- Academic research on long-horizon planning and embodied reasoning
- Researchers can use DeliveryGym to study credit assignment, persistent state, tool use, visual grounding, multi-objective RL, asynchronous rollout systems, and transfer across city layouts.
- The separation between fixed evaluation maps and adaptive training environments is useful for measuring generalization rather than memorization.
- The comparison between Waypoint and Any-Point movement provides a controlled way to isolate high-level planning from fine-grained visual grounding.
- Dependencies: Academic conclusions should account for the limited number of maps, the specific model family used for RL experiments, and possible simulator artifacts.
- Policy and safety evaluation for autonomous delivery systems
- Regulators and public-sector organizations could use simulator-based tests to assess whether autonomous delivery systems obey traffic rules, recover from blocked routes, and manage operational risks over extended periods.
- Policy agencies could define minimum thresholds for collision rates, red-light violations, on-time performance, and resource-related failures before allowing field trials.
- Replayable shifts make it possible to audit the same system under identical conditions across model versions.
- Dependencies: Regulatory adoption would require validation against real-world incident data, transparent scenario-generation rules, and independent auditing of the simulator and reward definitions.
Long-Term Applications
- Sim-to-real deployment of autonomous courier robots and vehicles
- DeliveryGym could become a training component for sidewalk robots, autonomous scooters, or small delivery vehicles that must coordinate route choice, order selection, battery management, traffic compliance, and customer deadlines.
- A future system could combine DeliveryGym pretraining with real-world fleet data and limited on-road adaptation.
- The persistent-shift formulation is particularly relevant to fleets that must maximize service quality over an entire operating period rather than complete one trip at a time.
- Dependencies: Sim-to-real transfer is a major challenge. Real-world weather, pedestrians, construction, ambiguous signage, communication failures, vehicle dynamics, and legal restrictions are not fully represented in the current environment.
- Multi-agent fleet dispatch and market coordination
- An extension could train multiple couriers or robots that share orders, charging stations, traffic capacity, and delivery regions.
- Potential products include fleet-level dispatchers that dynamically assign orders, coordinate rebalancing, and decide when vehicles should recharge or return to a depot.
- The current single-agent persistent-resource model provides a foundation for studying these interactions.
- Dependencies: Multi-agent training requires models of communication, competition, order reassignment, fleet priorities, worker autonomy, and congestion effects. It also requires mechanisms to prevent one agent’s optimization from degrading fleet-wide or customer outcomes.
- General-purpose long-horizon embodied-agent training
- The environment design could be generalized beyond delivery to warehouse picking, hospital logistics, grocery fulfillment, field maintenance, emergency response, and household assistance.
- The transferable pattern is an executable task with persistent state, delayed consequences, event-based verification, and adaptive practice.
- Potential tools include a general “shift simulator” framework in which agents manage jobs, resources, deadlines, safety constraints, and changing opportunities.
- Dependencies: Each domain needs a domain-specific verifier and realistic dynamics. Delivery-specific assumptions about income, food condition, and route structure cannot be transferred directly to healthcare, manufacturing, or emergency services.
- Safety-constrained RL for high-stakes operations
- The explicit separation between economic return and safety penalties could support training in healthcare logistics, industrial inspection, warehouse robotics, and infrastructure maintenance.
- Future systems could optimize productivity while enforcing hard constraints such as restricted zones, equipment limits, patient-priority rules, or regulatory procedures.
- A likely product is a constraint-aware policy-training platform that reports both task performance and independently verified safety behavior.
- Dependencies: Safety cannot rely solely on weighted rewards in high-stakes settings. Formal constraints, human oversight, runtime monitoring, and fail-safe control may be required because an RL agent can exploit omissions in the simulator.
- City-scale planning and urban policy simulation
- Expanded versions could help municipalities study delivery congestion, charging-station placement, traffic-rule effects, curb allocation, and the impact of delivery demand on emissions and travel time.
- Policy makers could compare scenarios such as restricted delivery zones, dynamic curb access, low-emission zones, or incentives for bicycle and electric-vehicle use.
- The reported gains from adding training maps suggest that broader geographic coverage could improve spatial generalization.
- Dependencies: Urban-policy use requires calibrated demand models, real traffic and infrastructure data, emissions accounting, and representation of pedestrians, cyclists, residents, and businesses—not only courier profitability.
- Adaptive education and training systems for planning skills
- The weakness-diagnosis loop could be adapted into educational software that identifies whether a learner struggles with sequencing, resource management, risk assessment, or recovery from failure.
- A training application might generate increasingly targeted logistics, operations-research, or robotics scenarios while reserving unseen tasks for assessment.
- This could support academic instruction, vocational training, and professional certification.
- Dependencies: Educational deployment requires interpretable skill models, pedagogically valid difficulty progression, privacy protections, and evidence that simulator performance transfers to real decision-making.
- Research platforms for economic and ethical objective design
- DeliveryGym can support studies of how reward choices shape behavior when income, safety, food quality, customer satisfaction, and worker well-being conflict.
- Future versions could include fairness constraints, minimum earnings guarantees, fatigue limits, customer equity, carbon emissions, and service obligations for low-profit areas.
- Such a platform could help organizations test whether an apparently profitable policy creates unacceptable social or labor outcomes.
- Dependencies: Ethical objectives must be defined with stakeholders rather than inferred solely from simulator metrics. The current net-income objective does not capture all relevant externalities.
- Large-scale synthetic data generation for multimodal agents
- With expanded city collections, task pools, and event traces, the environment could generate multimodal trajectories for pretraining or post-training vision-language-action models.
- These datasets could include street images, route maps, tool calls, state transitions, failures, recovery attempts, and verified outcomes.
- The reported scaling results—such as a 47% income improvement from enlarging the task pool and a 61% improvement from increasing training-map coverage—suggest that diversity of synthetic experience may improve learning efficiency.
- Dependencies: Synthetic data quality depends on visual and behavioral realism. Models may learn simulator-specific cues, and large-scale generation can be expensive because rendering remains a major bottleneck.
- Integrated digital twins for logistics operations
- A mature version could connect live order streams, fleet telemetry, maps, weather, charging infrastructure, and historical delivery outcomes to create a continuously updated operational digital twin.
- The system could test policies in simulation before deploying them to real couriers or vehicles, then use observed discrepancies to recalibrate the simulator.
- Dependencies: This requires secure data integration, low-latency updates, privacy protections, robust uncertainty modeling, and careful separation between experimental policies and production operations.
Glossary
- Adaptive curriculum: A training strategy that adjusts the distribution or difficulty of tasks according to the learner’s observed weaknesses. “The environment also adapts future training shifts to the policy's observed weaknesses while keeping~evaluation~fixed.”
- Asynchronous reinforcement learning: Reinforcement learning in which simulation, inference, and policy updates proceed without waiting for all workers to synchronize. “these changes improve training efficiency by reducing the time spent collecting experience and waiting for other workers, following asynchronous RL systems”
- Autonomous courier shift: A continuous simulated work period in which an agent selects, performs, and sequences delivery tasks. “An agent works as a courier throughout a continuous shift.”
- Batched inference: Processing multiple model-inference requests together to improve computational throughput. “Together with parallel workers and batched inference, these changes improve training efficiency”
- Closed-loop training: A learning process in which an agent’s actions generate outcomes that directly influence subsequent policy updates and training situations. “This creates a closed loop from tool interaction, to grounded consequence, to verifiable reward, policy update, and finally targeted future experience.”
- Constraint-aware behavior: Behavior that explicitly accounts for operational limitations such as time, safety, energy, and resource availability. “Income alone is not enough for constraint-aware behavior.”
- Curriculum learning: A training approach that presents examples or tasks in a structured way to improve learning efficiency. “An adaptive curriculum changes future training shifts according to the policy's measured weaknesses.”
- Egocentric RGB view: An image observation representing the environment from the agent’s own visual perspective. “The policy receives an egocentric RGB view, route map, and structured courier state”
- Embodied agent: An artificial agent that perceives and acts within a physical or simulated environment. “We introduce DeliveryGym, a 3D environment for evaluating and training agents on continuous courier shifts.”
- Embodied AI: Artificial intelligence concerned with agents that interact with the world through perception and action. “This progress raises a parallel question for embodied AI: can simulated worlds provide similarly grounded and scalable experience for learning?”
- Event trace: A chronological record of actions and simulator events produced during an agent’s interaction. “The event trace records executed actions; simulator events determine constraint checks and net income.”
- Foundation model: A large pretrained model that can be adapted to many downstream tasks. “Our experiments first evaluate six foundation models”
- Grounded action: An action whose execution and consequences are tied to the state of an environment or simulator. “It executes grounded actions and returns their physical consequences.”
- GRPO (Group Relative Policy Optimization): An outcome-based reinforcement-learning method that compares rewards within groups of sampled trajectories to update a policy. “we post-train Qwen3-VL-4B with outcome-based group relative policy optimization (GRPO)”
- Held-out evaluation: Evaluation performed on data, maps, or tasks excluded from training. “three evaluation maps are excluded from training entirely.”
- Long-horizon planning: Planning over many sequential decisions whose effects can influence distant future outcomes. “Long-horizon embodied reasoning makes this question particularly challenging.”
- Multimodal context: Input combining multiple information types, such as images, structured state, and text. “Agents receive multimodal context and act through tools”
- Multimodal policy: A policy that processes and acts on more than one modality of input. “DeliveryAgent combines a base multimodal policy with a fixed harness”
- Net income: Earnings remaining after subtracting expenses and penalties from revenue. “The goal is to maximize net income over the full shift.”
- On-policy trajectory: A sequence of states, actions, and outcomes generated by the policy currently being trained or evaluated. “The environment diagnoses weaknesses from the current policy's on-policy trajectories”
- Online rendering: Generating visual observations during execution rather than retrieving them from a cache. “Any-Point evaluation uses online rendering.”
- Online reinforcement learning: Reinforcement learning in which the policy learns from interactions it generates while operating in the environment. “Our focus is learning long-horizon planning through online RL”
- Persistent state: Environment information that remains available and continues to affect later decisions rather than being reset after each task. “Every interaction changes persistent physical and operational state”
- Policy update: A modification to an agent’s decision-making model based on collected experience and reward. “It supports repeated policy updates with resettable parallel rollouts and verifiable trajectory rewards”
- Procedurally generated: Created algorithmically according to specified rules rather than manually authored in advance. “MineDojo, Voyager, Crafter, and NetHack stress open-world and procedurally generated play”
- Reward shaping: Modifying or augmenting a reinforcement-learning reward to encourage particular behaviors. “with safety-aware rewards improving both income and traffic compliance over earnings-only rewards.”
- Rollout: One simulated execution of an agent interacting with an environment, producing a trajectory. “Each rollout begins from a generated shift.”
- Search-based oracle: A reference planner that searches possible action sequences, often with privileged simulator access, to estimate strong achievable performance. “A search-based oracle provides reference income”
- Simulator backend: The underlying simulation system that executes actions and maintains the virtual environment. “We use SimWorld Studio, built on Unreal Engine 5, as the simulation backend”
- Structured action: An action represented in a predefined machine-readable format that can be validated and executed by an environment. “At each turn, it formats the observation, validates one structured action, executes it, and returns environment feedback.”
- Structured state: A machine-readable representation of relevant environmental and agent variables. “The policy receives an egocentric RGB view, route map, and structured courier state”
- Task distribution: The probability distribution from which training or evaluation tasks are sampled. “A fixed task distribution is not equally informative throughout learning.”
- Terminal return: The final cumulative reward assigned to a completed trajectory or episode. “We train on the terminal return”
- Trajectory reward: A reward computed from the complete sequence of actions and resulting events in an episode. “It couples multimodal tool interaction with persistent world dynamics and computes trajectory rewards from simulator events”
- Visual grounding: Connecting visual content to actionable locations, objects, or movements in the environment. “These failures highlight the importance of visual grounding”
- Waypoint control: Navigation in which an agent selects among predefined visible destination points. “With Any-Point, the policy selects an image pixel that is projected to a reachable 3D point; with Waypoint, it selects a visible registered destination.”
- Verifier: A system that checks simulator events and computes whether actions or outcomes satisfy task requirements. “The verifier computes rewards from simulator events”





