@blogic-cz/agent-tools 0.16.0 → 0.17.1

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 (206) hide show
  1. package/dist/audit-tool/index.d.ts +3 -0
  2. package/dist/audit-tool/index.d.ts.map +1 -0
  3. package/dist/az-tool/build.d.ts +47 -0
  4. package/dist/az-tool/build.d.ts.map +1 -0
  5. package/dist/az-tool/config.d.ts +13 -0
  6. package/dist/az-tool/config.d.ts.map +1 -0
  7. package/dist/az-tool/errors.d.ts +43 -0
  8. package/dist/az-tool/errors.d.ts.map +1 -0
  9. package/dist/az-tool/extract-option-value.d.ts +2 -0
  10. package/dist/az-tool/extract-option-value.d.ts.map +1 -0
  11. package/dist/az-tool/index.d.ts +3 -0
  12. package/dist/az-tool/index.d.ts.map +1 -0
  13. package/dist/az-tool/security.d.ts +4 -0
  14. package/dist/az-tool/security.d.ts.map +1 -0
  15. package/dist/az-tool/service.d.ts +15 -0
  16. package/dist/az-tool/service.d.ts.map +1 -0
  17. package/dist/az-tool/transformers.d.ts +10 -0
  18. package/dist/az-tool/transformers.d.ts.map +1 -0
  19. package/dist/az-tool/types.d.ts +64 -0
  20. package/dist/az-tool/types.d.ts.map +1 -0
  21. package/dist/config/index.d.ts +4 -0
  22. package/dist/config/index.d.ts.map +1 -0
  23. package/dist/config/loader.d.ts +22 -0
  24. package/dist/config/loader.d.ts.map +1 -0
  25. package/dist/config/types.d.ts +189 -0
  26. package/dist/config/types.d.ts.map +1 -0
  27. package/dist/credential-guard/claude-hook.d.ts +13 -0
  28. package/dist/credential-guard/claude-hook.d.ts.map +1 -0
  29. package/dist/credential-guard/index.d.ts +77 -0
  30. package/dist/credential-guard/index.d.ts.map +1 -0
  31. package/dist/db-tool/config-service.d.ts +25 -0
  32. package/dist/db-tool/config-service.d.ts.map +1 -0
  33. package/dist/db-tool/errors.d.ts +41 -0
  34. package/dist/db-tool/errors.d.ts.map +1 -0
  35. package/dist/db-tool/index.d.ts +3 -0
  36. package/dist/db-tool/index.d.ts.map +1 -0
  37. package/dist/db-tool/schema.d.ts +21 -0
  38. package/dist/db-tool/schema.d.ts.map +1 -0
  39. package/dist/db-tool/security.d.ts +23 -0
  40. package/dist/db-tool/security.d.ts.map +1 -0
  41. package/dist/db-tool/service.d.ts +18 -0
  42. package/dist/db-tool/service.d.ts.map +1 -0
  43. package/dist/db-tool/sql-client.d.ts +24 -0
  44. package/dist/db-tool/sql-client.d.ts.map +1 -0
  45. package/dist/db-tool/transformers.d.ts +10 -0
  46. package/dist/db-tool/transformers.d.ts.map +1 -0
  47. package/dist/db-tool/types.d.ts +37 -0
  48. package/dist/db-tool/types.d.ts.map +1 -0
  49. package/dist/gh-tool/branch.d.ts +18 -0
  50. package/dist/gh-tool/branch.d.ts.map +1 -0
  51. package/dist/gh-tool/config.d.ts +7 -0
  52. package/dist/gh-tool/config.d.ts.map +1 -0
  53. package/dist/gh-tool/errors.d.ts +51 -0
  54. package/dist/gh-tool/errors.d.ts.map +1 -0
  55. package/dist/gh-tool/index.d.ts +3 -0
  56. package/dist/gh-tool/index.d.ts.map +1 -0
  57. package/dist/gh-tool/issue/commands.d.ts +68 -0
  58. package/dist/gh-tool/issue/commands.d.ts.map +1 -0
  59. package/dist/gh-tool/issue/core.d.ts +82 -0
  60. package/dist/gh-tool/issue/core.d.ts.map +1 -0
  61. package/dist/gh-tool/issue/index.d.ts +3 -0
  62. package/dist/gh-tool/issue/index.d.ts.map +1 -0
  63. package/dist/gh-tool/issue/triage.d.ts +89 -0
  64. package/dist/gh-tool/issue/triage.d.ts.map +1 -0
  65. package/dist/gh-tool/pr/commands.d.ts +384 -0
  66. package/dist/gh-tool/pr/commands.d.ts.map +1 -0
  67. package/dist/gh-tool/pr/core.d.ts +236 -0
  68. package/dist/gh-tool/pr/core.d.ts.map +1 -0
  69. package/dist/gh-tool/pr/helpers.d.ts +27 -0
  70. package/dist/gh-tool/pr/helpers.d.ts.map +1 -0
  71. package/dist/gh-tool/pr/index.d.ts +2 -0
  72. package/dist/gh-tool/pr/index.d.ts.map +1 -0
  73. package/dist/gh-tool/pr/review.d.ts +90 -0
  74. package/dist/gh-tool/pr/review.d.ts.map +1 -0
  75. package/dist/gh-tool/release.d.ts +52 -0
  76. package/dist/gh-tool/release.d.ts.map +1 -0
  77. package/dist/gh-tool/repo.d.ts +21 -0
  78. package/dist/gh-tool/repo.d.ts.map +1 -0
  79. package/dist/gh-tool/service.d.ts +25 -0
  80. package/dist/gh-tool/service.d.ts.map +1 -0
  81. package/dist/gh-tool/text-input.d.ts +22 -0
  82. package/dist/gh-tool/text-input.d.ts.map +1 -0
  83. package/dist/gh-tool/types.d.ts +271 -0
  84. package/dist/gh-tool/types.d.ts.map +1 -0
  85. package/dist/gh-tool/workflow.d.ts +157 -0
  86. package/dist/gh-tool/workflow.d.ts.map +1 -0
  87. package/dist/index.d.ts +4 -0
  88. package/dist/index.d.ts.map +1 -0
  89. package/dist/k8s-tool/context.d.ts +26 -0
  90. package/dist/k8s-tool/context.d.ts.map +1 -0
  91. package/dist/k8s-tool/errors.d.ts +43 -0
  92. package/dist/k8s-tool/errors.d.ts.map +1 -0
  93. package/dist/k8s-tool/index.d.ts +3 -0
  94. package/dist/k8s-tool/index.d.ts.map +1 -0
  95. package/dist/k8s-tool/profile.d.ts +3 -0
  96. package/dist/k8s-tool/profile.d.ts.map +1 -0
  97. package/dist/k8s-tool/security.d.ts +14 -0
  98. package/dist/k8s-tool/security.d.ts.map +1 -0
  99. package/dist/k8s-tool/service.d.ts +16 -0
  100. package/dist/k8s-tool/service.d.ts.map +1 -0
  101. package/dist/k8s-tool/transformers.d.ts +23 -0
  102. package/dist/k8s-tool/transformers.d.ts.map +1 -0
  103. package/dist/k8s-tool/types.d.ts +13 -0
  104. package/dist/k8s-tool/types.d.ts.map +1 -0
  105. package/dist/logs-tool/errors.d.ts +40 -0
  106. package/dist/logs-tool/errors.d.ts.map +1 -0
  107. package/dist/logs-tool/index.d.ts +21 -0
  108. package/dist/logs-tool/index.d.ts.map +1 -0
  109. package/dist/logs-tool/service.d.ts +17 -0
  110. package/dist/logs-tool/service.d.ts.map +1 -0
  111. package/dist/logs-tool/transformers.d.ts +2 -0
  112. package/dist/logs-tool/transformers.d.ts.map +1 -0
  113. package/dist/logs-tool/types.d.ts +39 -0
  114. package/dist/logs-tool/types.d.ts.map +1 -0
  115. package/dist/observability-tool/errors.d.ts +8 -0
  116. package/dist/observability-tool/errors.d.ts.map +1 -0
  117. package/dist/observability-tool/index.d.ts +3 -0
  118. package/dist/observability-tool/index.d.ts.map +1 -0
  119. package/dist/observability-tool/logs.d.ts +22 -0
  120. package/dist/observability-tool/logs.d.ts.map +1 -0
  121. package/dist/observability-tool/metrics.d.ts +3 -0
  122. package/dist/observability-tool/metrics.d.ts.map +1 -0
  123. package/dist/observability-tool/shared.d.ts +18 -0
  124. package/dist/observability-tool/shared.d.ts.map +1 -0
  125. package/dist/observability-tool/trace.d.ts +3 -0
  126. package/dist/observability-tool/trace.d.ts.map +1 -0
  127. package/dist/observability-tool/types.d.ts +171 -0
  128. package/dist/observability-tool/types.d.ts.map +1 -0
  129. package/dist/session-tool/claude-code.d.ts +46 -0
  130. package/dist/session-tool/claude-code.d.ts.map +1 -0
  131. package/dist/session-tool/codex.d.ts +44 -0
  132. package/dist/session-tool/codex.d.ts.map +1 -0
  133. package/dist/session-tool/config.d.ts +29 -0
  134. package/dist/session-tool/config.d.ts.map +1 -0
  135. package/dist/session-tool/errors.d.ts +27 -0
  136. package/dist/session-tool/errors.d.ts.map +1 -0
  137. package/dist/session-tool/index.d.ts +13 -0
  138. package/dist/session-tool/index.d.ts.map +1 -0
  139. package/dist/session-tool/pi.d.ts +40 -0
  140. package/dist/session-tool/pi.d.ts.map +1 -0
  141. package/dist/session-tool/service.d.ts +18 -0
  142. package/dist/session-tool/service.d.ts.map +1 -0
  143. package/dist/session-tool/summaries.d.ts +5 -0
  144. package/dist/session-tool/summaries.d.ts.map +1 -0
  145. package/dist/session-tool/types.d.ts +38 -0
  146. package/dist/session-tool/types.d.ts.map +1 -0
  147. package/dist/shared/audit.d.ts +40 -0
  148. package/dist/shared/audit.d.ts.map +1 -0
  149. package/dist/shared/binary-preflight.d.ts +27 -0
  150. package/dist/shared/binary-preflight.d.ts.map +1 -0
  151. package/dist/shared/bun.d.ts +4 -0
  152. package/dist/shared/bun.d.ts.map +1 -0
  153. package/dist/shared/cli.d.ts +18 -0
  154. package/dist/shared/cli.d.ts.map +1 -0
  155. package/dist/shared/env-template.d.ts +9 -0
  156. package/dist/shared/env-template.d.ts.map +1 -0
  157. package/dist/shared/error-renderer.d.ts +4 -0
  158. package/dist/shared/error-renderer.d.ts.map +1 -0
  159. package/dist/shared/exec.d.ts +30 -0
  160. package/dist/shared/exec.d.ts.map +1 -0
  161. package/dist/shared/format.d.ts +7 -0
  162. package/dist/shared/format.d.ts.map +1 -0
  163. package/dist/shared/index.d.ts +12 -0
  164. package/dist/shared/index.d.ts.map +1 -0
  165. package/dist/shared/k8s-probe.d.ts +11 -0
  166. package/dist/shared/k8s-probe.d.ts.map +1 -0
  167. package/dist/shared/log-transform.d.ts +2 -0
  168. package/dist/shared/log-transform.d.ts.map +1 -0
  169. package/dist/shared/path.d.ts +2 -0
  170. package/dist/shared/path.d.ts.map +1 -0
  171. package/dist/shared/prerequisites/config.d.ts +6 -0
  172. package/dist/shared/prerequisites/config.d.ts.map +1 -0
  173. package/dist/shared/prerequisites/driver-commands.d.ts +19 -0
  174. package/dist/shared/prerequisites/driver-commands.d.ts.map +1 -0
  175. package/dist/shared/prerequisites/errors.d.ts +10 -0
  176. package/dist/shared/prerequisites/errors.d.ts.map +1 -0
  177. package/dist/shared/prerequisites/guardian-entry.d.ts +2 -0
  178. package/dist/shared/prerequisites/guardian-entry.d.ts.map +1 -0
  179. package/dist/shared/prerequisites/guardian.d.ts +41 -0
  180. package/dist/shared/prerequisites/guardian.d.ts.map +1 -0
  181. package/dist/shared/prerequisites/index.d.ts +6 -0
  182. package/dist/shared/prerequisites/index.d.ts.map +1 -0
  183. package/dist/shared/prerequisites/runtime.d.ts +26 -0
  184. package/dist/shared/prerequisites/runtime.d.ts.map +1 -0
  185. package/dist/shared/prerequisites/store.d.ts +99 -0
  186. package/dist/shared/prerequisites/store.d.ts.map +1 -0
  187. package/dist/shared/prerequisites/types.d.ts +39 -0
  188. package/dist/shared/prerequisites/types.d.ts.map +1 -0
  189. package/dist/shared/prerequisites/vpn.d.ts +5 -0
  190. package/dist/shared/prerequisites/vpn.d.ts.map +1 -0
  191. package/dist/shared/schema-dump.d.ts +27 -0
  192. package/dist/shared/schema-dump.d.ts.map +1 -0
  193. package/dist/shared/throttle.d.ts +17 -0
  194. package/dist/shared/throttle.d.ts.map +1 -0
  195. package/dist/shared/transform.d.ts +49 -0
  196. package/dist/shared/transform.d.ts.map +1 -0
  197. package/dist/shared/types.d.ts +30 -0
  198. package/dist/shared/types.d.ts.map +1 -0
  199. package/package.json +77 -20
  200. package/src/az-tool/service.ts +30 -23
  201. package/src/k8s-tool/context.ts +73 -0
  202. package/src/k8s-tool/service.ts +34 -62
  203. package/src/logs-tool/service.ts +78 -87
  204. package/src/shared/bun.ts +0 -7
  205. package/src/shared/exec.ts +58 -4
  206. package/src/shared/index.ts +2 -2
@@ -0,0 +1,171 @@
1
+ import { Schema } from "effect";
2
+ export type ObservabilityEnvConfig = {
3
+ url: string;
4
+ token?: string;
5
+ prometheusUid: string;
6
+ lokiUid: string;
7
+ /** Undefined when the Grafana instance has no Tempo datasource (e.g. Percona PMM). */
8
+ tempoUid?: string;
9
+ };
10
+ export type LogLine = {
11
+ readonly timestamp: string;
12
+ readonly line: string;
13
+ readonly body?: string;
14
+ readonly severity?: string;
15
+ readonly attributes?: Record<string, unknown>;
16
+ readonly labels: Record<string, string>;
17
+ };
18
+ export type StructuredLogLine = {
19
+ readonly body?: string;
20
+ readonly severity?: string;
21
+ readonly attributes?: Record<string, unknown>;
22
+ };
23
+ export type GrafanaDatasource = {
24
+ uid: string;
25
+ name: string;
26
+ type: string;
27
+ url?: string;
28
+ };
29
+ export type OtlpAnyValue = {
30
+ readonly stringValue?: string;
31
+ readonly boolValue?: boolean;
32
+ readonly intValue?: number | string;
33
+ readonly doubleValue?: number;
34
+ readonly arrayValue?: {
35
+ readonly values?: readonly OtlpAnyValue[];
36
+ };
37
+ readonly kvlistValue?: {
38
+ readonly values?: ReadonlyArray<{
39
+ readonly key: string;
40
+ readonly value?: OtlpAnyValue;
41
+ }>;
42
+ };
43
+ };
44
+ export type OtlpAttribute = {
45
+ readonly key: string;
46
+ readonly value?: OtlpAnyValue;
47
+ };
48
+ export type TempoTraceResponse = {
49
+ readonly batches?: ReadonlyArray<{
50
+ readonly resource?: {
51
+ readonly attributes?: ReadonlyArray<OtlpAttribute>;
52
+ };
53
+ readonly scopeSpans?: ReadonlyArray<{
54
+ readonly scope?: {
55
+ readonly name?: string;
56
+ };
57
+ readonly spans?: ReadonlyArray<{
58
+ readonly attributes?: ReadonlyArray<OtlpAttribute>;
59
+ readonly endTimeUnixNano?: string;
60
+ readonly kind?: string | number;
61
+ readonly name?: string;
62
+ readonly parentSpanId?: string;
63
+ readonly spanId?: string;
64
+ readonly startTimeUnixNano?: string;
65
+ readonly status?: {
66
+ readonly code?: string | number;
67
+ readonly message?: string;
68
+ };
69
+ readonly traceId?: string;
70
+ }>;
71
+ }>;
72
+ }>;
73
+ };
74
+ export type FlattenedSpan = {
75
+ readonly serviceName: string;
76
+ readonly scopeName?: string;
77
+ readonly name: string;
78
+ readonly kind?: string | number;
79
+ readonly traceId?: string;
80
+ readonly spanId?: string;
81
+ readonly parentSpanId?: string;
82
+ readonly startTimeUnixNano?: string;
83
+ readonly endTimeUnixNano?: string;
84
+ readonly durationMs?: number;
85
+ readonly statusCode?: string | number;
86
+ readonly statusMessage?: string;
87
+ readonly isError: boolean;
88
+ readonly attributes: Record<string, unknown>;
89
+ readonly resourceAttributes: Record<string, unknown>;
90
+ };
91
+ export type TraceSummary = {
92
+ readonly traceId: string;
93
+ readonly spanCount: number;
94
+ readonly serviceCount: number;
95
+ readonly services: string[];
96
+ readonly errorSpanCount: number;
97
+ readonly rootSpans: FlattenedSpan[];
98
+ readonly totalDurationMs?: number;
99
+ readonly startedAtUnixNano?: string;
100
+ readonly endedAtUnixNano?: string;
101
+ };
102
+ export type TempoSearchResponse = {
103
+ readonly traces?: ReadonlyArray<{
104
+ readonly traceID?: string;
105
+ readonly rootServiceName?: string;
106
+ readonly rootTraceName?: string;
107
+ readonly startTimeUnixNano?: string;
108
+ readonly durationMs?: number;
109
+ readonly spanSets?: ReadonlyArray<{
110
+ readonly spans?: ReadonlyArray<{
111
+ readonly spanID?: string;
112
+ readonly startTimeUnixNano?: string;
113
+ readonly durationNanos?: string;
114
+ readonly attributes?: ReadonlyArray<OtlpAttribute>;
115
+ }>;
116
+ readonly matched?: number;
117
+ }>;
118
+ }>;
119
+ readonly metrics?: Record<string, unknown>;
120
+ };
121
+ export declare const IdKind: Schema.Literals<readonly ["trace_id", "span_id"]>;
122
+ export type IdKind = typeof IdKind.Type;
123
+ export declare const ResolutionVia: Schema.Literals<readonly ["direct_trace_id", "span_search"]>;
124
+ export type ResolutionVia = typeof ResolutionVia.Type;
125
+ export type ParsedId = {
126
+ readonly rawId: string;
127
+ readonly normalizedId: string;
128
+ readonly kind: IdKind;
129
+ };
130
+ export type SearchWindow = {
131
+ readonly start: string;
132
+ readonly end: string;
133
+ };
134
+ export type SpanResolution = {
135
+ readonly via: ResolutionVia;
136
+ readonly resolvedTraceId: string;
137
+ readonly searchedSpanId?: string;
138
+ readonly focusSpan?: FlattenedSpan;
139
+ readonly attemptedWindows?: ReadonlyArray<SearchWindow>;
140
+ readonly usedWindow?: SearchWindow;
141
+ };
142
+ export type DsQueryOpts = {
143
+ instant?: boolean;
144
+ from?: string;
145
+ to?: string;
146
+ maxLines?: number;
147
+ intervalMs?: number;
148
+ maxDataPoints?: number;
149
+ step?: number;
150
+ };
151
+ export type DsQueryResponse = {
152
+ results: {
153
+ A: {
154
+ status?: number;
155
+ frames?: Array<{
156
+ schema: {
157
+ fields: Array<{
158
+ name: string;
159
+ type?: string;
160
+ labels?: Record<string, string>;
161
+ }>;
162
+ };
163
+ data: {
164
+ values: unknown[][];
165
+ };
166
+ }>;
167
+ error?: string;
168
+ };
169
+ };
170
+ };
171
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/observability-tool/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,MAAM,MAAM,sBAAsB,GAAG;IACnC,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,sFAAsF;IACtF,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,OAAO,GAAG;IACpB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC9C,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC/C,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG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AAC;CACpC,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG;IAC5B,OAAO,EAAE;QACP,CAAC,EAAE;YACD,MAAM,CAAC,EAAE,MAAM,CAAC;YAChB,MAAM,CAAC,EAAE,KAAK,CAAC;gBACb,MAAM,EAAE;oBACN,MAAM,EAAE,KAAK,CAAC;wBACZ,IAAI,EAAE,MAAM,CAAC;wBACb,IAAI,CAAC,EAAE,MAAM,CAAC;wBACd,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;qBACjC,CAAC,CAAC;iBACJ,CAAC;gBACF,IAAI,EAAE;oBAAE,MAAM,EAAE,OAAO,EAAE,EAAE,CAAA;iBAAE,CAAC;aAC/B,CAAC,CAAC;YACH,KAAK,CAAC,EAAE,MAAM,CAAC;SAChB,CAAC;KACH,CAAC;CACH,CAAC"}
@@ -0,0 +1,46 @@
1
+ import { Effect } from "effect";
2
+ import type { MessageSummary } from "./types";
3
+ import { type SessionError } from "./errors";
4
+ export declare const encodeProjectPath: (dir: string) => string;
5
+ export type ContentBlock = {
6
+ type: "text";
7
+ text: string;
8
+ } | {
9
+ type: "thinking";
10
+ thinking: string;
11
+ } | {
12
+ type: "tool_use";
13
+ id: string;
14
+ name: string;
15
+ input: unknown;
16
+ } | {
17
+ type: "tool_result";
18
+ tool_use_id: string;
19
+ content: string;
20
+ };
21
+ export type ClaudeCodeRecord = {
22
+ type: "summary";
23
+ summary: string;
24
+ } | {
25
+ type: "user";
26
+ timestamp: string;
27
+ uuid: string;
28
+ message: {
29
+ role: "user";
30
+ content: string | ReadonlyArray<ContentBlock>;
31
+ };
32
+ } | {
33
+ type: "assistant";
34
+ timestamp: string;
35
+ uuid: string;
36
+ message: {
37
+ role: "assistant";
38
+ content: ReadonlyArray<ContentBlock>;
39
+ };
40
+ };
41
+ export declare const parseJsonlLine: (line: string) => ClaudeCodeRecord | null;
42
+ export declare const extractTextFromContent: (content: string | ReadonlyArray<ContentBlock>) => string;
43
+ export declare const extractSessionTitle: (records: ReadonlyArray<ClaudeCodeRecord>) => string;
44
+ export declare const getClaudeCodeSessions: (basePath: string, projectDir: string | null) => Effect.Effect<string[], SessionError>;
45
+ export declare const readClaudeCodeMessages: (sessionFiles: string[]) => Effect.Effect<MessageSummary[], SessionError>;
46
+ //# sourceMappingURL=claude-code.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"claude-code.d.ts","sourceRoot":"","sources":["../../src/session-tool/claude-code.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAIhC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9C,OAAO,EAAiD,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAE5F,eAAO,MAAM,iBAAiB,GAAI,KAAK,MAAM,KAAG,MAAwC,CAAC;AAEzF,MAAM,MAAM,YAAY,GACpB;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAC9B;IAAE,IAAI,EAAE,UAAU,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,GACtC;IAAE,IAAI,EAAE,UAAU,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,GAC9D;IAAE,IAAI,EAAE,aAAa,CAAC;IAAC,WAAW,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AAElE,MAAM,MAAM,gBAAgB,GACxB;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,GACpC;IACE,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,GAAG,aAAa,CAAC,YAAY,CAAC,CAAA;KAAE,CAAC;CAC1E,GACD;IACE,IAAI,EAAE,WAAW,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE;QAAE,IAAI,EAAE,WAAW,CAAC;QAAC,OAAO,EAAE,aAAa,CAAC,YAAY,CAAC,CAAA;KAAE,CAAC;CACtE,CAAC;AA8DN,eAAO,MAAM,cAAc,GAAI,MAAM,MAAM,KAAG,gBAAgB,GAAG,IAqChE,CAAC;AAEF,eAAO,MAAM,sBAAsB,GAAI,SAAS,MAAM,GAAG,aAAa,CAAC,YAAY,CAAC,KAAG,MAStF,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAAI,SAAS,aAAa,CAAC,gBAAgB,CAAC,KAAG,MAY9E,CAAC;AAEF,eAAO,MAAM,qBAAqB,GAChC,UAAU,MAAM,EAChB,YAAY,MAAM,GAAG,IAAI,KACxB,MAAM,CAAC,MAAM,CAAC,MAAM,EAAE,EAAE,YAAY,CA0CnC,CAAC;AAeL,eAAO,MAAM,sBAAsB,GACjC,cAAc,MAAM,EAAE,KACrB,MAAM,CAAC,MAAM,CAAC,cAAc,EAAE,EAAE,YAAY,CAuD3C,CAAC"}
@@ -0,0 +1,44 @@
1
+ import { Effect } from "effect";
2
+ import type { MessageSummary } from "./types";
3
+ import { type SessionError } from "./errors";
4
+ export type CodexContentBlock = {
5
+ type: "input_text";
6
+ text: string;
7
+ } | {
8
+ type: "output_text";
9
+ text: string;
10
+ } | {
11
+ type: string;
12
+ text?: string;
13
+ };
14
+ export type CodexRecord = {
15
+ type: "session_meta";
16
+ timestamp: string;
17
+ payload: {
18
+ id: string;
19
+ cwd?: string;
20
+ timestamp?: string;
21
+ };
22
+ } | {
23
+ type: "event_msg";
24
+ timestamp: string;
25
+ payload: {
26
+ type: "thread_name_updated";
27
+ thread_name: string;
28
+ };
29
+ } | {
30
+ type: "response_item";
31
+ timestamp: string;
32
+ payload: {
33
+ type: "message";
34
+ role: "user" | "assistant" | "developer" | string;
35
+ content: ReadonlyArray<CodexContentBlock>;
36
+ };
37
+ };
38
+ export declare const parseCodexLine: (line: string) => CodexRecord | null;
39
+ export declare const extractCodexText: (content: ReadonlyArray<CodexContentBlock>) => string;
40
+ export declare const extractCodexTitle: (records: ReadonlyArray<CodexRecord>) => string;
41
+ export declare const getCodexSessionId: (filePath: string) => string;
42
+ export declare const getCodexSessions: (basePath: string, projectDir: string | null) => Effect.Effect<string[], SessionError>;
43
+ export declare const readCodexMessages: (sessionFiles: string[]) => Effect.Effect<MessageSummary[], SessionError>;
44
+ //# sourceMappingURL=codex.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codex.d.ts","sourceRoot":"","sources":["../../src/session-tool/codex.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9C,OAAO,EAAiD,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAE5F,MAAM,MAAM,iBAAiB,GACzB;IAAE,IAAI,EAAE,YAAY,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GACpC;IAAE,IAAI,EAAE,aAAa,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GACrC;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAEpC,MAAM,MAAM,WAAW,GACn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+ /**
3
+ * Resolves the OpenCode storage base path from config or default.
4
+ * Session storage is global (not per-profile).
5
+ */
6
+ export declare const resolveStoragePath: Effect.Effect<string, undefined, never>;
7
+ /**
8
+ * Resolves the OpenCode messages directory path.
9
+ */
10
+ export declare const resolveMessagesPath: Effect.Effect<string, undefined, never>;
11
+ /**
12
+ * Resolves the OpenCode sessions directory path.
13
+ */
14
+ export declare const resolveSessionsPath: Effect.Effect<string, undefined, never>;
15
+ declare const ResolvedPaths_base: Context.ServiceClass<ResolvedPaths, "@agent-tools/ResolvedPaths", {
16
+ readonly messagesPath: string;
17
+ readonly sessionsPath: string;
18
+ readonly claudeCodePath: string | null;
19
+ readonly codexPath: string | null;
20
+ readonly piPath: string | null;
21
+ }>;
22
+ /**
23
+ * Context tag for resolved paths (cached during effect execution).
24
+ */
25
+ export declare class ResolvedPaths extends ResolvedPaths_base {
26
+ }
27
+ export declare const ResolvedPathsLayer: Layer.Layer<ResolvedPaths, undefined, never>;
28
+ export {};
29
+ //# sourceMappingURL=config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/session-tool/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAC;AAOhD;;;GAGG;AACH,eAAO,MAAM,kBAAkB,yCAQ7B,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,mBAAmB,yCAG9B,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,mBAAmB,yCAG9B,CAAC;;2BAQwB,MAAM;2BACN,MAAM;6BACJ,MAAM,GAAG,IAAI;wBAClB,MAAM,GAAG,IAAI;qBAChB,MAAM,GAAG,IAAI;;AAVlC;;GAEG;AACH,qBAAa,aAAc,SAAQ,kBASF;CAAG;AAEpC,eAAO,MAAM,kBAAkB,8CAa9B,CAAC"}
@@ -0,0 +1,27 @@
1
+ import { Schema } from "effect";
2
+ declare const SessionStorageNotFoundError_base: Schema.Class<SessionStorageNotFoundError, Schema.TaggedStruct<"SessionStorageNotFoundError", {
3
+ readonly message: Schema.String;
4
+ readonly path: Schema.String;
5
+ }>, import("effect/Cause").YieldableError>;
6
+ export declare class SessionStorageNotFoundError extends SessionStorageNotFoundError_base {
7
+ }
8
+ declare const SessionReadError_base: Schema.Class<SessionReadError, Schema.TaggedStruct<"SessionReadError", {
9
+ readonly message: Schema.String;
10
+ readonly source: Schema.String;
11
+ }>, import("effect/Cause").YieldableError>;
12
+ export declare class SessionReadError extends SessionReadError_base {
13
+ }
14
+ declare const SessionConfigError_base: Schema.Class<SessionConfigError, Schema.TaggedStruct<"SessionConfigError", {
15
+ readonly message: Schema.String;
16
+ }>, import("effect/Cause").YieldableError>;
17
+ export declare class SessionConfigError extends SessionConfigError_base {
18
+ }
19
+ declare const SessionParseError_base: Schema.Class<SessionParseError, Schema.TaggedStruct<"SessionParseError", {
20
+ readonly message: Schema.String;
21
+ readonly source: Schema.String;
22
+ }>, import("effect/Cause").YieldableError>;
23
+ export declare class SessionParseError extends SessionParseError_base {
24
+ }
25
+ export type SessionError = SessionReadError | SessionStorageNotFoundError | SessionConfigError | SessionParseError;
26
+ export {};
27
+ //# sourceMappingURL=errors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../src/session-tool/errors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;;;;;AAEhC,qBAAa,2BAA4B,SAAQ,gCAMhD;CAAG;;;;;AAEJ,qBAAa,gBAAiB,SAAQ,qBAGpC;CAAG;;;;AAEL,qBAAa,kBAAmB,SAAQ,uBAKvC;CAAG;;;;;AAEJ,qBAAa,iBAAkB,SAAQ,sBAMtC;CAAG;AAEJ,MAAM,MAAM,YAAY,GACpB,gBAAgB,GAChB,2BAA2B,GAC3B,kBAAkB,GAClB,iBAAiB,CAAC"}
@@ -0,0 +1,13 @@
1
+ #!/usr/bin/env bun
2
+ /**
3
+ * OpenCode Session Tool for Coding Agents
4
+ *
5
+ * Lists, searches, and reads OpenCode session history.
6
+ * Uses current project scope by default, or all projects with --all.
7
+ */
8
+ import { Command } from "effect/unstable/cli";
9
+ import { Effect } from "effect";
10
+ import { ResolvedPaths } from "./config";
11
+ import { SessionService } from "./service";
12
+ export declare const run: (input: ReadonlyArray<string>) => Effect.Effect<void, import("effect/unstable/cli/CliError").CliError, Command.Environment | ResolvedPaths | SessionService>;
13
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/session-tool/index.ts"],"names":[],"mappings":";AAEA;;;;;GAKG;AAEH,OAAO,EAAY,OAAO,EAAQ,MAAM,qBAAqB,CAAC;AAE9D,OAAO,EAAW,MAAM,EAAiB,MAAM,QAAQ,CAAC;AAQxD,OAAO,EAAE,aAAa,EAAsB,MAAM,UAAU,CAAC;AAE7D,OAAO,EAAc,cAAc,EAAiC,MAAM,WAAW,CAAC;AAiTtF,eAAO,MAAM,GAAG,8JAEd,CAAC"}
@@ -0,0 +1,40 @@
1
+ import { Effect } from "effect";
2
+ import type { MessageSummary, SessionSummary } from "./types";
3
+ import { type SessionError } from "./errors";
4
+ export declare const PI_HEADER_MAX_BYTES: number;
5
+ export declare const PI_SUMMARY_HEAD_MAX_BYTES: number;
6
+ export declare const PI_SUMMARY_TAIL_MAX_BYTES: number;
7
+ export type PiContentBlock = {
8
+ type: "text";
9
+ text: string;
10
+ } | {
11
+ type: string;
12
+ [key: string]: unknown;
13
+ };
14
+ export type PiRecord = {
15
+ type: "session";
16
+ id: string;
17
+ timestamp?: string;
18
+ cwd?: string;
19
+ } | {
20
+ type: "message";
21
+ timestamp: string;
22
+ message: {
23
+ role: string;
24
+ content: string | ReadonlyArray<PiContentBlock>;
25
+ };
26
+ };
27
+ export type PiSessionMetadata = SessionSummary & {
28
+ cwd: string | null;
29
+ bytesRead: number;
30
+ parsedLines: number;
31
+ };
32
+ export declare const parsePiLine: (line: string) => PiRecord | null;
33
+ export declare const extractPiText: (content: string | ReadonlyArray<PiContentBlock>) => string;
34
+ export declare const extractPiTitle: (records: ReadonlyArray<PiRecord>) => string;
35
+ export declare const getPiSessionId: (filePath: string) => string;
36
+ export declare const readPiSessionMetadata: (sessionFile: string) => Promise<PiSessionMetadata>;
37
+ export declare const getPiSessions: (basePath: string, projectDir: string | null) => Effect.Effect<string[], SessionError>;
38
+ export declare const readPiSessionSummaries: (sessionFiles: string[]) => Effect.Effect<SessionSummary[], SessionError>;
39
+ export declare const readPiMessages: (sessionFiles: string[]) => Effect.Effect<MessageSummary[], SessionError>;
40
+ //# sourceMappingURL=pi.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pi.d.ts","sourceRoot":"","sources":["../../src/session-tool/pi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAMhC,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9D,OAAO,EAAiD,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAE5F,eAAO,MAAM,mBAAmB,QAAY,CAAC;AAC7C,eAAO,MAAM,yBAAyB,QAAa,CAAC;AACpD,eAAO,MAAM,yBAAyB,QAAa,CAAC;AAGpD,MAAM,MAAM,cAAc,GACtB;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAC9B;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;CAAE,CAAC;AAE7C,MAAM,MAAM,QAAQ,GAChB;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAE,GACjE;IACE,IAAI,EAAE,SAAS,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,GAAG,aAAa,CAAC,cAAc,CAAC,CAAA;KAAE,CAAC;CAC5E,CAAC;AAEN,MAAM,MAAM,iBAAiB,GAAG,cAAc,GAAG;IAC/C,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;CACrB,CAAC;AAoBF,eAAO,MAAM,WAAW,GAAI,MAAM,MAAM,KAAG,QAAQ,GAAG,IA0BrD,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,SAAS,MAAM,GAAG,aAAa,CAAC,cAAc,CAAC,KAAG,MAY/E,CAAC;AAEF,eAAO,MAAM,cAAc,GAAI,SAAS,aAAa,CAAC,QAAQ,CAAC,KAAG,MAUjE,CAAC;AAKF,eAAO,MAAM,cAAc,GAAI,UAAU,MAAM,KAAG,MAIjD,CAAC;AA8CF,eAAO,MAAM,qBAAqB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,iBAAiB,CAqC1F,CAAC;AAoBF,eAAO,MAAM,aAAa,GACxB,UAAU,MAAM,EAChB,YAAY,MAAM,GAAG,IAAI,KACxB,MAAM,CAAC,MAAM,CAAC,MAAM,EAAE,EAAE,YAAY,CAuBnC,CAAC;AAEL,eAAO,MAAM,sBAAsB,GACjC,cAAc,MAAM,EAAE,KACrB,MAAM,CAAC,MAAM,CAAC,cAAc,EAAE,EAAE,YAAY,CAqB3C,CAAC;AAEL,eAAO,MAAM,cAAc,GACzB,cAAc,MAAM,EAAE,KACrB,MAAM,CAAC,MAAM,CAAC,cAAc,EAAE,EAAE,YAAY,CAmD3C,CAAC"}
@@ -0,0 +1,18 @@
1
+ import { Context, Effect, Layer } from "effect";
2
+ import type { MessageSummary, SessionSource, SessionSummary } from "./types";
3
+ import { ResolvedPaths } from "./config";
4
+ import { type SessionError } from "./errors";
5
+ export declare const formatDate: (timestamp: number) => string;
6
+ export declare const truncate: (value: string, maxLen: number) => string;
7
+ declare const SessionService_base: Context.ServiceClass<SessionService, "@agent-tools/SessionService", {
8
+ readonly getSessionsForProject: (projectDir: string | null, sources?: ReadonlySet<SessionSource>) => Effect.Effect<Set<string>, SessionError>;
9
+ readonly getPiSessionSummaries: (filterSessions: Set<string> | null) => Effect.Effect<SessionSummary[], SessionError>;
10
+ readonly getMessageSummaries: (filterSessions: Set<string> | null, sources?: ReadonlySet<SessionSource>) => Effect.Effect<MessageSummary[], SessionError>;
11
+ readonly searchSummaries: (summaries: MessageSummary[], query: string) => MessageSummary[];
12
+ }>;
13
+ export declare class SessionService extends SessionService_base {
14
+ static readonly layer: Layer.Layer<SessionService, never, ResolvedPaths>;
15
+ }
16
+ export declare const SessionServiceLayer: Layer.Layer<SessionService, never, ResolvedPaths>;
17
+ export {};
18
+ //# sourceMappingURL=service.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"service.d.ts","sourceRoot":"","sources":["../../src/session-tool/service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAC;AAIhD,OAAO,KAAK,EAAE,cAAc,EAAe,aAAa,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAO1F,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAiD,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAU5F,eAAO,MAAM,UAAU,GAAI,WAAW,MAAM,KAAG,MAW9C,CAAC;AAEF,eAAO,MAAM,QAAQ,GAAI,OAAO,MAAM,EAAE,QAAQ,MAAM,KAAG,MAMxD,CAAC;;oCA6HkC,CAC9B,UAAU,EAAE,MAAM,GAAG,IAAI,EACzB,OAAO,CAAC,EAAE,WAAW,CAAC,aAAa,CAAC,KACjC,MAAM,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,YAAY,CAAC;oCACb,CAC9B,cAAc,EAAE,GAAG,CAAC,MAAM,CAAC,GAAG,IAAI,KAC/B,MAAM,CAAC,MAAM,CAAC,cAAc,EAAE,EAAE,YAAY,CAAC;kCACpB,CAC5B,cAAc,EAAE,GAAG,CAAC,MAAM,CAAC,GAAG,IAAI,EAClC,OAAO,CAAC,EAAE,WAAW,CAAC,aAAa,CAAC,KACjC,MAAM,CAAC,MAAM,CAAC,cAAc,EAAE,EAAE,YAAY,CAAC;8BACxB,CAAC,SAAS,EAAE,cAAc,EAAE,EAAE,KAAK,EAAE,MAAM,KAAK,cAAc,EAAE;;AAd9F,qBAAa,cAAe,SAAQ,mBAgBF;IAChC,MAAM,CAAC,QAAQ,CAAC,KAAK,oDAsPnB;CACH;AAED,eAAO,MAAM,mBAAmB,mDAAuB,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { MessageSummary, SessionSummary } from "./types";
2
+ export declare const sessionSummariesFromMessages: (summaries: MessageSummary[]) => SessionSummary[];
3
+ export declare const projectSessionFilter: (sessionsBySource: ReadonlyMap<SessionSummary["source"], Set<string>>, source: SessionSummary["source"], allProjects: boolean) => Set<string> | null;
4
+ export declare const sortSessionSummaries: (summaries: SessionSummary[]) => SessionSummary[];
5
+ //# sourceMappingURL=summaries.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"summaries.d.ts","sourceRoot":"","sources":["../../src/session-tool/summaries.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9D,eAAO,MAAM,4BAA4B,GAAI,WAAW,cAAc,EAAE,KAAG,cAAc,EAwBxF,CAAC;AAEF,eAAO,MAAM,oBAAoB,GAC/B,kBAAkB,WAAW,CAAC,cAAc,CAAC,QAAQ,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC,EACpE,QAAQ,cAAc,CAAC,QAAQ,CAAC,EAChC,aAAa,OAAO,KACnB,GAAG,CAAC,MAAM,CAAC,GAAG,IAA0E,CAAC;AAE5F,eAAO,MAAM,oBAAoB,GAAI,WAAW,cAAc,EAAE,KAAG,cAAc,EAO9E,CAAC"}
@@ -0,0 +1,38 @@
1
+ import { Schema } from "effect";
2
+ import type { OutputFormat } from "#shared";
3
+ export type { OutputFormat };
4
+ export type SessionInfo = {
5
+ id: string;
6
+ directory: string;
7
+ projectID: string;
8
+ };
9
+ export declare const SESSION_SOURCES: readonly ["opencode", "claude-code", "codex", "pi"];
10
+ export declare const SessionSourceLiterals: Schema.Literals<readonly ["opencode", "claude-code", "codex", "pi"]>;
11
+ export type SessionSource = (typeof SESSION_SOURCES)[number];
12
+ export declare const ALL_SESSION_SOURCES: ReadonlySet<SessionSource>;
13
+ export type MessageSummary = {
14
+ sessionID: string;
15
+ id: string;
16
+ title: string;
17
+ body: string;
18
+ created: number;
19
+ role: string;
20
+ source: SessionSource;
21
+ };
22
+ export type SessionSummary = {
23
+ sessionID: string;
24
+ title: string;
25
+ createdAt: number;
26
+ updatedAt: number;
27
+ source: SessionSource;
28
+ };
29
+ export type SessionResult = {
30
+ success: boolean;
31
+ data?: unknown;
32
+ error?: string;
33
+ query?: string | null;
34
+ scope?: string;
35
+ count?: number;
36
+ executionTimeMs: number;
37
+ };
38
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/session-tool/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAE5C,YAAY,EAAE,YAAY,EAAE,CAAC;AAE7B,MAAM,MAAM,WAAW,GAAG;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,eAAe,qDAAsD,CAAC;AACnF,eAAO,MAAM,qBAAqB,sEAAmC,CAAC;AACtE,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,eAAe,CAAC,CAAC,MAAM,CAAC,CAAC;AAC7D,eAAO,MAAM,mBAAmB,EAAE,WAAW,CAAC,aAAa,CAA4B,CAAC;AAExF,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,EAAE,MAAM,CAAC;IAClB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,aAAa,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,aAAa,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,eAAe,EAAE,MAAM,CAAC;CACzB,CAAC"}
@@ -0,0 +1,40 @@
1
+ import { Context, Effect, Layer } from "effect";
2
+ export type AuditLogEntry = {
3
+ id: number;
4
+ ts: string;
5
+ tool: string;
6
+ project: string;
7
+ args: string;
8
+ duration: number;
9
+ success: boolean;
10
+ error: string | null;
11
+ exitCode: number | null;
12
+ };
13
+ export type AuditRecord = {
14
+ tool: string;
15
+ project: string;
16
+ args: string;
17
+ duration: number;
18
+ success: boolean;
19
+ error?: string;
20
+ exitCode?: number | null;
21
+ };
22
+ type AuditServiceShape = {
23
+ readonly dbPath: string;
24
+ readonly record: (entry: AuditRecord) => Effect.Effect<void, never, never>;
25
+ readonly listRecent: (limit?: number) => Effect.Effect<readonly AuditLogEntry[], never, never>;
26
+ readonly purgeOlderThanDays: (days: number) => Effect.Effect<number, never, never>;
27
+ };
28
+ type AuditServiceOptions = {
29
+ readonly dbPath?: string;
30
+ readonly retentionDays?: number;
31
+ };
32
+ declare const AuditService_base: Context.ServiceClass<AuditService, "@agent-tools/AuditService", AuditServiceShape>;
33
+ export declare class AuditService extends AuditService_base {
34
+ }
35
+ export declare const resolveAuditDbPath: () => string;
36
+ export declare const makeAuditServiceLayer: (options?: AuditServiceOptions) => Layer.Layer<AuditService, never, never>;
37
+ export declare const AuditServiceLayer: Layer.Layer<AuditService, never, never>;
38
+ export declare const withAudit: <A, E, R>(toolName: string, program: Effect.Effect<A, E, R>) => Effect.Effect<A, E, R | AuditService>;
39
+ export {};
40
+ //# sourceMappingURL=audit.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"audit.d.ts","sourceRoot":"","sources":["../../src/shared/audit.ts"],"names":[],"mappings":"AAKA,OAAO,EAAS,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAC;AAOvD,MAAM,MAAM,aAAa,GAAG;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CACzB,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IAC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: {
2
+ readonly az: {
3
+ readonly tools: "az-tool";
4
+ readonly install: "Install it with `brew install azure-cli` (macOS) or see https://learn.microsoft.com/cli/azure/install-azure-cli.";
5
+ };
6
+ readonly gh: {
7
+ readonly tools: "gh-tool";
8
+ readonly install: "Install it with `brew install gh` (macOS) or see https://cli.github.com/, then run `gh auth login`.";
9
+ };
10
+ readonly git: {
11
+ readonly tools: "gh-tool release and stack commands";
12
+ readonly install: "Install it with `xcode-select --install` (macOS) or see https://git-scm.com/downloads.";
13
+ };
14
+ readonly kubectl: {
15
+ readonly tools: "k8s-tool and db-tool tunnels";
16
+ readonly install: "Install it with `brew install kubectl` (macOS) or see https://kubernetes.io/docs/tasks/tools/.";
17
+ };
18
+ };
19
+ export type RequiredBinary = keyof typeof REQUIRED_BINARIES;
20
+ export type MissingBinary = {
21
+ binary: RequiredBinary;
22
+ message: string;
23
+ hint: string;
24
+ };
25
+ export declare const describeMissingBinary: (binary: RequiredBinary) => MissingBinary;
26
+ export declare const missingBinaryFromSpawnFailure: (binary: string, failure: string) => MissingBinary | undefined;
27
+ //# sourceMappingURL=binary-preflight.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"binary-preflight.d.ts","sourceRoot":"","sources":["../../src/shared/binary-preflight.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;CAqBpB,CAAC;AAEX,MAAM,MAAM,cAAc,GAAG,MAAM,OAAO,iBAAiB,CAAC;AAE5D,MAAM,MAAM,aAAa,GAAG;IAAE,MAAM,EAAE,cAAc,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAItF,eAAO,MAAM,qBAAqB,GAAI,QAAQ,cAAc,KAAG,aAI7D,CAAC;AAEH,eAAO,MAAM,6BAA6B,GACxC,QAAQ,MAAM,EACd,SAAS,MAAM,KACd,aAAa,GAAG,SAGJ,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { CommandOptions, CommandResult } from "./types";
2
+ export declare function expandPath(path: string): string;
3
+ export declare function runCommand(cmd: string[], options?: CommandOptions): Promise<CommandResult>;
4
+ //# sourceMappingURL=bun.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bun.d.ts","sourceRoot":"","sources":["../../src/shared/bun.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAE7D,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAS/C;AAED,wBAAsB,UAAU,CAC9B,GAAG,EAAE,MAAM,EAAE,EACb,OAAO,GAAE,cAAmB,GAC3B,OAAO,CAAC,aAAa,CAAC,CAmCxB"}
@@ -0,0 +1,18 @@
1
+ import type { OutputFormat } from "./types";
2
+ export declare const commonArgOptions: {
3
+ readonly help: {
4
+ readonly type: "boolean";
5
+ readonly short: "h";
6
+ readonly default: false;
7
+ };
8
+ readonly format: {
9
+ readonly type: "string";
10
+ readonly short: "f";
11
+ readonly default: "toon";
12
+ };
13
+ };
14
+ export declare function parseCommonArgs(): {
15
+ format: OutputFormat;
16
+ args: string[];
17
+ } | null;
18
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/shared/cli.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAE5C,eAAO,MAAM,gBAAgB;;;;;;;;;;;CAWnB,CAAC;AAEX,wBAAgB,eAAe,IAAI;IACjC,MAAM,EAAE,YAAY,CAAC;IACrB,IAAI,EAAE,MAAM,EAAE,CAAC;CAChB,GAAG,IAAI,CAiBP"}
@@ -0,0 +1,9 @@
1
+ import { Effect, Schema } from "effect";
2
+ declare const EnvTemplateError_base: Schema.Class<EnvTemplateError, Schema.TaggedStruct<"@agent-tools/EnvTemplateError", {
3
+ readonly envVar: Schema.String;
4
+ }>, import("effect/Cause").YieldableError>;
5
+ export declare class EnvTemplateError extends EnvTemplateError_base {
6
+ }
7
+ export declare const resolveEnvTemplate: (value: string) => Effect.Effect<string, EnvTemplateError, never>;
8
+ export {};
9
+ //# sourceMappingURL=env-template.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"env-template.d.ts","sourceRoot":"","sources":["../../src/shared/env-template.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;;;;AAIxC,qBAAa,gBAAiB,SAAQ,qBAGrC;CAAG;AAEJ,eAAO,MAAM,kBAAkB,mEA4B7B,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { Effect } from "effect";
2
+ import { Cause } from "effect";
3
+ export declare const renderCauseToStderr: (cause: Cause.Cause<unknown>) => Effect.Effect<void>;
4
+ //# sourceMappingURL=error-renderer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"error-renderer.d.ts","sourceRoot":"","sources":["../../src/shared/error-renderer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAErC,OAAO,EAAE,KAAK,EAAW,MAAM,QAAQ,CAAC;AAuDxC,eAAO,MAAM,mBAAmB,GAAI,OAAO,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,KAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CACjD,CAAC"}