@urateam/core 0.1.2 → 0.1.3
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/__tests__/pipeline-config.test.js +17 -0
- package/dist/__tests__/pipeline-config.test.js.map +1 -1
- package/dist/pm/types.d.ts +6 -28
- package/dist/pm/types.d.ts.map +1 -1
- package/dist/types.d.ts +129 -963
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +4 -4
- package/dist/types.js.map +1 -1
- package/package.json +2 -2
package/dist/types.d.ts
CHANGED
|
@@ -1,555 +1,182 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const StageTypeSchema: z.ZodEnum<
|
|
2
|
+
export declare const StageTypeSchema: z.ZodEnum<{
|
|
3
|
+
triage: "triage";
|
|
4
|
+
"await-approval": "await-approval";
|
|
5
|
+
reproduce: "reproduce";
|
|
6
|
+
implement: "implement";
|
|
7
|
+
test: "test";
|
|
8
|
+
review: "review";
|
|
9
|
+
}>;
|
|
3
10
|
export type StageType = z.infer<typeof StageTypeSchema>;
|
|
4
11
|
export declare const AGENT_STAGES: StageType[];
|
|
5
|
-
export declare const RetryStrategySchema: z.ZodEnum<
|
|
12
|
+
export declare const RetryStrategySchema: z.ZodEnum<{
|
|
13
|
+
"fix-and-retry": "fix-and-retry";
|
|
14
|
+
escalate: "escalate";
|
|
15
|
+
"fail-fast": "fail-fast";
|
|
16
|
+
}>;
|
|
6
17
|
export type RetryStrategy = z.infer<typeof RetryStrategySchema>;
|
|
7
18
|
export declare const RetryConfigSchema: z.ZodObject<{
|
|
8
19
|
maxAttempts: z.ZodNumber;
|
|
9
|
-
strategy: z.ZodEnum<
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
strategy: "fix-and-retry" | "escalate" | "fail-fast";
|
|
16
|
-
}>;
|
|
20
|
+
strategy: z.ZodEnum<{
|
|
21
|
+
"fix-and-retry": "fix-and-retry";
|
|
22
|
+
escalate: "escalate";
|
|
23
|
+
"fail-fast": "fail-fast";
|
|
24
|
+
}>;
|
|
25
|
+
}, z.core.$strip>;
|
|
17
26
|
export type RetryConfig = z.infer<typeof RetryConfigSchema>;
|
|
18
27
|
export declare const ReviewConfigSchema: z.ZodObject<{
|
|
19
28
|
requiredApprovals: z.ZodNumber;
|
|
20
|
-
},
|
|
21
|
-
requiredApprovals: number;
|
|
22
|
-
}, {
|
|
23
|
-
requiredApprovals: number;
|
|
24
|
-
}>;
|
|
29
|
+
}, z.core.$strip>;
|
|
25
30
|
export type ReviewConfig = z.infer<typeof ReviewConfigSchema>;
|
|
26
31
|
export declare const PipelineConfigSchema: z.ZodObject<{
|
|
27
32
|
name: z.ZodString;
|
|
28
|
-
stages: z.ZodArray<z.ZodEnum<
|
|
33
|
+
stages: z.ZodArray<z.ZodEnum<{
|
|
34
|
+
triage: "triage";
|
|
35
|
+
"await-approval": "await-approval";
|
|
36
|
+
reproduce: "reproduce";
|
|
37
|
+
implement: "implement";
|
|
38
|
+
test: "test";
|
|
39
|
+
review: "review";
|
|
40
|
+
}>>;
|
|
29
41
|
retry: z.ZodObject<{
|
|
30
42
|
maxAttempts: z.ZodNumber;
|
|
31
|
-
strategy: z.ZodEnum<
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
strategy: "fix-and-retry" | "escalate" | "fail-fast";
|
|
38
|
-
}>;
|
|
43
|
+
strategy: z.ZodEnum<{
|
|
44
|
+
"fix-and-retry": "fix-and-retry";
|
|
45
|
+
escalate: "escalate";
|
|
46
|
+
"fail-fast": "fail-fast";
|
|
47
|
+
}>;
|
|
48
|
+
}, z.core.$strip>;
|
|
39
49
|
review: z.ZodObject<{
|
|
40
50
|
requiredApprovals: z.ZodNumber;
|
|
41
|
-
},
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
51
|
+
}, z.core.$strip>;
|
|
52
|
+
prStrategy: z.ZodEnum<{
|
|
53
|
+
draft: "draft";
|
|
54
|
+
ready: "ready";
|
|
45
55
|
}>;
|
|
46
|
-
prStrategy: z.ZodEnum<["draft", "ready"]>;
|
|
47
|
-
/** Run a lightweight validation agent after each stage to verify handoff accuracy.
|
|
48
|
-
* Default: false. Set to true to opt in (adds ~15-20K tokens per run). */
|
|
49
56
|
validateHandoffs: z.ZodOptional<z.ZodBoolean>;
|
|
50
|
-
/** RALPH loop iterations for the implement stage. 0 disables. Default: 1.
|
|
51
|
-
* Set to 2 for more thorough requirements checking (adds ~100-200K tokens per iteration). */
|
|
52
57
|
ralphIterations: z.ZodOptional<z.ZodNumber>;
|
|
53
|
-
/** Review-fix loop iterations. When review finds blocking issues, re-run implement→test→review.
|
|
54
|
-
* Default: 1, 0 disables. WARNING: compounds with ralphIterations — worst case is
|
|
55
|
-
* reviewFixIterations × (1 + ralphIterations) implement runs per fix cycle.
|
|
56
|
-
* Set to 2 for an extra fix pass (adds ~150-300K tokens per iteration). */
|
|
57
58
|
reviewFixIterations: z.ZodOptional<z.ZodNumber>;
|
|
58
|
-
/** Deep review passes using 3 parallel sub-agents (reuse, quality, efficiency).
|
|
59
|
-
* Runs after the review-fix loop resolves blocking findings. Default: 0 (disabled).
|
|
60
|
-
* Set to 1 to opt in for critical pipelines (adds ~45-100K tokens per pass). */
|
|
61
59
|
deepReviewPasses: z.ZodOptional<z.ZodNumber>;
|
|
62
|
-
/** Hard cap on deep review passes. Prevents infinite loops. Default: 3. */
|
|
63
60
|
maxDeepReviewPasses: z.ZodOptional<z.ZodNumber>;
|
|
64
|
-
/** Auto-merge PRs when changes are trivial. Default: false (opt-in). */
|
|
65
61
|
autoMerge: z.ZodOptional<z.ZodBoolean>;
|
|
66
|
-
/** Max diff lines for auto-merge eligibility. Default: 200. */
|
|
67
62
|
autoMergeMaxLines: z.ZodOptional<z.ZodNumber>;
|
|
68
|
-
|
|
69
|
-
* Example: ["**\/migrations\/**", "**\/*.env", "infra\/**"] */
|
|
70
|
-
autoMergeExcludePatterns: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
71
|
-
/**
|
|
72
|
-
* Advanced automerge criteria evaluated when GitHub sends a PR event (check_suite.completed,
|
|
73
|
-
* status, pull_request.labeled, etc.). All criteria must pass for the PR to be merged.
|
|
74
|
-
* Requires GitHub App credentials (github config in ServerConfig).
|
|
75
|
-
*/
|
|
63
|
+
autoMergeExcludePatterns: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
76
64
|
autoMergeConfig: z.ZodOptional<z.ZodObject<{
|
|
77
|
-
/** Minimum number of unique approving reviews required. Default: 0. */
|
|
78
65
|
minimumApprovingReviews: z.ZodOptional<z.ZodNumber>;
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
}, "strip", z.ZodTypeAny, {
|
|
89
|
-
minimumApprovingReviews?: number | undefined;
|
|
90
|
-
requiredStatusChecks?: string[] | undefined;
|
|
91
|
-
requiredLabels?: string[] | undefined;
|
|
92
|
-
allowedBranches?: string[] | undefined;
|
|
93
|
-
mergeMethod?: "merge" | "squash" | "rebase" | undefined;
|
|
94
|
-
}, {
|
|
95
|
-
minimumApprovingReviews?: number | undefined;
|
|
96
|
-
requiredStatusChecks?: string[] | undefined;
|
|
97
|
-
requiredLabels?: string[] | undefined;
|
|
98
|
-
allowedBranches?: string[] | undefined;
|
|
99
|
-
mergeMethod?: "merge" | "squash" | "rebase" | undefined;
|
|
100
|
-
}>>;
|
|
101
|
-
/** Maximum total tokens (input + output) allowed per pipeline run. Exceeding this aborts the run. */
|
|
66
|
+
requiredStatusChecks: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
67
|
+
requiredLabels: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
68
|
+
allowedBranches: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
69
|
+
mergeMethod: z.ZodOptional<z.ZodEnum<{
|
|
70
|
+
merge: "merge";
|
|
71
|
+
squash: "squash";
|
|
72
|
+
rebase: "rebase";
|
|
73
|
+
}>>;
|
|
74
|
+
}, z.core.$strip>>;
|
|
102
75
|
maxTokens: z.ZodOptional<z.ZodNumber>;
|
|
103
|
-
/** Per-stage model overrides. Keys are stage names; values are model strings passed to the Agent SDK.
|
|
104
|
-
* Invalid model strings are passed through as-is (let the SDK error, no local validation).
|
|
105
|
-
* Example: { implement: "claude-opus-4-6", test: "claude-haiku-4-5" } */
|
|
106
76
|
stageModels: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
107
|
-
/** Fail the pipeline run if the agent did not commit its work and auto-commit was triggered.
|
|
108
|
-
* When false (default), auto-commit is a silent safety net and the run continues normally.
|
|
109
|
-
* When true, triggering auto-commit is treated as a pipeline error so the issue surfaces immediately. */
|
|
110
77
|
failOnAutoCommit: z.ZodOptional<z.ZodBoolean>;
|
|
111
|
-
},
|
|
112
|
-
review: {
|
|
113
|
-
requiredApprovals: number;
|
|
114
|
-
};
|
|
115
|
-
name: string;
|
|
116
|
-
stages: ("triage" | "await-approval" | "reproduce" | "implement" | "test" | "review")[];
|
|
117
|
-
retry: {
|
|
118
|
-
maxAttempts: number;
|
|
119
|
-
strategy: "fix-and-retry" | "escalate" | "fail-fast";
|
|
120
|
-
};
|
|
121
|
-
prStrategy: "draft" | "ready";
|
|
122
|
-
validateHandoffs?: boolean | undefined;
|
|
123
|
-
ralphIterations?: number | undefined;
|
|
124
|
-
reviewFixIterations?: number | undefined;
|
|
125
|
-
deepReviewPasses?: number | undefined;
|
|
126
|
-
maxDeepReviewPasses?: number | undefined;
|
|
127
|
-
autoMerge?: boolean | undefined;
|
|
128
|
-
autoMergeMaxLines?: number | undefined;
|
|
129
|
-
autoMergeExcludePatterns?: string[] | undefined;
|
|
130
|
-
autoMergeConfig?: {
|
|
131
|
-
minimumApprovingReviews?: number | undefined;
|
|
132
|
-
requiredStatusChecks?: string[] | undefined;
|
|
133
|
-
requiredLabels?: string[] | undefined;
|
|
134
|
-
allowedBranches?: string[] | undefined;
|
|
135
|
-
mergeMethod?: "merge" | "squash" | "rebase" | undefined;
|
|
136
|
-
} | undefined;
|
|
137
|
-
maxTokens?: number | undefined;
|
|
138
|
-
stageModels?: Record<string, string> | undefined;
|
|
139
|
-
failOnAutoCommit?: boolean | undefined;
|
|
140
|
-
}, {
|
|
141
|
-
review: {
|
|
142
|
-
requiredApprovals: number;
|
|
143
|
-
};
|
|
144
|
-
name: string;
|
|
145
|
-
stages: ("triage" | "await-approval" | "reproduce" | "implement" | "test" | "review")[];
|
|
146
|
-
retry: {
|
|
147
|
-
maxAttempts: number;
|
|
148
|
-
strategy: "fix-and-retry" | "escalate" | "fail-fast";
|
|
149
|
-
};
|
|
150
|
-
prStrategy: "draft" | "ready";
|
|
151
|
-
validateHandoffs?: boolean | undefined;
|
|
152
|
-
ralphIterations?: number | undefined;
|
|
153
|
-
reviewFixIterations?: number | undefined;
|
|
154
|
-
deepReviewPasses?: number | undefined;
|
|
155
|
-
maxDeepReviewPasses?: number | undefined;
|
|
156
|
-
autoMerge?: boolean | undefined;
|
|
157
|
-
autoMergeMaxLines?: number | undefined;
|
|
158
|
-
autoMergeExcludePatterns?: string[] | undefined;
|
|
159
|
-
autoMergeConfig?: {
|
|
160
|
-
minimumApprovingReviews?: number | undefined;
|
|
161
|
-
requiredStatusChecks?: string[] | undefined;
|
|
162
|
-
requiredLabels?: string[] | undefined;
|
|
163
|
-
allowedBranches?: string[] | undefined;
|
|
164
|
-
mergeMethod?: "merge" | "squash" | "rebase" | undefined;
|
|
165
|
-
} | undefined;
|
|
166
|
-
maxTokens?: number | undefined;
|
|
167
|
-
stageModels?: Record<string, string> | undefined;
|
|
168
|
-
failOnAutoCommit?: boolean | undefined;
|
|
169
|
-
}>;
|
|
78
|
+
}, z.core.$strip>;
|
|
170
79
|
export type PipelineConfig = z.infer<typeof PipelineConfigSchema>;
|
|
171
80
|
export declare const TriggerMapSchema: z.ZodObject<{
|
|
172
81
|
start: z.ZodString;
|
|
173
82
|
resume: z.ZodString;
|
|
174
83
|
pause: z.ZodString;
|
|
175
84
|
abort: z.ZodString;
|
|
176
|
-
},
|
|
177
|
-
start: string;
|
|
178
|
-
resume: string;
|
|
179
|
-
pause: string;
|
|
180
|
-
abort: string;
|
|
181
|
-
}, {
|
|
182
|
-
start: string;
|
|
183
|
-
resume: string;
|
|
184
|
-
pause: string;
|
|
185
|
-
abort: string;
|
|
186
|
-
}>;
|
|
85
|
+
}, z.core.$strip>;
|
|
187
86
|
export type TriggerMap = z.infer<typeof TriggerMapSchema>;
|
|
188
87
|
export declare const DEFAULT_TRIGGER_MAP: TriggerMap;
|
|
189
|
-
export declare const SetupCommandSchema: z.ZodArray<z.ZodString
|
|
88
|
+
export declare const SetupCommandSchema: z.ZodArray<z.ZodString>;
|
|
190
89
|
export type SetupCommand = z.infer<typeof SetupCommandSchema>;
|
|
191
90
|
export declare const McpServerEntrySchema: z.ZodObject<{
|
|
192
91
|
command: z.ZodString;
|
|
193
|
-
args: z.ZodOptional<z.ZodArray<z.ZodString
|
|
92
|
+
args: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
194
93
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
195
|
-
},
|
|
196
|
-
command: string;
|
|
197
|
-
args?: string[] | undefined;
|
|
198
|
-
env?: Record<string, string> | undefined;
|
|
199
|
-
}, {
|
|
200
|
-
command: string;
|
|
201
|
-
args?: string[] | undefined;
|
|
202
|
-
env?: Record<string, string> | undefined;
|
|
203
|
-
}>;
|
|
94
|
+
}, z.core.$strip>;
|
|
204
95
|
export declare const PluginEntrySchema: z.ZodObject<{
|
|
205
96
|
type: z.ZodLiteral<"local">;
|
|
206
97
|
path: z.ZodString;
|
|
207
|
-
},
|
|
208
|
-
path: string;
|
|
209
|
-
type: "local";
|
|
210
|
-
}, {
|
|
211
|
-
path: string;
|
|
212
|
-
type: "local";
|
|
213
|
-
}>;
|
|
98
|
+
}, z.core.$strip>;
|
|
214
99
|
export declare const PluginConfigSchema: z.ZodObject<{
|
|
215
|
-
/** Explicit MCP servers to always include */
|
|
216
100
|
mcpServers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
217
101
|
command: z.ZodString;
|
|
218
|
-
args: z.ZodOptional<z.ZodArray<z.ZodString
|
|
102
|
+
args: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
219
103
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
220
|
-
},
|
|
221
|
-
|
|
222
|
-
args?: string[] | undefined;
|
|
223
|
-
env?: Record<string, string> | undefined;
|
|
224
|
-
}, {
|
|
225
|
-
command: string;
|
|
226
|
-
args?: string[] | undefined;
|
|
227
|
-
env?: Record<string, string> | undefined;
|
|
228
|
-
}>>>;
|
|
229
|
-
/** MCP server names to never include */
|
|
230
|
-
excludeMcpServers: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
231
|
-
/** Explicit plugins to always include */
|
|
104
|
+
}, z.core.$strip>>>;
|
|
105
|
+
excludeMcpServers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
232
106
|
plugins: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
233
107
|
type: z.ZodLiteral<"local">;
|
|
234
108
|
path: z.ZodString;
|
|
235
|
-
},
|
|
236
|
-
|
|
237
|
-
type: "local";
|
|
238
|
-
}, {
|
|
239
|
-
path: string;
|
|
240
|
-
type: "local";
|
|
241
|
-
}>, "many">>;
|
|
242
|
-
/** Plugin paths to never include */
|
|
243
|
-
excludePlugins: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
244
|
-
/** Set to false to disable auto-detection of plugins/MCP servers */
|
|
109
|
+
}, z.core.$strip>>>;
|
|
110
|
+
excludePlugins: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
245
111
|
autoDetect: z.ZodOptional<z.ZodBoolean>;
|
|
246
|
-
},
|
|
247
|
-
mcpServers?: Record<string, {
|
|
248
|
-
command: string;
|
|
249
|
-
args?: string[] | undefined;
|
|
250
|
-
env?: Record<string, string> | undefined;
|
|
251
|
-
}> | undefined;
|
|
252
|
-
excludeMcpServers?: string[] | undefined;
|
|
253
|
-
plugins?: {
|
|
254
|
-
path: string;
|
|
255
|
-
type: "local";
|
|
256
|
-
}[] | undefined;
|
|
257
|
-
excludePlugins?: string[] | undefined;
|
|
258
|
-
autoDetect?: boolean | undefined;
|
|
259
|
-
}, {
|
|
260
|
-
mcpServers?: Record<string, {
|
|
261
|
-
command: string;
|
|
262
|
-
args?: string[] | undefined;
|
|
263
|
-
env?: Record<string, string> | undefined;
|
|
264
|
-
}> | undefined;
|
|
265
|
-
excludeMcpServers?: string[] | undefined;
|
|
266
|
-
plugins?: {
|
|
267
|
-
path: string;
|
|
268
|
-
type: "local";
|
|
269
|
-
}[] | undefined;
|
|
270
|
-
excludePlugins?: string[] | undefined;
|
|
271
|
-
autoDetect?: boolean | undefined;
|
|
272
|
-
}>;
|
|
112
|
+
}, z.core.$strip>;
|
|
273
113
|
export type PluginConfig = z.infer<typeof PluginConfigSchema>;
|
|
274
114
|
export declare const DevcontainerConfigSchema: z.ZodObject<{
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
115
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
116
|
+
never: "never";
|
|
117
|
+
auto: "auto";
|
|
118
|
+
always: "always";
|
|
119
|
+
}>>;
|
|
278
120
|
configPath: z.ZodOptional<z.ZodString>;
|
|
279
|
-
/** Extra environment variables for the container */
|
|
280
121
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
281
|
-
},
|
|
282
|
-
env?: Record<string, string> | undefined;
|
|
283
|
-
mode?: "never" | "auto" | "always" | undefined;
|
|
284
|
-
configPath?: string | undefined;
|
|
285
|
-
}, {
|
|
286
|
-
env?: Record<string, string> | undefined;
|
|
287
|
-
mode?: "never" | "auto" | "always" | undefined;
|
|
288
|
-
configPath?: string | undefined;
|
|
289
|
-
}>;
|
|
122
|
+
}, z.core.$strip>;
|
|
290
123
|
export type DevcontainerConfig = z.infer<typeof DevcontainerConfigSchema>;
|
|
291
124
|
export declare const GitHubFeedbackConfigSchema: z.ZodObject<{
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
* If empty/omitted, any reviewer can trigger.
|
|
295
|
-
*/
|
|
296
|
-
allowedReviewers: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
297
|
-
/**
|
|
298
|
-
* GitHub logins that should never trigger feedback runs (e.g. the bot itself).
|
|
299
|
-
*/
|
|
300
|
-
botLogins: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
301
|
-
/**
|
|
302
|
-
* If provided, only comments containing this keyword trigger a feedback run.
|
|
303
|
-
* When omitted and autoTrigger is true (the default), any qualifying comment triggers.
|
|
304
|
-
* Example: "@agent fix this"
|
|
305
|
-
*/
|
|
125
|
+
allowedReviewers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
126
|
+
botLogins: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
306
127
|
triggerKeyword: z.ZodOptional<z.ZodString>;
|
|
307
|
-
/**
|
|
308
|
-
* If true (default), any qualifying review comment automatically triggers a feedback run.
|
|
309
|
-
* Set to false to require the triggerKeyword to be present.
|
|
310
|
-
*/
|
|
311
128
|
autoTrigger: z.ZodOptional<z.ZodBoolean>;
|
|
312
|
-
/**
|
|
313
|
-
* If true, re-request review on the PR after the feedback run pushes changes.
|
|
314
|
-
* Requires GitHub App credentials in server config. Default: false.
|
|
315
|
-
*/
|
|
316
129
|
rerequestReview: z.ZodOptional<z.ZodBoolean>;
|
|
317
|
-
},
|
|
318
|
-
allowedReviewers?: string[] | undefined;
|
|
319
|
-
botLogins?: string[] | undefined;
|
|
320
|
-
triggerKeyword?: string | undefined;
|
|
321
|
-
autoTrigger?: boolean | undefined;
|
|
322
|
-
rerequestReview?: boolean | undefined;
|
|
323
|
-
}, {
|
|
324
|
-
allowedReviewers?: string[] | undefined;
|
|
325
|
-
botLogins?: string[] | undefined;
|
|
326
|
-
triggerKeyword?: string | undefined;
|
|
327
|
-
autoTrigger?: boolean | undefined;
|
|
328
|
-
rerequestReview?: boolean | undefined;
|
|
329
|
-
}>;
|
|
130
|
+
}, z.core.$strip>;
|
|
330
131
|
export type GitHubFeedbackConfig = z.infer<typeof GitHubFeedbackConfigSchema>;
|
|
331
132
|
export declare const RepoConfigSchema: z.ZodObject<{
|
|
332
133
|
url: z.ZodString;
|
|
333
134
|
defaultBranch: z.ZodString;
|
|
334
135
|
testCommand: z.ZodString;
|
|
335
136
|
buildCommand: z.ZodString;
|
|
336
|
-
setupCommands: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodString
|
|
137
|
+
setupCommands: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodString>>>;
|
|
337
138
|
workingDirectory: z.ZodOptional<z.ZodString>;
|
|
338
139
|
plugins: z.ZodOptional<z.ZodObject<{
|
|
339
|
-
/** Explicit MCP servers to always include */
|
|
340
140
|
mcpServers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
341
141
|
command: z.ZodString;
|
|
342
|
-
args: z.ZodOptional<z.ZodArray<z.ZodString
|
|
142
|
+
args: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
343
143
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
344
|
-
},
|
|
345
|
-
|
|
346
|
-
args?: string[] | undefined;
|
|
347
|
-
env?: Record<string, string> | undefined;
|
|
348
|
-
}, {
|
|
349
|
-
command: string;
|
|
350
|
-
args?: string[] | undefined;
|
|
351
|
-
env?: Record<string, string> | undefined;
|
|
352
|
-
}>>>;
|
|
353
|
-
/** MCP server names to never include */
|
|
354
|
-
excludeMcpServers: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
355
|
-
/** Explicit plugins to always include */
|
|
144
|
+
}, z.core.$strip>>>;
|
|
145
|
+
excludeMcpServers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
356
146
|
plugins: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
357
147
|
type: z.ZodLiteral<"local">;
|
|
358
148
|
path: z.ZodString;
|
|
359
|
-
},
|
|
360
|
-
|
|
361
|
-
type: "local";
|
|
362
|
-
}, {
|
|
363
|
-
path: string;
|
|
364
|
-
type: "local";
|
|
365
|
-
}>, "many">>;
|
|
366
|
-
/** Plugin paths to never include */
|
|
367
|
-
excludePlugins: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
368
|
-
/** Set to false to disable auto-detection of plugins/MCP servers */
|
|
149
|
+
}, z.core.$strip>>>;
|
|
150
|
+
excludePlugins: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
369
151
|
autoDetect: z.ZodOptional<z.ZodBoolean>;
|
|
370
|
-
},
|
|
371
|
-
mcpServers?: Record<string, {
|
|
372
|
-
command: string;
|
|
373
|
-
args?: string[] | undefined;
|
|
374
|
-
env?: Record<string, string> | undefined;
|
|
375
|
-
}> | undefined;
|
|
376
|
-
excludeMcpServers?: string[] | undefined;
|
|
377
|
-
plugins?: {
|
|
378
|
-
path: string;
|
|
379
|
-
type: "local";
|
|
380
|
-
}[] | undefined;
|
|
381
|
-
excludePlugins?: string[] | undefined;
|
|
382
|
-
autoDetect?: boolean | undefined;
|
|
383
|
-
}, {
|
|
384
|
-
mcpServers?: Record<string, {
|
|
385
|
-
command: string;
|
|
386
|
-
args?: string[] | undefined;
|
|
387
|
-
env?: Record<string, string> | undefined;
|
|
388
|
-
}> | undefined;
|
|
389
|
-
excludeMcpServers?: string[] | undefined;
|
|
390
|
-
plugins?: {
|
|
391
|
-
path: string;
|
|
392
|
-
type: "local";
|
|
393
|
-
}[] | undefined;
|
|
394
|
-
excludePlugins?: string[] | undefined;
|
|
395
|
-
autoDetect?: boolean | undefined;
|
|
396
|
-
}>>;
|
|
152
|
+
}, z.core.$strip>>;
|
|
397
153
|
devcontainer: z.ZodOptional<z.ZodObject<{
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
154
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
155
|
+
never: "never";
|
|
156
|
+
auto: "auto";
|
|
157
|
+
always: "always";
|
|
158
|
+
}>>;
|
|
401
159
|
configPath: z.ZodOptional<z.ZodString>;
|
|
402
|
-
/** Extra environment variables for the container */
|
|
403
160
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
404
|
-
},
|
|
405
|
-
env?: Record<string, string> | undefined;
|
|
406
|
-
mode?: "never" | "auto" | "always" | undefined;
|
|
407
|
-
configPath?: string | undefined;
|
|
408
|
-
}, {
|
|
409
|
-
env?: Record<string, string> | undefined;
|
|
410
|
-
mode?: "never" | "auto" | "always" | undefined;
|
|
411
|
-
configPath?: string | undefined;
|
|
412
|
-
}>>;
|
|
413
|
-
/** Per-team trigger map. Overrides the global triggerMap for this team's repo. Falls back to DEFAULT_TRIGGER_MAP. */
|
|
161
|
+
}, z.core.$strip>>;
|
|
414
162
|
triggerMap: z.ZodOptional<z.ZodObject<{
|
|
415
163
|
start: z.ZodString;
|
|
416
164
|
resume: z.ZodString;
|
|
417
165
|
pause: z.ZodString;
|
|
418
166
|
abort: z.ZodString;
|
|
419
|
-
},
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
abort: string;
|
|
424
|
-
}, {
|
|
425
|
-
start: string;
|
|
426
|
-
resume: string;
|
|
427
|
-
pause: string;
|
|
428
|
-
abort: string;
|
|
167
|
+
}, z.core.$strip>>;
|
|
168
|
+
provider: z.ZodOptional<z.ZodEnum<{
|
|
169
|
+
github: "github";
|
|
170
|
+
gitlab: "gitlab";
|
|
429
171
|
}>>;
|
|
430
|
-
/** Hosting provider. Defaults to "github". Set to "gitlab" for GitLab repos. */
|
|
431
|
-
provider: z.ZodOptional<z.ZodEnum<["github", "gitlab"]>>;
|
|
432
|
-
/** Configuration for GitHub PR review comment → pipeline re-entry (feedback runs). */
|
|
433
172
|
githubFeedback: z.ZodOptional<z.ZodObject<{
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
* If empty/omitted, any reviewer can trigger.
|
|
437
|
-
*/
|
|
438
|
-
allowedReviewers: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
439
|
-
/**
|
|
440
|
-
* GitHub logins that should never trigger feedback runs (e.g. the bot itself).
|
|
441
|
-
*/
|
|
442
|
-
botLogins: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
443
|
-
/**
|
|
444
|
-
* If provided, only comments containing this keyword trigger a feedback run.
|
|
445
|
-
* When omitted and autoTrigger is true (the default), any qualifying comment triggers.
|
|
446
|
-
* Example: "@agent fix this"
|
|
447
|
-
*/
|
|
173
|
+
allowedReviewers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
174
|
+
botLogins: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
448
175
|
triggerKeyword: z.ZodOptional<z.ZodString>;
|
|
449
|
-
/**
|
|
450
|
-
* If true (default), any qualifying review comment automatically triggers a feedback run.
|
|
451
|
-
* Set to false to require the triggerKeyword to be present.
|
|
452
|
-
*/
|
|
453
176
|
autoTrigger: z.ZodOptional<z.ZodBoolean>;
|
|
454
|
-
/**
|
|
455
|
-
* If true, re-request review on the PR after the feedback run pushes changes.
|
|
456
|
-
* Requires GitHub App credentials in server config. Default: false.
|
|
457
|
-
*/
|
|
458
177
|
rerequestReview: z.ZodOptional<z.ZodBoolean>;
|
|
459
|
-
},
|
|
460
|
-
|
|
461
|
-
botLogins?: string[] | undefined;
|
|
462
|
-
triggerKeyword?: string | undefined;
|
|
463
|
-
autoTrigger?: boolean | undefined;
|
|
464
|
-
rerequestReview?: boolean | undefined;
|
|
465
|
-
}, {
|
|
466
|
-
allowedReviewers?: string[] | undefined;
|
|
467
|
-
botLogins?: string[] | undefined;
|
|
468
|
-
triggerKeyword?: string | undefined;
|
|
469
|
-
autoTrigger?: boolean | undefined;
|
|
470
|
-
rerequestReview?: boolean | undefined;
|
|
471
|
-
}>>;
|
|
472
|
-
}, "strip", z.ZodTypeAny, {
|
|
473
|
-
url: string;
|
|
474
|
-
defaultBranch: string;
|
|
475
|
-
testCommand: string;
|
|
476
|
-
buildCommand: string;
|
|
477
|
-
plugins?: {
|
|
478
|
-
mcpServers?: Record<string, {
|
|
479
|
-
command: string;
|
|
480
|
-
args?: string[] | undefined;
|
|
481
|
-
env?: Record<string, string> | undefined;
|
|
482
|
-
}> | undefined;
|
|
483
|
-
excludeMcpServers?: string[] | undefined;
|
|
484
|
-
plugins?: {
|
|
485
|
-
path: string;
|
|
486
|
-
type: "local";
|
|
487
|
-
}[] | undefined;
|
|
488
|
-
excludePlugins?: string[] | undefined;
|
|
489
|
-
autoDetect?: boolean | undefined;
|
|
490
|
-
} | undefined;
|
|
491
|
-
setupCommands?: string[][] | undefined;
|
|
492
|
-
workingDirectory?: string | undefined;
|
|
493
|
-
devcontainer?: {
|
|
494
|
-
env?: Record<string, string> | undefined;
|
|
495
|
-
mode?: "never" | "auto" | "always" | undefined;
|
|
496
|
-
configPath?: string | undefined;
|
|
497
|
-
} | undefined;
|
|
498
|
-
triggerMap?: {
|
|
499
|
-
start: string;
|
|
500
|
-
resume: string;
|
|
501
|
-
pause: string;
|
|
502
|
-
abort: string;
|
|
503
|
-
} | undefined;
|
|
504
|
-
provider?: "github" | "gitlab" | undefined;
|
|
505
|
-
githubFeedback?: {
|
|
506
|
-
allowedReviewers?: string[] | undefined;
|
|
507
|
-
botLogins?: string[] | undefined;
|
|
508
|
-
triggerKeyword?: string | undefined;
|
|
509
|
-
autoTrigger?: boolean | undefined;
|
|
510
|
-
rerequestReview?: boolean | undefined;
|
|
511
|
-
} | undefined;
|
|
512
|
-
}, {
|
|
513
|
-
url: string;
|
|
514
|
-
defaultBranch: string;
|
|
515
|
-
testCommand: string;
|
|
516
|
-
buildCommand: string;
|
|
517
|
-
plugins?: {
|
|
518
|
-
mcpServers?: Record<string, {
|
|
519
|
-
command: string;
|
|
520
|
-
args?: string[] | undefined;
|
|
521
|
-
env?: Record<string, string> | undefined;
|
|
522
|
-
}> | undefined;
|
|
523
|
-
excludeMcpServers?: string[] | undefined;
|
|
524
|
-
plugins?: {
|
|
525
|
-
path: string;
|
|
526
|
-
type: "local";
|
|
527
|
-
}[] | undefined;
|
|
528
|
-
excludePlugins?: string[] | undefined;
|
|
529
|
-
autoDetect?: boolean | undefined;
|
|
530
|
-
} | undefined;
|
|
531
|
-
setupCommands?: string[][] | undefined;
|
|
532
|
-
workingDirectory?: string | undefined;
|
|
533
|
-
devcontainer?: {
|
|
534
|
-
env?: Record<string, string> | undefined;
|
|
535
|
-
mode?: "never" | "auto" | "always" | undefined;
|
|
536
|
-
configPath?: string | undefined;
|
|
537
|
-
} | undefined;
|
|
538
|
-
triggerMap?: {
|
|
539
|
-
start: string;
|
|
540
|
-
resume: string;
|
|
541
|
-
pause: string;
|
|
542
|
-
abort: string;
|
|
543
|
-
} | undefined;
|
|
544
|
-
provider?: "github" | "gitlab" | undefined;
|
|
545
|
-
githubFeedback?: {
|
|
546
|
-
allowedReviewers?: string[] | undefined;
|
|
547
|
-
botLogins?: string[] | undefined;
|
|
548
|
-
triggerKeyword?: string | undefined;
|
|
549
|
-
autoTrigger?: boolean | undefined;
|
|
550
|
-
rerequestReview?: boolean | undefined;
|
|
551
|
-
} | undefined;
|
|
552
|
-
}>;
|
|
178
|
+
}, z.core.$strip>>;
|
|
179
|
+
}, z.core.$strip>;
|
|
553
180
|
export type RepoConfig = z.infer<typeof RepoConfigSchema>;
|
|
554
181
|
export declare const TestResultSchema: z.ZodObject<{
|
|
555
182
|
passed: z.ZodNumber;
|
|
@@ -558,55 +185,21 @@ export declare const TestResultSchema: z.ZodObject<{
|
|
|
558
185
|
test: z.ZodString;
|
|
559
186
|
error: z.ZodString;
|
|
560
187
|
file: z.ZodString;
|
|
561
|
-
},
|
|
562
|
-
|
|
563
|
-
error: string;
|
|
564
|
-
file: string;
|
|
565
|
-
}, {
|
|
566
|
-
test: string;
|
|
567
|
-
error: string;
|
|
568
|
-
file: string;
|
|
569
|
-
}>>;
|
|
570
|
-
}, "strip", z.ZodTypeAny, {
|
|
571
|
-
passed: number;
|
|
572
|
-
failed: number;
|
|
573
|
-
firstFailure?: {
|
|
574
|
-
test: string;
|
|
575
|
-
error: string;
|
|
576
|
-
file: string;
|
|
577
|
-
} | undefined;
|
|
578
|
-
}, {
|
|
579
|
-
passed: number;
|
|
580
|
-
failed: number;
|
|
581
|
-
firstFailure?: {
|
|
582
|
-
test: string;
|
|
583
|
-
error: string;
|
|
584
|
-
file: string;
|
|
585
|
-
} | undefined;
|
|
586
|
-
}>;
|
|
188
|
+
}, z.core.$strip>>;
|
|
189
|
+
}, z.core.$strip>;
|
|
587
190
|
export type TestResult = z.infer<typeof TestResultSchema>;
|
|
588
191
|
export declare const ReviewFindingSchema: z.ZodObject<{
|
|
589
|
-
severity: z.ZodEnum<
|
|
192
|
+
severity: z.ZodEnum<{
|
|
193
|
+
blocking: "blocking";
|
|
194
|
+
warning: "warning";
|
|
195
|
+
suggestion: "suggestion";
|
|
196
|
+
}>;
|
|
590
197
|
file: z.ZodString;
|
|
591
198
|
line: z.ZodNumber;
|
|
592
199
|
category: z.ZodString;
|
|
593
200
|
description: z.ZodString;
|
|
594
201
|
fix: z.ZodString;
|
|
595
|
-
},
|
|
596
|
-
file: string;
|
|
597
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
598
|
-
line: number;
|
|
599
|
-
category: string;
|
|
600
|
-
description: string;
|
|
601
|
-
fix: string;
|
|
602
|
-
}, {
|
|
603
|
-
file: string;
|
|
604
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
605
|
-
line: number;
|
|
606
|
-
category: string;
|
|
607
|
-
description: string;
|
|
608
|
-
fix: string;
|
|
609
|
-
}>;
|
|
202
|
+
}, z.core.$strip>;
|
|
610
203
|
export type ReviewFinding = z.infer<typeof ReviewFindingSchema>;
|
|
611
204
|
export declare const HandoffArtifactSchema: z.ZodObject<{
|
|
612
205
|
runId: z.ZodString;
|
|
@@ -614,12 +207,12 @@ export declare const HandoffArtifactSchema: z.ZodObject<{
|
|
|
614
207
|
stage: z.ZodString;
|
|
615
208
|
timestamp: z.ZodString;
|
|
616
209
|
summary: z.ZodString;
|
|
617
|
-
filesChanged: z.ZodArray<z.ZodString
|
|
210
|
+
filesChanged: z.ZodArray<z.ZodString>;
|
|
618
211
|
approach: z.ZodString;
|
|
619
212
|
context: z.ZodObject<{
|
|
620
213
|
issueIntent: z.ZodString;
|
|
621
|
-
constraints: z.ZodArray<z.ZodString
|
|
622
|
-
assumptions: z.ZodArray<z.ZodString
|
|
214
|
+
constraints: z.ZodArray<z.ZodString>;
|
|
215
|
+
assumptions: z.ZodArray<z.ZodString>;
|
|
623
216
|
testResults: z.ZodOptional<z.ZodObject<{
|
|
624
217
|
passed: z.ZodNumber;
|
|
625
218
|
failed: z.ZodNumber;
|
|
@@ -627,176 +220,26 @@ export declare const HandoffArtifactSchema: z.ZodObject<{
|
|
|
627
220
|
test: z.ZodString;
|
|
628
221
|
error: z.ZodString;
|
|
629
222
|
file: z.ZodString;
|
|
630
|
-
},
|
|
631
|
-
|
|
632
|
-
error: string;
|
|
633
|
-
file: string;
|
|
634
|
-
}, {
|
|
635
|
-
test: string;
|
|
636
|
-
error: string;
|
|
637
|
-
file: string;
|
|
638
|
-
}>>;
|
|
639
|
-
}, "strip", z.ZodTypeAny, {
|
|
640
|
-
passed: number;
|
|
641
|
-
failed: number;
|
|
642
|
-
firstFailure?: {
|
|
643
|
-
test: string;
|
|
644
|
-
error: string;
|
|
645
|
-
file: string;
|
|
646
|
-
} | undefined;
|
|
647
|
-
}, {
|
|
648
|
-
passed: number;
|
|
649
|
-
failed: number;
|
|
650
|
-
firstFailure?: {
|
|
651
|
-
test: string;
|
|
652
|
-
error: string;
|
|
653
|
-
file: string;
|
|
654
|
-
} | undefined;
|
|
655
|
-
}>>;
|
|
223
|
+
}, z.core.$strip>>;
|
|
224
|
+
}, z.core.$strip>>;
|
|
656
225
|
reviewFindings: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
657
|
-
severity: z.ZodEnum<
|
|
226
|
+
severity: z.ZodEnum<{
|
|
227
|
+
blocking: "blocking";
|
|
228
|
+
warning: "warning";
|
|
229
|
+
suggestion: "suggestion";
|
|
230
|
+
}>;
|
|
658
231
|
file: z.ZodString;
|
|
659
232
|
line: z.ZodNumber;
|
|
660
233
|
category: z.ZodString;
|
|
661
234
|
description: z.ZodString;
|
|
662
235
|
fix: z.ZodString;
|
|
663
|
-
},
|
|
664
|
-
|
|
665
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
666
|
-
line: number;
|
|
667
|
-
category: string;
|
|
668
|
-
description: string;
|
|
669
|
-
fix: string;
|
|
670
|
-
}, {
|
|
671
|
-
file: string;
|
|
672
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
673
|
-
line: number;
|
|
674
|
-
category: string;
|
|
675
|
-
description: string;
|
|
676
|
-
fix: string;
|
|
677
|
-
}>, "many">>;
|
|
678
|
-
}, "strip", z.ZodTypeAny, {
|
|
679
|
-
issueIntent: string;
|
|
680
|
-
constraints: string[];
|
|
681
|
-
assumptions: string[];
|
|
682
|
-
testResults?: {
|
|
683
|
-
passed: number;
|
|
684
|
-
failed: number;
|
|
685
|
-
firstFailure?: {
|
|
686
|
-
test: string;
|
|
687
|
-
error: string;
|
|
688
|
-
file: string;
|
|
689
|
-
} | undefined;
|
|
690
|
-
} | undefined;
|
|
691
|
-
reviewFindings?: {
|
|
692
|
-
file: string;
|
|
693
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
694
|
-
line: number;
|
|
695
|
-
category: string;
|
|
696
|
-
description: string;
|
|
697
|
-
fix: string;
|
|
698
|
-
}[] | undefined;
|
|
699
|
-
}, {
|
|
700
|
-
issueIntent: string;
|
|
701
|
-
constraints: string[];
|
|
702
|
-
assumptions: string[];
|
|
703
|
-
testResults?: {
|
|
704
|
-
passed: number;
|
|
705
|
-
failed: number;
|
|
706
|
-
firstFailure?: {
|
|
707
|
-
test: string;
|
|
708
|
-
error: string;
|
|
709
|
-
file: string;
|
|
710
|
-
} | undefined;
|
|
711
|
-
} | undefined;
|
|
712
|
-
reviewFindings?: {
|
|
713
|
-
file: string;
|
|
714
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
715
|
-
line: number;
|
|
716
|
-
category: string;
|
|
717
|
-
description: string;
|
|
718
|
-
fix: string;
|
|
719
|
-
}[] | undefined;
|
|
720
|
-
}>;
|
|
236
|
+
}, z.core.$strip>>>;
|
|
237
|
+
}, z.core.$strip>;
|
|
721
238
|
tokenBudget: z.ZodObject<{
|
|
722
239
|
contextTokensUsed: z.ZodNumber;
|
|
723
240
|
recommendedMaxTurns: z.ZodNumber;
|
|
724
|
-
},
|
|
725
|
-
|
|
726
|
-
recommendedMaxTurns: number;
|
|
727
|
-
}, {
|
|
728
|
-
contextTokensUsed: number;
|
|
729
|
-
recommendedMaxTurns: number;
|
|
730
|
-
}>;
|
|
731
|
-
}, "strip", z.ZodTypeAny, {
|
|
732
|
-
runId: string;
|
|
733
|
-
issueId: string;
|
|
734
|
-
stage: string;
|
|
735
|
-
timestamp: string;
|
|
736
|
-
summary: string;
|
|
737
|
-
filesChanged: string[];
|
|
738
|
-
approach: string;
|
|
739
|
-
context: {
|
|
740
|
-
issueIntent: string;
|
|
741
|
-
constraints: string[];
|
|
742
|
-
assumptions: string[];
|
|
743
|
-
testResults?: {
|
|
744
|
-
passed: number;
|
|
745
|
-
failed: number;
|
|
746
|
-
firstFailure?: {
|
|
747
|
-
test: string;
|
|
748
|
-
error: string;
|
|
749
|
-
file: string;
|
|
750
|
-
} | undefined;
|
|
751
|
-
} | undefined;
|
|
752
|
-
reviewFindings?: {
|
|
753
|
-
file: string;
|
|
754
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
755
|
-
line: number;
|
|
756
|
-
category: string;
|
|
757
|
-
description: string;
|
|
758
|
-
fix: string;
|
|
759
|
-
}[] | undefined;
|
|
760
|
-
};
|
|
761
|
-
tokenBudget: {
|
|
762
|
-
contextTokensUsed: number;
|
|
763
|
-
recommendedMaxTurns: number;
|
|
764
|
-
};
|
|
765
|
-
}, {
|
|
766
|
-
runId: string;
|
|
767
|
-
issueId: string;
|
|
768
|
-
stage: string;
|
|
769
|
-
timestamp: string;
|
|
770
|
-
summary: string;
|
|
771
|
-
filesChanged: string[];
|
|
772
|
-
approach: string;
|
|
773
|
-
context: {
|
|
774
|
-
issueIntent: string;
|
|
775
|
-
constraints: string[];
|
|
776
|
-
assumptions: string[];
|
|
777
|
-
testResults?: {
|
|
778
|
-
passed: number;
|
|
779
|
-
failed: number;
|
|
780
|
-
firstFailure?: {
|
|
781
|
-
test: string;
|
|
782
|
-
error: string;
|
|
783
|
-
file: string;
|
|
784
|
-
} | undefined;
|
|
785
|
-
} | undefined;
|
|
786
|
-
reviewFindings?: {
|
|
787
|
-
file: string;
|
|
788
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
789
|
-
line: number;
|
|
790
|
-
category: string;
|
|
791
|
-
description: string;
|
|
792
|
-
fix: string;
|
|
793
|
-
}[] | undefined;
|
|
794
|
-
};
|
|
795
|
-
tokenBudget: {
|
|
796
|
-
contextTokensUsed: number;
|
|
797
|
-
recommendedMaxTurns: number;
|
|
798
|
-
};
|
|
799
|
-
}>;
|
|
241
|
+
}, z.core.$strip>;
|
|
242
|
+
}, z.core.$strip>;
|
|
800
243
|
export type HandoffArtifact = z.infer<typeof HandoffArtifactSchema>;
|
|
801
244
|
export declare const ReviewCommentSchema: z.ZodObject<{
|
|
802
245
|
author: z.ZodString;
|
|
@@ -805,28 +248,11 @@ export declare const ReviewCommentSchema: z.ZodObject<{
|
|
|
805
248
|
line: z.ZodOptional<z.ZodNumber>;
|
|
806
249
|
diffHunk: z.ZodOptional<z.ZodString>;
|
|
807
250
|
createdAt: z.ZodString;
|
|
808
|
-
},
|
|
809
|
-
author: string;
|
|
810
|
-
body: string;
|
|
811
|
-
createdAt: string;
|
|
812
|
-
file?: string | undefined;
|
|
813
|
-
line?: number | undefined;
|
|
814
|
-
diffHunk?: string | undefined;
|
|
815
|
-
}, {
|
|
816
|
-
author: string;
|
|
817
|
-
body: string;
|
|
818
|
-
createdAt: string;
|
|
819
|
-
file?: string | undefined;
|
|
820
|
-
line?: number | undefined;
|
|
821
|
-
diffHunk?: string | undefined;
|
|
822
|
-
}>;
|
|
251
|
+
}, z.core.$strip>;
|
|
823
252
|
export type ReviewComment = z.infer<typeof ReviewCommentSchema>;
|
|
824
253
|
export declare const ReviewFeedbackContextSchema: z.ZodObject<{
|
|
825
|
-
/** The URL of the PR being reviewed. */
|
|
826
254
|
prUrl: z.ZodString;
|
|
827
|
-
/** The branch to push fixes to (the existing PR branch). */
|
|
828
255
|
prBranch: z.ZodString;
|
|
829
|
-
/** Inline review comments with file/line context. */
|
|
830
256
|
comments: z.ZodArray<z.ZodObject<{
|
|
831
257
|
author: z.ZodString;
|
|
832
258
|
body: z.ZodString;
|
|
@@ -834,36 +260,20 @@ export declare const ReviewFeedbackContextSchema: z.ZodObject<{
|
|
|
834
260
|
line: z.ZodOptional<z.ZodNumber>;
|
|
835
261
|
diffHunk: z.ZodOptional<z.ZodString>;
|
|
836
262
|
createdAt: z.ZodString;
|
|
837
|
-
},
|
|
838
|
-
author: string;
|
|
839
|
-
body: string;
|
|
840
|
-
createdAt: string;
|
|
841
|
-
file?: string | undefined;
|
|
842
|
-
line?: number | undefined;
|
|
843
|
-
diffHunk?: string | undefined;
|
|
844
|
-
}, {
|
|
845
|
-
author: string;
|
|
846
|
-
body: string;
|
|
847
|
-
createdAt: string;
|
|
848
|
-
file?: string | undefined;
|
|
849
|
-
line?: number | undefined;
|
|
850
|
-
diffHunk?: string | undefined;
|
|
851
|
-
}>, "many">;
|
|
852
|
-
/** Optional overall review summary body (for full reviews, not just inline comments). */
|
|
263
|
+
}, z.core.$strip>>;
|
|
853
264
|
reviewBody: z.ZodOptional<z.ZodString>;
|
|
854
|
-
/** The original implement handoff, for context on what was done. */
|
|
855
265
|
previousHandoff: z.ZodOptional<z.ZodObject<{
|
|
856
266
|
runId: z.ZodString;
|
|
857
267
|
issueId: z.ZodString;
|
|
858
268
|
stage: z.ZodString;
|
|
859
269
|
timestamp: z.ZodString;
|
|
860
270
|
summary: z.ZodString;
|
|
861
|
-
filesChanged: z.ZodArray<z.ZodString
|
|
271
|
+
filesChanged: z.ZodArray<z.ZodString>;
|
|
862
272
|
approach: z.ZodString;
|
|
863
273
|
context: z.ZodObject<{
|
|
864
274
|
issueIntent: z.ZodString;
|
|
865
|
-
constraints: z.ZodArray<z.ZodString
|
|
866
|
-
assumptions: z.ZodArray<z.ZodString
|
|
275
|
+
constraints: z.ZodArray<z.ZodString>;
|
|
276
|
+
assumptions: z.ZodArray<z.ZodString>;
|
|
867
277
|
testResults: z.ZodOptional<z.ZodObject<{
|
|
868
278
|
passed: z.ZodNumber;
|
|
869
279
|
failed: z.ZodNumber;
|
|
@@ -871,271 +281,27 @@ export declare const ReviewFeedbackContextSchema: z.ZodObject<{
|
|
|
871
281
|
test: z.ZodString;
|
|
872
282
|
error: z.ZodString;
|
|
873
283
|
file: z.ZodString;
|
|
874
|
-
},
|
|
875
|
-
|
|
876
|
-
error: string;
|
|
877
|
-
file: string;
|
|
878
|
-
}, {
|
|
879
|
-
test: string;
|
|
880
|
-
error: string;
|
|
881
|
-
file: string;
|
|
882
|
-
}>>;
|
|
883
|
-
}, "strip", z.ZodTypeAny, {
|
|
884
|
-
passed: number;
|
|
885
|
-
failed: number;
|
|
886
|
-
firstFailure?: {
|
|
887
|
-
test: string;
|
|
888
|
-
error: string;
|
|
889
|
-
file: string;
|
|
890
|
-
} | undefined;
|
|
891
|
-
}, {
|
|
892
|
-
passed: number;
|
|
893
|
-
failed: number;
|
|
894
|
-
firstFailure?: {
|
|
895
|
-
test: string;
|
|
896
|
-
error: string;
|
|
897
|
-
file: string;
|
|
898
|
-
} | undefined;
|
|
899
|
-
}>>;
|
|
284
|
+
}, z.core.$strip>>;
|
|
285
|
+
}, z.core.$strip>>;
|
|
900
286
|
reviewFindings: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
901
|
-
severity: z.ZodEnum<
|
|
287
|
+
severity: z.ZodEnum<{
|
|
288
|
+
blocking: "blocking";
|
|
289
|
+
warning: "warning";
|
|
290
|
+
suggestion: "suggestion";
|
|
291
|
+
}>;
|
|
902
292
|
file: z.ZodString;
|
|
903
293
|
line: z.ZodNumber;
|
|
904
294
|
category: z.ZodString;
|
|
905
295
|
description: z.ZodString;
|
|
906
296
|
fix: z.ZodString;
|
|
907
|
-
},
|
|
908
|
-
|
|
909
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
910
|
-
line: number;
|
|
911
|
-
category: string;
|
|
912
|
-
description: string;
|
|
913
|
-
fix: string;
|
|
914
|
-
}, {
|
|
915
|
-
file: string;
|
|
916
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
917
|
-
line: number;
|
|
918
|
-
category: string;
|
|
919
|
-
description: string;
|
|
920
|
-
fix: string;
|
|
921
|
-
}>, "many">>;
|
|
922
|
-
}, "strip", z.ZodTypeAny, {
|
|
923
|
-
issueIntent: string;
|
|
924
|
-
constraints: string[];
|
|
925
|
-
assumptions: string[];
|
|
926
|
-
testResults?: {
|
|
927
|
-
passed: number;
|
|
928
|
-
failed: number;
|
|
929
|
-
firstFailure?: {
|
|
930
|
-
test: string;
|
|
931
|
-
error: string;
|
|
932
|
-
file: string;
|
|
933
|
-
} | undefined;
|
|
934
|
-
} | undefined;
|
|
935
|
-
reviewFindings?: {
|
|
936
|
-
file: string;
|
|
937
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
938
|
-
line: number;
|
|
939
|
-
category: string;
|
|
940
|
-
description: string;
|
|
941
|
-
fix: string;
|
|
942
|
-
}[] | undefined;
|
|
943
|
-
}, {
|
|
944
|
-
issueIntent: string;
|
|
945
|
-
constraints: string[];
|
|
946
|
-
assumptions: string[];
|
|
947
|
-
testResults?: {
|
|
948
|
-
passed: number;
|
|
949
|
-
failed: number;
|
|
950
|
-
firstFailure?: {
|
|
951
|
-
test: string;
|
|
952
|
-
error: string;
|
|
953
|
-
file: string;
|
|
954
|
-
} | undefined;
|
|
955
|
-
} | undefined;
|
|
956
|
-
reviewFindings?: {
|
|
957
|
-
file: string;
|
|
958
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
959
|
-
line: number;
|
|
960
|
-
category: string;
|
|
961
|
-
description: string;
|
|
962
|
-
fix: string;
|
|
963
|
-
}[] | undefined;
|
|
964
|
-
}>;
|
|
297
|
+
}, z.core.$strip>>>;
|
|
298
|
+
}, z.core.$strip>;
|
|
965
299
|
tokenBudget: z.ZodObject<{
|
|
966
300
|
contextTokensUsed: z.ZodNumber;
|
|
967
301
|
recommendedMaxTurns: z.ZodNumber;
|
|
968
|
-
},
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
}, {
|
|
972
|
-
contextTokensUsed: number;
|
|
973
|
-
recommendedMaxTurns: number;
|
|
974
|
-
}>;
|
|
975
|
-
}, "strip", z.ZodTypeAny, {
|
|
976
|
-
runId: string;
|
|
977
|
-
issueId: string;
|
|
978
|
-
stage: string;
|
|
979
|
-
timestamp: string;
|
|
980
|
-
summary: string;
|
|
981
|
-
filesChanged: string[];
|
|
982
|
-
approach: string;
|
|
983
|
-
context: {
|
|
984
|
-
issueIntent: string;
|
|
985
|
-
constraints: string[];
|
|
986
|
-
assumptions: string[];
|
|
987
|
-
testResults?: {
|
|
988
|
-
passed: number;
|
|
989
|
-
failed: number;
|
|
990
|
-
firstFailure?: {
|
|
991
|
-
test: string;
|
|
992
|
-
error: string;
|
|
993
|
-
file: string;
|
|
994
|
-
} | undefined;
|
|
995
|
-
} | undefined;
|
|
996
|
-
reviewFindings?: {
|
|
997
|
-
file: string;
|
|
998
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
999
|
-
line: number;
|
|
1000
|
-
category: string;
|
|
1001
|
-
description: string;
|
|
1002
|
-
fix: string;
|
|
1003
|
-
}[] | undefined;
|
|
1004
|
-
};
|
|
1005
|
-
tokenBudget: {
|
|
1006
|
-
contextTokensUsed: number;
|
|
1007
|
-
recommendedMaxTurns: number;
|
|
1008
|
-
};
|
|
1009
|
-
}, {
|
|
1010
|
-
runId: string;
|
|
1011
|
-
issueId: string;
|
|
1012
|
-
stage: string;
|
|
1013
|
-
timestamp: string;
|
|
1014
|
-
summary: string;
|
|
1015
|
-
filesChanged: string[];
|
|
1016
|
-
approach: string;
|
|
1017
|
-
context: {
|
|
1018
|
-
issueIntent: string;
|
|
1019
|
-
constraints: string[];
|
|
1020
|
-
assumptions: string[];
|
|
1021
|
-
testResults?: {
|
|
1022
|
-
passed: number;
|
|
1023
|
-
failed: number;
|
|
1024
|
-
firstFailure?: {
|
|
1025
|
-
test: string;
|
|
1026
|
-
error: string;
|
|
1027
|
-
file: string;
|
|
1028
|
-
} | undefined;
|
|
1029
|
-
} | undefined;
|
|
1030
|
-
reviewFindings?: {
|
|
1031
|
-
file: string;
|
|
1032
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
1033
|
-
line: number;
|
|
1034
|
-
category: string;
|
|
1035
|
-
description: string;
|
|
1036
|
-
fix: string;
|
|
1037
|
-
}[] | undefined;
|
|
1038
|
-
};
|
|
1039
|
-
tokenBudget: {
|
|
1040
|
-
contextTokensUsed: number;
|
|
1041
|
-
recommendedMaxTurns: number;
|
|
1042
|
-
};
|
|
1043
|
-
}>>;
|
|
1044
|
-
}, "strip", z.ZodTypeAny, {
|
|
1045
|
-
prUrl: string;
|
|
1046
|
-
prBranch: string;
|
|
1047
|
-
comments: {
|
|
1048
|
-
author: string;
|
|
1049
|
-
body: string;
|
|
1050
|
-
createdAt: string;
|
|
1051
|
-
file?: string | undefined;
|
|
1052
|
-
line?: number | undefined;
|
|
1053
|
-
diffHunk?: string | undefined;
|
|
1054
|
-
}[];
|
|
1055
|
-
reviewBody?: string | undefined;
|
|
1056
|
-
previousHandoff?: {
|
|
1057
|
-
runId: string;
|
|
1058
|
-
issueId: string;
|
|
1059
|
-
stage: string;
|
|
1060
|
-
timestamp: string;
|
|
1061
|
-
summary: string;
|
|
1062
|
-
filesChanged: string[];
|
|
1063
|
-
approach: string;
|
|
1064
|
-
context: {
|
|
1065
|
-
issueIntent: string;
|
|
1066
|
-
constraints: string[];
|
|
1067
|
-
assumptions: string[];
|
|
1068
|
-
testResults?: {
|
|
1069
|
-
passed: number;
|
|
1070
|
-
failed: number;
|
|
1071
|
-
firstFailure?: {
|
|
1072
|
-
test: string;
|
|
1073
|
-
error: string;
|
|
1074
|
-
file: string;
|
|
1075
|
-
} | undefined;
|
|
1076
|
-
} | undefined;
|
|
1077
|
-
reviewFindings?: {
|
|
1078
|
-
file: string;
|
|
1079
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
1080
|
-
line: number;
|
|
1081
|
-
category: string;
|
|
1082
|
-
description: string;
|
|
1083
|
-
fix: string;
|
|
1084
|
-
}[] | undefined;
|
|
1085
|
-
};
|
|
1086
|
-
tokenBudget: {
|
|
1087
|
-
contextTokensUsed: number;
|
|
1088
|
-
recommendedMaxTurns: number;
|
|
1089
|
-
};
|
|
1090
|
-
} | undefined;
|
|
1091
|
-
}, {
|
|
1092
|
-
prUrl: string;
|
|
1093
|
-
prBranch: string;
|
|
1094
|
-
comments: {
|
|
1095
|
-
author: string;
|
|
1096
|
-
body: string;
|
|
1097
|
-
createdAt: string;
|
|
1098
|
-
file?: string | undefined;
|
|
1099
|
-
line?: number | undefined;
|
|
1100
|
-
diffHunk?: string | undefined;
|
|
1101
|
-
}[];
|
|
1102
|
-
reviewBody?: string | undefined;
|
|
1103
|
-
previousHandoff?: {
|
|
1104
|
-
runId: string;
|
|
1105
|
-
issueId: string;
|
|
1106
|
-
stage: string;
|
|
1107
|
-
timestamp: string;
|
|
1108
|
-
summary: string;
|
|
1109
|
-
filesChanged: string[];
|
|
1110
|
-
approach: string;
|
|
1111
|
-
context: {
|
|
1112
|
-
issueIntent: string;
|
|
1113
|
-
constraints: string[];
|
|
1114
|
-
assumptions: string[];
|
|
1115
|
-
testResults?: {
|
|
1116
|
-
passed: number;
|
|
1117
|
-
failed: number;
|
|
1118
|
-
firstFailure?: {
|
|
1119
|
-
test: string;
|
|
1120
|
-
error: string;
|
|
1121
|
-
file: string;
|
|
1122
|
-
} | undefined;
|
|
1123
|
-
} | undefined;
|
|
1124
|
-
reviewFindings?: {
|
|
1125
|
-
file: string;
|
|
1126
|
-
severity: "blocking" | "warning" | "suggestion";
|
|
1127
|
-
line: number;
|
|
1128
|
-
category: string;
|
|
1129
|
-
description: string;
|
|
1130
|
-
fix: string;
|
|
1131
|
-
}[] | undefined;
|
|
1132
|
-
};
|
|
1133
|
-
tokenBudget: {
|
|
1134
|
-
contextTokensUsed: number;
|
|
1135
|
-
recommendedMaxTurns: number;
|
|
1136
|
-
};
|
|
1137
|
-
} | undefined;
|
|
1138
|
-
}>;
|
|
302
|
+
}, z.core.$strip>;
|
|
303
|
+
}, z.core.$strip>>;
|
|
304
|
+
}, z.core.$strip>;
|
|
1139
305
|
export type ReviewFeedbackContext = z.infer<typeof ReviewFeedbackContextSchema>;
|
|
1140
306
|
export interface AgentProfile {
|
|
1141
307
|
tools: string[];
|