@xrkseek/harness 0.6.23 → 0.7.0-rc.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (738) hide show
  1. package/node_modules/@xrkseek/a2a/README.md +45 -45
  2. package/node_modules/@xrkseek/attachment/README.md +23 -23
  3. package/node_modules/@xrkseek/attachment-local/README.md +6 -6
  4. package/node_modules/@xrkseek/attachment-local/package.json +26 -26
  5. package/node_modules/@xrkseek/checkpoint/README.md +90 -90
  6. package/node_modules/@xrkseek/checkpoint/dist/process-git.d.ts +5 -0
  7. package/node_modules/@xrkseek/checkpoint/dist/process-git.d.ts.map +1 -1
  8. package/node_modules/@xrkseek/checkpoint/dist/process-git.js +59 -2
  9. package/node_modules/@xrkseek/checkpoint/dist/process-git.js.map +1 -1
  10. package/node_modules/@xrkseek/checkpoint/dist/store.d.ts +45 -0
  11. package/node_modules/@xrkseek/checkpoint/dist/store.d.ts.map +1 -1
  12. package/node_modules/@xrkseek/checkpoint/dist/store.js +221 -60
  13. package/node_modules/@xrkseek/checkpoint/dist/store.js.map +1 -1
  14. package/node_modules/@xrkseek/checkpoint/package.json +26 -26
  15. package/node_modules/@xrkseek/claude-code-mods/README.md +152 -0
  16. package/node_modules/@xrkseek/claude-code-mods/README.zh.md +172 -0
  17. package/node_modules/@xrkseek/claude-code-mods/dist/api.d.ts +36 -0
  18. package/node_modules/@xrkseek/claude-code-mods/dist/api.d.ts.map +1 -0
  19. package/node_modules/@xrkseek/claude-code-mods/dist/api.js +215 -0
  20. package/node_modules/@xrkseek/claude-code-mods/dist/api.js.map +1 -0
  21. package/node_modules/@xrkseek/claude-code-mods/dist/attach.d.ts +92 -0
  22. package/node_modules/@xrkseek/claude-code-mods/dist/attach.d.ts.map +1 -0
  23. package/node_modules/@xrkseek/claude-code-mods/dist/attach.js +106 -0
  24. package/node_modules/@xrkseek/claude-code-mods/dist/attach.js.map +1 -0
  25. package/node_modules/@xrkseek/claude-code-mods/dist/chain.d.ts +105 -0
  26. package/node_modules/@xrkseek/claude-code-mods/dist/chain.d.ts.map +1 -0
  27. package/node_modules/@xrkseek/claude-code-mods/dist/chain.js +324 -0
  28. package/node_modules/@xrkseek/claude-code-mods/dist/chain.js.map +1 -0
  29. package/node_modules/@xrkseek/claude-code-mods/dist/define-mod.d.ts +39 -0
  30. package/node_modules/@xrkseek/claude-code-mods/dist/define-mod.d.ts.map +1 -0
  31. package/node_modules/@xrkseek/claude-code-mods/dist/define-mod.js +39 -0
  32. package/node_modules/@xrkseek/claude-code-mods/dist/define-mod.js.map +1 -0
  33. package/node_modules/@xrkseek/claude-code-mods/dist/elements.d.ts +96 -0
  34. package/node_modules/@xrkseek/claude-code-mods/dist/elements.d.ts.map +1 -0
  35. package/node_modules/@xrkseek/claude-code-mods/dist/elements.js +171 -0
  36. package/node_modules/@xrkseek/claude-code-mods/dist/elements.js.map +1 -0
  37. package/node_modules/@xrkseek/claude-code-mods/dist/engine.d.ts +155 -0
  38. package/node_modules/@xrkseek/claude-code-mods/dist/engine.d.ts.map +1 -0
  39. package/node_modules/@xrkseek/claude-code-mods/dist/engine.js +356 -0
  40. package/node_modules/@xrkseek/claude-code-mods/dist/engine.js.map +1 -0
  41. package/node_modules/@xrkseek/claude-code-mods/dist/host-ops.d.ts +72 -0
  42. package/node_modules/@xrkseek/claude-code-mods/dist/host-ops.d.ts.map +1 -0
  43. package/node_modules/@xrkseek/claude-code-mods/dist/host-ops.js +603 -0
  44. package/node_modules/@xrkseek/claude-code-mods/dist/host-ops.js.map +1 -0
  45. package/node_modules/@xrkseek/claude-code-mods/dist/index.d.ts +112 -0
  46. package/node_modules/@xrkseek/claude-code-mods/dist/index.d.ts.map +1 -0
  47. package/node_modules/@xrkseek/claude-code-mods/dist/index.js +654 -0
  48. package/node_modules/@xrkseek/claude-code-mods/dist/index.js.map +1 -0
  49. package/node_modules/@xrkseek/claude-code-mods/dist/matcher.d.ts +45 -0
  50. package/node_modules/@xrkseek/claude-code-mods/dist/matcher.d.ts.map +1 -0
  51. package/node_modules/@xrkseek/claude-code-mods/dist/matcher.js +195 -0
  52. package/node_modules/@xrkseek/claude-code-mods/dist/matcher.js.map +1 -0
  53. package/node_modules/@xrkseek/claude-code-mods/dist/module.d.ts +74 -0
  54. package/node_modules/@xrkseek/claude-code-mods/dist/module.d.ts.map +1 -0
  55. package/node_modules/@xrkseek/claude-code-mods/dist/module.js +167 -0
  56. package/node_modules/@xrkseek/claude-code-mods/dist/module.js.map +1 -0
  57. package/node_modules/@xrkseek/claude-code-mods/dist/native-import.d.ts +31 -0
  58. package/node_modules/@xrkseek/claude-code-mods/dist/native-import.d.ts.map +1 -0
  59. package/node_modules/@xrkseek/claude-code-mods/dist/native-import.js +32 -0
  60. package/node_modules/@xrkseek/claude-code-mods/dist/native-import.js.map +1 -0
  61. package/node_modules/@xrkseek/claude-code-mods/dist/plugin-dir.d.ts +70 -0
  62. package/node_modules/@xrkseek/claude-code-mods/dist/plugin-dir.d.ts.map +1 -0
  63. package/node_modules/@xrkseek/claude-code-mods/dist/plugin-dir.js +167 -0
  64. package/node_modules/@xrkseek/claude-code-mods/dist/plugin-dir.js.map +1 -0
  65. package/node_modules/@xrkseek/claude-code-mods/dist/product-agent.d.ts +57 -0
  66. package/node_modules/@xrkseek/claude-code-mods/dist/product-agent.d.ts.map +1 -0
  67. package/node_modules/@xrkseek/claude-code-mods/dist/product-agent.js +85 -0
  68. package/node_modules/@xrkseek/claude-code-mods/dist/product-agent.js.map +1 -0
  69. package/node_modules/@xrkseek/claude-code-mods/dist/runtime.d.ts +117 -0
  70. package/node_modules/@xrkseek/claude-code-mods/dist/runtime.d.ts.map +1 -0
  71. package/node_modules/@xrkseek/claude-code-mods/dist/runtime.js +252 -0
  72. package/node_modules/@xrkseek/claude-code-mods/dist/runtime.js.map +1 -0
  73. package/node_modules/@xrkseek/claude-code-mods/dist/storage-domain.d.ts +68 -0
  74. package/node_modules/@xrkseek/claude-code-mods/dist/storage-domain.d.ts.map +1 -0
  75. package/node_modules/@xrkseek/claude-code-mods/dist/storage-domain.js +104 -0
  76. package/node_modules/@xrkseek/claude-code-mods/dist/storage-domain.js.map +1 -0
  77. package/node_modules/@xrkseek/claude-code-mods/dist/surfaces.d.ts +82 -0
  78. package/node_modules/@xrkseek/claude-code-mods/dist/surfaces.d.ts.map +1 -0
  79. package/node_modules/@xrkseek/claude-code-mods/dist/surfaces.js +243 -0
  80. package/node_modules/@xrkseek/claude-code-mods/dist/surfaces.js.map +1 -0
  81. package/node_modules/@xrkseek/claude-code-mods/dist/testing.d.ts +157 -0
  82. package/node_modules/@xrkseek/claude-code-mods/dist/testing.d.ts.map +1 -0
  83. package/node_modules/@xrkseek/claude-code-mods/dist/testing.js +266 -0
  84. package/node_modules/@xrkseek/claude-code-mods/dist/testing.js.map +1 -0
  85. package/node_modules/@xrkseek/claude-code-mods/dist/tool-names.d.ts +21 -0
  86. package/node_modules/@xrkseek/claude-code-mods/dist/tool-names.d.ts.map +1 -0
  87. package/node_modules/@xrkseek/claude-code-mods/dist/tool-names.js +37 -0
  88. package/node_modules/@xrkseek/claude-code-mods/dist/tool-names.js.map +1 -0
  89. package/node_modules/@xrkseek/claude-code-mods/dist/types.d.ts +592 -0
  90. package/node_modules/@xrkseek/claude-code-mods/dist/types.d.ts.map +1 -0
  91. package/node_modules/@xrkseek/claude-code-mods/dist/types.js +10 -0
  92. package/node_modules/@xrkseek/claude-code-mods/dist/types.js.map +1 -0
  93. package/node_modules/@xrkseek/claude-code-mods/dist/values.d.ts +58 -0
  94. package/node_modules/@xrkseek/claude-code-mods/dist/values.d.ts.map +1 -0
  95. package/node_modules/@xrkseek/claude-code-mods/dist/values.js +75 -0
  96. package/node_modules/@xrkseek/claude-code-mods/dist/values.js.map +1 -0
  97. package/node_modules/@xrkseek/claude-code-mods/dist/working-directory.d.ts +45 -0
  98. package/node_modules/@xrkseek/claude-code-mods/dist/working-directory.d.ts.map +1 -0
  99. package/node_modules/@xrkseek/claude-code-mods/dist/working-directory.js +29 -0
  100. package/node_modules/@xrkseek/claude-code-mods/dist/working-directory.js.map +1 -0
  101. package/node_modules/@xrkseek/claude-code-mods/package.json +47 -0
  102. package/node_modules/@xrkseek/code-runtime/README.md +20 -20
  103. package/node_modules/@xrkseek/core-agent/dist/index.d.ts +87 -0
  104. package/node_modules/@xrkseek/core-agent/dist/index.d.ts.map +1 -1
  105. package/node_modules/@xrkseek/core-agent/dist/index.js.map +1 -1
  106. package/node_modules/@xrkseek/core-agent-loop/dist/index.d.ts.map +1 -1
  107. package/node_modules/@xrkseek/core-agent-loop/dist/index.js +62 -32
  108. package/node_modules/@xrkseek/core-agent-loop/dist/index.js.map +1 -1
  109. package/node_modules/@xrkseek/core-agent-loop/package.json +42 -42
  110. package/node_modules/@xrkseek/core-session/README.md +35 -35
  111. package/node_modules/@xrkseek/core-session/dist/compaction.d.ts +46 -2
  112. package/node_modules/@xrkseek/core-session/dist/compaction.d.ts.map +1 -1
  113. package/node_modules/@xrkseek/core-session/dist/compaction.js +124 -49
  114. package/node_modules/@xrkseek/core-session/dist/compaction.js.map +1 -1
  115. package/node_modules/@xrkseek/core-session/dist/freeze.d.ts +6 -0
  116. package/node_modules/@xrkseek/core-session/dist/freeze.d.ts.map +1 -1
  117. package/node_modules/@xrkseek/core-session/dist/freeze.js +9 -0
  118. package/node_modules/@xrkseek/core-session/dist/freeze.js.map +1 -1
  119. package/node_modules/@xrkseek/core-session/dist/index.d.ts +20 -4
  120. package/node_modules/@xrkseek/core-session/dist/index.d.ts.map +1 -1
  121. package/node_modules/@xrkseek/core-session/dist/index.js +55 -14
  122. package/node_modules/@xrkseek/core-session/dist/index.js.map +1 -1
  123. package/node_modules/@xrkseek/core-session/dist/list-hints.d.ts.map +1 -1
  124. package/node_modules/@xrkseek/core-session/dist/list-hints.js +14 -4
  125. package/node_modules/@xrkseek/core-session/dist/list-hints.js.map +1 -1
  126. package/node_modules/@xrkseek/core-session/dist/repair-open-turn.d.ts +8 -1
  127. package/node_modules/@xrkseek/core-session/dist/repair-open-turn.d.ts.map +1 -1
  128. package/node_modules/@xrkseek/core-session/dist/repair-open-turn.js +14 -4
  129. package/node_modules/@xrkseek/core-session/dist/repair-open-turn.js.map +1 -1
  130. package/node_modules/@xrkseek/core-session/dist/sqlite-store.d.ts +55 -0
  131. package/node_modules/@xrkseek/core-session/dist/sqlite-store.d.ts.map +1 -1
  132. package/node_modules/@xrkseek/core-session/dist/sqlite-store.js +670 -92
  133. package/node_modules/@xrkseek/core-session/dist/sqlite-store.js.map +1 -1
  134. package/node_modules/@xrkseek/core-session/dist/store.d.ts +38 -0
  135. package/node_modules/@xrkseek/core-session/dist/store.d.ts.map +1 -1
  136. package/node_modules/@xrkseek/core-session/dist/surface-estimate.d.ts +6 -0
  137. package/node_modules/@xrkseek/core-session/dist/surface-estimate.d.ts.map +1 -1
  138. package/node_modules/@xrkseek/core-session/dist/surface-estimate.js +23 -0
  139. package/node_modules/@xrkseek/core-session/dist/surface-estimate.js.map +1 -1
  140. package/node_modules/@xrkseek/core-session/dist/surface-fold.d.ts.map +1 -1
  141. package/node_modules/@xrkseek/core-session/dist/surface-fold.js +5 -7
  142. package/node_modules/@xrkseek/core-session/dist/surface-fold.js.map +1 -1
  143. package/node_modules/@xrkseek/core-session/package.json +34 -34
  144. package/node_modules/@xrkseek/core-system-prompt/README.md +14 -14
  145. package/node_modules/@xrkseek/core-tools/dist/session-query-prompt.d.ts.map +1 -1
  146. package/node_modules/@xrkseek/core-tools/dist/session-query-prompt.js +3 -2
  147. package/node_modules/@xrkseek/core-tools/dist/session-query-prompt.js.map +1 -1
  148. package/node_modules/@xrkseek/core-tools/dist/std-tools.d.ts.map +1 -1
  149. package/node_modules/@xrkseek/core-tools/dist/std-tools.js +1 -13
  150. package/node_modules/@xrkseek/core-tools/dist/std-tools.js.map +1 -1
  151. package/node_modules/@xrkseek/exec-computer-use/README.md +14 -14
  152. package/node_modules/@xrkseek/exec-computer-use/dist/windows-uia.js +402 -402
  153. package/node_modules/@xrkseek/exec-computer-use/package.json +26 -26
  154. package/node_modules/@xrkseek/exec-fs/README.md +12 -12
  155. package/node_modules/@xrkseek/exec-fs/dist/read-image.d.ts +7 -0
  156. package/node_modules/@xrkseek/exec-fs/dist/read-image.d.ts.map +1 -1
  157. package/node_modules/@xrkseek/exec-fs/dist/read-image.js +33 -15
  158. package/node_modules/@xrkseek/exec-fs/dist/read-image.js.map +1 -1
  159. package/node_modules/@xrkseek/exec-fs/dist/routing-prompt.js +1 -1
  160. package/node_modules/@xrkseek/exec-fs/dist/routing-prompt.js.map +1 -1
  161. package/node_modules/@xrkseek/exec-image-gen/README.md +13 -13
  162. package/node_modules/@xrkseek/exec-image-gen/package.json +28 -28
  163. package/node_modules/@xrkseek/exec-memory/README.md +14 -14
  164. package/node_modules/@xrkseek/exec-memory/dist/live-fragment.d.ts +11 -0
  165. package/node_modules/@xrkseek/exec-memory/dist/live-fragment.d.ts.map +1 -0
  166. package/node_modules/@xrkseek/exec-memory/dist/live-fragment.js +40 -0
  167. package/node_modules/@xrkseek/exec-memory/dist/live-fragment.js.map +1 -0
  168. package/node_modules/@xrkseek/exec-memory/package.json +28 -28
  169. package/node_modules/@xrkseek/exec-sandbox/README.md +15 -15
  170. package/node_modules/@xrkseek/exec-ssh/README.md +19 -19
  171. package/node_modules/@xrkseek/exec-subprocess/README.md +10 -10
  172. package/node_modules/@xrkseek/exec-video-analyze/README.md +11 -11
  173. package/node_modules/@xrkseek/exec-video-analyze/package.json +26 -26
  174. package/node_modules/@xrkseek/exec-video-gen/README.md +26 -26
  175. package/node_modules/@xrkseek/exec-voice/README.md +25 -25
  176. package/node_modules/@xrkseek/exec-web/README.md +11 -11
  177. package/node_modules/@xrkseek/exec-web/dist/fetch-http.d.ts +8 -0
  178. package/node_modules/@xrkseek/exec-web/dist/fetch-http.d.ts.map +1 -1
  179. package/node_modules/@xrkseek/exec-web/dist/fetch-http.js +5 -1
  180. package/node_modules/@xrkseek/exec-web/dist/fetch-http.js.map +1 -1
  181. package/node_modules/@xrkseek/exec-web/dist/format.d.ts.map +1 -1
  182. package/node_modules/@xrkseek/exec-web/dist/format.js +1 -0
  183. package/node_modules/@xrkseek/exec-web/dist/format.js.map +1 -1
  184. package/node_modules/@xrkseek/exec-web/dist/index.d.ts +2 -2
  185. package/node_modules/@xrkseek/exec-web/dist/index.d.ts.map +1 -1
  186. package/node_modules/@xrkseek/exec-web/dist/index.js +2 -2
  187. package/node_modules/@xrkseek/exec-web/dist/index.js.map +1 -1
  188. package/node_modules/@xrkseek/exec-web/dist/search-duckduckgo.d.ts.map +1 -1
  189. package/node_modules/@xrkseek/exec-web/dist/search-duckduckgo.js +15 -8
  190. package/node_modules/@xrkseek/exec-web/dist/search-duckduckgo.js.map +1 -1
  191. package/node_modules/@xrkseek/exec-web/dist/search-parallel-free.d.ts.map +1 -1
  192. package/node_modules/@xrkseek/exec-web/dist/search-parallel-free.js +21 -13
  193. package/node_modules/@xrkseek/exec-web/dist/search-parallel-free.js.map +1 -1
  194. package/node_modules/@xrkseek/exec-web/dist/search-providers.d.ts +16 -3
  195. package/node_modules/@xrkseek/exec-web/dist/search-providers.d.ts.map +1 -1
  196. package/node_modules/@xrkseek/exec-web/dist/search-providers.js +113 -7
  197. package/node_modules/@xrkseek/exec-web/dist/search-providers.js.map +1 -1
  198. package/node_modules/@xrkseek/exec-web/dist/tools.d.ts.map +1 -1
  199. package/node_modules/@xrkseek/exec-web/dist/tools.js +15 -2
  200. package/node_modules/@xrkseek/exec-web/dist/tools.js.map +1 -1
  201. package/node_modules/@xrkseek/exec-web/dist/types.d.ts +6 -0
  202. package/node_modules/@xrkseek/exec-web/dist/types.d.ts.map +1 -1
  203. package/node_modules/@xrkseek/llm-deepseek/README.md +22 -22
  204. package/node_modules/@xrkseek/llm-deepseek/package.json +30 -30
  205. package/node_modules/@xrkseek/llm-registry/dist/index.d.ts +2 -2
  206. package/node_modules/@xrkseek/llm-registry/dist/index.d.ts.map +1 -1
  207. package/node_modules/@xrkseek/llm-registry/dist/index.js +1 -1
  208. package/node_modules/@xrkseek/llm-registry/dist/index.js.map +1 -1
  209. package/node_modules/@xrkseek/llm-registry/dist/models-dev-catalog.d.ts.map +1 -1
  210. package/node_modules/@xrkseek/llm-registry/dist/models-dev-catalog.js +13 -2
  211. package/node_modules/@xrkseek/llm-registry/dist/models-dev-catalog.js.map +1 -1
  212. package/node_modules/@xrkseek/llm-registry/dist/registry.d.ts +6 -0
  213. package/node_modules/@xrkseek/llm-registry/dist/registry.d.ts.map +1 -1
  214. package/node_modules/@xrkseek/llm-registry/dist/registry.js +6 -0
  215. package/node_modules/@xrkseek/llm-registry/dist/registry.js.map +1 -1
  216. package/node_modules/@xrkseek/llm-registry/dist/types.d.ts +29 -0
  217. package/node_modules/@xrkseek/llm-registry/dist/types.d.ts.map +1 -1
  218. package/node_modules/@xrkseek/llm-registry/dist/types.js +21 -0
  219. package/node_modules/@xrkseek/llm-registry/dist/types.js.map +1 -1
  220. package/node_modules/@xrkseek/mcp/README.md +78 -78
  221. package/node_modules/@xrkseek/policy/README.md +18 -18
  222. package/node_modules/@xrkseek/policy/package.json +31 -31
  223. package/node_modules/@xrkseek/preset-harness/README.md +7 -7
  224. package/node_modules/@xrkseek/preset-harness/dist/mods.d.ts +68 -0
  225. package/node_modules/@xrkseek/preset-harness/dist/mods.d.ts.map +1 -0
  226. package/node_modules/@xrkseek/preset-harness/dist/mods.js +510 -0
  227. package/node_modules/@xrkseek/preset-harness/dist/mods.js.map +1 -0
  228. package/node_modules/@xrkseek/preset-harness/dist/preset.d.ts +12 -1
  229. package/node_modules/@xrkseek/preset-harness/dist/preset.d.ts.map +1 -1
  230. package/node_modules/@xrkseek/preset-harness/dist/preset.js +73 -26
  231. package/node_modules/@xrkseek/preset-harness/dist/preset.js.map +1 -1
  232. package/node_modules/@xrkseek/preset-harness/dist/tsconfig.tsbuildinfo +1 -1
  233. package/node_modules/@xrkseek/preset-harness/package.json +9 -8
  234. package/node_modules/@xrkseek/preset-minimal/README.md +6 -6
  235. package/node_modules/@xrkseek/preset-minimal/dist/preset.d.ts.map +1 -1
  236. package/node_modules/@xrkseek/preset-minimal/dist/preset.js +9 -3
  237. package/node_modules/@xrkseek/preset-minimal/dist/preset.js.map +1 -1
  238. package/node_modules/@xrkseek/preset-minimal/dist/tsconfig.tsbuildinfo +1 -1
  239. package/node_modules/@xrkseek/preset-server/README.md +4 -4
  240. package/node_modules/@xrkseek/preset-server/dist/preset.d.ts.map +1 -1
  241. package/node_modules/@xrkseek/preset-server/dist/preset.js +2 -1
  242. package/node_modules/@xrkseek/preset-server/dist/preset.js.map +1 -1
  243. package/node_modules/@xrkseek/preset-server/dist/tsconfig.tsbuildinfo +1 -1
  244. package/node_modules/@xrkseek/protocol/README.md +34 -34
  245. package/node_modules/@xrkseek/protocol/dist/content.d.ts.map +1 -1
  246. package/node_modules/@xrkseek/protocol/dist/content.js +6 -1
  247. package/node_modules/@xrkseek/protocol/dist/content.js.map +1 -1
  248. package/node_modules/@xrkseek/protocol/dist/index.d.ts +3 -2
  249. package/node_modules/@xrkseek/protocol/dist/index.d.ts.map +1 -1
  250. package/node_modules/@xrkseek/protocol/dist/index.js +1 -0
  251. package/node_modules/@xrkseek/protocol/dist/index.js.map +1 -1
  252. package/node_modules/@xrkseek/protocol/dist/json-schema.d.ts +12 -0
  253. package/node_modules/@xrkseek/protocol/dist/json-schema.d.ts.map +1 -1
  254. package/node_modules/@xrkseek/protocol/dist/json-schema.js +9 -0
  255. package/node_modules/@xrkseek/protocol/dist/json-schema.js.map +1 -1
  256. package/node_modules/@xrkseek/protocol/dist/json-value.d.ts +25 -0
  257. package/node_modules/@xrkseek/protocol/dist/json-value.d.ts.map +1 -0
  258. package/node_modules/@xrkseek/protocol/dist/json-value.js +181 -0
  259. package/node_modules/@xrkseek/protocol/dist/json-value.js.map +1 -0
  260. package/node_modules/@xrkseek/protocol/dist/session-events.d.ts +21 -1
  261. package/node_modules/@xrkseek/protocol/dist/session-events.d.ts.map +1 -1
  262. package/node_modules/@xrkseek/protocol/dist/session-events.js +1 -0
  263. package/node_modules/@xrkseek/protocol/dist/session-events.js.map +1 -1
  264. package/node_modules/@xrkseek/protocol/dist/validate.d.ts +4 -1
  265. package/node_modules/@xrkseek/protocol/dist/validate.d.ts.map +1 -1
  266. package/node_modules/@xrkseek/protocol/dist/validate.js +28 -2
  267. package/node_modules/@xrkseek/protocol/dist/validate.js.map +1 -1
  268. package/node_modules/@xrkseek/schemastery/lib/index.cjs +597 -597
  269. package/node_modules/@xrkseek/schemastery/lib/index.mjs +597 -597
  270. package/node_modules/@xrkseek/schemastery/lib/types/index.d.ts +203 -203
  271. package/node_modules/@xrkseek/schemastery/src/index.d.ts +203 -203
  272. package/node_modules/@xrkseek/schemastery/src/index.ts +906 -906
  273. package/node_modules/@xrkseek/server-config/package.json +28 -28
  274. package/node_modules/@xrkseek/server-cron/README.md +12 -12
  275. package/node_modules/@xrkseek/server-cron/package.json +26 -26
  276. package/node_modules/@xrkseek/server-face/dist/adapt/history-paginate.d.ts +22 -0
  277. package/node_modules/@xrkseek/server-face/dist/adapt/history-paginate.d.ts.map +1 -1
  278. package/node_modules/@xrkseek/server-face/dist/adapt/history-paginate.js +40 -3
  279. package/node_modules/@xrkseek/server-face/dist/adapt/history-paginate.js.map +1 -1
  280. package/node_modules/@xrkseek/server-face/dist/adapt/subagent-notice.d.ts.map +1 -1
  281. package/node_modules/@xrkseek/server-face/dist/adapt/subagent-notice.js +2 -0
  282. package/node_modules/@xrkseek/server-face/dist/adapt/subagent-notice.js.map +1 -1
  283. package/node_modules/@xrkseek/server-face/dist/adapt/wire-event.d.ts +1 -0
  284. package/node_modules/@xrkseek/server-face/dist/adapt/wire-event.d.ts.map +1 -1
  285. package/node_modules/@xrkseek/server-face/dist/adapt/wire-event.js +2 -0
  286. package/node_modules/@xrkseek/server-face/dist/adapt/wire-event.js.map +1 -1
  287. package/node_modules/@xrkseek/server-face/dist/adapt/wire-ids.d.ts +5 -0
  288. package/node_modules/@xrkseek/server-face/dist/adapt/wire-ids.d.ts.map +1 -1
  289. package/node_modules/@xrkseek/server-face/dist/adapt/wire-ids.js +7 -0
  290. package/node_modules/@xrkseek/server-face/dist/adapt/wire-ids.js.map +1 -1
  291. package/node_modules/@xrkseek/server-face/dist/agent-home-boundary.d.ts +31 -0
  292. package/node_modules/@xrkseek/server-face/dist/agent-home-boundary.d.ts.map +1 -0
  293. package/node_modules/@xrkseek/server-face/dist/agent-home-boundary.js +71 -0
  294. package/node_modules/@xrkseek/server-face/dist/agent-home-boundary.js.map +1 -0
  295. package/node_modules/@xrkseek/server-face/dist/agent-home.d.ts +18 -0
  296. package/node_modules/@xrkseek/server-face/dist/agent-home.d.ts.map +1 -0
  297. package/node_modules/@xrkseek/server-face/dist/agent-home.js +64 -0
  298. package/node_modules/@xrkseek/server-face/dist/agent-home.js.map +1 -0
  299. package/node_modules/@xrkseek/server-face/dist/agent-roster-store.d.ts +41 -2
  300. package/node_modules/@xrkseek/server-face/dist/agent-roster-store.d.ts.map +1 -1
  301. package/node_modules/@xrkseek/server-face/dist/agent-roster-store.js +200 -28
  302. package/node_modules/@xrkseek/server-face/dist/agent-roster-store.js.map +1 -1
  303. package/node_modules/@xrkseek/server-face/dist/agent-team-roles.js +1 -1
  304. package/node_modules/@xrkseek/server-face/dist/agent-team-roles.js.map +1 -1
  305. package/node_modules/@xrkseek/server-face/dist/attach-http.d.ts.map +1 -1
  306. package/node_modules/@xrkseek/server-face/dist/attach-http.js +9 -0
  307. package/node_modules/@xrkseek/server-face/dist/attach-http.js.map +1 -1
  308. package/node_modules/@xrkseek/server-face/dist/boss-status-broadcast.d.ts +55 -0
  309. package/node_modules/@xrkseek/server-face/dist/boss-status-broadcast.d.ts.map +1 -0
  310. package/node_modules/@xrkseek/server-face/dist/boss-status-broadcast.js +167 -0
  311. package/node_modules/@xrkseek/server-face/dist/boss-status-broadcast.js.map +1 -0
  312. package/node_modules/@xrkseek/server-face/dist/collab-board.d.ts +12 -0
  313. package/node_modules/@xrkseek/server-face/dist/collab-board.d.ts.map +1 -1
  314. package/node_modules/@xrkseek/server-face/dist/collab-board.js +101 -19
  315. package/node_modules/@xrkseek/server-face/dist/collab-board.js.map +1 -1
  316. package/node_modules/@xrkseek/server-face/dist/community-llm-sync.d.ts +2 -2
  317. package/node_modules/@xrkseek/server-face/dist/community-llm-sync.d.ts.map +1 -1
  318. package/node_modules/@xrkseek/server-face/dist/community-llm-sync.js +19 -7
  319. package/node_modules/@xrkseek/server-face/dist/community-llm-sync.js.map +1 -1
  320. package/node_modules/@xrkseek/server-face/dist/context.d.ts +29 -0
  321. package/node_modules/@xrkseek/server-face/dist/context.d.ts.map +1 -1
  322. package/node_modules/@xrkseek/server-face/dist/dispatch.d.ts.map +1 -1
  323. package/node_modules/@xrkseek/server-face/dist/dispatch.js +4 -1
  324. package/node_modules/@xrkseek/server-face/dist/dispatch.js.map +1 -1
  325. package/node_modules/@xrkseek/server-face/dist/face-schema.d.ts.map +1 -1
  326. package/node_modules/@xrkseek/server-face/dist/face-schema.js +2 -1
  327. package/node_modules/@xrkseek/server-face/dist/face-schema.js.map +1 -1
  328. package/node_modules/@xrkseek/server-face/dist/fork-cut.d.ts.map +1 -1
  329. package/node_modules/@xrkseek/server-face/dist/fork-cut.js +15 -3
  330. package/node_modules/@xrkseek/server-face/dist/fork-cut.js.map +1 -1
  331. package/node_modules/@xrkseek/server-face/dist/fork-lineage.d.ts +7 -0
  332. package/node_modules/@xrkseek/server-face/dist/fork-lineage.d.ts.map +1 -1
  333. package/node_modules/@xrkseek/server-face/dist/fork-lineage.js +23 -8
  334. package/node_modules/@xrkseek/server-face/dist/fork-lineage.js.map +1 -1
  335. package/node_modules/@xrkseek/server-face/dist/handlers/band.d.ts +7 -0
  336. package/node_modules/@xrkseek/server-face/dist/handlers/band.d.ts.map +1 -0
  337. package/node_modules/@xrkseek/server-face/dist/handlers/band.js +40 -0
  338. package/node_modules/@xrkseek/server-face/dist/handlers/band.js.map +1 -0
  339. package/node_modules/@xrkseek/server-face/dist/handlers/checkpoint.d.ts.map +1 -1
  340. package/node_modules/@xrkseek/server-face/dist/handlers/checkpoint.js +81 -3
  341. package/node_modules/@xrkseek/server-face/dist/handlers/checkpoint.js.map +1 -1
  342. package/node_modules/@xrkseek/server-face/dist/handlers/remotes.d.ts.map +1 -1
  343. package/node_modules/@xrkseek/server-face/dist/handlers/remotes.js +20 -7
  344. package/node_modules/@xrkseek/server-face/dist/handlers/remotes.js.map +1 -1
  345. package/node_modules/@xrkseek/server-face/dist/handlers/session.d.ts +2 -0
  346. package/node_modules/@xrkseek/server-face/dist/handlers/session.d.ts.map +1 -1
  347. package/node_modules/@xrkseek/server-face/dist/handlers/session.js +236 -62
  348. package/node_modules/@xrkseek/server-face/dist/handlers/session.js.map +1 -1
  349. package/node_modules/@xrkseek/server-face/dist/handlers/team.d.ts.map +1 -1
  350. package/node_modules/@xrkseek/server-face/dist/handlers/team.js +100 -9
  351. package/node_modules/@xrkseek/server-face/dist/handlers/team.js.map +1 -1
  352. package/node_modules/@xrkseek/server-face/dist/host-open-in-app.d.ts.map +1 -1
  353. package/node_modules/@xrkseek/server-face/dist/host-open-in-app.js +9 -0
  354. package/node_modules/@xrkseek/server-face/dist/host-open-in-app.js.map +1 -1
  355. package/node_modules/@xrkseek/server-face/dist/host-open-path.d.ts +8 -3
  356. package/node_modules/@xrkseek/server-face/dist/host-open-path.d.ts.map +1 -1
  357. package/node_modules/@xrkseek/server-face/dist/host-open-path.js +61 -19
  358. package/node_modules/@xrkseek/server-face/dist/host-open-path.js.map +1 -1
  359. package/node_modules/@xrkseek/server-face/dist/host-pick-directory.d.ts +2 -1
  360. package/node_modules/@xrkseek/server-face/dist/host-pick-directory.d.ts.map +1 -1
  361. package/node_modules/@xrkseek/server-face/dist/host-pick-directory.js +12 -2
  362. package/node_modules/@xrkseek/server-face/dist/host-pick-directory.js.map +1 -1
  363. package/node_modules/@xrkseek/server-face/dist/index.d.ts +6 -2
  364. package/node_modules/@xrkseek/server-face/dist/index.d.ts.map +1 -1
  365. package/node_modules/@xrkseek/server-face/dist/index.js +6 -2
  366. package/node_modules/@xrkseek/server-face/dist/index.js.map +1 -1
  367. package/node_modules/@xrkseek/server-face/dist/instruction-authority-fragment.d.ts +19 -0
  368. package/node_modules/@xrkseek/server-face/dist/instruction-authority-fragment.d.ts.map +1 -0
  369. package/node_modules/@xrkseek/server-face/dist/instruction-authority-fragment.js +28 -0
  370. package/node_modules/@xrkseek/server-face/dist/instruction-authority-fragment.js.map +1 -0
  371. package/node_modules/@xrkseek/server-face/dist/log-cut-reset.d.ts +3 -0
  372. package/node_modules/@xrkseek/server-face/dist/log-cut-reset.d.ts.map +1 -0
  373. package/node_modules/@xrkseek/server-face/dist/log-cut-reset.js +22 -0
  374. package/node_modules/@xrkseek/server-face/dist/log-cut-reset.js.map +1 -0
  375. package/node_modules/@xrkseek/server-face/dist/model-catalog.d.ts.map +1 -1
  376. package/node_modules/@xrkseek/server-face/dist/model-catalog.js +60 -5
  377. package/node_modules/@xrkseek/server-face/dist/model-catalog.js.map +1 -1
  378. package/node_modules/@xrkseek/server-face/dist/projections/index.d.ts +2 -2
  379. package/node_modules/@xrkseek/server-face/dist/projections/index.d.ts.map +1 -1
  380. package/node_modules/@xrkseek/server-face/dist/projections/index.js +2 -2
  381. package/node_modules/@xrkseek/server-face/dist/projections/index.js.map +1 -1
  382. package/node_modules/@xrkseek/server-face/dist/projections/list-checkpoint-cache.d.ts +50 -4
  383. package/node_modules/@xrkseek/server-face/dist/projections/list-checkpoint-cache.d.ts.map +1 -1
  384. package/node_modules/@xrkseek/server-face/dist/projections/list-checkpoint-cache.js +167 -19
  385. package/node_modules/@xrkseek/server-face/dist/projections/list-checkpoint-cache.js.map +1 -1
  386. package/node_modules/@xrkseek/server-face/dist/projections/snapshot-keys.d.ts +21 -1
  387. package/node_modules/@xrkseek/server-face/dist/projections/snapshot-keys.d.ts.map +1 -1
  388. package/node_modules/@xrkseek/server-face/dist/projections/snapshot-keys.js +21 -1
  389. package/node_modules/@xrkseek/server-face/dist/projections/snapshot-keys.js.map +1 -1
  390. package/node_modules/@xrkseek/server-face/dist/projections/units/context-pressure.d.ts +8 -4
  391. package/node_modules/@xrkseek/server-face/dist/projections/units/context-pressure.d.ts.map +1 -1
  392. package/node_modules/@xrkseek/server-face/dist/projections/units/context-pressure.js +2 -7
  393. package/node_modules/@xrkseek/server-face/dist/projections/units/context-pressure.js.map +1 -1
  394. package/node_modules/@xrkseek/server-face/dist/projections/units/context-timeline.d.ts.map +1 -1
  395. package/node_modules/@xrkseek/server-face/dist/projections/units/context-timeline.js +58 -0
  396. package/node_modules/@xrkseek/server-face/dist/projections/units/context-timeline.js.map +1 -1
  397. package/node_modules/@xrkseek/server-face/dist/projections/units/cost-usage.d.ts.map +1 -1
  398. package/node_modules/@xrkseek/server-face/dist/projections/units/cost-usage.js +85 -0
  399. package/node_modules/@xrkseek/server-face/dist/projections/units/cost-usage.js.map +1 -1
  400. package/node_modules/@xrkseek/server-face/dist/projections/units/session-list-metadata.d.ts.map +1 -1
  401. package/node_modules/@xrkseek/server-face/dist/projections/units/session-list-metadata.js +14 -0
  402. package/node_modules/@xrkseek/server-face/dist/projections/units/session-list-metadata.js.map +1 -1
  403. package/node_modules/@xrkseek/server-face/dist/projections/units/title.d.ts.map +1 -1
  404. package/node_modules/@xrkseek/server-face/dist/projections/units/title.js +14 -0
  405. package/node_modules/@xrkseek/server-face/dist/projections/units/title.js.map +1 -1
  406. package/node_modules/@xrkseek/server-face/dist/projections/units/turn-outline.d.ts.map +1 -1
  407. package/node_modules/@xrkseek/server-face/dist/projections/units/turn-outline.js +24 -0
  408. package/node_modules/@xrkseek/server-face/dist/projections/units/turn-outline.js.map +1 -1
  409. package/node_modules/@xrkseek/server-face/dist/runtime.d.ts +11 -1
  410. package/node_modules/@xrkseek/server-face/dist/runtime.d.ts.map +1 -1
  411. package/node_modules/@xrkseek/server-face/dist/runtime.js +118 -15
  412. package/node_modules/@xrkseek/server-face/dist/runtime.js.map +1 -1
  413. package/node_modules/@xrkseek/server-face/dist/seat-identity.d.ts +26 -0
  414. package/node_modules/@xrkseek/server-face/dist/seat-identity.d.ts.map +1 -0
  415. package/node_modules/@xrkseek/server-face/dist/seat-identity.js +137 -0
  416. package/node_modules/@xrkseek/server-face/dist/seat-identity.js.map +1 -0
  417. package/node_modules/@xrkseek/server-face/dist/seat-titles.d.ts +29 -0
  418. package/node_modules/@xrkseek/server-face/dist/seat-titles.d.ts.map +1 -0
  419. package/node_modules/@xrkseek/server-face/dist/seat-titles.js +74 -0
  420. package/node_modules/@xrkseek/server-face/dist/seat-titles.js.map +1 -0
  421. package/node_modules/@xrkseek/server-face/dist/session-capability.d.ts.map +1 -1
  422. package/node_modules/@xrkseek/server-face/dist/session-capability.js +9 -6
  423. package/node_modules/@xrkseek/server-face/dist/session-capability.js.map +1 -1
  424. package/node_modules/@xrkseek/server-face/dist/session-event-window.d.ts +37 -0
  425. package/node_modules/@xrkseek/server-face/dist/session-event-window.d.ts.map +1 -0
  426. package/node_modules/@xrkseek/server-face/dist/session-event-window.js +88 -0
  427. package/node_modules/@xrkseek/server-face/dist/session-event-window.js.map +1 -0
  428. package/node_modules/@xrkseek/server-face/dist/session-identity-store.d.ts +20 -0
  429. package/node_modules/@xrkseek/server-face/dist/session-identity-store.d.ts.map +1 -0
  430. package/node_modules/@xrkseek/server-face/dist/session-identity-store.js +82 -0
  431. package/node_modules/@xrkseek/server-face/dist/session-identity-store.js.map +1 -0
  432. package/node_modules/@xrkseek/server-face/dist/session-posture.d.ts +1 -1
  433. package/node_modules/@xrkseek/server-face/dist/session-posture.d.ts.map +1 -1
  434. package/node_modules/@xrkseek/server-face/dist/session-posture.js +20 -5
  435. package/node_modules/@xrkseek/server-face/dist/session-posture.js.map +1 -1
  436. package/node_modules/@xrkseek/server-face/dist/session-query-tools.d.ts +1 -0
  437. package/node_modules/@xrkseek/server-face/dist/session-query-tools.d.ts.map +1 -1
  438. package/node_modules/@xrkseek/server-face/dist/session-query-tools.js +172 -25
  439. package/node_modules/@xrkseek/server-face/dist/session-query-tools.js.map +1 -1
  440. package/node_modules/@xrkseek/server-face/dist/session-search.d.ts +20 -2
  441. package/node_modules/@xrkseek/server-face/dist/session-search.d.ts.map +1 -1
  442. package/node_modules/@xrkseek/server-face/dist/session-search.js +125 -19
  443. package/node_modules/@xrkseek/server-face/dist/session-search.js.map +1 -1
  444. package/node_modules/@xrkseek/server-face/dist/session-status.d.ts +6 -0
  445. package/node_modules/@xrkseek/server-face/dist/session-status.d.ts.map +1 -1
  446. package/node_modules/@xrkseek/server-face/dist/session-status.js +161 -21
  447. package/node_modules/@xrkseek/server-face/dist/session-status.js.map +1 -1
  448. package/node_modules/@xrkseek/server-face/dist/session-thread-tools.d.ts.map +1 -1
  449. package/node_modules/@xrkseek/server-face/dist/session-thread-tools.js +5 -0
  450. package/node_modules/@xrkseek/server-face/dist/session-thread-tools.js.map +1 -1
  451. package/node_modules/@xrkseek/server-face/dist/session-tool-copy.d.ts.map +1 -1
  452. package/node_modules/@xrkseek/server-face/dist/session-tool-copy.js +2 -1
  453. package/node_modules/@xrkseek/server-face/dist/session-tool-copy.js.map +1 -1
  454. package/node_modules/@xrkseek/server-face/dist/settings-credentials.d.ts.map +1 -1
  455. package/node_modules/@xrkseek/server-face/dist/settings-credentials.js +43 -3
  456. package/node_modules/@xrkseek/server-face/dist/settings-credentials.js.map +1 -1
  457. package/node_modules/@xrkseek/server-face/dist/settings-document.d.ts.map +1 -1
  458. package/node_modules/@xrkseek/server-face/dist/settings-document.js +4 -0
  459. package/node_modules/@xrkseek/server-face/dist/settings-document.js.map +1 -1
  460. package/node_modules/@xrkseek/server-face/dist/settings-schemas.d.ts.map +1 -1
  461. package/node_modules/@xrkseek/server-face/dist/settings-schemas.js +76 -11
  462. package/node_modules/@xrkseek/server-face/dist/settings-schemas.js.map +1 -1
  463. package/node_modules/@xrkseek/server-face/dist/skill-documents.d.ts.map +1 -1
  464. package/node_modules/@xrkseek/server-face/dist/skill-documents.js +14 -4
  465. package/node_modules/@xrkseek/server-face/dist/skill-documents.js.map +1 -1
  466. package/node_modules/@xrkseek/server-face/dist/skill-list.d.ts +4 -2
  467. package/node_modules/@xrkseek/server-face/dist/skill-list.d.ts.map +1 -1
  468. package/node_modules/@xrkseek/server-face/dist/skill-list.js +10 -4
  469. package/node_modules/@xrkseek/server-face/dist/skill-list.js.map +1 -1
  470. package/node_modules/@xrkseek/server-face/dist/skill-read.d.ts.map +1 -1
  471. package/node_modules/@xrkseek/server-face/dist/skill-read.js +9 -2
  472. package/node_modules/@xrkseek/server-face/dist/skill-read.js.map +1 -1
  473. package/node_modules/@xrkseek/server-face/dist/skill-source.d.ts +2 -1
  474. package/node_modules/@xrkseek/server-face/dist/skill-source.d.ts.map +1 -1
  475. package/node_modules/@xrkseek/server-face/dist/skill-source.js +12 -2
  476. package/node_modules/@xrkseek/server-face/dist/skill-source.js.map +1 -1
  477. package/node_modules/@xrkseek/server-face/dist/slash.d.ts +10 -1
  478. package/node_modules/@xrkseek/server-face/dist/slash.d.ts.map +1 -1
  479. package/node_modules/@xrkseek/server-face/dist/slash.js +118 -26
  480. package/node_modules/@xrkseek/server-face/dist/slash.js.map +1 -1
  481. package/node_modules/@xrkseek/server-face/dist/status-snapshot-cache.d.ts.map +1 -1
  482. package/node_modules/@xrkseek/server-face/dist/status-snapshot-cache.js +53 -0
  483. package/node_modules/@xrkseek/server-face/dist/status-snapshot-cache.js.map +1 -1
  484. package/node_modules/@xrkseek/server-face/dist/subagent-tools.d.ts.map +1 -1
  485. package/node_modules/@xrkseek/server-face/dist/subagent-tools.js +7 -2
  486. package/node_modules/@xrkseek/server-face/dist/subagent-tools.js.map +1 -1
  487. package/node_modules/@xrkseek/server-face/dist/types.d.ts +23 -0
  488. package/node_modules/@xrkseek/server-face/dist/types.d.ts.map +1 -1
  489. package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.d.ts +17 -2
  490. package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.d.ts.map +1 -1
  491. package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.js +111 -10
  492. package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.js.map +1 -1
  493. package/node_modules/@xrkseek/server-face/dist/workspace-face.d.ts.map +1 -1
  494. package/node_modules/@xrkseek/server-face/dist/workspace-face.js +19 -14
  495. package/node_modules/@xrkseek/server-face/dist/workspace-face.js.map +1 -1
  496. package/node_modules/@xrkseek/server-face/dist/workspace-member-look.d.ts +22 -0
  497. package/node_modules/@xrkseek/server-face/dist/workspace-member-look.d.ts.map +1 -0
  498. package/node_modules/@xrkseek/server-face/dist/workspace-member-look.js +35 -0
  499. package/node_modules/@xrkseek/server-face/dist/workspace-member-look.js.map +1 -0
  500. package/node_modules/@xrkseek/server-face/dist/workspace-orchestrate-tools.d.ts +3 -2
  501. package/node_modules/@xrkseek/server-face/dist/workspace-orchestrate-tools.d.ts.map +1 -1
  502. package/node_modules/@xrkseek/server-face/dist/workspace-orchestrate-tools.js +74 -57
  503. package/node_modules/@xrkseek/server-face/dist/workspace-orchestrate-tools.js.map +1 -1
  504. package/node_modules/@xrkseek/server-face/dist/workspace-registry.d.ts +31 -0
  505. package/node_modules/@xrkseek/server-face/dist/workspace-registry.d.ts.map +1 -1
  506. package/node_modules/@xrkseek/server-face/dist/workspace-registry.js +109 -0
  507. package/node_modules/@xrkseek/server-face/dist/workspace-registry.js.map +1 -1
  508. package/node_modules/@xrkseek/server-face/dist/workspace-store.d.ts +2 -0
  509. package/node_modules/@xrkseek/server-face/dist/workspace-store.d.ts.map +1 -1
  510. package/node_modules/@xrkseek/server-face/dist/workspace-store.js +7 -0
  511. package/node_modules/@xrkseek/server-face/dist/workspace-store.js.map +1 -1
  512. package/node_modules/@xrkseek/server-face/package.json +60 -60
  513. package/node_modules/@xrkseek/server-host/dist/index.d.ts +37 -6
  514. package/node_modules/@xrkseek/server-host/dist/index.d.ts.map +1 -1
  515. package/node_modules/@xrkseek/server-host/dist/index.js +182 -28
  516. package/node_modules/@xrkseek/server-host/dist/index.js.map +1 -1
  517. package/node_modules/@xrkseek/server-host/dist/log.d.ts +6 -0
  518. package/node_modules/@xrkseek/server-host/dist/log.d.ts.map +1 -1
  519. package/node_modules/@xrkseek/server-host/dist/sidebar-face-bridge.d.ts.map +1 -1
  520. package/node_modules/@xrkseek/server-host/dist/sidebar-face-bridge.js +17 -2
  521. package/node_modules/@xrkseek/server-host/dist/sidebar-face-bridge.js.map +1 -1
  522. package/node_modules/@xrkseek/server-host/dist/standing-tools.d.ts.map +1 -1
  523. package/node_modules/@xrkseek/server-host/dist/standing-tools.js +3 -3
  524. package/node_modules/@xrkseek/server-host/dist/standing-tools.js.map +1 -1
  525. package/node_modules/@xrkseek/server-host/package.json +75 -75
  526. package/node_modules/@xrkseek/server-http/dist/dsh-compat/adapter-types.d.ts +5 -0
  527. package/node_modules/@xrkseek/server-http/dist/dsh-compat/adapter-types.d.ts.map +1 -1
  528. package/node_modules/@xrkseek/server-http/dist/dsh-compat/auto-review-tool-pre.d.ts +1 -1
  529. package/node_modules/@xrkseek/server-http/dist/dsh-compat/auto-review-tool-pre.d.ts.map +1 -1
  530. package/node_modules/@xrkseek/server-http/dist/dsh-compat/genui-browser-runtime.js +188 -188
  531. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.d.ts +1 -1
  532. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.d.ts.map +1 -1
  533. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.js +1 -1
  534. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.js.map +1 -1
  535. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-auth.d.ts.map +1 -1
  536. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-auth.js +292 -24
  537. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-auth.js.map +1 -1
  538. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-gate.d.ts.map +1 -1
  539. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-gate.js +12 -1
  540. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-gate.js.map +1 -1
  541. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.d.ts +16 -1
  542. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.d.ts.map +1 -1
  543. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.js +47 -2
  544. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.js.map +1 -1
  545. package/node_modules/@xrkseek/server-http/dist/dsh-compat/skin-center.d.ts +1 -1
  546. package/node_modules/@xrkseek/server-http/dist/dsh-compat/token-usage-stats-dash.js +53 -53
  547. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.d.ts +9 -4
  548. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.d.ts.map +1 -1
  549. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.js +39 -20
  550. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.js.map +1 -1
  551. package/node_modules/@xrkseek/server-http/dist/index.d.ts +2 -1
  552. package/node_modules/@xrkseek/server-http/dist/index.d.ts.map +1 -1
  553. package/node_modules/@xrkseek/server-http/dist/index.js +2 -1
  554. package/node_modules/@xrkseek/server-http/dist/index.js.map +1 -1
  555. package/node_modules/@xrkseek/server-http/dist/sunflower-free/ensure.d.ts +55 -0
  556. package/node_modules/@xrkseek/server-http/dist/sunflower-free/ensure.d.ts.map +1 -0
  557. package/node_modules/@xrkseek/server-http/dist/sunflower-free/ensure.js +176 -0
  558. package/node_modules/@xrkseek/server-http/dist/sunflower-free/ensure.js.map +1 -0
  559. package/node_modules/@xrkseek/server-http/dist/xrk/plugin-mutate.d.ts +2 -0
  560. package/node_modules/@xrkseek/server-http/dist/xrk/plugin-mutate.d.ts.map +1 -1
  561. package/node_modules/@xrkseek/server-http/dist/xrk/plugin-mutate.js +7 -3
  562. package/node_modules/@xrkseek/server-http/dist/xrk/plugin-mutate.js.map +1 -1
  563. package/node_modules/@xrkseek/server-http/package.json +72 -72
  564. package/node_modules/@xrkseek/server-loader/dist/load.d.ts.map +1 -1
  565. package/node_modules/@xrkseek/server-loader/dist/load.js +132 -0
  566. package/node_modules/@xrkseek/server-loader/dist/load.js.map +1 -1
  567. package/node_modules/@xrkseek/session-projection/README.md +26 -26
  568. package/node_modules/@xrkseek/session-projection/dist/index.d.ts +31 -2
  569. package/node_modules/@xrkseek/session-projection/dist/index.d.ts.map +1 -1
  570. package/node_modules/@xrkseek/session-projection/dist/index.js +135 -19
  571. package/node_modules/@xrkseek/session-projection/dist/index.js.map +1 -1
  572. package/node_modules/@xrkseek/session-telemetry/README.md +11 -11
  573. package/node_modules/@xrkseek/session-telemetry/dist/index.d.ts +1 -0
  574. package/node_modules/@xrkseek/session-telemetry/dist/index.d.ts.map +1 -1
  575. package/node_modules/@xrkseek/session-telemetry/dist/index.js +1 -0
  576. package/node_modules/@xrkseek/session-telemetry/dist/index.js.map +1 -1
  577. package/node_modules/@xrkseek/session-telemetry/dist/redact.d.ts +14 -0
  578. package/node_modules/@xrkseek/session-telemetry/dist/redact.d.ts.map +1 -0
  579. package/node_modules/@xrkseek/session-telemetry/dist/redact.js +58 -0
  580. package/node_modules/@xrkseek/session-telemetry/dist/redact.js.map +1 -0
  581. package/node_modules/@xrkseek/session-telemetry/dist/wrap-store.d.ts +7 -0
  582. package/node_modules/@xrkseek/session-telemetry/dist/wrap-store.d.ts.map +1 -1
  583. package/node_modules/@xrkseek/session-telemetry/dist/wrap-store.js +43 -12
  584. package/node_modules/@xrkseek/session-telemetry/dist/wrap-store.js.map +1 -1
  585. package/node_modules/@xrkseek/session-telemetry/package.json +27 -27
  586. package/node_modules/@xrkseek/workspace/dist/durable-inject.d.ts +13 -0
  587. package/node_modules/@xrkseek/workspace/dist/durable-inject.d.ts.map +1 -1
  588. package/node_modules/@xrkseek/workspace/dist/durable-inject.js +40 -4
  589. package/node_modules/@xrkseek/workspace/dist/durable-inject.js.map +1 -1
  590. package/node_modules/@xrkseek/workspace/dist/ecosystem-instructions.d.ts +10 -9
  591. package/node_modules/@xrkseek/workspace/dist/ecosystem-instructions.d.ts.map +1 -1
  592. package/node_modules/@xrkseek/workspace/dist/ecosystem-instructions.js +67 -19
  593. package/node_modules/@xrkseek/workspace/dist/ecosystem-instructions.js.map +1 -1
  594. package/node_modules/@xrkseek/workspace/dist/index.d.ts +19 -20
  595. package/node_modules/@xrkseek/workspace/dist/index.d.ts.map +1 -1
  596. package/node_modules/@xrkseek/workspace/dist/index.js +43 -20
  597. package/node_modules/@xrkseek/workspace/dist/index.js.map +1 -1
  598. package/node_modules/@xrkseek/workspace/dist/inject-fingerprint.d.ts +2 -0
  599. package/node_modules/@xrkseek/workspace/dist/inject-fingerprint.d.ts.map +1 -1
  600. package/node_modules/@xrkseek/workspace/dist/inject-fingerprint.js +23 -12
  601. package/node_modules/@xrkseek/workspace/dist/inject-fingerprint.js.map +1 -1
  602. package/node_modules/@xrkseek/workspace/dist/inject-sources.d.ts +7 -4
  603. package/node_modules/@xrkseek/workspace/dist/inject-sources.d.ts.map +1 -1
  604. package/node_modules/@xrkseek/workspace/dist/inject-sources.js +10 -0
  605. package/node_modules/@xrkseek/workspace/dist/inject-sources.js.map +1 -1
  606. package/node_modules/@xrkseek/workspace/dist/instruction-authority.d.ts +27 -0
  607. package/node_modules/@xrkseek/workspace/dist/instruction-authority.d.ts.map +1 -0
  608. package/node_modules/@xrkseek/workspace/dist/instruction-authority.js +78 -0
  609. package/node_modules/@xrkseek/workspace/dist/instruction-authority.js.map +1 -0
  610. package/node_modules/@xrkseek/workspace/dist/skill-dirs.d.ts +7 -0
  611. package/node_modules/@xrkseek/workspace/dist/skill-dirs.d.ts.map +1 -1
  612. package/node_modules/@xrkseek/workspace/dist/skill-dirs.js +4 -2
  613. package/node_modules/@xrkseek/workspace/dist/skill-dirs.js.map +1 -1
  614. package/node_modules/@xrkseek/workspace/dist/skill-tools.js +1 -1
  615. package/node_modules/@xrkseek/workspace/dist/skill-tools.js.map +1 -1
  616. package/node_modules/@xrkseek/workspace/dist/skills.d.ts +13 -1
  617. package/node_modules/@xrkseek/workspace/dist/skills.d.ts.map +1 -1
  618. package/node_modules/@xrkseek/workspace/dist/skills.js +45 -5
  619. package/node_modules/@xrkseek/workspace/dist/skills.js.map +1 -1
  620. package/node_modules/@xrkseek/workspace/dist/standing-skill-dirs.d.ts +26 -0
  621. package/node_modules/@xrkseek/workspace/dist/standing-skill-dirs.d.ts.map +1 -0
  622. package/node_modules/@xrkseek/workspace/dist/standing-skill-dirs.js +80 -0
  623. package/node_modules/@xrkseek/workspace/dist/standing-skill-dirs.js.map +1 -0
  624. package/node_modules/@xrkseek/workspace/dist/workspace-anchor.d.ts +7 -1
  625. package/node_modules/@xrkseek/workspace/dist/workspace-anchor.d.ts.map +1 -1
  626. package/node_modules/@xrkseek/workspace/dist/workspace-anchor.js +21 -1
  627. package/node_modules/@xrkseek/workspace/dist/workspace-anchor.js.map +1 -1
  628. package/node_modules/@xrkseek/workspace/package.json +28 -28
  629. package/node_modules/@xrkseek/xrk-agent/lib/index.js +1 -793
  630. package/node_modules/@xrkseek/xrk-agent/lib/invariant.js +1 -23
  631. package/node_modules/@xrkseek/xrk-attachment/lib/index.js +1 -1
  632. package/node_modules/@xrkseek/xrk-attachment/lib/invariant.js +1 -0
  633. package/node_modules/@xrkseek/xrk-attachment/lib/types/brand.js +10 -0
  634. package/node_modules/@xrkseek/xrk-attachment/lib/types/error.js +48 -0
  635. package/node_modules/@xrkseek/xrk-attachment/lib/types/index.js +42 -0
  636. package/node_modules/@xrkseek/xrk-attachment/lib/types/invariant.js +16 -0
  637. package/node_modules/@xrkseek/xrk-attachment/lib/types/types.d.ts +6 -0
  638. package/node_modules/@xrkseek/xrk-attachment/lib/types/types.js +3 -0
  639. package/node_modules/@xrkseek/xrk-attachment/package.json +1 -0
  640. package/node_modules/@xrkseek/xrk-brand/lib/index.js +1 -1
  641. package/node_modules/@xrkseek/xrk-brand/lib/invariant.js +1 -0
  642. package/node_modules/@xrkseek/xrk-brand/lib/types/index.js +24 -0
  643. package/node_modules/@xrkseek/xrk-brand/lib/types/invariant.js +22 -0
  644. package/node_modules/@xrkseek/xrk-brand/package.json +1 -0
  645. package/node_modules/@xrkseek/xrk-commands/lib/index.js +1 -1
  646. package/node_modules/@xrkseek/xrk-commands/lib/invariant.js +1 -0
  647. package/node_modules/@xrkseek/xrk-file-reference-local/README.md +46 -46
  648. package/node_modules/@xrkseek/xrk-file-reference-local/README.zh.md +46 -46
  649. package/node_modules/@xrkseek/xrk-file-reference-local/package.json +30 -30
  650. package/node_modules/@xrkseek/xrk-invariants/lib/index.js +1 -1
  651. package/node_modules/@xrkseek/xrk-invariants/lib/invariant.js +1 -0
  652. package/node_modules/@xrkseek/xrk-invariants/lib/types/index.js +148 -0
  653. package/node_modules/@xrkseek/xrk-invariants/lib/types/invariant.js +22 -0
  654. package/node_modules/@xrkseek/xrk-invariants/package.json +1 -0
  655. package/node_modules/@xrkseek/xrk-llm/lib/index.js +1 -1
  656. package/node_modules/@xrkseek/xrk-llm/lib/invariant.js +1 -0
  657. package/node_modules/@xrkseek/xrk-llm/lib/types/index.js +4 -0
  658. package/node_modules/@xrkseek/xrk-llm/lib/types/types.d.ts +11 -0
  659. package/node_modules/@xrkseek/xrk-permission-presets/lib/index.js +1 -1
  660. package/node_modules/@xrkseek/xrk-permission-presets/lib/invariant.js +1 -0
  661. package/node_modules/@xrkseek/xrk-scope/lib/index.js +1 -0
  662. package/node_modules/@xrkseek/xrk-scope/lib/types/index.d.ts +129 -0
  663. package/node_modules/@xrkseek/xrk-scope/lib/types/index.js +243 -0
  664. package/node_modules/@xrkseek/xrk-scope/package.json +34 -0
  665. package/node_modules/@xrkseek/xrk-session/lib/index.js +1 -1
  666. package/node_modules/@xrkseek/xrk-session/lib/invariant.js +1 -0
  667. package/node_modules/@xrkseek/xrk-session-projection/lib/index.js +1 -1
  668. package/node_modules/@xrkseek/xrk-session-projection/lib/invariant.js +1 -0
  669. package/node_modules/@xrkseek/xrk-session-reference/README.md +50 -50
  670. package/node_modules/@xrkseek/xrk-session-reference/README.zh.md +50 -50
  671. package/node_modules/@xrkseek/xrk-session-reference/dist/prepare-face.js +13 -13
  672. package/node_modules/@xrkseek/xrk-session-reference/dist/spill.js +2 -2
  673. package/node_modules/@xrkseek/xrk-session-reference/package.json +56 -56
  674. package/node_modules/@xrkseek/xrk-settings/lib/index.js +1 -638
  675. package/node_modules/@xrkseek/xrk-settings/lib/invariant.js +1 -67
  676. package/node_modules/@xrkseek/xrk-system-prompt/package.json +15 -15
  677. package/node_modules/@xrkseek/xrk-system-prompt/src/index.ts +144 -144
  678. package/node_modules/@xrkseek/xrk-token-meter/README.i18n.yaml +6 -0
  679. package/node_modules/@xrkseek/xrk-token-meter/README.md +68 -0
  680. package/node_modules/@xrkseek/xrk-token-meter/README.zh.md +68 -0
  681. package/node_modules/@xrkseek/xrk-token-meter/lib/index.js +1 -0
  682. package/node_modules/@xrkseek/xrk-token-meter/lib/invariant.js +1 -0
  683. package/node_modules/@xrkseek/xrk-token-meter/lib/types/breakdown-projection.d.ts +29 -0
  684. package/node_modules/@xrkseek/xrk-token-meter/lib/types/breakdown-projection.js +56 -0
  685. package/node_modules/@xrkseek/xrk-token-meter/lib/types/client.d.ts +9 -0
  686. package/node_modules/@xrkseek/xrk-token-meter/lib/types/client.js +7 -0
  687. package/node_modules/@xrkseek/xrk-token-meter/lib/types/estimate.d.ts +42 -0
  688. package/node_modules/@xrkseek/xrk-token-meter/lib/types/estimate.js +79 -0
  689. package/node_modules/@xrkseek/xrk-token-meter/lib/types/index.d.ts +62 -0
  690. package/node_modules/@xrkseek/xrk-token-meter/lib/types/index.js +250 -0
  691. package/node_modules/@xrkseek/xrk-token-meter/lib/types/invariant.d.ts +16 -0
  692. package/node_modules/@xrkseek/xrk-token-meter/lib/types/invariant.js +30 -0
  693. package/node_modules/@xrkseek/xrk-token-meter/lib/types/projection.d.ts +74 -0
  694. package/node_modules/@xrkseek/xrk-token-meter/lib/types/projection.js +7 -0
  695. package/node_modules/@xrkseek/xrk-token-meter/lib/types/surface-fold.d.ts +38 -0
  696. package/node_modules/@xrkseek/xrk-token-meter/lib/types/surface-fold.js +47 -0
  697. package/node_modules/@xrkseek/xrk-token-meter/lib/types/surface-projection.d.ts +59 -0
  698. package/node_modules/@xrkseek/xrk-token-meter/lib/types/surface-projection.js +66 -0
  699. package/node_modules/@xrkseek/xrk-token-meter/lib/types/turn-usage.d.ts +33 -0
  700. package/node_modules/@xrkseek/xrk-token-meter/lib/types/turn-usage.js +247 -0
  701. package/node_modules/@xrkseek/xrk-token-meter/lib/types/types.d.ts +44 -0
  702. package/node_modules/@xrkseek/xrk-token-meter/lib/types/types.js +7 -0
  703. package/node_modules/@xrkseek/xrk-token-meter/lib/types/usage-projection.d.ts +64 -0
  704. package/node_modules/@xrkseek/xrk-token-meter/lib/types/usage-projection.js +161 -0
  705. package/node_modules/@xrkseek/xrk-token-meter/package.json +57 -0
  706. package/node_modules/@xrkseek/xrk-tools/lib/index.js +1 -1
  707. package/node_modules/@xrkseek/xrk-tools/lib/invariant.js +1 -1
  708. package/node_modules/@xrkseek/xrk-tools/src/presentation.ts +39 -39
  709. package/node_modules/@xrkseek/xrk-typert-protocol/lib/index.js +1 -1
  710. package/node_modules/@xrkseek/xrk-typert-protocol/lib/invariant.js +1 -0
  711. package/node_modules/@xrkseek/xrk-workflow/README.md +73 -73
  712. package/node_modules/@xrkseek/xrk-workflow/README.zh.md +72 -72
  713. package/node_modules/@xrkseek/xrk-workflow/lib/types/index.js +118 -118
  714. package/package.json +7 -1
  715. package/node_modules/@xrkseek/llm/dist/reasoning-effort.d.ts +0 -14
  716. package/node_modules/@xrkseek/llm/dist/reasoning-effort.d.ts.map +0 -1
  717. package/node_modules/@xrkseek/llm/dist/reasoning-effort.js +0 -21
  718. package/node_modules/@xrkseek/llm/dist/reasoning-effort.js.map +0 -1
  719. package/node_modules/@xrkseek/server-face/dist/index.d.mts +0 -3734
  720. package/node_modules/@xrkseek/server-face/dist/index.d.mts.map +0 -1
  721. package/node_modules/@xrkseek/server-face/dist/index.mjs +0 -22085
  722. package/node_modules/@xrkseek/server-face/dist/index.mjs.map +0 -1
  723. package/node_modules/@xrkseek/server-face/dist/model-reasoning.d.ts +0 -51
  724. package/node_modules/@xrkseek/server-face/dist/model-reasoning.d.ts.map +0 -1
  725. package/node_modules/@xrkseek/server-face/dist/model-reasoning.js +0 -104
  726. package/node_modules/@xrkseek/server-face/dist/model-reasoning.js.map +0 -1
  727. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-agent.d.ts +0 -2
  728. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-agent.d.ts.map +0 -1
  729. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-agent.js +0 -98
  730. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-agent.js.map +0 -1
  731. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-worker.d.ts +0 -18
  732. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-worker.d.ts.map +0 -1
  733. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-worker.js +0 -141
  734. package/node_modules/@xrkseek/server-host/dist/sidebar-pty-worker.js.map +0 -1
  735. package/node_modules/@xrkseek/server-host/dist/win-fd-inherit.d.ts +0 -30
  736. package/node_modules/@xrkseek/server-host/dist/win-fd-inherit.d.ts.map +0 -1
  737. package/node_modules/@xrkseek/server-host/dist/win-fd-inherit.js +0 -96
  738. package/node_modules/@xrkseek/server-host/dist/win-fd-inherit.js.map +0 -1
@@ -38,12 +38,27 @@ export declare const DEFAULT_SOFT_BUDGET_PEEL_ATTEMPTS = 3;
38
38
  * (before the buffer-adjusted ceiling), so pressure is not already near fail-closed.
39
39
  */
40
40
  export declare const SOFT_BUDGET_COMPACT_TRIGGER_RATIO = 0.9;
41
+ /**
42
+ * Codex `auto_compact_token_limit` when omitted: 90% of the model context window.
43
+ * Soft budget blank → derive this (never “blank = no proactive compact”).
44
+ */
45
+ export declare const AUTO_COMPACT_WINDOW_RATIO = 0.9;
46
+ /** Minimum window that can seed a derived soft budget (same floor as catalog soft). */
47
+ export declare const AUTO_COMPACT_MIN_CONTEXT_WINDOW = 8000;
48
+ /**
49
+ * Codex-style auto-compact ceiling from a route `contextWindow`.
50
+ * `floor(window × 0.9)`; undefined when the window is missing or too small.
51
+ */
52
+ export declare function deriveAutoCompactMaxTokens(contextWindow: number | undefined): number | undefined;
41
53
  /**
42
54
  * Budget estimator for `selectHeadRecent` / overflow (`chars/4` via {@link estimateText}).
43
55
  */
44
56
  export declare function estimateTokens(text: string): number;
57
+ type TextEstimator = (text: string) => number;
45
58
  export declare function estimateMessagesTokens(messages: readonly ChatMessage[], options?: {
46
59
  readonly inputModalities?: readonly InputModality[];
60
+ /** Default {@link estimateTokens}; soft-budget uses denser CJK. */
61
+ readonly textEst?: TextEstimator;
47
62
  }): number;
48
63
  /**
49
64
  * Soft-budget / overflow estimator for one outbound LLM request:
@@ -60,6 +75,11 @@ export declare function estimateRequestTokens(input: {
60
75
  readonly system?: string;
61
76
  /** Active adapter modalities; text-only routes price images as placeholders. */
62
77
  readonly inputModalities?: readonly InputModality[];
78
+ /**
79
+ * `soft-budget`: CJK-dense text (no provider usage sample). Default fixed
80
+ * chars/4 for keep/recent selection and meter-adjacent callers.
81
+ */
82
+ readonly density?: "fixed" | "soft-budget";
63
83
  }): number;
64
84
  /**
65
85
  * Inclusive soft-budget allow ceiling: `maxRequestTokens − buffer`.
@@ -67,6 +87,19 @@ export declare function estimateRequestTokens(input: {
67
87
  * non-empty turn (误杀) — treat that misconfig as buffer 0.
68
88
  */
69
89
  export declare function resolveSoftBudgetCeiling(maxRequestTokens: number, bufferTokens: number): number;
90
+ /**
91
+ * Soft-budget pre-trigger tokens (Face `softBudgetTriggerPercent` as a ratio).
92
+ *
93
+ * When the effective soft max already equals Codex `floor(window × 0.9)`
94
+ * (blank soft derived from the window, or ring-forced clamp to that line),
95
+ * do **not** multiply by `triggerRatio` again — that would compact near
96
+ * ~81% of the window while Codex's limit *is* the 90% line.
97
+ */
98
+ export declare function resolveSoftBudgetTriggerTokens(input: {
99
+ readonly maxRequestTokens: number;
100
+ readonly triggerRatio: number;
101
+ readonly windowForceTokens?: number;
102
+ }): number;
70
103
  /** Soft-budget numbers resolved for one outbound step (SDK or model catalog). */
71
104
  export interface ResolvedSoftBudget {
72
105
  readonly maxRequestTokens: number;
@@ -76,6 +109,11 @@ export interface ResolvedSoftBudget {
76
109
  /**
77
110
  * Derive keep/buffer defaults from a soft-budget max (old Face 24k/4k @ 100k).
78
111
  * Explicit keep/buffer win when provided and valid.
112
+ *
113
+ * When catalog/SDK soft max is omitted, Codex posture: derive
114
+ * `floor(contextWindow × 0.9)` so blank never means “no proactive compact”.
115
+ * With a provider ring, callers should also `min` with
116
+ * {@link deriveAutoCompactMaxTokens} so a too-large soft cannot outrun the window.
79
117
  */
80
118
  export declare function resolveSoftBudgetTokens(input: {
81
119
  readonly softBudgetMaxTokens?: number;
@@ -85,6 +123,11 @@ export declare function resolveSoftBudgetTokens(input: {
85
123
  readonly maxRequestTokens?: number;
86
124
  readonly keepTokens?: number;
87
125
  readonly bufferTokens?: number;
126
+ /**
127
+ * Route capacity. Seeds soft max when softBudgetMax / maxRequestTokens are
128
+ * blank (Codex `auto_compact_token_limit` from context_window).
129
+ */
130
+ readonly contextWindow?: number;
88
131
  }): ResolvedSoftBudget | undefined;
89
132
  export declare const COMPACTION_SUMMARY_TEMPLATE = "Output exactly this Markdown structure (keep section order). Do not mention that context was compacted.\n\n## Objective\n- [what the user is trying to accomplish, or \"(none)\"]\n\n## Decisions\n- [constraints, choices and why, or \"(none)\"]\n\n## State\n### Done\n- [finished work / verified facts, or \"(none)\"]\n### Active\n- [current work / partial state, or \"(none)\"]\n### Blocked\n- [blockers / unknowns, or \"(none)\"]\n\n## Next\n1. [immediate next action, or \"(none)\"]\n\n## Files\n- [path: why it matters, or \"(none)\"]";
90
133
  /**
@@ -132,8 +175,8 @@ export interface CompactionOptions {
132
175
  * - `prune-summary` (default): prune oversized tools, then LLM summary
133
176
  * - `prune-only`: model-free prune only; still fail-closed if over budget / overflow
134
177
  * - `summary-only`: skip prune pass; LLM summary only
135
- * - `off`: disable soft-budget auto path and provider-overflow recovery
136
- * (manual `/compact` still works)
178
+ * - `off`: disable soft-budget auto path only; provider-overflow still recovers
179
+ * once via prune→summary (manual `/compact` still works)
137
180
  */
138
181
  readonly strategy?: CompactionStrategy;
139
182
  /**
@@ -162,4 +205,5 @@ export declare function prepareCompactionPayload(events: readonly SessionEvent[]
162
205
  readonly prompt: string;
163
206
  readonly recent: string;
164
207
  } | undefined;
208
+ export {};
165
209
  //# sourceMappingURL=compaction.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"compaction.d.ts","sourceRoot":"","sources":["../src/compaction.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EACV,WAAW,EACX,sBAAsB,EAEtB,YAAY,EACb,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAyB,KAAK,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAQlF;;;;;;GAMG;AACH,eAAO,MAAM,8BAA8B,QAAS,CAAC;AACrD,eAAO,MAAM,gCAAgC,OAAQ,CAAC;AAEtD;;;;;GAKG;AACH,eAAO,MAAM,8BAA8B,QAAS,CAAC;AACrD,uFAAuF;AACvF,eAAO,MAAM,oCAAoC,IAAI,CAAC;AACtD;;;GAGG;AACH,eAAO,MAAM,yBAAyB,QAAS,CAAC;AAChD;;;GAGG;AACH,eAAO,MAAM,iCAAiC,IAAI,CAAC;AACnD;;;GAGG;AACH,eAAO,MAAM,iCAAiC,MAAM,CAAC;AAErD;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEnD;AAiDD,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,SAAS,WAAW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AE,MAAM,CAAC;IACzC;;;OAGG;IACH,QAAQ,CAAC,sBAAsB,CAAC,EAAE,MAAM,CAAC;IACzC;;;OAGG;IACH,QAAQ,CAAC,sBAAsB,CAAC,EAAE,MAAM,CAAC;CAC1C;AAED,kFAAkF;AAClF,MAAM,MAAM,kBAAkB,GAC1B,eAAe,GACf,YAAY,GACZ,cAAc,GACd,KAAK,CAAC;AAEV,eAAO,MAAM,qBAAqB,EAAE,SAAS,kBAAkB,EAKrD,CAAC;AAEX,wBAAgB,uBAAuB,CACrC,GAAG,EAAE,OAAO,GACX,kBAAkB,GAAG,SAAS,CAMhC;AAED,iFAAiF;AACjF,wBAAgB,yBAAyB,CACvC,OAAO,EAAE,iBAAiB,GAAG,SAAS,GACrC,kBAAkB,CAGpB;AAGD,wBAAgB,wBAAwB,CACtC,MAAM,EAAE,SAAS,YAAY,EAAE,EAC/B,UAAU,EAAE,MAAM,GAEhB;IACE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB,GACD,SAAS,CAgCZ"}
@@ -4,8 +4,7 @@
4
4
  * @see docs/session-compaction.md
5
5
  */
6
6
  import { flattenText } from "@xrkseek/protocol";
7
- import { priceRouteImageTokens } from "./surface-estimate.js";
8
- import { estimateText } from "./surface-estimate.js";
7
+ import { estimateText, estimateTextForSoftBudget, priceRouteImageTokens, } from "./surface-estimate.js";
9
8
  import { foldImageOffloadMarks, messageHasImageBlocks, projectOffloadedImages, } from "./image-offload.js";
10
9
  /**
11
10
  * Default keep/buffer for auto-compact when a caller does not pass explicit
@@ -40,6 +39,26 @@ export const DEFAULT_SOFT_BUDGET_PEEL_ATTEMPTS = 3;
40
39
  * (before the buffer-adjusted ceiling), so pressure is not already near fail-closed.
41
40
  */
42
41
  export const SOFT_BUDGET_COMPACT_TRIGGER_RATIO = 0.9;
42
+ /**
43
+ * Codex `auto_compact_token_limit` when omitted: 90% of the model context window.
44
+ * Soft budget blank → derive this (never “blank = no proactive compact”).
45
+ */
46
+ export const AUTO_COMPACT_WINDOW_RATIO = 0.9;
47
+ /** Minimum window that can seed a derived soft budget (same floor as catalog soft). */
48
+ export const AUTO_COMPACT_MIN_CONTEXT_WINDOW = 8_000;
49
+ /**
50
+ * Codex-style auto-compact ceiling from a route `contextWindow`.
51
+ * `floor(window × 0.9)`; undefined when the window is missing or too small.
52
+ */
53
+ export function deriveAutoCompactMaxTokens(contextWindow) {
54
+ if (typeof contextWindow !== "number" ||
55
+ !Number.isFinite(contextWindow) ||
56
+ contextWindow < AUTO_COMPACT_MIN_CONTEXT_WINDOW) {
57
+ return undefined;
58
+ }
59
+ const n = Math.floor(contextWindow * AUTO_COMPACT_WINDOW_RATIO);
60
+ return n >= 1 ? n : undefined;
61
+ }
43
62
  /**
44
63
  * Budget estimator for `selectHeadRecent` / overflow (`chars/4` via {@link estimateText}).
45
64
  */
@@ -59,7 +78,7 @@ function messagePlainText(m) {
59
78
  * Image blocks use {@link priceRouteImageTokens} (pass `inputModalities` from
60
79
  * the adapter; omit → annotated heuristic).
61
80
  */
62
- function estimateOpaqueContentBlocks(content, inputModalities) {
81
+ function estimateOpaqueContentBlocks(content, inputModalities, textEst = estimateTokens) {
63
82
  if (typeof content === "string")
64
83
  return 0;
65
84
  let n = 0;
@@ -87,25 +106,26 @@ function estimateOpaqueContentBlocks(content, inputModalities) {
87
106
  }
88
107
  if (block.type === "file")
89
108
  continue;
90
- n += estimateTokens(JSON.stringify(block));
109
+ n += textEst(JSON.stringify(block));
91
110
  }
92
111
  return n;
93
112
  }
94
113
  export function estimateMessagesTokens(messages, options) {
114
+ const textEst = options?.textEst ?? estimateTokens;
95
115
  let n = 0;
96
116
  for (const m of messages) {
97
- n += estimateTokens(messagePlainText(m));
117
+ n += textEst(messagePlainText(m));
98
118
  if (m.role === "assistant" && m.reasoning?.trim()) {
99
119
  // On the wire as reasoning_content; flattenText never sees it.
100
- n += estimateTokens(m.reasoning);
120
+ n += textEst(m.reasoning);
101
121
  }
102
122
  if (m.role === "user" || m.role === "tool") {
103
- n += estimateOpaqueContentBlocks(m.content, options?.inputModalities);
123
+ n += estimateOpaqueContentBlocks(m.content, options?.inputModalities, textEst);
104
124
  }
105
125
  if (m.role === "assistant" && m.toolCalls) {
106
126
  for (const c of m.toolCalls) {
107
- n += estimateTokens(c.name);
108
- n += estimateTokens(JSON.stringify(c.arguments ?? {}));
127
+ n += textEst(c.name);
128
+ n += textEst(JSON.stringify(c.arguments ?? {}));
109
129
  }
110
130
  }
111
131
  }
@@ -117,10 +137,12 @@ export function estimateMessagesTokens(messages, options) {
117
137
  * the assemble path; tools were previously omitted and could bypass soft compact).
118
138
  */
119
139
  export function estimateRequestTokens(input) {
140
+ const textEst = input.density === "soft-budget" ? estimateTextForSoftBudget : estimateTokens;
120
141
  let n = estimateMessagesTokens(input.messages, {
121
142
  ...(input.inputModalities !== undefined
122
143
  ? { inputModalities: input.inputModalities }
123
144
  : {}),
145
+ textEst,
124
146
  });
125
147
  // Non-assemble callers may pass system only on the side; avoid double-count
126
148
  // when the same text is already any system message (leading or in-history
@@ -128,11 +150,11 @@ export function estimateRequestTokens(input) {
128
150
  if (input.system?.trim()) {
129
151
  const alreadyCounted = input.messages.some((m) => m.role === "system" && messagePlainText(m) === input.system);
130
152
  if (!alreadyCounted) {
131
- n += estimateTokens(input.system);
153
+ n += textEst(input.system);
132
154
  }
133
155
  }
134
156
  if (input.tools?.length) {
135
- n += estimateTokens(JSON.stringify(input.tools));
157
+ n += textEst(JSON.stringify(input.tools));
136
158
  }
137
159
  return n;
138
160
  }
@@ -148,9 +170,35 @@ export function resolveSoftBudgetCeiling(maxRequestTokens, bufferTokens) {
148
170
  buffer = 0;
149
171
  return max - buffer;
150
172
  }
173
+ /**
174
+ * Soft-budget pre-trigger tokens (Face `softBudgetTriggerPercent` as a ratio).
175
+ *
176
+ * When the effective soft max already equals Codex `floor(window × 0.9)`
177
+ * (blank soft derived from the window, or ring-forced clamp to that line),
178
+ * do **not** multiply by `triggerRatio` again — that would compact near
179
+ * ~81% of the window while Codex's limit *is* the 90% line.
180
+ */
181
+ export function resolveSoftBudgetTriggerTokens(input) {
182
+ const max = Math.max(0, Math.floor(input.maxRequestTokens));
183
+ const atWindowForce = input.windowForceTokens !== undefined &&
184
+ max === input.windowForceTokens;
185
+ const ratio = atWindowForce
186
+ ? 1
187
+ : Number.isFinite(input.triggerRatio) &&
188
+ input.triggerRatio > 0 &&
189
+ input.triggerRatio <= 1
190
+ ? input.triggerRatio
191
+ : SOFT_BUDGET_COMPACT_TRIGGER_RATIO;
192
+ return Math.max(1, Math.floor(max * ratio));
193
+ }
151
194
  /**
152
195
  * Derive keep/buffer defaults from a soft-budget max (old Face 24k/4k @ 100k).
153
196
  * Explicit keep/buffer win when provided and valid.
197
+ *
198
+ * When catalog/SDK soft max is omitted, Codex posture: derive
199
+ * `floor(contextWindow × 0.9)` so blank never means “no proactive compact”.
200
+ * With a provider ring, callers should also `min` with
201
+ * {@link deriveAutoCompactMaxTokens} so a too-large soft cannot outrun the window.
154
202
  */
155
203
  export function resolveSoftBudgetTokens(input) {
156
204
  // SDK / tests may pass a small maxRequestTokens; catalog softBudget* stays ≥8k.
@@ -166,7 +214,9 @@ export function resolveSoftBudgetTokens(input) {
166
214
  maxRaw = catalogMax;
167
215
  }
168
216
  else {
169
- return undefined;
217
+ maxRaw = deriveAutoCompactMaxTokens(input.contextWindow);
218
+ if (maxRaw === undefined)
219
+ return undefined;
170
220
  }
171
221
  const maxRequestTokens = Math.floor(maxRaw);
172
222
  // SDK keep/buffer (CompactionOptions) accept any non-negative; catalog soft*
@@ -206,26 +256,26 @@ export function resolveSoftBudgetTokens(input) {
206
256
  }
207
257
  return { maxRequestTokens, keepTokens, bufferTokens };
208
258
  }
209
- export const COMPACTION_SUMMARY_TEMPLATE = `Output exactly this Markdown structure (keep section order). Do not mention that context was compacted.
210
-
211
- ## Objective
212
- - [what the user is trying to accomplish, or "(none)"]
213
-
214
- ## Decisions
215
- - [constraints, choices and why, or "(none)"]
216
-
217
- ## State
218
- ### Done
219
- - [finished work / verified facts, or "(none)"]
220
- ### Active
221
- - [current work / partial state, or "(none)"]
222
- ### Blocked
223
- - [blockers / unknowns, or "(none)"]
224
-
225
- ## Next
226
- 1. [immediate next action, or "(none)"]
227
-
228
- ## Files
259
+ export const COMPACTION_SUMMARY_TEMPLATE = `Output exactly this Markdown structure (keep section order). Do not mention that context was compacted.
260
+
261
+ ## Objective
262
+ - [what the user is trying to accomplish, or "(none)"]
263
+
264
+ ## Decisions
265
+ - [constraints, choices and why, or "(none)"]
266
+
267
+ ## State
268
+ ### Done
269
+ - [finished work / verified facts, or "(none)"]
270
+ ### Active
271
+ - [current work / partial state, or "(none)"]
272
+ ### Blocked
273
+ - [blockers / unknowns, or "(none)"]
274
+
275
+ ## Next
276
+ 1. [immediate next action, or "(none)"]
277
+
278
+ ## Files
229
279
  - [path: why it matters, or "(none)"]`;
230
280
  function serializeUserContent(content) {
231
281
  const text = flattenText(content);
@@ -360,19 +410,26 @@ export function deriveMessagesUnwindowed(events, options) {
360
410
  }
361
411
  function foldChat(events, markSource, indexOffset) {
362
412
  const offloadMarks = foldImageOffloadMarks(markSource);
363
- const messages = [];
413
+ const rows = [];
364
414
  for (let i = 0; i < events.length; i++) {
365
415
  const ev = events[i];
366
416
  const absSeq = i + indexOffset;
367
417
  switch (ev.type) {
368
- case "user/message":
369
- messages.push({
370
- role: "user",
371
- content: projectOffloadedImages(ev.content, offloadMarks.get(absSeq)),
418
+ case "user/message": {
419
+ const fragmentId = ev.source?.kind === "context-fragment"
420
+ ? ev.source.fragmentId
421
+ : undefined;
422
+ rows.push({
423
+ message: {
424
+ role: "user",
425
+ content: projectOffloadedImages(ev.content, offloadMarks.get(absSeq)),
426
+ },
427
+ ...(fragmentId !== undefined ? { fragmentId } : {}),
372
428
  });
373
429
  break;
430
+ }
374
431
  case "safety/notice":
375
- messages.push({ role: "user", content: ev.content });
432
+ rows.push({ message: { role: "user", content: ev.content } });
376
433
  break;
377
434
  case "assistant/message": {
378
435
  // DSH deriveEventMessage: skip usage-only / content-less assistants
@@ -382,13 +439,15 @@ function foldChat(events, markSource, indexOffset) {
382
439
  const hasText = Boolean(ev.content.trim());
383
440
  if (!hasTools && !hasReasoning && !hasText)
384
441
  break;
385
- messages.push({
386
- role: "assistant",
387
- content: ev.content,
388
- ...(ev.toolCalls ? { toolCalls: ev.toolCalls } : {}),
389
- // DSH serializeAssistant (dsh-v0.1.0-rc.8): every reasoning-carrying
390
- // turn keeps CoT for gateway re-encode; omit only when empty.
391
- ...(ev.reasoning?.trim() ? { reasoning: ev.reasoning } : {}),
442
+ rows.push({
443
+ message: {
444
+ role: "assistant",
445
+ content: ev.content,
446
+ ...(ev.toolCalls ? { toolCalls: ev.toolCalls } : {}),
447
+ // DSH serializeAssistant (dsh-v0.1.0-rc.8): every reasoning-carrying
448
+ // turn keeps CoT for gateway re-encode; omit only when empty.
449
+ ...(ev.reasoning?.trim() ? { reasoning: ev.reasoning } : {}),
450
+ },
392
451
  });
393
452
  break;
394
453
  }
@@ -401,12 +460,13 @@ function foldChat(events, markSource, indexOffset) {
401
460
  ...(ev.result.isError ? { isError: true } : {}),
402
461
  };
403
462
  // Latest surface wins (prune appends a replacement with the same callId).
404
- const existing = messages.findIndex((m) => m.role === "tool" && m.toolCallId === ev.result.toolCallId);
463
+ const existing = rows.findIndex((r) => r.message.role === "tool" &&
464
+ r.message.toolCallId === ev.result.toolCallId);
405
465
  if (existing >= 0) {
406
- messages[existing] = msg;
466
+ rows[existing] = { message: msg };
407
467
  }
408
468
  else {
409
- messages.push(msg);
469
+ rows.push({ message: msg });
410
470
  }
411
471
  break;
412
472
  }
@@ -414,7 +474,22 @@ function foldChat(events, markSource, indexOffset) {
414
474
  break;
415
475
  }
416
476
  }
417
- return messages;
477
+ // Context fragments re-append every turn with a stable fragmentId. Keep the
478
+ // latest body at its chronological slot; drop earlier same-id snapshots so
479
+ // hot updates (permission / tool routing / seat) do not stack stale prose.
480
+ const seenFragmentIds = new Set();
481
+ const kept = [];
482
+ for (let i = rows.length - 1; i >= 0; i--) {
483
+ const row = rows[i];
484
+ if (row.fragmentId !== undefined) {
485
+ if (seenFragmentIds.has(row.fragmentId))
486
+ continue;
487
+ seenFragmentIds.add(row.fragmentId);
488
+ }
489
+ kept.push(row.message);
490
+ }
491
+ kept.reverse();
492
+ return kept;
418
493
  }
419
494
  export const COMPACTION_STRATEGIES = [
420
495
  "prune-summary",
@@ -1 +1 @@
1
- {"version":3,"file":"compaction.js","sourceRoot":"","sources":["../src/compaction.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,qBAAqB,EAAsB,MAAM,uBAAuB,CAAC;AAClF,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACrD,OAAO,EACL,qBAAqB,EACrB,qBAAqB,EACrB,sBAAsB,GACvB,MAAM,oBAAoB,CAAC;AAE5B;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG,MAAM,CAAC;AACrD,MAAM,CAAC,MAAM,gCAAgC,GAAG,KAAK,CAAC;AAEtD;;;;;GAKG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG,MAAM,CAAC;AACrD,uFAAuF;AACvF,MAAM,CAAC,MAAM,oCAAoC,GAAG,CAAC,CAAC;AACtD;;;GAGG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG,MAAM,CAAC;AAChD;;;GAGG;AACH,MAAM,CAAC,MAAM,iCAAiC,GAAG,CAAC,CAAC;AACnD;;;GAGG;AACH,MAAM,CAAC,MAAM,iCAAiC,GAAG,GAAG,CAAC;AAErD;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,IAAY;IACzC,OAAO,YAAY,CAAC,IAAI,CAAC,CAAC;AAC5B,CAAC;AAED,SAAS,gBAAgB,CAAC,CAAc;IACtC,IAAI,CAAC,CAAC,IAA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AAE,MAAM,IAAI,EAAE,EAAE,CAAC;AACpD,CAAC"}
@@ -1,3 +1,9 @@
1
+ import { type SessionEvent } from "@xrkseek/protocol";
1
2
  export declare function deepFreeze<T>(value: T): T;
2
3
  export declare function newSessionId(): string;
4
+ /**
5
+ * Validate, detach lossless JSON, and freeze one session event for the log.
6
+ * Fail at append/seed — never wait for flush to discover Map/Date/BigInt.
7
+ */
8
+ export declare function freezeSessionEvent(event: SessionEvent): SessionEvent;
3
9
  //# sourceMappingURL=freeze.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"freeze.d.ts","sourceRoot":"","sources":["../src/freeze.ts"],"names":[],"mappings":"AAAA,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,CASzC;AAED,wBAAgB,YAAY,IAAI,MAAM,CAErC"}
1
+ {"version":3,"file":"freeze.d.ts","sourceRoot":"","sources":["../src/freeze.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,YAAY,EAClB,MAAM,mBAAmB,CAAC;AAE3B,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,CASzC;AAED,wBAAgB,YAAY,IAAI,MAAM,CAErC;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,YAAY,GAAG,YAAY,CAGpE"}
@@ -1,3 +1,4 @@
1
+ import { assertLosslessJson, assertSessionEvent, } from "@xrkseek/protocol";
1
2
  export function deepFreeze(value) {
2
3
  if (value === null || typeof value !== "object")
3
4
  return value;
@@ -12,4 +13,12 @@ export function deepFreeze(value) {
12
13
  export function newSessionId() {
13
14
  return `sess_${Date.now().toString(36)}_${Math.random().toString(36).slice(2, 8)}`;
14
15
  }
16
+ /**
17
+ * Validate, detach lossless JSON, and freeze one session event for the log.
18
+ * Fail at append/seed — never wait for flush to discover Map/Date/BigInt.
19
+ */
20
+ export function freezeSessionEvent(event) {
21
+ const parsed = assertSessionEvent(event);
22
+ return deepFreeze(assertLosslessJson(parsed, "session event"));
23
+ }
15
24
  //# sourceMappingURL=freeze.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"freeze.js","sourceRoot":"","sources":["../src/freeze.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,UAAU,CAAI,KAAQ;IACpC,IAAI,KAAK,KAAK,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,KAAK,CAAC;IAC9D,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACrB,KAAK,MAAM,CAAC,IAAI,MAAM,CAAC,MAAM,CAAC,KAAgC,CAAC,EAAE,CAAC;QAChE,IAAI,CAAC,IAAI,OAAO,CAAC,KAAK,QAAQ,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC;YACtD,UAAU,CAAC,CAAC,CAAC,CAAC;QAChB,CAAC;IACH,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AAED,MAAM,UAAU,YAAY;IAC1B,OAAO,QAAQ,IAAI,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC;AACrF,CAAC"}
1
+ {"version":3,"file":"freeze.js","sourceRoot":"","sources":["../src/freeze.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,kBAAkB,GAEnB,MAAM,mBAAmB,CAAC;AAE3B,MAAM,UAAU,UAAU,CAAI,KAAQ;IACpC,IAAI,KAAK,KAAK,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,KAAK,CAAC;IAC9D,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACrB,KAAK,MAAM,CAAC,IAAI,MAAM,CAAC,MAAM,CAAC,KAAgC,CAAC,EAAE,CAAC;QAChE,IAAI,CAAC,IAAI,OAAO,CAAC,KAAK,QAAQ,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC;YACtD,UAAU,CAAC,CAAC,CAAC,CAAC;QAChB,CAAC;IACH,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AAED,MAAM,UAAU,YAAY;IAC1B,OAAO,QAAQ,IAAI,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC;AACrF,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAAC,KAAmB;IACpD,MAAM,MAAM,GAAG,kBAAkB,CAAC,KAAK,CAAC,CAAC;IACzC,OAAO,UAAU,CAAC,kBAAkB,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC,CAAC;AACjE,CAAC"}
@@ -3,9 +3,9 @@ export { SessionBusyError, createTurnLatch, createSessionDrainLatch, type TurnLa
3
3
  export { createSessionDrainHub, type SessionDrainHub } from "./drain-hub.js";
4
4
  export { NoPendingAdmitError, AdmitNotPendingError, admitPrompt, withdrawAdmit, listPendingAdmits, listSessionsWithPendingAdmits, newSession, promoteNextAdmit, promoteAdmitsForTurn, promotePendingSteers, type AdmitReceipt, type AdmitPromptOptions, type PromoteForTurnResult, } from "./admit.js";
5
5
  export { SessionSafetyLimitError, checkRepeatedToolCall, createLoopDetectionTracker, createMistakeTracker, createSessionSafety, DEFAULT_LOOP_CONFIG, DEFAULT_MAX_CONSECUTIVE_MISTAKES, emptyLoopState, hardLoopNotice, mistakeLimitNotice, softLoopNotice, toolCallSignature, type LoopDetectionConfig, type LoopDetectionTracker, type LoopVerdict, type MistakeReason, type MistakeTracker, type SessionSafety, type SessionSafetyOptions, } from "./safety/index.js";
6
- export { COMPACTION_SUMMARY_TEMPLATE, COMPACT_RECENT_MAX_TOKENS, DEFAULT_COMPACTION_BUFFER_TOKENS, DEFAULT_COMPACTION_HEAD_TOKENS, DEFAULT_COMPACTION_KEEP_TOKENS, DEFAULT_SOFT_BUDGET_COMPACT_ATTEMPTS, DEFAULT_SOFT_BUDGET_PEEL_ATTEMPTS, SOFT_BUDGET_COMPACT_TRIGGER_RATIO, buildCompactionPrompt, deriveMessagesUnwindowed, estimateMessagesTokens, estimateRequestTokens, estimateTokens, findLatestCompaction, formatCompactionForModel, prepareCompactionPayload, resolveSoftBudgetCeiling, resolveSoftBudgetTokens, parseCompactionStrategy, resolveCompactionStrategy, COMPACTION_STRATEGIES, selectHeadRecent, type CompactionOptions, type CompactionStrategy, type ResolvedSoftBudget, } from "./compaction.js";
6
+ export { COMPACTION_SUMMARY_TEMPLATE, AUTO_COMPACT_MIN_CONTEXT_WINDOW, AUTO_COMPACT_WINDOW_RATIO, COMPACT_RECENT_MAX_TOKENS, DEFAULT_COMPACTION_BUFFER_TOKENS, DEFAULT_COMPACTION_HEAD_TOKENS, DEFAULT_COMPACTION_KEEP_TOKENS, DEFAULT_SOFT_BUDGET_COMPACT_ATTEMPTS, DEFAULT_SOFT_BUDGET_PEEL_ATTEMPTS, SOFT_BUDGET_COMPACT_TRIGGER_RATIO, buildCompactionPrompt, deriveAutoCompactMaxTokens, deriveMessagesUnwindowed, estimateMessagesTokens, estimateRequestTokens, estimateTokens, findLatestCompaction, formatCompactionForModel, prepareCompactionPayload, resolveSoftBudgetCeiling, resolveSoftBudgetTriggerTokens, resolveSoftBudgetTokens, parseCompactionStrategy, resolveCompactionStrategy, COMPACTION_STRATEGIES, selectHeadRecent, type CompactionOptions, type CompactionStrategy, type ResolvedSoftBudget, } from "./compaction.js";
7
7
  export { DEFAULT_MAX_REQUEST_IMAGE_BYTES, describeShadowedImages, ensureDurableImageOffloads, foldImageOffloadMarks, messageHasImageBlocks, MAX_DESCRIBED_SHADOWED_IMAGES, planImageOffloadTargets, projectOffloadedImages, } from "./image-offload.js";
8
- export { estimateAssistantSurface, estimateMessageContent, estimateSystemTokens, estimateToolsTokens, priceRouteImageTokens, type InputModality, } from "./surface-estimate.js";
8
+ export { estimateAssistantSurface, estimateMessageContent, estimateSystemTokens, estimateText, estimateTextForSoftBudget, estimateToolsTokens, priceRouteImageTokens, type InputModality, } from "./surface-estimate.js";
9
9
  export { foldSurfaceTokens, priceCurrentSurfaceWindow, projectedInputPressureTokens, } from "./surface-fold.js";
10
10
  export { TOOL_NOT_STARTED, TOOL_NOT_STARTED_MESSAGE, TOOL_OUTCOME_UNKNOWN, TOOL_OUTCOME_UNKNOWN_MESSAGE, TOOL_ABORTED_BEFORE_DISPATCH, TOOL_ABORTED_BEFORE_DISPATCH_MESSAGE, TOOL_ABORTED, TOOL_ABORTED_MESSAGE, ToolSettlementError, ToolAdjacencyError, assertToolCallsSettled, assertAssistantToolCallAdjacency, abortedBeforeDispatchSettlement, danglingSettlement, listDanglingToolCalls, settleDanglingTools, type DanglingToolCall, type SettleDanglingOptions, type SettleDanglingResult, } from "./dangling.js";
11
11
  export { TOOL_RESULT_PRUNE_HEAD_CHARS, TOOL_RESULT_PRUNE_META_PREV_TOKENS, TOOL_RESULT_PRUNE_TAIL_CHARS, TOOL_RESULT_PRUNE_THRESHOLD_CHARS, pruneOversizedToolResults, pruneToolResultText, type ToolResultPruneOptions, type ToolResultPruneResult, } from "./tool-result-prune.js";
@@ -53,11 +53,27 @@ export declare function durableModelHistory(messages: readonly ChatMessage[]): C
53
53
  export declare function assertModelVisible(events: readonly SessionEvent[], requestMessages: readonly ChatMessage[]): void;
54
54
  export { fromJSONL, parseJSONL, toJSONL, type ParseJSONLResult } from "./jsonl.js";
55
55
  export { exportSessionInterchange, importSessionInterchange, readSessionInterchange, SESSION_INTERCHANGE_VERSION, type InterchangeMessage, } from "./session-interchange.js";
56
- export { createPersistentSessionStore, ftsMatchQuery, isLikelyRemoteSessionsPath, resolveSqliteJournalMode, SESSION_ARCHIVE_DB_FILENAME, SESSION_DB_FILENAME, SESSION_SCHEMA_VERSION, SessionsDirInUseError, SESSIONS_WRITE_LOCK_FILENAME, type PersistentSessionStore, type PersistentSessionStoreOptions, type SqliteJournalMode, } from "./sqlite-store.js";
56
+ export { createPersistentSessionStore, ftsMatchQuery, planFtsQuery, SessionLogUnreadableError, isLikelyRemoteSessionsPath, type FtsQueryPlan, resolveSqliteJournalMode, SESSION_ARCHIVE_DB_FILENAME, SESSION_DB_FILENAME, SESSION_SCHEMA_VERSION, SessionsDirInUseError, SESSIONS_WRITE_LOCK_FILENAME, type PersistentSessionStore, type PersistentSessionStoreOptions, type SqliteJournalMode, } from "./sqlite-store.js";
57
57
  export { expandPackedStorageRecords, fromPackedJSONL, fromPackedJSONLZstd, isPackedChunkRow, isTextChunkRow, isToolCallChunkRow, packChunkRunsForExport, parsePackedJSONL, toPackedJSONL, zstdCompressUtf8, zstdDecompressUtf8, type PackedStorageRecord, type ParsePackedJSONLResult, type TextChunkRow, type ToolCallChunkRow, } from "./chunk-pack.js";
58
- export { listOpenTurnIds, repairOpenTurnEvents, sessionHasOpenTurn, } from "./repair-open-turn.js";
58
+ import { closeOpenTurns, FORKED_TURN_END, listOpenTurnIds, repairOpenTurnEvents, sessionHasOpenTurn } from "./repair-open-turn.js";
59
+ export { closeOpenTurns, FORKED_TURN_END, listOpenTurnIds, repairOpenTurnEvents, sessionHasOpenTurn, };
59
60
  export { extractEventSearchText, extractSessionSearchTexts } from "./search-text.js";
60
61
  export { writeTextFileAtomicSync } from "./atomic-write.js";
62
+ /**
63
+ * Durability checkpoint for one session (or every session when `sessionId`
64
+ * is omitted). No-op on stores without {@link SessionStore.flush}.
65
+ */
66
+ export declare function flushSession(store: SessionStore, sessionId?: string): void;
67
+ /**
68
+ * Release a cold-observed session from the resident LRU when it has no open
69
+ * turn. No-op / false on memory stores or pinned open turns.
70
+ */
71
+ export declare function releaseSessionResident(store: SessionStore, sessionId: string): boolean;
72
+ /**
73
+ * Build a fork child seed: parent prefix + forked closers for any open turn +
74
+ * durable `session/end-seed` inheritance marker (DSH).
75
+ */
76
+ export declare function buildForkSeed(prefix: readonly SessionEvent[], now?: () => number): SessionEvent[];
61
77
  export declare function forkSession(store: SessionStore, sourceId: string, boundaryIndex?: number, childId?: string): SessionRecord;
62
78
  /**
63
79
  * Cursor-style in-place truncate: keep `[0, boundaryIndex)` on the same
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAGnE,OAAO,EACL,gBAAgB,EAChB,eAAe,EACf,uBAAuB,EACvB,KAAK,SAAS,EACd,KAAK,iBAAiB,EACtB,KAAK,yBAAyB,EAC9B,KAAK,OAAO,GACb,MAAM,YAAY,CAAC;AAEpB,OAAO,EAAE,qBAAqB,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAE7E,OAAO,EACL,mBAAmB,EACnB,oBAAoB,EACpB,WAAW,EACX,aAAa,EACb,iBAAiB,EACjB,6BAA6B,EAC7B,UAAU,EACV,gBAAgB,EAChB,oBAAoB,EACpB,oBAAoB,EACpB,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,GAC1B,MAAM,YAAY,CAAC;AAEpB,OAAO,EACL,uBAAuB,EACvB,qBAAqB,EACrB,0BAA0B,EAC1B,oBAAoB,EACpB,mBAAmB,EACnB,mBAAmB,EACnB,gCAAgC,EAChC,cAAc,EACd,cAAc,EACd,kBAAkB,EAClB,cAAc,EACd,iBAAiB,EACjB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,KAAK,WAAW,EAChB,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,oBAAoB,GAC1B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACL,2BAA2B,EAC3B,yBAAyB,EACzB,gCAAgC,EAChC,8BAA8B,EAC9B,8BAA8B,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