Skip to content

ds-kimi/Auris

Repository files navigation

Auris logo

Auris

Real-time voice transcription for Garry’s Mod servers
Opus · whisper.cpp · extensible submodule API

GitHub release GitHub stars MIT License Windows Garry's Mod


Captures player voice chat via an in-process SV_BroadcastVoiceData detour, decodes Opus audio, and transcribes it in real time using whisper.cpp. Auris is a silent platform — it does nothing by default except make transcriptions available. What happens with them is up to submodule addons.


Demo Video

Auris demo video

Watch Auris transcribe Garry's Mod voice chat in real time.


Requirements

  • Git
  • Vulkan SDK 1.4.341.1 or newer (GPU builds only)
  • Visual Studio with C++ build tools
  • whisper.cpp model file (see "Models" below)

Models

Download a ggml-*.bin Whisper model from:

Place the model on your server in the Garry's Mod data folder:

  • garrysmod/data/auris/ggml-tiny.en.bin

Upgrading from a previous release? Move your model file from data/whisper/ to data/auris/.

If you want to use a different model name or path, update it in:

  • garrysmod_addon/auris/lua/auris/config.lua

Building the module

See BUILD.md for the full build guide — all platforms, architectures, CPU vs GPU variants, and flag reference.

Quick start (Windows, CPU-only):

RUN_ONCE.bat
premake5.exe --os=windows --gmcommon=./garrysmod_common vs2022

Open projects/windows/vs2022/ and build in Release.


Tested on

  • Windows 11
  • Vulkan SDK 1.4.341.1
  • Visual Studio 18.5.11626.173

Configuration

Edit garrysmod_addon/auris/lua/auris/config.lua to change the model path, language, thread count, and other options. Every key can also be overridden at runtime via ConVar (auris_threads, auris_language, auris_debug) in server.cfg — ConVar values take precedence over the file.


Backends

Auris has two transcription backends. Both fire the same Auris_Transcription hook with identical arguments, so submodules work unchanged on either.

Backend When it runs Trade-off
Local (whisper.cpp) openai_api_key = "" (default) Private, offline, no per-clip cost; uses server CPU/GPU and requires a downloaded model file
Remote (OpenAI) openai_api_key set in config.lua Zero local compute, hosted accuracy; requires network I/O and incurs OpenAI per-minute billing

To switch to the remote backend, fill the two keys in config.lua:

openai_api_key = "sk-...",
openai_model   = "whisper-1", -- or gpt-4o-mini-transcribe / gpt-4o-transcribe

Whisper.cpp is not loaded and the worker thread is not spawned in remote mode — the Steam voice detour still runs, captured Opus is still decoded to float32 PCM, but transcription happens entirely at https://api.openai.com/v1/audio/transcriptions. See OpenAI's speech-to-text docs for pricing and model options.


Submodule API

Auris exposes a hook that any addon can listen to:

hook.Run("Auris_Transcription", ply, steamid64, text, audio)
Parameter Type Notes
ply GPlayer or nil nil if the player disconnected before the result arrived
steamid64 string Always present
text string Transcribed speech
audio string or nil Raw 16 kHz mono float32 PCM binary. Convert to a playable WAV with Auris.PCMToWAV(audio)

Quick start

Create a new GMod addon with one server-side file:

-- lua/autorun/server/sv_myaddon_init.lua

-- timer.Simple(0) defers until all autorun files have loaded,
-- avoiding load-order issues with Auris.
timer.Simple(0, function()
    if not Auris then
        ErrorNoHalt("[myAddon] Auris core not found\n")
        return
    end

    Auris.Subscribe("MyAddon_Feature", function(ply, steamid64, text, audio)
        local name = IsValid(ply) and ply:Nick() or "Disconnected"
        Msg("[myAddon] " .. name .. ": " .. text .. "\n")

        -- optional: save the voice clip to disk
        if audio then
            file.Write("myaddon/" .. steamid64 .. ".wav", Auris.PCMToWAV(audio))
        end
    end)
end)

Full API reference

See API.md for the complete API, subscriber name conventions, version guards, and the publishing checklist to get your submodule listed here.

Community submodules

Addon Description Author
auris-logger Prints every transcription to the server console with player name and SteamID64 ds-kimi
auris-discord Forwards every transcription to a Discord webhook (requires gmsv_reqwest) ds-kimi
auris-subtitles Displays transcriptions as animated worldspace subtitles above the speaker's head, visible to nearby players ds-kimi

To add yours: follow the publishing guide in API.md, then open a Submit Submodule issue.


Star history

Star history chart

See the interactive chart on Star History (repo: ds-kimi/Auris).

About

Real-time speech-to-text for Garry's Mod. Captures player voice , decodes Opus audio, and transcribes it with whisper.cpp. Submodules receive results through a simple hook API and decide what to do with them.

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Contributors