@harness-engineering/core 0.10.1 → 0.11.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/architecture/matchers.d.mts +2 -0
- package/dist/architecture/matchers.d.ts +2 -0
- package/dist/architecture/matchers.js +1784 -0
- package/dist/architecture/matchers.mjs +10 -0
- package/dist/chunk-ZHGBWFYD.mjs +1827 -0
- package/dist/index.d.mts +892 -23
- package/dist/index.d.ts +892 -23
- package/dist/index.js +2241 -320
- package/dist/index.mjs +1161 -1026
- package/dist/matchers-D20x48U9.d.mts +353 -0
- package/dist/matchers-D20x48U9.d.ts +353 -0
- package/package.json +11 -3
package/dist/index.d.mts
CHANGED
|
@@ -1,41 +1,94 @@
|
|
|
1
1
|
import { Result, WorkflowStep, WorkflowStepResult, Workflow, WorkflowResult, SkillLifecycleHooks, SkillContext, SkillResult, TurnContext, CICheckName, CIFailOnSeverity, CICheckReport, Roadmap, FeatureStatus } from '@harness-engineering/types';
|
|
2
2
|
export * from '@harness-engineering/types';
|
|
3
3
|
import { z } from 'zod';
|
|
4
|
+
import { C as Collector, A as ArchConfig, a as ConstraintRule, M as MetricResult, b as ArchMetricCategory, c as ArchBaseline, d as ArchDiffResult, T as ThresholdConfig } from './matchers-D20x48U9.mjs';
|
|
5
|
+
export { e as ArchBaselineSchema, f as ArchConfigSchema, g as ArchDiffResultSchema, h as ArchHandle, i as ArchMetricCategorySchema, j as ArchitectureOptions, k as CategoryBaseline, l as CategoryBaselineSchema, m as CategoryRegression, n as CategoryRegressionSchema, o as ConstraintRuleSchema, p as MetricResultSchema, q as ThresholdConfigSchema, V as Violation, r as ViolationSchema, s as archMatchers, t as archModule, u as architecture } from './matchers-D20x48U9.mjs';
|
|
4
6
|
|
|
7
|
+
/**
|
|
8
|
+
* Represents an error code for identifying specific error types.
|
|
9
|
+
*/
|
|
5
10
|
type ErrorCode = string;
|
|
11
|
+
/**
|
|
12
|
+
* Base interface for all Harness Engineering errors.
|
|
13
|
+
* Provides a standardized structure for error reporting and suggestions.
|
|
14
|
+
*/
|
|
6
15
|
interface BaseError {
|
|
16
|
+
/** A unique code identifying the type of error. */
|
|
7
17
|
code: ErrorCode;
|
|
18
|
+
/** A human-readable message describing the error. */
|
|
8
19
|
message: string;
|
|
20
|
+
/** Additional structured data providing context about the error. */
|
|
9
21
|
details: Record<string, unknown>;
|
|
22
|
+
/** A list of suggested actions to resolve the error. */
|
|
10
23
|
suggestions: string[];
|
|
11
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* Error type for validation failures.
|
|
27
|
+
*/
|
|
12
28
|
interface ValidationError extends BaseError {
|
|
29
|
+
/** Validation-specific error codes. */
|
|
13
30
|
code: 'INVALID_TYPE' | 'MISSING_FIELD' | 'VALIDATION_FAILED' | 'PARSE_ERROR';
|
|
14
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* Error type for context-related issues.
|
|
34
|
+
*/
|
|
15
35
|
interface ContextError extends BaseError {
|
|
36
|
+
/** Context-specific error codes. */
|
|
16
37
|
code: 'PARSE_ERROR' | 'SCHEMA_VIOLATION' | 'MISSING_SECTION' | 'BROKEN_LINK';
|
|
17
38
|
}
|
|
39
|
+
/**
|
|
40
|
+
* Error type for architectural constraint violations.
|
|
41
|
+
*/
|
|
18
42
|
interface ConstraintError extends BaseError {
|
|
43
|
+
/** Constraint-specific error codes. */
|
|
19
44
|
code: 'WRONG_LAYER' | 'CIRCULAR_DEP' | 'FORBIDDEN_IMPORT' | 'BOUNDARY_ERROR' | 'PARSER_UNAVAILABLE';
|
|
20
45
|
}
|
|
46
|
+
/**
|
|
47
|
+
* Error type for entropy and drift-related issues.
|
|
48
|
+
*/
|
|
21
49
|
interface EntropyError extends BaseError {
|
|
50
|
+
/** Entropy-specific error codes. */
|
|
22
51
|
code: 'SNAPSHOT_BUILD_FAILED' | 'PARSE_ERROR' | 'ENTRY_POINT_NOT_FOUND' | 'INVALID_CONFIG' | 'CONFIG_VALIDATION_ERROR' | 'FIX_FAILED' | 'BACKUP_FAILED';
|
|
52
|
+
/** Entropy-specific error details. */
|
|
23
53
|
details: {
|
|
54
|
+
/** Path to the file where the error occurred. */
|
|
24
55
|
file?: string;
|
|
56
|
+
/** Reason for the error. */
|
|
25
57
|
reason?: string;
|
|
58
|
+
/** List of issues detected. */
|
|
26
59
|
issues?: unknown[];
|
|
60
|
+
/** The original Error object, if any. */
|
|
27
61
|
originalError?: Error;
|
|
28
62
|
};
|
|
29
63
|
}
|
|
64
|
+
/**
|
|
65
|
+
* Error type for agent feedback and review issues.
|
|
66
|
+
*/
|
|
30
67
|
interface FeedbackError$1 extends BaseError {
|
|
68
|
+
/** Feedback-specific error codes. */
|
|
31
69
|
code: 'AGENT_SPAWN_ERROR' | 'AGENT_TIMEOUT' | 'TELEMETRY_ERROR' | 'TELEMETRY_UNAVAILABLE' | 'REVIEW_ERROR' | 'DIFF_PARSE_ERROR' | 'SINK_ERROR';
|
|
70
|
+
/** Feedback-specific error details. */
|
|
32
71
|
details: {
|
|
72
|
+
/** ID of the agent involved. */
|
|
33
73
|
agentId?: string;
|
|
74
|
+
/** Name of the service where the error occurred. */
|
|
34
75
|
service?: string;
|
|
76
|
+
/** Reason for the error. */
|
|
35
77
|
reason?: string;
|
|
78
|
+
/** The original Error object, if any. */
|
|
36
79
|
originalError?: Error;
|
|
37
80
|
};
|
|
38
81
|
}
|
|
82
|
+
/**
|
|
83
|
+
* Creates a standardized error object.
|
|
84
|
+
*
|
|
85
|
+
* @template T - The specific error type to create.
|
|
86
|
+
* @param code - The error code identifying the type of error.
|
|
87
|
+
* @param message - A human-readable message describing the error.
|
|
88
|
+
* @param details - Additional structured data providing context (default: empty record).
|
|
89
|
+
* @param suggestions - A list of suggested actions to resolve the error (default: empty array).
|
|
90
|
+
* @returns A new error object of the specified type.
|
|
91
|
+
*/
|
|
39
92
|
declare function createError<T extends BaseError>(code: T['code'], message: string, details?: Record<string, unknown>, suggestions?: string[]): T;
|
|
40
93
|
|
|
41
94
|
interface Convention {
|
|
@@ -444,6 +497,587 @@ declare function createBoundaryValidator<T>(schema: z.ZodSchema<T>, name: string
|
|
|
444
497
|
*/
|
|
445
498
|
declare function validateBoundaries(boundaries: BoundaryDefinition[], data: Map<string, unknown>): Result<BoundaryValidation, ConstraintError>;
|
|
446
499
|
|
|
500
|
+
declare const ManifestSchema: z.ZodObject<{
|
|
501
|
+
name: z.ZodString;
|
|
502
|
+
version: z.ZodString;
|
|
503
|
+
description: z.ZodOptional<z.ZodString>;
|
|
504
|
+
include: z.ZodArray<z.ZodString, "many">;
|
|
505
|
+
minHarnessVersion: z.ZodOptional<z.ZodString>;
|
|
506
|
+
keywords: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString, "many">>>;
|
|
507
|
+
layers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>;
|
|
508
|
+
boundaries: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
509
|
+
name: z.ZodString;
|
|
510
|
+
layer: z.ZodString;
|
|
511
|
+
direction: z.ZodEnum<["input", "output"]>;
|
|
512
|
+
schema: z.ZodString;
|
|
513
|
+
}, "strip", z.ZodTypeAny, {
|
|
514
|
+
name: string;
|
|
515
|
+
layer: string;
|
|
516
|
+
direction: "input" | "output";
|
|
517
|
+
schema: string;
|
|
518
|
+
}, {
|
|
519
|
+
name: string;
|
|
520
|
+
layer: string;
|
|
521
|
+
direction: "input" | "output";
|
|
522
|
+
schema: string;
|
|
523
|
+
}>, "many">>;
|
|
524
|
+
}, "strip", z.ZodTypeAny, {
|
|
525
|
+
name: string;
|
|
526
|
+
version: string;
|
|
527
|
+
include: string[];
|
|
528
|
+
keywords: string[];
|
|
529
|
+
layers?: Record<string, string[]> | undefined;
|
|
530
|
+
description?: string | undefined;
|
|
531
|
+
minHarnessVersion?: string | undefined;
|
|
532
|
+
boundaries?: {
|
|
533
|
+
name: string;
|
|
534
|
+
layer: string;
|
|
535
|
+
direction: "input" | "output";
|
|
536
|
+
schema: string;
|
|
537
|
+
}[] | undefined;
|
|
538
|
+
}, {
|
|
539
|
+
name: string;
|
|
540
|
+
version: string;
|
|
541
|
+
include: string[];
|
|
542
|
+
layers?: Record<string, string[]> | undefined;
|
|
543
|
+
description?: string | undefined;
|
|
544
|
+
minHarnessVersion?: string | undefined;
|
|
545
|
+
keywords?: string[] | undefined;
|
|
546
|
+
boundaries?: {
|
|
547
|
+
name: string;
|
|
548
|
+
layer: string;
|
|
549
|
+
direction: "input" | "output";
|
|
550
|
+
schema: string;
|
|
551
|
+
}[] | undefined;
|
|
552
|
+
}>;
|
|
553
|
+
type Manifest = z.infer<typeof ManifestSchema>;
|
|
554
|
+
declare const BundleConstraintsSchema: z.ZodObject<{
|
|
555
|
+
layers: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
556
|
+
name: z.ZodString;
|
|
557
|
+
pattern: z.ZodString;
|
|
558
|
+
allowedDependencies: z.ZodArray<z.ZodString, "many">;
|
|
559
|
+
}, "strip", z.ZodTypeAny, {
|
|
560
|
+
name: string;
|
|
561
|
+
pattern: string;
|
|
562
|
+
allowedDependencies: string[];
|
|
563
|
+
}, {
|
|
564
|
+
name: string;
|
|
565
|
+
pattern: string;
|
|
566
|
+
allowedDependencies: string[];
|
|
567
|
+
}>, "many">>;
|
|
568
|
+
forbiddenImports: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
569
|
+
from: z.ZodString;
|
|
570
|
+
disallow: z.ZodArray<z.ZodString, "many">;
|
|
571
|
+
message: z.ZodOptional<z.ZodString>;
|
|
572
|
+
}, "strip", z.ZodTypeAny, {
|
|
573
|
+
from: string;
|
|
574
|
+
disallow: string[];
|
|
575
|
+
message?: string | undefined;
|
|
576
|
+
}, {
|
|
577
|
+
from: string;
|
|
578
|
+
disallow: string[];
|
|
579
|
+
message?: string | undefined;
|
|
580
|
+
}>, "many">>;
|
|
581
|
+
boundaries: z.ZodOptional<z.ZodObject<{
|
|
582
|
+
requireSchema: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
583
|
+
}, "strip", z.ZodTypeAny, {
|
|
584
|
+
requireSchema?: string[] | undefined;
|
|
585
|
+
}, {
|
|
586
|
+
requireSchema?: string[] | undefined;
|
|
587
|
+
}>>;
|
|
588
|
+
architecture: z.ZodOptional<z.ZodObject<{
|
|
589
|
+
thresholds: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
590
|
+
modules: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
591
|
+
}, "strip", z.ZodTypeAny, {
|
|
592
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
593
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
594
|
+
}, {
|
|
595
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
596
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
597
|
+
}>>;
|
|
598
|
+
security: z.ZodOptional<z.ZodObject<{
|
|
599
|
+
rules: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
600
|
+
}, "strip", z.ZodTypeAny, {
|
|
601
|
+
rules?: Record<string, string> | undefined;
|
|
602
|
+
}, {
|
|
603
|
+
rules?: Record<string, string> | undefined;
|
|
604
|
+
}>>;
|
|
605
|
+
}, "strip", z.ZodTypeAny, {
|
|
606
|
+
architecture?: {
|
|
607
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
608
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
609
|
+
} | undefined;
|
|
610
|
+
layers?: {
|
|
611
|
+
name: string;
|
|
612
|
+
pattern: string;
|
|
613
|
+
allowedDependencies: string[];
|
|
614
|
+
}[] | undefined;
|
|
615
|
+
boundaries?: {
|
|
616
|
+
requireSchema?: string[] | undefined;
|
|
617
|
+
} | undefined;
|
|
618
|
+
forbiddenImports?: {
|
|
619
|
+
from: string;
|
|
620
|
+
disallow: string[];
|
|
621
|
+
message?: string | undefined;
|
|
622
|
+
}[] | undefined;
|
|
623
|
+
security?: {
|
|
624
|
+
rules?: Record<string, string> | undefined;
|
|
625
|
+
} | undefined;
|
|
626
|
+
}, {
|
|
627
|
+
architecture?: {
|
|
628
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
629
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
630
|
+
} | undefined;
|
|
631
|
+
layers?: {
|
|
632
|
+
name: string;
|
|
633
|
+
pattern: string;
|
|
634
|
+
allowedDependencies: string[];
|
|
635
|
+
}[] | undefined;
|
|
636
|
+
boundaries?: {
|
|
637
|
+
requireSchema?: string[] | undefined;
|
|
638
|
+
} | undefined;
|
|
639
|
+
forbiddenImports?: {
|
|
640
|
+
from: string;
|
|
641
|
+
disallow: string[];
|
|
642
|
+
message?: string | undefined;
|
|
643
|
+
}[] | undefined;
|
|
644
|
+
security?: {
|
|
645
|
+
rules?: Record<string, string> | undefined;
|
|
646
|
+
} | undefined;
|
|
647
|
+
}>;
|
|
648
|
+
declare const BundleSchema: z.ZodObject<{
|
|
649
|
+
name: z.ZodString;
|
|
650
|
+
version: z.ZodString;
|
|
651
|
+
description: z.ZodOptional<z.ZodString>;
|
|
652
|
+
minHarnessVersion: z.ZodOptional<z.ZodString>;
|
|
653
|
+
manifest: z.ZodObject<{
|
|
654
|
+
name: z.ZodString;
|
|
655
|
+
version: z.ZodString;
|
|
656
|
+
description: z.ZodOptional<z.ZodString>;
|
|
657
|
+
include: z.ZodArray<z.ZodString, "many">;
|
|
658
|
+
minHarnessVersion: z.ZodOptional<z.ZodString>;
|
|
659
|
+
keywords: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString, "many">>>;
|
|
660
|
+
layers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>;
|
|
661
|
+
boundaries: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
662
|
+
name: z.ZodString;
|
|
663
|
+
layer: z.ZodString;
|
|
664
|
+
direction: z.ZodEnum<["input", "output"]>;
|
|
665
|
+
schema: z.ZodString;
|
|
666
|
+
}, "strip", z.ZodTypeAny, {
|
|
667
|
+
name: string;
|
|
668
|
+
layer: string;
|
|
669
|
+
direction: "input" | "output";
|
|
670
|
+
schema: string;
|
|
671
|
+
}, {
|
|
672
|
+
name: string;
|
|
673
|
+
layer: string;
|
|
674
|
+
direction: "input" | "output";
|
|
675
|
+
schema: string;
|
|
676
|
+
}>, "many">>;
|
|
677
|
+
}, "strip", z.ZodTypeAny, {
|
|
678
|
+
name: string;
|
|
679
|
+
version: string;
|
|
680
|
+
include: string[];
|
|
681
|
+
keywords: string[];
|
|
682
|
+
layers?: Record<string, string[]> | undefined;
|
|
683
|
+
description?: string | undefined;
|
|
684
|
+
minHarnessVersion?: string | undefined;
|
|
685
|
+
boundaries?: {
|
|
686
|
+
name: string;
|
|
687
|
+
layer: string;
|
|
688
|
+
direction: "input" | "output";
|
|
689
|
+
schema: string;
|
|
690
|
+
}[] | undefined;
|
|
691
|
+
}, {
|
|
692
|
+
name: string;
|
|
693
|
+
version: string;
|
|
694
|
+
include: string[];
|
|
695
|
+
layers?: Record<string, string[]> | undefined;
|
|
696
|
+
description?: string | undefined;
|
|
697
|
+
minHarnessVersion?: string | undefined;
|
|
698
|
+
keywords?: string[] | undefined;
|
|
699
|
+
boundaries?: {
|
|
700
|
+
name: string;
|
|
701
|
+
layer: string;
|
|
702
|
+
direction: "input" | "output";
|
|
703
|
+
schema: string;
|
|
704
|
+
}[] | undefined;
|
|
705
|
+
}>;
|
|
706
|
+
constraints: z.ZodObject<{
|
|
707
|
+
layers: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
708
|
+
name: z.ZodString;
|
|
709
|
+
pattern: z.ZodString;
|
|
710
|
+
allowedDependencies: z.ZodArray<z.ZodString, "many">;
|
|
711
|
+
}, "strip", z.ZodTypeAny, {
|
|
712
|
+
name: string;
|
|
713
|
+
pattern: string;
|
|
714
|
+
allowedDependencies: string[];
|
|
715
|
+
}, {
|
|
716
|
+
name: string;
|
|
717
|
+
pattern: string;
|
|
718
|
+
allowedDependencies: string[];
|
|
719
|
+
}>, "many">>;
|
|
720
|
+
forbiddenImports: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
721
|
+
from: z.ZodString;
|
|
722
|
+
disallow: z.ZodArray<z.ZodString, "many">;
|
|
723
|
+
message: z.ZodOptional<z.ZodString>;
|
|
724
|
+
}, "strip", z.ZodTypeAny, {
|
|
725
|
+
from: string;
|
|
726
|
+
disallow: string[];
|
|
727
|
+
message?: string | undefined;
|
|
728
|
+
}, {
|
|
729
|
+
from: string;
|
|
730
|
+
disallow: string[];
|
|
731
|
+
message?: string | undefined;
|
|
732
|
+
}>, "many">>;
|
|
733
|
+
boundaries: z.ZodOptional<z.ZodObject<{
|
|
734
|
+
requireSchema: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
735
|
+
}, "strip", z.ZodTypeAny, {
|
|
736
|
+
requireSchema?: string[] | undefined;
|
|
737
|
+
}, {
|
|
738
|
+
requireSchema?: string[] | undefined;
|
|
739
|
+
}>>;
|
|
740
|
+
architecture: z.ZodOptional<z.ZodObject<{
|
|
741
|
+
thresholds: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
742
|
+
modules: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
743
|
+
}, "strip", z.ZodTypeAny, {
|
|
744
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
745
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
746
|
+
}, {
|
|
747
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
748
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
749
|
+
}>>;
|
|
750
|
+
security: z.ZodOptional<z.ZodObject<{
|
|
751
|
+
rules: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
752
|
+
}, "strip", z.ZodTypeAny, {
|
|
753
|
+
rules?: Record<string, string> | undefined;
|
|
754
|
+
}, {
|
|
755
|
+
rules?: Record<string, string> | undefined;
|
|
756
|
+
}>>;
|
|
757
|
+
}, "strip", z.ZodTypeAny, {
|
|
758
|
+
architecture?: {
|
|
759
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
760
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
761
|
+
} | undefined;
|
|
762
|
+
layers?: {
|
|
763
|
+
name: string;
|
|
764
|
+
pattern: string;
|
|
765
|
+
allowedDependencies: string[];
|
|
766
|
+
}[] | undefined;
|
|
767
|
+
boundaries?: {
|
|
768
|
+
requireSchema?: string[] | undefined;
|
|
769
|
+
} | undefined;
|
|
770
|
+
forbiddenImports?: {
|
|
771
|
+
from: string;
|
|
772
|
+
disallow: string[];
|
|
773
|
+
message?: string | undefined;
|
|
774
|
+
}[] | undefined;
|
|
775
|
+
security?: {
|
|
776
|
+
rules?: Record<string, string> | undefined;
|
|
777
|
+
} | undefined;
|
|
778
|
+
}, {
|
|
779
|
+
architecture?: {
|
|
780
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
781
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
782
|
+
} | undefined;
|
|
783
|
+
layers?: {
|
|
784
|
+
name: string;
|
|
785
|
+
pattern: string;
|
|
786
|
+
allowedDependencies: string[];
|
|
787
|
+
}[] | undefined;
|
|
788
|
+
boundaries?: {
|
|
789
|
+
requireSchema?: string[] | undefined;
|
|
790
|
+
} | undefined;
|
|
791
|
+
forbiddenImports?: {
|
|
792
|
+
from: string;
|
|
793
|
+
disallow: string[];
|
|
794
|
+
message?: string | undefined;
|
|
795
|
+
}[] | undefined;
|
|
796
|
+
security?: {
|
|
797
|
+
rules?: Record<string, string> | undefined;
|
|
798
|
+
} | undefined;
|
|
799
|
+
}>;
|
|
800
|
+
contributions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
801
|
+
}, "strip", z.ZodTypeAny, {
|
|
802
|
+
name: string;
|
|
803
|
+
version: string;
|
|
804
|
+
manifest: {
|
|
805
|
+
name: string;
|
|
806
|
+
version: string;
|
|
807
|
+
include: string[];
|
|
808
|
+
keywords: string[];
|
|
809
|
+
layers?: Record<string, string[]> | undefined;
|
|
810
|
+
description?: string | undefined;
|
|
811
|
+
minHarnessVersion?: string | undefined;
|
|
812
|
+
boundaries?: {
|
|
813
|
+
name: string;
|
|
814
|
+
layer: string;
|
|
815
|
+
direction: "input" | "output";
|
|
816
|
+
schema: string;
|
|
817
|
+
}[] | undefined;
|
|
818
|
+
};
|
|
819
|
+
constraints: {
|
|
820
|
+
architecture?: {
|
|
821
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
822
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
823
|
+
} | undefined;
|
|
824
|
+
layers?: {
|
|
825
|
+
name: string;
|
|
826
|
+
pattern: string;
|
|
827
|
+
allowedDependencies: string[];
|
|
828
|
+
}[] | undefined;
|
|
829
|
+
boundaries?: {
|
|
830
|
+
requireSchema?: string[] | undefined;
|
|
831
|
+
} | undefined;
|
|
832
|
+
forbiddenImports?: {
|
|
833
|
+
from: string;
|
|
834
|
+
disallow: string[];
|
|
835
|
+
message?: string | undefined;
|
|
836
|
+
}[] | undefined;
|
|
837
|
+
security?: {
|
|
838
|
+
rules?: Record<string, string> | undefined;
|
|
839
|
+
} | undefined;
|
|
840
|
+
};
|
|
841
|
+
description?: string | undefined;
|
|
842
|
+
minHarnessVersion?: string | undefined;
|
|
843
|
+
contributions?: Record<string, unknown> | undefined;
|
|
844
|
+
}, {
|
|
845
|
+
name: string;
|
|
846
|
+
version: string;
|
|
847
|
+
manifest: {
|
|
848
|
+
name: string;
|
|
849
|
+
version: string;
|
|
850
|
+
include: string[];
|
|
851
|
+
layers?: Record<string, string[]> | undefined;
|
|
852
|
+
description?: string | undefined;
|
|
853
|
+
minHarnessVersion?: string | undefined;
|
|
854
|
+
keywords?: string[] | undefined;
|
|
855
|
+
boundaries?: {
|
|
856
|
+
name: string;
|
|
857
|
+
layer: string;
|
|
858
|
+
direction: "input" | "output";
|
|
859
|
+
schema: string;
|
|
860
|
+
}[] | undefined;
|
|
861
|
+
};
|
|
862
|
+
constraints: {
|
|
863
|
+
architecture?: {
|
|
864
|
+
thresholds?: Record<string, unknown> | undefined;
|
|
865
|
+
modules?: Record<string, Record<string, unknown>> | undefined;
|
|
866
|
+
} | undefined;
|
|
867
|
+
layers?: {
|
|
868
|
+
name: string;
|
|
869
|
+
pattern: string;
|
|
870
|
+
allowedDependencies: string[];
|
|
871
|
+
}[] | undefined;
|
|
872
|
+
boundaries?: {
|
|
873
|
+
requireSchema?: string[] | undefined;
|
|
874
|
+
} | undefined;
|
|
875
|
+
forbiddenImports?: {
|
|
876
|
+
from: string;
|
|
877
|
+
disallow: string[];
|
|
878
|
+
message?: string | undefined;
|
|
879
|
+
}[] | undefined;
|
|
880
|
+
security?: {
|
|
881
|
+
rules?: Record<string, string> | undefined;
|
|
882
|
+
} | undefined;
|
|
883
|
+
};
|
|
884
|
+
description?: string | undefined;
|
|
885
|
+
minHarnessVersion?: string | undefined;
|
|
886
|
+
contributions?: Record<string, unknown> | undefined;
|
|
887
|
+
}>;
|
|
888
|
+
declare const ContributionsSchema: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
889
|
+
type Bundle = z.infer<typeof BundleSchema>;
|
|
890
|
+
type BundleConstraints = z.infer<typeof BundleConstraintsSchema>;
|
|
891
|
+
type Contributions = Record<string, unknown>;
|
|
892
|
+
declare const LockfilePackageSchema: z.ZodObject<{
|
|
893
|
+
version: z.ZodString;
|
|
894
|
+
source: z.ZodString;
|
|
895
|
+
installedAt: z.ZodString;
|
|
896
|
+
contributions: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
897
|
+
resolved: z.ZodOptional<z.ZodString>;
|
|
898
|
+
integrity: z.ZodOptional<z.ZodString>;
|
|
899
|
+
provenance: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
900
|
+
}, "strip", z.ZodTypeAny, {
|
|
901
|
+
source: string;
|
|
902
|
+
version: string;
|
|
903
|
+
installedAt: string;
|
|
904
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
905
|
+
resolved?: string | undefined;
|
|
906
|
+
integrity?: string | undefined;
|
|
907
|
+
provenance?: string[] | undefined;
|
|
908
|
+
}, {
|
|
909
|
+
source: string;
|
|
910
|
+
version: string;
|
|
911
|
+
installedAt: string;
|
|
912
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
913
|
+
resolved?: string | undefined;
|
|
914
|
+
integrity?: string | undefined;
|
|
915
|
+
provenance?: string[] | undefined;
|
|
916
|
+
}>;
|
|
917
|
+
declare const LockfileSchema: z.ZodEffects<z.ZodObject<{
|
|
918
|
+
version: z.ZodOptional<z.ZodLiteral<1>>;
|
|
919
|
+
lockfileVersion: z.ZodOptional<z.ZodLiteral<1>>;
|
|
920
|
+
packages: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
921
|
+
version: z.ZodString;
|
|
922
|
+
source: z.ZodString;
|
|
923
|
+
installedAt: z.ZodString;
|
|
924
|
+
contributions: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
925
|
+
resolved: z.ZodOptional<z.ZodString>;
|
|
926
|
+
integrity: z.ZodOptional<z.ZodString>;
|
|
927
|
+
provenance: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
928
|
+
}, "strip", z.ZodTypeAny, {
|
|
929
|
+
source: string;
|
|
930
|
+
version: string;
|
|
931
|
+
installedAt: string;
|
|
932
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
933
|
+
resolved?: string | undefined;
|
|
934
|
+
integrity?: string | undefined;
|
|
935
|
+
provenance?: string[] | undefined;
|
|
936
|
+
}, {
|
|
937
|
+
source: string;
|
|
938
|
+
version: string;
|
|
939
|
+
installedAt: string;
|
|
940
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
941
|
+
resolved?: string | undefined;
|
|
942
|
+
integrity?: string | undefined;
|
|
943
|
+
provenance?: string[] | undefined;
|
|
944
|
+
}>>;
|
|
945
|
+
}, "strip", z.ZodTypeAny, {
|
|
946
|
+
packages: Record<string, {
|
|
947
|
+
source: string;
|
|
948
|
+
version: string;
|
|
949
|
+
installedAt: string;
|
|
950
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
951
|
+
resolved?: string | undefined;
|
|
952
|
+
integrity?: string | undefined;
|
|
953
|
+
provenance?: string[] | undefined;
|
|
954
|
+
}>;
|
|
955
|
+
version?: 1 | undefined;
|
|
956
|
+
lockfileVersion?: 1 | undefined;
|
|
957
|
+
}, {
|
|
958
|
+
packages: Record<string, {
|
|
959
|
+
source: string;
|
|
960
|
+
version: string;
|
|
961
|
+
installedAt: string;
|
|
962
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
963
|
+
resolved?: string | undefined;
|
|
964
|
+
integrity?: string | undefined;
|
|
965
|
+
provenance?: string[] | undefined;
|
|
966
|
+
}>;
|
|
967
|
+
version?: 1 | undefined;
|
|
968
|
+
lockfileVersion?: 1 | undefined;
|
|
969
|
+
}>, {
|
|
970
|
+
packages: Record<string, {
|
|
971
|
+
source: string;
|
|
972
|
+
version: string;
|
|
973
|
+
installedAt: string;
|
|
974
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
975
|
+
resolved?: string | undefined;
|
|
976
|
+
integrity?: string | undefined;
|
|
977
|
+
provenance?: string[] | undefined;
|
|
978
|
+
}>;
|
|
979
|
+
version?: 1 | undefined;
|
|
980
|
+
lockfileVersion?: 1 | undefined;
|
|
981
|
+
}, {
|
|
982
|
+
packages: Record<string, {
|
|
983
|
+
source: string;
|
|
984
|
+
version: string;
|
|
985
|
+
installedAt: string;
|
|
986
|
+
contributions?: Record<string, unknown> | null | undefined;
|
|
987
|
+
resolved?: string | undefined;
|
|
988
|
+
integrity?: string | undefined;
|
|
989
|
+
provenance?: string[] | undefined;
|
|
990
|
+
}>;
|
|
991
|
+
version?: 1 | undefined;
|
|
992
|
+
lockfileVersion?: 1 | undefined;
|
|
993
|
+
}>;
|
|
994
|
+
type Lockfile = z.infer<typeof LockfileSchema>;
|
|
995
|
+
type LockfilePackage = z.infer<typeof LockfilePackageSchema>;
|
|
996
|
+
declare const SharableLayerSchema: z.ZodUnknown;
|
|
997
|
+
declare const SharableForbiddenImportSchema: z.ZodUnknown;
|
|
998
|
+
declare const SharableBoundaryConfigSchema: z.ZodUnknown;
|
|
999
|
+
declare const SharableSecurityRulesSchema: z.ZodUnknown;
|
|
1000
|
+
|
|
1001
|
+
/**
|
|
1002
|
+
* Utility to write a config object to disk as JSON or YAML.
|
|
1003
|
+
* In this implementation, we'll keep it simple and just use JSON.stringify
|
|
1004
|
+
* or a placeholder for YAML if needed.
|
|
1005
|
+
*/
|
|
1006
|
+
declare function writeConfig(filePath: string, content: unknown): Promise<Result<void, Error>>;
|
|
1007
|
+
|
|
1008
|
+
/**
|
|
1009
|
+
* Parse and validate a manifest from a pre-parsed object.
|
|
1010
|
+
*
|
|
1011
|
+
* YAML parsing is the caller's responsibility (stays in the CLI layer).
|
|
1012
|
+
* This function validates the parsed structure against ManifestSchema.
|
|
1013
|
+
*
|
|
1014
|
+
* @param parsed - The result of YAML.parse() or JSON.parse()
|
|
1015
|
+
* @returns Result<Manifest, string>
|
|
1016
|
+
*/
|
|
1017
|
+
declare function parseManifest(parsed: unknown): Result<Manifest, string>;
|
|
1018
|
+
|
|
1019
|
+
/**
|
|
1020
|
+
* Extract a constraints bundle from a harness config using the paths declared
|
|
1021
|
+
* in the manifest's `include` array.
|
|
1022
|
+
*
|
|
1023
|
+
* Only paths that exist in the config are included in the bundle.
|
|
1024
|
+
* Missing paths are silently omitted (not an error).
|
|
1025
|
+
*
|
|
1026
|
+
* Supported include paths:
|
|
1027
|
+
* "layers" → config.layers
|
|
1028
|
+
* "forbiddenImports" → config.forbiddenImports
|
|
1029
|
+
* "boundaries" → config.boundaries
|
|
1030
|
+
* "architecture" → config.architecture
|
|
1031
|
+
* "security.rules" → config.security.rules
|
|
1032
|
+
*
|
|
1033
|
+
* @param manifest - Validated Manifest object
|
|
1034
|
+
* @param config - The project's harness config (Record<string, unknown>)
|
|
1035
|
+
* @returns Result<Bundle, string>
|
|
1036
|
+
*/
|
|
1037
|
+
declare function extractBundle(manifest: Manifest, config: Record<string, unknown>): Result<Bundle, string>;
|
|
1038
|
+
|
|
1039
|
+
interface ConflictReport {
|
|
1040
|
+
section: string;
|
|
1041
|
+
key: string;
|
|
1042
|
+
localValue: unknown;
|
|
1043
|
+
packageValue: unknown;
|
|
1044
|
+
description: string;
|
|
1045
|
+
}
|
|
1046
|
+
interface MergeResult {
|
|
1047
|
+
config: Record<string, unknown>;
|
|
1048
|
+
contributions: Contributions;
|
|
1049
|
+
conflicts: ConflictReport[];
|
|
1050
|
+
}
|
|
1051
|
+
declare function deepMergeConstraints(localConfig: Record<string, unknown>, bundleConstraints: BundleConstraints, _existingContributions?: Contributions): MergeResult;
|
|
1052
|
+
|
|
1053
|
+
/**
|
|
1054
|
+
* Read and validate a lockfile from disk.
|
|
1055
|
+
*
|
|
1056
|
+
* Returns null (not an error) if the file does not exist.
|
|
1057
|
+
* Returns an error if the file exists but is invalid JSON or fails schema validation.
|
|
1058
|
+
*/
|
|
1059
|
+
declare function readLockfile(lockfilePath: string): Promise<Result<Lockfile | null, string>>;
|
|
1060
|
+
/**
|
|
1061
|
+
* Write a lockfile to disk using atomic write.
|
|
1062
|
+
*/
|
|
1063
|
+
declare function writeLockfile(lockfilePath: string, lockfile: Lockfile): Promise<void>;
|
|
1064
|
+
/**
|
|
1065
|
+
* Add or replace a package entry in the lockfile (immutable).
|
|
1066
|
+
*
|
|
1067
|
+
* If the package already exists, its entry is replaced (upgrade semantics).
|
|
1068
|
+
*/
|
|
1069
|
+
declare function addProvenance(lockfile: Lockfile, packageName: string, entry: LockfilePackage): Lockfile;
|
|
1070
|
+
/**
|
|
1071
|
+
* Remove a package entry from the lockfile (immutable).
|
|
1072
|
+
*
|
|
1073
|
+
* Returns the updated lockfile and the removed package's contributions
|
|
1074
|
+
* (or null if the package was not found).
|
|
1075
|
+
*/
|
|
1076
|
+
declare function removeProvenance(lockfile: Lockfile, packageName: string): {
|
|
1077
|
+
lockfile: Lockfile;
|
|
1078
|
+
contributions: Contributions | null;
|
|
1079
|
+
};
|
|
1080
|
+
|
|
447
1081
|
interface InternalSymbol {
|
|
448
1082
|
name: string;
|
|
449
1083
|
type: 'function' | 'class' | 'variable' | 'type';
|
|
@@ -1420,13 +2054,13 @@ declare const EntropyConfigSchema: z.ZodObject<{
|
|
|
1420
2054
|
entryPoints?: string[] | undefined;
|
|
1421
2055
|
includeTypes?: boolean | undefined;
|
|
1422
2056
|
includeInternals?: boolean | undefined;
|
|
1423
|
-
treatDynamicImportsAs?: "
|
|
2057
|
+
treatDynamicImportsAs?: "unknown" | "used" | undefined;
|
|
1424
2058
|
}, {
|
|
1425
2059
|
ignorePatterns?: string[] | undefined;
|
|
1426
2060
|
entryPoints?: string[] | undefined;
|
|
1427
2061
|
includeTypes?: boolean | undefined;
|
|
1428
2062
|
includeInternals?: boolean | undefined;
|
|
1429
|
-
treatDynamicImportsAs?: "
|
|
2063
|
+
treatDynamicImportsAs?: "unknown" | "used" | undefined;
|
|
1430
2064
|
}>]>>;
|
|
1431
2065
|
patterns: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodObject<{
|
|
1432
2066
|
patterns: z.ZodArray<z.ZodObject<{
|
|
@@ -1692,7 +2326,7 @@ declare const EntropyConfigSchema: z.ZodObject<{
|
|
|
1692
2326
|
entryPoints?: string[] | undefined;
|
|
1693
2327
|
includeTypes?: boolean | undefined;
|
|
1694
2328
|
includeInternals?: boolean | undefined;
|
|
1695
|
-
treatDynamicImportsAs?: "
|
|
2329
|
+
treatDynamicImportsAs?: "unknown" | "used" | undefined;
|
|
1696
2330
|
} | undefined;
|
|
1697
2331
|
patterns?: boolean | {
|
|
1698
2332
|
patterns: {
|
|
@@ -1748,7 +2382,7 @@ declare const EntropyConfigSchema: z.ZodObject<{
|
|
|
1748
2382
|
entryPoints?: string[] | undefined;
|
|
1749
2383
|
includeTypes?: boolean | undefined;
|
|
1750
2384
|
includeInternals?: boolean | undefined;
|
|
1751
|
-
treatDynamicImportsAs?: "
|
|
2385
|
+
treatDynamicImportsAs?: "unknown" | "used" | undefined;
|
|
1752
2386
|
} | undefined;
|
|
1753
2387
|
patterns?: boolean | {
|
|
1754
2388
|
patterns: {
|
|
@@ -1810,7 +2444,7 @@ declare const EntropyConfigSchema: z.ZodObject<{
|
|
|
1810
2444
|
entryPoints?: string[] | undefined;
|
|
1811
2445
|
includeTypes?: boolean | undefined;
|
|
1812
2446
|
includeInternals?: boolean | undefined;
|
|
1813
|
-
treatDynamicImportsAs?: "
|
|
2447
|
+
treatDynamicImportsAs?: "unknown" | "used" | undefined;
|
|
1814
2448
|
} | undefined;
|
|
1815
2449
|
patterns?: boolean | {
|
|
1816
2450
|
patterns: {
|
|
@@ -1855,9 +2489,9 @@ declare const EntropyConfigSchema: z.ZodObject<{
|
|
|
1855
2489
|
} | undefined;
|
|
1856
2490
|
};
|
|
1857
2491
|
parser?: any;
|
|
2492
|
+
include?: string[] | undefined;
|
|
1858
2493
|
docPaths?: string[] | undefined;
|
|
1859
2494
|
entryPoints?: string[] | undefined;
|
|
1860
|
-
include?: string[] | undefined;
|
|
1861
2495
|
exclude?: string[] | undefined;
|
|
1862
2496
|
}, {
|
|
1863
2497
|
rootDir: string;
|
|
@@ -1874,7 +2508,7 @@ declare const EntropyConfigSchema: z.ZodObject<{
|
|
|
1874
2508
|
entryPoints?: string[] | undefined;
|
|
1875
2509
|
includeTypes?: boolean | undefined;
|
|
1876
2510
|
includeInternals?: boolean | undefined;
|
|
1877
|
-
treatDynamicImportsAs?: "
|
|
2511
|
+
treatDynamicImportsAs?: "unknown" | "used" | undefined;
|
|
1878
2512
|
} | undefined;
|
|
1879
2513
|
patterns?: boolean | {
|
|
1880
2514
|
patterns: {
|
|
@@ -1919,9 +2553,9 @@ declare const EntropyConfigSchema: z.ZodObject<{
|
|
|
1919
2553
|
} | undefined;
|
|
1920
2554
|
};
|
|
1921
2555
|
parser?: any;
|
|
2556
|
+
include?: string[] | undefined;
|
|
1922
2557
|
docPaths?: string[] | undefined;
|
|
1923
2558
|
entryPoints?: string[] | undefined;
|
|
1924
|
-
include?: string[] | undefined;
|
|
1925
2559
|
exclude?: string[] | undefined;
|
|
1926
2560
|
}>;
|
|
1927
2561
|
/**
|
|
@@ -2141,7 +2775,7 @@ interface ForbiddenPattern {
|
|
|
2141
2775
|
fileGlob?: string;
|
|
2142
2776
|
}
|
|
2143
2777
|
type AgentType = 'architecture-enforcer' | 'documentation-maintainer' | 'test-reviewer' | 'entropy-cleaner' | 'custom';
|
|
2144
|
-
interface
|
|
2778
|
+
interface FeedbackAgentConfig {
|
|
2145
2779
|
type: AgentType;
|
|
2146
2780
|
customType?: string;
|
|
2147
2781
|
context: ReviewContext;
|
|
@@ -2158,7 +2792,7 @@ interface AgentProcess {
|
|
|
2158
2792
|
id: string;
|
|
2159
2793
|
status: 'pending' | 'running' | 'completed' | 'failed' | 'timeout';
|
|
2160
2794
|
startedAt: string;
|
|
2161
|
-
config:
|
|
2795
|
+
config: FeedbackAgentConfig;
|
|
2162
2796
|
}
|
|
2163
2797
|
interface PeerReview {
|
|
2164
2798
|
agentId: string;
|
|
@@ -2289,7 +2923,7 @@ interface TelemetryAdapter {
|
|
|
2289
2923
|
interface AgentExecutor {
|
|
2290
2924
|
readonly name: string;
|
|
2291
2925
|
health(): Promise<Result<ExecutorHealth, FeedbackError>>;
|
|
2292
|
-
spawn(config:
|
|
2926
|
+
spawn(config: FeedbackAgentConfig): Promise<Result<AgentProcess, FeedbackError>>;
|
|
2293
2927
|
status(processId: string): Promise<Result<AgentProcess, FeedbackError>>;
|
|
2294
2928
|
wait(processId: string, timeout?: number): Promise<Result<PeerReview, FeedbackError>>;
|
|
2295
2929
|
kill(processId: string): Promise<Result<void, FeedbackError>>;
|
|
@@ -2388,7 +3022,7 @@ declare class NoOpExecutor implements AgentExecutor {
|
|
|
2388
3022
|
readonly name = "noop";
|
|
2389
3023
|
private processes;
|
|
2390
3024
|
health(): Promise<Result<ExecutorHealth, FeedbackError>>;
|
|
2391
|
-
spawn(config:
|
|
3025
|
+
spawn(config: FeedbackAgentConfig): Promise<Result<AgentProcess, FeedbackError>>;
|
|
2392
3026
|
status(processId: string): Promise<Result<AgentProcess, FeedbackError>>;
|
|
2393
3027
|
wait(processId: string): Promise<Result<PeerReview, FeedbackError>>;
|
|
2394
3028
|
kill(processId: string): Promise<Result<void, FeedbackError>>;
|
|
@@ -2444,6 +3078,171 @@ declare class NoOpSink implements ActionSink {
|
|
|
2444
3078
|
write(): Promise<Result<void, FeedbackError>>;
|
|
2445
3079
|
}
|
|
2446
3080
|
|
|
3081
|
+
declare class CircularDepsCollector implements Collector {
|
|
3082
|
+
readonly category: "circular-deps";
|
|
3083
|
+
getRules(_config: ArchConfig, _rootDir: string): ConstraintRule[];
|
|
3084
|
+
collect(_config: ArchConfig, rootDir: string): Promise<MetricResult[]>;
|
|
3085
|
+
}
|
|
3086
|
+
|
|
3087
|
+
declare class LayerViolationCollector implements Collector {
|
|
3088
|
+
readonly category: "layer-violations";
|
|
3089
|
+
getRules(_config: ArchConfig, _rootDir: string): ConstraintRule[];
|
|
3090
|
+
collect(_config: ArchConfig, rootDir: string): Promise<MetricResult[]>;
|
|
3091
|
+
}
|
|
3092
|
+
|
|
3093
|
+
declare class ComplexityCollector implements Collector {
|
|
3094
|
+
readonly category: "complexity";
|
|
3095
|
+
getRules(_config: ArchConfig, _rootDir: string): ConstraintRule[];
|
|
3096
|
+
collect(_config: ArchConfig, rootDir: string): Promise<MetricResult[]>;
|
|
3097
|
+
}
|
|
3098
|
+
|
|
3099
|
+
declare class CouplingCollector implements Collector {
|
|
3100
|
+
readonly category: "coupling";
|
|
3101
|
+
getRules(_config: ArchConfig, _rootDir: string): ConstraintRule[];
|
|
3102
|
+
collect(_config: ArchConfig, rootDir: string): Promise<MetricResult[]>;
|
|
3103
|
+
}
|
|
3104
|
+
|
|
3105
|
+
declare class ForbiddenImportCollector implements Collector {
|
|
3106
|
+
readonly category: "forbidden-imports";
|
|
3107
|
+
getRules(_config: ArchConfig, _rootDir: string): ConstraintRule[];
|
|
3108
|
+
collect(_config: ArchConfig, rootDir: string): Promise<MetricResult[]>;
|
|
3109
|
+
}
|
|
3110
|
+
|
|
3111
|
+
declare class ModuleSizeCollector implements Collector {
|
|
3112
|
+
readonly category: "module-size";
|
|
3113
|
+
getRules(config: ArchConfig, _rootDir: string): ConstraintRule[];
|
|
3114
|
+
collect(config: ArchConfig, rootDir: string): Promise<MetricResult[]>;
|
|
3115
|
+
}
|
|
3116
|
+
|
|
3117
|
+
declare class DepDepthCollector implements Collector {
|
|
3118
|
+
readonly category: "dependency-depth";
|
|
3119
|
+
getRules(config: ArchConfig, _rootDir: string): ConstraintRule[];
|
|
3120
|
+
collect(config: ArchConfig, rootDir: string): Promise<MetricResult[]>;
|
|
3121
|
+
}
|
|
3122
|
+
|
|
3123
|
+
/**
|
|
3124
|
+
* Produce a stable violation ID.
|
|
3125
|
+
* Formula: sha256(relativePath + ':' + category + ':' + normalizedDetail)
|
|
3126
|
+
* Line numbers are excluded to keep IDs stable across unrelated edits.
|
|
3127
|
+
*/
|
|
3128
|
+
declare function violationId(relativePath: string, category: string, normalizedDetail: string): string;
|
|
3129
|
+
/**
|
|
3130
|
+
* Produce a stable constraint rule ID.
|
|
3131
|
+
* Formula: sha256(category + ':' + scope + ':' + description)
|
|
3132
|
+
*/
|
|
3133
|
+
declare function constraintRuleId(category: string, scope: string, description: string): string;
|
|
3134
|
+
|
|
3135
|
+
declare const defaultCollectors: Collector[];
|
|
3136
|
+
/**
|
|
3137
|
+
* Run all collectors in parallel and return a flat array of MetricResults.
|
|
3138
|
+
*/
|
|
3139
|
+
declare function runAll(config: ArchConfig, rootDir: string, collectors?: Collector[]): Promise<MetricResult[]>;
|
|
3140
|
+
|
|
3141
|
+
/**
|
|
3142
|
+
* Minimal graph store interface for constraint node operations.
|
|
3143
|
+
* Matches the subset of GraphStore used by this module.
|
|
3144
|
+
*/
|
|
3145
|
+
interface ConstraintNodeStore {
|
|
3146
|
+
findNodes(query: {
|
|
3147
|
+
type: string;
|
|
3148
|
+
}): Array<{
|
|
3149
|
+
id: string;
|
|
3150
|
+
[key: string]: unknown;
|
|
3151
|
+
}>;
|
|
3152
|
+
upsertNode(node: Record<string, unknown>): void;
|
|
3153
|
+
removeNode(id: string): void;
|
|
3154
|
+
}
|
|
3155
|
+
/**
|
|
3156
|
+
* Synchronize constraint rules with graph nodes.
|
|
3157
|
+
*
|
|
3158
|
+
* - Upserts each rule as a `constraint` node (sets `createdAt` on first insert)
|
|
3159
|
+
* - Matches violations to rules and updates `lastViolatedAt`
|
|
3160
|
+
* - Prunes constraint nodes not present in the current rules set (orphan cleanup)
|
|
3161
|
+
*/
|
|
3162
|
+
declare function syncConstraintNodes(store: ConstraintNodeStore, rules: ConstraintRule[], violations: MetricResult[]): void;
|
|
3163
|
+
|
|
3164
|
+
interface StaleConstraint {
|
|
3165
|
+
id: string;
|
|
3166
|
+
category: ArchMetricCategory;
|
|
3167
|
+
description: string;
|
|
3168
|
+
scope: string;
|
|
3169
|
+
lastViolatedAt: string | null;
|
|
3170
|
+
daysSinceLastViolation: number;
|
|
3171
|
+
}
|
|
3172
|
+
interface DetectStaleResult {
|
|
3173
|
+
staleConstraints: StaleConstraint[];
|
|
3174
|
+
totalConstraints: number;
|
|
3175
|
+
windowDays: number;
|
|
3176
|
+
}
|
|
3177
|
+
/**
|
|
3178
|
+
* Detect constraint rules that haven't been violated within the given window.
|
|
3179
|
+
*
|
|
3180
|
+
* A constraint is considered stale if its comparison timestamp
|
|
3181
|
+
* (lastViolatedAt ?? createdAt) is older than `now - windowDays`.
|
|
3182
|
+
*/
|
|
3183
|
+
declare function detectStaleConstraints(store: ConstraintNodeStore, windowDays?: number, category?: ArchMetricCategory): DetectStaleResult;
|
|
3184
|
+
|
|
3185
|
+
/**
|
|
3186
|
+
* Manages architecture baselines stored on disk.
|
|
3187
|
+
*
|
|
3188
|
+
* Baselines are stored at `.harness/arch/baselines.json` relative to the project root.
|
|
3189
|
+
* Each category maps to an aggregate value and an allowlist of known violation IDs.
|
|
3190
|
+
*/
|
|
3191
|
+
declare class ArchBaselineManager {
|
|
3192
|
+
private readonly baselinesPath;
|
|
3193
|
+
constructor(projectRoot: string, baselinePath?: string);
|
|
3194
|
+
/**
|
|
3195
|
+
* Snapshot the current metric results into an ArchBaseline.
|
|
3196
|
+
* Aggregates multiple MetricResults for the same category by summing values
|
|
3197
|
+
* and concatenating violation IDs.
|
|
3198
|
+
*/
|
|
3199
|
+
capture(results: MetricResult[], commitHash: string): ArchBaseline;
|
|
3200
|
+
/**
|
|
3201
|
+
* Load the baselines file from disk.
|
|
3202
|
+
* Returns null if the file does not exist, contains invalid JSON,
|
|
3203
|
+
* or fails ArchBaselineSchema validation.
|
|
3204
|
+
*/
|
|
3205
|
+
load(): ArchBaseline | null;
|
|
3206
|
+
/**
|
|
3207
|
+
* Save an ArchBaseline to disk.
|
|
3208
|
+
* Creates parent directories if they do not exist.
|
|
3209
|
+
* Uses atomic write (write to temp file, then rename) to prevent corruption.
|
|
3210
|
+
*/
|
|
3211
|
+
save(baseline: ArchBaseline): void;
|
|
3212
|
+
}
|
|
3213
|
+
|
|
3214
|
+
/**
|
|
3215
|
+
* Diff current metric results against a stored baseline.
|
|
3216
|
+
*
|
|
3217
|
+
* Pure function implementing the ratchet logic:
|
|
3218
|
+
* - New violations (in current but not baseline) cause failure
|
|
3219
|
+
* - Aggregate value exceeding baseline causes failure (regression)
|
|
3220
|
+
* - Pre-existing violations (in both) are allowed
|
|
3221
|
+
* - Resolved violations (in baseline but not current) are celebrated
|
|
3222
|
+
*
|
|
3223
|
+
* Categories present in current but absent from the baseline are treated
|
|
3224
|
+
* as having an empty baseline (value: 0, no known violations), so any
|
|
3225
|
+
* violations in those categories are considered new.
|
|
3226
|
+
*/
|
|
3227
|
+
declare function diff(current: MetricResult[], baseline: ArchBaseline): ArchDiffResult;
|
|
3228
|
+
|
|
3229
|
+
/**
|
|
3230
|
+
* Resolve effective thresholds for a given scope.
|
|
3231
|
+
*
|
|
3232
|
+
* When scope is 'project' or has no matching module entry, returns
|
|
3233
|
+
* project-wide thresholds. Otherwise, merges project thresholds
|
|
3234
|
+
* with module-level overrides (module wins per-category).
|
|
3235
|
+
*
|
|
3236
|
+
* For object-valued thresholds (e.g. coupling: { maxFanIn, maxFanOut }),
|
|
3237
|
+
* performs a shallow merge at the category level:
|
|
3238
|
+
* project { maxFanIn: 10, maxFanOut: 8 } + module { maxFanOut: 5 }
|
|
3239
|
+
* => { maxFanIn: 10, maxFanOut: 5 }
|
|
3240
|
+
*
|
|
3241
|
+
* When either side is a scalar, the module value replaces the project
|
|
3242
|
+
* value entirely (no merge across scalar/object boundaries).
|
|
3243
|
+
*/
|
|
3244
|
+
declare function resolveThresholds(scope: string, config: ArchConfig): ThresholdConfig;
|
|
3245
|
+
|
|
2447
3246
|
declare const FailureEntrySchema: z.ZodObject<{
|
|
2448
3247
|
date: z.ZodString;
|
|
2449
3248
|
skill: z.ZodString;
|
|
@@ -2451,13 +3250,13 @@ declare const FailureEntrySchema: z.ZodObject<{
|
|
|
2451
3250
|
description: z.ZodString;
|
|
2452
3251
|
}, "strip", z.ZodTypeAny, {
|
|
2453
3252
|
type: string;
|
|
2454
|
-
date: string;
|
|
2455
3253
|
description: string;
|
|
3254
|
+
date: string;
|
|
2456
3255
|
skill: string;
|
|
2457
3256
|
}, {
|
|
2458
3257
|
type: string;
|
|
2459
|
-
date: string;
|
|
2460
3258
|
description: string;
|
|
3259
|
+
date: string;
|
|
2461
3260
|
skill: string;
|
|
2462
3261
|
}>;
|
|
2463
3262
|
type FailureEntry = z.infer<typeof FailureEntrySchema>;
|
|
@@ -2609,12 +3408,12 @@ declare const HarnessStateSchema: z.ZodObject<{
|
|
|
2609
3408
|
status: z.ZodEnum<["open", "resolved"]>;
|
|
2610
3409
|
}, "strip", z.ZodTypeAny, {
|
|
2611
3410
|
id: string;
|
|
2612
|
-
status: "open" | "resolved";
|
|
2613
3411
|
description: string;
|
|
3412
|
+
status: "resolved" | "open";
|
|
2614
3413
|
}, {
|
|
2615
3414
|
id: string;
|
|
2616
|
-
status: "open" | "resolved";
|
|
2617
3415
|
description: string;
|
|
3416
|
+
status: "resolved" | "open";
|
|
2618
3417
|
}>, "many">>;
|
|
2619
3418
|
progress: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodEnum<["pending", "in_progress", "complete"]>>>;
|
|
2620
3419
|
lastSession: z.ZodOptional<z.ZodObject<{
|
|
@@ -2641,8 +3440,8 @@ declare const HarnessStateSchema: z.ZodObject<{
|
|
|
2641
3440
|
}[];
|
|
2642
3441
|
blockers: {
|
|
2643
3442
|
id: string;
|
|
2644
|
-
status: "open" | "resolved";
|
|
2645
3443
|
description: string;
|
|
3444
|
+
status: "resolved" | "open";
|
|
2646
3445
|
}[];
|
|
2647
3446
|
schemaVersion: 1;
|
|
2648
3447
|
position: {
|
|
@@ -2665,8 +3464,8 @@ declare const HarnessStateSchema: z.ZodObject<{
|
|
|
2665
3464
|
}[] | undefined;
|
|
2666
3465
|
blockers?: {
|
|
2667
3466
|
id: string;
|
|
2668
|
-
status: "open" | "resolved";
|
|
2669
3467
|
description: string;
|
|
3468
|
+
status: "resolved" | "open";
|
|
2670
3469
|
}[] | undefined;
|
|
2671
3470
|
position?: {
|
|
2672
3471
|
task?: string | undefined;
|
|
@@ -2915,10 +3714,10 @@ declare const SecurityConfigSchema: z.ZodObject<{
|
|
|
2915
3714
|
} | undefined;
|
|
2916
3715
|
}>>;
|
|
2917
3716
|
}, "strip", z.ZodTypeAny, {
|
|
3717
|
+
rules: Record<string, "error" | "warning" | "info" | "off">;
|
|
2918
3718
|
enabled: boolean;
|
|
2919
3719
|
strict: boolean;
|
|
2920
3720
|
exclude: string[];
|
|
2921
|
-
rules: Record<string, "error" | "warning" | "info" | "off">;
|
|
2922
3721
|
external?: {
|
|
2923
3722
|
semgrep?: {
|
|
2924
3723
|
enabled: boolean | "auto";
|
|
@@ -2929,10 +3728,10 @@ declare const SecurityConfigSchema: z.ZodObject<{
|
|
|
2929
3728
|
} | undefined;
|
|
2930
3729
|
} | undefined;
|
|
2931
3730
|
}, {
|
|
3731
|
+
rules?: Record<string, "error" | "warning" | "info" | "off"> | undefined;
|
|
2932
3732
|
enabled?: boolean | undefined;
|
|
2933
3733
|
strict?: boolean | undefined;
|
|
2934
3734
|
exclude?: string[] | undefined;
|
|
2935
|
-
rules?: Record<string, "error" | "warning" | "info" | "off"> | undefined;
|
|
2936
3735
|
external?: {
|
|
2937
3736
|
semgrep?: {
|
|
2938
3737
|
enabled?: boolean | "auto" | undefined;
|
|
@@ -3880,6 +4679,69 @@ type Confirmation = z.infer<typeof ConfirmationSchema>;
|
|
|
3880
4679
|
type Transition = z.infer<typeof TransitionSchema>;
|
|
3881
4680
|
type EmitInteractionInput = z.infer<typeof EmitInteractionInputSchema>;
|
|
3882
4681
|
|
|
4682
|
+
interface Quiz$1 {
|
|
4683
|
+
questions: {
|
|
4684
|
+
question: string;
|
|
4685
|
+
answer: string;
|
|
4686
|
+
}[];
|
|
4687
|
+
}
|
|
4688
|
+
interface Content$1 {
|
|
4689
|
+
codeTranslation: string;
|
|
4690
|
+
quiz: Quiz$1;
|
|
4691
|
+
}
|
|
4692
|
+
interface BlueprintModule {
|
|
4693
|
+
id: string;
|
|
4694
|
+
title: string;
|
|
4695
|
+
description: string;
|
|
4696
|
+
files: string[];
|
|
4697
|
+
content?: Content$1;
|
|
4698
|
+
}
|
|
4699
|
+
interface Hotspot {
|
|
4700
|
+
file: string;
|
|
4701
|
+
function: string;
|
|
4702
|
+
score: number;
|
|
4703
|
+
}
|
|
4704
|
+
interface ModuleDependency {
|
|
4705
|
+
from: string;
|
|
4706
|
+
to: string;
|
|
4707
|
+
}
|
|
4708
|
+
interface BlueprintData {
|
|
4709
|
+
projectName: string;
|
|
4710
|
+
generatedAt: string;
|
|
4711
|
+
modules: BlueprintModule[];
|
|
4712
|
+
hotspots: Hotspot[];
|
|
4713
|
+
dependencies: ModuleDependency[];
|
|
4714
|
+
}
|
|
4715
|
+
interface BlueprintOptions {
|
|
4716
|
+
outputDir: string;
|
|
4717
|
+
projectName?: string;
|
|
4718
|
+
}
|
|
4719
|
+
|
|
4720
|
+
declare class ProjectScanner {
|
|
4721
|
+
private rootDir;
|
|
4722
|
+
constructor(rootDir: string);
|
|
4723
|
+
scan(): Promise<BlueprintData>;
|
|
4724
|
+
}
|
|
4725
|
+
|
|
4726
|
+
declare class BlueprintGenerator {
|
|
4727
|
+
private contentPipeline;
|
|
4728
|
+
generate(data: BlueprintData, options: BlueprintOptions): Promise<void>;
|
|
4729
|
+
}
|
|
4730
|
+
|
|
4731
|
+
interface Content {
|
|
4732
|
+
codeTranslation: string;
|
|
4733
|
+
quiz: Quiz;
|
|
4734
|
+
}
|
|
4735
|
+
interface Quiz {
|
|
4736
|
+
questions: {
|
|
4737
|
+
question: string;
|
|
4738
|
+
answer: string;
|
|
4739
|
+
}[];
|
|
4740
|
+
}
|
|
4741
|
+
declare class ContentPipeline {
|
|
4742
|
+
generateModuleContent(module: BlueprintModule): Promise<Content>;
|
|
4743
|
+
}
|
|
4744
|
+
|
|
3883
4745
|
interface UpdateCheckState {
|
|
3884
4746
|
lastCheckTime: number;
|
|
3885
4747
|
latestVersion: string | null;
|
|
@@ -3920,15 +4782,22 @@ declare function getUpdateNotification(currentVersion: string): string | null;
|
|
|
3920
4782
|
/**
|
|
3921
4783
|
* @harness-engineering/core
|
|
3922
4784
|
*
|
|
3923
|
-
* Core library for Harness Engineering toolkit
|
|
4785
|
+
* Core library for Harness Engineering toolkit.
|
|
4786
|
+
* This library provides the fundamental building blocks for codebase analysis,
|
|
4787
|
+
* validation, entropy management, and agent-driven workflows.
|
|
4788
|
+
*/
|
|
4789
|
+
/**
|
|
4790
|
+
* Re-export all fundamental types from the types package.
|
|
3924
4791
|
*/
|
|
3925
4792
|
|
|
3926
4793
|
/**
|
|
4794
|
+
* The current version of the Harness Engineering core library.
|
|
4795
|
+
*
|
|
3927
4796
|
* @deprecated Read the CLI version from `@harness-engineering/cli/package.json`
|
|
3928
4797
|
* instead. This hardcoded constant drifts from the actual CLI version on each
|
|
3929
4798
|
* release. Kept only as a fallback for consumers that cannot resolve the CLI
|
|
3930
4799
|
* package at runtime.
|
|
3931
4800
|
*/
|
|
3932
|
-
declare const VERSION = "
|
|
4801
|
+
declare const VERSION = "0.11.0";
|
|
3933
4802
|
|
|
3934
|
-
export { AGENT_DESCRIPTORS, ARCHITECTURE_DESCRIPTOR, type AST, type ActionContext, type ActionEvent, type ActionEventHandler, type ActionEventType, type ActionResult, type ActionSink, type ActionTracker, type ActionType, type AgentAction, AgentActionEmitter, type
|
|
4803
|
+
export { AGENT_DESCRIPTORS, ARCHITECTURE_DESCRIPTOR, type AST, type ActionContext, type ActionEvent, type ActionEventHandler, type ActionEventType, type ActionResult, type ActionSink, type ActionTracker, type ActionType, type AgentAction, AgentActionEmitter, type AgentExecutor, type AgentMapLink, type AgentMapSection, type AgentMapValidation, type AgentProcess, type AgentReviewResult, type AgentType, type AgentsMapConfig, ArchBaseline, ArchBaselineManager, ArchConfig, ArchDiffResult, ArchMetricCategory, BUG_DETECTION_DESCRIPTOR, type BaseError, type Baseline, BaselineManager, type BaselinesFile, type BenchmarkResult, type BenchmarkRunOptions, BenchmarkRunner, type BlueprintData, BlueprintGenerator, type BlueprintModule, type BlueprintOptions, type BoundaryDefinition, type BoundaryValidation, type BoundaryValidator, type BoundaryViolation, type BrokenLink, type Bundle, type BundleConstraints, BundleConstraintsSchema, BundleSchema, COMPLIANCE_DESCRIPTOR, type ChangeType, type ChangedFile, ChecklistBuilder, type CircularDependency, CircularDepsCollector, type CircularDepsResult, type CleanupFinding, type CodeBlock, type CodeChanges, type CodePattern, type CodeReference, type CodebaseSnapshot, Collector, type CommentedCodeBlock, type CommitFormat, type CommitHistoryEntry, type CommitValidation, ComplexityCollector, type ComplexityConfig, type ComplexityReport, type ComplexityThresholds, type ComplexityViolation, type ConfigError, type ConfigPattern, type Confirmation, ConfirmationSchema, type ConflictReport, ConsoleSink, type ConstraintError, type ConstraintNodeStore, ConstraintRule, type Content$1 as Content, ContentPipeline, type ContextBundle, type ContextError, type ContextFile, type ContextFilterResult, type ContextScopeOptions, type Contributions, ContributionsSchema, type Convention, CouplingCollector, type CouplingConfig, type CouplingReport, type CouplingThresholds, type CouplingViolation, type CoverageOptions, type CoverageReport, type CriticalPathEntry, CriticalPathResolver, type CriticalPathSet, type CustomRule, type CustomRuleResult, DEFAULT_PROVIDER_TIERS, DEFAULT_SECURITY_CONFIG, DEFAULT_STATE, DEFAULT_STREAM_INDEX, type DeadCodeConfig, type DeadCodeReport, type DeadExport, type DeadFile, type DeadInternal, type DeduplicateFindingsOptions, DepDepthCollector, type DependencyEdge, type DependencyGraph, type DependencyValidation, type DependencyViolation, type DetectStaleResult, type DiffInfo, type DocumentationDrift, type DocumentationFile, type DocumentationGap, type DriftConfig, type DriftReport, type EligibilityResult, type EmitInteractionInput, EmitInteractionInputSchema, EntropyAnalyzer, type EntropyConfig, EntropyConfigSchema, type EntropyError, type EntropyReport, ExclusionSet, type ExecutorHealth, type Export, type ExportMap, type FailureEntry, FailureEntrySchema, type FanOutOptions, type FeedbackAgentConfig, type FeedbackConfig, type FeedbackError$1 as FeedbackError, type FileCategory, FileSink, type FindingSeverity, type Fix, type FixConfig, type FixResult, type FixType, ForbiddenImportCollector, type ForbiddenImportViolation, type ForbiddenPattern, type GateConfig, GateConfigSchema, type GateResult, GateResultSchema, type GenerationSection, type GitHubInlineComment, type GraphAdapter, type GraphComplexityData, type GraphCouplingData, type GraphCoverageData, type GraphCriticalPathData, type GraphDependencyData, type GraphHarnessCheckData, type GraphImpactData, type Handoff, HandoffSchema, type HarnessState, HarnessStateSchema, type HealthCheckResult, type Hotspot, type HotspotContext, type Import, type InlineReference, type IntegrityReport, type InteractionType, InteractionTypeSchema, type InternalSymbol, type JSDocComment, type LanguageParser, type Layer, type LayerConfig, LayerViolationCollector, type Lockfile, type LockfilePackage, LockfilePackageSchema, LockfileSchema, type LogEntry, type LogFilter, type Manifest, ManifestSchema, type MechanicalCheckOptions, type MechanicalCheckResult, type MechanicalCheckStatus, type MechanicalFinding, type MergeResult, type Metric, MetricResult, type ModelProvider, type ModelTier, type ModelTierConfig, type ModuleDependency, ModuleSizeCollector, NoOpExecutor, NoOpSink, NoOpTelemetryAdapter, type OrphanedDep, type ParseError, type PatternConfig, PatternConfigSchema, type PatternMatch, type PatternReport, type PatternViolation, type PeerReview, type PeerReviewOptions, type PipelineContext, type PipelineFlags, type PipelineOptions, type PipelineResult, type PrMetadata, type PriorReview, ProjectScanner, type ProviderDefaults, type Question, QuestionSchema, type Quiz$1 as Quiz, REQUIRED_SECTIONS, type ReachabilityNode, RegressionDetector, type RegressionReport, type RegressionResult, type ReviewAgentDescriptor, type ReviewAssessment, type ReviewChecklist, type ReviewComment, type ReviewContext, type ReviewDomain, type ReviewFinding, type ReviewItem, type ReviewOutputOptions, type ReviewPipelineResult, type ReviewStrength, type RuleOverride, RuleRegistry, type RunCIChecksInput, type RunPipelineOptions, SECURITY_DESCRIPTOR, type SafetyLevel, type ScanResult, type SecurityCategory, type SecurityConfidence, type SecurityConfig, SecurityConfigSchema, type SecurityFinding, type SecurityRule, SecurityScanner, type SecuritySeverity, type SelfReviewConfig, SharableBoundaryConfigSchema, SharableForbiddenImportSchema, SharableLayerSchema, SharableSecurityRulesSchema, type SizeBudgetConfig, type SizeBudgetReport, type SizeBudgetViolation, type SkillExecutor, type SourceFile, type Span, type SpanEvent, type StaleConstraint, type StepExecutor, type StreamIndex, StreamIndexSchema, type StreamInfo, StreamInfoSchema, type StructureValidation, type Suggestion, type SuggestionReport, type SyncChange, type SyncOptions, type TelemetryAdapter, type TelemetryHealth, ThresholdConfig, type TimeRange, type TokenBudget, type TokenBudgetOverrides, type Trace, type Transition, TransitionSchema, type TurnExecutor, TypeScriptParser, type UnusedImport, type UpdateCheckState, VERSION, type ValidateFindingsOptions, type ValidationError, type WorkflowPhase, addProvenance, analyzeDiff, appendFailure, appendLearning, applyFixes, applyHotspotDowngrade, archiveFailures, archiveStream, buildDependencyGraph, buildExclusionSet, buildSnapshot, checkDocCoverage, checkEligibility, classifyFinding, configureFeedback, constraintRuleId, contextBudget, contextFilter, createBoundaryValidator, createCommentedCodeFixes, createError, createFixes, createForbiddenImportFixes, createOrphanedDepFixes, createParseError, createSelfReview, createStream, cryptoRules, deduplicateCleanupFindings, deduplicateFindings, deepMergeConstraints, defaultCollectors, defineLayer, deserializationRules, detectChangeType, detectCircularDeps, detectCircularDepsInFiles, detectComplexityViolations, detectCouplingViolations, detectDeadCode, detectDocDrift, detectPatternViolations, detectSizeBudgetViolations, detectStack, detectStaleConstraints, determineAssessment, diff, executeWorkflow, expressRules, extractBundle, extractMarkdownLinks, extractSections, fanOutReview, formatFindingBlock, formatGitHubComment, formatGitHubSummary, formatTerminalOutput, generateAgentsMap, generateSuggestions, getActionEmitter, getExitCode, getFeedbackConfig, getPhaseCategories, getStreamForBranch, getUpdateNotification, goRules, injectionRules, isSmallSuggestion, isUpdateCheckEnabled, listStreams, loadFailures, loadHandoff, loadRelevantLearnings, loadState, loadStreamIndex, logAgentAction, migrateToStreams, networkRules, nodeRules, parseDiff, parseManifest, parseRoadmap, parseSecurityConfig, parseSize, pathTraversalRules, previewFix, reactRules, readCheckState, readLockfile, removeProvenance, requestMultiplePeerReviews, requestPeerReview, resetFeedbackConfig, resolveFileToLayer, resolveModelTier, resolveRuleSeverity, resolveStreamPath, resolveThresholds, runAll, runArchitectureAgent, runBugDetectionAgent, runCIChecks, runComplianceAgent, runMechanicalChecks, runMechanicalGate, runMultiTurnPipeline, runPipeline, runReviewPipeline, runSecurityAgent, saveHandoff, saveState, saveStreamIndex, scopeContext, secretRules, serializeRoadmap, setActiveStream, shouldRunCheck, spawnBackgroundCheck, syncConstraintNodes, syncRoadmap, touchStream, trackAction, validateAgentsMap, validateBoundaries, validateCommitMessage, validateConfig, validateDependencies, validateFileStructure, validateFindings, validateKnowledgeMap, validatePatternConfig, violationId, writeConfig, writeLockfile, xssRules };
|