modelbrain-mcp 0.0.0-stage → 0.1.1

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Matthew Firth
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,39 @@
1
- # Temporary Holding Version
1
+ # modelbrain-mcp
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ A thin [MCP](https://modelcontextprotocol.io) stdio client for [ModelBrain](https://modelbrain.net): a memory layer for AI assistants that runs on your own computer.
4
+
5
+ This package does not install or bundle ModelBrain. It connects to the ModelBrain desktop app already running on your machine. If ModelBrain is not installed, running this prints where to get it and exits, rather than failing silently.
6
+
7
+ ## Why a separate package
8
+
9
+ ModelBrain's own installed app already ships a binary, `mcp_server`, that speaks MCP over stdio and talks to the local ModelBrain daemon. This package finds that binary on the current machine and runs it. It exists so ModelBrain can be registered with the MCP Registry and the directories that list from it, with a reviewable package as the distribution target, while the actual engine stays out of this repository.
10
+
11
+ ## Requirements
12
+
13
+ - macOS (Apple Silicon) or Windows (x64 or arm64)
14
+ - [ModelBrain](https://modelbrain.net/get-it.html) installed
15
+
16
+ ## Use
17
+
18
+ Most MCP clients run a server with `npx`. Point your client's MCP config at:
19
+
20
+ ```json
21
+ {
22
+ "mcpServers": {
23
+ "modelbrain": {
24
+ "command": "npx",
25
+ "args": ["-y", "modelbrain-mcp"]
26
+ }
27
+ }
28
+ }
29
+ ```
30
+
31
+ Claude Desktop, Claude Code and Cursor users do not need this: ModelBrain's own app registers itself with those clients directly. See [modelbrain.net/docs](https://modelbrain.net/docs.html) for the full tool surface (`remember`, `recall`, `forget`, `expand`, `connector_sync`) and the [connect guides](https://modelbrain.net/docs.html#guides) for other clients.
32
+
33
+ ## License
34
+
35
+ MIT, for this wrapper package. ModelBrain itself is separate, proprietary software; see [modelbrain.net](https://modelbrain.net) for its own terms.
36
+
37
+ ## Security
38
+
39
+ See [SECURITY.md](SECURITY.md).
package/SECURITY.md ADDED
@@ -0,0 +1,13 @@
1
+ # Security
2
+
3
+ ## Reporting a vulnerability
4
+
5
+ Email security@modelbrain.net with a description and steps to reproduce. Please do not open a public issue for security reports.
6
+
7
+ We acknowledge reports within 72 hours and aim to ship a fix or a mitigation within 90 days. We ask for the same window before public disclosure.
8
+
9
+ ## What this package does
10
+
11
+ `modelbrain-mcp` is a small launcher. It finds the `mcp_server` binary that the ModelBrain desktop app installs on your computer and runs it, passing stdio through. It makes no network requests, reads no files other than checking for the installed binary, and stores nothing.
12
+
13
+ The ModelBrain app itself is separate software. Its data stays on your computer. See https://modelbrain.net/privacy.html for what leaves the machine and what does not.
@@ -0,0 +1,102 @@
1
+ #!/usr/bin/env node
2
+ 'use strict';
3
+
4
+ // Thin stdio client for ModelBrain (https://modelbrain.net).
5
+ //
6
+ // This package does not bundle ModelBrain or talk to its daemon directly.
7
+ // ModelBrain's own installed app already ships a binary, mcp_server, that
8
+ // does exactly that (connects to the resident daemon over a Unix socket on
9
+ // macOS or a named pipe on Windows, spawning the daemon on demand, then
10
+ // relays raw MCP bytes between its own stdio and that connection). This
11
+ // wrapper's only job is to find that binary on the current machine and
12
+ // exec it, or say plainly that it is not installed.
13
+ //
14
+ // Why a wrapper at all, instead of pointing a client straight at the
15
+ // installed binary: the MCP Registry, and directories that ingest from it,
16
+ // want a published package as the distribution target. This is that
17
+ // package, kept deliberately thin.
18
+
19
+ const { spawn } = require('node:child_process');
20
+ const fs = require('node:fs');
21
+ const os = require('node:os');
22
+ const path = require('node:path');
23
+
24
+ function macCandidates() {
25
+ const home = os.homedir();
26
+ return [
27
+ '/Applications/ModelBrain.app/Contents/MacOS/mcp_server',
28
+ path.join(home, 'Applications/ModelBrain.app/Contents/MacOS/mcp_server'),
29
+ ];
30
+ }
31
+
32
+ function windowsCandidates() {
33
+ const localAppData = process.env.LOCALAPPDATA;
34
+ if (!localAppData) return [];
35
+ return [path.join(localAppData, 'Programs', 'ModelBrain', 'mcp_server.exe')];
36
+ }
37
+
38
+ function candidatesForPlatform() {
39
+ if (process.platform === 'darwin') return macCandidates();
40
+ if (process.platform === 'win32') return windowsCandidates();
41
+ return [];
42
+ }
43
+
44
+ function findServerBinary() {
45
+ for (const candidate of candidatesForPlatform()) {
46
+ try {
47
+ fs.accessSync(candidate, fs.constants.X_OK);
48
+ return candidate;
49
+ } catch {
50
+ // Not there, or not executable. Try the next candidate.
51
+ }
52
+ }
53
+ return null;
54
+ }
55
+
56
+ function notFoundMessage() {
57
+ const lines = [
58
+ 'ModelBrain desktop app not detected on this computer.',
59
+ '',
60
+ 'modelbrain-mcp is a thin client: it connects to the ModelBrain app',
61
+ 'already running on your machine. It does not install or bundle',
62
+ 'ModelBrain itself.',
63
+ '',
64
+ ];
65
+ if (process.platform === 'darwin' || process.platform === 'win32') {
66
+ lines.push('Install ModelBrain, then run this again: https://modelbrain.net/get-it.html');
67
+ } else {
68
+ lines.push(
69
+ `${process.platform} is not part of this launch. ModelBrain currently`,
70
+ 'ships for macOS (Apple Silicon) and Windows (x64 and arm64) only:',
71
+ 'https://modelbrain.net/get-it.html'
72
+ );
73
+ }
74
+ return lines.join('\n');
75
+ }
76
+
77
+ function main() {
78
+ const binaryPath = findServerBinary();
79
+
80
+ if (!binaryPath) {
81
+ process.stderr.write(notFoundMessage() + '\n');
82
+ process.exitCode = 1;
83
+ return;
84
+ }
85
+
86
+ const child = spawn(binaryPath, process.argv.slice(2), { stdio: 'inherit' });
87
+
88
+ child.on('error', (err) => {
89
+ process.stderr.write(`Failed to start ModelBrain's MCP server: ${err.message}\n`);
90
+ process.exitCode = 1;
91
+ });
92
+
93
+ child.on('exit', (code, signal) => {
94
+ if (signal) {
95
+ process.kill(process.pid, signal);
96
+ return;
97
+ }
98
+ process.exitCode = code === null ? 1 : code;
99
+ });
100
+ }
101
+
102
+ main();
package/package.json CHANGED
@@ -1,6 +1,41 @@
1
1
  {
2
2
  "name": "modelbrain-mcp",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.1.1",
4
+ "description": "Thin MCP stdio client for ModelBrain, a local memory layer for AI assistants. Connects to the ModelBrain desktop app already running on your computer; does not bundle ModelBrain itself.",
5
+ "bin": {
6
+ "modelbrain-mcp": "bin/modelbrain-mcp.js"
7
+ },
8
+ "main": "bin/modelbrain-mcp.js",
9
+ "files": [
10
+ "bin/modelbrain-mcp.js",
11
+ "README.md",
12
+ "LICENSE",
13
+ "SECURITY.md"
14
+ ],
15
+ "engines": {
16
+ "node": ">=18"
17
+ },
18
+ "license": "MIT",
19
+ "author": "Matthew Firth <hello@modelbrain.net> (https://modelbrain.net)",
20
+ "homepage": "https://modelbrain.net",
21
+ "keywords": [
22
+ "mcp",
23
+ "model-context-protocol",
24
+ "modelbrain",
25
+ "memory",
26
+ "ai-memory",
27
+ "local-first"
28
+ ],
29
+ "os": [
30
+ "darwin",
31
+ "win32"
32
+ ],
33
+ "mcpName": "net.modelbrain/mcp",
34
+ "repository": {
35
+ "type": "git",
36
+ "url": "git+https://github.com/modelbrain/modelbrain-mcp.git"
37
+ },
38
+ "bugs": {
39
+ "url": "https://github.com/modelbrain/modelbrain-mcp/issues"
40
+ }
41
+ }