@fbincon/claude-code-statusline 0.0.0-stage → 3.0.0

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 (648) hide show
  1. package/LICENSE +21 -0
  2. package/LICENSE-Unicode.txt +39 -0
  3. package/LICENSE-Wcwidth.txt +27 -0
  4. package/README.md +420 -2
  5. package/bin/claude-statusline.js +2 -0
  6. package/candidate.json +1244 -0
  7. package/node_modules/@fbincon/statusline-cli/dist/src/config/arguments.d.ts +35 -0
  8. package/node_modules/@fbincon/statusline-cli/dist/src/config/arguments.js +228 -0
  9. package/node_modules/@fbincon/statusline-cli/dist/src/config/arguments.js.map +1 -0
  10. package/node_modules/@fbincon/statusline-cli/dist/src/config/backend-preferences.d.ts +6 -0
  11. package/node_modules/@fbincon/statusline-cli/dist/src/config/backend-preferences.js +72 -0
  12. package/node_modules/@fbincon/statusline-cli/dist/src/config/backend-preferences.js.map +1 -0
  13. package/node_modules/@fbincon/statusline-cli/dist/src/config/commands.d.ts +10 -0
  14. package/node_modules/@fbincon/statusline-cli/dist/src/config/commands.js +140 -0
  15. package/node_modules/@fbincon/statusline-cli/dist/src/config/commands.js.map +1 -0
  16. package/node_modules/@fbincon/statusline-cli/dist/src/config/host.d.ts +10 -0
  17. package/node_modules/@fbincon/statusline-cli/dist/src/config/host.js +101 -0
  18. package/node_modules/@fbincon/statusline-cli/dist/src/config/host.js.map +1 -0
  19. package/node_modules/@fbincon/statusline-cli/dist/src/config/operations.d.ts +10 -0
  20. package/node_modules/@fbincon/statusline-cli/dist/src/config/operations.js +96 -0
  21. package/node_modules/@fbincon/statusline-cli/dist/src/config/operations.js.map +1 -0
  22. package/node_modules/@fbincon/statusline-cli/dist/src/config/preferences.d.ts +11 -0
  23. package/node_modules/@fbincon/statusline-cli/dist/src/config/preferences.js +80 -0
  24. package/node_modules/@fbincon/statusline-cli/dist/src/config/preferences.js.map +1 -0
  25. package/node_modules/@fbincon/statusline-cli/dist/src/config/service.d.ts +45 -0
  26. package/node_modules/@fbincon/statusline-cli/dist/src/config/service.js +99 -0
  27. package/node_modules/@fbincon/statusline-cli/dist/src/config/service.js.map +1 -0
  28. package/node_modules/@fbincon/statusline-cli/dist/src/config/storage.d.ts +30 -0
  29. package/node_modules/@fbincon/statusline-cli/dist/src/config/storage.js +134 -0
  30. package/node_modules/@fbincon/statusline-cli/dist/src/config/storage.js.map +1 -0
  31. package/node_modules/@fbincon/statusline-cli/dist/src/config/transfer.d.ts +3 -0
  32. package/node_modules/@fbincon/statusline-cli/dist/src/config/transfer.js +89 -0
  33. package/node_modules/@fbincon/statusline-cli/dist/src/config/transfer.js.map +1 -0
  34. package/node_modules/@fbincon/statusline-cli/dist/src/context.d.ts +11 -0
  35. package/node_modules/@fbincon/statusline-cli/dist/src/context.js +2 -0
  36. package/node_modules/@fbincon/statusline-cli/dist/src/context.js.map +1 -0
  37. package/node_modules/@fbincon/statusline-cli/dist/src/entry.d.ts +1 -0
  38. package/node_modules/@fbincon/statusline-cli/dist/src/entry.js +3 -0
  39. package/node_modules/@fbincon/statusline-cli/dist/src/entry.js.map +1 -0
  40. package/node_modules/@fbincon/statusline-cli/dist/src/errors.d.ts +4 -0
  41. package/node_modules/@fbincon/statusline-cli/dist/src/errors.js +8 -0
  42. package/node_modules/@fbincon/statusline-cli/dist/src/errors.js.map +1 -0
  43. package/node_modules/@fbincon/statusline-cli/dist/src/help.d.ts +3 -0
  44. package/node_modules/@fbincon/statusline-cli/dist/src/help.js +67 -0
  45. package/node_modules/@fbincon/statusline-cli/dist/src/help.js.map +1 -0
  46. package/node_modules/@fbincon/statusline-cli/dist/src/integration/arguments.d.ts +10 -0
  47. package/node_modules/@fbincon/statusline-cli/dist/src/integration/arguments.js +40 -0
  48. package/node_modules/@fbincon/statusline-cli/dist/src/integration/arguments.js.map +1 -0
  49. package/node_modules/@fbincon/statusline-cli/dist/src/integration/configure.d.ts +3 -0
  50. package/node_modules/@fbincon/statusline-cli/dist/src/integration/configure.js +63 -0
  51. package/node_modules/@fbincon/statusline-cli/dist/src/integration/configure.js.map +1 -0
  52. package/node_modules/@fbincon/statusline-cli/dist/src/integration/doctor.d.ts +4 -0
  53. package/node_modules/@fbincon/statusline-cli/dist/src/integration/doctor.js +153 -0
  54. package/node_modules/@fbincon/statusline-cli/dist/src/integration/doctor.js.map +1 -0
  55. package/node_modules/@fbincon/statusline-cli/dist/src/integration/editor.d.ts +14 -0
  56. package/node_modules/@fbincon/statusline-cli/dist/src/integration/editor.js +3 -0
  57. package/node_modules/@fbincon/statusline-cli/dist/src/integration/editor.js.map +1 -0
  58. package/node_modules/@fbincon/statusline-cli/dist/src/integration/install.d.ts +6 -0
  59. package/node_modules/@fbincon/statusline-cli/dist/src/integration/install.js +142 -0
  60. package/node_modules/@fbincon/statusline-cli/dist/src/integration/install.js.map +1 -0
  61. package/node_modules/@fbincon/statusline-cli/dist/src/integration/launcher.d.ts +15 -0
  62. package/node_modules/@fbincon/statusline-cli/dist/src/integration/launcher.js +91 -0
  63. package/node_modules/@fbincon/statusline-cli/dist/src/integration/launcher.js.map +1 -0
  64. package/node_modules/@fbincon/statusline-cli/dist/src/integration/mod-ownership.d.ts +20 -0
  65. package/node_modules/@fbincon/statusline-cli/dist/src/integration/mod-ownership.js +109 -0
  66. package/node_modules/@fbincon/statusline-cli/dist/src/integration/mod-ownership.js.map +1 -0
  67. package/node_modules/@fbincon/statusline-cli/dist/src/integration/model.d.ts +60 -0
  68. package/node_modules/@fbincon/statusline-cli/dist/src/integration/model.js +12 -0
  69. package/node_modules/@fbincon/statusline-cli/dist/src/integration/model.js.map +1 -0
  70. package/node_modules/@fbincon/statusline-cli/dist/src/integration/mods.d.ts +10 -0
  71. package/node_modules/@fbincon/statusline-cli/dist/src/integration/mods.js +234 -0
  72. package/node_modules/@fbincon/statusline-cli/dist/src/integration/mods.js.map +1 -0
  73. package/node_modules/@fbincon/statusline-cli/dist/src/integration/ownership.d.ts +8 -0
  74. package/node_modules/@fbincon/statusline-cli/dist/src/integration/ownership.js +41 -0
  75. package/node_modules/@fbincon/statusline-cli/dist/src/integration/ownership.js.map +1 -0
  76. package/node_modules/@fbincon/statusline-cli/dist/src/integration/paths.d.ts +1 -0
  77. package/node_modules/@fbincon/statusline-cli/dist/src/integration/paths.js +14 -0
  78. package/node_modules/@fbincon/statusline-cli/dist/src/integration/paths.js.map +1 -0
  79. package/node_modules/@fbincon/statusline-cli/dist/src/integration/plan.d.ts +13 -0
  80. package/node_modules/@fbincon/statusline-cli/dist/src/integration/plan.js +92 -0
  81. package/node_modules/@fbincon/statusline-cli/dist/src/integration/plan.js.map +1 -0
  82. package/node_modules/@fbincon/statusline-cli/dist/src/integration/resources.d.ts +19 -0
  83. package/node_modules/@fbincon/statusline-cli/dist/src/integration/resources.js +91 -0
  84. package/node_modules/@fbincon/statusline-cli/dist/src/integration/resources.js.map +1 -0
  85. package/node_modules/@fbincon/statusline-cli/dist/src/integration/slash-hook.d.ts +6 -0
  86. package/node_modules/@fbincon/statusline-cli/dist/src/integration/slash-hook.js +94 -0
  87. package/node_modules/@fbincon/statusline-cli/dist/src/integration/slash-hook.js.map +1 -0
  88. package/node_modules/@fbincon/statusline-cli/dist/src/integration/transaction.d.ts +8 -0
  89. package/node_modules/@fbincon/statusline-cli/dist/src/integration/transaction.js +3 -0
  90. package/node_modules/@fbincon/statusline-cli/dist/src/integration/transaction.js.map +1 -0
  91. package/node_modules/@fbincon/statusline-cli/dist/src/main.d.ts +22 -0
  92. package/node_modules/@fbincon/statusline-cli/dist/src/main.js +197 -0
  93. package/node_modules/@fbincon/statusline-cli/dist/src/main.js.map +1 -0
  94. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/files.d.ts +7 -0
  95. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/files.js +134 -0
  96. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/files.js.map +1 -0
  97. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/journal.d.ts +58 -0
  98. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/journal.js +144 -0
  99. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/journal.js.map +1 -0
  100. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/official.d.ts +5 -0
  101. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/official.js +125 -0
  102. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/official.js.map +1 -0
  103. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/service.d.ts +11 -0
  104. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/service.js +55 -0
  105. package/node_modules/@fbincon/statusline-cli/dist/src/recovery/service.js.map +1 -0
  106. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/environment.d.ts +15 -0
  107. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/environment.js +95 -0
  108. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/environment.js.map +1 -0
  109. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/main.d.ts +6 -0
  110. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/main.js +48 -0
  111. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/main.js.map +1 -0
  112. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/preview.d.ts +2 -0
  113. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/preview.js +13 -0
  114. package/node_modules/@fbincon/statusline-cli/dist/src/rendering/preview.js.map +1 -0
  115. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/context.d.ts +11 -0
  116. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/context.js +11 -0
  117. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/context.js.map +1 -0
  118. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/git.d.ts +19 -0
  119. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/git.js +162 -0
  120. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/git.js.map +1 -0
  121. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/hook.d.ts +3 -0
  122. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/hook.js +19 -0
  123. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/hook.js.map +1 -0
  124. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/io.d.ts +37 -0
  125. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/io.js +75 -0
  126. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/io.js.map +1 -0
  127. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/json-data.d.ts +9 -0
  128. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/json-data.js +241 -0
  129. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/json-data.js.map +1 -0
  130. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/collect.d.ts +2 -0
  131. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/collect.js +14 -0
  132. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/collect.js.map +1 -0
  133. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/durations.d.ts +15 -0
  134. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/durations.js +69 -0
  135. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/durations.js.map +1 -0
  136. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/protocol.d.ts +16 -0
  137. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/protocol.js +90 -0
  138. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/protocol.js.map +1 -0
  139. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/store.d.ts +25 -0
  140. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/store.js +80 -0
  141. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/live/store.js.map +1 -0
  142. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/registry.d.ts +4 -0
  143. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/registry.js +40 -0
  144. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/registry.js.map +1 -0
  145. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/collect.d.ts +5 -0
  146. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/collect.js +59 -0
  147. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/collect.js.map +1 -0
  148. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/service.d.ts +17 -0
  149. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/service.js +69 -0
  150. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/service.js.map +1 -0
  151. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/store.d.ts +17 -0
  152. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/store.js +70 -0
  153. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/store.js.map +1 -0
  154. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/submissions.d.ts +13 -0
  155. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/submissions.js +75 -0
  156. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/tasks/submissions.js.map +1 -0
  157. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/usage.d.ts +33 -0
  158. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/usage.js +227 -0
  159. package/node_modules/@fbincon/statusline-cli/dist/src/runtime/usage.js.map +1 -0
  160. package/node_modules/@fbincon/statusline-cli/dist/src/ui/protocol.d.ts +20 -0
  161. package/node_modules/@fbincon/statusline-cli/dist/src/ui/protocol.js +144 -0
  162. package/node_modules/@fbincon/statusline-cli/dist/src/ui/protocol.js.map +1 -0
  163. package/node_modules/@fbincon/statusline-cli/package.json +17 -0
  164. package/node_modules/@fbincon/statusline-cli/resources/statusline-config/SKILL.md +80 -0
  165. package/node_modules/@fbincon/statusline-cli/resources/statusline-configure/SKILL.md +19 -0
  166. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/.claude-plugin/plugin.json +37 -0
  167. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/hooks/hooks.json +6 -0
  168. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/hooks/register.ts +820 -0
  169. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/backend.ts +503 -0
  170. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/client/forms.ts +3 -0
  171. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/client/keys.ts +198 -0
  172. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/client/messages.ts +101 -0
  173. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/client/settings.ts +218 -0
  174. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/appearance.ts +29 -0
  175. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/draft.ts +254 -0
  176. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/forms.ts +167 -0
  177. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/guidance.ts +20 -0
  178. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/import-review.ts +55 -0
  179. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/instances.ts +30 -0
  180. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/navigation.ts +98 -0
  181. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/numeric.ts +42 -0
  182. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/editor/search.ts +114 -0
  183. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/generated-contracts.ts +276 -0
  184. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/generated-unicode.ts +92 -0
  185. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/i18n/generated-locales.ts +6842 -0
  186. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/i18n/index.ts +40 -0
  187. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/i18n/messages.ts +33 -0
  188. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/i18n/presentation.ts +62 -0
  189. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/launch.ts +25 -0
  190. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/preferences.ts +61 -0
  191. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/preview-preferences.ts +8 -0
  192. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/session.ts +124 -0
  193. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/lib/unicode.ts +121 -0
  194. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/resource-manifest.json +47 -0
  195. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/client/draw.ts +159 -0
  196. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/client/help.ts +84 -0
  197. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/client/surface.ts +89 -0
  198. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/components/catalog.ts +23 -0
  199. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/components/preview.ts +45 -0
  200. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/components/section.ts +49 -0
  201. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/components/shortcuts.ts +83 -0
  202. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/layout.ts +49 -0
  203. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/styled-text.ts +56 -0
  204. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/text.ts +23 -0
  205. package/node_modules/@fbincon/statusline-cli/resources/statusline-native/ui/theme.ts +27 -0
  206. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/.claude-plugin/plugin.json +49 -0
  207. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/hooks/hooks.json +1 -0
  208. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/hooks/observe.ts +279 -0
  209. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/checklists.ts +45 -0
  210. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/costs.ts +23 -0
  211. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/generated-contracts.ts +18 -0
  212. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/identity.ts +14 -0
  213. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/launch.ts +25 -0
  214. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/queue.ts +68 -0
  215. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/streams.ts +28 -0
  216. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/lib/timing.ts +11 -0
  217. package/node_modules/@fbincon/statusline-cli/resources/statusline-runtime/resource-manifest.json +19 -0
  218. package/node_modules/@fbincon/statusline-core/dist/src/config/backend-preferences.d.ts +14 -0
  219. package/node_modules/@fbincon/statusline-core/dist/src/config/backend-preferences.js +72 -0
  220. package/node_modules/@fbincon/statusline-core/dist/src/config/backend-preferences.js.map +1 -0
  221. package/node_modules/@fbincon/statusline-core/dist/src/config/catalog-data.d.ts +86 -0
  222. package/node_modules/@fbincon/statusline-core/dist/src/config/catalog-data.js +3462 -0
  223. package/node_modules/@fbincon/statusline-core/dist/src/config/catalog-data.js.map +1 -0
  224. package/node_modules/@fbincon/statusline-core/dist/src/config/catalog.d.ts +10 -0
  225. package/node_modules/@fbincon/statusline-core/dist/src/config/catalog.js +17 -0
  226. package/node_modules/@fbincon/statusline-core/dist/src/config/catalog.js.map +1 -0
  227. package/node_modules/@fbincon/statusline-core/dist/src/config/defaults.d.ts +5 -0
  228. package/node_modules/@fbincon/statusline-core/dist/src/config/defaults.js +19 -0
  229. package/node_modules/@fbincon/statusline-core/dist/src/config/defaults.js.map +1 -0
  230. package/node_modules/@fbincon/statusline-core/dist/src/config/display.d.ts +13 -0
  231. package/node_modules/@fbincon/statusline-core/dist/src/config/display.js +232 -0
  232. package/node_modules/@fbincon/statusline-core/dist/src/config/display.js.map +1 -0
  233. package/node_modules/@fbincon/statusline-core/dist/src/config/draft.d.ts +4 -0
  234. package/node_modules/@fbincon/statusline-core/dist/src/config/draft.js +48 -0
  235. package/node_modules/@fbincon/statusline-core/dist/src/config/draft.js.map +1 -0
  236. package/node_modules/@fbincon/statusline-core/dist/src/config/editor-fields.d.ts +8 -0
  237. package/node_modules/@fbincon/statusline-core/dist/src/config/editor-fields.js +104 -0
  238. package/node_modules/@fbincon/statusline-core/dist/src/config/editor-fields.js.map +1 -0
  239. package/node_modules/@fbincon/statusline-core/dist/src/config/formatting.d.ts +11 -0
  240. package/node_modules/@fbincon/statusline-core/dist/src/config/formatting.js +99 -0
  241. package/node_modules/@fbincon/statusline-core/dist/src/config/formatting.js.map +1 -0
  242. package/node_modules/@fbincon/statusline-core/dist/src/config/generated-constants.d.ts +36 -0
  243. package/node_modules/@fbincon/statusline-core/dist/src/config/generated-constants.js +5 -0
  244. package/node_modules/@fbincon/statusline-core/dist/src/config/generated-constants.js.map +1 -0
  245. package/node_modules/@fbincon/statusline-core/dist/src/config/import-review.d.ts +4 -0
  246. package/node_modules/@fbincon/statusline-core/dist/src/config/import-review.js +80 -0
  247. package/node_modules/@fbincon/statusline-core/dist/src/config/import-review.js.map +1 -0
  248. package/node_modules/@fbincon/statusline-core/dist/src/config/instances.d.ts +29 -0
  249. package/node_modules/@fbincon/statusline-core/dist/src/config/instances.js +159 -0
  250. package/node_modules/@fbincon/statusline-core/dist/src/config/instances.js.map +1 -0
  251. package/node_modules/@fbincon/statusline-core/dist/src/config/presets.d.ts +10 -0
  252. package/node_modules/@fbincon/statusline-core/dist/src/config/presets.js +34 -0
  253. package/node_modules/@fbincon/statusline-core/dist/src/config/presets.js.map +1 -0
  254. package/node_modules/@fbincon/statusline-core/dist/src/config/transfer.d.ts +6 -0
  255. package/node_modules/@fbincon/statusline-core/dist/src/config/transfer.js +23 -0
  256. package/node_modules/@fbincon/statusline-core/dist/src/config/transfer.js.map +1 -0
  257. package/node_modules/@fbincon/statusline-core/dist/src/config/validation.d.ts +15 -0
  258. package/node_modules/@fbincon/statusline-core/dist/src/config/validation.js +55 -0
  259. package/node_modules/@fbincon/statusline-core/dist/src/config/validation.js.map +1 -0
  260. package/node_modules/@fbincon/statusline-core/dist/src/contracts/generated-catalog.d.ts +33 -0
  261. package/node_modules/@fbincon/statusline-core/dist/src/contracts/generated-catalog.js +5 -0
  262. package/node_modules/@fbincon/statusline-core/dist/src/contracts/generated-catalog.js.map +1 -0
  263. package/node_modules/@fbincon/statusline-core/dist/src/contracts/runtime.d.ts +18 -0
  264. package/node_modules/@fbincon/statusline-core/dist/src/contracts/runtime.js +3 -0
  265. package/node_modules/@fbincon/statusline-core/dist/src/contracts/runtime.js.map +1 -0
  266. package/node_modules/@fbincon/statusline-core/dist/src/contracts/ui.d.ts +663 -0
  267. package/node_modules/@fbincon/statusline-core/dist/src/contracts/ui.js +23 -0
  268. package/node_modules/@fbincon/statusline-core/dist/src/contracts/ui.js.map +1 -0
  269. package/node_modules/@fbincon/statusline-core/dist/src/editor/appearance.d.ts +5 -0
  270. package/node_modules/@fbincon/statusline-core/dist/src/editor/appearance.js +27 -0
  271. package/node_modules/@fbincon/statusline-core/dist/src/editor/appearance.js.map +1 -0
  272. package/node_modules/@fbincon/statusline-core/dist/src/editor/backend.d.ts +18 -0
  273. package/node_modules/@fbincon/statusline-core/dist/src/editor/backend.js +401 -0
  274. package/node_modules/@fbincon/statusline-core/dist/src/editor/backend.js.map +1 -0
  275. package/node_modules/@fbincon/statusline-core/dist/src/editor/draft.d.ts +73 -0
  276. package/node_modules/@fbincon/statusline-core/dist/src/editor/draft.js +251 -0
  277. package/node_modules/@fbincon/statusline-core/dist/src/editor/draft.js.map +1 -0
  278. package/node_modules/@fbincon/statusline-core/dist/src/editor/forms.d.ts +26 -0
  279. package/node_modules/@fbincon/statusline-core/dist/src/editor/forms.js +146 -0
  280. package/node_modules/@fbincon/statusline-core/dist/src/editor/forms.js.map +1 -0
  281. package/node_modules/@fbincon/statusline-core/dist/src/editor/guidance.d.ts +3 -0
  282. package/node_modules/@fbincon/statusline-core/dist/src/editor/guidance.js +17 -0
  283. package/node_modules/@fbincon/statusline-core/dist/src/editor/guidance.js.map +1 -0
  284. package/node_modules/@fbincon/statusline-core/dist/src/editor/import-review.d.ts +19 -0
  285. package/node_modules/@fbincon/statusline-core/dist/src/editor/import-review.js +53 -0
  286. package/node_modules/@fbincon/statusline-core/dist/src/editor/import-review.js.map +1 -0
  287. package/node_modules/@fbincon/statusline-core/dist/src/editor/instances.d.ts +4 -0
  288. package/node_modules/@fbincon/statusline-core/dist/src/editor/instances.js +36 -0
  289. package/node_modules/@fbincon/statusline-core/dist/src/editor/instances.js.map +1 -0
  290. package/node_modules/@fbincon/statusline-core/dist/src/editor/navigation.d.ts +37 -0
  291. package/node_modules/@fbincon/statusline-core/dist/src/editor/navigation.js +73 -0
  292. package/node_modules/@fbincon/statusline-core/dist/src/editor/navigation.js.map +1 -0
  293. package/node_modules/@fbincon/statusline-core/dist/src/editor/numeric.d.ts +11 -0
  294. package/node_modules/@fbincon/statusline-core/dist/src/editor/numeric.js +27 -0
  295. package/node_modules/@fbincon/statusline-core/dist/src/editor/numeric.js.map +1 -0
  296. package/node_modules/@fbincon/statusline-core/dist/src/editor/search.d.ts +22 -0
  297. package/node_modules/@fbincon/statusline-core/dist/src/editor/search.js +122 -0
  298. package/node_modules/@fbincon/statusline-core/dist/src/editor/search.js.map +1 -0
  299. package/node_modules/@fbincon/statusline-core/dist/src/editor/text.d.ts +2 -0
  300. package/node_modules/@fbincon/statusline-core/dist/src/editor/text.js +30 -0
  301. package/node_modules/@fbincon/statusline-core/dist/src/editor/text.js.map +1 -0
  302. package/node_modules/@fbincon/statusline-core/dist/src/i18n/generated-locales.d.ts +6841 -0
  303. package/node_modules/@fbincon/statusline-core/dist/src/i18n/generated-locales.js +6841 -0
  304. package/node_modules/@fbincon/statusline-core/dist/src/i18n/generated-locales.js.map +1 -0
  305. package/node_modules/@fbincon/statusline-core/dist/src/i18n/messages.d.ts +16 -0
  306. package/node_modules/@fbincon/statusline-core/dist/src/i18n/messages.js +38 -0
  307. package/node_modules/@fbincon/statusline-core/dist/src/i18n/messages.js.map +1 -0
  308. package/node_modules/@fbincon/statusline-core/dist/src/i18n/registry.d.ts +3 -0
  309. package/node_modules/@fbincon/statusline-core/dist/src/i18n/registry.js +4 -0
  310. package/node_modules/@fbincon/statusline-core/dist/src/i18n/registry.js.map +1 -0
  311. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/en.d.ts +222 -0
  312. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/en.js +224 -0
  313. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/en.js.map +1 -0
  314. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/ja.d.ts +222 -0
  315. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/ja.js +224 -0
  316. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/ja.js.map +1 -0
  317. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/ko.d.ts +222 -0
  318. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/ko.js +224 -0
  319. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/ko.js.map +1 -0
  320. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/zh-CN.d.ts +222 -0
  321. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/zh-CN.js +224 -0
  322. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/zh-CN.js.map +1 -0
  323. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/zh-Hant.d.ts +222 -0
  324. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/zh-Hant.js +224 -0
  325. package/node_modules/@fbincon/statusline-core/dist/src/i18n/statusline/zh-Hant.js.map +1 -0
  326. package/node_modules/@fbincon/statusline-core/dist/src/integration/binding.d.ts +9 -0
  327. package/node_modules/@fbincon/statusline-core/dist/src/integration/binding.js +27 -0
  328. package/node_modules/@fbincon/statusline-core/dist/src/integration/binding.js.map +1 -0
  329. package/node_modules/@fbincon/statusline-core/dist/src/json-equality.d.ts +2 -0
  330. package/node_modules/@fbincon/statusline-core/dist/src/json-equality.js +31 -0
  331. package/node_modules/@fbincon/statusline-core/dist/src/json-equality.js.map +1 -0
  332. package/node_modules/@fbincon/statusline-core/dist/src/json-read.d.ts +9 -0
  333. package/node_modules/@fbincon/statusline-core/dist/src/json-read.js +137 -0
  334. package/node_modules/@fbincon/statusline-core/dist/src/json-read.js.map +1 -0
  335. package/node_modules/@fbincon/statusline-core/dist/src/json-text.d.ts +9 -0
  336. package/node_modules/@fbincon/statusline-core/dist/src/json-text.js +56 -0
  337. package/node_modules/@fbincon/statusline-core/dist/src/json-text.js.map +1 -0
  338. package/node_modules/@fbincon/statusline-core/dist/src/json.d.ts +18 -0
  339. package/node_modules/@fbincon/statusline-core/dist/src/json.js +165 -0
  340. package/node_modules/@fbincon/statusline-core/dist/src/json.js.map +1 -0
  341. package/node_modules/@fbincon/statusline-core/dist/src/numbers.d.ts +4 -0
  342. package/node_modules/@fbincon/statusline-core/dist/src/numbers.js +47 -0
  343. package/node_modules/@fbincon/statusline-core/dist/src/numbers.js.map +1 -0
  344. package/node_modules/@fbincon/statusline-core/dist/src/ordered-record.d.ts +21 -0
  345. package/node_modules/@fbincon/statusline-core/dist/src/ordered-record.js +105 -0
  346. package/node_modules/@fbincon/statusline-core/dist/src/ordered-record.js.map +1 -0
  347. package/node_modules/@fbincon/statusline-core/dist/src/release.d.ts +7 -0
  348. package/node_modules/@fbincon/statusline-core/dist/src/release.js +14 -0
  349. package/node_modules/@fbincon/statusline-core/dist/src/release.js.map +1 -0
  350. package/node_modules/@fbincon/statusline-core/dist/src/rendering/appearance.d.ts +10 -0
  351. package/node_modules/@fbincon/statusline-core/dist/src/rendering/appearance.js +73 -0
  352. package/node_modules/@fbincon/statusline-core/dist/src/rendering/appearance.js.map +1 -0
  353. package/node_modules/@fbincon/statusline-core/dist/src/rendering/coercion.d.ts +2 -0
  354. package/node_modules/@fbincon/statusline-core/dist/src/rendering/coercion.js +50 -0
  355. package/node_modules/@fbincon/statusline-core/dist/src/rendering/coercion.js.map +1 -0
  356. package/node_modules/@fbincon/statusline-core/dist/src/rendering/colors.d.ts +3 -0
  357. package/node_modules/@fbincon/statusline-core/dist/src/rendering/colors.js +36 -0
  358. package/node_modules/@fbincon/statusline-core/dist/src/rendering/colors.js.map +1 -0
  359. package/node_modules/@fbincon/statusline-core/dist/src/rendering/components.d.ts +10 -0
  360. package/node_modules/@fbincon/statusline-core/dist/src/rendering/components.js +49 -0
  361. package/node_modules/@fbincon/statusline-core/dist/src/rendering/components.js.map +1 -0
  362. package/node_modules/@fbincon/statusline-core/dist/src/rendering/context.d.ts +36 -0
  363. package/node_modules/@fbincon/statusline-core/dist/src/rendering/context.js +2 -0
  364. package/node_modules/@fbincon/statusline-core/dist/src/rendering/context.js.map +1 -0
  365. package/node_modules/@fbincon/statusline-core/dist/src/rendering/formatters.d.ts +10 -0
  366. package/node_modules/@fbincon/statusline-core/dist/src/rendering/formatters.js +58 -0
  367. package/node_modules/@fbincon/statusline-core/dist/src/rendering/formatters.js.map +1 -0
  368. package/node_modules/@fbincon/statusline-core/dist/src/rendering/git.d.ts +7 -0
  369. package/node_modules/@fbincon/statusline-core/dist/src/rendering/git.js +34 -0
  370. package/node_modules/@fbincon/statusline-core/dist/src/rendering/git.js.map +1 -0
  371. package/node_modules/@fbincon/statusline-core/dist/src/rendering/items.d.ts +49 -0
  372. package/node_modules/@fbincon/statusline-core/dist/src/rendering/items.js +399 -0
  373. package/node_modules/@fbincon/statusline-core/dist/src/rendering/items.js.map +1 -0
  374. package/node_modules/@fbincon/statusline-core/dist/src/rendering/language.d.ts +13 -0
  375. package/node_modules/@fbincon/statusline-core/dist/src/rendering/language.js +36 -0
  376. package/node_modules/@fbincon/statusline-core/dist/src/rendering/language.js.map +1 -0
  377. package/node_modules/@fbincon/statusline-core/dist/src/rendering/layout.d.ts +19 -0
  378. package/node_modules/@fbincon/statusline-core/dist/src/rendering/layout.js +176 -0
  379. package/node_modules/@fbincon/statusline-core/dist/src/rendering/layout.js.map +1 -0
  380. package/node_modules/@fbincon/statusline-core/dist/src/rendering/live.d.ts +4 -0
  381. package/node_modules/@fbincon/statusline-core/dist/src/rendering/live.js +29 -0
  382. package/node_modules/@fbincon/statusline-core/dist/src/rendering/live.js.map +1 -0
  383. package/node_modules/@fbincon/statusline-core/dist/src/rendering/metrics.d.ts +13 -0
  384. package/node_modules/@fbincon/statusline-core/dist/src/rendering/metrics.js +93 -0
  385. package/node_modules/@fbincon/statusline-core/dist/src/rendering/metrics.js.map +1 -0
  386. package/node_modules/@fbincon/statusline-core/dist/src/rendering/numeric-format.d.ts +3 -0
  387. package/node_modules/@fbincon/statusline-core/dist/src/rendering/numeric-format.js +46 -0
  388. package/node_modules/@fbincon/statusline-core/dist/src/rendering/numeric-format.js.map +1 -0
  389. package/node_modules/@fbincon/statusline-core/dist/src/rendering/palette.d.ts +23 -0
  390. package/node_modules/@fbincon/statusline-core/dist/src/rendering/palette.js +9 -0
  391. package/node_modules/@fbincon/statusline-core/dist/src/rendering/palette.js.map +1 -0
  392. package/node_modules/@fbincon/statusline-core/dist/src/rendering/powerline.d.ts +10 -0
  393. package/node_modules/@fbincon/statusline-core/dist/src/rendering/powerline.js +76 -0
  394. package/node_modules/@fbincon/statusline-core/dist/src/rendering/powerline.js.map +1 -0
  395. package/node_modules/@fbincon/statusline-core/dist/src/rendering/preferences.d.ts +14 -0
  396. package/node_modules/@fbincon/statusline-core/dist/src/rendering/preferences.js +98 -0
  397. package/node_modules/@fbincon/statusline-core/dist/src/rendering/preferences.js.map +1 -0
  398. package/node_modules/@fbincon/statusline-core/dist/src/rendering/preview.d.ts +67 -0
  399. package/node_modules/@fbincon/statusline-core/dist/src/rendering/preview.js +36 -0
  400. package/node_modules/@fbincon/statusline-core/dist/src/rendering/preview.js.map +1 -0
  401. package/node_modules/@fbincon/statusline-core/dist/src/rendering/spans.d.ts +8 -0
  402. package/node_modules/@fbincon/statusline-core/dist/src/rendering/spans.js +14 -0
  403. package/node_modules/@fbincon/statusline-core/dist/src/rendering/spans.js.map +1 -0
  404. package/node_modules/@fbincon/statusline-core/dist/src/rendering/styles.d.ts +24 -0
  405. package/node_modules/@fbincon/statusline-core/dist/src/rendering/styles.js +116 -0
  406. package/node_modules/@fbincon/statusline-core/dist/src/rendering/styles.js.map +1 -0
  407. package/node_modules/@fbincon/statusline-core/dist/src/rendering/subagents.d.ts +13 -0
  408. package/node_modules/@fbincon/statusline-core/dist/src/rendering/subagents.js +305 -0
  409. package/node_modules/@fbincon/statusline-core/dist/src/rendering/subagents.js.map +1 -0
  410. package/node_modules/@fbincon/statusline-core/dist/src/rendering/timer.d.ts +8 -0
  411. package/node_modules/@fbincon/statusline-core/dist/src/rendering/timer.js +33 -0
  412. package/node_modules/@fbincon/statusline-core/dist/src/rendering/timer.js.map +1 -0
  413. package/node_modules/@fbincon/statusline-core/dist/src/rendering/visibility.d.ts +4 -0
  414. package/node_modules/@fbincon/statusline-core/dist/src/rendering/visibility.js +52 -0
  415. package/node_modules/@fbincon/statusline-core/dist/src/rendering/visibility.js.map +1 -0
  416. package/node_modules/@fbincon/statusline-core/dist/src/runtime/git.d.ts +9 -0
  417. package/node_modules/@fbincon/statusline-core/dist/src/runtime/git.js +115 -0
  418. package/node_modules/@fbincon/statusline-core/dist/src/runtime/git.js.map +1 -0
  419. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/bindings.d.ts +4 -0
  420. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/bindings.js +104 -0
  421. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/bindings.js.map +1 -0
  422. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/model.d.ts +27 -0
  423. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/model.js +196 -0
  424. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/model.js.map +1 -0
  425. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/ownership.d.ts +6 -0
  426. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/ownership.js +45 -0
  427. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/ownership.js.map +1 -0
  428. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/reducer.d.ts +5 -0
  429. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/reducer.js +228 -0
  430. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/reducer.js.map +1 -0
  431. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/requests.d.ts +24 -0
  432. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/requests.js +145 -0
  433. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/requests.js.map +1 -0
  434. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/snapshot.d.ts +6 -0
  435. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/snapshot.js +70 -0
  436. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/snapshot.js.map +1 -0
  437. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/state.d.ts +36 -0
  438. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/state.js +110 -0
  439. package/node_modules/@fbincon/statusline-core/dist/src/runtime/live/state.js.map +1 -0
  440. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/agents.d.ts +8 -0
  441. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/agents.js +75 -0
  442. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/agents.js.map +1 -0
  443. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/hooks.d.ts +10 -0
  444. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/hooks.js +121 -0
  445. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/hooks.js.map +1 -0
  446. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/model.d.ts +43 -0
  447. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/model.js +198 -0
  448. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/model.js.map +1 -0
  449. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/native.d.ts +6 -0
  450. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/native.js +192 -0
  451. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/native.js.map +1 -0
  452. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/transitions.d.ts +16 -0
  453. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/transitions.js +245 -0
  454. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/transitions.js.map +1 -0
  455. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/view.d.ts +4 -0
  456. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/view.js +28 -0
  457. package/node_modules/@fbincon/statusline-core/dist/src/runtime/tasks/view.js.map +1 -0
  458. package/node_modules/@fbincon/statusline-core/dist/src/runtime/transcript.d.ts +26 -0
  459. package/node_modules/@fbincon/statusline-core/dist/src/runtime/transcript.js +183 -0
  460. package/node_modules/@fbincon/statusline-core/dist/src/runtime/transcript.js.map +1 -0
  461. package/node_modules/@fbincon/statusline-core/dist/src/runtime/usage.d.ts +64 -0
  462. package/node_modules/@fbincon/statusline-core/dist/src/runtime/usage.js +263 -0
  463. package/node_modules/@fbincon/statusline-core/dist/src/runtime/usage.js.map +1 -0
  464. package/node_modules/@fbincon/statusline-core/dist/src/runtime/values.d.ts +18 -0
  465. package/node_modules/@fbincon/statusline-core/dist/src/runtime/values.js +103 -0
  466. package/node_modules/@fbincon/statusline-core/dist/src/runtime/values.js.map +1 -0
  467. package/node_modules/@fbincon/statusline-core/dist/src/terminal/key.d.ts +7 -0
  468. package/node_modules/@fbincon/statusline-core/dist/src/terminal/key.js +2 -0
  469. package/node_modules/@fbincon/statusline-core/dist/src/terminal/key.js.map +1 -0
  470. package/node_modules/@fbincon/statusline-core/dist/src/terminal/spans.d.ts +6 -0
  471. package/node_modules/@fbincon/statusline-core/dist/src/terminal/spans.js +50 -0
  472. package/node_modules/@fbincon/statusline-core/dist/src/terminal/spans.js.map +1 -0
  473. package/node_modules/@fbincon/statusline-core/dist/src/timing/sample.d.ts +8 -0
  474. package/node_modules/@fbincon/statusline-core/dist/src/timing/sample.js +13 -0
  475. package/node_modules/@fbincon/statusline-core/dist/src/timing/sample.js.map +1 -0
  476. package/node_modules/@fbincon/statusline-core/dist/src/timing/timer.d.ts +22 -0
  477. package/node_modules/@fbincon/statusline-core/dist/src/timing/timer.js +75 -0
  478. package/node_modules/@fbincon/statusline-core/dist/src/timing/timer.js.map +1 -0
  479. package/node_modules/@fbincon/statusline-core/dist/src/unicode/generated-unicode.d.ts +12 -0
  480. package/node_modules/@fbincon/statusline-core/dist/src/unicode/generated-unicode.js +93 -0
  481. package/node_modules/@fbincon/statusline-core/dist/src/unicode/generated-unicode.js.map +1 -0
  482. package/node_modules/@fbincon/statusline-core/dist/src/unicode/index.d.ts +5 -0
  483. package/node_modules/@fbincon/statusline-core/dist/src/unicode/index.js +178 -0
  484. package/node_modules/@fbincon/statusline-core/dist/src/unicode/index.js.map +1 -0
  485. package/node_modules/@fbincon/statusline-core/package.json +8 -0
  486. package/node_modules/@fbincon/statusline-core/resources/i18n/languages.json +7 -0
  487. package/node_modules/@fbincon/statusline-core/resources/i18n/locales/en.json +1367 -0
  488. package/node_modules/@fbincon/statusline-core/resources/i18n/locales/ja.json +1367 -0
  489. package/node_modules/@fbincon/statusline-core/resources/i18n/locales/ko.json +1367 -0
  490. package/node_modules/@fbincon/statusline-core/resources/i18n/locales/zh-CN.json +1367 -0
  491. package/node_modules/@fbincon/statusline-core/resources/i18n/locales/zh-Hant.json +1367 -0
  492. package/node_modules/@fbincon/statusline-platform/dist/src/architecture.d.ts +15 -0
  493. package/node_modules/@fbincon/statusline-platform/dist/src/architecture.js +22 -0
  494. package/node_modules/@fbincon/statusline-platform/dist/src/architecture.js.map +1 -0
  495. package/node_modules/@fbincon/statusline-platform/dist/src/clocks.d.ts +4 -0
  496. package/node_modules/@fbincon/statusline-platform/dist/src/clocks.js +102 -0
  497. package/node_modules/@fbincon/statusline-platform/dist/src/clocks.js.map +1 -0
  498. package/node_modules/@fbincon/statusline-platform/dist/src/command.d.ts +16 -0
  499. package/node_modules/@fbincon/statusline-platform/dist/src/command.js +18 -0
  500. package/node_modules/@fbincon/statusline-platform/dist/src/command.js.map +1 -0
  501. package/node_modules/@fbincon/statusline-platform/dist/src/commands.d.ts +12 -0
  502. package/node_modules/@fbincon/statusline-platform/dist/src/commands.js +160 -0
  503. package/node_modules/@fbincon/statusline-platform/dist/src/commands.js.map +1 -0
  504. package/node_modules/@fbincon/statusline-platform/dist/src/errors.d.ts +1 -0
  505. package/node_modules/@fbincon/statusline-platform/dist/src/errors.js +19 -0
  506. package/node_modules/@fbincon/statusline-platform/dist/src/errors.js.map +1 -0
  507. package/node_modules/@fbincon/statusline-platform/dist/src/files.d.ts +8 -0
  508. package/node_modules/@fbincon/statusline-platform/dist/src/files.js +164 -0
  509. package/node_modules/@fbincon/statusline-platform/dist/src/files.js.map +1 -0
  510. package/node_modules/@fbincon/statusline-platform/dist/src/hash.d.ts +2 -0
  511. package/node_modules/@fbincon/statusline-platform/dist/src/hash.js +5 -0
  512. package/node_modules/@fbincon/statusline-platform/dist/src/hash.js.map +1 -0
  513. package/node_modules/@fbincon/statusline-platform/dist/src/input.d.ts +2 -0
  514. package/node_modules/@fbincon/statusline-platform/dist/src/input.js +14 -0
  515. package/node_modules/@fbincon/statusline-platform/dist/src/input.js.map +1 -0
  516. package/node_modules/@fbincon/statusline-platform/dist/src/launch.d.ts +12 -0
  517. package/node_modules/@fbincon/statusline-platform/dist/src/launch.js +21 -0
  518. package/node_modules/@fbincon/statusline-platform/dist/src/launch.js.map +1 -0
  519. package/node_modules/@fbincon/statusline-platform/dist/src/line-cursor.d.ts +2 -0
  520. package/node_modules/@fbincon/statusline-platform/dist/src/line-cursor.js +31 -0
  521. package/node_modules/@fbincon/statusline-platform/dist/src/line-cursor.js.map +1 -0
  522. package/node_modules/@fbincon/statusline-platform/dist/src/native.d.ts +15 -0
  523. package/node_modules/@fbincon/statusline-platform/dist/src/native.js +36 -0
  524. package/node_modules/@fbincon/statusline-platform/dist/src/native.js.map +1 -0
  525. package/node_modules/@fbincon/statusline-platform/dist/src/plugin-host.d.ts +17 -0
  526. package/node_modules/@fbincon/statusline-platform/dist/src/plugin-host.js +44 -0
  527. package/node_modules/@fbincon/statusline-platform/dist/src/plugin-host.js.map +1 -0
  528. package/node_modules/@fbincon/statusline-platform/dist/src/presentation.d.ts +4 -0
  529. package/node_modules/@fbincon/statusline-platform/dist/src/presentation.js +48 -0
  530. package/node_modules/@fbincon/statusline-platform/dist/src/presentation.js.map +1 -0
  531. package/node_modules/@fbincon/statusline-platform/dist/src/processes.d.ts +2 -0
  532. package/node_modules/@fbincon/statusline-platform/dist/src/processes.js +67 -0
  533. package/node_modules/@fbincon/statusline-platform/dist/src/processes.js.map +1 -0
  534. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/bridge.d.ts +42 -0
  535. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/bridge.js +180 -0
  536. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/bridge.js.map +1 -0
  537. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/input.d.ts +11 -0
  538. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/input.js +81 -0
  539. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/input.js.map +1 -0
  540. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/launchers.d.ts +32 -0
  541. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/launchers.js +157 -0
  542. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/launchers.js.map +1 -0
  543. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/session.d.ts +18 -0
  544. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/session.js +150 -0
  545. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/session.js.map +1 -0
  546. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/windows-modes.d.ts +6 -0
  547. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/windows-modes.js +39 -0
  548. package/node_modules/@fbincon/statusline-platform/dist/src/terminal/windows-modes.js.map +1 -0
  549. package/node_modules/@fbincon/statusline-platform/dist/src/utf8.d.ts +5 -0
  550. package/node_modules/@fbincon/statusline-platform/dist/src/utf8.js +82 -0
  551. package/node_modules/@fbincon/statusline-platform/dist/src/utf8.js.map +1 -0
  552. package/node_modules/@fbincon/statusline-platform/package.json +8 -0
  553. package/node_modules/@fbincon/statusline-tui/dist/src/drawing.d.ts +14 -0
  554. package/node_modules/@fbincon/statusline-tui/dist/src/drawing.js +230 -0
  555. package/node_modules/@fbincon/statusline-tui/dist/src/drawing.js.map +1 -0
  556. package/node_modules/@fbincon/statusline-tui/dist/src/layout.d.ts +30 -0
  557. package/node_modules/@fbincon/statusline-tui/dist/src/layout.js +34 -0
  558. package/node_modules/@fbincon/statusline-tui/dist/src/layout.js.map +1 -0
  559. package/node_modules/@fbincon/statusline-tui/dist/src/session.d.ts +28 -0
  560. package/node_modules/@fbincon/statusline-tui/dist/src/session.js +126 -0
  561. package/node_modules/@fbincon/statusline-tui/dist/src/session.js.map +1 -0
  562. package/node_modules/@fbincon/statusline-tui/dist/src/state.d.ts +52 -0
  563. package/node_modules/@fbincon/statusline-tui/dist/src/state.js +352 -0
  564. package/node_modules/@fbincon/statusline-tui/dist/src/state.js.map +1 -0
  565. package/node_modules/@fbincon/statusline-tui/dist/src/theme.d.ts +7 -0
  566. package/node_modules/@fbincon/statusline-tui/dist/src/theme.js +5 -0
  567. package/node_modules/@fbincon/statusline-tui/dist/src/theme.js.map +1 -0
  568. package/node_modules/@fbincon/statusline-tui/package.json +16 -0
  569. package/node_modules/@koromix/koffi-darwin-arm64/README.md +6 -0
  570. package/node_modules/@koromix/koffi-darwin-arm64/darwin_arm64/koffi.node +0 -0
  571. package/node_modules/@koromix/koffi-darwin-arm64/index.js +1 -0
  572. package/node_modules/@koromix/koffi-darwin-arm64/package.json +24 -0
  573. package/node_modules/@koromix/koffi-darwin-x64/README.md +6 -0
  574. package/node_modules/@koromix/koffi-darwin-x64/darwin_x64/koffi.node +0 -0
  575. package/node_modules/@koromix/koffi-darwin-x64/index.js +1 -0
  576. package/node_modules/@koromix/koffi-darwin-x64/package.json +24 -0
  577. package/node_modules/@koromix/koffi-linux-x64/README.md +6 -0
  578. package/node_modules/@koromix/koffi-linux-x64/index.js +198 -0
  579. package/node_modules/@koromix/koffi-linux-x64/linux_x64/koffi.node +0 -0
  580. package/node_modules/@koromix/koffi-linux-x64/musl_x64/koffi.node +0 -0
  581. package/node_modules/@koromix/koffi-linux-x64/package.json +24 -0
  582. package/node_modules/@koromix/koffi-win32-x64/README.md +6 -0
  583. package/node_modules/@koromix/koffi-win32-x64/index.js +1 -0
  584. package/node_modules/@koromix/koffi-win32-x64/package.json +24 -0
  585. package/node_modules/@koromix/koffi-win32-x64/win32_x64/koffi.lib +0 -0
  586. package/node_modules/@koromix/koffi-win32-x64/win32_x64/koffi.node +0 -0
  587. package/node_modules/koffi/LICENSE.txt +22 -0
  588. package/node_modules/koffi/README.md +46 -0
  589. package/node_modules/koffi/index.cjs +1 -0
  590. package/node_modules/koffi/index.d.ts +390 -0
  591. package/node_modules/koffi/index.js +2 -0
  592. package/node_modules/koffi/indirect.cjs +1 -0
  593. package/node_modules/koffi/indirect.js +2 -0
  594. package/node_modules/koffi/package.json +73 -0
  595. package/node_modules/koffi/src/koffi/index.cjs +327 -0
  596. package/node_modules/koffi/src/koffi/index.js +312 -0
  597. package/node_modules/koffi/src/koffi/indirect.cjs +326 -0
  598. package/node_modules/koffi/src/koffi/indirect.js +311 -0
  599. package/node_modules/koffi/src/koffi/src/static.cjs +170 -0
  600. package/node_modules/koffi/src/koffi/src/static.js +173 -0
  601. package/node_modules/lossless-json/LICENSE.md +9 -0
  602. package/node_modules/lossless-json/README.md +549 -0
  603. package/node_modules/lossless-json/lib/esm/LosslessNumber.js +92 -0
  604. package/node_modules/lossless-json/lib/esm/LosslessNumber.js.map +1 -0
  605. package/node_modules/lossless-json/lib/esm/config.js +9 -0
  606. package/node_modules/lossless-json/lib/esm/config.js.map +1 -0
  607. package/node_modules/lossless-json/lib/esm/index.js +9 -0
  608. package/node_modules/lossless-json/lib/esm/index.js.map +1 -0
  609. package/node_modules/lossless-json/lib/esm/numberParsers.js +9 -0
  610. package/node_modules/lossless-json/lib/esm/numberParsers.js.map +1 -0
  611. package/node_modules/lossless-json/lib/esm/package.json +3 -0
  612. package/node_modules/lossless-json/lib/esm/parse.js +346 -0
  613. package/node_modules/lossless-json/lib/esm/parse.js.map +1 -0
  614. package/node_modules/lossless-json/lib/esm/revive.js +57 -0
  615. package/node_modules/lossless-json/lib/esm/revive.js.map +1 -0
  616. package/node_modules/lossless-json/lib/esm/reviveDate.js +10 -0
  617. package/node_modules/lossless-json/lib/esm/reviveDate.js.map +1 -0
  618. package/node_modules/lossless-json/lib/esm/stringify.js +166 -0
  619. package/node_modules/lossless-json/lib/esm/stringify.js.map +1 -0
  620. package/node_modules/lossless-json/lib/esm/types.js +2 -0
  621. package/node_modules/lossless-json/lib/esm/types.js.map +1 -0
  622. package/node_modules/lossless-json/lib/esm/utils.js +236 -0
  623. package/node_modules/lossless-json/lib/esm/utils.js.map +1 -0
  624. package/node_modules/lossless-json/lib/types/LosslessNumber.d.ts +40 -0
  625. package/node_modules/lossless-json/lib/types/LosslessNumber.d.ts.map +1 -0
  626. package/node_modules/lossless-json/lib/types/config.d.ts +13 -0
  627. package/node_modules/lossless-json/lib/types/config.d.ts.map +1 -0
  628. package/node_modules/lossless-json/lib/types/index.d.ts +9 -0
  629. package/node_modules/lossless-json/lib/types/index.d.ts.map +1 -0
  630. package/node_modules/lossless-json/lib/types/numberParsers.d.ts +4 -0
  631. package/node_modules/lossless-json/lib/types/numberParsers.d.ts.map +1 -0
  632. package/node_modules/lossless-json/lib/types/parse.d.ts +33 -0
  633. package/node_modules/lossless-json/lib/types/parse.d.ts.map +1 -0
  634. package/node_modules/lossless-json/lib/types/revive.d.ts +13 -0
  635. package/node_modules/lossless-json/lib/types/revive.d.ts.map +1 -0
  636. package/node_modules/lossless-json/lib/types/reviveDate.d.ts +5 -0
  637. package/node_modules/lossless-json/lib/types/reviveDate.d.ts.map +1 -0
  638. package/node_modules/lossless-json/lib/types/stringify.d.ts +37 -0
  639. package/node_modules/lossless-json/lib/types/stringify.d.ts.map +1 -0
  640. package/node_modules/lossless-json/lib/types/types.d.ts +61 -0
  641. package/node_modules/lossless-json/lib/types/types.d.ts.map +1 -0
  642. package/node_modules/lossless-json/lib/types/utils.d.ts +79 -0
  643. package/node_modules/lossless-json/lib/types/utils.d.ts.map +1 -0
  644. package/node_modules/lossless-json/lib/umd/lossless-json.js +1 -0
  645. package/node_modules/lossless-json/lib/umd/lossless-json.js.map +1 -0
  646. package/node_modules/lossless-json/lib/umd/package.json +3 -0
  647. package/node_modules/lossless-json/package.json +89 -0
  648. package/package.json +57 -4
@@ -0,0 +1,183 @@
1
+ import { LosslessNumber, pythonFloat } from '../json.js';
2
+ import { numeric, object, truth, string } from './values.js';
3
+ import { agentNotificationId } from './tasks/model.js';
4
+ import { divideIntegers } from '../numbers.js';
5
+ const SPACE = '[\\p{White_Space}\\x1c-\\x1f]';
6
+ const TRIM_SPACE = new RegExp('^' + SPACE + '+|' + SPACE + '+$', 'gu');
7
+ export function trim(value) { return value.replace(TRIM_SPACE, ''); }
8
+ export function float(value) { return new LosslessNumber(pythonFloat(value)); }
9
+ export function roundedInteger(value) {
10
+ const floor = Math.floor(value), fraction = value - floor;
11
+ return BigInt(fraction > 0.5 || fraction === 0.5 && floor % 2 !== 0 ? floor + 1 : floor);
12
+ }
13
+ /** ISO transcript seconds use the same binary64 precision as datetime.timestamp. */
14
+ export function timestamp(value) {
15
+ if (typeof value !== 'string')
16
+ return null;
17
+ let raw = trim(value);
18
+ if (raw.endsWith('Z'))
19
+ raw = raw.slice(0, -1) + '+00:00';
20
+ const date = raw.match(/^(\d{4})(-?)(?:(\d{2})\2(\d{2})|W(\d{2})(?:\2([1-7]))?)/u);
21
+ if (!date)
22
+ return null;
23
+ const year = Number(date[1]);
24
+ if (year < 1)
25
+ return null;
26
+ const calendar = new Date(0);
27
+ calendar.setUTCHours(0, 0, 0, 0);
28
+ if (date[5] !== undefined) {
29
+ const week = Number(date[5]), weekday = Number(date[6] ?? 1);
30
+ if (week < 1 || week > 53)
31
+ return null;
32
+ calendar.setUTCFullYear(year, 0, 4);
33
+ calendar.setUTCDate(calendar.getUTCDate() - (calendar.getUTCDay() + 6) % 7 + (week - 1) * 7 + weekday - 1);
34
+ const thursday = new Date(calendar.getTime());
35
+ thursday.setUTCDate(thursday.getUTCDate() + 4 - weekday);
36
+ if (thursday.getUTCFullYear() !== year || calendar.getUTCFullYear() > 9999)
37
+ return null;
38
+ }
39
+ else {
40
+ const month = Number(date[3]), day = Number(date[4]);
41
+ if (month < 1 || month > 12 || day < 1)
42
+ return null;
43
+ calendar.setUTCFullYear(year, month - 1, day);
44
+ if (calendar.getUTCMonth() !== month - 1 || calendar.getUTCDate() !== day)
45
+ return null;
46
+ }
47
+ const tail = raw.slice(date[0].length);
48
+ // fromisoformat accepts one arbitrary Unicode separator and compact times.
49
+ const time = tail ? tail.slice([...tail][0].length).match(/^(\d{2})(?:(:?)(\d{2})(?:\2(\d{2}))?)?(?:[.,](\d+))?([+-].*)?$/u) : null;
50
+ if (tail && !time || time?.[5] !== undefined && time[4] === undefined)
51
+ return null;
52
+ const hour = Number(time?.[1] ?? 0), minute = Number(time?.[3] ?? 0), second = Number(time?.[4] ?? 0), micro = BigInt((time?.[5] ?? '').slice(0, 6).padEnd(6, '0'));
53
+ if (hour > 23 || minute > 59 || second > 59)
54
+ return null;
55
+ calendar.setUTCHours(hour, minute, second, 0);
56
+ const zone = time?.[6];
57
+ if (zone === undefined) {
58
+ const local = new Date(0);
59
+ local.setFullYear(calendar.getUTCFullYear(), calendar.getUTCMonth(), calendar.getUTCDate());
60
+ local.setHours(hour, minute, second, 0);
61
+ // Python's naive timestamp conversion probes the previous day for fold.
62
+ if (year === 1 && calendar.getUTCMonth() === 0 && calendar.getUTCDate() === 1)
63
+ return null;
64
+ return local.getTime() / 1000 + Number(micro) / 1e6;
65
+ }
66
+ const offset = zone.match(/^([+-])(\d{2})(?:(:?)(\d{2})(?:\3(\d{2}))?)?(?:[.,](\d+))?$/u);
67
+ if (!offset || offset[6] !== undefined && offset[5] === undefined)
68
+ return null;
69
+ const seconds = Number(offset[2]) * 3600 + Number(offset[4] ?? 0) * 60 + Number(offset[5] ?? 0);
70
+ let micros = seconds === 0 ? 0n : BigInt(seconds) * 1000000n + BigInt((offset[6] ?? '').slice(0, 6).padEnd(6, '0'));
71
+ if (micros >= 86400000000n)
72
+ return null;
73
+ if (offset[1] === '-')
74
+ micros = -micros;
75
+ return divideIntegers(BigInt(calendar.getTime()) * 1000n + micro - micros, 1000000n);
76
+ }
77
+ const LOCAL_PREFIXES = ['<command-name>', '<local-command-', '<bash-input>', '<bash-stdout>'];
78
+ export function localCommand(content) {
79
+ return typeof content === 'string' && LOCAL_PREFIXES.some(prefix => content.replace(new RegExp('^' + SPACE + '+', 'u'), '').startsWith(prefix));
80
+ }
81
+ export function realPrompt(record, content) {
82
+ if (typeof content !== 'string' || truth(record.isMeta) || localCommand(content))
83
+ return false;
84
+ const origin = object(record.origin) ? record.origin.kind ?? null : null;
85
+ return origin === 'human' || ['typed', 'queued', 'sdk'].includes(String(record.promptSource)) && (origin === null || origin === 'human');
86
+ }
87
+ /** Retains compact lifecycle observations, never the parsed transcript rows. */
88
+ export class TurnAccumulator {
89
+ promptContext;
90
+ result = { prompt: null, interrupt: null, local_command: null, assistant_activity: null, observations: [] };
91
+ constructor(promptContext = null) {
92
+ this.promptContext = promptContext;
93
+ }
94
+ push(row) {
95
+ const result = this.result;
96
+ if (!object(row))
97
+ return;
98
+ const ts = timestamp(row.timestamp);
99
+ if (row.type === 'assistant') {
100
+ if (ts !== null) {
101
+ if (result.assistant_activity === null || ts > result.assistant_activity)
102
+ result.assistant_activity = ts;
103
+ result.observations.push({ kind: 'assistant', wall_ns: roundedInteger(ts * 1e9), prompt_id: truth(row.promptId) ? row.promptId : this.promptContext });
104
+ }
105
+ return;
106
+ }
107
+ if (row.type === 'system' && row.subtype === 'stop_hook_summary') {
108
+ if (ts !== null && row.preventedContinuation === false && Array.isArray(row.hookErrors) && !row.hookErrors.length && (row.hookAdditionalContext == null || Array.isArray(row.hookAdditionalContext) && !row.hookAdditionalContext.length) && !truth(row.stopReason))
109
+ result.observations.push({ kind: 'confirmed_stop', wall_ns: roundedInteger(ts * 1e9), prompt_id: truth(row.promptId) ? row.promptId : this.promptContext });
110
+ return;
111
+ }
112
+ if (row.type === 'system' && row.subtype === 'turn_duration') {
113
+ const duration = numeric(row.durationMs);
114
+ if (ts !== null && duration !== null && Number.isFinite(duration) && duration >= 0 && duration <= 1e15)
115
+ result.observations.push({ kind: 'turn_duration', wall_ns: roundedInteger(ts * 1e9), duration_ms: row.durationMs, prompt_id: truth(row.promptId) ? row.promptId : this.promptContext });
116
+ return;
117
+ }
118
+ if (row.type !== 'user' || !object(row.message) || row.message.role !== 'user')
119
+ return;
120
+ const promptId = truth(row.promptId) ? string(row.promptId) : null;
121
+ if (truth(row.interruptedMessageId) && ts !== null) {
122
+ const candidate = { ts: float(ts), prompt_id: promptId };
123
+ if (!result.interrupt || ts > numeric(result.interrupt.ts))
124
+ result.interrupt = candidate;
125
+ result.observations.push({ kind: 'interrupt', prompt_id: promptId, wall_ns: roundedInteger(ts * 1e9) });
126
+ }
127
+ const content = row.message.content;
128
+ const notificationText = Array.isArray(content) ? content.filter(part => object(part) && part.type === 'text').map(part => {
129
+ const value = part.text ?? (Object.hasOwn(part, 'text') ? null : '');
130
+ if (typeof value !== 'string')
131
+ throw new TypeError('Transcript text part must be a string');
132
+ return value;
133
+ }).join('\n') : content;
134
+ const agentId = agentNotificationId(notificationText), notification = truth(row.isMeta) || object(row.origin) && row.origin.kind === 'task-notification';
135
+ if (agentId && ts !== null && notification) {
136
+ result.observations.push({ kind: 'agent_notification', agent_id: agentId, prompt_id: promptId, wall_ns: roundedInteger(ts * 1e9) });
137
+ if (promptId)
138
+ this.promptContext = promptId;
139
+ return;
140
+ }
141
+ if (ts === null || typeof content !== 'string')
142
+ return;
143
+ const candidate = { ts: float(ts), prompt_id: promptId };
144
+ if (localCommand(content)) {
145
+ if (!result.local_command || ts > numeric(result.local_command.ts))
146
+ result.local_command = candidate;
147
+ result.observations.push({ kind: 'local_command', prompt_id: promptId, wall_ns: roundedInteger(ts * 1e9) });
148
+ }
149
+ else if (realPrompt(row, content)) {
150
+ this.promptContext = promptId;
151
+ if (!result.prompt || ts > numeric(result.prompt.ts))
152
+ result.prompt = candidate;
153
+ result.observations.push({ kind: 'prompt', prompt_id: promptId, wall_ns: roundedInteger(ts * 1e9) });
154
+ }
155
+ }
156
+ }
157
+ export function turnEvents(lines, promptContext = null) {
158
+ const scan = new TurnAccumulator(promptContext);
159
+ for (const row of lines)
160
+ scan.push(row);
161
+ return scan.result;
162
+ }
163
+ export function updateTurnMetadata(entry, lines, resetContext = false) {
164
+ return applyTurnMetadata(entry, turnEvents(lines, resetContext ? null : entry.transcript_prompt_id ?? null));
165
+ }
166
+ export function applyTurnMetadata(entry, result) {
167
+ for (const event of result.observations)
168
+ if (event.kind === 'prompt')
169
+ entry.transcript_prompt_id = event.prompt_id;
170
+ if (result.prompt && numeric(result.prompt.ts) > (numeric(entry.last_pt) ?? 0)) {
171
+ entry.last_pt = result.prompt.ts;
172
+ entry.last_prompt_id = result.prompt.prompt_id;
173
+ }
174
+ for (const [key, value] of [['last_interrupt', result.interrupt], ['last_local_command', result.local_command]]) {
175
+ const old = entry[key];
176
+ if (value && numeric(value.ts) > (object(old) ? numeric(old.ts) ?? 0 : 0))
177
+ entry[key] = value;
178
+ }
179
+ if (result.assistant_activity !== null && result.assistant_activity > (numeric(entry.last_assistant_ts) ?? 0))
180
+ entry.last_assistant_ts = float(result.assistant_activity);
181
+ return result.observations;
182
+ }
183
+ //# sourceMappingURL=transcript.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transcript.js","sourceRoot":"","sources":["../../../src/runtime/transcript.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAa,MAAM,aAAa,CAAC;AACxE,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/C,MAAM,KAAK,GAAG,+BAA+B,CAAC;AAC9C,MAAM,UAAU,GAAG,IAAI,MAAM,CAAC,GAAG,GAAG,KAAK,GAAG,IAAI,GAAG,KAAK,GAAG,IAAI,EAAE,IAAI,CAAC,CAAC;AACvE,MAAM,UAAU,IAAI,CAAC,KAAa,IAAY,OAAO,KAAK,CAAC,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC;AACrF,MAAM,UAAU,KAAK,CAAC,KAAa,IAAoB,OAAO,IAAI,cAAc,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;AACvG,MAAM,UAAU,cAAc,CAAC,KAAa;IACxC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,GAAG,KAAK,GAAG,KAAK,CAAC;IAC1D,OAAO,MAAM,CAAC,QAAQ,GAAG,GAAG,IAAI,QAAQ,KAAK,GAAG,IAAI,KAAK,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;AAC7F,CAAC;AACD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AE,CAAE,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YACtE,KAAK,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;IAC3B,CAAC;IACD,IAAI,MAAM,CAAC,kBAAkB,KAAK,IAAI,IAAI,MAAM,CAAC,kBAAkB,GAAG,CAAC,OAAO,CAAC,KAAK,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC;QACzG,KAAK,CAAC,iBAAiB,GAAG,KAAK,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAC;IAC/D,OAAO,MAAM,CAAC,YAAY,CAAC;AAC/B,CAAC"}
@@ -0,0 +1,64 @@
1
+ import { type Data } from './values.js';
2
+ export declare const BASE: {
3
+ i: bigint;
4
+ o: bigint;
5
+ cc: bigint;
6
+ cr: bigint;
7
+ }, MAX_IDS = 5000, MAX_SESSIONS = 100, TURN_SCAN_VERSION = 6, USAGE_SCAN_VERSION = 3;
8
+ export declare const TOKEN_FIELDS: {
9
+ readonly hit: readonly ["cr"];
10
+ readonly miss: readonly ["i", "cc"];
11
+ readonly out: readonly ["o"];
12
+ };
13
+ export type Counters = typeof BASE;
14
+ export type Totals = {
15
+ hit: bigint;
16
+ miss: bigint;
17
+ out: bigint;
18
+ };
19
+ export type Observed = {
20
+ input: boolean;
21
+ output: boolean;
22
+ };
23
+ export interface UsageEntry extends Data {
24
+ files: Record<string, Data>;
25
+ ids: Record<string, Counters>;
26
+ base: Counters;
27
+ token_observed?: Observed;
28
+ }
29
+ export declare function usageInt(value: unknown): bigint;
30
+ export declare function hasUsage(value: unknown, fields: readonly string[]): value is Data;
31
+ export declare function tokenObservations(entry: Data, positiveOnly?: boolean): Observed;
32
+ export declare function addUsage(out: Record<string, Counters> | null, row: unknown, observed?: Observed): void;
33
+ export declare function parseUsage(lines: readonly unknown[], observed?: Observed): Record<string, Counters>;
34
+ export declare function mergeUsageFields(ids: Record<string, Counters>, newIds: Record<string, Counters>, keys: readonly (keyof Totals)[]): void;
35
+ export declare function mergeIds(ids: Record<string, Counters>, next: Record<string, Counters>): boolean;
36
+ /** Each independently observed token field keeps only IDs after its latest
37
+ * snapshot. Group insertion order matches the legacy final-index rescan. */
38
+ export declare class CostAccumulator {
39
+ private readonly observed?;
40
+ private latest;
41
+ private lastTime;
42
+ private readonly times;
43
+ private readonly fields;
44
+ private groups;
45
+ constructor(observed?: Observed | undefined);
46
+ push(row: unknown): void;
47
+ finish(hash: (input: string) => string): Data | null;
48
+ }
49
+ export declare function parseCostSnapshot(lines: readonly unknown[], hash: (input: string) => string, observed?: Observed): Data | null;
50
+ export declare function stageCostSnapshot(entry: UsageEntry, lines: readonly unknown[], hash: (input: string) => string, force?: boolean): void;
51
+ export declare function stageParsedCostSnapshot(entry: UsageEntry, snapshot: Data | null, force?: boolean): void;
52
+ export declare function stageSubagentDelta(entry: UsageEntry, lines: readonly unknown[]): void;
53
+ export declare function aggregateVisible(entry: Data): Counters;
54
+ export declare function visibleTotals(entry: Data): Totals;
55
+ export declare function displayTotals(entry: Data, visible?: Totals): Totals;
56
+ export declare function acceptPending(entry: UsageEntry, visible: Totals): boolean;
57
+ export declare function collapseIds(entry: UsageEntry): boolean;
58
+ export interface SessionTokenCounts {
59
+ hit: bigint | null;
60
+ miss: bigint | null;
61
+ out: bigint | null;
62
+ input_tokens: bigint | null;
63
+ }
64
+ export declare function sessionTokenCounts(entry: unknown): SessionTokenCounts | null;
@@ -0,0 +1,263 @@
1
+ import { forEachRecord, recordEntries, recordKeys, recordValues } from '../ordered-record.js';
2
+ import { object, int, numeric, own, dictionary, string } from './values.js';
3
+ import { timestamp, float } from './transcript.js';
4
+ export const BASE = { i: 0n, o: 0n, cc: 0n, cr: 0n }, MAX_IDS = 5000, MAX_SESSIONS = 100, TURN_SCAN_VERSION = 6, USAGE_SCAN_VERSION = 3;
5
+ export const TOKEN_FIELDS = { hit: ['cr'], miss: ['i', 'cc'], out: ['o'] };
6
+ const FIELDS = ['i', 'o', 'cc', 'cr'];
7
+ const INPUT = ['input_tokens', 'cache_creation_input_tokens', 'cache_read_input_tokens'];
8
+ export function usageInt(value) { const result = int(value); return result !== null && result >= 0n ? result : 0n; }
9
+ export function hasUsage(value, fields) { return object(value) && fields.some(field => { const n = int(value[field]); return n !== null && n >= 0n; }); }
10
+ export function tokenObservations(entry, positiveOnly = false) {
11
+ if (object(entry.token_observed))
12
+ return { input: entry.token_observed.input === true, output: entry.token_observed.output === true };
13
+ const has = (record, fields) => positiveOnly ? object(record) && fields.some(field => usageInt(record[field]) > 0n) : hasUsage(record, fields);
14
+ const observed = { input: false, output: false };
15
+ for (const row of recordValues(object(entry.ids) ? entry.ids : {})) {
16
+ observed.input ||= has(row, ['i', 'cc', 'cr']);
17
+ observed.output ||= has(row, ['o']);
18
+ if (observed.input && observed.output)
19
+ break;
20
+ }
21
+ observed.input ||= has(entry.api_snapshot, ['hit', 'miss']);
22
+ observed.output ||= has(entry.api_snapshot, ['out']);
23
+ if (object(entry.base)) {
24
+ observed.input ||= ['i', 'cc', 'cr'].some(key => usageInt(entry.base[key]) > 0n);
25
+ observed.output ||= usageInt(entry.base.o) > 0n;
26
+ }
27
+ return observed;
28
+ }
29
+ function observe(observed, usage, input, output) {
30
+ if (observed) {
31
+ observed.input ||= hasUsage(usage, input);
32
+ observed.output ||= hasUsage(usage, output);
33
+ }
34
+ }
35
+ export function addUsage(out, row, observed) {
36
+ if (!object(row) || row.type !== 'assistant' || !object(row.message))
37
+ return;
38
+ const { id, usage } = row.message;
39
+ if (typeof id !== 'string' || !id || !hasUsage(usage, [...INPUT, 'output_tokens']))
40
+ return;
41
+ observe(observed, usage, INPUT, ['output_tokens']);
42
+ if (!out)
43
+ return;
44
+ const record = out[id] ??= { ...BASE };
45
+ for (const [key, field] of [['i', 'input_tokens'], ['o', 'output_tokens'], ['cc', 'cache_creation_input_tokens'], ['cr', 'cache_read_input_tokens']]) {
46
+ const value = int(usage[field]);
47
+ if (value !== null && value > record[key])
48
+ record[key] = value;
49
+ }
50
+ }
51
+ export function parseUsage(lines, observed) {
52
+ const out = dictionary();
53
+ for (const row of lines)
54
+ addUsage(out, row, observed);
55
+ return out;
56
+ }
57
+ export function mergeUsageFields(ids, newIds, keys) {
58
+ forEachRecord(newIds, (next, id) => {
59
+ const record = ids[id] ??= { ...BASE };
60
+ for (const key of keys)
61
+ for (const field of TOKEN_FIELDS[key])
62
+ if (usageInt(next[field]) > usageInt(record[field]))
63
+ record[field] = next[field];
64
+ });
65
+ }
66
+ export function mergeIds(ids, next) {
67
+ let changed = false;
68
+ forEachRecord(next, (value, id) => {
69
+ const record = own(ids, id);
70
+ if (record === undefined) {
71
+ ids[id] = value;
72
+ changed = true;
73
+ return;
74
+ }
75
+ for (const key of FIELDS)
76
+ if (usageInt(value[key]) > usageInt(record[key])) {
77
+ record[key] = value[key];
78
+ changed = true;
79
+ }
80
+ });
81
+ return changed;
82
+ }
83
+ /** Each independently observed token field keeps only IDs after its latest
84
+ * snapshot. Group insertion order matches the legacy final-index rescan. */
85
+ export class CostAccumulator {
86
+ observed;
87
+ latest = null;
88
+ lastTime = null;
89
+ times = {};
90
+ fields = new Map();
91
+ groups = [];
92
+ constructor(observed) {
93
+ this.observed = observed;
94
+ }
95
+ push(row) {
96
+ if (!object(row))
97
+ return;
98
+ const time = timestamp(row.timestamp);
99
+ if (time !== null)
100
+ this.lastTime = time;
101
+ for (const group of this.groups)
102
+ addUsage(group, row);
103
+ if (row.type !== 'cost-state' || !object(row.modelUsage) || !recordKeys(row.modelUsage).length)
104
+ return;
105
+ let hit = 0n, miss = 0n, out = 0n, valid = 0;
106
+ const available = { input: false, output: false };
107
+ forEachRecord(row.modelUsage, usage => {
108
+ const input = ['inputTokens', 'cacheCreationInputTokens', 'cacheReadInputTokens'];
109
+ if (!hasUsage(usage, [...input, 'outputTokens']))
110
+ return;
111
+ observe(available, usage, input, ['outputTokens']);
112
+ valid++;
113
+ hit += usageInt(usage.cacheReadInputTokens);
114
+ miss += usageInt(usage.inputTokens) + usageInt(usage.cacheCreationInputTokens);
115
+ out += usageInt(usage.outputTokens);
116
+ });
117
+ if (!valid)
118
+ return;
119
+ if (this.observed) {
120
+ this.observed.input ||= available.input;
121
+ this.observed.output ||= available.output;
122
+ }
123
+ const totals = {};
124
+ if (available.input)
125
+ Object.assign(totals, { hit, miss });
126
+ if (available.output)
127
+ totals.out = out;
128
+ Object.assign(this.latest ??= {}, totals);
129
+ const post = dictionary();
130
+ for (const key of Object.keys(totals)) {
131
+ this.fields.set(key, post);
132
+ this.times[key] = this.lastTime === null ? null : float(this.lastTime);
133
+ }
134
+ this.groups = [...new Set(this.fields.values())];
135
+ }
136
+ finish(hash) {
137
+ if (!this.latest)
138
+ return null;
139
+ const latest = this.latest;
140
+ latest.fingerprint = hash(recordKeys(TOKEN_FIELDS).map(key => string(latest[key])).join(':'));
141
+ latest._snapshot_ts = this.times;
142
+ const post = dictionary();
143
+ latest._post_ids = post;
144
+ for (const group of this.groups)
145
+ mergeUsageFields(post, group, [...this.fields].filter(([, value]) => value === group).map(([key]) => key));
146
+ return latest;
147
+ }
148
+ }
149
+ export function parseCostSnapshot(lines, hash, observed) {
150
+ const scan = new CostAccumulator(observed);
151
+ for (const row of lines)
152
+ scan.push(row);
153
+ return scan.finish(hash);
154
+ }
155
+ export function stageCostSnapshot(entry, lines, hash, force = false) {
156
+ stageParsedCostSnapshot(entry, parseCostSnapshot(lines, hash, entry.token_observed), force);
157
+ }
158
+ export function stageParsedCostSnapshot(entry, snapshot, force = false) {
159
+ if (snapshot && (force || snapshot.fingerprint !== (object(entry.api_snapshot) ? entry.api_snapshot.fingerprint : null)))
160
+ entry._pending_api_snapshot = snapshot;
161
+ }
162
+ export function stageSubagentDelta(entry, lines) {
163
+ const pending = entry._pending_api_snapshot;
164
+ if (!object(pending) || !object(pending._snapshot_ts))
165
+ return;
166
+ const post = (pending._post_ids ??= dictionary());
167
+ for (const row of lines) {
168
+ if (!object(row) || row.type !== 'assistant')
169
+ continue;
170
+ const time = timestamp(row.timestamp);
171
+ if (time === null)
172
+ continue;
173
+ const keys = recordEntries(pending._snapshot_ts).filter(([, value]) => numeric(value) !== null && time > numeric(value)).map(([key]) => key);
174
+ if (keys.length)
175
+ mergeUsageFields(post, parseUsage([row]), keys);
176
+ }
177
+ }
178
+ export function aggregateVisible(entry) {
179
+ const totals = { ...BASE };
180
+ const small = { i: 0, o: 0, cc: 0, cr: 0 };
181
+ const add = (record) => {
182
+ if (object(record))
183
+ for (const key of FIELDS) {
184
+ const value = record[key];
185
+ if (typeof value === 'number' && Number.isSafeInteger(value) && value >= 0) {
186
+ if (value > Number.MAX_SAFE_INTEGER - small[key]) {
187
+ // Flush the exact operands BEFORE an unsafe floating sum.
188
+ totals[key] += BigInt(small[key]);
189
+ small[key] = value;
190
+ }
191
+ else
192
+ small[key] += value;
193
+ }
194
+ else
195
+ totals[key] += usageInt(value);
196
+ }
197
+ };
198
+ add(entry.base ?? BASE);
199
+ if (object(entry.ids))
200
+ forEachRecord(entry.ids, add);
201
+ for (const key of FIELDS)
202
+ totals[key] += BigInt(small[key]);
203
+ return totals;
204
+ }
205
+ export function visibleTotals(entry) { const raw = aggregateVisible(entry); return { hit: raw.cr, miss: raw.i + raw.cc, out: raw.o }; }
206
+ export function displayTotals(entry, visible = visibleTotals(entry)) {
207
+ const { api_snapshot: snapshot, api_visible_anchor: anchor } = entry;
208
+ if (!object(snapshot) || !object(anchor))
209
+ return visible;
210
+ return Object.fromEntries(recordKeys(TOKEN_FIELDS).map(key => [key, hasUsage(snapshot, [key]) ? usageInt(snapshot[key]) + maxZero(usageInt(visible[key]) - usageInt(anchor[key])) : visible[key]]));
211
+ }
212
+ function maxZero(value) { return value > 0n ? value : 0n; }
213
+ export function acceptPending(entry, visible) {
214
+ const pending = entry._pending_api_snapshot;
215
+ delete entry._pending_api_snapshot;
216
+ if (!object(pending))
217
+ return false;
218
+ const post = visibleTotals({ base: { ...BASE }, ids: object(pending._post_ids) ? pending._post_ids : {} }), candidate = {};
219
+ for (const key of recordKeys(TOKEN_FIELDS))
220
+ if (hasUsage(pending, [key]))
221
+ candidate[key] = usageInt(pending[key]) + post[key];
222
+ const current = entry.api_snapshot;
223
+ if (object(current)) {
224
+ const displayed = displayTotals(entry, visible);
225
+ if (recordKeys(candidate).some(key => candidate[key] < displayed[key]))
226
+ return false;
227
+ }
228
+ const snapshot = object(current) ? { ...current } : {};
229
+ snapshot.fingerprint = pending.fingerprint;
230
+ const anchor = object(entry.api_visible_anchor) ? { ...entry.api_visible_anchor } : {};
231
+ for (const key of recordKeys(candidate)) {
232
+ snapshot[key] = pending[key];
233
+ anchor[key] = maxZero(visible[key] - post[key]);
234
+ }
235
+ entry.api_snapshot = snapshot;
236
+ entry.api_visible_anchor = anchor;
237
+ return true;
238
+ }
239
+ export function collapseIds(entry) {
240
+ const ids = recordKeys(entry.ids);
241
+ if (ids.length <= MAX_IDS)
242
+ return false;
243
+ for (const id of ids.slice(0, Math.floor(ids.length / 2))) {
244
+ const row = entry.ids[id];
245
+ delete entry.ids[id];
246
+ for (const key of FIELDS)
247
+ entry.base[key] = usageInt(entry.base[key]) + usageInt(row[key]);
248
+ }
249
+ return true;
250
+ }
251
+ export function sessionTokenCounts(entry) {
252
+ if (!object(entry))
253
+ return null;
254
+ const observed = tokenObservations(entry);
255
+ if (!observed.input && !observed.output)
256
+ return null;
257
+ const raw = object(entry._raw_token_counts) && recordKeys(entry._raw_token_counts).sort().join(',') === 'hit,miss,out' ? entry._raw_token_counts : displayTotals(entry);
258
+ if (recordValues(raw).some(value => numeric(value) === null || !Number.isFinite(numeric(value)) || numeric(value) < 0))
259
+ return null;
260
+ const hit = observed.input ? usageInt(raw.hit) : null, miss = observed.input ? usageInt(raw.miss) : null, out = observed.output ? usageInt(raw.out) : null;
261
+ return { hit, miss, out, input_tokens: hit === null || miss === null ? null : hit + miss };
262
+ }
263
+ //# sourceMappingURL=usage.js.map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record<string, unknown>;
4
+ export declare function dictionary<T = unknown>(entries?: Iterable<readonly [
5
+ string,
6
+ T
7
+ ]>): Record<string, T>;
8
+ export declare function own<T>(data: Record<string, T>, key: unknown): T | undefined;
9
+ export declare function int(value: unknown, strict?: boolean): bigint | null;
10
+ export declare function numeric(value: unknown): number | null;
11
+ export declare function truth(value: unknown): boolean;
12
+ export declare function string(value: unknown): string;
13
+ export declare function maxInt(values: Iterable<bigint>, fallback?: bigint): bigint;
14
+ export declare function compareInt(a: bigint, b: bigint): number;
15
+ export declare function maxNumber(a: unknown, b: unknown): unknown;
16
+ export declare function minNumber(a: unknown, b: unknown): unknown;
17
+ export declare function compareNumbers(a: unknown, b: unknown): number;
18
+ export declare function multiplyInteger(value: unknown, factor: bigint): bigint | number;