@contractspec/bundle.workspace 3.7.5 → 4.0.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.
Files changed (108) hide show
  1. package/README.md +55 -66
  2. package/dist/adapters/ai.d.ts +1 -1
  3. package/dist/adapters/factory.d.ts +1 -1
  4. package/dist/adapters/index.d.ts +5 -5
  5. package/dist/ai/agents/index.d.ts +4 -4
  6. package/dist/ai/agents/orchestrator.d.ts +1 -1
  7. package/dist/ai/agents/simple-agent.d.ts +1 -1
  8. package/dist/ai/agents/unified-adapter.d.ts +2 -2
  9. package/dist/ai/index.d.ts +1 -1
  10. package/dist/ai/providers.d.ts +1 -1
  11. package/dist/contracts/operations/init.operation.d.ts +2 -2
  12. package/dist/formatters/index.d.ts +1 -1
  13. package/dist/index.d.ts +5 -5
  14. package/dist/index.js +14194 -13988
  15. package/dist/node/index.js +14187 -13981
  16. package/dist/ports/index.d.ts +2 -2
  17. package/dist/services/action-drift/index.d.ts +1 -1
  18. package/dist/services/action-drift/types.d.ts +1 -1
  19. package/dist/services/action-pr/index.d.ts +1 -1
  20. package/dist/services/agent-guide/index.d.ts +3 -3
  21. package/dist/services/agent-guide/types.d.ts +1 -1
  22. package/dist/services/build.d.ts +1 -1
  23. package/dist/services/ci-check/checks/handlers.d.ts +1 -1
  24. package/dist/services/ci-check/checks/index.d.ts +7 -6
  25. package/dist/services/ci-check/checks/policy.d.ts +13 -0
  26. package/dist/services/ci-check/checks/policy.test.d.ts +1 -0
  27. package/dist/services/ci-check/checks/tests.d.ts +1 -1
  28. package/dist/services/ci-check/index.d.ts +1 -1
  29. package/dist/services/ci-check/types.d.ts +3 -3
  30. package/dist/services/ci-check/utils.d.ts +2 -0
  31. package/dist/services/config.d.ts +1 -1
  32. package/dist/services/create/ai-generator.d.ts +1 -1
  33. package/dist/services/create/index.d.ts +1 -1
  34. package/dist/services/doctor/checks/ai.d.ts +1 -1
  35. package/dist/services/doctor/checks/config.d.ts +1 -1
  36. package/dist/services/doctor/checks/deps.d.ts +1 -1
  37. package/dist/services/doctor/checks/index.d.ts +3 -3
  38. package/dist/services/doctor/checks/mcp.d.ts +1 -1
  39. package/dist/services/doctor/doctor-service.d.ts +24 -2
  40. package/dist/services/doctor/index.d.ts +1 -1
  41. package/dist/services/features/index.d.ts +1 -1
  42. package/dist/services/fix/fix-link-formatter.d.ts +1 -1
  43. package/dist/services/fix/fix-service.d.ts +1 -1
  44. package/dist/services/fix/format-applicator.d.ts +1 -1
  45. package/dist/services/fix/index.d.ts +2 -2
  46. package/dist/services/fix/strategies/implement-ai.d.ts +1 -1
  47. package/dist/services/fix/strategies/implement-skeleton.d.ts +1 -1
  48. package/dist/services/fix/strategies/index.d.ts +2 -2
  49. package/dist/services/fix/strategies/remove-reference.d.ts +1 -1
  50. package/dist/services/fix/types.d.ts +1 -1
  51. package/dist/services/formatter.d.ts +1 -1
  52. package/dist/services/hooks/index.d.ts +1 -1
  53. package/dist/services/impact/index.d.ts +2 -2
  54. package/dist/services/implementation/discovery.d.ts +1 -1
  55. package/dist/services/implementation/index.d.ts +1 -1
  56. package/dist/services/implementation/resolver/index.d.ts +3 -3
  57. package/dist/services/import/import-service.d.ts +2 -2
  58. package/dist/services/import/index.d.ts +3 -3
  59. package/dist/services/import/verify-service.d.ts +1 -1
  60. package/dist/services/index.d.ts +37 -37
  61. package/dist/services/layer-discovery.d.ts +1 -1
  62. package/dist/services/list.d.ts +3 -3
  63. package/dist/services/openapi/import-service.d.ts +1 -1
  64. package/dist/services/openapi/index.d.ts +3 -3
  65. package/dist/services/openapi/sync-service.d.ts +1 -1
  66. package/dist/services/quickstart/index.d.ts +1 -1
  67. package/dist/services/quickstart/quickstart-service.d.ts +1 -1
  68. package/dist/services/regenerator.d.ts +1 -1
  69. package/dist/services/rulesync.d.ts +1 -1
  70. package/dist/services/setup/index.d.ts +2 -2
  71. package/dist/services/setup/setup-service.d.ts +1 -1
  72. package/dist/services/setup/targets/agents-md.d.ts +1 -1
  73. package/dist/services/setup/targets/biome-config.d.ts +9 -0
  74. package/dist/services/setup/targets/cli-config.d.ts +1 -1
  75. package/dist/services/setup/targets/cursor-rules.d.ts +1 -1
  76. package/dist/services/setup/targets/index.d.ts +5 -4
  77. package/dist/services/setup/targets/mcp-claude.d.ts +1 -1
  78. package/dist/services/setup/targets/mcp-cursor.d.ts +1 -1
  79. package/dist/services/setup/targets/vscode-settings.d.ts +1 -1
  80. package/dist/services/setup/types.d.ts +1 -1
  81. package/dist/services/sync.d.ts +1 -1
  82. package/dist/services/test/index.d.ts +1 -1
  83. package/dist/services/test/test-generator-service.d.ts +2 -2
  84. package/dist/services/test/test-service.d.ts +1 -1
  85. package/dist/services/test-link/index.d.ts +2 -2
  86. package/dist/services/test-link/test-ref-validator.d.ts +1 -1
  87. package/dist/services/upgrade/index.d.ts +1 -1
  88. package/dist/services/upgrade/upgrade-service.d.ts +1 -1
  89. package/dist/services/validate/blueprint-validator.d.ts +1 -1
  90. package/dist/services/validate/implementation-agent-validator.d.ts +1 -1
  91. package/dist/services/validate/implementation-validator.d.ts +1 -1
  92. package/dist/services/validate/index.d.ts +3 -3
  93. package/dist/services/validate/tenant-validator.d.ts +1 -1
  94. package/dist/services/verification-cache/adapters/index.d.ts +1 -1
  95. package/dist/services/verification-cache/index.d.ts +2 -2
  96. package/dist/services/verify/index.d.ts +4 -4
  97. package/dist/services/versioning/changelog-formatter.d.ts +1 -1
  98. package/dist/services/versioning/conventional-commits.d.ts +1 -1
  99. package/dist/services/versioning/index.d.ts +3 -3
  100. package/dist/services/versioning/types.d.ts +2 -3
  101. package/dist/services/versioning/versioning-service.d.ts +1 -1
  102. package/dist/services/vibe/index.d.ts +5 -5
  103. package/dist/services/watch.d.ts +2 -2
  104. package/dist/services/workspace-info.d.ts +2 -2
  105. package/dist/templates/fix/index.d.ts +2 -2
  106. package/dist/templates/index.d.ts +9 -9
  107. package/dist/utils/index.d.ts +1 -1
  108. package/package.json +16 -14
@@ -2,9 +2,9 @@
2
2
  * Port interfaces for ContractSpec workspace services.
3
3
  * These define the contracts that adapters must implement.
4
4
  */
5
+ export * from './ai';
5
6
  export * from './fs';
6
7
  export * from './git';
7
- export * from './watcher';
8
- export * from './ai';
9
8
  export * from './logger';
10
9
  export * from './rulesync';
10
+ export * from './watcher';
@@ -1,2 +1,2 @@
1
- export * from './types';
2
1
  export * from './service';
2
+ export * from './types';
@@ -16,4 +16,4 @@ export interface FinalizeDriftResult {
16
16
  driftDetected: boolean;
17
17
  shouldFail: boolean;
18
18
  }
19
- export type { ReportData, ContractVerificationStatus };
19
+ export type { ContractVerificationStatus, ReportData };
@@ -1,2 +1,2 @@
1
- export * from './types';
2
1
  export * from './service';
2
+ export * from './types';
@@ -6,6 +6,6 @@
6
6
  *
7
7
  * @module @contractspec/bundle.workspace/services/agent-guide
8
8
  */
9
- export type { AgentGuideConfig, GuideOptions, FormatOptions, GuideResult, AgentAdapter, } from './types';
10
- export { AgentGuideService, createAgentGuideService, agentGuideService, } from './agent-guide-service';
11
- export { ClaudeCodeAdapter, claudeCodeAdapter, CursorCLIAdapter, cursorCLIAdapter, GenericMCPAdapter, genericMCPAdapter, agentAdapters, getAgentAdapter, listAgentTypes, } from './adapters';
9
+ export { agentAdapters, ClaudeCodeAdapter, CursorCLIAdapter, claudeCodeAdapter, cursorCLIAdapter, GenericMCPAdapter, genericMCPAdapter, getAgentAdapter, listAgentTypes, } from './adapters';
10
+ export { AgentGuideService, agentGuideService, createAgentGuideService, } from './agent-guide-service';
11
+ export type { AgentAdapter, AgentGuideConfig, FormatOptions, GuideOptions, GuideResult, } from './types';
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * Types for the Agent Guide service.
3
3
  */
4
- import type { AgentPrompt, AgentType, ImplementationPlan } from '@contractspec/lib.contracts-spec/llm';
5
4
  import type { AnyOperationSpec } from '@contractspec/lib.contracts-spec';
5
+ import type { AgentPrompt, AgentType, ImplementationPlan } from '@contractspec/lib.contracts-spec/llm';
6
6
  /** Configuration for the agent guide service */
7
7
  export interface AgentGuideConfig {
8
8
  /** Default agent to use if not specified */
@@ -4,10 +4,10 @@
4
4
  * Uses templates from @contractspec/module.workspace to generate
5
5
  * handler, component, and test skeletons without requiring AI.
6
6
  */
7
+ import type { ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec';
7
8
  import { type SpecScanResult } from '@contractspec/module.workspace';
8
9
  import type { FsAdapter } from '../ports/fs';
9
10
  import type { LoggerAdapter } from '../ports/logger';
10
- import type { ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec';
11
11
  /**
12
12
  * Build target types.
13
13
  */
@@ -1,10 +1,10 @@
1
1
  /**
2
2
  * Handler implementation checks.
3
3
  */
4
+ import type { SpecScanResult } from '@contractspec/module.workspace';
4
5
  import type { FsAdapter } from '../../../ports/fs';
5
6
  import type { LoggerAdapter } from '../../../ports/logger';
6
7
  import type { CIIssue } from '../types';
7
- import type { SpecScanResult } from '@contractspec/module.workspace';
8
8
  /**
9
9
  * Run handler implementation checks.
10
10
  */
@@ -1,14 +1,15 @@
1
1
  /**
2
2
  * CI check modules index.
3
3
  */
4
- export { runStructureChecks } from './structure';
5
- export { runIntegrityChecks } from './integrity';
4
+ export { runCoverageChecks } from './coverage';
6
5
  export { runDepsChecks } from './deps';
7
6
  export { runDoctorChecks } from './doctor';
7
+ export { runDriftChecks } from './drift';
8
8
  export { runHandlerChecks } from './handlers';
9
- export { runTestChecks } from './tests';
10
- export { runTestRefsChecks } from './test-refs';
11
- export { runCoverageChecks } from './coverage';
12
9
  export { runImplementationChecks } from './implementation';
10
+ export { runIntegrityChecks } from './integrity';
13
11
  export { runLayerChecks } from './layers';
14
- export { runDriftChecks } from './drift';
12
+ export { runPolicyChecks } from './policy';
13
+ export { runStructureChecks } from './structure';
14
+ export { runTestRefsChecks } from './test-refs';
15
+ export { runTestChecks } from './tests';
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Policy enforcement checks.
3
+ */
4
+ import type { FsAdapter } from '../../../ports/fs';
5
+ import type { LoggerAdapter } from '../../../ports/logger';
6
+ import type { CICheckOptions, CIIssue } from '../types';
7
+ /**
8
+ * Run contract-first implementation checks.
9
+ */
10
+ export declare function runPolicyChecks(adapters: {
11
+ fs: FsAdapter;
12
+ logger: LoggerAdapter;
13
+ }, options: CICheckOptions): Promise<CIIssue[]>;
@@ -0,0 +1 @@
1
+ export {};
@@ -1,10 +1,10 @@
1
1
  /**
2
2
  * Test coverage checks.
3
3
  */
4
+ import type { SpecScanResult } from '@contractspec/module.workspace';
4
5
  import type { FsAdapter } from '../../../ports/fs';
5
6
  import type { LoggerAdapter } from '../../../ports/logger';
6
7
  import type { CIIssue } from '../types';
7
- import type { SpecScanResult } from '@contractspec/module.workspace';
8
8
  /**
9
9
  * Run test coverage checks.
10
10
  */
@@ -1,5 +1,5 @@
1
1
  /**
2
2
  * CI Check service exports.
3
3
  */
4
- export * from './types';
5
4
  export * from './ci-check-service';
5
+ export * from './types';
@@ -3,11 +3,11 @@
3
3
  *
4
4
  * Types for CI/CD validation checks with support for multiple output formats.
5
5
  */
6
- import type { ContractsrcConfig } from '@contractspec/lib.contracts-spec/workspace-config';
6
+ import type { ContractsrcConfig, ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec/workspace-config';
7
7
  /**
8
8
  * Categories of CI checks.
9
9
  */
10
- export type CICheckCategory = 'structure' | 'integrity' | 'deps' | 'doctor' | 'handlers' | 'tests' | 'test-refs' | 'coverage' | 'implementation' | 'layers' | 'drift';
10
+ export type CICheckCategory = 'structure' | 'integrity' | 'deps' | 'doctor' | 'policy' | 'handlers' | 'tests' | 'test-refs' | 'coverage' | 'implementation' | 'layers' | 'drift';
11
11
  /**
12
12
  * All available CI check categories.
13
13
  */
@@ -123,7 +123,7 @@ export interface CICheckOptions {
123
123
  /**
124
124
  * Workspace configuration
125
125
  */
126
- config?: ContractsrcConfig;
126
+ config?: ContractsrcConfig | ResolvedContractsrcConfig;
127
127
  }
128
128
  /**
129
129
  * Output format for CI check results.
@@ -1,6 +1,7 @@
1
1
  /**
2
2
  * CI check utilities.
3
3
  */
4
+ import type { ContractsrcConfig } from '@contractspec/lib.contracts-spec/workspace-config';
4
5
  import type { FsAdapter } from '../../ports/fs';
5
6
  import type { CICheckCategory, CICheckCategorySummary, CIIssue } from './types';
6
7
  /**
@@ -24,4 +25,5 @@ export declare function getChecksToRun(options: {
24
25
  checkDrift?: boolean;
25
26
  checks?: CICheckCategory[];
26
27
  skip?: CICheckCategory[];
28
+ config?: ContractsrcConfig;
27
29
  }): CICheckCategory[];
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * Workspace configuration service.
3
3
  */
4
- import type { FsAdapter } from '../ports/fs';
5
4
  import { type ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec/workspace-config';
5
+ import type { FsAdapter } from '../ports/fs';
6
6
  /**
7
7
  * Load workspace configuration from .contractsrc.json.
8
8
  */
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * Generates specs and code using AI models.
5
5
  */
6
- import { type PresentationKind } from '@contractspec/module.workspace';
7
6
  import type { OpKind, ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec';
7
+ import { type PresentationKind } from '@contractspec/module.workspace';
8
8
  /**
9
9
  * AI Generator Service
10
10
  */
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * Unifies manual and AI-assisted spec creation.
5
5
  */
6
+ import type { ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec';
6
7
  import { AIGenerator } from './ai-generator';
7
8
  import * as templates from './templates';
8
- import type { ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec';
9
9
  export declare class SpecCreatorService {
10
10
  readonly ai: AIGenerator;
11
11
  readonly templates: typeof templates;
@@ -2,7 +2,7 @@
2
2
  * AI provider health checks.
3
3
  */
4
4
  import type { FsAdapter } from '../../../ports/fs';
5
- import type { CheckResult, CheckContext, DoctorPromptCallbacks } from '../types';
5
+ import type { CheckContext, CheckResult, DoctorPromptCallbacks } from '../types';
6
6
  /**
7
7
  * Run AI provider-related health checks.
8
8
  */
@@ -2,7 +2,7 @@
2
2
  * Configuration file health checks.
3
3
  */
4
4
  import type { FsAdapter } from '../../../ports/fs';
5
- import type { CheckResult, CheckContext } from '../types';
5
+ import type { CheckContext, CheckResult } from '../types';
6
6
  /**
7
7
  * Run configuration-related health checks.
8
8
  */
@@ -2,7 +2,7 @@
2
2
  * Dependencies health checks.
3
3
  */
4
4
  import type { FsAdapter } from '../../../ports/fs';
5
- import type { CheckResult, CheckContext } from '../types';
5
+ import type { CheckContext, CheckResult } from '../types';
6
6
  /**
7
7
  * Run dependency-related health checks.
8
8
  */
@@ -1,10 +1,10 @@
1
1
  /**
2
2
  * Health check modules.
3
3
  */
4
+ export { runAiChecks } from './ai';
4
5
  export { runCliChecks } from './cli';
5
6
  export { runConfigChecks } from './config';
6
- export { runMcpChecks } from './mcp';
7
7
  export { runDepsChecks } from './deps';
8
- export { runWorkspaceChecks } from './workspace';
9
- export { runAiChecks } from './ai';
10
8
  export { runLayerChecks } from './layers';
9
+ export { runMcpChecks } from './mcp';
10
+ export { runWorkspaceChecks } from './workspace';
@@ -2,7 +2,7 @@
2
2
  * MCP server health checks.
3
3
  */
4
4
  import type { FsAdapter } from '../../../ports/fs';
5
- import type { CheckResult, CheckContext } from '../types';
5
+ import type { CheckContext, CheckResult } from '../types';
6
6
  /**
7
7
  * Run MCP-related health checks.
8
8
  */
@@ -3,16 +3,37 @@
3
3
  *
4
4
  * Orchestrates health checks and applies fixes.
5
5
  */
6
+ import { findPackageRoot, findWorkspaceRoot, getPackageName, isMonorepo } from '../../adapters/workspace';
6
7
  import type { FsAdapter } from '../../ports/fs';
7
8
  import type { LoggerAdapter } from '../../ports/logger';
8
- import type { CheckResult, DoctorOptions, DoctorResult, DoctorPromptCallbacks } from './types';
9
+ import { runAiChecks, runCliChecks, runConfigChecks, runDepsChecks, runLayerChecks, runMcpChecks, runWorkspaceChecks } from './checks/index';
10
+ import type { CheckResult, DoctorOptions, DoctorPromptCallbacks, DoctorResult } from './types';
11
+ interface DoctorCheckRunners {
12
+ runCliChecks: typeof runCliChecks;
13
+ runConfigChecks: typeof runConfigChecks;
14
+ runMcpChecks: typeof runMcpChecks;
15
+ runDepsChecks: typeof runDepsChecks;
16
+ runWorkspaceChecks: typeof runWorkspaceChecks;
17
+ runAiChecks: typeof runAiChecks;
18
+ runLayerChecks: typeof runLayerChecks;
19
+ }
20
+ interface DoctorWorkspaceResolvers {
21
+ findWorkspaceRoot: typeof findWorkspaceRoot;
22
+ findPackageRoot: typeof findPackageRoot;
23
+ isMonorepo: typeof isMonorepo;
24
+ getPackageName: typeof getPackageName;
25
+ }
26
+ interface DoctorDependencies {
27
+ checks: DoctorCheckRunners;
28
+ workspace: DoctorWorkspaceResolvers;
29
+ }
9
30
  /**
10
31
  * Run all health checks and optionally apply fixes.
11
32
  */
12
33
  export declare function runDoctor(adapters: {
13
34
  fs: FsAdapter;
14
35
  logger: LoggerAdapter;
15
- }, options: DoctorOptions, prompts?: DoctorPromptCallbacks): Promise<DoctorResult>;
36
+ }, options: DoctorOptions, prompts?: DoctorPromptCallbacks, dependencies?: DoctorDependencies): Promise<DoctorResult>;
16
37
  /**
17
38
  * Get a summary string for the doctor result.
18
39
  */
@@ -21,3 +42,4 @@ export declare function formatDoctorSummary(result: DoctorResult): string;
21
42
  * Format a single check result for display.
22
43
  */
23
44
  export declare function formatCheckResult(result: CheckResult): string;
45
+ export {};
@@ -3,5 +3,5 @@
3
3
  *
4
4
  * Health checks and auto-fix for ContractSpec installations.
5
5
  */
6
- export * from './types';
7
6
  export * from './doctor-service';
7
+ export * from './types';
@@ -1,3 +1,3 @@
1
+ export * from './completion';
1
2
  export * from './feature-editor';
2
3
  export * from './validation';
3
- export * from './completion';
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * Generates links for external surfaces (CLI, VSCode, GitHub).
5
5
  */
6
- import type { FixLink, FixLinkOptions } from './types';
7
6
  import type { IntegrityIssue } from '../integrity';
7
+ import type { FixLink, FixLinkOptions } from './types';
8
8
  /**
9
9
  * Generate fix links for an issue.
10
10
  */
@@ -6,7 +6,7 @@
6
6
  import type { FsAdapter } from '../../ports/fs';
7
7
  import type { LoggerAdapter } from '../../ports/logger';
8
8
  import type { IntegrityIssue } from '../integrity';
9
- import { type BatchFixRequest, type BatchFixResult, type FixableIssue, type FixResult, type FixStrategyType, type FixOptions } from './types';
9
+ import { type BatchFixRequest, type BatchFixResult, type FixableIssue, type FixOptions, type FixResult, type FixStrategyType } from './types';
10
10
  /**
11
11
  * Service for fixing integrity issues.
12
12
  */
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * Format applicator service.
3
3
  */
4
- import type { FixOptions, FixResult } from './types';
5
4
  import type { LoggerAdapter } from '../../ports/logger';
5
+ import type { FixOptions, FixResult } from './types';
6
6
  /**
7
7
  * Apply formatting to the changed files in a fix result.
8
8
  */
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * Fix service exports.
3
3
  */
4
- export * from './types';
4
+ export * from './fix-link-formatter';
5
5
  export * from './fix-service';
6
6
  export * from './schemas';
7
- export * from './fix-link-formatter';
8
7
  export * from './strategies';
8
+ export * from './types';
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * Creates a spec with AI-generated content using experimental stability.
5
5
  */
6
- import type { FixableIssue, FixOptions, FixResult } from '../types';
7
6
  import type { FsAdapter } from '../../../ports/fs';
8
7
  import type { LoggerAdapter } from '../../../ports/logger';
8
+ import type { FixableIssue, FixOptions, FixResult } from '../types';
9
9
  /**
10
10
  * Create a spec with AI-generated content.
11
11
  *
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * Creates a minimal spec stub with in_creation stability.
5
5
  */
6
- import type { FixableIssue, FixOptions, FixResult } from '../types';
7
6
  import type { FsAdapter } from '../../../ports/fs';
7
+ import type { FixableIssue, FixOptions, FixResult } from '../types';
8
8
  /**
9
9
  * Create a skeleton spec for a missing reference.
10
10
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Fix strategy exports.
3
3
  */
4
- export { removeReferenceStrategy } from './remove-reference';
5
- export { implementSkeletonStrategy } from './implement-skeleton';
6
4
  export { implementAiStrategy } from './implement-ai';
5
+ export { implementSkeletonStrategy } from './implement-skeleton';
6
+ export { removeReferenceStrategy } from './remove-reference';
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * Removes a broken reference from a feature file.
5
5
  */
6
- import type { FixableIssue, FixOptions, FixResult } from '../types';
7
6
  import type { FsAdapter } from '../../../ports/fs';
7
+ import type { FixableIssue, FixOptions, FixResult } from '../types';
8
8
  /**
9
9
  * Remove a specific reference from a feature file.
10
10
  *
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * Types for fixing integrity issues found by CI checks.
5
5
  */
6
- import type { AnalyzedSpecType, RefInfo } from '@contractspec/module.workspace';
7
6
  import type { Stability } from '@contractspec/lib.contracts-spec';
7
+ import type { AnalyzedSpecType, RefInfo } from '@contractspec/module.workspace';
8
8
  import type { IntegrityIssue } from '../integrity';
9
9
  /**
10
10
  * Available fix strategies.
@@ -6,6 +6,6 @@ export interface FormatterOptions {
6
6
  cwd?: string;
7
7
  }
8
8
  /**
9
- * Format files using the configured formatter (defaulting to prettier).
9
+ * Format files using the configured formatter (defaulting to Biome).
10
10
  */
11
11
  export declare function formatFiles(files: string[], _configResolver?: unknown, options?: FormatterOptions): Promise<void>;
@@ -3,5 +3,5 @@
3
3
  *
4
4
  * Provides hook execution for git hooks configured in .contractsrc.json.
5
5
  */
6
+ export { getAvailableHooks, runHook } from './hooks-service';
6
7
  export * from './types';
7
- export { runHook, getAvailableHooks } from './hooks-service';
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Impact detection service module.
3
3
  */
4
- export * from './types';
4
+ export { formatCheckRun, formatJson, formatMinimalComment, formatPrComment, } from './formatters';
5
5
  export { detectImpact } from './impact-detection-service';
6
- export { formatPrComment, formatMinimalComment, formatCheckRun, formatJson, } from './formatters';
6
+ export * from './types';
@@ -4,8 +4,8 @@
4
4
  * Scans workspace files to find implementations that reference specs.
5
5
  * Uses regex-based pattern matching for performance (avoids full AST parsing).
6
6
  */
7
- import type { FsAdapter } from '../../ports/fs';
8
7
  import type { ImplementationType } from '@contractspec/lib.contracts-spec';
8
+ import type { FsAdapter } from '../../ports/fs';
9
9
  import type { DiscoveryOptions, SpecReferenceMatch } from './types';
10
10
  /**
11
11
  * Infer implementation type from file path.
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Implementation tracking and discovery services.
3
3
  */
4
- export * from './types';
5
4
  export * from './discovery';
6
5
  export * from './resolver';
6
+ export * from './types';
@@ -6,13 +6,13 @@
6
6
  * 2. Auto-discovered references from workspace scanning
7
7
  * 3. Convention-based paths (naming conventions)
8
8
  */
9
- import type { SpecScanResult } from '@contractspec/module.workspace';
10
9
  import type { ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec';
10
+ import type { SpecScanResult } from '@contractspec/module.workspace';
11
+ import type { Ora } from 'ora';
11
12
  import type { FsAdapter } from '../../../ports/fs';
12
13
  import type { ResolverOptions, SpecImplementationResult } from '../types';
13
- import type { Ora } from 'ora';
14
- export * from './parsers';
15
14
  export * from './conventions';
15
+ export * from './parsers';
16
16
  export * from './status';
17
17
  /**
18
18
  * Resolve all implementations for a spec file.
@@ -3,11 +3,11 @@
3
3
  *
4
4
  * Integrates source extraction into the workspace bundle.
5
5
  */
6
- import type { FsAdapter } from '../../ports/fs';
7
- import type { LoggerAdapter } from '../../ports/logger';
8
6
  import type { ResolvedContractsrcConfig } from '@contractspec/lib.contracts-spec';
9
7
  import { type ImportIR } from '@contractspec/lib.source-extractors';
10
8
  import { type GenerationResult } from '@contractspec/lib.source-extractors/codegen';
9
+ import type { FsAdapter } from '../../ports/fs';
10
+ import type { LoggerAdapter } from '../../ports/logger';
11
11
  /**
12
12
  * Options for the import service.
13
13
  */
@@ -3,6 +3,6 @@
3
3
  *
4
4
  * Exports the import service for extracting contracts from source code.
5
5
  */
6
- export { importFromSourceService, type ImportServiceOptions, type ImportServiceResult, type ImportServiceAdapters, } from './import-service';
7
- export { verifyImportedContracts, type VerifyOptions as ImportVerifyOptions, type VerifyResult as ImportVerifyResult, type EndpointVerification, type VerificationIssue as ImportVerificationIssue, } from './verify-service';
8
- export { generateMarkdownReport, generateCliReport, type ReportOptions, } from './report-service';
6
+ export { type ImportServiceAdapters, type ImportServiceOptions, type ImportServiceResult, importFromSourceService, } from './import-service';
7
+ export { generateCliReport, generateMarkdownReport, type ReportOptions, } from './report-service';
8
+ export { type EndpointVerification, type VerificationIssue as ImportVerificationIssue, type VerifyOptions as ImportVerifyOptions, type VerifyResult as ImportVerifyResult, verifyImportedContracts, } from './verify-service';
@@ -3,7 +3,7 @@
3
3
  *
4
4
  * Validates extracted contracts against existing codebase and specs.
5
5
  */
6
- import type { ImportIR, EndpointCandidate, Ambiguity } from '@contractspec/lib.source-extractors';
6
+ import type { Ambiguity, EndpointCandidate, ImportIR } from '@contractspec/lib.source-extractors';
7
7
  import type { FsAdapter } from '../../ports/fs';
8
8
  import type { LoggerAdapter } from '../../ports/logger';
9
9
  /**
@@ -1,50 +1,50 @@
1
1
  /**
2
2
  * Workspace services (use-cases).
3
3
  */
4
- export * from './validate/index';
5
- export * as features from './features';
6
- export * from './diff';
7
- export * from './deps';
8
- export * from './list';
9
- export * from './config';
4
+ export * from './action-drift/index';
5
+ export * from './action-pr';
6
+ export * from './agent-guide/index';
10
7
  export * from './build';
11
- export * from './openapi/index';
12
- export * from './registry';
13
- export * from './sync';
14
- export * from './watch';
8
+ export * from './ci-check/index';
15
9
  export * from './clean';
16
- export * from './test';
17
- export * from './regenerator';
18
- export * from './workspace-info';
10
+ export * from './config';
11
+ export * from './create/index';
12
+ export * from './delete';
13
+ export * from './deps';
14
+ export * from './diff';
15
+ export * from './docs/index';
16
+ export * from './doctor/index';
17
+ export * from './extract';
18
+ export * as features from './features';
19
+ export * as fix from './fix';
20
+ export * from './formatter';
21
+ export * from './gap';
22
+ export * from './generate-artifacts';
23
+ export * as hooks from './hooks/index';
24
+ export * as impact from './impact/index';
25
+ export * from './implementation/index';
26
+ export * from './import/index';
19
27
  export * from './integrity';
20
28
  export * from './integrity-diagram';
21
29
  export * from './layer-discovery';
22
- export * from './setup/index';
23
- export * from './doctor/index';
24
- export * from './action-pr';
25
- export * from './ci-check/index';
26
- export * from './agent-guide/index';
30
+ export * from './list';
27
31
  export * from './llm/index';
28
- export * from './create/index';
29
- export * from './verify/index';
30
- export * from './implementation/index';
31
- export * from './verification-cache/index';
32
+ export * from './openapi/index';
32
33
  export * from './quickstart/index';
33
- export * from './docs/index';
34
- export * as impact from './impact/index';
35
- export * from './formatter';
36
- export * from './action-drift/index';
34
+ export * from './regenerator';
35
+ export * from './registry';
36
+ export * from './rulesync';
37
+ export * from './setup/index';
38
+ export * from './sync';
39
+ export * from './test';
40
+ export * from './update';
41
+ export * as upgrade from './upgrade/index';
42
+ export * from './validate/index';
43
+ export * from './verification-cache/index';
44
+ export * from './verify/index';
37
45
  export * as versioning from './versioning/index';
38
46
  export type { SpecVersionAnalysis } from './versioning/types';
39
- export * as upgrade from './upgrade/index';
40
- export * as hooks from './hooks/index';
41
- export * from './rulesync';
42
- export * as fix from './fix';
43
- export * from './view/index';
44
- export * from './gap';
45
- export * from './generate-artifacts';
46
- export * from './extract';
47
47
  export * as vibe from './vibe/index';
48
- export * from './import/index';
49
- export * from './update';
50
- export * from './delete';
48
+ export * from './view/index';
49
+ export * from './watch';
50
+ export * from './workspace-info';
@@ -7,7 +7,7 @@
7
7
  * - App Configs (*.app-config.ts, *.blueprint.ts)
8
8
  * - Workspace Config (.contractsrc.json)
9
9
  */
10
- import { type FeatureScanResult, type ExampleScanResult, type SpecScanResult } from '@contractspec/module.workspace';
10
+ import { type ExampleScanResult, type FeatureScanResult, type SpecScanResult } from '@contractspec/module.workspace';
11
11
  import type { FsAdapter } from '../ports/fs';
12
12
  import type { LoggerAdapter } from '../ports/logger';
13
13
  /**