{"_id":"@buckeyestudio/toh-session-log-export","name":"@buckeyestudio/toh-session-log-export","dist-tags":{"next":"0.1.1-rc.2","latest":"0.1.1-rc.2"},"versions":{"0.1.1-rc.2":{"name":"@buckeyestudio/toh-session-log-export","description":"Web Session-log export command and shared download dialog","version":"0.1.1-rc.2","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/dustinwloring1988/theopen-harness.git","directory":"packages/session-query/session-log-export"},"type":"module","main":"lib/index.js","types":"lib/types/index.d.ts","exports":{".":{"types":"./lib/types/index.d.ts","default":"./lib/index.js"},"./invariant":{"types":"./lib/types/invariant.d.ts","default":"./lib/invariant.js"},"./client":{"types":"./lib/types/client/index.d.ts","default":"./lib/client.js"},"./src/*":"./src/*","./package.json":"./package.json"},"license":"MIT","author":{"name":"buckeyestudio"},"peerDependencies":{"@buckeyestudio/cordis":"^4.0.1","@buckeyestudio/toh-client-locale":"^0.1.1-rc.2","@buckeyestudio/toh-client-ui-commands":"^0.1.1-rc.2","@buckeyestudio/toh-client-runtime":"^0.1.1-rc.2","@buckeyestudio/toh-invariants":"^0.1.1-rc.2","@buckeyestudio/toh-commands":"^0.1.1-rc.2","@buckeyestudio/toh-client-ui-conversation":"^0.1.1-rc.2"},"devDependencies":{"@types/react":"~19.2.3","react":"^19.2.8","@buckeyestudio/cordis":"^4.0.1","@buckeyestudio/cordis-plugin-loader":"^1.0.2","@buckeyestudio/toh-client-locale":"^0.1.1-rc.2","@buckeyestudio/toh-client-runtime":"^0.1.1-rc.2","@buckeyestudio/toh-client-ui-commands":"^0.1.1-rc.2","@buckeyestudio/toh-agent":"^0.1.1-rc.2","@buckeyestudio/toh-client-ui-conversation":"^0.1.1-rc.2","@buckeyestudio/toh-client-ui-primitives":"^0.1.1-rc.2","@buckeyestudio/toh-client-ui-slots":"^0.1.1-rc.2","@buckeyestudio/toh-commands":"^0.1.1-rc.2","@buckeyestudio/toh-invariants":"^0.1.1-rc.2","@buckeyestudio/toh-session":"^0.1.1-rc.2"},"toh":{"client":{"inject":["@buckeyestudio/toh-client-locale","@buckeyestudio/toh-client-runtime","@buckeyestudio/toh-client-ui-commands","@buckeyestudio/toh-client-ui-conversation"],"platform":"web"}},"scripts":{"bundle":"tsdown","watch":"tsdown --watch"},"_id":"@buckeyestudio/toh-session-log-export@0.1.1-rc.2","bugs":{"url":"https://github.com/dustinwloring1988/theopen-harness/issues"},"homepage":"https://github.com/dustinwloring1988/theopen-harness#readme","_integrity":"sha512-IiLQ7kklyvcf2bQDJxJJbyyRe6BGNP+InuRsM6R+sDKFool6xb4BpFJGrfOdhxayHlAzW9EblFN+k6RNGmjgfQ==","_resolved":"/home/runner/work/theopen-harness/theopen-harness/dist/npm/buckeyestudio-toh-session-log-export-0.1.1-rc.2.tgz","_from":"file:/home/runner/work/theopen-harness/theopen-harness/dist/npm/buckeyestudio-toh-session-log-export-0.1.1-rc.2.tgz","_nodeVersion":"24.19.0","_npmVersion":"11.17.0","dist":{"integrity":"sha512-IiLQ7kklyvcf2bQDJxJJbyyRe6BGNP+InuRsM6R+sDKFool6xb4BpFJGrfOdhxayHlAzW9EblFN+k6RNGmjgfQ==","shasum":"1539711e1d6bbc23103416d7a14cc25e19b532a3","tarball":"https://registry.npmjs.org/@buckeyestudio/toh-session-log-export/-/toh-session-log-export-0.1.1-rc.2.tgz","fileCount":15,"unpackedSize":31067,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCaJJjcYzXr5Ymb/duPewsZ9LG+kFIZHbhLE6LnDdtJRwIgDv+2i9e7UxpMhLLd9RYW8/Q0D8BWLZEPyAAG6TckviM="}]},"_npmUser":{"name":"buckeyestudio","email":"dustinwloring1988@gmail.com"},"directories":{},"maintainers":[{"name":"buckeyestudio","email":"dustinwloring1988@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/toh-session-log-export_0.1.1-rc.2_1787489706688_0.8181919641647608"},"_hasShrinkwrap":false}},"time":{"created":"2026-08-23T12:55:06.532Z","0.1.1-rc.2":"2026-08-23T12:55:06.829Z","modified":"2026-08-23T12:55:07.011Z"},"maintainers":[{"name":"buckeyestudio","email":"dustinwloring1988@gmail.com"}],"description":"Web Session-log export command and shared download dialog","homepage":"https://github.com/dustinwloring1988/theopen-harness#readme","repository":{"type":"git","url":"git+https://github.com/dustinwloring1988/theopen-harness.git","directory":"packages/session-query/session-log-export"},"author":{"name":"buckeyestudio"},"bugs":{"url":"https://github.com/dustinwloring1988/theopen-harness/issues"},"license":"MIT","readme":"# @buckeyestudio/toh-session-log-export\n\n[English](README.md) | 中文\n\nWeb Session 日志下载控制，使用 `toh-host-apiproxy` 拥有的 Host 流式 ZIP 端点。Host 半包注册 `/export`；浏览器半包在 Session Header 中提供 111×32 的 `Session log` 操作，以及一个供该按钮与斜杠命令共用的下载控制器和弹窗。ZIP 生成、原始 JSONL/zstd 读取、子 Session、附件、背压和 HTTP 错误语义仍由 [ApiProxy 下载实现](../../host/apiproxy/README.zh.md)负责。\n\n## 命令约定\n\n| 输入 | 结果 |\n|---|---|\n| `/export` | 记录一组用户命令生命周期；提交命令的浏览器收到本地执行确认后，下载 `GET /api/session.export?sessionId=<id>&includeDescendants=true`。 |\n| `/export <path>` | 返回错误。浏览器下载通过浏览器的普通下载行为选择目标位置。 |\n\n该命令只由 Web bundle 挂载。只有 `/export` 返回成功时，本地 `command/executed` 确认才会在提交命令的浏览器中触发斜杠下载；其他标签页仍会渲染持久命令行，但不会重复执行浏览器副作用。Header 按钮直接调用同一个控制器。两种入口都会先发出 `HEAD` 预检，再把 GET URL 交给浏览器下载管理器，JavaScript 不会缓冲 ZIP；它们共用并发折叠、插件释放时取消预检、准备阶段错误处理、浏览器保存行为和同一个 Modal。\n\nHost 下载端点会在 `readRaw` 前 flush 活动的根 Session，因此斜杠命令触发的 ZIP 会包含启动下载的 `command/run` 与 `command/done` 事件对。冷持久化 Session 不需要 flush。\n\n弹窗报告准备中、开始下载或失败。关闭弹窗不会取消正在进行的下载；该操作随后完成时也不会重新打开弹窗。每个 Session 同时只允许一项下载，重复操作会共用该任务。\n\n## 组合\n\n```yaml\n- id: session-log-download\n  name: '@buckeyestudio/toh-session-log-export'\n```\n\nWeb bundle 将本包与 `toh-host-apiproxy`、`toh-commands`、`toh-client-ui-commands` 和 `toh-client-ui-conversation` 一起挂载。本包把按钮和弹窗贡献到最右侧的 `conversation.session.header.utilities` 列表，与标题旁 `conversation.session.header.actions` 中的模式、Subagent 和 Task 配置项相互独立；Trajectory 不包含导出入口。\n\n## 模型体验\n\n### 用户 `/export` 控制\n\n#### 模型看到什么\n\n无。`/export` 留在用户命令平面，ZIP 下载不会进入模型历史。\n\n#### Token 影响\n\n为零。该命令不创建模型轮次。\n\n#### KV Cache 影响\n\n无。仅日志命令生命周期和浏览器下载不会改变派生请求前缀。\n\n## 已知限制与暂缓事项\n\n- 下载端点要求持久化后端具有逐 Session 原始工件。随附 JSONL 后端支持明文和 zstd 工件；本次改动不包含 SQLite 导出。\n- 这是浏览器下载，不是 Host 路径写入。目标位置由浏览器选择，不会返回 Host 路径或原生文件夹操作。\n- 预检只报告 ZIP 开始流式传输前发现的失败。浏览器接受 GET 后发生的子 Session 或附件读取失败由浏览器下载管理器报告，不通过弹窗报告。\n","readmeFilename":"README.zh.md","_rev":"1-1ce2ca3e59b7aa4a2cf1596da9031722"}