Skip to content

Start a session with the Plannotator Inbox off (PLANNOTATOR_INBOX=off) - #4221

Merged
backnotprop merged 11 commits into
mainfrom
feat/inbox-start-off
Dec 1, 2026
Merged

backnotprop merged 11 commits into
mainfrom
feat/inbox-start-off

Conversation

@backnotprop

@backnotprop backnotprop commented Nov 29, 2026 •

Copy link
Copy Markdown
Owner

Start an agent with PLANNOTATOR_INBOX=off (for example PLANNOTATOR_INBOX=off claude) and its sessions begin with the Plannotator Inbox off. They stay off until the person types /plannotator-inbox on. A typed /plannotator-inbox off in a running session works exactly as before.

off, 0, false and disabled count as off, the same words every other Plannotator switch takes. Any other value, or no value, changes nothing. The setting is read once per process, when the host loads Plannotator, whether or not an Inbox connection exists yet (the DeepSeek Harness reads it only when its Inbox connection starts). So on plain Pi with its tool switched off, in Claude Code before the Inbox was turned on, or in OpenCode 2 with no Inbox found at load, a bare /plannotator-inbox already briefs nothing, and a connection that appears later in the process (a reload) starts off.

The session is in the same off state as a typed off: the Inbox window shows "Inbox off" for it, and replies wait. Plannotator's runtime then adds nothing about the Inbox to the agent's context:

  • no reminder
  • no open-thread list
  • no off sentence
  • no note after a compaction
  • nothing for a typed off before on (except OpenCode 1, below)
  • no briefing when the person types a bare /plannotator-inbox: it still opens the Inbox and shows them the address (two exceptions below)

What each host withholds

  • Claude Code (mod). The plannotator_inbox tool is not registered.
    • on registers it in the running session, then behaves as today's typed on: the on sentence, and the reminder at the next prompt where the reminder applies.
    • If the engine refuses the registration, the session stays off and silent. The person sees the existing "Plannotator Inbox off for this session." notice and the existing log line saying why.
    • A plugin auto reload keeps the state.
    • With no Inbox tool in the session (the Inbox never turned on here, or its tool switched off), on ends the start and the command is then answered as without the variable.
  • Pi / Oh My Pi. The tool stays inactive until on activates it.
  • OpenCode 1 and 2, DeepSeek Harness. The tool stays listed with its description, because these plugin APIs fix the tool list when the plugin loads.
    • Sends are refused with the existing off line; read_thread, search and get_guide_brief still answer.
    • Every session in the process starts off until on is typed in it.
    • An OpenCode subagent is off when any session in its chain was typed off; otherwise it is on when any session in its chain was turned on, and off when none was.
    • OpenCode 1 still briefs on a bare /plannotator-inbox. OpenCode 1 runs a model turn for every command's message, and an empty message makes the model answer its last reply again (command-turn.ts). So a bare /plannotator-inbox there keeps the address and the briefing in its turn, and a typed off or on keeps the off or on sentence in its turn, as part 1 does.

Claude desktop app, Code tab

A bare /plannotator-inbox goes past the mod to the skill (reviews: false), and the skill's "Using the Inbox" section briefs the agent. Behaviour is unchanged there. Whether the variable even reaches the desktop app is unproven.

What still reaches the agent on every host

  • The Inbox note in the agent's always-loaded instructions file, when one is installed (packages/server/inbox-agent-notes.ts).
  • The core plannotator skill's description.
  • On OpenCode and the DeepSeek Harness, the listed tool.

The MCP shim

When plannotator inbox mcp sees the variable in its own environment, it answers with no tools and no instructions for its whole life. That is all it does:

  • the session gets no "Inbox off" label
  • replies are not held
  • plannotator inbox call is not refused
  • plannotator inbox on cannot change a running shim

Codex: no effect. Codex hands a stdio MCP server none of its own environment, and the connect step adds a plain codex mcp add. That is why Ask AI writes the entry's env itself.

Qwen Code and Gemini CLI: not checked. Whether they pass their environment to the MCP child is unverified.

Unproven without a real session

  • Whether Claude Code offers a tool registered from inside a command (/plannotator-inbox on) to the model on its next request. If it never does, on cannot work in a start-off Claude Code session, and the person sees "Plannotator Inbox off for this session." with no hint to restart without the variable. The engine harness answers tool.register with the test's own hook and never shows a request's tool list. A live check on 2.1.310 saw the tool registered about 230 ms after the first prompt context and working, but that was early in the session, not after a later command.
  • Whether $.env.get sees a PLANNOTATOR_INBOX value set in Claude Code's settings.json.
  • Whether Qwen Code and Gemini CLI pass the variable to the MCP child.
  • Whether the variable reaches the Claude desktop app.

Other limits

  • plannotator inbox call from the agent's shell is a separate process and ignores the variable.
  • When the engine's tool.register returns no name (rather than throwing), no log line says why.

Not tried

No real agent was run.

  • The mod's registered hooks are driven with a fake engine.
  • Pi is driven through a fake extension API against a scratch Inbox.
  • OpenCode's off logic is tested directly.
  • The real CLI shim is tested over stdio against a scratch Inbox.

Wording

No user-facing or agent-facing sentence was added or changed. The shim answers methods other than initialize, tools/list and ping with the JSON-RPC standard error "Method not found", which only the MCP client sees. This PR adds no Inbox route and no wire field.

Tests: apps/hook/hooks/mod/inbox-start-off.test.ts, apps/pi-extension/inbox-start-off.test.ts, apps/pi-extension/inbox-command.test.ts, apps/opencode-plugin/inbox-off.test.ts, apps/opencode-plugin/command-interception.test.ts, apps/hook/server/inbox-start-off-shim.test.ts.

The session is in the same off state as a typed /plannotator-inbox off, but
silent: no tool (mod: not registered; Pi: inactive), no reminder, no off
sentence, nothing after a compaction, until /plannotator-inbox on. OpenCode and
the DeepSeek Harness keep the tool listed and refuse sends. plannotator inbox mcp
started with it lists no tools and sends no instructions.
@backnotprop backnotprop added the ci:e2e Run the full browser suite (Inbox window e2e) on this PR label Nov 29, 2026
…while silent, true docs

A refused registration at /plannotator-inbox on keeps the session off and
silent. A bare /plannotator-inbox in a start-off session opens the Inbox
without briefing the agent (mod, Pi, OpenCode 1). On typed in an OpenCode
subagent lifts it for that subagent. Docs list what still reaches the agent
per host and that PLANNOTATOR_INBOX=off codex has no effect.
…e 1's bare command turn, exact docs

The setting is read when the host loads Plannotator, so a bare
/plannotator-inbox briefs nothing before a connection exists (Pi with its tool
off, the mod before the Inbox was turned on, OpenCode with no Inbox at load).
OpenCode 1 keeps the address and briefing in a bare command's own turn: an
empty one makes the model answer its last reply again. Docs state the desktop
Code tab and the other limits.
# Conflicts:
#	apps/hook/hooks/mod/register.ts
#	apps/hook/server/inbox-command.ts
#	apps/hook/server/inbox-mcp-shim.ts
… keeps its turn

In the Claude Code mod, /plannotator-inbox on now ends a start-off session
that has no Inbox tool (Inbox not turned on here, or its tool switched off),
and the command is answered as without the variable. OpenCode 1's typed off
and on keep the off or on sentence in the command's own turn, as part 1 does,
instead of an empty turn. Docs: the DeepSeek Harness reads the setting only
when its Inbox connection starts.
@backnotprop
backnotprop marked this pull request as ready for review December 1, 2026 04:03
@backnotprop
backnotprop merged commit 93fc77c into main Dec 1, 2026
80 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:e2e Run the full browser suite (Inbox window e2e) on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant