# GLaDOS
This is a small example of how to use piper-tts with NeuroDock to get GLaDOS to say what ever the AI responds with
# This project might be writen in Java, but it's not operating system agnostic as it REQUIRES a Linux and Pipewire system.
I Zacharias (the dev) what's to clarify that YES many parts of this code is writen with the assistance of or fully by AI.
I have reviewd the code. However, as I'm not confident enough in how Audio works in general and Java's Audio stack on Linux is well ehh to put it lightly fucked, I made use of
Anthropics Claude Sonnet 5 for this... IF you do not like that AI was used for this PoC, don't use it. don't go and complain about it.
## Setup
Unlike NeuroDock this one requires some extra setup
### System
This is only tested and will lickely only work on a Linux machine with Pipewiere as the audio stack; this is because I chuldent get Java's audio system to work on my pipewire system
This, however, will be looked at and refined to work on more things
### Envirment
#### Java
- Right now you need to add the gitea repo for NeuroDock as project builds with NeuroDock:Core 1.7 or newer
#### Python/Whispers
1. Create the venv `$ python -m venv .venv`
2. Install the dependecies
nvidia: For nvidia you can just use the default pytourch
AMD: For AMD you need to grab pytourch from the ROCm repo: https://download.pytorch.org/whl/rocm/
CPU: I'm quite sure you can use the default pyturch for this
#### NeuroDock
- Make sure you have the Ollama server started and avalible on localhost
- Make sure you have an appropreat LLM downloaded and installed to Ollama(This project is currently configured to use `llama3.2`)
#### Piper
- The current configuration expects you to have GLaDOS and the Announcer from Portal voice models in `~/.local/share/piper/glados/glados_piper_medium.onnx` and `~/.local/share/piper/portal-announcer/announcer.onnx` respectivle.
These can be fetched from https://huggingface.co/DavesArmoury/GLaDOS_TTS/tree/main and https://github.com/Davis8483/portal2-announcer-piper-tts/tree/main respectivly, grab both the `onnx` and `onnx.json` files for both models and place them next to each other in the respective folders.
## Run
### Java
1. Build: `$./gradlew shadowJar`
2. Run: `$java -jar build/libs/GLaDOS-1.0-SNAPSHOT-all.jar`
### Python (start this AFTER the Java component as it connects via a UNIX socket)
1. Run `$python src/main/python/whisper_daemon.py`
Enjoy talking with GLaDOS!