mcp-music-studio 0.2.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +95 -116
- package/dist/mcp-app.html +51 -51
- package/dist/server.js +1 -1
- package/dist/strudel-app.html +16 -15
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,27 +1,61 @@
|
|
|
1
1
|
# MCP Music Studio
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://smithery.ai/server/linxule/mcp-music-studio)
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Two-mode creative music studio for AI: **scored composition** (ABC notation with sheet music) and **live performance** (Strudel live coding with TidalCycles). Interactive UI renders inline in Claude Desktop, claude.ai, and other MCP clients.
|
|
6
6
|
|
|
7
|
-
##
|
|
7
|
+
## Quick Start — No Install Required
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
- **30 instruments** — selectable from UI or via tool parameter, with fuzzy matching
|
|
11
|
-
- **Three rendering modes** — ext-apps inline UI for Claude Desktop/VS Code, browser fallback for CLI environments, configurable via `--render-mode`
|
|
12
|
-
- **`get-music-guide` tool** — on-demand reference for AI systems (instruments, drums, ABC syntax, arrangements, genre templates, MIDI directives)
|
|
13
|
-
- **7 `music://guide/*` resources** — same content for resource-capable clients
|
|
14
|
-
- **Note highlighting** — currently playing notes light up during playback
|
|
15
|
-
- **Forgiving parser** — warnings don't block playback, only fatal errors do
|
|
16
|
-
- **Streaming render** — sheet music appears as the AI types (`ontoolinputpartial`)
|
|
17
|
-
- **Tempo slider** — warp control in the UI
|
|
18
|
-
- **Fullscreen mode** — via ext-apps `requestDisplayMode`
|
|
9
|
+
Paste this URL into any MCP client that supports remote servers:
|
|
19
10
|
|
|
20
|
-
|
|
11
|
+
```
|
|
12
|
+
https://mcp-music-studio.linxule.workers.dev/mcp
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
**Claude Desktop / claude.ai:**
|
|
16
|
+
Settings → Connectors → Add Connector → paste the URL above → done.
|
|
17
|
+
|
|
18
|
+
**Claude Code:**
|
|
19
|
+
```bash
|
|
20
|
+
claude mcp add --transport http music-studio https://mcp-music-studio.linxule.workers.dev/mcp
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
That's it — ask Claude to play a song or create a beat.
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## What You Get
|
|
28
|
+
|
|
29
|
+
### Scored Composition (ABC Notation)
|
|
30
|
+
Write sheet music → see it rendered → hear it played with multi-instrument audio.
|
|
31
|
+
|
|
32
|
+
- **8 style presets** — rock, jazz, bossa, waltz, march, reggae, folk, classical — one parameter adds drums + bass + chord accompaniment
|
|
33
|
+
- **30 instruments** — piano, strings, brass, woodwinds, synths — selectable by name
|
|
34
|
+
- **Visual sheet music** — notes highlight as they play
|
|
35
|
+
- **Streaming render** — sheet music appears as the AI types
|
|
36
|
+
- **WAV download** — export audio as WAV files directly from the UI
|
|
37
|
+
- **`get-music-guide`** — 7 reference topics (instruments, drums, ABC syntax, arrangements, genres, styles, MIDI directives)
|
|
38
|
+
|
|
39
|
+
### Live Performance (Strudel)
|
|
40
|
+
Write code → hear it play → edit in a live REPL.
|
|
41
|
+
|
|
42
|
+
- **TidalCycles mini-notation** in JavaScript
|
|
43
|
+
- **72 drum machine banks** + **128 GM instruments** + built-in synths
|
|
44
|
+
- **Full effects chain** — filters, reverb, delay, FM synthesis
|
|
45
|
+
- **Editable REPL** — users can tweak the code and hear changes instantly
|
|
46
|
+
- **Record & download** — capture live audio and export as WAV
|
|
47
|
+
- **`get-strudel-guide`** — 7 reference topics (mini-notation, sounds, effects, patterns, genres, tips, advanced)
|
|
21
48
|
|
|
22
|
-
|
|
49
|
+
### Shared
|
|
50
|
+
- **`search-music-docs`** — semantic search over strudel.cc and ABCJS documentation
|
|
23
51
|
|
|
24
|
-
|
|
52
|
+
---
|
|
53
|
+
|
|
54
|
+
## Local Install (Optional)
|
|
55
|
+
|
|
56
|
+
The remote URL above works without any local setup. If you prefer running locally (offline use, lower latency), install via npm:
|
|
57
|
+
|
|
58
|
+
### CLI One-Liners
|
|
25
59
|
|
|
26
60
|
```bash
|
|
27
61
|
# Claude Code
|
|
@@ -32,11 +66,15 @@ codex mcp add -- npx -y mcp-music-studio --stdio
|
|
|
32
66
|
|
|
33
67
|
# Gemini CLI
|
|
34
68
|
gemini mcp add -- npx -y mcp-music-studio --stdio
|
|
69
|
+
|
|
70
|
+
# OpenCode
|
|
71
|
+
opencode mcp add music-studio -- npx -y mcp-music-studio --stdio
|
|
35
72
|
```
|
|
36
73
|
|
|
37
|
-
### Claude Desktop
|
|
74
|
+
### JSON Config (Claude Desktop, Cursor, Windsurf, etc.)
|
|
38
75
|
|
|
39
|
-
|
|
76
|
+
<details>
|
|
77
|
+
<summary>Claude Desktop — edit config file</summary>
|
|
40
78
|
|
|
41
79
|
| OS | Path |
|
|
42
80
|
|----|------|
|
|
@@ -54,12 +92,12 @@ Config file location:
|
|
|
54
92
|
}
|
|
55
93
|
}
|
|
56
94
|
```
|
|
95
|
+
</details>
|
|
57
96
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
Add to `.vscode/mcp.json` (project) or user settings:
|
|
97
|
+
<details>
|
|
98
|
+
<summary>VS Code / Trae / PearAI</summary>
|
|
61
99
|
|
|
62
|
-
|
|
100
|
+
Add to `.vscode/mcp.json` — note: uses `"servers"` not `"mcpServers"`:
|
|
63
101
|
|
|
64
102
|
```json
|
|
65
103
|
{
|
|
@@ -71,10 +109,12 @@ Add to `.vscode/mcp.json` (project) or user settings:
|
|
|
71
109
|
}
|
|
72
110
|
}
|
|
73
111
|
```
|
|
112
|
+
</details>
|
|
74
113
|
|
|
75
|
-
|
|
114
|
+
<details>
|
|
115
|
+
<summary>Cursor</summary>
|
|
76
116
|
|
|
77
|
-
Add to `~/.cursor/mcp.json
|
|
117
|
+
Add to `~/.cursor/mcp.json`:
|
|
78
118
|
|
|
79
119
|
```json
|
|
80
120
|
{
|
|
@@ -86,8 +126,10 @@ Add to `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project):
|
|
|
86
126
|
}
|
|
87
127
|
}
|
|
88
128
|
```
|
|
129
|
+
</details>
|
|
89
130
|
|
|
90
|
-
|
|
131
|
+
<details>
|
|
132
|
+
<summary>Windsurf</summary>
|
|
91
133
|
|
|
92
134
|
Add to `~/.codeium/windsurf/mcp_config.json`:
|
|
93
135
|
|
|
@@ -101,8 +143,10 @@ Add to `~/.codeium/windsurf/mcp_config.json`:
|
|
|
101
143
|
}
|
|
102
144
|
}
|
|
103
145
|
```
|
|
146
|
+
</details>
|
|
104
147
|
|
|
105
|
-
|
|
148
|
+
<details>
|
|
149
|
+
<summary>Windows</summary>
|
|
106
150
|
|
|
107
151
|
On Windows, `npx` is a `.cmd` file and requires a shell wrapper:
|
|
108
152
|
|
|
@@ -116,87 +160,42 @@ On Windows, `npx` is a `.cmd` file and requires a shell wrapper:
|
|
|
116
160
|
}
|
|
117
161
|
}
|
|
118
162
|
```
|
|
163
|
+
</details>
|
|
119
164
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
ChatGPT only supports remote HTTPS MCP servers. Run the HTTP transport and expose via tunnel:
|
|
123
|
-
|
|
124
|
-
```bash
|
|
125
|
-
npx mcp-music-studio
|
|
126
|
-
# Server starts on http://localhost:3001/mcp
|
|
127
|
-
# Use ngrok, Cloudflare Tunnel, etc. to expose publicly
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
### HTTP Transport
|
|
131
|
-
|
|
132
|
-
```bash
|
|
133
|
-
npx mcp-music-studio
|
|
134
|
-
# Server starts on http://localhost:3001/mcp
|
|
135
|
-
```
|
|
136
|
-
|
|
137
|
-
## Tools
|
|
138
|
-
|
|
139
|
-
### `play-sheet-music`
|
|
140
|
-
|
|
141
|
-
Creates and plays music with visual sheet music and multi-instrument audio.
|
|
142
|
-
|
|
143
|
-
| Parameter | Type | Description |
|
|
144
|
-
|-----------|------|-------------|
|
|
145
|
-
| `abcNotation` | string | ABC notation with optional chord symbols |
|
|
146
|
-
| `instrument` | string? | Default instrument (e.g., "Violin", "Flute") |
|
|
147
|
-
| `style` | enum? | Accompaniment style: rock, jazz, bossa, waltz, march, reggae, folk, classical |
|
|
148
|
-
| `tempo` | number? | BPM (40-240) |
|
|
149
|
-
| `swing` | number? | Swing feel (0-100) |
|
|
150
|
-
| `transpose` | number? | Semitones (-12 to 12) |
|
|
151
|
-
|
|
152
|
-
**Example — jazz arrangement:**
|
|
153
|
-
```json
|
|
154
|
-
{
|
|
155
|
-
"abcNotation": "X:1\nT:Blue Note\nM:4/4\nL:1/8\nK:Bb\n\"Bbmaj7\"d2 f2 d2 Bc | \"Eb7\"_e2 g2 e2 cB | \"Dm7\"d2 f2 a2 fd | \"G7\"g2 f2 e2 dc |",
|
|
156
|
-
"style": "jazz",
|
|
157
|
-
"instrument": "Alto Sax",
|
|
158
|
-
"tempo": 140
|
|
159
|
-
}
|
|
160
|
-
```
|
|
161
|
-
|
|
162
|
-
### `get-music-guide`
|
|
163
|
-
|
|
164
|
-
Returns reference material for composition. Topics:
|
|
165
|
+
<details>
|
|
166
|
+
<summary>Render modes (for non-ext-apps clients)</summary>
|
|
165
167
|
|
|
166
|
-
|
|
167
|
-
|-------|----------|
|
|
168
|
-
| `instruments` | All 128 GM instruments by family, program numbers, combo suggestions |
|
|
169
|
-
| `drums` | Percussion notes, pattern syntax, 8 ready-to-use patterns |
|
|
170
|
-
| `abc-syntax` | Notes, rests, chords, repeats, dynamics, multi-voice, lyrics |
|
|
171
|
-
| `arrangements` | Multi-voice patterns, volume balancing, accompaniment setup |
|
|
172
|
-
| `genres` | Complete ABC examples: jazz, blues, folk, minuet, rock, bossa, lullaby |
|
|
173
|
-
| `styles` | What each style preset does and when to use it |
|
|
174
|
-
| `midi-directives` | Full `%%MIDI` reference for ABCJS |
|
|
168
|
+
The server auto-detects ext-apps support. For clients that don't support it (Cherry Studio, CLI environments), use `--render-mode`:
|
|
175
169
|
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
|
181
|
-
|------|------|----------|
|
|
182
|
-
| `auto` | (default) | Inline ext-apps UI for Claude Desktop, VS Code |
|
|
183
|
-
| `browser` | `--render-mode browser` | Saves HTML player and opens in system browser |
|
|
184
|
-
| `html` | `--render-mode html` | Returns HTML as embedded resource in response |
|
|
185
|
-
|
|
186
|
-
Use `--output-dir` to control where HTML player files are saved (default: `~/Desktop/mcp-music-studio`).
|
|
187
|
-
|
|
188
|
-
**Example — Cherry Studio, CLI environments, or other non-ext-apps clients:**
|
|
170
|
+
| Mode | Behavior |
|
|
171
|
+
|------|----------|
|
|
172
|
+
| `auto` (default) | Inline UI for Claude Desktop, VS Code |
|
|
173
|
+
| `browser` | Saves HTML and opens in system browser |
|
|
174
|
+
| `html` | Returns HTML as embedded resource |
|
|
189
175
|
|
|
190
176
|
```json
|
|
191
177
|
{
|
|
192
178
|
"mcpServers": {
|
|
193
179
|
"music-studio": {
|
|
194
180
|
"command": "npx",
|
|
195
|
-
"args": ["-y", "mcp-music-studio", "--stdio", "--render-mode", "browser"
|
|
181
|
+
"args": ["-y", "mcp-music-studio", "--stdio", "--render-mode", "browser"]
|
|
196
182
|
}
|
|
197
183
|
}
|
|
198
184
|
}
|
|
199
185
|
```
|
|
186
|
+
</details>
|
|
187
|
+
|
|
188
|
+
---
|
|
189
|
+
|
|
190
|
+
## Tools
|
|
191
|
+
|
|
192
|
+
| Tool | Description |
|
|
193
|
+
|------|-------------|
|
|
194
|
+
| `play-sheet-music` | ABC notation → visual sheet music + multi-instrument audio |
|
|
195
|
+
| `play-live-pattern` | Strudel code → live-coded patterns with synthesis + effects |
|
|
196
|
+
| `get-music-guide` | ABC reference (7 topics: instruments, drums, syntax, genres...) |
|
|
197
|
+
| `get-strudel-guide` | Strudel reference (7 topics: sounds, effects, patterns, genres...) |
|
|
198
|
+
| `search-music-docs` | Semantic search over strudel.cc and ABCJS docs |
|
|
200
199
|
|
|
201
200
|
## Development
|
|
202
201
|
|
|
@@ -204,32 +203,12 @@ Use `--output-dir` to control where HTML player files are saved (default: `~/Des
|
|
|
204
203
|
bun install
|
|
205
204
|
bun run dev # watch + serve (hot reload)
|
|
206
205
|
bun run build # production build
|
|
207
|
-
bun run
|
|
208
|
-
```
|
|
209
|
-
|
|
210
|
-
## Architecture
|
|
211
|
-
|
|
212
|
-
```
|
|
213
|
-
mcp-music-studio/
|
|
214
|
-
├── server.ts # MCP server: tools, resources, guides, forgiving parser
|
|
215
|
-
├── main.ts # Entry point: HTTP + stdio transports
|
|
216
|
-
├── mcp-app.html # HTML shell (Vite inlines everything for ext-apps UI)
|
|
217
|
-
├── src/
|
|
218
|
-
│ ├── mcp-app.ts # Ext-apps client: rendering, audio, streaming
|
|
219
|
-
│ ├── mcp-app.css # Styles: dark mode, note highlighting, toolbar
|
|
220
|
-
│ ├── music-logic.ts # Shared: instruments, presets, ABC processing
|
|
221
|
-
│ ├── server-logic.ts # Server: parse validation, result construction
|
|
222
|
-
│ ├── browser-fallback.ts # Browser player: HTML generation, auto-open
|
|
223
|
-
│ └── global.css # Base reset
|
|
224
|
-
├── tests/ # Vitest tests
|
|
225
|
-
├── vite.config.ts # Single-file HTML bundling
|
|
226
|
-
├── tsconfig.json # Client TypeScript config
|
|
227
|
-
└── tsconfig.server.json # Server TypeScript config
|
|
206
|
+
bun run test # run tests
|
|
228
207
|
```
|
|
229
208
|
|
|
230
209
|
## Attribution
|
|
231
210
|
|
|
232
|
-
|
|
211
|
+
Forked from the [Sheet Music Server](https://github.com/modelcontextprotocol/ext-apps/tree/main/examples/sheet-music-server) example from [MCP ext-apps](https://github.com/modelcontextprotocol/ext-apps) by Anthropic, licensed under MIT.
|
|
233
212
|
|
|
234
213
|
## License
|
|
235
214
|
|