engine-dj-mcp 0.17.1 → 0.17.2

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.
Files changed (3) hide show
  1. package/README.md +102 -32
  2. package/dist/server.js +9 -4
  3. package/package.json +12 -4
package/README.md CHANGED
@@ -4,40 +4,58 @@
4
4
  [![npm](https://img.shields.io/npm/v/engine-dj-mcp)](https://www.npmjs.com/package/engine-dj-mcp)
5
5
  [![licence](https://img.shields.io/npm/l/engine-dj-mcp)](./LICENSE)
6
6
 
7
- An MCP server that gives an AI assistant your **Engine DJ** libraries — the
8
- one on your computer and the ones on your USB drives. It searches and audits
9
- them, reads the cues and beatgrids Engine stored, and builds playlists when
10
- you ask it to.
7
+ Ask Claude, or any AI assistant, about your **Engine DJ** library: find tracks
8
+ by BPM, key, genre or your own comments, check the collection for duplicates,
9
+ missing files and tracks with no cues, read the cues and beatgrids Engine
10
+ stored, and have playlists built or track tags fixed when you ask. It works
11
+ through MCP, the Model Context Protocol, the standard way AI apps such as
12
+ Claude Desktop, Claude Code, Cursor and VS Code connect to tools on your own
13
+ computer: the app starts this server, and the assistant calls it when a
14
+ question needs your library.
15
+
16
+ It reads the library on your computer and the ones on your USB drives. It
17
+ opens them **read-only at the operating-system level** and changes nothing
18
+ unless you start it with `--allow-writes` — then it can create and edit
19
+ playlists and edit genre, comment, label, year and rating, and it copies the
20
+ whole database to a backup before the first change. See [Safety](#safety).
21
+ The server itself sends nothing anywhere; what your AI app does with its
22
+ answers is covered in [PRIVACY.md](./PRIVACY.md).
23
+
24
+ **Status: Active · Pre-1.0.** In regular use and maintained; before 1.0 a MINOR
25
+ release may change behaviour, a PATCH never does. Changes are recorded in
26
+ [CHANGELOG.md](./CHANGELOG.md).
11
27
 
12
28
  > **Not affiliated with, endorsed by, or sponsored by inMusic Brands, Denon
13
29
  > DJ, or the Engine DJ product.** "Engine DJ" is used here only to name the
14
30
  > software whose library this tool reads and writes. No logos or brand
15
31
  > artwork from inMusic or Denon DJ are used in this project.
16
32
 
17
- Your library is opened **read-only at the operating-system level**. It is
18
- never written to unless you start the server with `--allow-writes` — see
19
- [Safety](#safety).
20
-
21
33
  ## What you can ask
22
34
 
23
35
  Once connected, these are ordinary questions in chat:
24
36
 
25
37
  - *"Something dark around 124 in a minor key I haven't played in six months."*
26
- - *"Which tracks still have no hot cue set?"*
27
38
  - *"Find me anything harmonically compatible with 8A between 138 and 142."*
28
- - *"What's in my ACID Beach playlist, in order?"*
29
- - *"Anything around 128 in ACID Beach?"*
30
- - *"What's broken in my collection — missing files, duplicates, bad tempos?"*
39
+ - *"What's broken in my collection — missing files, duplicates, tracks with no cues?"*
31
40
  - *"Where are the cue points on this track, and what tempo did Engine analyse?"*
32
41
  - *"Build me a playlist of everything in 5A from 140 BPM up."* (needs `--allow-writes`)
42
+ - *"Set the genre of these five tracks to Minimal and rate them four stars."* (needs `--allow-writes`)
33
43
 
34
44
  ## Install
35
45
 
46
+ You need [Node.js](https://nodejs.org) 22.16 or newer. There is nothing else
47
+ to install: every app below starts the server with `npx`, which downloads it
48
+ from npm the first time.
49
+
36
50
  ```bash
37
51
  npx engine-dj-mcp
38
52
  ```
39
53
 
40
- Claude Desktop — add to your configuration:
54
+ That command is what the apps run; you do not need to run it yourself.
55
+
56
+ ### Claude Desktop
57
+
58
+ Settings → Developer → Edit Config, and add to `claude_desktop_config.json`:
41
59
 
42
60
  ```json
43
61
  {
@@ -47,14 +65,43 @@ Claude Desktop — add to your configuration:
47
65
  }
48
66
  ```
49
67
 
50
- To let the assistant create playlists as well, add `--allow-writes` — a flag
51
- in `args` rather than an environment variable precisely so it is visible in
52
- the configuration you are reading:
68
+ Restart Claude Desktop.
69
+
70
+ ### Claude Code
71
+
72
+ ```bash
73
+ claude mcp add --scope user engine-dj -- npx -y engine-dj-mcp
74
+ ```
75
+
76
+ ### Cursor
77
+
78
+ [Add to Cursor](https://cursor.com/install-mcp?name=engine-dj&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsImVuZ2luZS1kai1tY3AiXX0%3D)
79
+ — or open this deep link directly, or add the same `mcpServers` entry as for
80
+ Claude Desktop to `~/.cursor/mcp.json`:
81
+
82
+ ```text
83
+ cursor://anysphere.cursor-deeplink/mcp/install?name=engine-dj&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsImVuZ2luZS1kai1tY3AiXX0%3D
84
+ ```
85
+
86
+ ### VS Code
87
+
88
+ [Add to VS Code](https://vscode.dev/redirect/mcp/install?name=engine-dj&config=%7B%22command%22%3A%22npx%22%2C%22args%22%3A%5B%22-y%22%2C%22engine-dj-mcp%22%5D%7D)
89
+ — or run:
90
+
91
+ ```bash
92
+ code --add-mcp '{"name":"engine-dj","command":"npx","args":["-y","engine-dj-mcp"]}'
93
+ ```
94
+
95
+ ### Letting it write
96
+
97
+ To let the assistant create and edit playlists and edit track tags, add
98
+ `--allow-writes` to `args` — a flag rather than an environment variable
99
+ precisely so it is visible in the configuration you are reading:
53
100
 
54
101
  ```json
55
102
  {
56
103
  "mcpServers": {
57
- "engine-dj": { "command": "npx", "args": ["-y", "engine-dj-mcp@0.17.1", "--allow-writes"] }
104
+ "engine-dj": { "command": "npx", "args": ["-y", "engine-dj-mcp@0.17.2", "--allow-writes"] }
58
105
  }
59
106
  }
60
107
  ```
@@ -62,18 +109,33 @@ the configuration you are reading:
62
109
  Pin the version in this one. Unpinned, `npx` fetches whatever is newest at
63
110
  every launch, and this configuration gives that code write access to your
64
111
  library. Pinned, a new release reaches it only when you change the number.
65
-
66
- **Requirements:** Node.js 22.16 or newer (`node:sqlite` stopped needing a
67
- flag in 22.13, but the pre-write snapshot uses its `backup()`, added in
68
- 22.16;
69
- there are no native dependencies), and an Engine DJ library at schema 3.0.0
70
- through 3.0.2 — Engine DJ 4.5 and 5.x.
112
+ Quit Engine DJ before asking for a change; see [Writing](#writing).
113
+
114
+ ## Compatibility
115
+
116
+ - **macOS: yes.** Every check against a real library has been run on macOS,
117
+ and it finds libraries where Engine DJ keeps them there: `~/Music` and the
118
+ top of each drive under `/Volumes`.
119
+ - **Windows and Linux: not supported yet.** The test suite passes on Ubuntu,
120
+ but no real library has been read on either system. Off macOS the server
121
+ looks only in `~/Music/Engine Library`, so a library on a USB drive is not
122
+ found, and there is no option to point it somewhere else.
123
+ - **Node.js 22.16 or newer**, with no native dependencies. `node:sqlite`
124
+ stopped needing a flag in 22.13, but the pre-write backup uses its
125
+ `backup()`, added in 22.16. CI runs the full suite on Node 22.16 and 24, on
126
+ macOS and Ubuntu.
127
+ - **Engine DJ libraries at schema 3.0.0 through 3.0.2** — Engine DJ 4.5 and
128
+ 5.x. Everything here has been exercised against a real **schema 3.0.2**
129
+ library; 3.0.0 and 3.0.1 are accepted by the version check and covered by
130
+ generated fixtures, but no real library at those versions has been read.
131
+ Anything outside the range is listed with its version and refused, never
132
+ read on a guess.
71
133
 
72
134
  ## Tools
73
135
 
74
- Nine read-only tools, and four that write — `create_playlist`,
75
- `add_tracks_to_playlist`, `remove_tracks_from_playlist` and
76
- `reorder_playlist` — that appear only when you start the server with
136
+ Nine read-only tools, and five that write — `create_playlist`,
137
+ `add_tracks_to_playlist`, `remove_tracks_from_playlist`, `reorder_playlist`
138
+ and `update_track_metadata` — that appear only when you start the server with
77
139
  `--allow-writes`. Every tool that reads library data also accepts an
78
140
  optional `library` argument — see [Choosing a library](#choosing-a-library).
79
141
 
@@ -487,6 +549,9 @@ does.
487
549
 
488
550
  ## Safety
489
551
 
552
+ The guarantees this server makes about your library are listed in
553
+ [PRINCIPLES.md](./PRINCIPLES.md); this section is how they work.
554
+
490
555
  Your library is opened **read-only at the operating-system level**, not by
491
556
  convention and not by a `PRAGMA` a query could turn back off. Writes are
492
557
  refused by SQLite itself, and without `--allow-writes` no file is ever
@@ -675,11 +740,15 @@ changes. The track's **main cue** does not count towards it — Engine sets
675
740
  that as a playback marker rather than the DJ placing it. `has_beatgrid` does
676
741
  still test for the blob: `beatData` has no "written but empty" state.
677
742
 
678
- **It writes nothing but playlists, and only when you ask for it.** Without
679
- `--allow-writes` the library is opened read-only at the OS level and there is
680
- no tool that could write. With the flag, the four write tools add, edit and
681
- reorder playlists — and that is the whole list. Not a cue, not a tag, not a
682
- rating, and not even the recovery of a journal Engine DJ left behind.
743
+ **It writes playlists and five track fields, and only when you ask for it.**
744
+ Without `--allow-writes` the library is opened read-only at the OS level and
745
+ there is no tool that could write. With the flag, five write tools appear:
746
+ four create playlists and add, remove and reorder their tracks, and
747
+ `update_track_metadata` changes genre, comment, label, year and rating in
748
+ Engine's database — and that is the whole list. Not a cue, a loop or a
749
+ beatgrid; not a title, artist, album, play count or file path; not the tags
750
+ inside your audio files; and not even the recovery of a journal Engine DJ
751
+ left behind.
683
752
 
684
753
  **It does not read play history.** `Track.timeLastPlayed` answers "what have I
685
754
  not played in six months?", but the separate Engine history database —
@@ -707,4 +776,5 @@ their version and reported as unsupported rather than read on a guess.
707
776
 
708
777
  ## Licence
709
778
 
710
- MIT — see [LICENSE](./LICENSE).
779
+ MIT — see [LICENSE](./LICENSE). What this project guarantees and refuses to do:
780
+ [PRINCIPLES.md](./PRINCIPLES.md).
package/dist/server.js CHANGED
@@ -20,7 +20,12 @@ import { refreshIndex } from "./tools/refresh.js";
20
20
  import { CreatePlaylistInput, runCreatePlaylist, AddTracksToPlaylistInput, runAddTracksToPlaylist, RemoveTracksFromPlaylistInput, runRemoveTracksFromPlaylist, ReorderPlaylistInput, runReorderPlaylist, } from "./tools/write-playlist.js";
21
21
  import { UpdateTrackMetadataInput, runUpdateTrackMetadata } from "./tools/write-track-metadata.js";
22
22
  import { err, isEngineError, libraryNeedsRecovery } from "./errors.js";
23
- const RO = { readOnlyHint: true, destructiveHint: false, idempotentHint: true };
23
+ /**
24
+ * Every tool here works on files on this machine -- the Engine library, the
25
+ * sidecar index and the backups beside it -- and none reaches a network
26
+ * service, so each one says so: `openWorldHint: false` on all four sets.
27
+ */
28
+ const RO = { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false };
24
29
  /**
25
30
  * A write that only ever *adds*. `destructiveHint: false` is a claim with a
26
31
  * defined meaning in MCP -- "this tool performs only additive updates" -- and
@@ -28,20 +33,20 @@ const RO = { readOnlyHint: true, destructiveHint: false, idempotentHint: true };
28
33
  * create_playlist (a new playlist, nothing else touched) and of
29
34
  * add_tracks_to_playlist (new entries, existing ones left where they are).
30
35
  */
31
- const RW = { readOnlyHint: false, destructiveHint: false, idempotentHint: false };
36
+ const RW = { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: false };
32
37
  /**
33
38
  * A write that can destroy or reorganise what is already there:
34
39
  * remove_tracks_from_playlist deletes entries, reorder_playlist rewrites the
35
40
  * order of a list a DJ may be playing from live. Advertising either as
36
41
  * additive told a client it need not ask before calling.
37
42
  */
38
- const RW_DESTRUCTIVE = { readOnlyHint: false, destructiveHint: true, idempotentHint: false };
43
+ const RW_DESTRUCTIVE = { readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false };
39
44
  /**
40
45
  * A write that overwrites or clears what is there -- so destructive -- but
41
46
  * that a repeat of the same call leaves alone: a track already holding the
42
47
  * requested values is not written again. update_track_metadata.
43
48
  */
44
- const RW_OVERWRITE = { readOnlyHint: false, destructiveHint: true, idempotentHint: true };
49
+ const RW_OVERWRITE = { readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false };
45
50
  /**
46
51
  * name/version reported to every client on initialize. Read from
47
52
  * package.json rather than typed here, so the two cannot re-diverge the way
package/package.json CHANGED
@@ -1,7 +1,8 @@
1
1
  {
2
2
  "name": "engine-dj-mcp",
3
- "version": "0.17.1",
4
- "description": "MCP server for an Engine DJ library: search and audit it, read cues and beatgrids, and build playlists when you ask. Not affiliated with inMusic or Denon DJ.",
3
+ "version": "0.17.2",
4
+ "mcpName": "io.github.Venut-Technologies/engine-dj-mcp",
5
+ "description": "Ask an AI assistant about your Engine DJ library: find tracks by BPM, key, genre or comment, audit duplicates and missing files, read cues and beatgrids, and, only once you turn writes on, build playlists and edit genre, comment, label, year or rating, with a backup taken first. Not affiliated with inMusic or Denon DJ.",
5
6
  "keywords": [
6
7
  "mcp",
7
8
  "model-context-protocol",
@@ -13,10 +14,17 @@
13
14
  "claude",
14
15
  "ai",
15
16
  "playlist",
16
- "harmonic-mixing"
17
+ "harmonic-mixing",
18
+ "mcp-server",
19
+ "modelcontextprotocol",
20
+ "dj-library",
21
+ "camelot",
22
+ "duplicates",
23
+ "cue-points",
24
+ "beatgrid"
17
25
  ],
18
26
  "license": "MIT",
19
- "author": "Mikhail Chereshnev <venuttv@gmail.com>",
27
+ "author": "Mikhail Chereshnev",
20
28
  "repository": {
21
29
  "type": "git",
22
30
  "url": "git+https://github.com/Venut-Technologies/engine-dj-mcp.git"