# Inference with a custom Onnx policy using the AI Agents Plugin

**URL:** <https://forums.unrealengine.com/t/inference-with-a-custom-onnx-policy-using-the-ai-agents-plugin/2125276>\
**Category:** AI\
**Tags:** unreal-engine, question\
**Created:** [November 15, 2024, 5:30pm UTC](https://forums.unrealengine.com/t/inference-with-a-custom-onnx-policy-using-the-ai-agents-plugin/2125276 "2024-11-15T17:30:14Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![Deathcalibur](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/deathcalibur/32/1037610_2.png) [@Deathcalibur](https://forums.unrealengine.com/u/Deathcalibur)\
**Post date:** [November 18, 2024, 3:57pm UTC](https://forums.unrealengine.com/t/inference-with-a-custom-onnx-policy-using-the-ai-agents-plugin/2125276/5 "2024-11-18T15:57:02Z")

</div>

> [@How to use custom model in Learning Agents?](https://forums.unrealengine.com/t/how-to-use-custom-model-in-learning-agents/1947225/8):
>
> I forgot I did a write-up over here with how to use ONNX if you want. The code I provided should be thought of as pseudo-code. I wrote it up in a notepad and did not try to compile it. The idea is you make a sub-class of Policy and add some bits which let LA work with NNE & ONNX: [https://forums.unrealengine.com/t/background-neural-networks-for-leaning-agents-neural-network-data-assets/2080575/2?u=deathcalibur](https://forums.unrealengine.com/t/background-neural-networks-for-leaning-agents-neural-network-data-assets/2080575/2) We haven’t made this part of the LA “official” yet because it has a lot of rough edge…

Let me know if this chain of messages meets your needs or not!

---

_[View the full topic](https://forums.unrealengine.com/t/inference-with-a-custom-onnx-policy-using-the-ai-agents-plugin/2125276)._
