@nyte-ai/schema 0.0.0-stage → 0.0.19

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 (148) hide show
  1. package/LICENSE +21 -0
  2. package/THIRD-PARTY-NOTICES.md +866 -0
  3. package/dist/chunks/browser-0byq2fja.js +50 -0
  4. package/dist/chunks/browser-0chm3654.js +125 -0
  5. package/dist/chunks/browser-0g0z3617.js +47 -0
  6. package/dist/chunks/browser-0khex2b1.js +33 -0
  7. package/dist/chunks/browser-0sbkxgkx.js +115 -0
  8. package/dist/chunks/browser-0xr6c36r.js +106 -0
  9. package/dist/chunks/browser-1nqahr9q.js +239 -0
  10. package/dist/chunks/browser-1sfp0bcx.js +73 -0
  11. package/dist/chunks/browser-3exd93gm.js +50 -0
  12. package/dist/chunks/browser-40enyw9r.js +75 -0
  13. package/dist/chunks/browser-4et7qtz3.js +7 -0
  14. package/dist/chunks/browser-6e1madxa.js +83 -0
  15. package/dist/chunks/browser-6yby604e.js +96 -0
  16. package/dist/chunks/browser-7195qf3t.js +14 -0
  17. package/dist/chunks/browser-8ancsy4m.js +118 -0
  18. package/dist/chunks/browser-9ystjh78.js +0 -0
  19. package/dist/chunks/browser-b519jtez.js +102 -0
  20. package/dist/chunks/browser-bg1esaw0.js +82 -0
  21. package/dist/chunks/browser-ebr6k189.js +120 -0
  22. package/dist/chunks/browser-ekbecx9r.js +73 -0
  23. package/dist/chunks/browser-fd3accdr.js +159 -0
  24. package/dist/chunks/browser-g5khdcap.js +170 -0
  25. package/dist/chunks/browser-h5k4hqfq.js +244 -0
  26. package/dist/chunks/browser-h86zs54a.js +65 -0
  27. package/dist/chunks/browser-hp9ze9ga.js +185 -0
  28. package/dist/chunks/browser-hq5q56sf.js +79 -0
  29. package/dist/chunks/browser-j150etqf.js +101 -0
  30. package/dist/chunks/browser-j629a6wa.js +17 -0
  31. package/dist/chunks/browser-jgxe05s4.js +301 -0
  32. package/dist/chunks/browser-k20f6cvv.js +0 -0
  33. package/dist/chunks/browser-m0wzr0g8.js +5 -0
  34. package/dist/chunks/browser-mzfc0v5j.js +58 -0
  35. package/dist/chunks/browser-p691tcac.js +139 -0
  36. package/dist/chunks/browser-pdv675va.js +135 -0
  37. package/dist/chunks/browser-pvfshqyk.js +36 -0
  38. package/dist/chunks/browser-qkxe0fwp.js +6 -0
  39. package/dist/chunks/browser-qncc807c.js +66 -0
  40. package/dist/chunks/browser-r87w64mz.js +32 -0
  41. package/dist/chunks/browser-s2xe7c21.js +82 -0
  42. package/dist/chunks/browser-sgst60b0.js +293 -0
  43. package/dist/chunks/browser-sgwxbek9.js +37 -0
  44. package/dist/chunks/browser-v70eq512.js +215 -0
  45. package/dist/chunks/browser-vzc3r2r3.js +64 -0
  46. package/dist/chunks/browser-xensz05x.js +172 -0
  47. package/dist/chunks/browser-ynj8v9ad.js +35 -0
  48. package/dist/chunks/browser-ypez6s7v.js +52 -0
  49. package/dist/src/browser.d.ts +64 -0
  50. package/dist/src/browser.js +26 -0
  51. package/dist/src/configuration.d.ts +26 -0
  52. package/dist/src/configuration.js +17 -0
  53. package/dist/src/connection.d.ts +189 -0
  54. package/dist/src/connection.js +35 -0
  55. package/dist/src/declaration.d.ts +12 -0
  56. package/dist/src/declaration.js +1 -0
  57. package/dist/src/errors.d.ts +56 -0
  58. package/dist/src/errors.js +23 -0
  59. package/dist/src/events.d.ts +1752 -0
  60. package/dist/src/events.js +36 -0
  61. package/dist/src/files.d.ts +130 -0
  62. package/dist/src/files.js +49 -0
  63. package/dist/src/git.d.ts +280 -0
  64. package/dist/src/git.js +66 -0
  65. package/dist/src/github.d.ts +174 -0
  66. package/dist/src/github.js +31 -0
  67. package/dist/src/heads.d.ts +255 -0
  68. package/dist/src/heads.js +48 -0
  69. package/dist/src/hooks.d.ts +201 -0
  70. package/dist/src/hooks.js +28 -0
  71. package/dist/src/host.d.ts +137 -0
  72. package/dist/src/host.js +49 -0
  73. package/dist/src/ids.d.ts +66 -0
  74. package/dist/src/ids.js +67 -0
  75. package/dist/src/index.d.ts +30 -0
  76. package/dist/src/index.js +783 -0
  77. package/dist/src/jobs.d.ts +152 -0
  78. package/dist/src/jobs.js +34 -0
  79. package/dist/src/json.d.ts +24 -0
  80. package/dist/src/json.js +21 -0
  81. package/dist/src/mcp.d.ts +212 -0
  82. package/dist/src/mcp.js +34 -0
  83. package/dist/src/messages.d.ts +114 -0
  84. package/dist/src/messages.js +28 -0
  85. package/dist/src/model/index.d.ts +6 -0
  86. package/dist/src/model/index.js +61 -0
  87. package/dist/src/model/message.d.ts +178 -0
  88. package/dist/src/model/message.js +7 -0
  89. package/dist/src/model/model.d.ts +154 -0
  90. package/dist/src/model/model.js +11 -0
  91. package/dist/src/model/text.d.ts +6 -0
  92. package/dist/src/model/text.js +10 -0
  93. package/dist/src/model/tool.d.ts +36 -0
  94. package/dist/src/model/tool.js +1 -0
  95. package/dist/src/model/transcript.d.ts +34 -0
  96. package/dist/src/model/transcript.js +37 -0
  97. package/dist/src/model/typed.d.ts +6 -0
  98. package/dist/src/model/typed.js +8 -0
  99. package/dist/src/models.d.ts +198 -0
  100. package/dist/src/models.js +47 -0
  101. package/dist/src/parts.d.ts +364 -0
  102. package/dist/src/parts.js +35 -0
  103. package/dist/src/patch.d.ts +21 -0
  104. package/dist/src/patch.js +11 -0
  105. package/dist/src/plugins.d.ts +36 -0
  106. package/dist/src/plugins.js +9 -0
  107. package/dist/src/primitives.d.ts +83 -0
  108. package/dist/src/primitives.js +26 -0
  109. package/dist/src/runs.d.ts +433 -0
  110. package/dist/src/runs.js +39 -0
  111. package/dist/src/schema.d.ts +14 -0
  112. package/dist/src/schema.js +8 -0
  113. package/dist/src/serial.d.ts +18 -0
  114. package/dist/src/serial.js +39 -0
  115. package/dist/src/sessions.d.ts +578 -0
  116. package/dist/src/sessions.js +74 -0
  117. package/dist/src/store.d.ts +830 -0
  118. package/dist/src/store.js +33 -0
  119. package/dist/src/tools.d.ts +76 -0
  120. package/dist/src/tools.js +24 -0
  121. package/dist/src/views.d.ts +3105 -0
  122. package/dist/src/views.js +50 -0
  123. package/dist/src/wire/base64.d.ts +2 -0
  124. package/dist/src/wire/base64.js +6 -0
  125. package/dist/src/wire/nullable.d.ts +2 -0
  126. package/dist/src/wire/nullable.js +6 -0
  127. package/dist/src/wire/operations/browser.d.ts +535 -0
  128. package/dist/src/wire/operations/browser.js +12 -0
  129. package/dist/src/wire/operations/fields.d.ts +54 -0
  130. package/dist/src/wire/operations/fields.js +30 -0
  131. package/dist/src/wire/operations/files.d.ts +244 -0
  132. package/dist/src/wire/operations/files.js +13 -0
  133. package/dist/src/wire/operations/git.d.ts +513 -0
  134. package/dist/src/wire/operations/git.js +15 -0
  135. package/dist/src/wire/operations/github.d.ts +172 -0
  136. package/dist/src/wire/operations/github.js +12 -0
  137. package/dist/src/wire/operations/host.d.ts +1031 -0
  138. package/dist/src/wire/operations/host.js +27 -0
  139. package/dist/src/wire/operations/index.d.ts +7103 -0
  140. package/dist/src/wire/operations/index.js +40 -0
  141. package/dist/src/wire/operations/session.d.ts +3779 -0
  142. package/dist/src/wire/operations/session.js +25 -0
  143. package/dist/src/wire/operations/workspace.d.ts +842 -0
  144. package/dist/src/wire/operations/workspace.js +24 -0
  145. package/dist/src/workspaces.d.ts +119 -0
  146. package/dist/src/workspaces.js +38 -0
  147. package/package.json +51 -3
  148. package/README.md +0 -3
@@ -0,0 +1,830 @@
1
+ import { Type } from "typebox";
2
+ import type { Decoded, Schema } from "./schema.ts";
3
+ export declare const RefType: Type.TObject<{
4
+ name: Type.TString;
5
+ target: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"object">>, Type.TNull]>;
6
+ revision: Type.TUnsafe<import("./ids.ts").Id<"revision">>;
7
+ }>;
8
+ export type Ref = Decoded<typeof RefType>;
9
+ export declare const RefUpdateType: Type.TObject<{
10
+ name: Type.TString;
11
+ target: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"object">>, Type.TNull]>;
12
+ expect: Type.TOptional<Type.TUnion<[Type.TLiteral<"absent">, Type.TUnsafe<import("./ids.ts").Id<"revision">>]>>;
13
+ events: Type.TOptional<Type.TArray<Type.TUnion<[Type.TObject<{
14
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
15
+ } & {
16
+ kind: Type.TLiteral<"commit">;
17
+ id: Type.TUnsafe<import("./ids.ts").Id<"commit">>;
18
+ parent: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"commit">>, Type.TNull]>;
19
+ run: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"run">>, Type.TNull]>;
20
+ body: Type.TUnion<[Type.TObject<{
21
+ kind: Type.TLiteral<"user">;
22
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
23
+ content: Type.TUnion<[Type.TString, Type.TArray<Type.TUnion<[Type.TObject<{
24
+ kind: Type.TLiteral<"text">;
25
+ text: Type.TString;
26
+ }>, Type.TObject<{
27
+ kind: Type.TLiteral<"file">;
28
+ blob: Type.TUnsafe<import("./ids.ts").Id<"blob">>;
29
+ mime: Type.TString;
30
+ name: Type.TString;
31
+ }>, Type.TObject<{
32
+ kind: Type.TLiteral<"reference">;
33
+ path: Type.TString;
34
+ blob: Type.TOptional<Type.TUnsafe<import("./ids.ts").Id<"blob">>>;
35
+ }>, Type.TObject<{
36
+ kind: Type.TLiteral<"skill">;
37
+ name: Type.TString;
38
+ location: Type.TString;
39
+ }>, Type.TObject<{
40
+ kind: Type.TLiteral<"excerpt">;
41
+ source: Type.TUnion<[Type.TObject<{
42
+ kind: Type.TLiteral<"diff">;
43
+ path: Type.TString;
44
+ side: Type.TEnum<["old", "new"]>;
45
+ start: Type.TNumber;
46
+ end: Type.TNumber;
47
+ }>, Type.TObject<{
48
+ kind: Type.TLiteral<"terminal">;
49
+ command: Type.TOptional<Type.TString>;
50
+ }>, Type.TObject<{
51
+ kind: Type.TLiteral<"browser">;
52
+ url: Type.TString;
53
+ selector: Type.TString;
54
+ }>]>;
55
+ text: Type.TString;
56
+ }>]>>]>;
57
+ source: Type.TUnion<[Type.TObject<{
58
+ kind: Type.TLiteral<"user">;
59
+ }>, Type.TObject<{
60
+ kind: Type.TLiteral<"child">;
61
+ session: Type.TUnsafe<import("./ids.ts").Id<"session">>;
62
+ end: Type.TEnum<["completed", "stopped", "failed"]>;
63
+ }>, Type.TObject<{
64
+ kind: Type.TLiteral<"job">;
65
+ job: Type.TUnsafe<import("./ids.ts").Id<"job">>;
66
+ }>, Type.TObject<{
67
+ kind: Type.TLiteral<"shell">;
68
+ }>, Type.TObject<{
69
+ kind: Type.TLiteral<"action">;
70
+ label: Type.TString;
71
+ command: Type.TOptional<Type.TString>;
72
+ }>]>;
73
+ delivery: Type.TEnum<["steer", "queue", "attach"]>;
74
+ siblings: Type.TArray<Type.TUnsafe<import("./ids.ts").Id<"commit">>>;
75
+ }>, Type.TObject<{
76
+ kind: Type.TLiteral<"part">;
77
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
78
+ }>, Type.TObject<{
79
+ kind: Type.TLiteral<"compaction">;
80
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
81
+ replaces: Type.TArray<Type.TUnsafe<import("./ids.ts").Id<"commit">>>;
82
+ }>, Type.TObject<{
83
+ kind: Type.TLiteral<"branchSummary">;
84
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
85
+ replaces: Type.TArray<Type.TUnsafe<import("./ids.ts").Id<"commit">>>;
86
+ }>]>;
87
+ }>, Type.TObject<{
88
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
89
+ } & {
90
+ kind: Type.TLiteral<"head">;
91
+ from: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"commit">>, Type.TNull]>;
92
+ to: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"commit">>, Type.TNull]>;
93
+ reason: Type.TEnum<["moved", "merged", "created", "removed"]>;
94
+ }>, Type.TObject<{
95
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
96
+ } & {
97
+ kind: Type.TLiteral<"seen">;
98
+ principal: Type.TUnsafe<import("./ids.ts").Id<"principal">>;
99
+ commit: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"commit">>, Type.TNull]>;
100
+ }>, Type.TObject<{
101
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
102
+ } & {
103
+ change: Type.TLiteral<"admitted">;
104
+ content: Type.TUnion<[Type.TString, Type.TArray<Type.TUnion<[Type.TObject<{
105
+ kind: Type.TLiteral<"text">;
106
+ text: Type.TString;
107
+ }>, Type.TObject<{
108
+ kind: Type.TLiteral<"file">;
109
+ blob: Type.TUnsafe<import("./ids.ts").Id<"blob">>;
110
+ mime: Type.TString;
111
+ name: Type.TString;
112
+ }>, Type.TObject<{
113
+ kind: Type.TLiteral<"reference">;
114
+ path: Type.TString;
115
+ blob: Type.TOptional<Type.TUnsafe<import("./ids.ts").Id<"blob">>>;
116
+ }>, Type.TObject<{
117
+ kind: Type.TLiteral<"skill">;
118
+ name: Type.TString;
119
+ location: Type.TString;
120
+ }>, Type.TObject<{
121
+ kind: Type.TLiteral<"excerpt">;
122
+ source: Type.TUnion<[Type.TObject<{
123
+ kind: Type.TLiteral<"diff">;
124
+ path: Type.TString;
125
+ side: Type.TEnum<["old", "new"]>;
126
+ start: Type.TNumber;
127
+ end: Type.TNumber;
128
+ }>, Type.TObject<{
129
+ kind: Type.TLiteral<"terminal">;
130
+ command: Type.TOptional<Type.TString>;
131
+ }>, Type.TObject<{
132
+ kind: Type.TLiteral<"browser">;
133
+ url: Type.TString;
134
+ selector: Type.TString;
135
+ }>]>;
136
+ text: Type.TString;
137
+ }>]>>]>;
138
+ source: Type.TUnion<[Type.TObject<{
139
+ kind: Type.TLiteral<"user">;
140
+ }>, Type.TObject<{
141
+ kind: Type.TLiteral<"child">;
142
+ session: Type.TUnsafe<import("./ids.ts").Id<"session">>;
143
+ end: Type.TEnum<["completed", "stopped", "failed"]>;
144
+ }>, Type.TObject<{
145
+ kind: Type.TLiteral<"job">;
146
+ job: Type.TUnsafe<import("./ids.ts").Id<"job">>;
147
+ }>, Type.TObject<{
148
+ kind: Type.TLiteral<"shell">;
149
+ }>, Type.TObject<{
150
+ kind: Type.TLiteral<"action">;
151
+ label: Type.TString;
152
+ command: Type.TOptional<Type.TString>;
153
+ }>]>;
154
+ delivery: Type.TEnum<["steer", "queue", "attach"]>;
155
+ schedule: Type.TUnion<[Type.TObject<{
156
+ kind: Type.TLiteral<"joined">;
157
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
158
+ }>, Type.TObject<{
159
+ kind: Type.TLiteral<"next-turn">;
160
+ reason: Type.TEnum<["requested", "idle", "run-ended", "configuration"]>;
161
+ }>, Type.TObject<{
162
+ kind: Type.TLiteral<"attached">;
163
+ }>, Type.TObject<{
164
+ kind: Type.TLiteral<"deciding">;
165
+ }>]>;
166
+ covered: Type.TBoolean;
167
+ configuration: Type.TObject<{
168
+ kind: Type.TLiteral<"exact">;
169
+ model: Type.TObject<{
170
+ provider: Type.TString;
171
+ id: Type.TString;
172
+ }>;
173
+ thinking: Type.TEnum<["off", "minimal", "low", "medium", "high", "xhigh", "max"]>;
174
+ agent: Type.TUnion<[Type.TString, Type.TNull]>;
175
+ settings: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
176
+ settingsVersion: Type.TString;
177
+ }>;
178
+ replaced: Type.TUnion<[Type.TObject<{
179
+ previous: Type.TUnsafe<import("./ids.ts").Id<"message">>;
180
+ stopped: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"run">>, Type.TNull]>;
181
+ }>, Type.TNull]>;
182
+ requires: Type.TOptional<Type.TArray<Type.TString>>;
183
+ kind: Type.TLiteral<"input">;
184
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
185
+ }>, Type.TObject<{
186
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
187
+ } & {
188
+ change: Type.TLiteral<"scheduled">;
189
+ schedule: Type.TUnion<[Type.TObject<{
190
+ kind: Type.TLiteral<"joined">;
191
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
192
+ }>, Type.TObject<{
193
+ kind: Type.TLiteral<"next-turn">;
194
+ reason: Type.TEnum<["requested", "idle", "run-ended", "configuration"]>;
195
+ }>, Type.TObject<{
196
+ kind: Type.TLiteral<"attached">;
197
+ }>, Type.TObject<{
198
+ kind: Type.TLiteral<"deciding">;
199
+ }>]>;
200
+ position: Type.TNumber;
201
+ kind: Type.TLiteral<"input">;
202
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
203
+ }>, Type.TObject<{
204
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
205
+ } & {
206
+ change: Type.TLiteral<"landed">;
207
+ commit: Type.TUnsafe<import("./ids.ts").Id<"commit">>;
208
+ run: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"run">>, Type.TNull]>;
209
+ kind: Type.TLiteral<"input">;
210
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
211
+ }>, Type.TObject<{
212
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
213
+ } & {
214
+ change: Type.TLiteral<"withdrawn">;
215
+ kind: Type.TLiteral<"input">;
216
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
217
+ }>, Type.TObject<{
218
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
219
+ } & {
220
+ change: Type.TLiteral<"superseded">;
221
+ by: Type.TUnsafe<import("./ids.ts").Id<"message">>;
222
+ kind: Type.TLiteral<"input">;
223
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
224
+ }>, Type.TObject<{
225
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
226
+ } & {
227
+ change: Type.TLiteral<"started">;
228
+ view: Type.TObject<{
229
+ id: Type.TUnsafe<import("./ids.ts").Id<"run">>;
230
+ head: Type.TUnsafe<import("./ids.ts").Id<"head">>;
231
+ startedAt: Type.TNumber;
232
+ attempt: Type.TNumber;
233
+ configuration: Type.TObject<{
234
+ kind: Type.TLiteral<"exact">;
235
+ model: Type.TObject<{
236
+ provider: Type.TString;
237
+ id: Type.TString;
238
+ }>;
239
+ thinking: Type.TEnum<["off", "minimal", "low", "medium", "high", "xhigh", "max"]>;
240
+ agent: Type.TUnion<[Type.TString, Type.TNull]>;
241
+ settings: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
242
+ settingsVersion: Type.TString;
243
+ }>;
244
+ origin: Type.TUnion<[Type.TObject<{
245
+ kind: Type.TLiteral<"input">;
246
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
247
+ }>, Type.TObject<{
248
+ kind: Type.TLiteral<"continuation">;
249
+ from: Type.TEnum<["child", "job", "wake"]>;
250
+ }>]>;
251
+ }>;
252
+ kind: Type.TLiteral<"run">;
253
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
254
+ }>, Type.TObject<{
255
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
256
+ } & {
257
+ change: Type.TLiteral<"phase">;
258
+ phase: Type.TEnum<["responding", "executing"]>;
259
+ kind: Type.TLiteral<"run">;
260
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
261
+ }>, Type.TObject<{
262
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
263
+ } & {
264
+ change: Type.TLiteral<"waiting">;
265
+ on: Type.TUnion<[Type.TObject<{
266
+ kind: Type.TLiteral<"run">;
267
+ session: Type.TUnsafe<import("./ids.ts").Id<"session">>;
268
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
269
+ deadline: Type.TOptional<Type.TNumber>;
270
+ }>, Type.TObject<{
271
+ kind: Type.TLiteral<"job">;
272
+ job: Type.TUnsafe<import("./ids.ts").Id<"job">>;
273
+ deadline: Type.TOptional<Type.TNumber>;
274
+ }>, Type.TObject<{
275
+ kind: Type.TLiteral<"part">;
276
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
277
+ deadline: Type.TOptional<Type.TNumber>;
278
+ }>, Type.TObject<{
279
+ kind: Type.TLiteral<"timer">;
280
+ until: Type.TNumber;
281
+ deadline: Type.TOptional<Type.TNumber>;
282
+ }>]>;
283
+ kind: Type.TLiteral<"run">;
284
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
285
+ }>, Type.TObject<{
286
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
287
+ } & {
288
+ change: Type.TLiteral<"retrying">;
289
+ attempt: Type.TNumber;
290
+ until: Type.TNumber;
291
+ reason: Type.TString;
292
+ kind: Type.TLiteral<"run">;
293
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
294
+ }>, Type.TObject<{
295
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
296
+ } & {
297
+ change: Type.TLiteral<"stopping">;
298
+ kind: Type.TLiteral<"run">;
299
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
300
+ }>, Type.TObject<{
301
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
302
+ } & {
303
+ change: Type.TLiteral<"ended">;
304
+ end: Type.TUnion<[Type.TObject<{
305
+ kind: Type.TLiteral<"completed">;
306
+ usage: Type.TObject<{
307
+ input: Type.TNumber;
308
+ output: Type.TNumber;
309
+ cacheRead: Type.TNumber;
310
+ cacheWrite: Type.TNumber;
311
+ reasoning: Type.TUnion<[Type.TNumber, Type.TNull]>;
312
+ total: Type.TNumber;
313
+ cost: Type.TObject<{
314
+ input: Type.TNumber;
315
+ output: Type.TNumber;
316
+ cacheRead: Type.TNumber;
317
+ cacheWrite: Type.TNumber;
318
+ total: Type.TNumber;
319
+ }>;
320
+ }>;
321
+ }>, Type.TObject<{
322
+ kind: Type.TLiteral<"stopped">;
323
+ }>, Type.TObject<{
324
+ kind: Type.TLiteral<"failed">;
325
+ failure: Type.TObject<{
326
+ class: Type.TEnum<["rate_limit", "auth", "quota", "context_window", "overloaded", "network", "aborted", "provider", "runner"]>;
327
+ message: Type.TString;
328
+ retryAfterMs: Type.TOptional<Type.TNumber>;
329
+ }>;
330
+ }>]>;
331
+ kind: Type.TLiteral<"run">;
332
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
333
+ }>, Type.TObject<{
334
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
335
+ } & {
336
+ change: Type.TLiteral<"created">;
337
+ partKind: Type.TString;
338
+ placement: Type.TUnion<[Type.TObject<{
339
+ kind: Type.TLiteral<"transcript">;
340
+ role: Type.TEnum<["step", "answer", "note"]>;
341
+ }>, Type.TObject<{
342
+ kind: Type.TLiteral<"modal">;
343
+ }>, Type.TIntersect<[Type.TObject<{
344
+ kind: Type.TString;
345
+ }>, Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>]>]>;
346
+ state: Type.TUnsafe<import("./json.ts").Json>;
347
+ version: Type.TNumber;
348
+ run: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"run">>, Type.TNull]>;
349
+ owner: Type.TUnion<[Type.TString, Type.TNull]>;
350
+ kind: Type.TLiteral<"part">;
351
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
352
+ }>, Type.TObject<{
353
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
354
+ } & {
355
+ change: Type.TLiteral<"updated">;
356
+ state: Type.TUnsafe<import("./json.ts").Json>;
357
+ version: Type.TNumber;
358
+ kind: Type.TLiteral<"part">;
359
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
360
+ }>, Type.TObject<{
361
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
362
+ } & {
363
+ change: Type.TLiteral<"waiting">;
364
+ call: Type.TUnsafe<import("./ids.ts").Id<"call">>;
365
+ kind: Type.TLiteral<"part">;
366
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
367
+ }>, Type.TObject<{
368
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
369
+ } & {
370
+ change: Type.TLiteral<"settled">;
371
+ commit: Type.TUnsafe<import("./ids.ts").Id<"commit">>;
372
+ endedAt: Type.TNumber;
373
+ kind: Type.TLiteral<"part">;
374
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
375
+ }>, Type.TObject<{
376
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
377
+ } & {
378
+ change: Type.TLiteral<"failed">;
379
+ failure: Type.TObject<{
380
+ class: Type.TEnum<["rate_limit", "auth", "quota", "context_window", "overloaded", "network", "aborted", "provider", "runner"]>;
381
+ message: Type.TString;
382
+ retryAfterMs: Type.TOptional<Type.TNumber>;
383
+ }>;
384
+ kind: Type.TLiteral<"part">;
385
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
386
+ }>, Type.TObject<{
387
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
388
+ } & {
389
+ change: Type.TLiteral<"answered">;
390
+ answer: Type.TObject<{
391
+ action: Type.TString;
392
+ input: Type.TUnsafe<import("./json.ts").Json>;
393
+ }>;
394
+ kind: Type.TLiteral<"part">;
395
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
396
+ }>, Type.TObject<{
397
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
398
+ } & {
399
+ change: Type.TLiteral<"closed">;
400
+ kind: Type.TLiteral<"part">;
401
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
402
+ }>, Type.TObject<{
403
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
404
+ } & {
405
+ change: Type.TLiteral<"intent">;
406
+ kind: Type.TLiteral<"call">;
407
+ call: Type.TUnsafe<import("./ids.ts").Id<"call">>;
408
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
409
+ }>, Type.TObject<{
410
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
411
+ } & {
412
+ change: Type.TLiteral<"waiting">;
413
+ on: Type.TUnion<[Type.TObject<{
414
+ kind: Type.TLiteral<"run">;
415
+ session: Type.TUnsafe<import("./ids.ts").Id<"session">>;
416
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
417
+ deadline: Type.TOptional<Type.TNumber>;
418
+ }>, Type.TObject<{
419
+ kind: Type.TLiteral<"job">;
420
+ job: Type.TUnsafe<import("./ids.ts").Id<"job">>;
421
+ deadline: Type.TOptional<Type.TNumber>;
422
+ }>, Type.TObject<{
423
+ kind: Type.TLiteral<"part">;
424
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
425
+ deadline: Type.TOptional<Type.TNumber>;
426
+ }>, Type.TObject<{
427
+ kind: Type.TLiteral<"timer">;
428
+ until: Type.TNumber;
429
+ deadline: Type.TOptional<Type.TNumber>;
430
+ }>]>;
431
+ kind: Type.TLiteral<"call">;
432
+ call: Type.TUnsafe<import("./ids.ts").Id<"call">>;
433
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
434
+ }>, Type.TObject<{
435
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
436
+ } & {
437
+ change: Type.TLiteral<"settled">;
438
+ outcome: Type.TUnion<[Type.TObject<{
439
+ kind: Type.TLiteral<"ok">;
440
+ content: Type.TArray<Type.TUnion<[Type.TObject<{
441
+ kind: Type.TLiteral<"text">;
442
+ text: Type.TString;
443
+ }>, Type.TObject<{
444
+ kind: Type.TLiteral<"file">;
445
+ blob: Type.TUnsafe<import("./ids.ts").Id<"blob">>;
446
+ mime: Type.TString;
447
+ name: Type.TOptional<Type.TString>;
448
+ }>]>>;
449
+ output: Type.TUnsafe<import("./json.ts").Json>;
450
+ parts: Type.TArray<Type.TUnsafe<import("./ids.ts").Id<"part">>>;
451
+ }>, Type.TObject<{
452
+ kind: Type.TLiteral<"failed">;
453
+ message: Type.TString;
454
+ }>, Type.TObject<{
455
+ kind: Type.TLiteral<"interrupted">;
456
+ }>, Type.TObject<{
457
+ kind: Type.TLiteral<"rejected">;
458
+ reason: Type.TString;
459
+ }>, Type.TObject<{
460
+ kind: Type.TLiteral<"stopped">;
461
+ }>]>;
462
+ changes: Type.TUnion<[Type.TObject<{
463
+ added: Type.TNumber;
464
+ removed: Type.TNumber;
465
+ paths: Type.TArray<Type.TString>;
466
+ }>, Type.TNull]>;
467
+ kind: Type.TLiteral<"call">;
468
+ call: Type.TUnsafe<import("./ids.ts").Id<"call">>;
469
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
470
+ }>, Type.TObject<{
471
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
472
+ } & {
473
+ kind: Type.TLiteral<"background">;
474
+ item: Type.TObject<{
475
+ kind: Type.TEnum<["child", "job", "page"]>;
476
+ id: Type.TString;
477
+ title: Type.TString;
478
+ state: Type.TEnum<["working", "waiting", "done", "failed"]>;
479
+ startedBy: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"call">>, Type.TNull]>;
480
+ }>;
481
+ }>, Type.TObject<{
482
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
483
+ } & {
484
+ kind: Type.TLiteral<"configured">;
485
+ selected: Type.TUnion<[Type.TObject<{
486
+ kind: Type.TLiteral<"exact">;
487
+ model: Type.TObject<{
488
+ provider: Type.TString;
489
+ id: Type.TString;
490
+ }>;
491
+ thinking: Type.TEnum<["off", "minimal", "low", "medium", "high", "xhigh", "max"]>;
492
+ agent: Type.TUnion<[Type.TString, Type.TNull]>;
493
+ settings: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
494
+ settingsVersion: Type.TString;
495
+ }>, Type.TNull]>;
496
+ effective: Type.TUnion<[Type.TObject<{
497
+ kind: Type.TLiteral<"exact">;
498
+ model: Type.TObject<{
499
+ provider: Type.TString;
500
+ id: Type.TString;
501
+ }>;
502
+ thinking: Type.TEnum<["off", "minimal", "low", "medium", "high", "xhigh", "max"]>;
503
+ agent: Type.TUnion<[Type.TString, Type.TNull]>;
504
+ settings: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
505
+ settingsVersion: Type.TString;
506
+ }>, Type.TNull]>;
507
+ }>, Type.TObject<{
508
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
509
+ } & {
510
+ kind: Type.TLiteral<"request">;
511
+ usage: Type.TObject<{
512
+ input: Type.TNumber;
513
+ output: Type.TNumber;
514
+ cacheRead: Type.TNumber;
515
+ cacheWrite: Type.TNumber;
516
+ reasoning: Type.TUnion<[Type.TNumber, Type.TNull]>;
517
+ total: Type.TNumber;
518
+ cost: Type.TObject<{
519
+ input: Type.TNumber;
520
+ output: Type.TNumber;
521
+ cacheRead: Type.TNumber;
522
+ cacheWrite: Type.TNumber;
523
+ total: Type.TNumber;
524
+ }>;
525
+ }>;
526
+ context: Type.TObject<{
527
+ tokens: Type.TNumber;
528
+ window: Type.TNumber;
529
+ lastRequest: Type.TUnion<[Type.TObject<{
530
+ input: Type.TNumber;
531
+ output: Type.TNumber;
532
+ cacheRead: Type.TNumber;
533
+ cacheWrite: Type.TNumber;
534
+ reasoning: Type.TUnion<[Type.TNumber, Type.TNull]>;
535
+ total: Type.TNumber;
536
+ cost: Type.TObject<{
537
+ input: Type.TNumber;
538
+ output: Type.TNumber;
539
+ cacheRead: Type.TNumber;
540
+ cacheWrite: Type.TNumber;
541
+ total: Type.TNumber;
542
+ }>;
543
+ }>, Type.TNull]>;
544
+ }>;
545
+ step: Type.TEnum<["assistant", "compaction", "summary", "plugin"]>;
546
+ }>, Type.TObject<{
547
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
548
+ } & {
549
+ kind: Type.TLiteral<"changes">;
550
+ files: Type.TArray<Type.TObject<{
551
+ path: Type.TString;
552
+ status: Type.TEnum<["added", "modified", "deleted", "renamed", "untracked", "conflicted"]>;
553
+ added: Type.TNumber;
554
+ removed: Type.TNumber;
555
+ from: Type.TOptional<Type.TString>;
556
+ }>>;
557
+ }>, Type.TObject<{
558
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
559
+ } & {
560
+ kind: Type.TLiteral<"session">;
561
+ info: Type.TObject<{
562
+ id: Type.TUnsafe<import("./ids.ts").Id<"session">>;
563
+ name: Type.TUnion<[Type.TString, Type.TNull]>;
564
+ parent: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"session">>, Type.TNull]>;
565
+ call: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"call">>, Type.TNull]>;
566
+ workspace: Type.TUnsafe<import("./ids.ts").Id<"workspace">>;
567
+ pinned: Type.TBoolean;
568
+ archived: Type.TBoolean;
569
+ activation: Type.TUnion<[Type.TObject<{
570
+ kind: Type.TLiteral<"active">;
571
+ }>, Type.TObject<{
572
+ kind: Type.TLiteral<"inactive">;
573
+ }>, Type.TObject<{
574
+ kind: Type.TLiteral<"unavailable">;
575
+ reason: Type.TEnum<["unsupported", "unreachable"]>;
576
+ workspace: Type.TUnsafe<import("./ids.ts").Id<"workspace">>;
577
+ }>, Type.TObject<{
578
+ kind: Type.TLiteral<"failed">;
579
+ message: Type.TString;
580
+ }>]>;
581
+ heads: Type.TArray<Type.TObject<{
582
+ name: Type.TUnsafe<import("./ids.ts").Id<"head">>;
583
+ tip: Type.TUnion<[Type.TObject<{
584
+ kind: Type.TLiteral<"start">;
585
+ }>, Type.TObject<{
586
+ kind: Type.TLiteral<"commit">;
587
+ id: Type.TUnsafe<import("./ids.ts").Id<"commit">>;
588
+ }>]>;
589
+ stack: Type.TUnion<[Type.TObject<{
590
+ parent: Type.TUnsafe<import("./ids.ts").Id<"head">>;
591
+ base: Type.TUnion<[Type.TObject<{
592
+ kind: Type.TLiteral<"start">;
593
+ }>, Type.TObject<{
594
+ kind: Type.TLiteral<"commit">;
595
+ id: Type.TUnsafe<import("./ids.ts").Id<"commit">>;
596
+ }>]>;
597
+ stale: Type.TBoolean;
598
+ }>, Type.TNull]>;
599
+ execution: Type.TUnion<[Type.TObject<{
600
+ kind: Type.TLiteral<"idle">;
601
+ lastRun: Type.TUnion<[Type.TObject<{
602
+ id: Type.TUnsafe<import("./ids.ts").Id<"run">>;
603
+ end: Type.TUnion<[Type.TObject<{
604
+ kind: Type.TLiteral<"completed">;
605
+ usage: Type.TObject<{
606
+ input: Type.TNumber;
607
+ output: Type.TNumber;
608
+ cacheRead: Type.TNumber;
609
+ cacheWrite: Type.TNumber;
610
+ reasoning: Type.TUnion<[Type.TNumber, Type.TNull]>;
611
+ total: Type.TNumber;
612
+ cost: Type.TObject<{
613
+ input: Type.TNumber;
614
+ output: Type.TNumber;
615
+ cacheRead: Type.TNumber;
616
+ cacheWrite: Type.TNumber;
617
+ total: Type.TNumber;
618
+ }>;
619
+ }>;
620
+ }>, Type.TObject<{
621
+ kind: Type.TLiteral<"stopped">;
622
+ }>, Type.TObject<{
623
+ kind: Type.TLiteral<"failed">;
624
+ failure: Type.TObject<{
625
+ class: Type.TEnum<["rate_limit", "auth", "quota", "context_window", "overloaded", "network", "aborted", "provider", "runner"]>;
626
+ message: Type.TString;
627
+ retryAfterMs: Type.TOptional<Type.TNumber>;
628
+ }>;
629
+ }>]>;
630
+ endedAt: Type.TNumber;
631
+ }>, Type.TNull]>;
632
+ }>, Type.TObject<{
633
+ kind: Type.TLiteral<"live">;
634
+ run: Type.TObject<{
635
+ id: Type.TUnsafe<import("./ids.ts").Id<"run">>;
636
+ head: Type.TUnsafe<import("./ids.ts").Id<"head">>;
637
+ startedAt: Type.TNumber;
638
+ attempt: Type.TNumber;
639
+ configuration: Type.TObject<{
640
+ kind: Type.TLiteral<"exact">;
641
+ model: Type.TObject<{
642
+ provider: Type.TString;
643
+ id: Type.TString;
644
+ }>;
645
+ thinking: Type.TEnum<["off", "minimal", "low", "medium", "high", "xhigh", "max"]>;
646
+ agent: Type.TUnion<[Type.TString, Type.TNull]>;
647
+ settings: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
648
+ settingsVersion: Type.TString;
649
+ }>;
650
+ origin: Type.TUnion<[Type.TObject<{
651
+ kind: Type.TLiteral<"input">;
652
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
653
+ }>, Type.TObject<{
654
+ kind: Type.TLiteral<"continuation">;
655
+ from: Type.TEnum<["child", "job", "wake"]>;
656
+ }>]>;
657
+ }>;
658
+ phase: Type.TEnum<["responding", "executing"]>;
659
+ stopping: Type.TBoolean;
660
+ }>, Type.TObject<{
661
+ kind: Type.TLiteral<"waiting">;
662
+ run: Type.TObject<{
663
+ id: Type.TUnsafe<import("./ids.ts").Id<"run">>;
664
+ head: Type.TUnsafe<import("./ids.ts").Id<"head">>;
665
+ startedAt: Type.TNumber;
666
+ attempt: Type.TNumber;
667
+ configuration: Type.TObject<{
668
+ kind: Type.TLiteral<"exact">;
669
+ model: Type.TObject<{
670
+ provider: Type.TString;
671
+ id: Type.TString;
672
+ }>;
673
+ thinking: Type.TEnum<["off", "minimal", "low", "medium", "high", "xhigh", "max"]>;
674
+ agent: Type.TUnion<[Type.TString, Type.TNull]>;
675
+ settings: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
676
+ settingsVersion: Type.TString;
677
+ }>;
678
+ origin: Type.TUnion<[Type.TObject<{
679
+ kind: Type.TLiteral<"input">;
680
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
681
+ }>, Type.TObject<{
682
+ kind: Type.TLiteral<"continuation">;
683
+ from: Type.TEnum<["child", "job", "wake"]>;
684
+ }>]>;
685
+ }>;
686
+ on: Type.TUnion<[Type.TObject<{
687
+ kind: Type.TLiteral<"run">;
688
+ session: Type.TUnsafe<import("./ids.ts").Id<"session">>;
689
+ run: Type.TUnsafe<import("./ids.ts").Id<"run">>;
690
+ deadline: Type.TOptional<Type.TNumber>;
691
+ }>, Type.TObject<{
692
+ kind: Type.TLiteral<"job">;
693
+ job: Type.TUnsafe<import("./ids.ts").Id<"job">>;
694
+ deadline: Type.TOptional<Type.TNumber>;
695
+ }>, Type.TObject<{
696
+ kind: Type.TLiteral<"part">;
697
+ part: Type.TUnsafe<import("./ids.ts").Id<"part">>;
698
+ deadline: Type.TOptional<Type.TNumber>;
699
+ }>, Type.TObject<{
700
+ kind: Type.TLiteral<"timer">;
701
+ until: Type.TNumber;
702
+ deadline: Type.TOptional<Type.TNumber>;
703
+ }>]>;
704
+ }>, Type.TObject<{
705
+ kind: Type.TLiteral<"retrying">;
706
+ run: Type.TObject<{
707
+ id: Type.TUnsafe<import("./ids.ts").Id<"run">>;
708
+ head: Type.TUnsafe<import("./ids.ts").Id<"head">>;
709
+ startedAt: Type.TNumber;
710
+ attempt: Type.TNumber;
711
+ configuration: Type.TObject<{
712
+ kind: Type.TLiteral<"exact">;
713
+ model: Type.TObject<{
714
+ provider: Type.TString;
715
+ id: Type.TString;
716
+ }>;
717
+ thinking: Type.TEnum<["off", "minimal", "low", "medium", "high", "xhigh", "max"]>;
718
+ agent: Type.TUnion<[Type.TString, Type.TNull]>;
719
+ settings: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
720
+ settingsVersion: Type.TString;
721
+ }>;
722
+ origin: Type.TUnion<[Type.TObject<{
723
+ kind: Type.TLiteral<"input">;
724
+ message: Type.TUnsafe<import("./ids.ts").Id<"message">>;
725
+ }>, Type.TObject<{
726
+ kind: Type.TLiteral<"continuation">;
727
+ from: Type.TEnum<["child", "job", "wake"]>;
728
+ }>]>;
729
+ }>;
730
+ until: Type.TNumber;
731
+ reason: Type.TString;
732
+ }>]>;
733
+ unread: Type.TBoolean;
734
+ }>>;
735
+ createdAt: Type.TNumber;
736
+ lastActivityAt: Type.TNumber;
737
+ }>;
738
+ }>, Type.TObject<{
739
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
740
+ } & {
741
+ kind: Type.TLiteral<"activation">;
742
+ activation: Type.TUnion<[Type.TObject<{
743
+ kind: Type.TLiteral<"active">;
744
+ }>, Type.TObject<{
745
+ kind: Type.TLiteral<"inactive">;
746
+ }>, Type.TObject<{
747
+ kind: Type.TLiteral<"unavailable">;
748
+ reason: Type.TEnum<["unsupported", "unreachable"]>;
749
+ workspace: Type.TUnsafe<import("./ids.ts").Id<"workspace">>;
750
+ }>, Type.TObject<{
751
+ kind: Type.TLiteral<"failed">;
752
+ message: Type.TString;
753
+ }>]>;
754
+ }>, Type.TObject<{
755
+ head: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"head">>, Type.TNull]>;
756
+ } & {
757
+ kind: Type.TLiteral<"catalog">;
758
+ catalog: Type.TObject<{
759
+ commands: Type.TArray<Type.TObject<{
760
+ name: Type.TString;
761
+ owner: Type.TString;
762
+ side: Type.TEnum<["core", "client"]>;
763
+ title: Type.TString;
764
+ description: Type.TString;
765
+ takesText: Type.TBoolean;
766
+ completes: Type.TBoolean;
767
+ category: Type.TOptional<Type.TString>;
768
+ keywords: Type.TOptional<Type.TArray<Type.TString>>;
769
+ }>>;
770
+ settings: Type.TArray<Type.TObject<{
771
+ id: Type.TString;
772
+ owner: Type.TString;
773
+ scope: Type.TEnum<["host", "session"]>;
774
+ label: Type.TString;
775
+ schema: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
776
+ choices: Type.TUnion<[Type.TArray<Type.TObject<{
777
+ value: Type.TUnsafe<import("./json.ts").Json>;
778
+ label: Type.TString;
779
+ badge: Type.TOptional<Type.TString>;
780
+ }>>, Type.TNull]>;
781
+ value: Type.TUnsafe<import("./json.ts").Json>;
782
+ from: Type.TEnum<["default", "host", "session"]>;
783
+ }>>;
784
+ skills: Type.TArray<Type.TObject<{
785
+ name: Type.TString;
786
+ owner: Type.TString;
787
+ description: Type.TString;
788
+ location: Type.TString;
789
+ }>>;
790
+ agents: Type.TArray<Type.TObject<{
791
+ id: Type.TString;
792
+ owner: Type.TString;
793
+ description: Type.TUnion<[Type.TString, Type.TNull]>;
794
+ model: Type.TUnion<[Type.TObject<{
795
+ provider: Type.TString;
796
+ id: Type.TString;
797
+ }>, Type.TNull]>;
798
+ mode: Type.TEnum<["primary", "subagent", "all"]>;
799
+ }>>;
800
+ tools: Type.TArray<Type.TObject<{
801
+ name: Type.TString;
802
+ owner: Type.TString;
803
+ namespace: Type.TUnion<[Type.TString, Type.TNull]>;
804
+ description: Type.TString;
805
+ parameters: Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>;
806
+ output: Type.TUnion<[Type.TRecord<"^.*$", Type.TUnsafe<import("./json.ts").Json>>, Type.TNull]>;
807
+ exposure: Type.TEnum<["model", "deferred", "code", "hidden"]>;
808
+ }>>;
809
+ }>;
810
+ }>]>>>;
811
+ fences: Type.TOptional<Type.TArray<Type.TString>>;
812
+ }>;
813
+ export type RefUpdate = Decoded<typeof RefUpdateType>;
814
+ export declare const SetOutcomeType: Type.TUnion<[Type.TObject<{
815
+ kind: Type.TLiteral<"set">;
816
+ logged: Type.TArray<Type.TUnsafe<import("./ids.ts").Seq>>;
817
+ at: Type.TNumber;
818
+ revisions: Type.TArray<Type.TUnsafe<import("./ids.ts").Id<"revision">>>;
819
+ }>, Type.TObject<{
820
+ kind: Type.TLiteral<"stale">;
821
+ name: Type.TString;
822
+ revision: Type.TUnion<[Type.TUnsafe<import("./ids.ts").Id<"revision">>, Type.TNull]>;
823
+ }>, Type.TObject<{
824
+ kind: Type.TLiteral<"fenced">;
825
+ name: Type.TString;
826
+ }>]>;
827
+ export type SetOutcome = Decoded<typeof SetOutcomeType>;
828
+ export declare const RefSchema: Schema<Ref>;
829
+ export declare const RefUpdateSchema: Schema<RefUpdate>;
830
+ export declare const SetOutcomeSchema: Schema<SetOutcome>;