@cat-factory/agents 0.146.6 → 0.148.0
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/kinds/bug-investigator.d.ts.map +1 -1
- package/dist/agents/kinds/bug-investigator.js +7 -3
- package/dist/agents/kinds/bug-investigator.js.map +1 -1
- package/dist/agents/kinds/step-surface.d.ts.map +1 -1
- package/dist/agents/kinds/step-surface.js +6 -0
- package/dist/agents/kinds/step-surface.js.map +1 -1
- package/dist/agents/kinds/traits.d.ts +22 -0
- package/dist/agents/kinds/traits.d.ts.map +1 -1
- package/dist/agents/kinds/traits.js +38 -3
- package/dist/agents/kinds/traits.js.map +1 -1
- package/dist/agents/kinds/versions.d.ts +5 -0
- package/dist/agents/kinds/versions.d.ts.map +1 -1
- package/dist/agents/kinds/versions.js +7 -0
- package/dist/agents/kinds/versions.js.map +1 -1
- package/dist/agents/prompts/environment-investigation.d.ts +22 -0
- package/dist/agents/prompts/environment-investigation.d.ts.map +1 -0
- package/dist/agents/prompts/environment-investigation.js +202 -0
- package/dist/agents/prompts/environment-investigation.js.map +1 -0
- package/dist/agents/prompts/inline-engine.d.ts.map +1 -1
- package/dist/agents/prompts/inline-engine.js +8 -0
- package/dist/agents/prompts/inline-engine.js.map +1 -1
- package/dist/foundationalServices/FoundationalServiceCatalogService.js +1 -0
- package/dist/foundationalServices/FoundationalServiceCatalogService.js.map +1 -1
- package/dist/foundationalServices/ServiceCatalogSyncService.d.ts +77 -0
- package/dist/foundationalServices/ServiceCatalogSyncService.d.ts.map +1 -0
- package/dist/foundationalServices/ServiceCatalogSyncService.js +384 -0
- package/dist/foundationalServices/ServiceCatalogSyncService.js.map +1 -0
- package/dist/index.d.ts +4 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/providers/endpoints.d.ts +60 -0
- package/dist/providers/endpoints.d.ts.map +1 -1
- package/dist/providers/endpoints.js +39 -0
- package/dist/providers/endpoints.js.map +1 -1
- package/dist/providers/gateway-attribution.d.ts +74 -0
- package/dist/providers/gateway-attribution.d.ts.map +1 -0
- package/dist/providers/gateway-attribution.js +120 -0
- package/dist/providers/gateway-attribution.js.map +1 -0
- package/dist/providers/index.d.ts +3 -2
- package/dist/providers/index.d.ts.map +1 -1
- package/dist/providers/index.js +3 -2
- package/dist/providers/index.js.map +1 -1
- package/dist/providers/instrumented.d.ts.map +1 -1
- package/dist/providers/instrumented.js +19 -0
- package/dist/providers/instrumented.js.map +1 -1
- package/dist/providers/resolvers.d.ts +79 -0
- package/dist/providers/resolvers.d.ts.map +1 -1
- package/dist/providers/resolvers.js +91 -8
- package/dist/providers/resolvers.js.map +1 -1
- package/package.json +6 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bug-investigator.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/bug-investigator.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAA;AA0B3E,eAAO,MAAM,qBAAqB,qBAAqB,CAAA;AAEvD;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;EA4B5B,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,KAAK,CAAC,CAAA;AAwBxE,eAAO,MAAM,4BAA4B,EAAE,mBAAmB,
|
|
1
|
+
{"version":3,"file":"bug-investigator.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/bug-investigator.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAA;AA0B3E,eAAO,MAAM,qBAAqB,qBAAqB,CAAA;AAEvD;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;EA4B5B,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,KAAK,CAAC,CAAA;AAwBxE,eAAO,MAAM,4BAA4B,EAAE,mBAAmB,EAkC7D,CAAA;AAED;;;GAGG;AACH,wBAAgB,4BAA4B,CAAC,QAAQ,EAAE,iBAAiB,GAAG,IAAI,CAE9E"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as v from 'valibot';
|
|
2
2
|
import { defineStructuredOutput } from './structured-output.js';
|
|
3
|
-
import { CODE_AWARE_TRAIT } from './traits.js';
|
|
3
|
+
import { CODE_AWARE_TRAIT, SERVICE_ESTATE_TRAIT } from './traits.js';
|
|
4
4
|
// ---------------------------------------------------------------------------
|
|
5
5
|
// The `bug-investigator` agent kind — the read-only, multi-repo investigation that
|
|
6
6
|
// OPENS a bug-fix / bug-triage pipeline.
|
|
@@ -74,8 +74,12 @@ export const BUG_INVESTIGATOR_AGENT_KINDS = [
|
|
|
74
74
|
kind: BUG_INVESTIGATOR_KIND,
|
|
75
75
|
systemPrompt: BUG_INVESTIGATOR_SYSTEM_PROMPT,
|
|
76
76
|
// Reads the codebase to trace a bug's root cause, so the engine folds the task's best-practice
|
|
77
|
-
// fragments into its prompt (the service's standards inform what "correct" looks like).
|
|
78
|
-
|
|
77
|
+
// fragments into its prompt (the service's standards inform what "correct" looks like). It also
|
|
78
|
+
// carries `service-estate`: this kind's whole job starts with deciding which service a report
|
|
79
|
+
// belongs to, and it already fans out over the connected service repos to answer it, so the
|
|
80
|
+
// organisation's own record of what those services are and who owns them is the cheapest
|
|
81
|
+
// context it can be given.
|
|
82
|
+
traits: [CODE_AWARE_TRAIT, SERVICE_ESTATE_TRAIT],
|
|
79
83
|
// Read-only checkout of the primary repo's base branch (+ any peer repos as siblings,
|
|
80
84
|
// wired by the executor's multi-repo fan-out). `agent.output` is derived from the schema.
|
|
81
85
|
agent: { surface: 'container-explore', clone: { branch: 'base' } },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bug-investigator.js","sourceRoot":"","sources":["../../../src/agents/kinds/bug-investigator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAC5B,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAA;AAE/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"bug-investigator.js","sourceRoot":"","sources":["../../../src/agents/kinds/bug-investigator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAC5B,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAA;AAE/D,OAAO,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAEpE,8EAA8E;AAC9E,mFAAmF;AACnF,yCAAyC;AACzC,EAAE;AACF,mFAAmF;AACnF,uFAAuF;AACvF,0FAA0F;AAC1F,0FAA0F;AAC1F,yFAAyF;AACzF,2FAA2F;AAC3F,8EAA8E;AAC9E,EAAE;AACF,0FAA0F;AAC1F,0FAA0F;AAC1F,4FAA4F;AAC5F,2FAA2F;AAC3F,6FAA6F;AAC7F,EAAE;AACF,4FAA4F;AAC5F,2FAA2F;AAC3F,0CAA0C;AAC1C,8EAA8E;AAE9E,MAAM,CAAC,MAAM,qBAAqB,GAAG,kBAAkB,CAAA;AAEvD;;;;;GAKG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,sBAAsB,CACpD,CAAC,CAAC,MAAM,CAAC;IACP,sFAAsF;IACtF,OAAO,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,OAAO,EAAE,qBAAqB,CAAC,CAAC,EAAE,OAAO,CAAC;IAC1E,2FAA2F;IAC3F,OAAO,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,SAAS,CAAC;IACtD,wDAAwD;IACxD,mBAAmB,EAAE,CAAC,CAAC,QAAQ,CAAC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":"","sources":["../../../src/agents/kinds/step-surface.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;
|
|
1
|
+
{"version":3,"file":"step-surface.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/step-surface.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;AAGpD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAA;AAqBtD,eAAO,MAAM,8BAA8B,wBAAwB,CAAA;AACnE,eAAO,MAAM,yBAAyB,mBAAmB,CAAA;AACzD,eAAO,MAAM,kCAAkC,4BAA4B,CAAA;AAC3E,eAAO,MAAM,kCAAkC,4BAA4B,CAAA;AAe3E;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,iBAAiB,GAAG,OAAO,CAGvF"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ENVIRONMENT_INVESTIGATOR_AGENT_KIND } from '@cat-factory/contracts';
|
|
1
2
|
import { TASK_ESTIMATOR_AGENT_KIND } from '../prompts/roles.js';
|
|
2
3
|
// Which execution surface a pipeline step's model runs on — the taxonomy the preset
|
|
3
4
|
// satisfiability guard keys off. Only INLINE model steps need a special check: an inline
|
|
@@ -27,6 +28,11 @@ const INLINE_ENGINE_KINDS = new Set([
|
|
|
27
28
|
REQUIREMENTS_BRAINSTORM_AGENT_KIND,
|
|
28
29
|
ARCHITECTURE_BRAINSTORM_AGENT_KIND,
|
|
29
30
|
TASK_ESTIMATOR_AGENT_KIND,
|
|
31
|
+
// Never authored into a pipeline (the deployer's failure path drives it), so the start guard
|
|
32
|
+
// never grades it. Listed anyway because the taxonomy is what "does this kind run a model
|
|
33
|
+
// inline" means, and a kind that answers yes and is not listed here is a latent
|
|
34
|
+
// mis-classification the moment anything else asks the question.
|
|
35
|
+
ENVIRONMENT_INVESTIGATOR_AGENT_KIND,
|
|
30
36
|
]);
|
|
31
37
|
/**
|
|
32
38
|
* Whether a pipeline step of this kind runs its model as an INLINE LLM call (as opposed to a
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"step-surface.js","sourceRoot":"","sources":["../../../src/agents/kinds/step-surface.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAA;AAG/D,oFAAoF;AACpF,yFAAyF;AACzF,4FAA4F;AAC5F,6FAA6F;AAC7F,wFAAwF;AACxF,2CAA2C;AAC3C,EAAE;AACF,wFAAwF;AACxF,4FAA4F;AAC5F,yFAAyF;AAEzF,+EAA+E;AAC/E,0FAA0F;AAC1F,2FAA2F;AAC3F,uFAAuF;AACvF,qFAAqF;AACrF,sFAAsF;AACtF,0FAA0F;AAC1F,kCAAkC;AAClC,MAAM,CAAC,MAAM,8BAA8B,GAAG,qBAAqB,CAAA;AACnE,MAAM,CAAC,MAAM,yBAAyB,GAAG,gBAAgB,CAAA;AACzD,MAAM,CAAC,MAAM,kCAAkC,GAAG,yBAAyB,CAAA;AAC3E,MAAM,CAAC,MAAM,kCAAkC,GAAG,yBAAyB,CAAA;AAE3E,MAAM,mBAAmB,GAAG,IAAI,GAAG,CAAS;IAC1C,8BAA8B;IAC9B,yBAAyB;IACzB,kCAAkC;IAClC,kCAAkC;IAClC,yBAAyB;
|
|
1
|
+
{"version":3,"file":"step-surface.js","sourceRoot":"","sources":["../../../src/agents/kinds/step-surface.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mCAAmC,EAAE,MAAM,wBAAwB,CAAA;AAC5E,OAAO,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAA;AAG/D,oFAAoF;AACpF,yFAAyF;AACzF,4FAA4F;AAC5F,6FAA6F;AAC7F,wFAAwF;AACxF,2CAA2C;AAC3C,EAAE;AACF,wFAAwF;AACxF,4FAA4F;AAC5F,yFAAyF;AAEzF,+EAA+E;AAC/E,0FAA0F;AAC1F,2FAA2F;AAC3F,uFAAuF;AACvF,qFAAqF;AACrF,sFAAsF;AACtF,0FAA0F;AAC1F,kCAAkC;AAClC,MAAM,CAAC,MAAM,8BAA8B,GAAG,qBAAqB,CAAA;AACnE,MAAM,CAAC,MAAM,yBAAyB,GAAG,gBAAgB,CAAA;AACzD,MAAM,CAAC,MAAM,kCAAkC,GAAG,yBAAyB,CAAA;AAC3E,MAAM,CAAC,MAAM,kCAAkC,GAAG,yBAAyB,CAAA;AAE3E,MAAM,mBAAmB,GAAG,IAAI,GAAG,CAAS;IAC1C,8BAA8B;IAC9B,yBAAyB;IACzB,kCAAkC;IAClC,kCAAkC;IAClC,yBAAyB;IACzB,6FAA6F;IAC7F,0FAA0F;IAC1F,gFAAgF;IAChF,iEAAiE;IACjE,mCAAmC;CACpC,CAAC,CAAA;AAEF;;;;;GAKG;AACH,MAAM,UAAU,iBAAiB,CAAC,IAAe,EAAE,QAA2B;IAC5E,IAAI,mBAAmB,CAAC,GAAG,CAAC,IAAI,CAAC;QAAE,OAAO,IAAI,CAAA;IAC9C,OAAO,QAAQ,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,OAAO,KAAK,QAAQ,CAAA;AACxD,CAAC"}
|
|
@@ -120,6 +120,28 @@ export declare const FOUNDATIONAL_CATALOG_TRAIT: AgentTrait;
|
|
|
120
120
|
* service the design deliberately rejected.
|
|
121
121
|
*/
|
|
122
122
|
export declare const FOUNDATIONAL_CONTRACTS_TRAIT: AgentTrait;
|
|
123
|
+
/**
|
|
124
|
+
* ORIENTATION-time kinds that need to know what the organisation RUNS in order to locate work: a
|
|
125
|
+
* bug triager deciding which service a report belongs to, an on-call investigator attributing a
|
|
126
|
+
* regression, any kind whose first problem is "whose is this".
|
|
127
|
+
*
|
|
128
|
+
* A third trait rather than a reuse of {@link FOUNDATIONAL_CATALOG_TRAIT}, because that one's
|
|
129
|
+
* guidance asks the kind to prefer consuming a shared service and to END its reply with a
|
|
130
|
+
* machine-read declaration block. Both are wrong here and the second is actively harmful: the
|
|
131
|
+
* triage kinds are structured-output kinds whose reply IS a JSON object, so appending "end your
|
|
132
|
+
* reply with a fenced block" would put their contract in conflict with itself. What this trait
|
|
133
|
+
* delivers is the same rows under a different framing (`.cat-context/foundational-services/
|
|
134
|
+
* estate.md`), stating ownership and interface surface and asking for nothing back.
|
|
135
|
+
*
|
|
136
|
+
* It deliberately does NOT carry the full API documents. Those stay behind a design's declaration,
|
|
137
|
+
* which is the whole point of the catalog/contracts split: an orientation read happens on every
|
|
138
|
+
* triage dispatch, and folding every service's OpenAPI document into one would make the prompt
|
|
139
|
+
* scale with the size of the organisation's specs. A kind that genuinely needs a document carries
|
|
140
|
+
* `foundational-contracts` and reads the ids a prior design declared.
|
|
141
|
+
*/
|
|
142
|
+
export declare const SERVICE_ESTATE_TRAIT: AgentTrait;
|
|
143
|
+
/** The guidance an orientation kind gets: locate and attribute, do not choose or declare. */
|
|
144
|
+
export declare const SERVICE_ESTATE_GUIDANCE: string;
|
|
123
145
|
/** The guidance a design-time kind gets: consult the catalog, then DECLARE what it used. */
|
|
124
146
|
export declare const FOUNDATIONAL_CATALOG_GUIDANCE: string;
|
|
125
147
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"traits.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/traits.ts"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,SAAS,
|
|
1
|
+
{"version":3,"file":"traits.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/traits.ts"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,SAAS,EAUf,MAAM,qBAAqB,CAAA;AAC5B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAA;AAetD,yFAAyF;AACzF,MAAM,MAAM,UAAU,GAAG,MAAM,CAAA;AAE/B;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,EAAE,UAAyB,CAAA;AAExD;;;;;;;GAOG;AACH,eAAO,MAAM,e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T_KIND, FOUNDATIONAL_CATALOG_FILE, FOUNDATIONAL_CONTEXT_DIR, FOUNDATIONAL_DECLARATION_TAG, FOUNDATIONAL_INDEX_FILE, INITIATIVE_INTERVIEWER_AGENT_KIND, } from '@cat-factory/kernel';
|
|
2
|
+
import { BINARY_OUTPUT_BRIEF_FILE, BINARY_OUTPUT_DECLARATION_TAG, DOC_INTERVIEWER_AGENT_KIND, FOUNDATIONAL_CATALOG_FILE, FOUNDATIONAL_CONTEXT_DIR, FOUNDATIONAL_DECLARATION_TAG, FOUNDATIONAL_ESTATE_FILE, FOUNDATIONAL_INDEX_FILE, INITIATIVE_INTERVIEWER_AGENT_KIND, } from '@cat-factory/kernel';
|
|
3
3
|
/**
|
|
4
4
|
* Code-aware kinds read and/or change the service's code. The service's selected
|
|
5
5
|
* best-practice / guideline fragments (Node, Fastify, performance, …) are folded into
|
|
@@ -118,6 +118,32 @@ export const FOUNDATIONAL_CATALOG_TRAIT = 'foundational-catalog';
|
|
|
118
118
|
* service the design deliberately rejected.
|
|
119
119
|
*/
|
|
120
120
|
export const FOUNDATIONAL_CONTRACTS_TRAIT = 'foundational-contracts';
|
|
121
|
+
/**
|
|
122
|
+
* ORIENTATION-time kinds that need to know what the organisation RUNS in order to locate work: a
|
|
123
|
+
* bug triager deciding which service a report belongs to, an on-call investigator attributing a
|
|
124
|
+
* regression, any kind whose first problem is "whose is this".
|
|
125
|
+
*
|
|
126
|
+
* A third trait rather than a reuse of {@link FOUNDATIONAL_CATALOG_TRAIT}, because that one's
|
|
127
|
+
* guidance asks the kind to prefer consuming a shared service and to END its reply with a
|
|
128
|
+
* machine-read declaration block. Both are wrong here and the second is actively harmful: the
|
|
129
|
+
* triage kinds are structured-output kinds whose reply IS a JSON object, so appending "end your
|
|
130
|
+
* reply with a fenced block" would put their contract in conflict with itself. What this trait
|
|
131
|
+
* delivers is the same rows under a different framing (`.cat-context/foundational-services/
|
|
132
|
+
* estate.md`), stating ownership and interface surface and asking for nothing back.
|
|
133
|
+
*
|
|
134
|
+
* It deliberately does NOT carry the full API documents. Those stay behind a design's declaration,
|
|
135
|
+
* which is the whole point of the catalog/contracts split: an orientation read happens on every
|
|
136
|
+
* triage dispatch, and folding every service's OpenAPI document into one would make the prompt
|
|
137
|
+
* scale with the size of the organisation's specs. A kind that genuinely needs a document carries
|
|
138
|
+
* `foundational-contracts` and reads the ids a prior design declared.
|
|
139
|
+
*/
|
|
140
|
+
export const SERVICE_ESTATE_TRAIT = 'service-estate';
|
|
141
|
+
/** The guidance an orientation kind gets: locate and attribute, do not choose or declare. */
|
|
142
|
+
export const SERVICE_ESTATE_GUIDANCE = [
|
|
143
|
+
`This organisation records the services it runs in a catalog, and it is provided to you as \`.cat-context/${FOUNDATIONAL_ESTATE_FILE}\`. Read it when you need to work out WHICH service a piece of work belongs to, who owns it, or what interface it exposes to the rest of the estate.`,
|
|
144
|
+
`Use it for attribution and for scope. Naming the owning team, or the neighbouring service a fault crosses into, is far more useful than a guess drawn from a repository name. Where the file says an owner is not recorded, say that rather than inferring one.`,
|
|
145
|
+
`It lists each service's operations, NOT its full API documents: enough to say which service exposes what, and not enough to write a call against. Do not invent an endpoint, a field or an owner it does not state, and if what you need belongs to a service the file does not carry, say so in your report.`,
|
|
146
|
+
].join('\n');
|
|
121
147
|
/** The guidance a design-time kind gets: consult the catalog, then DECLARE what it used. */
|
|
122
148
|
export const FOUNDATIONAL_CATALOG_GUIDANCE = [
|
|
123
149
|
`This deployment runs shared FOUNDATIONAL SERVICES — capabilities such as file storage, notifications or audit that already exist and that new systems are expected to CONSUME rather than rebuild. The catalog of what is available is provided to you as \`.cat-context/${FOUNDATIONAL_CATALOG_FILE}\`; read it before you settle on a design.`,
|
|
@@ -216,8 +242,10 @@ export const STANDARD_AGENT_TRAITS = {
|
|
|
216
242
|
mocker: [SPEC_AWARE_TRAIT],
|
|
217
243
|
merger: [SPEC_AWARE_TRAIT],
|
|
218
244
|
// The on-call agent clones the released change and reads the code to correlate the diff
|
|
219
|
-
// with the regression evidence, so it gets the service's best-practice + spec context
|
|
220
|
-
|
|
245
|
+
// with the regression evidence, so it gets the service's best-practice + spec context, plus
|
|
246
|
+
// the estate: a release regression routinely shows up in a service other than the one that
|
|
247
|
+
// shipped, and attributing it needs to know which services exist and who owns them.
|
|
248
|
+
'on-call': [CODE_AWARE_TRAIT, SPEC_AWARE_TRAIT, SERVICE_ESTATE_TRAIT],
|
|
221
249
|
// The document reviewer is a companion (no `AgentKindDefinition` of its own), so it
|
|
222
250
|
// gets `doc-aware` here — folding the SAME writing-style fragments the writer received,
|
|
223
251
|
// which become its review criteria (style guidance as both instruction and check).
|
|
@@ -279,6 +307,13 @@ export const STANDARD_TRAIT_DEFINITIONS = [
|
|
|
279
307
|
id: FOUNDATIONAL_CONTRACTS_TRAIT,
|
|
280
308
|
guidance: (_kind, delivery) => wasDelivered(delivery, FOUNDATIONAL_INDEX_FILE) ? FOUNDATIONAL_CONTRACTS_GUIDANCE : undefined,
|
|
281
309
|
},
|
|
310
|
+
// Gated on its file for the same reason the two above are: on a deployment with no catalog
|
|
311
|
+
// resolver the engine injects nothing, and a guidance section whose first sentence names a
|
|
312
|
+
// missing path reads to the agent as a platform fault rather than as an absence.
|
|
313
|
+
{
|
|
314
|
+
id: SERVICE_ESTATE_TRAIT,
|
|
315
|
+
guidance: (_kind, delivery) => wasDelivered(delivery, FOUNDATIONAL_ESTATE_FILE) ? SERVICE_ESTATE_GUIDANCE : undefined,
|
|
316
|
+
},
|
|
282
317
|
// NOT gated, deliberately, though it names a file the same way. Its own text handles the absent
|
|
283
318
|
// case as a REFUSAL ("If that file is absent, the platform could not provide storage — do not
|
|
284
319
|
// attempt any upload; state it in your report and stop generating"), which is a thing the agent
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"traits.js","sourceRoot":"","sources":["../../../src/agents/kinds/traits.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,wBAA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86,11 @@ export declare const PROMPT_VERSIONS: {
|
|
|
86
86
|
readonly version: 2;
|
|
87
87
|
readonly text: string;
|
|
88
88
|
};
|
|
89
|
+
readonly 'environment-investigation': {
|
|
90
|
+
readonly id: 'environment-investigation';
|
|
91
|
+
readonly version: 1;
|
|
92
|
+
readonly text: string;
|
|
93
|
+
};
|
|
89
94
|
};
|
|
90
95
|
/** Ids of the prompts currently under version control. */
|
|
91
96
|
export type PromptId = keyof typeof PROMPT_VERSIONS;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/versions.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../src/agents/kinds/versions.ts"],"names":[],"mappings":"AA+BA,+EAA+E;AAC/E,MAAM,WAAW,eAAe;IAC9B,EAAE,EAAE,MAAM,CAAA;IACV,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,MAAM,CAAA;CACb;AAED,8DAA8D;AAC9D,eAAO,MAAM,eAAe;;iBAgBF,EAAE,EAAE,oBAAoB;iBAAE,OAAO,EAAE,CAAC;iBAAE,IAAI;;;iBAC1C,EAAE,EAAE,oBAAoB;iBAAE,OAAO,EAAE,CAAC;iBAAE,IAAI;;;iBAC1C,EAAE,EAAE,oBAAoB;iBAAE,OAAO,EAAE,CAAC;iBAAE,IAAI;;;iBAG9C,EAAE,EAAE,gBAAgB;iBAAE,OAAO,EAAE,CAAC;iBAAE,IAAI;;;iBACtC,EAAE,EAAE,gBAAgB;iBAAE,OAAO,EAAE,CAAC;iBAAE,IAAI;;;iBAExD,EAAE,EAAE,yBAAyB;iBAC7B,OAAO,EAAE,CAAC;iBACV,IAAI;;;iBAGJ,EAAE,EAAE,gCAAgC;iBACpC,OAAO,EAAE,CAAC;iBACV,IAAI;;;iBAGJ,EAAE,EAAE,yBAAyB;iBAC7B,OAAO,EAAE,CAAC;iBACV,IAAI;;;iBAGJ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';
|
|
3
3
|
import { CLARITY_REVIEW_SYSTEM_PROMPT, CLARITY_REWORK_SYSTEM_PROMPT } from '../prompts/clarity.js';
|
|
4
4
|
import { ARCHITECTURE_BRAINSTORM_REWORK_SYSTEM_PROMPT, ARCHITECTURE_BRAINSTORM_SYSTEM_PROMPT, REQUIREMENTS_BRAINSTORM_REWORK_SYSTEM_PROMPT, REQUIREMENTS_BRAINSTORM_SYSTEM_PROMPT, } from '../prompts/brainstorm.js';
|
|
5
|
+
import { ENVIRONMENT_INVESTIGATION_SYSTEM_PROMPT } from '../prompts/environment-investigation.js';
|
|
5
6
|
import { KAIZEN_SYSTEM_PROMPT } from '../prompts/kaizen.js';
|
|
6
7
|
import { FORK_PROPOSER_SYSTEM_PROMPT } from './fork-proposer.js';
|
|
7
8
|
import { FORK_CHAT_SYSTEM_PROMPT } from '../prompts/fork-decision.js';
|
|
@@ -85,6 +86,12 @@ export const PROMPT_VERSIONS = {
|
|
|
85
86
|
// label attribute an outcome to); it does not re-key a Kaizen combo, because a judge is attached
|
|
86
87
|
// to a step and is never a step's own `agentKind`, which is what `promptVersionForKind` reads.
|
|
87
88
|
judge: { id: 'judge', version: 2, text: JUDGE_SYSTEM_PROMPT },
|
|
89
|
+
// Numbering starts at 1: there is no earlier RECORDED version to succeed.
|
|
90
|
+
'environment-investigation': {
|
|
91
|
+
id: 'environment-investigation',
|
|
92
|
+
version: 1,
|
|
93
|
+
text: ENVIRONMENT_INVESTIGATION_SYSTEM_PROMPT,
|
|
94
|
+
},
|
|
88
95
|
};
|
|
89
96
|
/**
|
|
90
97
|
* The versioned prompt id for each STANDARD PHASE that is under version control. The
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"versions.js","sourceRoot":"","sources":["../../../src/agents/kinds/versions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,YAAY,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAA;AAC/F,OAAO,EACL,oBAAoB,EACpB,oBAAoB,EACpB,o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@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { EnvironmentInvestigationSubject } from '@cat-factory/kernel';
|
|
2
|
+
import { type BespokeSystemPrompt } from './bespoke.js';
|
|
3
|
+
/**
|
|
4
|
+
* The role/directives split. `product: 'reply'` because the engine PARSES the verdict: the
|
|
5
|
+
* directives half therefore owns the JSON contract, the closed action vocabulary and the
|
|
6
|
+
* evidence-or-say-so rule, so a workspace override of the role cannot leave the engine with
|
|
7
|
+
* nothing to read or with a remediation it never offered.
|
|
8
|
+
*/
|
|
9
|
+
export declare const ENVIRONMENT_INVESTIGATION_PROMPT: BespokeSystemPrompt;
|
|
10
|
+
/** The shipped prompt, composed. A workspace override replaces the role half only. */
|
|
11
|
+
export declare const ENVIRONMENT_INVESTIGATION_SYSTEM_PROMPT: string;
|
|
12
|
+
/**
|
|
13
|
+
* Assemble one investigation prompt from the evidence bundle. Pure, so the whole framing can be
|
|
14
|
+
* exercised, including every degraded shape (no record, no fields, no provider diagnosis),
|
|
15
|
+
* without a model.
|
|
16
|
+
*
|
|
17
|
+
* The bundle's absences are RENDERED rather than skipped, which is the point of the function: a
|
|
18
|
+
* section quietly omitted reads exactly like a section that came back clean, and the investigator
|
|
19
|
+
* would then reason from a silence the platform never earned.
|
|
20
|
+
*/
|
|
21
|
+
export declare function renderEnvironmentInvestigationPrompt(subject: EnvironmentInvestigationSubject): string;
|
|
22
|
+
//# sourceMappingURL=environment-investigation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"environment-investigation.d.ts","sourceRoot":"","sources":["../../../src/agents/prompts/environment-investigation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAGV,+BAA+B,EAChC,MAAM,qBAAqB,CAAA;AAC5B,OAAO,EAAE,KAAK,mBAAmB,EAAwB,MAAM,cAAc,CAAA;AAmB7E;;;;;GAKG;AACH,eAAO,MAAM,gCAAgC,EAAE,mBAiD9C,CAAA;AAED,sFAAsF;AACtF,eAAO,MAAM,uCAAuC,QAEnD,CAAA;AA6HD;;;;;;;;GAQG;AACH,wBAAgB,oCAAoC,CAClD,OAAO,EAAE,+BAA+B,GACvC,MAAM,CAqCR"}
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
import { composeBespokePrompt } from './bespoke.js';
|
|
2
|
+
import { FINAL_ANSWER_IN_REPLY, NO_ASSUMED_PRODUCT } from './shared.js';
|
|
3
|
+
// ---------------------------------------------------------------------------
|
|
4
|
+
// The ENVIRONMENT INVESTIGATOR prompt: the inline LLM call behind the platform's diagnosis of an
|
|
5
|
+
// environment that never became usable.
|
|
6
|
+
//
|
|
7
|
+
// It is the counterpart of the `deploy-fixer` and is deliberately the opposite kind of agent. The
|
|
8
|
+
// fixer is a container with a checkout whose product is a pushed commit; this one has no checkout,
|
|
9
|
+
// no container and no credentials, because the evidence and the actions both live on the platform
|
|
10
|
+
// side of the boundary and provider credentials never reach a container. Its whole product is the
|
|
11
|
+
// JSON the engine parses.
|
|
12
|
+
//
|
|
13
|
+
// The one piece of knowledge the role encodes is the one a human contributed to the incident this
|
|
14
|
+
// was written for: look PAST the summary field. A provider that answered `status: online` was
|
|
15
|
+
// carrying an offline VM and two unhealthy balancers in the same response, and the diagnosis is
|
|
16
|
+
// entirely the observation that two named sources disagreed.
|
|
17
|
+
// ---------------------------------------------------------------------------
|
|
18
|
+
/**
|
|
19
|
+
* The role/directives split. `product: 'reply'` because the engine PARSES the verdict: the
|
|
20
|
+
* directives half therefore owns the JSON contract, the closed action vocabulary and the
|
|
21
|
+
* evidence-or-say-so rule, so a workspace override of the role cannot leave the engine with
|
|
22
|
+
* nothing to read or with a remediation it never offered.
|
|
23
|
+
*/
|
|
24
|
+
export const ENVIRONMENT_INVESTIGATION_PROMPT = {
|
|
25
|
+
product: 'reply',
|
|
26
|
+
role: 'You are a platform engineer investigating why an ephemeral environment a delivery pipeline ' +
|
|
27
|
+
'provisioned never became usable. You are given everything the platform knows about it: the ' +
|
|
28
|
+
"environment record it keeps itself, the whole field bag the provider's own response was " +
|
|
29
|
+
"mapped into, the run's provisioning attempts in order, and (when the provider can answer " +
|
|
30
|
+
"at all) the provider's own account of the environment and its logs.\n\n" +
|
|
31
|
+
'Your job is to settle WHERE the fault is and WHETHER anything is worth trying. Work the way ' +
|
|
32
|
+
'a human would with the same evidence:\n' +
|
|
33
|
+
'- READ PAST THE SUMMARY FIELD. A provider that reports one healthy top-level status while ' +
|
|
34
|
+
'its own sub-resources report otherwise is the single most common shape of this failure. Two ' +
|
|
35
|
+
'named sources disagreeing IS the finding; say which said what.\n' +
|
|
36
|
+
'- LINE THE TIMESTAMPS UP. A readiness verdict that settled before the work that produces ' +
|
|
37
|
+
'readiness even started is a platform fault, not an infrastructure one.\n' +
|
|
38
|
+
'- SEPARATE THE LAYERS. The environment being unreachable from where the test ran, the ' +
|
|
39
|
+
'workload being unhealthy, and the infrastructure under it being absent are three different ' +
|
|
40
|
+
'faults with three different owners.\n' +
|
|
41
|
+
'- DISTRUST ABSENCE. A read the platform could not make is recorded as a gap; it is UNKNOWN, ' +
|
|
42
|
+
'never healthy. Never conclude a workload started cleanly from the absence of its logs.\n\n' +
|
|
43
|
+
'You never touch a repository and you never run anything yourself. The platform performs the ' +
|
|
44
|
+
'remediation you ask for and then re-checks the environment; whether it worked is decided by ' +
|
|
45
|
+
'that re-check and never by what you say here.',
|
|
46
|
+
directives: '\n\nChoose ONE `action`, and only from the list the prompt says is offered this round. An ' +
|
|
47
|
+
'action outside it is discarded and read as `stop`, so a remedy you think is right but that ' +
|
|
48
|
+
'is not offered belongs in `actionRationale` instead. `stop` when nothing here is retryable ' +
|
|
49
|
+
'and a person has to act: that is a legitimate, useful answer and it is far better than a ' +
|
|
50
|
+
'speculative retry, because the named cause it carries is the whole reason you were asked.\n' +
|
|
51
|
+
'Cite what you actually read. Every `evidence` entry names its `source` (a key from the ' +
|
|
52
|
+
'provision fields, a provider fact, a timeline entry) and states the fact in your words. Do ' +
|
|
53
|
+
'not invent a field you were not shown, and return an EMPTY evidence array rather than a ' +
|
|
54
|
+
'padded one when the bundle genuinely supported nothing.\n' +
|
|
55
|
+
'Reply with ONLY a JSON object of this shape, with no prose around it and no code fences:\n' +
|
|
56
|
+
'{\n' +
|
|
57
|
+
' "faultLayer": "provider" | "platform" | "deployment" | "unknown",\n' +
|
|
58
|
+
' "summary": "one paragraph: what is wrong, in plain words",\n' +
|
|
59
|
+
' "evidence": [{ "source": "where the fact came from", "statement": "the fact" }],\n' +
|
|
60
|
+
' "action": "one of the offered actions",\n' +
|
|
61
|
+
' "actionRationale": "why that action, in a sentence or two"\n' +
|
|
62
|
+
'}\n' +
|
|
63
|
+
'Use `faultLayer: "unknown"` when the evidence did not settle it. It is a real answer: ' +
|
|
64
|
+
'"we could not tell" and "the provider is broken" send different people to different places.\n' +
|
|
65
|
+
// The shared rule every inline engine kind carries, and it binds here for its own reason as
|
|
66
|
+
// well as the shared one: the vendor behind an environment is not in the evidence, so an
|
|
67
|
+
// investigator that names one has invented the layer it is blaming.
|
|
68
|
+
NO_ASSUMED_PRODUCT +
|
|
69
|
+
' ' +
|
|
70
|
+
FINAL_ANSWER_IN_REPLY,
|
|
71
|
+
};
|
|
72
|
+
/** The shipped prompt, composed. A workspace override replaces the role half only. */
|
|
73
|
+
export const ENVIRONMENT_INVESTIGATION_SYSTEM_PROMPT = composeBespokePrompt(ENVIRONMENT_INVESTIGATION_PROMPT);
|
|
74
|
+
/** Section separator, matching the other assembled inline prompts. */
|
|
75
|
+
function section(title, body) {
|
|
76
|
+
return `--- ${title} ---\n${body}`;
|
|
77
|
+
}
|
|
78
|
+
function renderRecord(bundle) {
|
|
79
|
+
const env = bundle.environment;
|
|
80
|
+
const lines = [
|
|
81
|
+
`id: ${env.id ?? '(none recorded)'}`,
|
|
82
|
+
`status: ${env.status}`,
|
|
83
|
+
`url: ${env.url ?? '(none published)'}`,
|
|
84
|
+
`provisionType: ${env.provisionType ?? '(unrecorded)'}`,
|
|
85
|
+
`engine: ${env.engine ?? '(unrecorded)'}`,
|
|
86
|
+
`expiresAt: ${env.expiresAt === null ? '(no TTL)' : new Date(env.expiresAt).toISOString()}`,
|
|
87
|
+
`lastError: ${env.lastError ?? '(none)'}`,
|
|
88
|
+
];
|
|
89
|
+
return section("The platform's own environment record", lines.join('\n'));
|
|
90
|
+
}
|
|
91
|
+
function renderProvisionFields(bundle) {
|
|
92
|
+
const entries = Object.entries(bundle.provisionFields);
|
|
93
|
+
if (entries.length === 0) {
|
|
94
|
+
return section('Provision fields captured from the provider', 'The provider captured no fields for this environment (or they could not be read; see the ' +
|
|
95
|
+
'timeline). This is an ABSENCE, not a clean result.');
|
|
96
|
+
}
|
|
97
|
+
const body = entries
|
|
98
|
+
.sort(([a], [b]) => a.localeCompare(b))
|
|
99
|
+
.map(([key, value]) => `${key}: ${value}`)
|
|
100
|
+
.join('\n');
|
|
101
|
+
return section("Provision fields captured from the provider's own response", `${body}\n\nThese are the provider's words, mapped verbatim at provision and on every poll.`);
|
|
102
|
+
}
|
|
103
|
+
function renderTimeline(bundle) {
|
|
104
|
+
if (bundle.timeline.length === 0) {
|
|
105
|
+
return section("The run's provisioning timeline", 'No provisioning attempts were recorded for this run. Either this deployment keeps no ' +
|
|
106
|
+
'provisioning log, or nothing was ever appended. The two are indistinguishable here, so ' +
|
|
107
|
+
'draw no conclusion from the silence.');
|
|
108
|
+
}
|
|
109
|
+
const body = bundle.timeline
|
|
110
|
+
.map((entry) => {
|
|
111
|
+
const stamp = entry.at === null ? '(undated)' : new Date(entry.at).toISOString();
|
|
112
|
+
return `${stamp} ${entry.label}${entry.detail ? `\n ${entry.detail}` : ''}`;
|
|
113
|
+
})
|
|
114
|
+
.join('\n');
|
|
115
|
+
return section("The run's provisioning timeline (oldest first)", body);
|
|
116
|
+
}
|
|
117
|
+
/** Compile-time totality guard for {@link renderReadinessWait}. */
|
|
118
|
+
function unhandledReadinessWait(kind) {
|
|
119
|
+
return `The platform recorded an unrecognised readiness state (${JSON.stringify(kind)}).`;
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* What the readiness wait says about this failure, in the three ways it can say something.
|
|
123
|
+
*
|
|
124
|
+
* The distinction is load-bearing right above the role's "LINE THE TIMESTAMPS UP" directive: an
|
|
125
|
+
* absent duration used to render as "there was a live verdict and nothing waited", which is a
|
|
126
|
+
* CLAIM, and it was false on every failure route except the provider's own declared failure.
|
|
127
|
+
*/
|
|
128
|
+
function renderReadinessWait(failure) {
|
|
129
|
+
switch (failure.readinessWait) {
|
|
130
|
+
case 'waited':
|
|
131
|
+
return (`The readiness wait ran for ${Math.round((failure.waitedMs ?? 0) / 1000)} seconds before ` +
|
|
132
|
+
'it was given up on.');
|
|
133
|
+
case 'verdict_without_wait':
|
|
134
|
+
return 'Nothing waited on this environment: there was a live verdict and it was not ready.';
|
|
135
|
+
case 'not_reached':
|
|
136
|
+
return ('This failure happened BEFORE any readiness judgement, so there is no readiness verdict ' +
|
|
137
|
+
'and no wait duration. Draw no conclusion from either; the provisioning timeline below is ' +
|
|
138
|
+
'the only account of how long the attempt ran.');
|
|
139
|
+
default:
|
|
140
|
+
return unhandledReadinessWait(failure.readinessWait);
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
function renderDiagnosis(diagnosis) {
|
|
144
|
+
const parts = [];
|
|
145
|
+
parts.push(diagnosis.facts.length === 0
|
|
146
|
+
? 'Facts: the provider returned none.'
|
|
147
|
+
: `Facts:\n${diagnosis.facts
|
|
148
|
+
.map((fact) => {
|
|
149
|
+
const verdict = fact.healthy === undefined
|
|
150
|
+
? '(provider offers no verdict)'
|
|
151
|
+
: fact.healthy
|
|
152
|
+
? '(provider considers this healthy)'
|
|
153
|
+
: '(provider considers this UNHEALTHY)';
|
|
154
|
+
return ` ${fact.key} = ${fact.value} ${verdict}`;
|
|
155
|
+
})
|
|
156
|
+
.join('\n')}`);
|
|
157
|
+
for (const entry of diagnosis.logs ?? []) {
|
|
158
|
+
parts.push(`Log from ${entry.source}${entry.truncated ? ' (TAIL only; the start was dropped)' : ''}:\n${entry.text}`);
|
|
159
|
+
}
|
|
160
|
+
if (diagnosis.gaps?.length) {
|
|
161
|
+
parts.push(`Reads the provider could NOT make (treat each as UNKNOWN, never as healthy):\n${diagnosis.gaps
|
|
162
|
+
.map((gap) => ` ${gap.read}: ${gap.reason}${gap.permanent ? ' (this will never answer differently)' : ''}`)
|
|
163
|
+
.join('\n')}`);
|
|
164
|
+
}
|
|
165
|
+
return section("The provider's own account", parts.join('\n\n'));
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* Assemble one investigation prompt from the evidence bundle. Pure, so the whole framing can be
|
|
169
|
+
* exercised, including every degraded shape (no record, no fields, no provider diagnosis),
|
|
170
|
+
* without a model.
|
|
171
|
+
*
|
|
172
|
+
* The bundle's absences are RENDERED rather than skipped, which is the point of the function: a
|
|
173
|
+
* section quietly omitted reads exactly like a section that came back clean, and the investigator
|
|
174
|
+
* would then reason from a silence the platform never earned.
|
|
175
|
+
*/
|
|
176
|
+
export function renderEnvironmentInvestigationPrompt(subject) {
|
|
177
|
+
const { evidence, offeredActions } = subject;
|
|
178
|
+
const parts = [
|
|
179
|
+
section('What went wrong', [
|
|
180
|
+
`The run recorded this provisioning failure:\n${evidence.failure.error}`,
|
|
181
|
+
evidence.failure.reason
|
|
182
|
+
? `The platform classified the cause as: ${evidence.failure.reason}`
|
|
183
|
+
: 'The platform could not classify the cause.',
|
|
184
|
+
renderReadinessWait(evidence.failure),
|
|
185
|
+
].join('\n\n')),
|
|
186
|
+
renderRecord(evidence),
|
|
187
|
+
renderProvisionFields(evidence),
|
|
188
|
+
renderTimeline(evidence),
|
|
189
|
+
];
|
|
190
|
+
if (evidence.diagnosis)
|
|
191
|
+
parts.push(renderDiagnosis(evidence.diagnosis));
|
|
192
|
+
if (evidence.diagnosisUnavailable) {
|
|
193
|
+
parts.push(section("The provider's own account is unavailable", evidence.diagnosisUnavailable));
|
|
194
|
+
}
|
|
195
|
+
if (evidence.evidenceCaps?.length) {
|
|
196
|
+
parts.push(section('What the platform did NOT pass on', `${evidence.evidenceCaps.map((cap) => `- ${cap}`).join('\n')}\n\nThese were held back by ` +
|
|
197
|
+
'the platform for size, not refused by the provider. Treat each as UNKNOWN.'));
|
|
198
|
+
}
|
|
199
|
+
parts.push(section('What the platform will do if you ask', `${offeredActions.join(', ')}\n\nAnything else is discarded and read as "stop".`));
|
|
200
|
+
return parts.join('\n\n');
|
|
201
|
+
}
|
|
202
|
+
//# sourceMappingURL=environment-investigation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"environment-investigation.js","sourceRoot":"","sources":["../../../src/agents/prompts/environment-investigation.ts"],"names":[],"mappings":"AAKA,OAAO,EAA4B,oBAAoB,EAAE,MAAM,cAAc,CAAA;AAC7E,OAAO,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAA;AAEvE,8EAA8E;AAC9E,iGAAiG;AACjG,wCAAwC;AACxC,EAAE;AACF,kGAAkG;AAClG,mGAAmG;AACnG,kGAAkG;AAClG,kGAAkG;AAClG,0BAA0B;AAC1B,EAAE;AACF,kGAAkG;AAClG,8FAA8F;AAC9F,gGAAgG;AAChG,6DAA6D;AAC7D,8EAA8E;AAE9E;;;;;GAKG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAwB;IACnE,OAAO,EAAE,OAAO;IAChB,IAAI,EACF,6FAA6F;QAC7F,6FAA6F;QAC7F,0FAA0F;QAC1F,2FAA2F;QAC3F,yEAAyE;QACzE,8FAA8F;QAC9F,yCAAyC;QACzC,4FAA4F;QAC5F,8FAA8F;QAC9F,kEAAkE;QAClE,2FAA2F;QAC3F,0EAA0E;QAC1E,wFAAwF;QACxF,6FAA6F;QAC7F,uCAAuC;QACvC,8FAA8F;QAC9F,4FAA4F;QAC5F,8FAA8F;QAC9F,8FAA8F;QAC9F,+CAA+C;IACjD,UAAU,EACR,4FAA4F;QAC5F,6FAA6F;QAC7F,6FAA6F;QAC7F,2FAA2F;QAC3F,6FAA6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CAAC;KACzB,CAAA;IACD,IAAI,QAAQ,CAAC,SAAS;QAAE,KAAK,CAAC,IAAI,CAAC,eAAe,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,CAAA;IACvE,IAAI,QAAQ,CAAC,oBAAoB,EAAE,CAAC;QAClC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,2CAA2C,EAAE,QAAQ,CAAC,oBAAoB,CAAC,CAAC,CAAA;IACjG,CAAC;IACD,IAAI,QAAQ,CAAC,YAAY,EAAE,MAAM,EAAE,CAAC;QAClC,KAAK,CAAC,IAAI,CACR,OAAO,CACL,mCAAmC,EACnC,GAAG,QAAQ,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,KAAK,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,8BAA8B;YACxF,4EAA4E,CAC/E,CACF,CAAA;IACH,CAAC;IACD,KAAK,CAAC,IAAI,CACR,OAAO,CACL,sCAAsC,EACtC,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,oDAAoD,CACjF,CACF,CAAA;IACD,OAAO,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;AAC3B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inline-engine.d.ts","sourceRoot":"","sources":["../../../src/agents/prompts/inline-engine.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inline-engine.d.ts","sourceRoot":"","sources":["../../../src/agents/prompts/inline-engine.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAA;AA6BvD,yEAAyE;AACzE,eAAO,MAAM,8BAA8B,wBAAwB,CAAA;AACnE,eAAO,MAAM,8BAA8B,wBAAwB,CAAA;AACnE,eAAO,MAAM,yBAAyB,mBAAmB,CAAA;AACzD,eAAO,MAAM,yCAAyC,mCAAmC,CAAA;AACzF,eAAO,MAAM,yCAAyC,mCAAmC,CAAA;AAEzF,eAAO,MAAM,4BAA4B,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,mBAAmB,CAAC,CAgBtF,CAAA"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
import { ENVIRONMENT_INVESTIGATOR_AGENT_KIND } from '@cat-factory/contracts';
|
|
1
2
|
import { REVIEW_PROMPT, REWORK_PROMPT, WRITER_PROMPT } from './requirements.js';
|
|
2
3
|
import { CLARITY_REVIEW_PROMPT, CLARITY_REWORK_PROMPT } from './clarity.js';
|
|
4
|
+
import { ENVIRONMENT_INVESTIGATION_PROMPT } from './environment-investigation.js';
|
|
3
5
|
import { ARCHITECTURE_BRAINSTORM_PROMPT, ARCHITECTURE_BRAINSTORM_REWORK_PROMPT, REQUIREMENTS_BRAINSTORM_PROMPT, REQUIREMENTS_BRAINSTORM_REWORK_PROMPT, } from './brainstorm.js';
|
|
4
6
|
// The system prompts of the INLINE ENGINE steps, keyed by the agent-kind id each runs under.
|
|
5
7
|
//
|
|
@@ -34,5 +36,11 @@ export const INLINE_ENGINE_SYSTEM_PROMPTS = {
|
|
|
34
36
|
[REQUIREMENTS_BRAINSTORM_REWORK_AGENT_KIND]: REQUIREMENTS_BRAINSTORM_REWORK_PROMPT,
|
|
35
37
|
'architecture-brainstorm': ARCHITECTURE_BRAINSTORM_PROMPT,
|
|
36
38
|
[ARCHITECTURE_BRAINSTORM_REWORK_AGENT_KIND]: ARCHITECTURE_BRAINSTORM_REWORK_PROMPT,
|
|
39
|
+
// Not a pipeline STEP: the deployer's failure path drives it, exactly as it drives the
|
|
40
|
+
// `deploy-fixer`. It belongs here all the same, because what makes a kind a member of this map
|
|
41
|
+
// is that its prompt is sent by a SERVICE rather than composed by `systemPromptFor`, which is
|
|
42
|
+
// the seam that both applies a workspace override and re-appends what an override may not
|
|
43
|
+
// delete.
|
|
44
|
+
[ENVIRONMENT_INVESTIGATOR_AGENT_KIND]: ENVIRONMENT_INVESTIGATION_PROMPT,
|
|
37
45
|
};
|
|
38
46
|
//# sourceMappingURL=inline-engine.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inline-engine.js","sourceRoot":"","sources":["../../../src/agents/prompts/inline-engine.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inline-engine.js","sourceRoot":"","sources":["../../../src/agents/prompts/inline-engine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mCAAmC,EAAE,MAAM,wBAAwB,CAAA;AAE5E,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAC/E,OAAO,EAAE,qBAAqB,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAA;AAC3E,OAAO,EAAE,gCAAgC,EAAE,MAAM,gCAAgC,CAAA;AACjF,OAAO,EACL,8BAA8B,EAC9B,qCAAqC,EACrC,8BAA8B,EAC9B,qCAAqC,GACtC,MAAM,iBAAiB,CAAA;AAExB,6FAA6F;AAC7F,EAAE;AACF,mFAAmF;AACnF,+FAA+F;AAC/F,yFAAyF;AACzF,8FAA8F;AAC9F,gGAAgG;AAChG,4FAA4F;AAC5F,0DAA0D;AAC1D,EAAE;AACF,gGAAgG;AAChG,iGAAiG;AACjG,YAAY;AACZ,EAAE;AACF,uFAAuF;AACvF,6FAA6F;AAC7F,0EAA0E;AAE1E,yEAAyE;AACzE,MAAM,CAAC,MAAM,8BAA8B,GAAG,qBAAqB,CAAA;AACnE,MAAM,CAAC,MAAM,8BAA8B,GAAG,qBAAqB,CAAA;AACnE,MAAM,CAAC,MAAM,yBAAyB,GAAG,gBAAgB,CAAA;AACzD,MAAM,CAAC,MAAM,yCAAyC,GAAG,gCAAgC,CAAA;AACzF,MAAM,CAAC,MAAM,yCAAyC,GAAG,gCAAgC,CAAA;AAEzF,MAAM,CAAC,MAAM,4BAA4B,GAAkD;IACzF,qBAAqB,EAAE,aAAa;IACpC,CAAC,8BAA8B,CAAC,EAAE,aAAa;IAC/C,CA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