@cat-factory/agents 0.116.2 → 0.116.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/agents/catalog.d.ts +19 -4
- package/dist/agents/catalog.d.ts.map +1 -1
- package/dist/agents/catalog.js +34 -7
- package/dist/agents/catalog.js.map +1 -1
- package/dist/agents/kinds/built-in-container.d.ts +32 -0
- package/dist/agents/kinds/built-in-container.d.ts.map +1 -0
- package/dist/agents/kinds/built-in-container.js +197 -0
- package/dist/agents/kinds/built-in-container.js.map +1 -0
- package/dist/agents/kinds/built-in-results.d.ts +30 -0
- package/dist/agents/kinds/built-in-results.d.ts.map +1 -0
- package/dist/agents/kinds/built-in-results.js +190 -0
- package/dist/agents/kinds/built-in-results.js.map +1 -0
- package/dist/agents/kinds/container-surface.d.ts +3 -11
- package/dist/agents/kinds/container-surface.d.ts.map +1 -1
- package/dist/agents/kinds/container-surface.js +9 -62
- package/dist/agents/kinds/container-surface.js.map +1 -1
- package/dist/agents/kinds/initiative.d.ts.map +1 -1
- package/dist/agents/kinds/initiative.js +16 -4
- package/dist/agents/kinds/initiative.js.map +1 -1
- package/dist/agents/kinds/registry.d.ts +71 -11
- package/dist/agents/kinds/registry.d.ts.map +1 -1
- package/dist/agents/kinds/registry.js +23 -2
- package/dist/agents/kinds/registry.js.map +1 -1
- package/dist/agents/kinds/spec-blueprints.d.ts.map +1 -1
- package/dist/agents/kinds/spec-blueprints.js +44 -4
- package/dist/agents/kinds/spec-blueprints.js.map +1 -1
- package/dist/agents/prompts/built-in-container.d.ts +43 -0
- package/dist/agents/prompts/built-in-container.d.ts.map +1 -0
- package/dist/agents/prompts/built-in-container.js +130 -0
- package/dist/agents/prompts/built-in-container.js.map +1 -0
- package/dist/agents/runtime/fragments.d.ts +6 -1
- package/dist/agents/runtime/fragments.d.ts.map +1 -1
- package/dist/agents/runtime/fragments.js +7 -0
- package/dist/agents/runtime/fragments.js.map +1 -1
- package/dist/index.d.ts +4 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -1
- package/dist/index.js.map +1 -1
- package/package.json +5 -5
package/dist/agents/catalog.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AgentKind } from '@cat-factory/kernel';
|
|
1
|
+
import type { AgentDispatchContext, AgentKind } from '@cat-factory/kernel';
|
|
2
2
|
import type { AgentRunContext } from '@cat-factory/kernel';
|
|
3
3
|
import type { AgentKindRegistry } from './kinds/registry.js';
|
|
4
4
|
/**
|
|
@@ -36,12 +36,27 @@ export declare function systemPromptFor(kind: AgentKind, registry: AgentKindRegi
|
|
|
36
36
|
* them. It is also therefore the text the prompt editor shows as the built-in baseline.
|
|
37
37
|
*/
|
|
38
38
|
export declare function baseSystemPromptFor(kind: AgentKind, registry: AgentKindRegistry): string;
|
|
39
|
+
/** How a caller wants the user prompt rendered. See {@link userPromptFor}. */
|
|
40
|
+
export interface AgentUserPromptOptions {
|
|
41
|
+
/**
|
|
42
|
+
* The caller has a filesystem and has already written the run's context files onto it, so
|
|
43
|
+
* linked context renders as an index pointing at them rather than folding their bodies in.
|
|
44
|
+
*/
|
|
45
|
+
materialized?: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* The resolved checkout this dispatch creates, for the kinds whose own prompt names a branch.
|
|
48
|
+
* Absent for every inline caller (which has no checkout), so a builder that reads it must
|
|
49
|
+
* phrase itself without one rather than invent a branch name.
|
|
50
|
+
*/
|
|
51
|
+
dispatch?: AgentDispatchContext;
|
|
52
|
+
}
|
|
39
53
|
/**
|
|
40
54
|
* Build the user prompt from the block context and the run so far. `opts.materialized`
|
|
41
55
|
* (set by the container executor) renders linked context as a summary index pointing at
|
|
42
56
|
* the on-disk files; the default (inline executors) injects the bodies into the prompt.
|
|
57
|
+
* `opts.dispatch` carries the resolved checkout facts (base/work branch, multi-repo) for the
|
|
58
|
+
* kinds whose own prompt has to name a branch; absent for every inline caller, which has no
|
|
59
|
+
* checkout to describe.
|
|
43
60
|
*/
|
|
44
|
-
export declare function userPromptFor(context: AgentRunContext, registry: AgentKindRegistry, opts?:
|
|
45
|
-
materialized?: boolean;
|
|
46
|
-
}): string;
|
|
61
|
+
export declare function userPromptFor(context: AgentRunContext, registry: AgentKindRegistry, opts?: AgentUserPromptOptions): string;
|
|
47
62
|
//# sourceMappingURL=catalog.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"catalog.d.ts","sourceRoot":"","sources":["../../src/agents/catalog.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;
|
|
1
|
+
{"version":3,"file":"catalog.d.ts","sourceRoot":"","sources":["../../src/agents/catalog.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;AAC1E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAc1D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAA;AA0E5D;;;;;;;;;;;GAWG;AACH,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,iBAAiB,GAAG,MAAM,CAE1F;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,eAAe,CAC7B,IAAI,EAAE,SAAS,EACf,QAAQ,EAAE,iBAAiB,EAC3B,QAAQ,CAAC,EAAE,MAAM,GAChB,MAAM,CAsBR;AA4CD;;;;;;;GAOG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,iBAAiB,GAAG,MAAM,CAyBxF;AAwCD,8EAA8E;AAC9E,MAAM,WAAW,sBAAsB;IACrC;;;OAGG;IACH,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,oBAAoB,CAAA;CAChC;AAED;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAC3B,OAAO,EAAE,eAAe,EACxB,QAAQ,EAAE,iBAAiB,EAC3B,IAAI,GAAE,sBAA2B,GAChC,MAAM,CAQR"}
|
package/dist/agents/catalog.js
CHANGED
|
@@ -129,11 +129,16 @@ export function systemPromptFor(kind, registry, override) {
|
|
|
129
129
|
* on the base actually being the registered prompt, not merely on the kind being in the registry.
|
|
130
130
|
*/
|
|
131
131
|
function applySurfaceDirectives(prompt, kind, registry) {
|
|
132
|
-
const
|
|
132
|
+
const step = registry.agentStep(kind);
|
|
133
|
+
const surface = step?.surface;
|
|
133
134
|
// True only when the base prompt is the one from the registry — i.e. no built-in track claimed
|
|
134
135
|
// this kind. A built-in-track-owned id (even if also registered) already got the directive.
|
|
135
136
|
const usedRegisteredPrompt = prompt === registry.systemPrompt(kind);
|
|
136
|
-
|
|
137
|
+
// `localWrites` is the explore kind that legitimately writes inside its own working tree (a
|
|
138
|
+
// tester installs dependencies and runs a suite). The surface still means "never pushes"; the
|
|
139
|
+
// guardrail's wording ("must not create files") does not, and reads to that agent as a refusal
|
|
140
|
+
// to run the suite. See {@link AgentStepSpec.localWrites}.
|
|
141
|
+
const needsGuardrail = isReadOnlyAgentKind(kind) || (surface === 'container-explore' && !step?.localWrites);
|
|
137
142
|
const needsFinalAnswer = usedRegisteredPrompt && (surface === 'inline' || surface === 'container-explore');
|
|
138
143
|
let result = prompt;
|
|
139
144
|
if (needsGuardrail)
|
|
@@ -219,9 +224,22 @@ function withRevision(prompt, context) {
|
|
|
219
224
|
* Build the user prompt from the block context and the run so far. `opts.materialized`
|
|
220
225
|
* (set by the container executor) renders linked context as a summary index pointing at
|
|
221
226
|
* the on-disk files; the default (inline executors) injects the bodies into the prompt.
|
|
227
|
+
* `opts.dispatch` carries the resolved checkout facts (base/work branch, multi-repo) for the
|
|
228
|
+
* kinds whose own prompt has to name a branch; absent for every inline caller, which has no
|
|
229
|
+
* checkout to describe.
|
|
222
230
|
*/
|
|
223
231
|
export function userPromptFor(context, registry, opts = {}) {
|
|
224
|
-
|
|
232
|
+
const { prompt, suffix } = buildBaseUserPrompt(context, registry, opts);
|
|
233
|
+
// The kind's closing instruction is applied OUTSIDE both wrappers, not folded into the base
|
|
234
|
+
// prompt: `userPromptSuffix` exists to be the last thing the agent reads (the `on-call` kind's
|
|
235
|
+
// "respond with ONLY a JSON object" is the shape), and both wrappers append. Folded in earlier,
|
|
236
|
+
// a revision re-run would end on the reviewer's feedback and an inline run on a context-file
|
|
237
|
+
// dump, leaving the reply-shape instruction buried mid-prompt.
|
|
238
|
+
return withSuffix(withInjectedContext(withRevision(prompt, context), context, opts), suffix);
|
|
239
|
+
}
|
|
240
|
+
/** Append a kind's closing task instructions ({@link buildBaseUserPrompt}'s `suffix`), if any. */
|
|
241
|
+
function withSuffix(prompt, suffix) {
|
|
242
|
+
return suffix ? `${prompt}\n\n${suffix}` : prompt;
|
|
225
243
|
}
|
|
226
244
|
/**
|
|
227
245
|
* Total budget for the folded context bodies. A panel re-sends this prompt to every participant
|
|
@@ -286,7 +304,8 @@ function buildBaseUserPrompt(context, registry, opts = {}) {
|
|
|
286
304
|
// Standard phases get their built-out, templated user prompt.
|
|
287
305
|
const phase = phaseForKind(context.agentKind);
|
|
288
306
|
if (phase)
|
|
289
|
-
return renderStandardUserPrompt(phase, context, opts);
|
|
307
|
+
return { prompt: renderStandardUserPrompt(phase, context, opts) };
|
|
308
|
+
const dispatch = opts.dispatch;
|
|
290
309
|
// A registered custom kind may supply its own user prompt; otherwise it falls through
|
|
291
310
|
// to the generic block-context prompt below, like any other non-standard-phase kind. Even a
|
|
292
311
|
// self-authored prompt still gets the initiative-preset steering folded in FIRST — an
|
|
@@ -298,12 +317,14 @@ function buildBaseUserPrompt(context, registry, opts = {}) {
|
|
|
298
317
|
// matters most for them: an org's reusable operation typically runs on that org's OWN kinds,
|
|
299
318
|
// which are exactly the kinds that author their own user prompt. Miss it and the parameters
|
|
300
319
|
// vanish for the runs the whole feature exists to serve.
|
|
301
|
-
const registered = registry.userPrompt(context);
|
|
320
|
+
const registered = registry.userPrompt(context, dispatch);
|
|
302
321
|
if (registered !== undefined) {
|
|
303
322
|
const prepended = [initiativePresetSection(context), customTaskTypeSection(context)]
|
|
304
323
|
.filter(Boolean)
|
|
305
324
|
.map((section) => section.trimStart());
|
|
306
|
-
return
|
|
325
|
+
return {
|
|
326
|
+
prompt: prepended.length ? `${prepended.join('\n\n')}\n\n${registered}` : registered,
|
|
327
|
+
};
|
|
307
328
|
}
|
|
308
329
|
const { block, pipelineName, priorOutputs, decisions, resolvedDecision } = context;
|
|
309
330
|
const lines = [
|
|
@@ -374,7 +395,13 @@ function buildBaseUserPrompt(context, registry, opts = {}) {
|
|
|
374
395
|
}
|
|
375
396
|
}
|
|
376
397
|
lines.push('', 'Produce your contribution. Be concise and concrete.');
|
|
377
|
-
|
|
398
|
+
// A kind's ADDITIVE closing instructions (see `AgentKindDefinition.userPromptSuffix`) — the
|
|
399
|
+
// shape for a kind that needs everything above (the run's evidence, the prior agents' output)
|
|
400
|
+
// plus its own task framing. Returned BESIDE the prompt rather than pushed onto `lines`, so
|
|
401
|
+
// `userPromptFor` can append it after the revision/injected-context wrappers and it genuinely
|
|
402
|
+
// ends the prompt.
|
|
403
|
+
const suffix = registry.userPromptSuffix(context, dispatch);
|
|
404
|
+
return { prompt: lines.join('\n'), ...(suffix ? { suffix } : {}) };
|
|
378
405
|
}
|
|
379
406
|
/**
|
|
380
407
|
* For a companion step, name the specific producer output it must grade: the NEAREST
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"catalog.js","sourceRoot":"","sources":["../../src/agents/catalog.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,sBAAsB,EACtB,mBAAmB,EACnB,gBAAgB,GACjB,MAAM,yBAAyB,CAAA;AAChC,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAA;AAC/D,OAAO,EAAE,qBAAqB,EAAE,MAAM,wBAAwB,CAAA;AAC9D,OAAO,EAAE,gBAAgB,EAAE,MAAM,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,OAAO,EAAE,QAAQ,CAAC,CAAA;IAC3D,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAA;AACpE,CAAC;AAED;;;;;;GAMG;AACH,SAAS,sBAAsB,CAC7B,OAAwB,EACxB,QAA2B;IAE3B,MAAM,OAAO,GAAG,gBAAgB,CAAC,OAAO,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAA;IAC7D,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,SAAS,CAAA;IAC1C,KAAK,IAAI,CAAC,GAAG,OAAO,CAAC,YAAY,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC;QAC1D,MAAM,QAAQ,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC,CAAE,CAAA;QACzC,IAAI,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAC,SAAS,CAAC,EAAE,CAAC;YACzC,OAAO,CACL,uCAAuC,QAAQ,CAAC,SAAS,uBAAuB;gBAChF,QAAQ,QAAQ,CAAC,SAAS,4CAA4C,CACvE,CAAA;QACH,CAAC;IACH,CAAC;IACD,OAAO,SAAS,CAAA;AAClB,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import type { AgentKindDefinition, AgentKindRegistry } from './registry.js';
|
|
2
|
+
/**
|
|
3
|
+
* The agent kind of the implementer: the container agent that writes the change, commits it to
|
|
4
|
+
* the per-task work branch and opens the run's pull request.
|
|
5
|
+
*/
|
|
6
|
+
export declare const IMPLEMENTER_AGENT_KIND = "coder";
|
|
7
|
+
/** The agent kind of the read-only container agent that proposes a design after reading the repo. */
|
|
8
|
+
export declare const ARCHITECT_AGENT_KIND = "architect";
|
|
9
|
+
/** The agent kind of the read-only tech-debt auditor that reads the repo and emits a report. */
|
|
10
|
+
export declare const ANALYSIS_AGENT_KIND = "analysis";
|
|
11
|
+
/** The agent kind of the container agent that scores a PR for the merge decision. */
|
|
12
|
+
export declare const MERGER_AGENT_KIND = "merger";
|
|
13
|
+
/**
|
|
14
|
+
* The agent kind of the general/API tester: it clones the PR branch, stands the service's test
|
|
15
|
+
* dependencies up, runs the suite and returns a structured report. {@link UI_TESTER_AGENT_KIND}
|
|
16
|
+
* is its browser-driven, screenshot-capturing sibling.
|
|
17
|
+
*/
|
|
18
|
+
export declare const TESTER_AGENT_KIND = "tester-api";
|
|
19
|
+
/** The agent kind of the container agent that builds WireMock mocks for a service's upstreams. */
|
|
20
|
+
export declare const MOCKER_AGENT_KIND = "mocker";
|
|
21
|
+
/** The agent kind of the container agent that authors Playwright end-to-end tests. */
|
|
22
|
+
export declare const PLAYWRIGHT_AGENT_KIND = "playwright";
|
|
23
|
+
/** The agent kind of the container agent that reads the code and commits the domain-rules docs. */
|
|
24
|
+
export declare const BUSINESS_DOCUMENTER_AGENT_KIND = "business-documenter";
|
|
25
|
+
/** Every built-in container kind, in one list so `defaultAgentKindRegistry` installs them once. */
|
|
26
|
+
export declare const BUILT_IN_CONTAINER_AGENT_KINDS: AgentKindDefinition[];
|
|
27
|
+
/**
|
|
28
|
+
* Register the built-in container kinds on the given registry. Called by
|
|
29
|
+
* `defaultAgentKindRegistry()`; idempotent (the registry replaces by kind).
|
|
30
|
+
*/
|
|
31
|
+
export declare function registerBuiltInContainerAgents(registry: AgentKindRegistry): void;
|
|
32
|
+
//# sourceMappingURL=built-in-container.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"built-in-container.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/built-in-container.ts"],"names":[],"mappings":"AAiBA,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAA;AA+B3E;;;GAGG;AACH,eAAO,MAAM,sBAAsB,UAAU,CAAA;AAE7C,qGAAqG;AACrG,eAAO,MAAM,oBAAoB,cAAc,CAAA;AAE/C,gGAAgG;AAChG,eAAO,MAAM,mBAAmB,aAAa,CAAA;AAE7C,qFAAqF;AACrF,eAAO,MAAM,iBAAiB,WAAW,CAAA;AAEzC;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,eAAe,CAAA;AAE7C,kGAAkG;AAClG,eAAO,MAAM,iBAAiB,WAAW,CAAA;AAEzC,sFAAsF;AACtF,eAAO,MAAM,qBAAqB,eAAe,CAAA;AAEjD,mGAAmG;AACnG,eAAO,MAAM,8BAA8B,wBAAwB,CAAA;AAwBnE,mGAAmG;AACnG,eAAO,MAAM,8BAA8B,EAAE,mBAAmB,EAoH/D,CAAA;AAED;;;GAGG;AACH,wBAAgB,8BAA8B,CAAC,QAAQ,EAAE,iBAAiB,GAAG,IAAI,CAEhF"}
|
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
import { CI_FIXER_AGENT_KIND, CONFLICT_RESOLVER_AGENT_KIND, FIXER_AGENT_KIND, ON_CALL_AGENT_KIND, } from '@cat-factory/kernel';
|
|
2
|
+
import { UI_TESTER_AGENT_KIND } from '@cat-factory/contracts';
|
|
3
|
+
import { conflictResolverUserPrompt, MERGE_ASSESSMENT_SHAPE_HINT, mergerUserPrompt, ON_CALL_ASSESSMENT_SHAPE_HINT, onCallUserPromptSuffix, TEST_REPORT_SHAPE_HINT, UI_TEST_REPORT_SHAPE_HINT, } from '../prompts/built-in-container.js';
|
|
4
|
+
import { mergerResult, onCallResult, testerResult } from './built-in-results.js';
|
|
5
|
+
// ---------------------------------------------------------------------------
|
|
6
|
+
// The BUILT-IN container agent kinds, as ordinary `registerAgentKind` entries.
|
|
7
|
+
//
|
|
8
|
+
// This is the last slice of the agent-kind strangler (`docs/internal/refactoring-candidates.md`
|
|
9
|
+
// #5). Every one of these used to be rendered by a `switch (context.agentKind)` in
|
|
10
|
+
// `@cat-factory/server`'s job-body builder, plus a parallel `agentKind === …` chain coercing the
|
|
11
|
+
// reply: two hand-maintained switches a deployment could not reach. They are now the SAME kind of
|
|
12
|
+
// declaration a deployment writes, so what a built-in does is DATA the engine reads, and a
|
|
13
|
+
// deployment can register its own fixer / tester / assessor beside them with no fork.
|
|
14
|
+
//
|
|
15
|
+
// What each definition deliberately does NOT carry:
|
|
16
|
+
//
|
|
17
|
+
// - **`systemPrompt`.** Every kind here already has a prompt OWNER further up
|
|
18
|
+
// `baseSystemPromptFor` (a standard-phase track, the tester/fixer track, the acceptance and
|
|
19
|
+
// mock tracks, or the bespoke `{ role, directives }` split `merger` / `on-call` run under).
|
|
20
|
+
// The track wins there regardless, so a copy on the definition would be a second source of
|
|
21
|
+
// truth that is dead the day it drifts.
|
|
22
|
+
// - **`presentation`.** These are first-class built-ins in the SPA's own catalog already;
|
|
23
|
+
// declaring it is what promotes a REGISTERED kind into the palette (`snapshotCustomAgentKinds`
|
|
24
|
+
// filters on it), so declaring it here would list each built-in twice.
|
|
25
|
+
// - **`gatable` / `traits`.** Both fall back to the built-in catalogs (`BUILTIN_GATABLE_KINDS`,
|
|
26
|
+
// `STANDARD_AGENT_TRAITS`) when a registration omits them, and those catalogs remain the
|
|
27
|
+
// answer for these kinds. A `false` here would SHADOW them.
|
|
28
|
+
//
|
|
29
|
+
// The clone/PR/infra knobs each definition does carry are declarative on purpose: they are the
|
|
30
|
+
// vocabulary a deployment's own kind needs too (an in-place fixer wants `requirePr`, a bespoke
|
|
31
|
+
// tester wants `testInfra`, a resolver wants `mergeBase`), not per-kind escape hatches.
|
|
32
|
+
// ---------------------------------------------------------------------------
|
|
33
|
+
/**
|
|
34
|
+
* The agent kind of the implementer: the container agent that writes the change, commits it to
|
|
35
|
+
* the per-task work branch and opens the run's pull request.
|
|
36
|
+
*/
|
|
37
|
+
export const IMPLEMENTER_AGENT_KIND = 'coder';
|
|
38
|
+
/** The agent kind of the read-only container agent that proposes a design after reading the repo. */
|
|
39
|
+
export const ARCHITECT_AGENT_KIND = 'architect';
|
|
40
|
+
/** The agent kind of the read-only tech-debt auditor that reads the repo and emits a report. */
|
|
41
|
+
export const ANALYSIS_AGENT_KIND = 'analysis';
|
|
42
|
+
/** The agent kind of the container agent that scores a PR for the merge decision. */
|
|
43
|
+
export const MERGER_AGENT_KIND = 'merger';
|
|
44
|
+
/**
|
|
45
|
+
* The agent kind of the general/API tester: it clones the PR branch, stands the service's test
|
|
46
|
+
* dependencies up, runs the suite and returns a structured report. {@link UI_TESTER_AGENT_KIND}
|
|
47
|
+
* is its browser-driven, screenshot-capturing sibling.
|
|
48
|
+
*/
|
|
49
|
+
export const TESTER_AGENT_KIND = 'tester-api';
|
|
50
|
+
/** The agent kind of the container agent that builds WireMock mocks for a service's upstreams. */
|
|
51
|
+
export const MOCKER_AGENT_KIND = 'mocker';
|
|
52
|
+
/** The agent kind of the container agent that authors Playwright end-to-end tests. */
|
|
53
|
+
export const PLAYWRIGHT_AGENT_KIND = 'playwright';
|
|
54
|
+
/** The agent kind of the container agent that reads the code and commits the domain-rules docs. */
|
|
55
|
+
export const BUSINESS_DOCUMENTER_AGENT_KIND = 'business-documenter';
|
|
56
|
+
/**
|
|
57
|
+
* The implementer's dispatch shape, shared by every built-in that WRITES a change and opens the
|
|
58
|
+
* run's pull request: branch off base onto the deterministic per-task work branch
|
|
59
|
+
* (`cat-factory/<blockId>` — per BLOCK, not per dispatch, so a retry resumes the same branch and
|
|
60
|
+
* an evicted run's checkpointed commits survive), push it, open a PR.
|
|
61
|
+
*/
|
|
62
|
+
const WORK_BRANCH_CODING = {
|
|
63
|
+
surface: 'container-coding',
|
|
64
|
+
clone: { branch: 'work' },
|
|
65
|
+
};
|
|
66
|
+
/**
|
|
67
|
+
* The in-place fixer's dispatch shape: clone the PR head branch, push the fixes back onto it and
|
|
68
|
+
* open NO new pull request, so the gate that dispatched the fixer re-checks the real signal on
|
|
69
|
+
* the same PR. `requirePr` because a fixer with no PR has nothing to fix, and the generic
|
|
70
|
+
* `pr`-clone fallback would push unrelated work onto the base branch.
|
|
71
|
+
*/
|
|
72
|
+
const IN_PLACE_CODING = {
|
|
73
|
+
surface: 'container-coding',
|
|
74
|
+
clone: { branch: 'pr', requirePr: true },
|
|
75
|
+
};
|
|
76
|
+
/** Every built-in container kind, in one list so `defaultAgentKindRegistry` installs them once. */
|
|
77
|
+
export const BUILT_IN_CONTAINER_AGENT_KINDS = [
|
|
78
|
+
// --- Producers: write a change, push the work branch, open the run's PR -------------------
|
|
79
|
+
{
|
|
80
|
+
kind: IMPLEMENTER_AGENT_KIND,
|
|
81
|
+
agent: WORK_BRANCH_CODING,
|
|
82
|
+
// The implementer fans out across the task's connected involved-service repos: it clones
|
|
83
|
+
// each as a sibling checkout, opens the SAME work branch in every one and opens a PR per
|
|
84
|
+
// repo, so a change that spans services lands as one coordinated set.
|
|
85
|
+
fanOutMultiRepo: true,
|
|
86
|
+
},
|
|
87
|
+
{ kind: MOCKER_AGENT_KIND, agent: WORK_BRANCH_CODING },
|
|
88
|
+
{ kind: PLAYWRIGHT_AGENT_KIND, agent: WORK_BRANCH_CODING },
|
|
89
|
+
{ kind: BUSINESS_DOCUMENTER_AGENT_KIND, agent: WORK_BRANCH_CODING },
|
|
90
|
+
// --- Read-only explorers: clone, read, report; no commit, no PR ---------------------------
|
|
91
|
+
// No `clone` target, deliberately: the generic explore resolution then prefers the per-block
|
|
92
|
+
// WORK branch when one is ready, so the architect reads the spec-writer's committed `spec/`
|
|
93
|
+
// and any in-progress implementation, falling back to the PR branch and then base.
|
|
94
|
+
{ kind: ARCHITECT_AGENT_KIND, agent: { surface: 'container-explore' } },
|
|
95
|
+
{ kind: ANALYSIS_AGENT_KIND, agent: { surface: 'container-explore' } },
|
|
96
|
+
// --- In-place fixers: clone the PR head, push back onto it, open no new PR ----------------
|
|
97
|
+
{
|
|
98
|
+
kind: CI_FIXER_AGENT_KIND,
|
|
99
|
+
agent: IN_PLACE_CODING,
|
|
100
|
+
// Red CI on a multi-repo task is routinely a cross-repo contract break, which a single-repo
|
|
101
|
+
// fixer structurally cannot fix: it resumes the SAME work branches the implementer opened,
|
|
102
|
+
// in one container.
|
|
103
|
+
fanOutMultiRepo: true,
|
|
104
|
+
},
|
|
105
|
+
{ kind: FIXER_AGENT_KIND, agent: IN_PLACE_CODING },
|
|
106
|
+
{
|
|
107
|
+
// The conflict-resolver clones the PR head with FULL history, the harness merges the repo's
|
|
108
|
+
// base branch in to surface the conflicts, the agent resolves them, and the harness completes
|
|
109
|
+
// the merge commit and pushes back onto the SAME branch (refusing a half-resolved tree) so
|
|
110
|
+
// the PR becomes mergeable and CI re-runs.
|
|
111
|
+
//
|
|
112
|
+
// `prFallback: 'work'` is the peer-conflict case: the branch to resolve on is the shared
|
|
113
|
+
// per-task work branch every repo's PR rides, and the OWN service may have had no change (so
|
|
114
|
+
// no own `pullRequest`) while a PEER repo did. It stays SINGLE-repo — a git conflict is
|
|
115
|
+
// per-repo textual, handled by targeting the conflicted repo rather than by fanning out.
|
|
116
|
+
kind: CONFLICT_RESOLVER_AGENT_KIND,
|
|
117
|
+
agent: {
|
|
118
|
+
surface: 'container-coding',
|
|
119
|
+
clone: { branch: 'pr', full: true, requirePr: true, prFallback: 'work', mergeBase: true },
|
|
120
|
+
},
|
|
121
|
+
userPrompt: conflictResolverUserPrompt,
|
|
122
|
+
},
|
|
123
|
+
// --- Assessors: read-only structured explore whose JSON the engine acts on ----------------
|
|
124
|
+
{
|
|
125
|
+
// The merger clones the PR head (full, to diff against base) and returns ONLY the
|
|
126
|
+
// complexity / risk / impact assessment; the ENGINE performs the real merge from those
|
|
127
|
+
// scores against the task's merge threshold preset.
|
|
128
|
+
//
|
|
129
|
+
// `standardsDelivery: 'none'` because it JUDGES rather than produces: a house coding
|
|
130
|
+
// standard has no bearing on how risky a diff is, and folding the service's standards into
|
|
131
|
+
// every assessment charges each one for text it never applies.
|
|
132
|
+
kind: MERGER_AGENT_KIND,
|
|
133
|
+
agent: {
|
|
134
|
+
surface: 'container-explore',
|
|
135
|
+
clone: { branch: 'pr', full: true },
|
|
136
|
+
output: { kind: 'structured', shapeHint: MERGE_ASSESSMENT_SHAPE_HINT },
|
|
137
|
+
},
|
|
138
|
+
userPrompt: mergerUserPrompt,
|
|
139
|
+
standardsDelivery: 'none',
|
|
140
|
+
mapStructuredResult: mergerResult,
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
// The on-call agent clones the BASE branch (full, to locate + diff the merged release
|
|
144
|
+
// commit) and returns ONLY the regression assessment. It never auto-reverts: the engine
|
|
145
|
+
// raises a card and best-effort enriches any open incident.
|
|
146
|
+
//
|
|
147
|
+
// A prompt SUFFIX rather than its own user prompt: the generic block-context prompt carries
|
|
148
|
+
// the regression evidence and the prior steps' output, which is the input it reasons over.
|
|
149
|
+
kind: ON_CALL_AGENT_KIND,
|
|
150
|
+
agent: {
|
|
151
|
+
surface: 'container-explore',
|
|
152
|
+
clone: { branch: 'base', full: true },
|
|
153
|
+
output: { kind: 'structured', shapeHint: ON_CALL_ASSESSMENT_SHAPE_HINT },
|
|
154
|
+
},
|
|
155
|
+
userPromptSuffix: onCallUserPromptSuffix,
|
|
156
|
+
mapStructuredResult: onCallResult,
|
|
157
|
+
},
|
|
158
|
+
// --- Testers: read-only structured explore with the service's test dependencies stood up --
|
|
159
|
+
// `localWrites` because an explore surface means "never pushes", not "never writes": a tester
|
|
160
|
+
// installs dependencies and runs a suite, which creates build output, so the read-only
|
|
161
|
+
// guardrail's wording would read to it as a refusal to run the suite at all.
|
|
162
|
+
{
|
|
163
|
+
kind: TESTER_AGENT_KIND,
|
|
164
|
+
agent: {
|
|
165
|
+
surface: 'container-explore',
|
|
166
|
+
clone: { branch: 'pr' },
|
|
167
|
+
output: { kind: 'structured', shapeHint: TEST_REPORT_SHAPE_HINT },
|
|
168
|
+
testInfra: true,
|
|
169
|
+
localWrites: true,
|
|
170
|
+
},
|
|
171
|
+
mapStructuredResult: testerResult,
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
// The UI tester is the Tester's browser-driven sibling: same read-only structured explore +
|
|
175
|
+
// infra stand-up, but it drives Playwright (from the heavier UI image) to capture a
|
|
176
|
+
// non-redundant screenshot of each distinct view, uploads them to the artifact store and
|
|
177
|
+
// reports them under `screenshots[]`.
|
|
178
|
+
kind: UI_TESTER_AGENT_KIND,
|
|
179
|
+
agent: {
|
|
180
|
+
surface: 'container-explore',
|
|
181
|
+
clone: { branch: 'pr' },
|
|
182
|
+
output: { kind: 'structured', shapeHint: UI_TEST_REPORT_SHAPE_HINT },
|
|
183
|
+
testInfra: true,
|
|
184
|
+
localWrites: true,
|
|
185
|
+
image: 'ui',
|
|
186
|
+
},
|
|
187
|
+
mapStructuredResult: testerResult,
|
|
188
|
+
},
|
|
189
|
+
];
|
|
190
|
+
/**
|
|
191
|
+
* Register the built-in container kinds on the given registry. Called by
|
|
192
|
+
* `defaultAgentKindRegistry()`; idempotent (the registry replaces by kind).
|
|
193
|
+
*/
|
|
194
|
+
export function registerBuiltInContainerAgents(registry) {
|
|
195
|
+
registry.registerAll(BUILT_IN_CONTAINER_AGENT_KINDS);
|
|
196
|
+
}
|
|
197
|
+
//# sourceMappingURL=built-in-container.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"built-in-container.js","sourceRoot":"","sources":["../../../src/agents/kinds/built-in-container.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,4BAA4B,EAC5B,gBAAgB,EAChB,kBAAkB,GACnB,MAAM,qBAAqB,CAAA;AAC5B,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAA;AAC7D,OAAO,EACL,0BAA0B,EAC1B,2BAA2B,EAC3B,gBAAgB,EAChB,6BAA6B,EAC7B,sBAAsB,EACtB,sBAAsB,EACtB,yBAAyB,GAC1B,MAAM,kCAAkC,CAAA;AACzC,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AAGhF,8EAA8E;AAC9E,+EAA+E;AAC/E,EAAE;AACF,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B,KAAK,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;YACvB,MAAM,EAAE,EAAE,IAAI,EAAE,YAAY,EAAE,SAAS,EAAE,yBAAyB,EAAE;YACpE,SAAS,EAAE,IAAI;YACf,WAAW,EAAE,IAAI;YACjB,KAAK,EAAE,IAAI;SACZ;QACD,mBAAmB,EAAE,YAAY;KAClC;CACF,CAAA;AAED;;;GAGG;AACH,MAAM,UAAU,8BAA8B,CAAC,QAA2B;IACxE,QAAQ,CAAC,WAAW,CAAC,8BAA8B,CAAC,CAAA;AACtD,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { AgentRunResult, RunnerJobResult } from '@cat-factory/kernel';
|
|
2
|
+
/** The job summary trimmed, or a kind-specific fallback when the model returned none. */
|
|
3
|
+
export declare function summaryOr(result: RunnerJobResult, fallback: string): string;
|
|
4
|
+
/**
|
|
5
|
+
* The `merger`'s structured JSON as the engine's merge assessment. A missing or garbage score
|
|
6
|
+
* defaults to 1 (severe → routes to human review rather than a silent auto-merge) and the
|
|
7
|
+
* rationale falls back to the agent's summary. The harness's old container-side `diffExaminable`
|
|
8
|
+
* guard (force 1/1/1 when the base diff was unreadable) is not reproducible backend-side; the
|
|
9
|
+
* conservative-on-garbage default covers the same risk.
|
|
10
|
+
*/
|
|
11
|
+
export declare function mergerResult(result: RunnerJobResult): AgentRunResult;
|
|
12
|
+
/**
|
|
13
|
+
* The `on-call` agent's structured JSON as the engine's release-regression assessment: a missing
|
|
14
|
+
* confidence defaults to 0 (don't imply the PR is at fault without evidence) and a missing
|
|
15
|
+
* recommendation to `hold` (a human decides). It never auto-reverts.
|
|
16
|
+
*/
|
|
17
|
+
export declare function onCallResult(result: RunnerJobResult): AgentRunResult;
|
|
18
|
+
/**
|
|
19
|
+
* A tester's structured JSON as the engine's `testReport`, defaulting every field safely so a
|
|
20
|
+
* malformed reply still parses (the engine strict-validates it). Crucially a greenlight is
|
|
21
|
+
* honoured ONLY when no BLOCKING (high/critical) concern is open and the run did not abort, so a
|
|
22
|
+
* model that greenlights with an open blocker cannot auto-pass; low/medium concerns are advisory.
|
|
23
|
+
* The engine's `TesterController` re-applies this rule defensively.
|
|
24
|
+
*
|
|
25
|
+
* The in-container docker-compose stand-up record (`infraSetup`) rides along so the engine can
|
|
26
|
+
* persist its captured logs on the Tester step. Harness-produced, so no coercion; the controller
|
|
27
|
+
* validates it defensively before persisting.
|
|
28
|
+
*/
|
|
29
|
+
export declare function testerResult(result: RunnerJobResult): AgentRunResult;
|
|
30
|
+
//# sourceMappingURL=built-in-results.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"built-in-results.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/built-in-results.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAoB1E,yFAAyF;AACzF,wBAAgB,SAAS,CAAC,MAAM,EAAE,eAAe,EAAE,QAAQ,EAAE,MAAM,GAAG,MAAM,CAE3E;AAgCD;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,MAAM,EAAE,eAAe,GAAG,cAAc,CAWpE;AAED;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,MAAM,EAAE,eAAe,GAAG,cAAc,CAepE;AAmED;;;;;;;;;;GAUG;AACH,wBAAgB,YAAY,CAAC,MAAM,EAAE,eAAe,GAAG,cAAc,CA2BpE"}
|