Roblox Audio MCP
# Roblox Audio MCP
Give your Roblox assistant audio tools: inspect a game, obtain the actual audio,
listen to it through an audio-capable model, compare or generate alternatives,
apply a change, and evaluate a recording of the result.
**For any Roblox game or genre.** The creative brief comes from you: a racing
engine, a cheerful UI click, a robot footstep, a forest ambience, or a cinematic
impact. There are no game-specific sound rules.
**Status: 0.1.0 experimental alpha.** This is a working local foundation, not a
claim of fully validated autonomous sound design. See [validation](docs/validation.md)
for what has actually been tested and what remains unverified.
## What it does
| Capability | Implementation |
| --- | --- |
| Connect AI to Studio | Tools-only MCP over stdio; authenticated loopback Studio plugin |
| Inspect audio | Sound and AudioPlayer inventory, settings, child effects, SoundGroup reference, Wire connections |
| Understand triggers | Read scripts; edit existing scripts with stale-source protection |
| Obtain audio | Local files, authenticated Roblox Asset Delivery, or opt-in FFmpeg recording |
| Measure | PCM peak/RMS, near-clipping samples, near-silence, channel boundaries, waveform envelope |
| Listen | Actual audio bytes sent to Gemini with a genre-neutral contextual brief |
| Compare | Independent listening reviews for 2–4 candidates |
| Generate | ElevenLabs sound effects, then review using the listening tool |
| Apply | Undoable audio property edits and legacy Sound creation |
| Upload | Open Cloud audio upload and operation status; creator explicitly selected |
A sound ID, filename, or screenshot is **never** treated as listening evidence.
Every listening report records the SHA-256 of the bytes submitted, provider,
model, context, observations, uncertainty, and limitations. Signal measurements
are marked `listened: false`. Playing a sound is not proof that it was heard.
## Quick start
Requirements: Python 3.11+, Roblox Studio, and an MCP host with local stdio
support. The core has **no third-party Python dependencies**. FFmpeg is optional
for compressed-audio measurements and recording. Provider calls require network
access and your own provider credentials.
1. Download or clone this project.
2. Run local checks from the project directory:
```sh
python -m unittest discover -v
python studio/build_plugin.py
```
3. Configure your MCP host with the absolute `run.py` path. Example:
```json
{
"mcpServers": {
"roblox-audio": {
"command": "python",
"args": ["C:/projects/roblox-audio-mcp/run.py", "--media-dir", "C:/projects/roblox-audio-mcp/media", "--pairing-file", "C:/projects/roblox-audio-mcp/.ramcp/pairing-token.txt"]
}
}
}
```
This is a generic stdio configuration example, not a verified config for
every product. Use your client's equivalent command/args configuration.
ChatGPT web-only remote connectors cannot directly run this local stdio
server. Remote Streamable HTTP hosting is not implemented in this release.
4. Install `studio/RobloxAudioMCP.rbxmx` as a **local Studio plugin**. See
[Studio setup](docs/studio-setup.md). It must not run as a game Script.
5. Start/restart the MCP connection in your host. The server writes a short-lived
pairing token to the file specified above. Paste that token in the plugin,
use port `44755`, and click **Connect this workspace**. Allow the plugin to
reach `127.0.0.1` when Studio prompts. It starts with edits/previews off.
6. Ask your assistant to run `bridge_status`, then `studio_sessions`, and verify
the intended workspace. Enable edits/previews only in the intended workspace.
7. Copy audio into `media/`, or use `roblox_download_audio` with an accessible
asset ID. Call `audio_measure` for local measurements.
The server is launched by the MCP host. Running it manually waits for MCP JSON
on stdin; that is normal. Only one process can bind a given port. If several AI
hosts are running, use a distinct port and pairing file for each. A Studio plugin
connection talks to one server at a time.
## Enable listening, generation and uploads
Configure these as **environment variables of the MCP server process** using
your host's secret mechanism. They are not sent to the Studio plugin. A local
`.env` file is not automatically loaded.
| Variable | Purpose |
| --- | --- |
| `GEMINI_API_KEY` | Actual audio analysis through Gemini |
| `GEMINI_MODEL` | An audio-input model ID available to your account; explicitly required |
| `ELEVENLABS_API_KEY` | Sound-effect generation |
| `ELEVENLABS_MODEL` | Optional generation model override; default `eleven_text_to_sound_v3` |
| `ROBLOX_API_KEY` | Authenticated audio download/upload/status with the required asset permissions |
| `RAMCP_TOKEN` | Optional fixed local pairing token, at least 24 characters; otherwise random per process |
Open-source code does not make provider usage free. Provider terms and asset
rights are separate from this project's MIT license. Uploaded audio still goes
through Roblox processing/moderation and requires permission for the intended
experience. This release does not automatically grant those permissions.
## Example assistant request
> Work only in the Studio session I approve. This is a colorful racing game.
> Inspect the garage door's sound and trigger. Obtain the actual audio and
> listen: it should feel like a heavy electric shutter, not a rusty wooden door.
> Compare two alternatives or generate one. Explain what you heard, apply the
> chosen asset with undo support, and evaluate a recording in the garage.
> If audio cannot be accessed or heard, say so rather than judging the filename.
The assistant orchestrates tools. There is no autonomous background process
that changes every sound without a request. Sound quality remains contextual
and subjective; confidence is not an objective score.
## Recording gameplay audio
See [capture setup](docs/capture.md). Recording is optional and explicit; no
microphone is selected automatically. Configure an isolated loopback input if
possible. A system mix can include unrelated applications.
## Development and contribution
```sh
python -m unittest discover -v
python -m compileall -q roblox_audio_mcp
python studio/build_plugin.py
```
See [architecture](docs/architecture.md), [contributing](CONTRIBUTING.md), and
[security](SECURITY.md). This project is independent and not endorsed by Roblox,
Google, ElevenLabs, OpenAI, or Anthropic.
## Current boundaries
- Local stdio MCP only; per-client compatibility remains to be tested.
- General inspection and existing-script edits are included. Full scene design,
screenshots, animation, playtest control, and Creator Store search are not
included; use this alongside a general Studio MCP for those tasks.
- AudioPlayer/Wire graphs are inventoried; new routing graphs are not created.
- Inventory pagination can shift if objects are changed during the scan.
- No unrestricted remote Luau execution or automatic game publishing.
- Audio download can fail due to rights/permissions. Playback capture or the
original source file is then needed; the bridge does not bypass access rules.
- Recording and remote providers need independent live validation on your setup.
- No perceptual tuning loop is considered verified until real audio capture and
before/after listening have succeeded.
MIT licensed. Created by Aashish Sijapati.
TDQS
Scored across 19 tools
The tools are mostly distinct and clearly partitioned between Studio operations, local audio handling, Roblox asset operations, and bridge diagnostics. A few audio-inspection tools such as audio_preview, audio_listen, audio_compare, and audio_measure are adjacent and could be confused at a glance, but their descriptions clarify the intended differences.
Names consistently use snake_case and meaningful domain prefixes such as studio_, audio_, roblox_, and bridge_. The main deviation is that some tools are verb-led while others are noun-led, but the pattern remains readable and predictable overall.
Nineteen tools is slightly heavy, but the server spans several real subdomains: Studio integration, local audio analysis, AI review/generation, and Roblox asset upload/download. Each tool appears to earn its place, though the surface is close to being too broad.
The set covers a strong audio lifecycle: inspect, create, patch, preview, record, measure, listen, compare, generate, upload, and download. Notable gaps remain around deletion/cleanup operations for Studio audio objects or local files, and there is no script creation tool, but most core workflows are supported.