install
One command. The MCP server lands on your machine, your Claude Code / Claude Desktop / Cursor / Codex pick it up, and the daemon app keeps your iMessage, browser, and calendar syncs running in the background.
the one-liner
curl -fsSL https://cosmos.polarity-lab.com/install.sh | sh
On macOS this installs the full stack. On linux and windows it installs the MCP server (the daemon app is mac-only right now).
what the script does
- Checks for Node 20+. Installs it via Homebrew if missing on macOS. On other platforms it tells you to install Node and re-run.
- Installs
@polarity-lab/cosmos-mcpfrom npm globally. Falls back tosudoif your npm prefix needs it. - Drops
Cosmos Sync.appinto/Applicationsand registers it as a login item, so the daemon starts at boot. macOS only. - Registers the
cosmos-mcp://URL scheme so the one-tap key handoff from the browser works. - Merges cosmos into every MCP client you have installed. Claude Desktop, Claude Code, Cursor, Codex, Zed, Continue. The script never overwrites or removes any existing server you have configured. It backs every file up to
<path>.bak.<timestamp>before touching it, and re-running the installer is a no-op. Continue's YAML config (the current default) is the one exception, since YAML auto-merge in a shell script cannot safely preserve comments and formatting; for those users the installer prints the exact snippet to paste. - Opens your browser to cosmos.polarity-lab.com/connectors so you can sign in and let the browser hand a fresh key into your macOS keychain. The key never appears on screen.
flags
--dry-run Print every step without making changes.
--no-app Skip the macOS daemon app. Install MCP server only.
--help Show usage.
--dry-run is the right move if you want to see exactly what the script would touch on your machine. It enumerates every file path, every command, every config it would merge.
manual path
If you would rather skip the curl pipe entirely.
read the script first
git clone https://github.com/teampolarity/cosmos-mcp.git
less cosmos-mcp/install/install.sh # or open it in any editor
bash cosmos-mcp/install/install.sh --dry-run
Or pull just the script and inspect it before running.
curl -fsSL https://cosmos.polarity-lab.com/install.sh -o install.sh
less install.sh
bash install.sh --dry-run
bash install.sh
fully by hand
If you do not want the installer at all, the three things it does that matter are.
- Install the MCP server.
npm install -g @polarity-lab/cosmos-mcp - Add cosmos to your MCP client.
For Claude Code, run.
claude mcp add cosmos --scope user -- npx -y @polarity-lab/cosmos-mcpFor Claude Desktop, add this to
~/Library/Application Support/Claude/claude_desktop_config.jsonalongside whatever else you have there.{ "mcpServers": { "cosmos": { "command": "npx", "args": ["-y", "@polarity-lab/cosmos-mcp"] } } }For Cursor the same JSON lands at
~/.cursor/mcp.json. For Codex add a[mcp_servers.cosmos]block to~/.codex/config.toml. - Provision a key. Sign in at cosmos.polarity-lab.com/connectors and tap "open in cosmos-mcp". The browser hands the key into your macOS keychain. If you already have a
pmk_...key, run.npx -y @polarity-lab/cosmos-mcp provision pmk_xxx
rollback
Every config the installer modified has a .bak.<timestamp> beside it. Restore the one you want.
# example
mv ~/.cursor/mcp.json.bak.20260525-143012 ~/.cursor/mcp.json
npm uninstall -g @polarity-lab/cosmos-mcp
rm -rf "/Applications/Cosmos Sync.app"
troubleshooting
"unidentified developer" on Cosmos Sync.app
The Sync.app is code-signed and notarized, but the first launch on a fresh machine sometimes still trips Gatekeeper. Right-click the app in /Applications, choose Open, then Open again in the dialog. macOS remembers the choice after that.
keychain prompt on every sync
The first time cosmos-mcp reads the key, macOS asks whether to allow access. Choose Always Allow so it stops asking. If you accidentally clicked Allow Once, run npx -y @polarity-lab/cosmos-mcp provision pmk_xxx with your key to re-add the entry with the right permissions.
cosmos does not appear in Claude Code
Run claude mcp list to see what is wired. If cosmos is not there, the installer probably ran without the claude CLI on your PATH. Add it manually.
claude mcp add cosmos --scope user -- npx -y @polarity-lab/cosmos-mcp
cosmos does not appear in Cursor or Claude Desktop
Quit and relaunch the app. Both clients only load mcpServers at startup.
Source is at teampolarity/cosmos-mcp. The MCP server is MIT-licensed. The cognitive engine that backs the graph lives at cosmos.polarity-lab.com and is part of the Cosmos service.