@transitrix/diagrams 1.13.3 → 1.14.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/activities/action-fields.d.ts +6 -0
- package/dist/activities/action-fields.js +34 -0
- package/dist/activities/validate.d.ts +3 -1
- package/dist/activities/validate.js +36 -34
- package/dist/applications/validate.js +27 -26
- package/dist/capability-map/validate.d.ts +4 -1
- package/dist/capability-map/validate.js +32 -30
- package/dist/codex/validate.js +3 -3
- package/dist/compliance/canon-catalog.js +1 -1
- package/dist/compliance/classify.d.ts +4 -1
- package/dist/compliance/classify.js +21 -1
- package/dist/compliance/coverage-metric.js +3 -3
- package/dist/compliance/impact.js +4 -4
- package/dist/compliance/index.d.ts +3 -0
- package/dist/compliance/index.js +1 -0
- package/dist/compliance/requirement-chain.d.ts +111 -0
- package/dist/compliance/requirement-chain.js +501 -0
- package/dist/compliance/reverse-index.js +4 -0
- package/dist/compliance/types.d.ts +20 -0
- package/dist/fgca/parse-canonical.d.ts +0 -25
- package/dist/fgca/parse-canonical.js +16 -26
- package/dist/fgca/projection-origin.d.ts +2 -0
- package/dist/fgca/projection-origin.js +2 -0
- package/dist/fgca/resolver.d.ts +0 -8
- package/dist/fgca/resolver.js +2 -0
- package/dist/products/validate.js +30 -25
- package/dist/repo-validate/check-strategy-chain.d.ts +8 -2
- package/dist/repo-validate/check-strategy-chain.js +64 -64
- package/dist/repo-validate/types.d.ts +2 -0
- package/dist/repo-validate/validate-repo.js +2 -0
- package/dist/risk/index.d.ts +1 -1
- package/dist/risk/types.d.ts +8 -1
- package/dist/risk/validate.js +19 -4
- package/dist/scenarios/validate.js +4 -0
- package/dist/schema-finding.d.ts +3 -0
- package/dist/schema-finding.js +6 -0
- package/dist/webview/entry.js +7 -2
- package/dist/webview/render-goals.js +2 -1
- package/package.json +1 -1
- package/src/activities/action-fields.ts +31 -0
- package/src/activities/validate.ts +37 -34
- package/src/applications/validate.ts +27 -26
- package/src/capability-map/validate.ts +33 -29
- package/src/codex/validate.ts +3 -3
- package/src/compliance/canon-catalog.ts +1 -1
- package/src/compliance/classify.ts +24 -1
- package/src/compliance/coverage-metric.ts +3 -3
- package/src/compliance/impact.ts +4 -4
- package/src/compliance/index.ts +3 -0
- package/src/compliance/requirement-chain.ts +430 -0
- package/src/compliance/reverse-index.ts +3 -0
- package/src/compliance/types.ts +21 -0
- package/src/fgca/parse-canonical.ts +14 -1
- package/src/fgca/projection-origin.ts +2 -0
- package/src/fgca/resolver.ts +2 -0
- package/src/products/validate.ts +31 -25
- package/src/repo-validate/check-strategy-chain.ts +69 -64
- package/src/repo-validate/types.ts +2 -0
- package/src/repo-validate/validate-repo.ts +2 -0
- package/src/risk/index.ts +1 -1
- package/src/risk/types.ts +9 -1
- package/src/risk/validate.ts +19 -5
- package/src/scenarios/validate.ts +5 -0
- package/src/schema-finding.ts +8 -0
- package/src/webview/entry.ts +6 -2
- package/src/webview/render-goals.ts +2 -1
- package/src/webview/styles.css +8 -0
|
@@ -16,14 +16,14 @@ export function collectCoverageViewResolutionFindings(config, catalog, complianc
|
|
|
16
16
|
const t = catalog.typeOf(id);
|
|
17
17
|
if (t === undefined) {
|
|
18
18
|
findings.push({
|
|
19
|
-
code: 'COVMET-
|
|
19
|
+
code: 'COVMET-003',
|
|
20
20
|
severity: 'error',
|
|
21
21
|
message: `subjects.products: "${id}" does not resolve to an admitted artefact.`,
|
|
22
22
|
});
|
|
23
23
|
}
|
|
24
24
|
else if (t !== 'PRODUCT') {
|
|
25
25
|
findings.push({
|
|
26
|
-
code: 'COVMET-
|
|
26
|
+
code: 'COVMET-003',
|
|
27
27
|
severity: 'error',
|
|
28
28
|
message: `subjects.products: "${id}" resolves to ${t}, not PRODUCT.`,
|
|
29
29
|
});
|
|
@@ -32,7 +32,7 @@ export function collectCoverageViewResolutionFindings(config, catalog, complianc
|
|
|
32
32
|
for (const id of config.regimes?.include ?? []) {
|
|
33
33
|
if (!codexIds.has(id)) {
|
|
34
34
|
findings.push({
|
|
35
|
-
code: 'COVMET-
|
|
35
|
+
code: 'COVMET-003',
|
|
36
36
|
severity: 'error',
|
|
37
37
|
message: `regimes.include: "${id}" does not resolve to an admitted codex artefact.`,
|
|
38
38
|
});
|
|
@@ -26,14 +26,14 @@ export function collectImpactViewResolutionFindings(config, catalog, complianceC
|
|
|
26
26
|
const t = catalog.typeOf(id);
|
|
27
27
|
if (t === undefined) {
|
|
28
28
|
findings.push({
|
|
29
|
-
code: 'COMPIMP-
|
|
29
|
+
code: 'COMPIMP-003',
|
|
30
30
|
severity: 'error',
|
|
31
31
|
message: `${path}: "${id}" does not resolve to an admitted artefact.`,
|
|
32
32
|
});
|
|
33
33
|
}
|
|
34
34
|
else if (t !== expectedType) {
|
|
35
35
|
findings.push({
|
|
36
|
-
code: 'COMPIMP-
|
|
36
|
+
code: 'COMPIMP-003',
|
|
37
37
|
severity: 'error',
|
|
38
38
|
message: `${path}: "${id}" resolves to ${t}, not ${expectedType}.`,
|
|
39
39
|
});
|
|
@@ -44,7 +44,7 @@ export function collectImpactViewResolutionFindings(config, catalog, complianceC
|
|
|
44
44
|
const t = catalog.typeOf(id);
|
|
45
45
|
if (t === undefined || t !== 'REQUIREMENT') {
|
|
46
46
|
findings.push({
|
|
47
|
-
code: 'COMPIMP-
|
|
47
|
+
code: 'COMPIMP-003',
|
|
48
48
|
severity: 'error',
|
|
49
49
|
message: `obligations.include: "${id}" does not resolve to an admitted REQUIREMENT.`,
|
|
50
50
|
});
|
|
@@ -53,7 +53,7 @@ export function collectImpactViewResolutionFindings(config, catalog, complianceC
|
|
|
53
53
|
for (const id of config.obligations.filter?.derived_from_codex ?? []) {
|
|
54
54
|
if (!codexIds.has(id)) {
|
|
55
55
|
findings.push({
|
|
56
|
-
code: 'COMPIMP-
|
|
56
|
+
code: 'COMPIMP-003',
|
|
57
57
|
severity: 'error',
|
|
58
58
|
message: `obligations.filter.derived_from_codex: "${id}" does not resolve to an admitted codex artefact.`,
|
|
59
59
|
});
|
|
@@ -19,3 +19,6 @@ export { assertionToScoringElement, complianceConfidenceHeader, requirementToSco
|
|
|
19
19
|
export { parseCoverageMetricConfig, buildCoverageMatrix, collectCoverageViewResolutionFindings, } from './coverage-metric.js';
|
|
20
20
|
export type { CoverageMetricConfig, CoverageMetricRegimes, CoverageMetricRegimesFilter, CoverageMetricSubjects, CoverageMetricThresholds, CoverageMatrix, CoverageRow, CoverageViewFinding, ParseCoverageMetricResult, RagStatus, } from './coverage-metric.js';
|
|
21
21
|
export type { ComplianceIndex, ComplianceIndexInput, DeadlineStatus, IndexRequirement, IndexAssertion, IndexVerification, IndexNeed, IndexValidation, LawTree, LawTreeRequirement, ProductView, ProductRequirementStatus, ObjectDetailDef, ObjectDetailInput, RequirementTrace, TraceAssertionRow, TraceVerificationRow, TraceElementCatalog, TraceElementRef, TraceSourceRef, } from './types.js';
|
|
22
|
+
export { buildRequirementChain, requirementReleaseCounts, selectRequirementChain, RequirementChainSnapshot, CHAIN_STAGES, chainDate } from './requirement-chain.js';
|
|
23
|
+
export type { ChainInput, ChainScope, ChainSet, RequirementChainNode, RequirementChainEdge, RequirementChainProjection } from './requirement-chain.js';
|
|
24
|
+
export type { ChainRecord, ChainFinding } from './types.js';
|
package/dist/compliance/index.js
CHANGED
|
@@ -11,3 +11,4 @@ export { renderComplianceHtml, renderImpactMatrixHtml } from './html.js';
|
|
|
11
11
|
export { buildImpactMatrix, renderImpactMarkdown, parseImpactViewConfig, collectImpactViewResolutionFindings, COMPLIANCE_IMPACT_DEFAULTS, extractObjectDetails, extractProcessFlowTasks, mergeStageTaskDetails, computeDeadlineStatus } from './impact.js';
|
|
12
12
|
export { assertionToScoringElement, complianceConfidenceHeader, requirementToScoringElement, scoreComplianceView, } from './confidence.js';
|
|
13
13
|
export { parseCoverageMetricConfig, buildCoverageMatrix, collectCoverageViewResolutionFindings, } from './coverage-metric.js';
|
|
14
|
+
export { buildRequirementChain, requirementReleaseCounts, selectRequirementChain, RequirementChainSnapshot, CHAIN_STAGES, chainDate } from './requirement-chain.js';
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import type { ChainRecord, ChainFinding, ComplianceIndex } from './types.js';
|
|
2
|
+
export declare const CHAIN_STAGES: readonly ["Source document", "Driver", "Need", "Stakeholder requirement", "System requirement", "Software requirement", "Unclassified requirement", "Verification definition", "Result"];
|
|
3
|
+
export interface ChainScope {
|
|
4
|
+
catalogue: string;
|
|
5
|
+
product?: string;
|
|
6
|
+
release?: string;
|
|
7
|
+
project?: string;
|
|
8
|
+
}
|
|
9
|
+
export interface ChainInput {
|
|
10
|
+
index: ComplianceIndex;
|
|
11
|
+
scope: ChainScope;
|
|
12
|
+
asAt: string;
|
|
13
|
+
snapshotId: string;
|
|
14
|
+
sourceRevision?: string;
|
|
15
|
+
complete: boolean;
|
|
16
|
+
}
|
|
17
|
+
export interface ChainSet {
|
|
18
|
+
ids: string[];
|
|
19
|
+
completeness: 'complete' | 'incomplete';
|
|
20
|
+
total: number | null;
|
|
21
|
+
}
|
|
22
|
+
export interface RequirementChainNode {
|
|
23
|
+
id: string;
|
|
24
|
+
recordId: string;
|
|
25
|
+
name: string;
|
|
26
|
+
stage: number;
|
|
27
|
+
sourcePath: string;
|
|
28
|
+
context: string[];
|
|
29
|
+
raw: Record<string, unknown>;
|
|
30
|
+
}
|
|
31
|
+
export interface RequirementChainEdge {
|
|
32
|
+
id: string;
|
|
33
|
+
kind: string;
|
|
34
|
+
storedFrom: string;
|
|
35
|
+
storedTo: string;
|
|
36
|
+
from: string;
|
|
37
|
+
to: string;
|
|
38
|
+
identities: string[];
|
|
39
|
+
trace: boolean;
|
|
40
|
+
valid: boolean;
|
|
41
|
+
}
|
|
42
|
+
export interface ChainAssignment {
|
|
43
|
+
requirement: string;
|
|
44
|
+
nearest: string;
|
|
45
|
+
depth: number;
|
|
46
|
+
relations: string[];
|
|
47
|
+
}
|
|
48
|
+
export interface RequirementChainProjection {
|
|
49
|
+
contract: 'requirement-chain/0.2';
|
|
50
|
+
contractRevision: string;
|
|
51
|
+
asAt: string;
|
|
52
|
+
snapshotId: string;
|
|
53
|
+
sourceRevision?: string;
|
|
54
|
+
scope: ChainScope;
|
|
55
|
+
completeness: 'complete' | 'incomplete';
|
|
56
|
+
scopeFindings: string[];
|
|
57
|
+
populations: {
|
|
58
|
+
product: ChainSet;
|
|
59
|
+
release: ChainSet;
|
|
60
|
+
selected: ChainSet;
|
|
61
|
+
inactive: ChainSet;
|
|
62
|
+
unresolved: ChainSet;
|
|
63
|
+
};
|
|
64
|
+
assignments: {
|
|
65
|
+
here: ChainSet;
|
|
66
|
+
otherReleaseOnly: ChainSet;
|
|
67
|
+
unassigned: ChainSet;
|
|
68
|
+
invalid: ChainSet;
|
|
69
|
+
provenance: ChainAssignment[];
|
|
70
|
+
};
|
|
71
|
+
stages: ChainSet[];
|
|
72
|
+
metrics: {
|
|
73
|
+
broken: ChainSet;
|
|
74
|
+
noSource: ChainSet;
|
|
75
|
+
noDefinition: ChainSet;
|
|
76
|
+
noResult: ChainSet;
|
|
77
|
+
failed: ChainSet;
|
|
78
|
+
unassigned: ChainSet;
|
|
79
|
+
};
|
|
80
|
+
records: ChainRecord[];
|
|
81
|
+
nodes: RequirementChainNode[];
|
|
82
|
+
edges: RequirementChainEdge[];
|
|
83
|
+
findings: ChainFinding[];
|
|
84
|
+
defectiveReferences: ChainSet;
|
|
85
|
+
selectedReferences: ChainSet;
|
|
86
|
+
unattributableFindings: ChainSet;
|
|
87
|
+
affectedRequirements: Record<string, string[]>;
|
|
88
|
+
definitions: Record<string, string[]>;
|
|
89
|
+
executions: Record<string, string[]>;
|
|
90
|
+
}
|
|
91
|
+
export declare function chainDate(v: unknown): v is string;
|
|
92
|
+
/** Pure, lossless release projection; no legacy coverage verdict is reinterpreted. */
|
|
93
|
+
export declare function buildRequirementChain(input: ChainInput): RequirementChainProjection;
|
|
94
|
+
/** Both is two independent walks, never an expansion from the union frontier. */
|
|
95
|
+
export declare function selectRequirementChain(p: RequirementChainProjection, focus?: string, direction?: 'upstream' | 'downstream' | 'both'): {
|
|
96
|
+
nodes: RequirementChainNode[];
|
|
97
|
+
edges: RequirementChainEdge[];
|
|
98
|
+
};
|
|
99
|
+
/** Count/list contract for the release report, derived solely from the shared snapshot. */
|
|
100
|
+
export declare function requirementReleaseCounts(p: RequirementChainProjection): Record<string, {
|
|
101
|
+
label: string;
|
|
102
|
+
unit: "requirements" | "references" | "findings" | "source documents" | "drivers" | "needs" | "definition parts" | "result parts";
|
|
103
|
+
set: ChainSet;
|
|
104
|
+
}>;
|
|
105
|
+
/** Monotonic refresh gate shared by reports; late successes and failures cannot replace newer data. */
|
|
106
|
+
export declare class RequirementChainSnapshot {
|
|
107
|
+
private generation;
|
|
108
|
+
current?: RequirementChainProjection;
|
|
109
|
+
stale: boolean;
|
|
110
|
+
refresh(load: () => Promise<ChainInput>): Promise<boolean>;
|
|
111
|
+
}
|