> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hyperspell.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Codex

> Save local work notes, capture activity in Hyperspell, and continue recent work in Codex.

Connect Codex to Hyperspell through [MCP](https://docs.hyperspell.com/agents/mcp.md) or the
[command line tool](https://docs.hyperspell.com/agents/cli.md). The optional native Hyperspell Activity plugin
adds local work notes, opted-in activity capture and explicit session handoff.
Connecting MCP alone does not install this plugin.

If you used the Hyperspell daemon, it configured Codex's brain connection and
`~/.codex/AGENTS.md`. Its `hyperspell activity status` command describes the
**Claude Code** activity plugin. Check Codex itself with `codex plugin list`; if
`hyperspell-activity@hyperspell-codex` is absent, Codex session capture is not
installed. Codex can still call the MCP `log_activity` tool for a single summary.
Saved activity entries describe past sessions; use `codex plugin list` for the
current installation state on this machine.

## Install the activity plugin

Use current Codex with local command hooks and Python 3.11 or later. The plugin is
tested with CLI 0.163.0. In Codex Desktop, use a local session with Python available;
cloud-orchestrated ChatGPT Work does not run these local plugin hooks.

Activity 0.1.6 and later need the guarded `log_activity_if_current` tool on the
connected brain. If Codex uses the local `hyperbrain-mcp` connector installed by
the daemon, it also needs `hyperspell-brain[mcp]` 0.10.1 or later. Once that CLI
release is published, close applications using the connector and run:

```bash theme={null}
uv tool install --force 'hyperspell-brain[mcp]>=0.10.1,<0.11'
```

This replaces the daemon's older installation constraint; `hyperbrain update`
alone cannot cross a recorded `>=0.9,<0.10` bound. If your connector instead runs
through `uvx`, set its `--from` argument to `hyperspell-brain[mcp]>=0.10.1,<0.11`.
A hosted `/mcp` connection uses the server's catalog and does not need this local
CLI upgrade. After reopening Codex, verify `log_activity_if_current` is available
before enabling capture; the older `log_activity` tool is not a substitute.

In the [Hyperspell dashboard](https://app.hyperspell.com/settings?pane=connect-agents),
open Settings, then Connect Agents, then Activity plugin, choose the Codex tab and
click **Download Codex plugin**. Extract it to a directory you will keep, and run:

```bash theme={null}
codex plugin marketplace add /absolute/path/to/extracted-marketplace
codex plugin add hyperspell-activity@hyperspell-codex
```

Start a new conversation and review and trust the plugin's hooks when prompted.
Managed organization policy may restrict hooks. The plugin uses your existing
Hyperspell MCP connection and does not install credentials.
Finish conversations that loaded an older version before upgrading or removing it:
Codex deletes that version's cached hook scripts, but running conversations may
still call them and report `No such file or directory`.
Run `codex plugin list` to confirm it is installed, then ask
`$hyperspell-activity status` in the new conversation to confirm its hooks are
running. A working MCP connection alone does not verify the hooks.

Version 0.1.1 and later use the bundled local tool for `status`, capture and
handoff; the default Codex shell sandbox needs no extra writable root. If the
tool is missing, update the plugin and start a new conversation.

With version 0.1.0, these commands may report unavailable local storage under
`workspace-write`. Until you can upgrade, start one Codex session with access to
the plugin's private data directory:

```bash theme={null}
codex -c 'sandbox_workspace_write.writable_roots=["/Users/you/.codex/plugins/data/hyperspell-activity-hyperspell-codex"]'
```

Use your actual home directory, then check `status` in that new conversation.

## Enable capture and handoff

Capture and handoff start off. Ask Codex:

```text theme={null}
Use $hyperspell-activity to configure capture suggest and handoff on,
using my hyperspell-context MCP server.
```

Replace the server name if your connection uses another name. Capture also needs
you to turn on **Activity capture** in the dashboard, under Settings, then Connect
Agents; until then the plugin pauses and says why. See
[Agent activity capture](https://docs.hyperspell.com/agent-activity/overview.md#you-turn-it-on-yourself).

The share setting `suggest` or `personal` keeps new entries private to you, and
`suggest` no longer sends an Inbox question for a new entry. `shared` shares at once
where your organization allows direct sharing. Where it does not,
every save fails until you switch to `personal`. The credential must belong to a
person; a workspace key cannot save activity. See
[Sharing and review](https://docs.hyperspell.com/agent-activity/sharing.md).

## Capture and continue work

After a working turn, the plugin saves a small local note. Use
`$hyperspell-activity now` to capture a summary in the brain, and
`$hyperspell-activity status` to check the saved entry ID and any error.
If local storage is busy, work notes remain queued across process exits and recover
on the next hook or `status` command. A full queue or unavailable disk reports that
new work could not be saved; existing queued work is preserved.

The remote entry lives in the vault as a normal searchable memory containing the
work summary, decisions, next steps and links. Later captures update the saved
entry. The plugin does not upload the full transcript or tool outputs; its local
handoff notes remain on this machine.

## What the vault keeps

The plugin keeps one evolving entry for each repository and branch and reuses the
saved entry ID across sessions. Another machine without the saved ID can create a
separate entry. Claude and Codex keep separate local notes. Only the summary,
decisions, next steps and links are saved: no transcript, tool output or file
contents. See [what is sent](https://docs.hyperspell.com/agent-activity/overview.md#what-is-sent) and
[private history](https://docs.hyperspell.com/agent-activity/history-and-continuing.md#private-history), which
explains how to read or share an earlier capture. For example entries, see
[one fix across two sessions](https://docs.hyperspell.com/integrations/all/vault.md#example-one-fix-two-sessions).

## Manage sharing from Codex

Ask: "Show my pending session entries, read the ones about this branch, and share
the handoff fix. Keep the other test entry private." Codex can perform authorized
decisions without opening the dashboard, using your personal credential and the
sharing tools described in [Sharing and review](https://docs.hyperspell.com/agent-activity/sharing.md). The
updated [CLI](https://docs.hyperspell.com/agents/cli.md#review-session-sharing-from-the-terminal) offers the same
operations when those tools are unavailable. Installing the activity plugin alone
does not update the server or CLI.

## Continue saved work

In a new conversation, use `$hyperspell-activity continue`. Select a numbered
note from the list. Codex receives the historical context and continues that work;
it does not switch your Git branch. The status shows the resume count and attached
characters. Notes are local to this machine and separate from Claude's notes.

Automatic capture requests one continuation at a turn boundary after pending work
has been quiet for 15 minutes, or after compaction. It uses the active conversation
and normal MCP permissions. It does not wake an idle model or guarantee a write
at exit. Use `now` before clearing or closing when the brain must be current.

## Pause or remove

Use `$hyperspell-activity pause` or `resume` for this session's brain writes.
Configure `share off` to disable captures while keeping local notes. Disable the
plugin in `/plugins` to stop all hooks, or uninstall it with:

```bash theme={null}
codex plugin remove hyperspell-activity@hyperspell-codex
```

If a capture fails, inspect `status` and the MCP result before retrying. A pending
capture belongs to its originating session; ask to cancel that reservation by its
session ID only when you intend to release it. Cancellation does not undo a remote
write. Existing brain entries remain after uninstalling the plugin.

For Cursor, use its separate [native plugin](https://docs.hyperspell.com/agents/cursor.md). The clients share
capture safeguards but keep separate local notes and installation settings.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.