-
Notifications
You must be signed in to change notification settings - Fork 0
OpenAI Assistant Integration
AarickZook edited this page Feb 4, 2025
·
5 revisions
- This is information on how to integrate OpenAI with Unity.
- PSU has provided Azure OpenAI resources for use with this project, but there is a required process to access the Azure resources. It's not the same as with a traditional OpenAI API key.
- The branch published to the GitHub,
openai-assistant-integration, adds a scene for an assistant interaction. - All that the game developers need to do is add a button in the game that loads the assistant scene.
- Attached to this page is a compressed file OpenAI-Integration-Resources. Download and extract all, then copy the files from the
/Assetsfolder into the correct directories in the Unity project.- Copy over
.dllfiles from and to/Assets/Plugins/. - Copy prefabs and their meta files to
/Assets/Prefabs/. - Copy over
Assistant_Interface.unityand meta file to/Assets/Scenes/. - Copy over
/Scripts/OpenAI Integration/toAssets/_Scripts/. - If you don't copy over the meta files, the relationships between prefabs, scene, and scripts won't work properly.
- Copy over
- The only other thing that needs to be set up is the credentials for the Azure project. Create a folder in
C:\Users\[username]\called.openai. - Into the new folder
.openai, add theauth.jsonfile (also found in the compressed folder). Open the file in a text editor and fill in the arguments from your Azure project (currently empty strings).
- Version 1 Game Flow Overview
- Version 2 Game Flow Overview
- Localization and Start Screen Canvas Organization