1- # 🧠 Creating an Agent
1+ # 🧠 Creating Agent
22
33---
44
5- An agent in UnityNeuroSpeech is a Unity object that can listen, talk, and respond using LLMs.
5+ Agent in UnityNeuroSpeech is a GameObject that can listen, talk, and respond using LLMs.
66** Once you create your first agent, you’ll be able to speak with your AI!**
77
88---
99
10- ## 🛠 How to Create an Agent
11-
12- Go to ** UnityNeuroSpeech → Create Agent** .
13- You will see the window with these settings:
10+ > Before creating agent make sure you have any two sprites. They're used for Microphone state(enabled/disabled).
1411
12+ ---
1513
16- #### 👤 Agent Parameters
14+ ## ✅ Scene Setup
1715
18- | Setting | Description |
19- | -----------------| -----------------------------------------------------------------------------|
20- | ** Model name** | Name of the LLM you downloaded via Ollama. |
21- | ** Agent name** | Internal name for your agent. Avoid spaces or dashes. |
22- | ** System prompt** | Base prompt used to control the AI’s behavior and tone. |
16+ 1 . Add a ` Button ` to your scene.
17+ 2 . Add an ` AudioSource ` to your scene.
2318
2419---
2520
26- ### ✅ Final Setup in Scene
21+ ## ️⚙️ Opening Agent settings
2722
28- 1 . Create a ` Canvas ` in your scene.
29- 2 . Add a ` Dropdown ` with at least three options and a ` Button ` .
30- 3 . Add an ` AudioSource ` to your scene.
31- 4 . Create an empty ` GameObject ` and attach the following scripts:
23+ Go to ** UnityNeuroSpeech → Create Agent** .
24+ You will see the window with these settings:
3225
33- - ` WhisperManager `
34- - ` MicrophoneRecord `
35- - ` YourAgentNameController `
36- - ` SetupWhisperPath `
37-
38- 5 . Configure the scripts:
26+ ### 👤 Agent Parameters
3927
40- #### 🔧 ` WhisperManager `
41- - Leave ` Model Path ` empty.
42- - Turn off:
28+ | Setting | Description |
29+ | -----------------| --------------------------------------------------------------------------|
30+ | ** Model name** | Name of the LLM you downloaded via Ollama |
31+ | ** Agent name** | Internal name for your agent. Avoid spaces or dashes |
32+ | ** System prompt** | Base prompt used to control the AI’s behavior and tone |
4333
44- - ` Is Model Path In StreamingAssets `
45- - ` Init On Awake `
46- - ` Use VAD `
47- - Set ` Language ` to ` auto ` .
34+ ### 👤 Agent Component Values
4835
49- #### 🎙 ` MicrophoneRecord `
50- - Turn off ` Use VAD `
51- - Assign the ` Dropdown ` to ` Microphone Dropdown ` .
36+ | Setting | Description |
37+ | --------------------------------| --------------------------------|
38+ | ** Microphone enable button** | Button you created before |
39+ | ** Enabled microphone sprite** | Sprite for enabled microphone |
40+ | ** Disabled microphone sprite** | Sprite for disabled microphone |
41+ | ** Response audiosource** | AudioSource you created before |
5242
53- #### 🤖 ` YourAgentNameController `
54- - ` Agent Settings ` : assign the ` Agent_YourAgentName ` ScriptableObject.
55- - ` WhisperManager ` , ` MicrophoneRecord ` : assign the same GameObject.
56- - Assign your ` Button ` , ` Enable Mic Sprite ` , ` Disable Mic Sprite ` , and ` AudioSource ` .
5743
58- #### 📁 ` SetupWhisperPath `
59- - Drag the GameObject into ` Whisper ` .
60- - For ` Model Path ` , use:
61- ` UnityNeuroSpeech/Whisper/ggml-medium.bin `
62- (replace with your actual file name and folder if moved).
44+ 📝 When you're done, click ** Generate agent** .
45+ After scripts compilation click ** Create agent in scene** .
6346
6447---
6548
66- ### 🔄 Start the TTS Server
49+ ## 🔄 Start the TTS Server
6750
6851Run the ` run_server.bat ` file.
6952⚠️ It ** must be in the same directory** as the ` Server ` folder (i.e., not inside it).
@@ -79,13 +62,7 @@ Run the `run_server.bat` file.
7962
8063---
8164
82- ### ❕ Note
83-
84- If you want to add ** more than one agent** in one scene, after creating new empty ` GameObject ` , add only ` YourAgentNameController ` script.
85-
86- ---
87-
88- ### 🎧 Tip
65+ ## 🎧 Tip
8966
9067The response delay depends on:
9168
0 commit comments