Are Learning Agents Suitable for Complex Bot Behavior?

Hello, community!

I’m working on a game using Unreal Engine 5 and plan to actively use Learning Agents to train the bots. Could you please let me know if it is possible to implement complex bot behavior within a single policy using Learning Agents? For example, can a bot patrol, search for the player, shoot, flee, search for ammo, etc., and flexibly switch between these states while planning the next steps?

Are Learning Agents suitable for such complex tasks at this stage, or are they only suitable for simpler tasks like driving a vehicle to a designated point? Is it possible to achieve complex behavior only by combining Learning Agents with Behavior Trees and HTN Planning to switch policies depending on the situation?

Thank you for your help!

Hello,

Thanks for the question!

So far in practice, I have only used learning agents to train skills like driving, aiming, and movement and I typically combine these skills with a higher level behavior tree as needed, but theoretically you can train your entire agent using reinforcement learning. The biggest issues are gathering enough data and creating a dense enough reward function that matches the desired behavior (this is challenging in itself).

The biggest burden is going to be doing enough rollouts in parallel in order to train quickly (i.e. you will need a lot of parallel gyms inside your single UE instance). For future Learning Agents release (targeting UE 5.5), we have been working on making the training API more robust and making it easier to parallelize across multiple UE instances.

So the answer bottom line is, theoretically you can design a powerful enough neural network model in LA today, but you might have trouble training it unless you do is piecemeal. In the future, training the whole behavior in a single agent should be much easier.

Brendan