CLI commands
Every memorinth command: making and choosing a cortex, connecting AI harnesses, checking what's connected, agent usage, the search model and the MCP server.
On this page
memorinth with no command shows each cortex on this computer, what it holds and the sessions using it. memorinth <command> -h says more about any command. mem is a short alias for memorinth.
Getting started
memorinth init
$ memorinth init [<path>] [--no-connect] [-y]Gets agents a memory in one step. It makes <path> a cortex (by default ~/Memorinth, or MEMORINTH_CORTEX), with memory/, decisions/ and facts/, makes it the cortex agents use, turns agents on, and connects the AI harnesses on this computer: Claude Code, Codex, Cursor and Gemini CLI. A folder of notes you already have works too; nothing in it changes.
In a terminal, init alone asks: this folder or another one, which harnesses to connect, whether to install the skills and the hooks, and whether to download the search and dictation models.
| Option | |
|---|---|
--no-connect |
Connect no harness |
-y, --yes |
Take the defaults without asking |
memorinth install
$ memorinth install [--no-path]Copies this memorinth to Memorinth’s own folder, where it stays put across updates, with mem beside it, and puts that folder on your PATH. Run it once after downloading memorinth on its own; the install scripts and the desktop app do this for you. --no-path leaves PATH as it is.
memorinth update
$ memorinth update [<version>] [--check] [--json]
$ memorinth update --rollbackInstalls the latest memorinth, or the version given, in place of this one: downloaded from downloads.memorinth.app, checked against the release’s checksums.txt, and installed as memorinth install does. --check only says whether a newer version exists (--json for scripts). --rollback puts back the version the last update replaced.
memorinth never updates by itself. The engine asks which version is the latest at most once a day, and status and doctor mention a newer one. MEMORINTH_NO_UPDATE_CHECK=1 turns that off. Where the desktop app installed memorinth, the app updates it.
Cortexes
$ memorinth cortexThe cortex agents use. c is short for cortex.
| Command | |
|---|---|
memorinth cortex list |
The cortexes on this computer (ls for short) |
memorinth cortex use [<path>] |
Make <path> the cortex agents use. Without a path, pick one with the arrow keys |
memorinth cortex new [<path>] |
Make a new cortex at <path>, and use it |
Sessions read the cortex when they start: sessions already running keep theirs, new ones get the one chosen here. The app shows the same choice.
Connecting agents
memorinth setup
$ memorinth setup <harness> [--cortex <path>] [--remove]Connects one AI harness, in every project, to the cortex agents use: the MCP server, the hooks (the briefing at session start and, where the harness allows it, a reminder to save) and the /memorinth-save and memorinth-search skills. <harness> is claude-code, codex, cursor or gemini. Run it again to repair a connection an older version made.
| Option | |
|---|---|
--cortex <path> |
Make this the cortex agents use, and turn agents on |
--remove |
Take Memorinth out of this harness |
memorinth agents
$ memorinth agents [on | off]Whether agents get a memory. off takes Memorinth out of every harness (its tools, hooks and skills); on connects them again. The same switch as in the app.
Checking
| Command | |
|---|---|
memorinth status [--json] |
Whether agents are on, and each cortex: what it holds, the facts due for a recheck, and the sessions using it |
memorinth doctor [--json] |
Which cortex agents use, what each harness has of Memorinth, which memorinth they run, the servers running now, and what to fix |
memorinth usage |
How agents used a cortex: calls by day, by agent and by tool |
memorinth usage covers this month unless you pass --today, --year or --days <n>, and reads the cortex agents use unless --cortex <path> names another. Memorinth logs when, which agent and which tool, never what was asked or written.
Search model
$ memorinth model [download]Says whether the search model (EmbeddingGemma-300M, about 220 MB) is on this computer; download fetches it now. Until it’s there, search uses keywords.
| Variable | |
|---|---|
MEMORINTH_MODEL_DIR |
Where models go |
MEMORINTH_EMBEDDINGS=off |
Turns semantic search off |
The MCP server
You rarely run these yourself: the harnesses and the app start them.
| Command | |
|---|---|
memorinth mcp serve [--client <name>] [--cortex <path>] |
The MCP server an agent runs, over stdio. --client names the agent, recorded as agent:<name> on what it writes |
memorinth mcp host [--idle-after <seconds>] |
The engine every session and the app share, so there’s one engine and one model. It leaves after ten minutes unused |
memorinth hook <event> |
Run by the hooks that setup installs |
Updated