substrate-ai 0.21.1 → 0.21.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/README.md +32 -3
- package/dist/adapter-registry-BSig1zpx.js +4 -0
- package/dist/cli/index.js +114 -19
- package/dist/cli/templates/agents-md-substrate-section.md +12 -1
- package/dist/cli/templates/claude-md-substrate-section.md +6 -0
- package/dist/cli/templates/gemini-md-substrate-section.md +12 -1
- package/dist/{decisions-BPwrDCTx.js → decisions-lxU14pNh.js} +1 -1
- package/dist/{dist-BkhYgJWo.js → dist-CpnLJuVw.js} +13 -3
- package/dist/{errors-C7pY6_yQ.js → errors-8tVEwG6v.js} +2 -2
- package/dist/{experimenter-BYqALeaE.js → experimenter-C7swe92R.js} +1 -1
- package/dist/{health-Cfkv6XoQ.js → health-Dnzblihr.js} +3 -3
- package/dist/{health-Coh3BG8W.js → health-bhMCTYDO.js} +3 -3
- package/dist/{index-CnV5PcSR.d.ts → index-C31XtSMn.d.ts} +8 -1
- package/dist/index.d.ts +45 -2
- package/dist/index.js +2 -2
- package/dist/{interactive-prompt-BBfPSxyJ.js → interactive-prompt-BM5RaXYG.js} +2 -2
- package/dist/{manifest-read-BhNRIiqm.js → manifest-read-B3gE46DX.js} +369 -4
- package/dist/modules/interactive-prompt/index.js +3 -3
- package/dist/{routing-BS-Q8_2L.js → routing-CGO2UZyA.js} +1 -1
- package/dist/{run-CKM-5T34.js → run-ChZFveqv.js} +5 -5
- package/dist/{run-JrEnvaB0.js → run-ZxFHQyE_.js} +219 -8
- package/dist/src/modules/recovery-engine/index.d.ts +16 -2
- package/dist/{upgrade-S1oUMH5P.js → upgrade-BUSzXgnd.js} +2 -2
- package/dist/{upgrade-BOWLlLbD.js → upgrade-M0UkDCeg.js} +2 -2
- package/dist/{version-manager-impl-BVcsgUtN.js → version-manager-impl-DeEPhQlA.js} +1 -1
- package/package.json +1 -1
- package/packs/bmad/prompts/create-story.md +22 -0
- package/dist/adapter-registry-CZn__637.js +0 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createLogger } from "./logger-KeHncl-f.js";
|
|
2
|
-
import { readCurrentRunId, resolveMainRepoRoot } from "./manifest-read-
|
|
2
|
+
import { readCurrentRunId, resolveMainRepoRoot } from "./manifest-read-B3gE46DX.js";
|
|
3
3
|
import { join } from "node:path";
|
|
4
4
|
import { mkdir, readFile, writeFile } from "node:fs/promises";
|
|
5
5
|
import * as readline from "node:readline";
|
|
@@ -180,4 +180,4 @@ async function runInteractivePrompt(decisionContext) {
|
|
|
180
180
|
|
|
181
181
|
//#endregion
|
|
182
182
|
export { runInteractivePrompt };
|
|
183
|
-
//# sourceMappingURL=interactive-prompt-
|
|
183
|
+
//# sourceMappingURL=interactive-prompt-BM5RaXYG.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createLogger } from "./logger-KeHncl-f.js";
|
|
2
|
-
import { LEARNING_FINDING, createDecision, getDecisionsByCategory } from "./dist-
|
|
2
|
+
import { LEARNING_FINDING, createDecision, getDecisionsByCategory } from "./dist-CpnLJuVw.js";
|
|
3
3
|
import * as path$1 from "path";
|
|
4
4
|
import { join } from "path";
|
|
5
5
|
import { readFile } from "fs/promises";
|
|
@@ -3087,7 +3087,21 @@ function executeProbeOnHost(probe, options = {}) {
|
|
|
3087
3087
|
* registry, os. Open string so novel names don't cause silent skips.
|
|
3088
3088
|
*/
|
|
3089
3089
|
const ExternalStateDependencySchema = z.string();
|
|
3090
|
-
|
|
3090
|
+
/**
|
|
3091
|
+
* Journey tags (acceptance-gate story A0.2): `journeys: [UJ-x]` declares which
|
|
3092
|
+
* registry journeys this story claims to deliver. Tolerant by design — a bare
|
|
3093
|
+
* string coerces to a one-element list, and any non-coercible shape falls back
|
|
3094
|
+
* to `[]` via `.catch` WITHOUT failing the whole frontmatter block (a malformed
|
|
3095
|
+
* journey tag must never silently drop `external_state_dependencies`).
|
|
3096
|
+
* Untagged is legal: the epic-close coverage invariant (A0.3) is the backstop;
|
|
3097
|
+
* tags only buy earlier detection. Unknown-id validation happens against the
|
|
3098
|
+
* trusted-tree registry in the create-story workflow, not here.
|
|
3099
|
+
*/
|
|
3100
|
+
const JourneyTagsSchema = z.union([z.string().transform((s) => [s]), z.array(z.string())]).catch([]);
|
|
3101
|
+
const StoryFrontmatterSchema = z.object({
|
|
3102
|
+
external_state_dependencies: z.array(ExternalStateDependencySchema).optional().default([]),
|
|
3103
|
+
journeys: JourneyTagsSchema.optional().default([])
|
|
3104
|
+
});
|
|
3091
3105
|
/**
|
|
3092
3106
|
* Parse the optional YAML frontmatter block from a story artifact.
|
|
3093
3107
|
*
|
|
@@ -4963,6 +4977,342 @@ async function runAcTraceabilityCheck(input) {
|
|
|
4963
4977
|
};
|
|
4964
4978
|
}
|
|
4965
4979
|
|
|
4980
|
+
//#endregion
|
|
4981
|
+
//#region packages/sdlc/dist/acceptance/registry.js
|
|
4982
|
+
/** Repo-relative path of the registry — the single canonical location. */
|
|
4983
|
+
const JOURNEY_REGISTRY_PATH = ".substrate/acceptance/journeys.yaml";
|
|
4984
|
+
const JourneySurfaceSchema = z.enum([
|
|
4985
|
+
"email",
|
|
4986
|
+
"cli",
|
|
4987
|
+
"file",
|
|
4988
|
+
"web"
|
|
4989
|
+
]);
|
|
4990
|
+
const JourneyEndStateSchema = z.object({
|
|
4991
|
+
id: z.string().min(1, "end-state id must be a non-empty string"),
|
|
4992
|
+
given: z.string().min(1, "given must be a non-empty string"),
|
|
4993
|
+
walk: z.string().min(1, "walk must be a non-empty string"),
|
|
4994
|
+
then: z.string().min(1, "then must be a non-empty string")
|
|
4995
|
+
});
|
|
4996
|
+
const JourneySchema = z.object({
|
|
4997
|
+
id: z.string().min(1, "journey id must be a non-empty string"),
|
|
4998
|
+
title: z.string().min(1, "title must be a non-empty string"),
|
|
4999
|
+
criticality: z.enum(["critical", "standard"]),
|
|
5000
|
+
surfaces: z.array(JourneySurfaceSchema).min(1, "a journey must declare at least one surface"),
|
|
5001
|
+
epic: z.number().int().positive().optional(),
|
|
5002
|
+
end_states: z.array(JourneyEndStateSchema).min(1, "a journey must declare at least one end_state — a journey with none is unjudgeable")
|
|
5003
|
+
});
|
|
5004
|
+
const JourneyRegistrySchema = z.object({
|
|
5005
|
+
version: z.number().int().positive("version must be a positive integer"),
|
|
5006
|
+
journeys: z.array(JourneySchema)
|
|
5007
|
+
}).superRefine((registry, ctx) => {
|
|
5008
|
+
const seenJourneyIds = new Map();
|
|
5009
|
+
registry.journeys.forEach((journey, i) => {
|
|
5010
|
+
const firstIndex = seenJourneyIds.get(journey.id);
|
|
5011
|
+
if (firstIndex !== void 0) ctx.addIssue({
|
|
5012
|
+
code: "custom",
|
|
5013
|
+
path: [
|
|
5014
|
+
"journeys",
|
|
5015
|
+
i,
|
|
5016
|
+
"id"
|
|
5017
|
+
],
|
|
5018
|
+
message: `duplicate journey id "${journey.id}" (first declared at journeys[${firstIndex}])`
|
|
5019
|
+
});
|
|
5020
|
+
else seenJourneyIds.set(journey.id, i);
|
|
5021
|
+
const seenEndStateIds = new Map();
|
|
5022
|
+
journey.end_states.forEach((endState, j) => {
|
|
5023
|
+
const firstEs = seenEndStateIds.get(endState.id);
|
|
5024
|
+
if (firstEs !== void 0) ctx.addIssue({
|
|
5025
|
+
code: "custom",
|
|
5026
|
+
path: [
|
|
5027
|
+
"journeys",
|
|
5028
|
+
i,
|
|
5029
|
+
"end_states",
|
|
5030
|
+
j,
|
|
5031
|
+
"id"
|
|
5032
|
+
],
|
|
5033
|
+
message: `duplicate end-state id "${endState.id}" in journey "${journey.id}" (first declared at end_states[${firstEs}])`
|
|
5034
|
+
});
|
|
5035
|
+
else seenEndStateIds.set(endState.id, j);
|
|
5036
|
+
});
|
|
5037
|
+
});
|
|
5038
|
+
});
|
|
5039
|
+
function zodErrorToValidationIssues(error) {
|
|
5040
|
+
return error.issues.map((issue) => ({
|
|
5041
|
+
path: issue.path.length > 0 ? issue.path.map(String).join(".") : "(root)",
|
|
5042
|
+
message: issue.message
|
|
5043
|
+
}));
|
|
5044
|
+
}
|
|
5045
|
+
/**
|
|
5046
|
+
* Parse and validate registry YAML content.
|
|
5047
|
+
*
|
|
5048
|
+
* Never throws: malformed YAML, non-object documents, and schema violations
|
|
5049
|
+
* all come back as named, pathed issues.
|
|
5050
|
+
*/
|
|
5051
|
+
function parseJourneyRegistry(yamlContent) {
|
|
5052
|
+
let doc;
|
|
5053
|
+
try {
|
|
5054
|
+
doc = load(yamlContent);
|
|
5055
|
+
} catch (err) {
|
|
5056
|
+
const message = err instanceof YAMLException ? err.message : String(err);
|
|
5057
|
+
return {
|
|
5058
|
+
ok: false,
|
|
5059
|
+
issues: [{
|
|
5060
|
+
path: "(root)",
|
|
5061
|
+
message: `malformed YAML: ${message}`
|
|
5062
|
+
}]
|
|
5063
|
+
};
|
|
5064
|
+
}
|
|
5065
|
+
if (doc === null || doc === void 0) return {
|
|
5066
|
+
ok: false,
|
|
5067
|
+
issues: [{
|
|
5068
|
+
path: "(root)",
|
|
5069
|
+
message: "registry file is empty"
|
|
5070
|
+
}]
|
|
5071
|
+
};
|
|
5072
|
+
const result = JourneyRegistrySchema.safeParse(doc);
|
|
5073
|
+
if (!result.success) return {
|
|
5074
|
+
ok: false,
|
|
5075
|
+
issues: zodErrorToValidationIssues(result.error)
|
|
5076
|
+
};
|
|
5077
|
+
return {
|
|
5078
|
+
ok: true,
|
|
5079
|
+
registry: result.data
|
|
5080
|
+
};
|
|
5081
|
+
}
|
|
5082
|
+
|
|
5083
|
+
//#endregion
|
|
5084
|
+
//#region packages/sdlc/dist/acceptance/coverage.js
|
|
5085
|
+
/**
|
|
5086
|
+
* Compute the coverage state of every journey audited at this scope.
|
|
5087
|
+
*
|
|
5088
|
+
* - `{epic: n}` audits journeys declaring `epic: n`.
|
|
5089
|
+
* - `{final: true}` audits the FULL registry (epicless journeys have no
|
|
5090
|
+
* earlier audit point; epic-scoped ones are re-audited — idempotent).
|
|
5091
|
+
*
|
|
5092
|
+
* State precedence: deferred > walked-fail > walked-pass > unwalked/unclaimed.
|
|
5093
|
+
* An operator deferral wins over everything (explicit scope decision); a fail
|
|
5094
|
+
* verdict wins over a pass (any failing end-state fails the journey).
|
|
5095
|
+
*/
|
|
5096
|
+
function computeJourneyCoverage(input) {
|
|
5097
|
+
const { registry, claims, verdicts, deferredJourneyIds, scope } = input;
|
|
5098
|
+
const audited = registry.journeys.filter((j) => "final" in scope ? true : j.epic === scope.epic);
|
|
5099
|
+
const claimsByJourney = new Map();
|
|
5100
|
+
for (const claim of claims) {
|
|
5101
|
+
const owners = claimsByJourney.get(claim.journeyId) ?? [];
|
|
5102
|
+
if (!owners.includes(claim.storyKey)) owners.push(claim.storyKey);
|
|
5103
|
+
claimsByJourney.set(claim.journeyId, owners);
|
|
5104
|
+
}
|
|
5105
|
+
const deferred = new Set(deferredJourneyIds);
|
|
5106
|
+
const verdictByJourney = new Map();
|
|
5107
|
+
for (const v of verdicts) {
|
|
5108
|
+
const existing = verdictByJourney.get(v.journeyId);
|
|
5109
|
+
verdictByJourney.set(v.journeyId, existing === "fail" ? "fail" : v.verdict);
|
|
5110
|
+
}
|
|
5111
|
+
return audited.map((journey) => {
|
|
5112
|
+
const ownerStories = claimsByJourney.get(journey.id) ?? [];
|
|
5113
|
+
let state;
|
|
5114
|
+
if (deferred.has(journey.id)) state = "deferred";
|
|
5115
|
+
else {
|
|
5116
|
+
const verdict = verdictByJourney.get(journey.id);
|
|
5117
|
+
if (verdict === "fail") state = "walked-fail";
|
|
5118
|
+
else if (verdict === "pass") state = "walked-pass";
|
|
5119
|
+
else state = ownerStories.length > 0 ? "unwalked" : "unclaimed";
|
|
5120
|
+
}
|
|
5121
|
+
return {
|
|
5122
|
+
journeyId: journey.id,
|
|
5123
|
+
title: journey.title,
|
|
5124
|
+
criticality: journey.criticality,
|
|
5125
|
+
...journey.epic !== void 0 ? { epic: journey.epic } : {},
|
|
5126
|
+
state,
|
|
5127
|
+
ownerStories
|
|
5128
|
+
};
|
|
5129
|
+
});
|
|
5130
|
+
}
|
|
5131
|
+
/** Aggregate counts for the `acceptance:coverage` event payload. */
|
|
5132
|
+
function summarizeCoverage(entries) {
|
|
5133
|
+
const summary = {
|
|
5134
|
+
"walked-pass": 0,
|
|
5135
|
+
"walked-fail": 0,
|
|
5136
|
+
deferred: 0,
|
|
5137
|
+
unclaimed: 0,
|
|
5138
|
+
unwalked: 0
|
|
5139
|
+
};
|
|
5140
|
+
for (const entry of entries) summary[entry.state] += 1;
|
|
5141
|
+
return summary;
|
|
5142
|
+
}
|
|
5143
|
+
/** Repo-relative path of the operator deferral file. */
|
|
5144
|
+
const JOURNEY_DEFERRALS_PATH = ".substrate/acceptance/deferrals.yaml";
|
|
5145
|
+
const JourneyDeferralSchema = z.object({
|
|
5146
|
+
journey: z.string().min(1),
|
|
5147
|
+
reason: z.string().min(1, "a deferral must carry an operator reason"),
|
|
5148
|
+
deferred_at: z.string().optional()
|
|
5149
|
+
});
|
|
5150
|
+
const JourneyDeferralsFileSchema = z.object({ deferrals: z.array(JourneyDeferralSchema) });
|
|
5151
|
+
/** Parse deferrals YAML. Never throws; malformed content comes back as issues. */
|
|
5152
|
+
function parseJourneyDeferrals(yamlContent) {
|
|
5153
|
+
let doc;
|
|
5154
|
+
try {
|
|
5155
|
+
doc = load(yamlContent);
|
|
5156
|
+
} catch (err) {
|
|
5157
|
+
const message = err instanceof YAMLException ? err.message : String(err);
|
|
5158
|
+
return {
|
|
5159
|
+
ok: false,
|
|
5160
|
+
issues: [{
|
|
5161
|
+
path: "(root)",
|
|
5162
|
+
message: `malformed YAML: ${message}`
|
|
5163
|
+
}]
|
|
5164
|
+
};
|
|
5165
|
+
}
|
|
5166
|
+
if (doc === null || doc === void 0) return {
|
|
5167
|
+
ok: true,
|
|
5168
|
+
deferrals: []
|
|
5169
|
+
};
|
|
5170
|
+
const result = JourneyDeferralsFileSchema.safeParse(doc);
|
|
5171
|
+
if (!result.success) return {
|
|
5172
|
+
ok: false,
|
|
5173
|
+
issues: result.error.issues.map((issue) => ({
|
|
5174
|
+
path: issue.path.length > 0 ? issue.path.map(String).join(".") : "(root)",
|
|
5175
|
+
message: issue.message
|
|
5176
|
+
}))
|
|
5177
|
+
};
|
|
5178
|
+
return {
|
|
5179
|
+
ok: true,
|
|
5180
|
+
deferrals: result.data.deferrals
|
|
5181
|
+
};
|
|
5182
|
+
}
|
|
5183
|
+
|
|
5184
|
+
//#endregion
|
|
5185
|
+
//#region packages/sdlc/dist/acceptance/loader.js
|
|
5186
|
+
/** stderr shapes that mean "the path is not in the tree at this ref" (absent, not an error). */
|
|
5187
|
+
const GIT_SHOW_ABSENT_PATTERNS = [
|
|
5188
|
+
/does not exist in/i,
|
|
5189
|
+
/exists on disk, but not in/i,
|
|
5190
|
+
/path .* does not exist/i
|
|
5191
|
+
];
|
|
5192
|
+
/** Array-argv spawn — no shell, no interpolation, injection-safe by construction. */
|
|
5193
|
+
function runGitShow(repoRoot, ref, relPath) {
|
|
5194
|
+
return new Promise((resolve$2) => {
|
|
5195
|
+
let stdout = "";
|
|
5196
|
+
let stderr = "";
|
|
5197
|
+
const proc = spawn("git", ["show", `${ref}:${relPath}`], {
|
|
5198
|
+
cwd: repoRoot,
|
|
5199
|
+
stdio: [
|
|
5200
|
+
"ignore",
|
|
5201
|
+
"pipe",
|
|
5202
|
+
"pipe"
|
|
5203
|
+
]
|
|
5204
|
+
});
|
|
5205
|
+
proc.stdout?.on("data", (chunk) => {
|
|
5206
|
+
stdout += chunk.toString("utf-8");
|
|
5207
|
+
});
|
|
5208
|
+
proc.stderr?.on("data", (chunk) => {
|
|
5209
|
+
stderr += chunk.toString("utf-8");
|
|
5210
|
+
});
|
|
5211
|
+
proc.on("error", (err) => {
|
|
5212
|
+
resolve$2({
|
|
5213
|
+
code: null,
|
|
5214
|
+
stdout,
|
|
5215
|
+
stderr,
|
|
5216
|
+
spawnError: err.message
|
|
5217
|
+
});
|
|
5218
|
+
});
|
|
5219
|
+
proc.on("close", (code) => {
|
|
5220
|
+
resolve$2({
|
|
5221
|
+
code,
|
|
5222
|
+
stdout,
|
|
5223
|
+
stderr
|
|
5224
|
+
});
|
|
5225
|
+
});
|
|
5226
|
+
});
|
|
5227
|
+
}
|
|
5228
|
+
/**
|
|
5229
|
+
* Load the journey registry from the trusted main tree at `ref`.
|
|
5230
|
+
*
|
|
5231
|
+
* @param repoRoot absolute path of the TRUSTED repo root (the main tree, not a worktree)
|
|
5232
|
+
* @param ref git ref to read at — the dispatch snapshot ref (defaults to HEAD)
|
|
5233
|
+
*/
|
|
5234
|
+
async function loadJourneyRegistryFromTrustedTree(repoRoot, ref = "HEAD") {
|
|
5235
|
+
const result = await runGitShow(repoRoot, ref, JOURNEY_REGISTRY_PATH);
|
|
5236
|
+
if (result.spawnError !== void 0) return {
|
|
5237
|
+
status: "error",
|
|
5238
|
+
message: `git show could not be spawned: ${result.spawnError}`
|
|
5239
|
+
};
|
|
5240
|
+
if (result.code !== 0) {
|
|
5241
|
+
if (GIT_SHOW_ABSENT_PATTERNS.some((p) => p.test(result.stderr))) return { status: "absent" };
|
|
5242
|
+
return {
|
|
5243
|
+
status: "error",
|
|
5244
|
+
message: `git show ${ref}:${JOURNEY_REGISTRY_PATH} failed (exit ${String(result.code)}): ${result.stderr.trim()}`
|
|
5245
|
+
};
|
|
5246
|
+
}
|
|
5247
|
+
const parsed = parseJourneyRegistry(result.stdout);
|
|
5248
|
+
if (!parsed.ok) return {
|
|
5249
|
+
status: "invalid",
|
|
5250
|
+
issues: parsed.issues
|
|
5251
|
+
};
|
|
5252
|
+
return {
|
|
5253
|
+
status: "ok",
|
|
5254
|
+
registry: parsed.registry
|
|
5255
|
+
};
|
|
5256
|
+
}
|
|
5257
|
+
/**
|
|
5258
|
+
* Load operator journey deferrals from the trusted tree at `ref`.
|
|
5259
|
+
* A0.3 note: `HEAD` at run end can include story-merged edits — full
|
|
5260
|
+
* tamper-hardening of this input is A1.3 scope (spec-tamper tripwire).
|
|
5261
|
+
*/
|
|
5262
|
+
async function loadJourneyDeferralsFromTrustedTree(repoRoot, ref = "HEAD") {
|
|
5263
|
+
const result = await runGitShow(repoRoot, ref, JOURNEY_DEFERRALS_PATH);
|
|
5264
|
+
if (result.spawnError !== void 0) return {
|
|
5265
|
+
status: "error",
|
|
5266
|
+
message: `git show could not be spawned: ${result.spawnError}`
|
|
5267
|
+
};
|
|
5268
|
+
if (result.code !== 0) {
|
|
5269
|
+
if (GIT_SHOW_ABSENT_PATTERNS.some((p) => p.test(result.stderr))) return {
|
|
5270
|
+
status: "ok",
|
|
5271
|
+
deferrals: []
|
|
5272
|
+
};
|
|
5273
|
+
return {
|
|
5274
|
+
status: "error",
|
|
5275
|
+
message: `git show ${ref}:${JOURNEY_DEFERRALS_PATH} failed (exit ${String(result.code)}): ${result.stderr.trim()}`
|
|
5276
|
+
};
|
|
5277
|
+
}
|
|
5278
|
+
const parsed = parseJourneyDeferrals(result.stdout);
|
|
5279
|
+
if (!parsed.ok) return {
|
|
5280
|
+
status: "invalid",
|
|
5281
|
+
issues: parsed.issues
|
|
5282
|
+
};
|
|
5283
|
+
return {
|
|
5284
|
+
status: "ok",
|
|
5285
|
+
deferrals: parsed.deferrals
|
|
5286
|
+
};
|
|
5287
|
+
}
|
|
5288
|
+
/**
|
|
5289
|
+
* Filesystem read for OPERATOR LINT ONLY (`substrate acceptance validate`).
|
|
5290
|
+
* Gate/judge code paths must use `loadJourneyRegistryFromTrustedTree`.
|
|
5291
|
+
*/
|
|
5292
|
+
async function loadJourneyRegistryFromFile(projectRoot) {
|
|
5293
|
+
const filePath = join$1(projectRoot, JOURNEY_REGISTRY_PATH);
|
|
5294
|
+
let content;
|
|
5295
|
+
try {
|
|
5296
|
+
content = await readFile$1(filePath, "utf-8");
|
|
5297
|
+
} catch (err) {
|
|
5298
|
+
const code = err.code;
|
|
5299
|
+
if (code === "ENOENT" || code === "ENOTDIR") return { status: "absent" };
|
|
5300
|
+
return {
|
|
5301
|
+
status: "error",
|
|
5302
|
+
message: `could not read ${filePath}: ${String(err)}`
|
|
5303
|
+
};
|
|
5304
|
+
}
|
|
5305
|
+
const parsed = parseJourneyRegistry(content);
|
|
5306
|
+
if (!parsed.ok) return {
|
|
5307
|
+
status: "invalid",
|
|
5308
|
+
issues: parsed.issues
|
|
5309
|
+
};
|
|
5310
|
+
return {
|
|
5311
|
+
status: "ok",
|
|
5312
|
+
registry: parsed.registry
|
|
5313
|
+
};
|
|
5314
|
+
}
|
|
5315
|
+
|
|
4966
5316
|
//#endregion
|
|
4967
5317
|
//#region packages/sdlc/dist/run-model/cli-flags.js
|
|
4968
5318
|
/**
|
|
@@ -5167,6 +5517,7 @@ const PerStoryStateSchema = z.object({
|
|
|
5167
5517
|
escalation_detail: z.string().optional(),
|
|
5168
5518
|
commit_sha: z.string().optional(),
|
|
5169
5519
|
baseline_sha: z.string().optional(),
|
|
5520
|
+
journeys: z.array(z.string()).optional(),
|
|
5170
5521
|
checkpoint_sha: z.string().optional(),
|
|
5171
5522
|
finalization: z.object({
|
|
5172
5523
|
mode: z.union([
|
|
@@ -5301,6 +5652,20 @@ const RunManifestSchema = z.object({
|
|
|
5301
5652
|
orchestrator_start_branch: z.string().optional(),
|
|
5302
5653
|
stopped_reason: z.string().optional(),
|
|
5303
5654
|
stopped_at: z.string().optional(),
|
|
5655
|
+
journeys: z.array(z.object({
|
|
5656
|
+
journeyId: z.string(),
|
|
5657
|
+
title: z.string(),
|
|
5658
|
+
criticality: z.enum(["critical", "standard"]),
|
|
5659
|
+
epic: z.number().optional(),
|
|
5660
|
+
state: z.enum([
|
|
5661
|
+
"walked-pass",
|
|
5662
|
+
"walked-fail",
|
|
5663
|
+
"deferred",
|
|
5664
|
+
"unclaimed",
|
|
5665
|
+
"unwalked"
|
|
5666
|
+
]),
|
|
5667
|
+
ownerStories: z.array(z.string())
|
|
5668
|
+
})).optional(),
|
|
5304
5669
|
generation: z.number().int().nonnegative(),
|
|
5305
5670
|
created_at: z.string(),
|
|
5306
5671
|
updated_at: z.string()
|
|
@@ -6381,5 +6746,5 @@ async function resolveRunManifest(dbRoot, runId) {
|
|
|
6381
6746
|
}
|
|
6382
6747
|
|
|
6383
6748
|
//#endregion
|
|
6384
|
-
export { FindingsInjector, RunManifest, RuntimeProbeListSchema, SupervisorLock, ZERO_FINDINGS_BY_AUTHOR, ZERO_FINDING_COUNTS, ZERO_PROBE_AUTHOR_METRICS, aggregateProbeAuthorMetrics, applyConfigToGraph, createDefaultVerificationPipeline, createGraphOrchestrator, createSdlcCodeReviewHandler, createSdlcCreateStoryHandler, createSdlcDevStoryHandler, createSdlcPhaseHandler, detectsEventDrivenAC, detectsStateIntegratingAC, extractTargetFilesFromStoryContent, parseRuntimeProbes, readCurrentRunId, renderFindings, resolveGraphPath, resolveMainRepoRoot, resolveRunManifest, rollupFindingCounts, rollupFindingsByAuthor, rollupProbeAuthorByClass, rollupProbeAuthorMetrics, runAcTraceabilityCheck, runStaleVerificationRecovery };
|
|
6385
|
-
//# sourceMappingURL=manifest-read-
|
|
6749
|
+
export { FindingsInjector, JOURNEY_DEFERRALS_PATH, JOURNEY_REGISTRY_PATH, RunManifest, RuntimeProbeListSchema, SupervisorLock, ZERO_FINDINGS_BY_AUTHOR, ZERO_FINDING_COUNTS, ZERO_PROBE_AUTHOR_METRICS, aggregateProbeAuthorMetrics, applyConfigToGraph, computeJourneyCoverage, createDefaultVerificationPipeline, createGraphOrchestrator, createSdlcCodeReviewHandler, createSdlcCreateStoryHandler, createSdlcDevStoryHandler, createSdlcPhaseHandler, detectsEventDrivenAC, detectsStateIntegratingAC, extractTargetFilesFromStoryContent, loadJourneyDeferralsFromTrustedTree, loadJourneyRegistryFromFile, loadJourneyRegistryFromTrustedTree, parseJourneyDeferrals, parseRuntimeProbes, parseStoryFrontmatter, readCurrentRunId, renderFindings, resolveGraphPath, resolveMainRepoRoot, resolveRunManifest, rollupFindingCounts, rollupFindingsByAuthor, rollupProbeAuthorByClass, rollupProbeAuthorMetrics, runAcTraceabilityCheck, runStaleVerificationRecovery, summarizeCoverage };
|
|
6750
|
+
//# sourceMappingURL=manifest-read-B3gE46DX.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "../../logger-KeHncl-f.js";
|
|
2
|
-
import "../../dist-
|
|
3
|
-
import "../../manifest-read-
|
|
4
|
-
import { runInteractivePrompt } from "../../interactive-prompt-
|
|
2
|
+
import "../../dist-CpnLJuVw.js";
|
|
3
|
+
import "../../manifest-read-B3gE46DX.js";
|
|
4
|
+
import { runInteractivePrompt } from "../../interactive-prompt-BM5RaXYG.js";
|
|
5
5
|
|
|
6
6
|
export { runInteractivePrompt };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ModelRoutingConfigSchema, ProviderPolicySchema, RoutingConfigError, RoutingRecommender, RoutingResolver, RoutingTelemetry, RoutingTokenAccumulator, RoutingTuner, TASK_TYPE_PHASE_MAP, getModelTier, loadModelRoutingConfig } from "./dist-
|
|
1
|
+
import { ModelRoutingConfigSchema, ProviderPolicySchema, RoutingConfigError, RoutingRecommender, RoutingResolver, RoutingTelemetry, RoutingTokenAccumulator, RoutingTuner, TASK_TYPE_PHASE_MAP, getModelTier, loadModelRoutingConfig } from "./dist-CpnLJuVw.js";
|
|
2
2
|
import "./routing-DFxoKHDt.js";
|
|
3
3
|
|
|
4
4
|
export { loadModelRoutingConfig };
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import "./health-
|
|
1
|
+
import "./health-Dnzblihr.js";
|
|
2
2
|
import "./logger-KeHncl-f.js";
|
|
3
3
|
import "./helpers-CElYrONe.js";
|
|
4
|
-
import "./dist-
|
|
5
|
-
import "./manifest-read-
|
|
6
|
-
import { normalizeGraphSummaryToStatus, registerRunCommand, resolveMaxReviewCycles, resolveProbeAuthorStateIntegrating, runRunAction, wireNdjsonEmitter } from "./run-
|
|
4
|
+
import "./dist-CpnLJuVw.js";
|
|
5
|
+
import "./manifest-read-B3gE46DX.js";
|
|
6
|
+
import { normalizeGraphSummaryToStatus, registerRunCommand, resolveMaxReviewCycles, resolveProbeAuthorStateIntegrating, runRunAction, wireNdjsonEmitter } from "./run-ZxFHQyE_.js";
|
|
7
7
|
import "./routing-DFxoKHDt.js";
|
|
8
8
|
import "./work-graph-repository-DZyJv5pV.js";
|
|
9
9
|
import "./decisions-CzSIEeGP.js";
|
|
10
10
|
import "./decision-router-BAPpON_C.js";
|
|
11
|
-
import "./interactive-prompt-
|
|
11
|
+
import "./interactive-prompt-BM5RaXYG.js";
|
|
12
12
|
import "./recovery-engine-BKGBeBnW.js";
|
|
13
13
|
|
|
14
14
|
export { runRunAction };
|