AI DevKit
Glitch9 Inc.Glitch9 DocsDiscordIssues
  • Introduction
    • AI DevKit 3.0
    • Update Logs
    • Troubleshooting
      • ❗Issues After Updating AIDevKit?
      • ❗The type or namespace name 'Newtonsoft' could not be found
      • ❗Build Error: The name 'UnityMenu' does not exist in the current context
      • ❗Model 'modelName' not found
      • ❗The model `model name` does not exist or you do not have access to it
      • ❗The type or namespace name 'AndroidJavaObject' could not be found
      • ❗The type or namaspace name 'Plastic' does not exist
      • ❗Build Error: The name 'Asset Database' does not exist in the current context
      • ❗'ModelData.Create(Provider, string, UnixTime?, string)': not all code paths return a value
      • ⚠️ Timeout Issues
      • ⚠️ Receiving a “HTTP/1.1 400 Bad Request” Error?
    • FAQ
      • My OpenAI API free trial has ended or is inactive.
  • Quick Start
    • Get API Keys
      • OpenAI API Key Guide
      • Google API Key Guide
      • ElevenLabs API Key Guide
    • Text Generation
    • C# Object Generation
    • Image Generation
    • Sound Effect Generation
    • Text to Speech (TTS)
    • Speech to Text (STT)
    • Voice Changer
    • Audio Isolation
  • Pro Features
    • Generation Menu
      • Code Generators
        • C# Script Generator
        • Unity Component Generator
    • Editor Chat
    • Editor Vision (TTI, ITI)
    • Editor Speech (TTS)
    • Management Tools
      • Prompt History Viewer
      • AI Model Manager
      • TTS Voice Manager
      • OpenAI File Manager
      • OpenAI Assistant Manager
      • ElevenLabs Voice Library
  • Assistants API (OpenAI)
    • How it works
    • Creating custom functions
    • Creating assistants API
  • Advanced API Supports
    • OpenAI API
      • 💬Chat completions
      • 🖼️Image operations
      • 🗣️Text to speech
      • 🎙️Speech to text
        • Recording real-time in Unity
      • 💾Files
      • 🔎Embeddings
      • 🛡️Moderations
      • ⚙️Fine-tuning
    • Google API
      • 📝System instructions
      • 💬Text generation
      • ⚙️Fine-tuning
      • ▶️Fucntion calling
      • 🔎Embeddings
      • 🛡️Safety
      • 💻Code execution
    • ElevenLabs API
  • Legacy Documents
    • AI DevKit 1.0 - 2.0
      • AI DevKit 2.0
      • AI DevKit 1.0
      • Preperation
      • Event Handlers
      • Scriptable Toolkits
        • Chat Streamer
        • Image Generator
        • Voice Transcriber
        • Voice Generator
      • Editor Tools
Powered by GitBook
On this page
  • ScriptableObject Advantage:
  • Key Features:
  • Available Toolkits:
  • Getting Started:
  1. Legacy Documents
  2. AI DevKit 1.0 - 2.0

Scriptable Toolkits

The Scriptable Toolkits offer a suite of Unity ScriptableObject-based tools designed to simplify the integration and utilization of OpenAI's powerful AI services within Unity applications. These toolkits abstract the complexity of interacting with various OpenAI APIs, providing a user-friendly interface for developers to quickly leverage capabilities such as natural language processing, image generation, and speech conversion directly in their Unity projects.

ScriptableObject Advantage:

Leveraging Unity's ScriptableObject system, these toolkits allow for easy configuration and reuse of settings across different parts of your application without the need for hard-coding values or duplicating setup logic. This approach promotes a more modular, efficient, and easily manageable codebase.

Key Features:

  • Ease of Use: Simple interfaces and customizable settings via Unity's Inspector window.

  • Modularity: Each toolkit can be used independently or combined for more complex AI interactions.

  • Flexibility: Scriptable objects allow for easy saving and loading of pre-configured settings, which can be used across different scenes and projects.

  • Event Handling: Scriptable Toolkits can broadcast events and allow developers to subscribe to these events for custom behaviors and UI updates.

  • Asynchronous Support: Operations that communicate with OpenAI's servers are designed to be asynchronous, ensuring that the Unity editor remains responsive.

Available Toolkits:

  • ChatStreamer (ChatStreamer.cs): Facilitates real-time, interactive text-based chat experiences powered by OpenAI's GPT models.

  • ImageGenerator (ImageGenerator.cs & ImageGenerator_Setters.cs): Provides the ability to generate images from textual descriptions, edit images, and create image variations, utilizing OpenAI's DALL-E model variants.

  • VoiceTranscriber (VoiceTranscriber.cs): Converts audio input into text format, harnessing OpenAI's advanced speech recognition capabilities.

  • VoiceGenerator (VoiceGenerator.cs): Transforms text into natural-sounding audio, allowing for a wide range of voice synthesis options.

Getting Started:

To use any of the Scriptable Toolkits, simply create a new ScriptableObject instance for the desired toolkit in your Unity project. This can be done by right-clicking in the Project window, navigating to Create -> Glitch9/OpenAI/Toolkits, and selecting the toolkit you wish to use. Once created, select the ScriptableObject asset to configure its settings in the Inspector window according to your project's needs.

The following sections will provide step-by-step guides on how to use each toolkit, showcasing their capabilities and how to tailor them to fit your project's needs.

PreviousEvent HandlersNextChat Streamer