@leitwerk-dev/protocol 0.1.9 → 0.2.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.
- package/dist/api-token-contracts.d.ts +45 -0
- package/dist/api-token-contracts.d.ts.map +1 -0
- package/dist/{chunk-SKQG5SE3.js → chunk-4AKWRRFS.js} +113 -28
- package/dist/chunk-4AKWRRFS.js.map +1 -0
- package/dist/{chunk-J7LXDQAN.js → chunk-LTIDCJFK.js} +185 -6
- package/dist/chunk-LTIDCJFK.js.map +1 -0
- package/dist/{chunk-IWVU76M5.js → chunk-RUPDB3WZ.js} +1 -1
- package/dist/chunk-RUPDB3WZ.js.map +1 -0
- package/dist/compact-turn-summary.d.ts +49 -0
- package/dist/compact-turn-summary.d.ts.map +1 -0
- package/dist/config-snapshot-public.d.ts +2 -0
- package/dist/config-snapshot-public.d.ts.map +1 -0
- package/dist/config-snapshot-public.js +1 -0
- package/dist/config-snapshot.d.ts +110 -15
- package/dist/config-snapshot.d.ts.map +1 -1
- package/dist/config-snapshot.js +0 -1
- package/dist/config-snapshot.js.map +1 -1
- package/dist/extension-ui-contracts.d.ts +49 -0
- package/dist/extension-ui-contracts.d.ts.map +1 -0
- package/dist/external-review.d.ts +5 -1
- package/dist/external-review.d.ts.map +1 -1
- package/dist/form-contract-public.d.ts +2 -0
- package/dist/form-contract-public.d.ts.map +1 -0
- package/dist/form-contract-public.js +1 -0
- package/dist/form-contract.d.ts +29 -5
- package/dist/form-contract.d.ts.map +1 -1
- package/dist/form-contract.js +0 -1
- package/dist/form-contract.js.map +1 -1
- package/dist/{http-contracts-DP9P_2YM.d.ts → http-contracts-public-rL4HFcxz.d.ts} +1099 -47
- package/dist/http-contracts-public.d.ts +4 -0
- package/dist/http-contracts-public.d.ts.map +1 -0
- package/dist/http-contracts-public.js +10 -0
- package/dist/http-contracts.d.ts +923 -45
- package/dist/http-contracts.d.ts.map +1 -1
- package/dist/http-contracts.js +32 -432
- package/dist/http-contracts.js.map +1 -1
- package/dist/index.d.ts +30 -20
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1146 -20
- package/dist/index.js.map +1 -1
- package/dist/initial-prompt.d.ts +6 -0
- package/dist/initial-prompt.d.ts.map +1 -1
- package/dist/launcher-contract-public.d.ts +2 -0
- package/dist/launcher-contract-public.d.ts.map +1 -0
- package/dist/launcher-contract-public.js +1 -0
- package/dist/launcher-contract-public.js.map +1 -0
- package/dist/launcher-contract.d.ts +26 -1
- package/dist/launcher-contract.d.ts.map +1 -1
- package/dist/launcher-contract.js +0 -1
- package/dist/launcher-contract.js.map +1 -1
- package/dist/live-turn-projection.d.ts +30 -1
- package/dist/live-turn-projection.d.ts.map +1 -1
- package/dist/pi-session-message.d.ts +16 -0
- package/dist/pi-session-message.d.ts.map +1 -1
- package/dist/primary-path-snapshot.d.ts +64 -0
- package/dist/primary-path-snapshot.d.ts.map +1 -1
- package/dist/protocol.d.ts +450 -17
- package/dist/protocol.d.ts.map +1 -1
- package/dist/protocol.js +37 -259
- package/dist/protocol.js.map +1 -1
- package/dist/session-entry-tree.d.ts +12 -0
- package/dist/session-entry-tree.d.ts.map +1 -1
- package/dist/streamable-events.d.ts +4 -1
- package/dist/streamable-events.d.ts.map +1 -1
- package/dist/text-preview.d.ts +5 -0
- package/dist/text-preview.d.ts.map +1 -1
- package/dist/ticket-creation-contracts.d.ts +55 -0
- package/dist/ticket-creation-contracts.d.ts.map +1 -0
- package/dist/timeline-projection.d.ts +6 -1
- package/dist/timeline-projection.d.ts.map +1 -1
- package/dist/timestamp-ordering.d.ts +2 -0
- package/dist/timestamp-ordering.d.ts.map +1 -1
- package/dist/tool-renderer-contract-public.d.ts +3 -0
- package/dist/tool-renderer-contract-public.d.ts.map +1 -0
- package/dist/tool-renderer-contract-public.js +9 -0
- package/dist/tool-renderer-contract-public.js.map +1 -0
- package/dist/tool-renderer-contract.d.ts +15 -0
- package/dist/tool-renderer-contract.d.ts.map +1 -1
- package/dist/tool-renderer-contract.js +10 -21
- package/dist/tool-renderer-contract.js.map +1 -1
- package/dist/tool-result-truncation.d.ts +10 -0
- package/dist/tool-result-truncation.d.ts.map +1 -0
- package/dist/turn-continuation.d.ts +29 -1
- package/dist/turn-continuation.d.ts.map +1 -1
- package/dist/turn-trace-projection.d.ts +5 -0
- package/dist/turn-trace-projection.d.ts.map +1 -0
- package/dist/usage-by-turn-record.d.ts +2 -0
- package/dist/usage-by-turn-record.d.ts.map +1 -1
- package/dist/usage-snapshot.d.ts +23 -4
- package/dist/usage-snapshot.d.ts.map +1 -1
- package/dist/ws-event-payloads.d.ts +16 -1
- package/dist/ws-event-payloads.d.ts.map +1 -1
- package/package.json +18 -18
- package/src/api-token-contracts.ts +44 -0
- package/src/compact-turn-summary.ts +141 -0
- package/src/config-snapshot-public.ts +12 -0
- package/src/config-snapshot.ts +110 -15
- package/src/extension-ui-contracts.ts +67 -0
- package/src/external-review.ts +5 -1
- package/src/form-contract-public.ts +6 -0
- package/src/form-contract.ts +29 -5
- package/src/http-contracts-public.ts +86 -0
- package/src/http-contracts.ts +1059 -102
- package/src/index.ts +184 -20
- package/src/initial-prompt.ts +9 -6
- package/src/launcher-contract-public.ts +8 -0
- package/src/launcher-contract.ts +26 -1
- package/src/live-turn-projection.ts +70 -113
- package/src/pi-session-message.ts +21 -3
- package/src/primary-path-snapshot.ts +64 -0
- package/src/protocol.ts +461 -26
- package/src/session-entry-tree.ts +12 -0
- package/src/streamable-events.ts +5 -0
- package/src/text-preview.ts +5 -0
- package/src/ticket-creation-contracts.ts +62 -0
- package/src/timeline-projection.ts +10 -4
- package/src/timestamp-ordering.ts +2 -0
- package/src/tool-renderer-contract-public.ts +10 -0
- package/src/tool-renderer-contract.ts +15 -0
- package/src/tool-result-truncation.ts +98 -0
- package/src/turn-continuation.ts +50 -46
- package/src/turn-trace-projection.ts +42 -0
- package/src/usage-by-turn-record.ts +2 -0
- package/src/usage-snapshot.ts +45 -62
- package/src/ws-event-payloads.ts +19 -14
- package/dist/chunk-6L4W7WPV.js +0 -1
- package/dist/chunk-AAV3AAOF.js +0 -1
- package/dist/chunk-IEMT3JG4.js +0 -1
- package/dist/chunk-IWVU76M5.js.map +0 -1
- package/dist/chunk-J7LXDQAN.js.map +0 -1
- package/dist/chunk-SKQG5SE3.js.map +0 -1
- package/dist/external-review.js +0 -2
- package/dist/external-review.js.map +0 -1
- package/dist/initial-prompt.js +0 -103
- package/dist/initial-prompt.js.map +0 -1
- package/dist/live-turn-projection.js +0 -395
- package/dist/live-turn-projection.js.map +0 -1
- package/dist/pi-session-message.js +0 -27
- package/dist/pi-session-message.js.map +0 -1
- package/dist/primary-path-snapshot.js +0 -2
- package/dist/primary-path-snapshot.js.map +0 -1
- package/dist/session-entry-tree.js +0 -42
- package/dist/session-entry-tree.js.map +0 -1
- package/dist/streamable-events.js +0 -17
- package/dist/streamable-events.js.map +0 -1
- package/dist/text-preview.js +0 -23
- package/dist/text-preview.js.map +0 -1
- package/dist/timeline-projection.js +0 -33
- package/dist/timeline-projection.js.map +0 -1
- package/dist/timestamp-ordering.js +0 -15
- package/dist/timestamp-ordering.js.map +0 -1
- package/dist/turn-continuation.js +0 -179
- package/dist/turn-continuation.js.map +0 -1
- package/dist/usage-by-turn-record.js +0 -25
- package/dist/usage-by-turn-record.js.map +0 -1
- package/dist/usage-snapshot.js +0 -120
- package/dist/usage-snapshot.js.map +0 -1
- package/dist/ws-event-payloads.js +0 -47
- package/dist/ws-event-payloads.js.map +0 -1
- /package/dist/{chunk-6L4W7WPV.js.map → config-snapshot-public.js.map} +0 -0
- /package/dist/{chunk-AAV3AAOF.js.map → form-contract-public.js.map} +0 -0
- /package/dist/{chunk-IEMT3JG4.js.map → http-contracts-public.js.map} +0 -0
package/src/config-snapshot.ts
CHANGED
|
@@ -1,184 +1,275 @@
|
|
|
1
|
+
/** @public */
|
|
1
2
|
export interface ExtensionLoadingConfigSnapshot {
|
|
3
|
+
/** @public */
|
|
2
4
|
sources: string[];
|
|
3
5
|
}
|
|
4
6
|
|
|
7
|
+
/** @internal */
|
|
5
8
|
export interface ServerWebsocketConfigSnapshot {
|
|
9
|
+
/** @internal */
|
|
6
10
|
heartbeat_interval: string;
|
|
11
|
+
/** @internal */
|
|
7
12
|
client_timeout: string;
|
|
13
|
+
/** @internal */
|
|
8
14
|
toast_ttl: string;
|
|
9
15
|
}
|
|
10
16
|
|
|
17
|
+
/** @public */
|
|
11
18
|
export interface ServerConfigSnapshot {
|
|
19
|
+
/** @public */
|
|
12
20
|
host: string;
|
|
21
|
+
/** @public */
|
|
13
22
|
port: number;
|
|
23
|
+
/** @public */
|
|
14
24
|
base_url: string;
|
|
25
|
+
/** @internal */
|
|
15
26
|
websocket: ServerWebsocketConfigSnapshot;
|
|
16
27
|
}
|
|
17
28
|
|
|
29
|
+
/** @public */
|
|
18
30
|
export interface StorageConfigSnapshot {
|
|
31
|
+
/** @public */
|
|
19
32
|
sqlite_path: string;
|
|
33
|
+
/** @public */
|
|
20
34
|
process_workspaces_dir: string;
|
|
35
|
+
/** @public */
|
|
21
36
|
tree_files_dir: string;
|
|
22
37
|
}
|
|
23
38
|
|
|
39
|
+
/** @internal */
|
|
24
40
|
export interface ComponentConfigSnapshot {
|
|
41
|
+
/** @internal */
|
|
25
42
|
repo: string;
|
|
43
|
+
/** @internal */
|
|
26
44
|
default_branch: string;
|
|
27
45
|
/**
|
|
28
46
|
* Worker runtime profile this component requires. Selection precedence is
|
|
29
47
|
* process override → component → default; conflicting component profiles on
|
|
30
48
|
* a single process are rejected before the worker starts.
|
|
31
49
|
*/
|
|
50
|
+
/** @internal */
|
|
32
51
|
worker_runtime_profile?: string;
|
|
33
52
|
}
|
|
34
53
|
|
|
54
|
+
/** @internal */
|
|
35
55
|
export interface WorkersCleanupConfigSnapshot {
|
|
56
|
+
/** @internal */
|
|
36
57
|
transient_ttl: string;
|
|
58
|
+
/** @internal */
|
|
37
59
|
completed_process_retention: string;
|
|
60
|
+
/** @internal */
|
|
38
61
|
error_process_retention: string;
|
|
39
62
|
}
|
|
40
63
|
|
|
64
|
+
/** @public */
|
|
41
65
|
export interface WorkersConfigSnapshot {
|
|
42
|
-
/** Worker execution run mode. Docker/Kubernetes are production; local is test/development only. */
|
|
66
|
+
/** Worker execution run mode. Docker/Kubernetes are production; local is test/development only. @public */
|
|
43
67
|
runner: "docker" | "kubernetes" | "local";
|
|
44
68
|
/**
|
|
45
69
|
* Fallback worker runtime profile id used when neither the process nor any
|
|
46
70
|
* component selects one. Must reference a configured `worker_runtime_profiles`
|
|
47
71
|
* entry when set.
|
|
48
72
|
*/
|
|
73
|
+
/** @internal */
|
|
49
74
|
default_runtime_profile?: string;
|
|
75
|
+
/** @internal */
|
|
50
76
|
max_parallel_processes: number;
|
|
77
|
+
/** @internal */
|
|
51
78
|
startup_timeout: string;
|
|
79
|
+
/** @public */
|
|
52
80
|
shutdown_grace_period: string;
|
|
81
|
+
/** @internal */
|
|
53
82
|
heartbeat_interval: string;
|
|
83
|
+
/** @internal */
|
|
54
84
|
turn_max_duration: string;
|
|
85
|
+
/** @internal */
|
|
55
86
|
turn_inactivity_timeout: string;
|
|
87
|
+
/** @internal */
|
|
56
88
|
turn_abort_grace_period: string;
|
|
89
|
+
/** @internal */
|
|
57
90
|
stale_heartbeat_timeout: string;
|
|
91
|
+
/** @internal */
|
|
58
92
|
resume_on_boot: boolean;
|
|
93
|
+
/** @internal */
|
|
59
94
|
idle_worker_ttl: string;
|
|
60
|
-
/** Server-enforced maximum HTTP session snapshot upload size in bytes. */
|
|
95
|
+
/** Server-enforced maximum HTTP session snapshot upload size in bytes. @internal */
|
|
61
96
|
session_snapshot_max_size_bytes: number;
|
|
62
|
-
/** Server-owned debug mirror for raw worker.event payloads. Workers ignore this switch. */
|
|
97
|
+
/** Server-owned debug mirror for raw worker.event payloads. Workers ignore this switch. @internal */
|
|
63
98
|
log_worker_events_to_stdout: boolean;
|
|
99
|
+
/** @internal */
|
|
64
100
|
cleanup: WorkersCleanupConfigSnapshot;
|
|
65
101
|
}
|
|
66
102
|
|
|
103
|
+
/** @internal */
|
|
67
104
|
export interface WorkerRuntimeConfigSnapshot {
|
|
105
|
+
/** @internal */
|
|
68
106
|
heartbeat_interval: string;
|
|
107
|
+
/** @internal */
|
|
69
108
|
turn_max_duration: string;
|
|
109
|
+
/** @internal */
|
|
70
110
|
turn_inactivity_timeout: string;
|
|
111
|
+
/** @internal */
|
|
71
112
|
turn_abort_grace_period: string;
|
|
72
113
|
}
|
|
73
114
|
|
|
115
|
+
/** @public */
|
|
74
116
|
export interface ModelProfileSnapshot {
|
|
117
|
+
/** @public */
|
|
75
118
|
id: string;
|
|
119
|
+
/** @public */
|
|
76
120
|
provider: string;
|
|
121
|
+
/** @public */
|
|
77
122
|
model_id: string;
|
|
123
|
+
/** @public */
|
|
78
124
|
thinking_level?: string;
|
|
79
|
-
/** Non-secret provider-owned defaults applied to each new LLM start. */
|
|
125
|
+
/** Non-secret provider-owned defaults applied to each new LLM start. @internal */
|
|
80
126
|
provider_options?: Record<string, string>;
|
|
81
127
|
}
|
|
82
128
|
|
|
129
|
+
/** @internal */
|
|
83
130
|
export interface PiProviderRetryConfigSnapshot {
|
|
84
|
-
/** Optional provider/SDK request timeout. Null defers to the provider SDK default. */
|
|
131
|
+
/** Optional provider/SDK request timeout. Null defers to the provider SDK default. @internal */
|
|
85
132
|
timeout: string | null;
|
|
86
|
-
/** Optional provider/SDK retry attempts. Null defers to the provider SDK default. */
|
|
133
|
+
/** Optional provider/SDK retry attempts. Null defers to the provider SDK default. @internal */
|
|
87
134
|
max_retries: number | null;
|
|
88
|
-
/** Maximum provider-requested retry delay before failing fast. */
|
|
135
|
+
/** Maximum provider-requested retry delay before failing fast. @internal */
|
|
89
136
|
max_retry_delay: string;
|
|
90
137
|
}
|
|
91
138
|
|
|
139
|
+
/** @internal */
|
|
92
140
|
export interface PiRetryConfigSnapshot {
|
|
141
|
+
/** @internal */
|
|
93
142
|
enabled: boolean;
|
|
143
|
+
/** @internal */
|
|
94
144
|
max_retries: number;
|
|
145
|
+
/** @internal */
|
|
95
146
|
base_delay: string;
|
|
147
|
+
/** @internal */
|
|
96
148
|
provider: PiProviderRetryConfigSnapshot;
|
|
97
149
|
}
|
|
98
150
|
|
|
151
|
+
/** @internal */
|
|
99
152
|
export interface PiProcessTitleGenerationRetryConfigSnapshot {
|
|
100
|
-
/** Total title-generation attempts including the first immediate try. */
|
|
153
|
+
/** Total title-generation attempts including the first immediate try. @internal */
|
|
101
154
|
max_attempts: number;
|
|
102
|
-
/** Base outer retry delay after a failed server-side title request. */
|
|
155
|
+
/** Base outer retry delay after a failed server-side title request. @internal */
|
|
103
156
|
base_delay: string;
|
|
104
|
-
/** Maximum outer retry delay for failed title-generation jobs. */
|
|
157
|
+
/** Maximum outer retry delay for failed title-generation jobs. @internal */
|
|
105
158
|
max_delay: string;
|
|
106
159
|
}
|
|
107
160
|
|
|
161
|
+
/** @public */
|
|
108
162
|
export interface PiProcessTitleGenerationConfigSnapshot {
|
|
163
|
+
/** @public */
|
|
109
164
|
model_profile: string | null;
|
|
165
|
+
/** @internal */
|
|
110
166
|
retry: PiProcessTitleGenerationRetryConfigSnapshot;
|
|
111
167
|
}
|
|
112
168
|
|
|
169
|
+
/** @public */
|
|
113
170
|
export interface PiConfigSnapshot {
|
|
114
|
-
/** Leitwerk-managed Pi agent directory. Local workers use it as PI_CODING_AGENT_DIR. */
|
|
171
|
+
/** Leitwerk-managed Pi agent directory. Local workers use it as PI_CODING_AGENT_DIR. @public */
|
|
115
172
|
agent_dir: string;
|
|
173
|
+
/** @public */
|
|
116
174
|
model_profiles: ModelProfileSnapshot[];
|
|
117
|
-
/** Global default system prompt template for all processes. Rendered with Mustache against runtime context. When omitted, the worker uses its built-in default. */
|
|
175
|
+
/** Global default system prompt template for all processes. Rendered with Mustache against runtime context. When omitted, the worker uses its built-in default. @internal */
|
|
118
176
|
system_prompt_template?: string;
|
|
119
|
-
/** Server-side pre-start process title generation settings. */
|
|
177
|
+
/** Server-side pre-start process title generation settings. @public */
|
|
120
178
|
process_title_generation: PiProcessTitleGenerationConfigSnapshot;
|
|
121
|
-
/** Leitwerk-managed Pi retry/runtime settings for newly created worker sessions. */
|
|
179
|
+
/** Leitwerk-managed Pi retry/runtime settings for newly created worker sessions. @internal */
|
|
122
180
|
retry: PiRetryConfigSnapshot;
|
|
123
181
|
}
|
|
124
182
|
|
|
183
|
+
/** @internal */
|
|
125
184
|
export interface ProcessPiConfigSnapshot {
|
|
185
|
+
/** @internal */
|
|
126
186
|
system_prompt_template?: string;
|
|
187
|
+
/** @internal */
|
|
127
188
|
append_system_prompt_template?: string;
|
|
128
189
|
}
|
|
129
190
|
|
|
191
|
+
/** @public */
|
|
130
192
|
export interface ProcessTurnConfigSnapshot {
|
|
193
|
+
/** @internal */
|
|
131
194
|
model_profile?: string;
|
|
132
195
|
}
|
|
133
196
|
|
|
197
|
+
/** @public */
|
|
134
198
|
export interface ProcessConfigSnapshot {
|
|
199
|
+
/** @public */
|
|
135
200
|
default_model_profile?: string;
|
|
136
201
|
/**
|
|
137
202
|
* Restricts which model profiles this process may use.
|
|
138
203
|
* When set, only listed profile IDs are valid for default, turn, and override selections.
|
|
139
204
|
* When omitted, all configured model profiles are allowed.
|
|
140
205
|
*/
|
|
206
|
+
/** @internal */
|
|
141
207
|
allowed_model_profiles?: string[];
|
|
142
208
|
/**
|
|
143
209
|
* Process-level worker runtime profile override. Wins over per-component
|
|
144
210
|
* selection. Must reference a configured `worker_runtime_profiles` entry.
|
|
145
211
|
*/
|
|
212
|
+
/** @internal */
|
|
146
213
|
worker_runtime_profile?: string;
|
|
214
|
+
/** Server-only process-volume capacity override, for example 128Mi or 1Gi. @internal */
|
|
215
|
+
storage_size?: string;
|
|
216
|
+
/** @internal */
|
|
147
217
|
pi?: ProcessPiConfigSnapshot;
|
|
218
|
+
/** @public */
|
|
148
219
|
turn_configs: Record<string, ProcessTurnConfigSnapshot>;
|
|
149
|
-
/** Extension-owned watcher configuration, keyed by code-defined watcher id. */
|
|
220
|
+
/** Extension-owned watcher configuration, keyed by code-defined watcher id. @public */
|
|
150
221
|
watchers?: Record<string, unknown>;
|
|
151
222
|
}
|
|
152
223
|
|
|
224
|
+
/** @internal */
|
|
153
225
|
export interface WorkerProcessConfigSnapshot {
|
|
226
|
+
/** @internal */
|
|
154
227
|
pi?: ProcessPiConfigSnapshot;
|
|
155
228
|
}
|
|
156
229
|
|
|
230
|
+
/** @internal */
|
|
157
231
|
export interface NotificationChannelConfigSnapshot {
|
|
232
|
+
/** @internal */
|
|
158
233
|
enabled: boolean;
|
|
234
|
+
/** @internal */
|
|
159
235
|
type: string;
|
|
236
|
+
/** @internal */
|
|
160
237
|
url: string;
|
|
161
238
|
}
|
|
162
239
|
|
|
240
|
+
/** @internal */
|
|
163
241
|
export interface SquadNotificationRouteSnapshot {
|
|
242
|
+
/** @internal */
|
|
164
243
|
url: string;
|
|
165
244
|
}
|
|
166
245
|
|
|
246
|
+
/** @internal */
|
|
167
247
|
export interface SquadNotificationConfigSnapshot {
|
|
248
|
+
/** @internal */
|
|
168
249
|
enabled: boolean;
|
|
250
|
+
/** @internal */
|
|
169
251
|
type: string;
|
|
252
|
+
/** @internal */
|
|
170
253
|
routing_field: string;
|
|
254
|
+
/** @internal */
|
|
171
255
|
routes: Record<string, SquadNotificationRouteSnapshot>;
|
|
172
256
|
}
|
|
173
257
|
|
|
258
|
+
/** @internal */
|
|
174
259
|
export interface NotificationsConfigSnapshot {
|
|
260
|
+
/** @internal */
|
|
175
261
|
all: NotificationChannelConfigSnapshot;
|
|
262
|
+
/** @internal */
|
|
176
263
|
debug: NotificationChannelConfigSnapshot;
|
|
264
|
+
/** @internal */
|
|
177
265
|
squad: SquadNotificationConfigSnapshot;
|
|
178
266
|
}
|
|
179
267
|
|
|
268
|
+
/** @internal */
|
|
180
269
|
export interface SandboxConfigSnapshot {
|
|
270
|
+
/** @internal */
|
|
181
271
|
enabled: boolean;
|
|
272
|
+
/** @internal */
|
|
182
273
|
profile: string;
|
|
183
274
|
}
|
|
184
275
|
|
|
@@ -187,8 +278,12 @@ export interface SandboxConfigSnapshot {
|
|
|
187
278
|
* time. Server-only wiring and unused operator/server config are intentionally
|
|
188
279
|
* excluded.
|
|
189
280
|
*/
|
|
281
|
+
/** @public */
|
|
190
282
|
export interface ConfigSnapshot {
|
|
283
|
+
/** @internal */
|
|
191
284
|
workers: WorkerRuntimeConfigSnapshot;
|
|
285
|
+
/** @public */
|
|
192
286
|
pi: PiConfigSnapshot;
|
|
287
|
+
/** @internal */
|
|
193
288
|
process_configs?: Record<string, WorkerProcessConfigSnapshot>;
|
|
194
289
|
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { isUnknownRecord } from "@leitwerk-dev/domain";
|
|
2
|
+
import * as v from "valibot";
|
|
3
|
+
|
|
4
|
+
// Wire shape only; the catalog validates manifests and hosts check supported versions.
|
|
5
|
+
const recordSchema = v.custom<Record<string, unknown>>(isUnknownRecord);
|
|
6
|
+
const versionSchema = v.custom<number>((value) => typeof value === "number");
|
|
7
|
+
|
|
8
|
+
/** @internal */
|
|
9
|
+
export const leafOutcomeRendererDescriptorSchema = v.pipe(
|
|
10
|
+
recordSchema,
|
|
11
|
+
v.object({
|
|
12
|
+
/** @internal */
|
|
13
|
+
ok: v.literal(true),
|
|
14
|
+
/** @internal */
|
|
15
|
+
rendererId: v.string(),
|
|
16
|
+
/** @internal */
|
|
17
|
+
kind: v.literal("custom_element"),
|
|
18
|
+
/** @internal */
|
|
19
|
+
tagName: v.string(),
|
|
20
|
+
/** @internal */
|
|
21
|
+
modulePath: v.string(),
|
|
22
|
+
/** @internal */
|
|
23
|
+
rendererApiVersion: versionSchema,
|
|
24
|
+
/** @internal */
|
|
25
|
+
extensionManifestId: v.string(),
|
|
26
|
+
/** @internal */
|
|
27
|
+
moduleUrl: v.string(),
|
|
28
|
+
}),
|
|
29
|
+
);
|
|
30
|
+
/** @internal */
|
|
31
|
+
export type LeafOutcomeRendererDescriptor = v.InferOutput<
|
|
32
|
+
typeof leafOutcomeRendererDescriptorSchema
|
|
33
|
+
>;
|
|
34
|
+
|
|
35
|
+
/** @internal */
|
|
36
|
+
export const leafOutcomeRendererFailureSchema = v.pipe(
|
|
37
|
+
recordSchema,
|
|
38
|
+
v.object({
|
|
39
|
+
/** @internal */
|
|
40
|
+
ok: v.literal(false),
|
|
41
|
+
/** @internal */
|
|
42
|
+
rendererId: v.string(),
|
|
43
|
+
/** @internal */
|
|
44
|
+
code: v.string(),
|
|
45
|
+
/** @internal */
|
|
46
|
+
message: v.string(),
|
|
47
|
+
}),
|
|
48
|
+
);
|
|
49
|
+
/** @internal */
|
|
50
|
+
export type LeafOutcomeRendererFailure = v.InferOutput<typeof leafOutcomeRendererFailureSchema>;
|
|
51
|
+
|
|
52
|
+
/** @internal */
|
|
53
|
+
export const browserUiExtensionDescriptorSchema = v.pipe(
|
|
54
|
+
recordSchema,
|
|
55
|
+
v.object({
|
|
56
|
+
/** @internal */
|
|
57
|
+
extensionManifestId: v.string(),
|
|
58
|
+
/** @internal */
|
|
59
|
+
modulePath: v.string(),
|
|
60
|
+
/** @internal */
|
|
61
|
+
moduleUrl: v.string(),
|
|
62
|
+
/** @internal */
|
|
63
|
+
browserApiVersion: versionSchema,
|
|
64
|
+
}),
|
|
65
|
+
);
|
|
66
|
+
/** @internal */
|
|
67
|
+
export type BrowserUiExtensionDescriptor = v.InferOutput<typeof browserUiExtensionDescriptorSchema>;
|
package/src/external-review.ts
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
/** Repository review created by a worker-side handoff and persisted by the server. */
|
|
1
|
+
/** Repository review created by a worker-side handoff and persisted by the server. @internal */
|
|
2
2
|
export interface CreatedExternalReview {
|
|
3
|
+
/** @internal */
|
|
3
4
|
projectKey: string;
|
|
5
|
+
/** @internal */
|
|
4
6
|
externalId: string;
|
|
7
|
+
/** @internal */
|
|
5
8
|
externalUrl: string;
|
|
9
|
+
/** @internal */
|
|
6
10
|
baseBranch: string;
|
|
7
11
|
}
|
package/src/form-contract.ts
CHANGED
|
@@ -1,50 +1,74 @@
|
|
|
1
|
+
/** @public */
|
|
1
2
|
export type FormFieldKind = "text" | "textarea" | "number" | "boolean" | "select";
|
|
2
3
|
|
|
4
|
+
/** @public */
|
|
3
5
|
export interface FormFieldOptionDefinition {
|
|
6
|
+
/** @internal */
|
|
4
7
|
value: string;
|
|
8
|
+
/** @internal */
|
|
5
9
|
label: string;
|
|
10
|
+
/** @internal */
|
|
6
11
|
description?: string;
|
|
7
12
|
}
|
|
8
13
|
|
|
14
|
+
/** @internal */
|
|
9
15
|
export interface FormFieldPublishDefinition {
|
|
10
|
-
/** Product name to publish. Defaults to the field id. */
|
|
16
|
+
/** Product name to publish. Defaults to the field id. @internal */
|
|
11
17
|
product?: string;
|
|
12
18
|
}
|
|
13
19
|
|
|
20
|
+
/** @internal */
|
|
14
21
|
export interface FormFieldStateDefinition {
|
|
15
|
-
/** Dot-separated path in process state to write the submitted field value to. */
|
|
22
|
+
/** Dot-separated path in process state to write the submitted field value to. @internal */
|
|
16
23
|
path: string;
|
|
17
24
|
}
|
|
18
25
|
|
|
26
|
+
/** @public */
|
|
19
27
|
export interface FormFieldDefinition<TKind extends FormFieldKind = FormFieldKind> {
|
|
28
|
+
/** @public */
|
|
20
29
|
id: string;
|
|
30
|
+
/** @public */
|
|
21
31
|
label: string;
|
|
32
|
+
/** @public */
|
|
22
33
|
kind: TKind;
|
|
34
|
+
/** @public */
|
|
23
35
|
required?: boolean;
|
|
36
|
+
/** @public */
|
|
24
37
|
placeholder?: string;
|
|
38
|
+
/** @public */
|
|
25
39
|
description?: string;
|
|
40
|
+
/** @internal */
|
|
26
41
|
options?: readonly FormFieldOptionDefinition[];
|
|
42
|
+
/** @internal */
|
|
27
43
|
rememberRecentValues?: boolean;
|
|
28
|
-
/** Publish this field as transition-scoped product/input data. */
|
|
44
|
+
/** Publish this field as transition-scoped product/input data. @internal */
|
|
29
45
|
publish?: true | FormFieldPublishDefinition;
|
|
30
|
-
/** Persist this field value into process state. */
|
|
46
|
+
/** Persist this field value into process state. @internal */
|
|
31
47
|
state?: FormFieldStateDefinition;
|
|
32
48
|
}
|
|
33
49
|
|
|
50
|
+
/** @public */
|
|
34
51
|
export type ActionFormFieldKind = Exclude<FormFieldKind, "select">;
|
|
52
|
+
/** @public */
|
|
35
53
|
export type ActionFormFieldDefinition = Omit<
|
|
36
54
|
FormFieldDefinition<ActionFormFieldKind>,
|
|
37
55
|
"options" | "rememberRecentValues"
|
|
38
56
|
> & {
|
|
39
|
-
/** Share this textual value across compatible action forms as their primary prompt. */
|
|
57
|
+
/** Share this textual value across compatible action forms as their primary prompt. @internal */
|
|
40
58
|
primaryPrompt?: true;
|
|
41
59
|
};
|
|
42
60
|
|
|
61
|
+
/** @public */
|
|
43
62
|
export interface FormDefinition<TField extends FormFieldDefinition = FormFieldDefinition> {
|
|
63
|
+
/** @public */
|
|
44
64
|
id: string;
|
|
65
|
+
/** @public */
|
|
45
66
|
title: string;
|
|
67
|
+
/** @public */
|
|
46
68
|
fields: readonly TField[];
|
|
69
|
+
/** @public */
|
|
47
70
|
submitLabel?: string;
|
|
48
71
|
}
|
|
49
72
|
|
|
73
|
+
/** @public */
|
|
50
74
|
export type ActionFormDefinition = FormDefinition<ActionFormFieldDefinition>;
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
export type {
|
|
2
|
+
ApiTokenMetadata,
|
|
3
|
+
ApiTokenPolicy,
|
|
4
|
+
ApiTokensResponseBody,
|
|
5
|
+
CreateApiTokenResponseBody,
|
|
6
|
+
} from "./api-token-contracts.js";
|
|
7
|
+
export type {
|
|
8
|
+
AuthMeResponseBody,
|
|
9
|
+
CronPreviewResponseBody,
|
|
10
|
+
CurrentErrorSummary,
|
|
11
|
+
CurrentTurnRecoverySummary,
|
|
12
|
+
ErrorResponseBody,
|
|
13
|
+
FutureActionSummary,
|
|
14
|
+
FutureExecutionDetailResponseBody,
|
|
15
|
+
FutureExecutionOverviewItem,
|
|
16
|
+
FutureExecutionSummary,
|
|
17
|
+
FutureLaunchMutationResponseBody,
|
|
18
|
+
FutureLaunchSummary,
|
|
19
|
+
InstalledSkillCatalogDetail,
|
|
20
|
+
InstalledSkillCatalogDetailResponseBody,
|
|
21
|
+
InstalledSkillCatalogItem,
|
|
22
|
+
InstanceTreeEdgeSummary,
|
|
23
|
+
InstanceTreeNodeSummary,
|
|
24
|
+
LauncherDefaultModelPreview,
|
|
25
|
+
LauncherDefaultsResponseBody,
|
|
26
|
+
LauncherModelConfigDefaults,
|
|
27
|
+
LauncherModelConfigPreview,
|
|
28
|
+
LauncherModelConfigPreviewResponseBody,
|
|
29
|
+
LauncherModelConfigSchema,
|
|
30
|
+
LauncherMutationResponseBody,
|
|
31
|
+
LauncherOptionsResponseBody,
|
|
32
|
+
LauncherRecentValuesResponseBody,
|
|
33
|
+
LaunchersResponseBody,
|
|
34
|
+
LauncherTurnModelConfigPreview,
|
|
35
|
+
LaunchRunResponseBody,
|
|
36
|
+
ModelProfileOptionSummary,
|
|
37
|
+
ModelProviderOptionsResponseBody,
|
|
38
|
+
PrimaryPathSnapshotResponseBody,
|
|
39
|
+
ProcessActionFieldDefinition,
|
|
40
|
+
ProcessActionModelPreview,
|
|
41
|
+
ProcessActionModelPreviewResponseBody,
|
|
42
|
+
ProcessActionModelResolutionPreview,
|
|
43
|
+
ProcessActionPreviewSummary,
|
|
44
|
+
ProcessActionSummary,
|
|
45
|
+
ProcessActionWarmPromptCacheContext,
|
|
46
|
+
ProcessBrowseFacets,
|
|
47
|
+
ProcessBrowseItem,
|
|
48
|
+
ProcessBrowsePagination,
|
|
49
|
+
ProcessBrowseResponseBody,
|
|
50
|
+
ProcessDetailUiSnapshotResponseBody,
|
|
51
|
+
ProcessDiagnosticsData,
|
|
52
|
+
ProcessDiagnosticsResponseBody,
|
|
53
|
+
ProcessExternalSourceSummary,
|
|
54
|
+
ProcessExternalTriggerSummary,
|
|
55
|
+
ProcessesListResponseBody,
|
|
56
|
+
ProcessesOverviewResponseBody,
|
|
57
|
+
ProcessInstanceTreeResponseBody,
|
|
58
|
+
ProcessLaunchConfigurationView,
|
|
59
|
+
ProcessLaunchRunsResponseBody,
|
|
60
|
+
ProcessListItem,
|
|
61
|
+
ProcessModelConfigurationView,
|
|
62
|
+
ProcessOverviewItem,
|
|
63
|
+
ProcessRetryConfig,
|
|
64
|
+
ProcessRetryConfigResponseBody,
|
|
65
|
+
ProcessRunDetailsView,
|
|
66
|
+
ProcessRunTurnView,
|
|
67
|
+
ProcessSelectedTurnSummary,
|
|
68
|
+
QuestionRequestMutationResponseBody,
|
|
69
|
+
ScheduleConfigInput,
|
|
70
|
+
ScheduledActionDetail,
|
|
71
|
+
ScheduledActionMutationResponseBody,
|
|
72
|
+
SessionTransferOperationView,
|
|
73
|
+
SkillCatalogDetail,
|
|
74
|
+
SkillCatalogDetailResponseBody,
|
|
75
|
+
SkillCatalogItem,
|
|
76
|
+
SkillRepositorySummary,
|
|
77
|
+
SkillsCatalogResponseBody,
|
|
78
|
+
StartLaunchRunResponseBody,
|
|
79
|
+
SubmitQuestionAnswersRequestBody,
|
|
80
|
+
TurnReasoningDetailResponseBody,
|
|
81
|
+
UiLauncherSummary,
|
|
82
|
+
WatcherLaunchModelSummary,
|
|
83
|
+
WatcherSummary,
|
|
84
|
+
WatchersResponseBody,
|
|
85
|
+
} from "./http-contracts.js";
|
|
86
|
+
export { parseScheduleRequestInput, resolvePromptCacheSwitch } from "./http-contracts.js";
|