Files
sessions: omp's local sessions are in Usage › Sessions (#303), and the GLM Coding Plans take Codex's Responses as they are (#306) — omp (oh-my-pi) keeps Pi's session jsonl (v3) under ~/.omp/agent/sessions (and profiles' and $XDG_DATA_HOME/omp's) with a title line, title changes, model_usage for calls outside the chat, provider/model changes and subagent/advisor transcripts beside the file; they are read through Pi's parser, subagents counted in their session, a fork's copied entries in the original only, resumed by omp --resume <id>. The zhipu and zai Coding Plan regions get their Responses base (open.bigmodel.cn/api/v1, api.z.ai/api/v1, per their Codex docs), so Codex's requests go there as they are instead of rebuilt for Chat; Chat and Claude Code routes are unchanged. TestOmp, TestDirsMore and TestGLMCodingPlanResponses fail without the change. go vet, go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass.
sessions: omp's local sessions are in Usage › Sessions (#303), and the GLM Coding Plans take Codex's Responses as they are (#306) — omp (oh-my-pi) keeps Pi's session jsonl (v3) under ~/.omp/agent/sessions (and profiles' and $XDG_DATA_HOME/omp's) with a title line, title changes, model_usage for calls outside the chat, provider/model changes and subagent/advisor transcripts beside the file; they are read through Pi's parser, subagents counted in their session, a fork's copied entries in the original only, resumed by omp --resume <id>. The zhipu and zai Coding Plan regions get their Responses base (open.bigmodel.cn/api/v1, api.z.ai/api/v1, per their Codex docs), so Codex's requests go there as they are instead of rebuilt for Chat; Chat and Claude Code routes are unchanged. TestOmp, TestDirsMore and TestGLMCodingPlanResponses fail without the change. go vet, go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass.
sessions: Codex rollouts the Codex app has compressed (.jsonl.zst) are read as the plain ones (#448) — with "compress local chat history" on, the Codex app packs older rollout-*.jsonl into rollout-*.jsonl.zst, and rolloutName ended in \.jsonl$, so those sessions, their calls and their usage were gone from Sessions, Usage and the ledger. A .zst rollout is now found, decompressed as it is read (klauspost/compress, already used for dsh's .zstd files; dshOpen now shares openLines), read whole again whenever it changes rather than read on from an offset, and its calls' places are those of its lines decompressed, so a call's content (the detail view) reads the same from either form, and one read before its file was packed still finds it. A rollout there in both forms (the app packing it) is read once, as the plain one, under the same codex:<thread id> key, so the session keeps its id and nothing is counted twice; deleting such a session moves both forms to the trash. TestCodexPackedSessions, TestCodexPackedCalls and TestCodexPackedDelete fail without the change; rollouts packed with the zstd CLI list the same as plain ones in a sandbox CODEX_HOME.
sessions: Codex rollouts the Codex app has compressed (.jsonl.zst) are read as the plain ones (#448) — with "compress local chat history" on, the Codex app packs older rollout-*.jsonl into rollout-*.jsonl.zst, and rolloutName ended in \.jsonl$, so those sessions, their calls and their usage were gone from Sessions, Usage and the ledger. A .zst rollout is now found, decompressed as it is read (klauspost/compress, already used for dsh's .zstd files; dshOpen now shares openLines), read whole again whenever it changes rather than read on from an offset, and its calls' places are those of its lines decompressed, so a call's content (the detail view) reads the same from either form, and one read before its file was packed still finds it. A rollout there in both forms (the app packing it) is read once, as the plain one, under the same codex:<thread id> key, so the session keeps its id and nothing is counted twice; deleting such a session moves both forms to the trash. TestCodexPackedSessions, TestCodexPackedCalls and TestCodexPackedDelete fail without the change; rollouts packed with the zstd CLI list the same as plain ones in a sandbox CODEX_HOME.
sessions: Codex rollouts the Codex app has compressed (.jsonl.zst) are read as the plain ones (#448) — with "compress local chat history" on, the Codex app packs older rollout-*.jsonl into rollout-*.jsonl.zst, and rolloutName ended in \.jsonl$, so those sessions, their calls and their usage were gone from Sessions, Usage and the ledger. A .zst rollout is now found, decompressed as it is read (klauspost/compress, already used for dsh's .zstd files; dshOpen now shares openLines), read whole again whenever it changes rather than read on from an offset, and its calls' places are those of its lines decompressed, so a call's content (the detail view) reads the same from either form, and one read before its file was packed still finds it. A rollout there in both forms (the app packing it) is read once, as the plain one, under the same codex:<thread id> key, so the session keeps its id and nothing is counted twice; deleting such a session moves both forms to the trash. TestCodexPackedSessions, TestCodexPackedCalls and TestCodexPackedDelete fail without the change; rollouts packed with the zstd CLI list the same as plain ones in a sandbox CODEX_HOME.
sessions: Codex rollouts the Codex app has compressed (.jsonl.zst) are read as the plain ones (#448) — with "compress local chat history" on, the Codex app packs older rollout-*.jsonl into rollout-*.jsonl.zst, and rolloutName ended in \.jsonl$, so those sessions, their calls and their usage were gone from Sessions, Usage and the ledger. A .zst rollout is now found, decompressed as it is read (klauspost/compress, already used for dsh's .zstd files; dshOpen now shares openLines), read whole again whenever it changes rather than read on from an offset, and its calls' places are those of its lines decompressed, so a call's content (the detail view) reads the same from either form, and one read before its file was packed still finds it. A rollout there in both forms (the app packing it) is read once, as the plain one, under the same codex:<thread id> key, so the session keeps its id and nothing is counted twice; deleting such a session moves both forms to the trash. TestCodexPackedSessions, TestCodexPackedCalls and TestCodexPackedDelete fail without the change; rollouts packed with the zstd CLI list the same as plain ones in a sandbox CODEX_HOME.
sessions: a session in magpie's trash can be erased for good, one at a time or the whole trash, after magpie's own dialog (#487: no way to empty the trash but removing its folder by hand) — the Sessions page's Trash only restored, and said magpie never erases what is in it: remove the folder yourself. Each trashed row now has Delete forever and the Trash an Empty trash, with the count of what is in it; both ask in magpie's dialog, as Delete does (never confirm()), naming the sessions, and Cancel sends nothing. They post /api/sessions/purge with the rows' keys, or all for every session the trash lists; each key is checked as Restore checks it (<agent>/<name>, an agent magpie deletes for, no separators, no . or ..), and its folder, and its agent's, must be real folders in <magpie dir>/trash/sessions, not links, with the session's note (session.json) in it; only that folder goes, its note with it, so the trash lists it no more. Nothing is erased by itself: the note under the Trash now says they are kept until erased there, and magpie never erases them by itself. TestPurgeOne, TestPurgeAll, TestPurgeRefusesOutOfTrash, TestSessionsPurgeRoute and sessions-purge.test.cjs (Chromium, WebKit; en, zh) fail without the change. go vet, go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass (TestFXInState failed once under load, passes alone and in its package); sessions-manage, sessions-toolbar, click-scroll, old-webkit pass.
sessions: omp's local sessions are in Usage › Sessions (#303), and the GLM Coding Plans take Codex's Responses as they are (#306) — omp (oh-my-pi) keeps Pi's session jsonl (v3) under ~/.omp/agent/sessions (and profiles' and $XDG_DATA_HOME/omp's) with a title line, title changes, model_usage for calls outside the chat, provider/model changes and subagent/advisor transcripts beside the file; they are read through Pi's parser, subagents counted in their session, a fork's copied entries in the original only, resumed by omp --resume <id>. The zhipu and zai Coding Plan regions get their Responses base (open.bigmodel.cn/api/v1, api.z.ai/api/v1, per their Codex docs), so Codex's requests go there as they are instead of rebuilt for Chat; Chat and Claude Code routes are unchanged. TestOmp, TestDirsMore and TestGLMCodingPlanResponses fail without the change. go vet, go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass.
sessions: omp's local sessions are in Usage › Sessions (#303), and the GLM Coding Plans take Codex's Responses as they are (#306) — omp (oh-my-pi) keeps Pi's session jsonl (v3) under ~/.omp/agent/sessions (and profiles' and $XDG_DATA_HOME/omp's) with a title line, title changes, model_usage for calls outside the chat, provider/model changes and subagent/advisor transcripts beside the file; they are read through Pi's parser, subagents counted in their session, a fork's copied entries in the original only, resumed by omp --resume <id>. The zhipu and zai Coding Plan regions get their Responses base (open.bigmodel.cn/api/v1, api.z.ai/api/v1, per their Codex docs), so Codex's requests go there as they are instead of rebuilt for Chat; Chat and Claude Code routes are unchanged. TestOmp, TestDirsMore and TestGLMCodingPlanResponses fail without the change. go vet, go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass.
sessions: Pi's and omp's sessions count their prompts, replies, tool calls and skills (#384) — Usage → Sessions filtered to Pi showed no session shape by messages or tool calls, no tools and no skills: piParse read only the title, the model and the usage, and the fast path dropped every user line after the first. Now, from Pi's v3 session format as its source writes it (packages/ai types.ts: AssistantMessage content ToolCall {type:"toolCall",name,arguments}, ToolResultMessage nestedCalls.calls; agent-session.ts: /skill:name sent as <skill name="…" location="…">; skills.ts: a skill is loaded by reading its SKILL.md), a typed user message is a prompt, an assistant message a reply, each toolCall part a tool call, a tool's nestedCalls (a codemode script's) calls too, and a read of a SKILL.md (or omp's skill://) or a /skill: prompt a skill; a fork's copied entries count in the session they came from. ToolCategory knows Pi's lowercase names (bash, powershell, read, write, find, ls). The sessions cache version goes to 6 so kept parses are read again. TestPiToolsAndMessages and TestToolCategoryPi fail without the change. go vet ./internal/..., go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass (TestUserPath and the Claude account tests flake under load, pass alone).
sessions: a session in magpie's trash can be erased for good, one at a time or the whole trash, after magpie's own dialog (#487: no way to empty the trash but removing its folder by hand) — the Sessions page's Trash only restored, and said magpie never erases what is in it: remove the folder yourself. Each trashed row now has Delete forever and the Trash an Empty trash, with the count of what is in it; both ask in magpie's dialog, as Delete does (never confirm()), naming the sessions, and Cancel sends nothing. They post /api/sessions/purge with the rows' keys, or all for every session the trash lists; each key is checked as Restore checks it (<agent>/<name>, an agent magpie deletes for, no separators, no . or ..), and its folder, and its agent's, must be real folders in <magpie dir>/trash/sessions, not links, with the session's note (session.json) in it; only that folder goes, its note with it, so the trash lists it no more. Nothing is erased by itself: the note under the Trash now says they are kept until erased there, and magpie never erases them by itself. TestPurgeOne, TestPurgeAll, TestPurgeRefusesOutOfTrash, TestSessionsPurgeRoute and sessions-purge.test.cjs (Chromium, WebKit; en, zh) fail without the change. go vet, go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass (TestFXInState failed once under load, passes alone and in its package); sessions-manage, sessions-toolbar, click-scroll, old-webkit pass.
sessions: the indexing show no longer comes back on every visit — the index is written after the read, in the background, and not counted as indexing (Image #15: 这个还是会出现无数次)
sessions: Codex rollouts the Codex app has compressed (.jsonl.zst) are read as the plain ones (#448) — with "compress local chat history" on, the Codex app packs older rollout-*.jsonl into rollout-*.jsonl.zst, and rolloutName ended in \.jsonl$, so those sessions, their calls and their usage were gone from Sessions, Usage and the ledger. A .zst rollout is now found, decompressed as it is read (klauspost/compress, already used for dsh's .zstd files; dshOpen now shares openLines), read whole again whenever it changes rather than read on from an offset, and its calls' places are those of its lines decompressed, so a call's content (the detail view) reads the same from either form, and one read before its file was packed still finds it. A rollout there in both forms (the app packing it) is read once, as the plain one, under the same codex:<thread id> key, so the session keeps its id and nothing is counted twice; deleting such a session moves both forms to the trash. TestCodexPackedSessions, TestCodexPackedCalls and TestCodexPackedDelete fail without the change; rollouts packed with the zstd CLI list the same as plain ones in a sandbox CODEX_HOME.
sessions: Pi's and omp's sessions count their prompts, replies, tool calls and skills (#384) — Usage → Sessions filtered to Pi showed no session shape by messages or tool calls, no tools and no skills: piParse read only the title, the model and the usage, and the fast path dropped every user line after the first. Now, from Pi's v3 session format as its source writes it (packages/ai types.ts: AssistantMessage content ToolCall {type:"toolCall",name,arguments}, ToolResultMessage nestedCalls.calls; agent-session.ts: /skill:name sent as <skill name="…" location="…">; skills.ts: a skill is loaded by reading its SKILL.md), a typed user message is a prompt, an assistant message a reply, each toolCall part a tool call, a tool's nestedCalls (a codemode script's) calls too, and a read of a SKILL.md (or omp's skill://) or a /skill: prompt a skill; a fork's copied entries count in the session they came from. ToolCategory knows Pi's lowercase names (bash, powershell, read, write, find, ls). The sessions cache version goes to 6 so kept parses are read again. TestPiToolsAndMessages and TestToolCategoryPi fail without the change. go vet ./internal/..., go build -tags nogui (darwin, GOOS=linux), GOOS=windows go build, go test -tags nogui ./... pass (TestUserPath and the Claude account tests flake under load, pass alone).