Repository navigation
Inbox: name sessions started in Oh My Pi "Oh My Pi" (#3443, part 1) - #4075
Merged
Merged
Conversation
Oh My Pi loads Plannotator's Pi extension, which polls as host pi and says plugin.host oh-my-pi. The live sessions now carry runtime "oh-my-pi" on the To picker's sessions and the Agents list, and the /mcp door stores such a session's messages under "Oh My Pi". inboxHostName is the one place a host and its runtime become a name. An older Inbox or extension still shows Pi. Issue #3443.
Its sessions are host pi, so a one-agent row named its writer from the host. The row now carries the writer's own name when it is not its host's.
…abel # Conflicts: # apps/mobile/contract/parity/ledger.json
…nbox-oh-my-pi-label
…ox-oh-my-pi-label # Conflicts: # apps/mobile/contract/parity/ledger.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part 1 of 2 for #3443 (start an Oh My Pi session from the Inbox). This part changes only the name.
What a person sees
A session started by hand in Oh My Pi (
omp, withomp plugin install @plannotator/pi-extension) is named "Oh My Pi" instead of "Pi" in:Settings → Agents already named these sessions "Oh My Pi" in its reload lines, through
runtimeonInboxOpenSession. Nothing else in Settings names a single session.How
packages/core/inbox-types.ts:INBOX_HOST_NAMES["oh-my-pi"] = "Oh My Pi".inboxHostName(host, runtime)is the one place a host and its runtime become a name, andinboxAgentRuntimeOf(host, plugin.host)gives that runtime. Aruntimevalue other thanoh-my-piis ignored, including one sent by another machine.packages/server/inbox-sessions.ts: live sessions and Agents sessions carryruntime: "oh-my-pi"when apipoll saidplugin.host: "oh-my-pi". The field is set ininbox-compose.ts(To picker sessions) andinbox-agents-list.ts(agents). It is additive.packages/server/inbox-runtime-name.ts, called from/mcpininbox.ts: a tool call from such a session that carries the extension's ownagent_name: "Pi"is stored as "Oh My Pi". A name the agent chose itself is left alone. The host stayspi, so routing, wake and tags do not change. Wake lines still name agents from their host.INBOX_WAKE_AGENT_NAMES(the mod's copy and the shared copy) gains "Oh My Pi", becauseconnection-tags.test.tsrequires everyINBOX_HOST_NAMESvalue. This adds one allowed name to the list. No wake sentence changes, and since wakes name agents from their host, the server does not produce this name today.Across computers and the phone
runtimethrough (inboxAgentNamesCheckedkeeps unknown fields). The window reads it only throughinboxHostName.bun scripts/mobile/all.ts): it adds theruntimefield and enum onInboxAgentandInboxComposeSession, the wordhost.oh-my-pi, and undecided ledger rows.bun scripts/mobile/check.tspasses.plugin.host, shows Pi.Not in this PR
LiveSessioninpackages/inbox/api.ts, which is at its size ceiling). They still say Pi. This is the follow-up.Tests
packages/server/inbox-runtime-name.test.ts: 4 pass. Fails on main (module missing).packages/inbox/agents/ohMyPiName.test.ts: 2 pass. Fails on main ("Pi" received).packages/server/inbox-oh-my-pi-over-inbox.test.ts: over a real Inbox, so it runs in CI only.connection-tags,inbox-agents-list,agentsModel, the modinbox-contract,tests/inbox-structure,dom-test-allowlist.tscpasses for core, server, inbox, shared and apps/hook.bun scripts/mobile/check.tspasses.Part 2 (the "New Oh My Pi session" row) is a separate PR stacked on this one.
Added (225af7c): the held line. A thread that a single Oh My Pi session answers used to read "Pi replied in …", because a one-agent row was named from its host,
pi. The row now carries the writer's own name (last_agent) when that name is not its host's (inboxRuntimeNamed), so the line reads "Oh My Pi replied in …". Test:packages/inbox/ohMyPiHeldLine.test.ts, 2 tests, both passing. It failed before the fix.