audit-tools 0.28.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/README.audit.md +223 -0
- package/README.md +42 -0
- package/README.remediate.md +113 -0
- package/audit-code-wrapper-build.mjs +185 -0
- package/audit-code-wrapper-install-hosts.mjs +1079 -0
- package/audit-code-wrapper-install-renderers.mjs +58 -0
- package/audit-code-wrapper-io.mjs +155 -0
- package/audit-code-wrapper-legacy.mjs +125 -0
- package/audit-code-wrapper-lib.mjs +314 -0
- package/audit-code-wrapper-opencode.mjs +241 -0
- package/audit-code.mjs +12 -0
- package/dispatch/lens-definitions.json +46 -0
- package/dispatch/merge-results.mjs +110 -0
- package/dispatch/validate-result.mjs +59 -0
- package/dispatch/validate.mjs +16 -0
- package/dist/audit/adapters/coverageSummary.d.ts +9 -0
- package/dist/audit/adapters/coverageSummary.d.ts.map +1 -0
- package/dist/audit/adapters/coverageSummary.js +18 -0
- package/dist/audit/adapters/coverageSummary.js.map +1 -0
- package/dist/audit/adapters/eslint.d.ts +14 -0
- package/dist/audit/adapters/eslint.d.ts.map +1 -0
- package/dist/audit/adapters/eslint.js +28 -0
- package/dist/audit/adapters/eslint.js.map +1 -0
- package/dist/audit/adapters/normalizeExternal.d.ts +13 -0
- package/dist/audit/adapters/normalizeExternal.d.ts.map +1 -0
- package/dist/audit/adapters/normalizeExternal.js +44 -0
- package/dist/audit/adapters/normalizeExternal.js.map +1 -0
- package/dist/audit/adapters/npmAudit.d.ts +16 -0
- package/dist/audit/adapters/npmAudit.d.ts.map +1 -0
- package/dist/audit/adapters/npmAudit.js +24 -0
- package/dist/audit/adapters/npmAudit.js.map +1 -0
- package/dist/audit/adapters/semgrep.d.ts +23 -0
- package/dist/audit/adapters/semgrep.d.ts.map +1 -0
- package/dist/audit/adapters/semgrep.js +40 -0
- package/dist/audit/adapters/semgrep.js.map +1 -0
- package/dist/audit/cli/advanceAuditCommand.d.ts +2 -0
- package/dist/audit/cli/advanceAuditCommand.d.ts.map +1 -0
- package/dist/audit/cli/advanceAuditCommand.js +95 -0
- package/dist/audit/cli/advanceAuditCommand.js.map +1 -0
- package/dist/audit/cli/args.d.ts +95 -0
- package/dist/audit/cli/args.d.ts.map +1 -0
- package/dist/audit/cli/args.js +274 -0
- package/dist/audit/cli/args.js.map +1 -0
- package/dist/audit/cli/auditStep.d.ts +34 -0
- package/dist/audit/cli/auditStep.d.ts.map +1 -0
- package/dist/audit/cli/auditStep.js +162 -0
- package/dist/audit/cli/auditStep.js.map +1 -0
- package/dist/audit/cli/cleanup.d.ts +12 -0
- package/dist/audit/cli/cleanup.d.ts.map +1 -0
- package/dist/audit/cli/cleanup.js +44 -0
- package/dist/audit/cli/cleanup.js.map +1 -0
- package/dist/audit/cli/cleanupCommand.d.ts +2 -0
- package/dist/audit/cli/cleanupCommand.d.ts.map +1 -0
- package/dist/audit/cli/cleanupCommand.js +25 -0
- package/dist/audit/cli/cleanupCommand.js.map +1 -0
- package/dist/audit/cli/conceptualDispatch.d.ts +74 -0
- package/dist/audit/cli/conceptualDispatch.d.ts.map +1 -0
- package/dist/audit/cli/conceptualDispatch.js +118 -0
- package/dist/audit/cli/conceptualDispatch.js.map +1 -0
- package/dist/audit/cli/confirmIntentStep.d.ts +25 -0
- package/dist/audit/cli/confirmIntentStep.d.ts.map +1 -0
- package/dist/audit/cli/confirmIntentStep.js +210 -0
- package/dist/audit/cli/confirmIntentStep.js.map +1 -0
- package/dist/audit/cli/dispatch/packetFilter.d.ts +102 -0
- package/dist/audit/cli/dispatch/packetFilter.d.ts.map +1 -0
- package/dist/audit/cli/dispatch/packetFilter.js +148 -0
- package/dist/audit/cli/dispatch/packetFilter.js.map +1 -0
- package/dist/audit/cli/dispatch/packetPrompt.d.ts +48 -0
- package/dist/audit/cli/dispatch/packetPrompt.d.ts.map +1 -0
- package/dist/audit/cli/dispatch/packetPrompt.js +258 -0
- package/dist/audit/cli/dispatch/packetPrompt.js.map +1 -0
- package/dist/audit/cli/dispatch/paths.d.ts +7 -0
- package/dist/audit/cli/dispatch/paths.d.ts.map +1 -0
- package/dist/audit/cli/dispatch/paths.js +38 -0
- package/dist/audit/cli/dispatch/paths.js.map +1 -0
- package/dist/audit/cli/dispatch/quotaPool.d.ts +75 -0
- package/dist/audit/cli/dispatch/quotaPool.d.ts.map +1 -0
- package/dist/audit/cli/dispatch/quotaPool.js +163 -0
- package/dist/audit/cli/dispatch/quotaPool.js.map +1 -0
- package/dist/audit/cli/dispatch/tierRouting.d.ts +36 -0
- package/dist/audit/cli/dispatch/tierRouting.d.ts.map +1 -0
- package/dist/audit/cli/dispatch/tierRouting.js +121 -0
- package/dist/audit/cli/dispatch/tierRouting.js.map +1 -0
- package/dist/audit/cli/dispatch/types.d.ts +90 -0
- package/dist/audit/cli/dispatch/types.d.ts.map +1 -0
- package/dist/audit/cli/dispatch/types.js +15 -0
- package/dist/audit/cli/dispatch/types.js.map +1 -0
- package/dist/audit/cli/dispatch.d.ts +29 -0
- package/dist/audit/cli/dispatch.d.ts.map +1 -0
- package/dist/audit/cli/dispatch.js +303 -0
- package/dist/audit/cli/dispatch.js.map +1 -0
- package/dist/audit/cli/dispatchStatusCommand.d.ts +2 -0
- package/dist/audit/cli/dispatchStatusCommand.d.ts.map +1 -0
- package/dist/audit/cli/dispatchStatusCommand.js +81 -0
- package/dist/audit/cli/dispatchStatusCommand.js.map +1 -0
- package/dist/audit/cli/envelope.d.ts +50 -0
- package/dist/audit/cli/envelope.d.ts.map +1 -0
- package/dist/audit/cli/envelope.js +69 -0
- package/dist/audit/cli/envelope.js.map +1 -0
- package/dist/audit/cli/explainTaskCommand.d.ts +2 -0
- package/dist/audit/cli/explainTaskCommand.d.ts.map +1 -0
- package/dist/audit/cli/explainTaskCommand.js +34 -0
- package/dist/audit/cli/explainTaskCommand.js.map +1 -0
- package/dist/audit/cli/importExternalAnalyzerCommand.d.ts +2 -0
- package/dist/audit/cli/importExternalAnalyzerCommand.d.ts.map +1 -0
- package/dist/audit/cli/importExternalAnalyzerCommand.js +25 -0
- package/dist/audit/cli/importExternalAnalyzerCommand.js.map +1 -0
- package/dist/audit/cli/ingestResultsCommand.d.ts +2 -0
- package/dist/audit/cli/ingestResultsCommand.d.ts.map +1 -0
- package/dist/audit/cli/ingestResultsCommand.js +42 -0
- package/dist/audit/cli/ingestResultsCommand.js.map +1 -0
- package/dist/audit/cli/intakeCommand.d.ts +2 -0
- package/dist/audit/cli/intakeCommand.d.ts.map +1 -0
- package/dist/audit/cli/intakeCommand.js +18 -0
- package/dist/audit/cli/intakeCommand.js.map +1 -0
- package/dist/audit/cli/lineIndex.d.ts +5 -0
- package/dist/audit/cli/lineIndex.d.ts.map +1 -0
- package/dist/audit/cli/lineIndex.js +70 -0
- package/dist/audit/cli/lineIndex.js.map +1 -0
- package/dist/audit/cli/mergeAndIngestCommand.d.ts +46 -0
- package/dist/audit/cli/mergeAndIngestCommand.d.ts.map +1 -0
- package/dist/audit/cli/mergeAndIngestCommand.js +541 -0
- package/dist/audit/cli/mergeAndIngestCommand.js.map +1 -0
- package/dist/audit/cli/nextStepCommand.d.ts +22 -0
- package/dist/audit/cli/nextStepCommand.d.ts.map +1 -0
- package/dist/audit/cli/nextStepCommand.js +531 -0
- package/dist/audit/cli/nextStepCommand.js.map +1 -0
- package/dist/audit/cli/nextStepHelpers.d.ts +303 -0
- package/dist/audit/cli/nextStepHelpers.d.ts.map +1 -0
- package/dist/audit/cli/nextStepHelpers.js +861 -0
- package/dist/audit/cli/nextStepHelpers.js.map +1 -0
- package/dist/audit/cli/paths.d.ts +2 -0
- package/dist/audit/cli/paths.d.ts.map +1 -0
- package/dist/audit/cli/paths.js +10 -0
- package/dist/audit/cli/paths.js.map +1 -0
- package/dist/audit/cli/planCommand.d.ts +2 -0
- package/dist/audit/cli/planCommand.d.ts.map +1 -0
- package/dist/audit/cli/planCommand.js +17 -0
- package/dist/audit/cli/planCommand.js.map +1 -0
- package/dist/audit/cli/prepareDispatchCommand.d.ts +2 -0
- package/dist/audit/cli/prepareDispatchCommand.d.ts.map +1 -0
- package/dist/audit/cli/prepareDispatchCommand.js +37 -0
- package/dist/audit/cli/prepareDispatchCommand.js.map +1 -0
- package/dist/audit/cli/prompts.d.ts +54 -0
- package/dist/audit/cli/prompts.d.ts.map +1 -0
- package/dist/audit/cli/prompts.js +324 -0
- package/dist/audit/cli/prompts.js.map +1 -0
- package/dist/audit/cli/quotaCommand.d.ts +2 -0
- package/dist/audit/cli/quotaCommand.d.ts.map +1 -0
- package/dist/audit/cli/quotaCommand.js +64 -0
- package/dist/audit/cli/quotaCommand.js.map +1 -0
- package/dist/audit/cli/requeueCommand.d.ts +2 -0
- package/dist/audit/cli/requeueCommand.d.ts.map +1 -0
- package/dist/audit/cli/requeueCommand.js +11 -0
- package/dist/audit/cli/requeueCommand.js.map +1 -0
- package/dist/audit/cli/resynthesizeCommand.d.ts +2 -0
- package/dist/audit/cli/resynthesizeCommand.d.ts.map +1 -0
- package/dist/audit/cli/resynthesizeCommand.js +57 -0
- package/dist/audit/cli/resynthesizeCommand.js.map +1 -0
- package/dist/audit/cli/reviewRun.d.ts +57 -0
- package/dist/audit/cli/reviewRun.d.ts.map +1 -0
- package/dist/audit/cli/reviewRun.js +180 -0
- package/dist/audit/cli/reviewRun.js.map +1 -0
- package/dist/audit/cli/rollingAuditDispatch.d.ts +119 -0
- package/dist/audit/cli/rollingAuditDispatch.d.ts.map +1 -0
- package/dist/audit/cli/rollingAuditDispatch.js +264 -0
- package/dist/audit/cli/rollingAuditDispatch.js.map +1 -0
- package/dist/audit/cli/sampleRunCommand.d.ts +2 -0
- package/dist/audit/cli/sampleRunCommand.d.ts.map +1 -0
- package/dist/audit/cli/sampleRunCommand.js +106 -0
- package/dist/audit/cli/sampleRunCommand.js.map +1 -0
- package/dist/audit/cli/semanticReviewStep.d.ts +23 -0
- package/dist/audit/cli/semanticReviewStep.d.ts.map +1 -0
- package/dist/audit/cli/semanticReviewStep.js +123 -0
- package/dist/audit/cli/semanticReviewStep.js.map +1 -0
- package/dist/audit/cli/statusCommand.d.ts +2 -0
- package/dist/audit/cli/statusCommand.d.ts.map +1 -0
- package/dist/audit/cli/statusCommand.js +133 -0
- package/dist/audit/cli/statusCommand.js.map +1 -0
- package/dist/audit/cli/steps.d.ts +204 -0
- package/dist/audit/cli/steps.d.ts.map +1 -0
- package/dist/audit/cli/steps.js +105 -0
- package/dist/audit/cli/steps.js.map +1 -0
- package/dist/audit/cli/submitPacketCommand.d.ts +2 -0
- package/dist/audit/cli/submitPacketCommand.d.ts.map +1 -0
- package/dist/audit/cli/submitPacketCommand.js +126 -0
- package/dist/audit/cli/submitPacketCommand.js.map +1 -0
- package/dist/audit/cli/synthesizeCommand.d.ts +2 -0
- package/dist/audit/cli/synthesizeCommand.d.ts.map +1 -0
- package/dist/audit/cli/synthesizeCommand.js +16 -0
- package/dist/audit/cli/synthesizeCommand.js.map +1 -0
- package/dist/audit/cli/updateRuntimeValidationCommand.d.ts +2 -0
- package/dist/audit/cli/updateRuntimeValidationCommand.d.ts.map +1 -0
- package/dist/audit/cli/updateRuntimeValidationCommand.js +17 -0
- package/dist/audit/cli/updateRuntimeValidationCommand.js.map +1 -0
- package/dist/audit/cli/validateCommand.d.ts +2 -0
- package/dist/audit/cli/validateCommand.d.ts.map +1 -0
- package/dist/audit/cli/validateCommand.js +42 -0
- package/dist/audit/cli/validateCommand.js.map +1 -0
- package/dist/audit/cli/validateResultCommand.d.ts +2 -0
- package/dist/audit/cli/validateResultCommand.d.ts.map +1 -0
- package/dist/audit/cli/validateResultCommand.js +92 -0
- package/dist/audit/cli/validateResultCommand.js.map +1 -0
- package/dist/audit/cli/validateResultsCommand.d.ts +2 -0
- package/dist/audit/cli/validateResultsCommand.d.ts.map +1 -0
- package/dist/audit/cli/validateResultsCommand.js +32 -0
- package/dist/audit/cli/validateResultsCommand.js.map +1 -0
- package/dist/audit/cli/waveManifest.d.ts +41 -0
- package/dist/audit/cli/waveManifest.d.ts.map +1 -0
- package/dist/audit/cli/waveManifest.js +42 -0
- package/dist/audit/cli/waveManifest.js.map +1 -0
- package/dist/audit/cli/workerResult.d.ts +19 -0
- package/dist/audit/cli/workerResult.d.ts.map +1 -0
- package/dist/audit/cli/workerResult.js +43 -0
- package/dist/audit/cli/workerResult.js.map +1 -0
- package/dist/audit/cli/workerRunCommand.d.ts +16 -0
- package/dist/audit/cli/workerRunCommand.d.ts.map +1 -0
- package/dist/audit/cli/workerRunCommand.js +132 -0
- package/dist/audit/cli/workerRunCommand.js.map +1 -0
- package/dist/audit/cli.d.ts +21 -0
- package/dist/audit/cli.d.ts.map +1 -0
- package/dist/audit/cli.js +137 -0
- package/dist/audit/cli.js.map +1 -0
- package/dist/audit/contracts/workerSchemas.d.ts +1448 -0
- package/dist/audit/contracts/workerSchemas.d.ts.map +1 -0
- package/dist/audit/contracts/workerSchemas.js +117 -0
- package/dist/audit/contracts/workerSchemas.js.map +1 -0
- package/dist/audit/contracts/wrapperResponse.d.ts +316 -0
- package/dist/audit/contracts/wrapperResponse.d.ts.map +1 -0
- package/dist/audit/contracts/wrapperResponse.js +96 -0
- package/dist/audit/contracts/wrapperResponse.js.map +1 -0
- package/dist/audit/coverage.d.ts +11 -0
- package/dist/audit/coverage.d.ts.map +1 -0
- package/dist/audit/coverage.js +78 -0
- package/dist/audit/coverage.js.map +1 -0
- package/dist/audit/extractors/analyzers/css.d.ts +3 -0
- package/dist/audit/extractors/analyzers/css.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/css.js +102 -0
- package/dist/audit/extractors/analyzers/css.js.map +1 -0
- package/dist/audit/extractors/analyzers/html.d.ts +3 -0
- package/dist/audit/extractors/analyzers/html.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/html.js +93 -0
- package/dist/audit/extractors/analyzers/html.js.map +1 -0
- package/dist/audit/extractors/analyzers/merge.d.ts +15 -0
- package/dist/audit/extractors/analyzers/merge.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/merge.js +86 -0
- package/dist/audit/extractors/analyzers/merge.js.map +1 -0
- package/dist/audit/extractors/analyzers/python.d.ts +3 -0
- package/dist/audit/extractors/analyzers/python.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/python.js +105 -0
- package/dist/audit/extractors/analyzers/python.js.map +1 -0
- package/dist/audit/extractors/analyzers/registry.d.ts +34 -0
- package/dist/audit/extractors/analyzers/registry.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/registry.js +82 -0
- package/dist/audit/extractors/analyzers/registry.js.map +1 -0
- package/dist/audit/extractors/analyzers/resourceUrl.d.ts +8 -0
- package/dist/audit/extractors/analyzers/resourceUrl.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/resourceUrl.js +26 -0
- package/dist/audit/extractors/analyzers/resourceUrl.js.map +1 -0
- package/dist/audit/extractors/analyzers/sql.d.ts +3 -0
- package/dist/audit/extractors/analyzers/sql.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/sql.js +23 -0
- package/dist/audit/extractors/analyzers/sql.js.map +1 -0
- package/dist/audit/extractors/analyzers/treeSitter.d.ts +44 -0
- package/dist/audit/extractors/analyzers/treeSitter.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/treeSitter.js +148 -0
- package/dist/audit/extractors/analyzers/treeSitter.js.map +1 -0
- package/dist/audit/extractors/analyzers/types.d.ts +54 -0
- package/dist/audit/extractors/analyzers/types.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/types.js +2 -0
- package/dist/audit/extractors/analyzers/types.js.map +1 -0
- package/dist/audit/extractors/analyzers/typescript.d.ts +3 -0
- package/dist/audit/extractors/analyzers/typescript.d.ts.map +1 -0
- package/dist/audit/extractors/analyzers/typescript.js +279 -0
- package/dist/audit/extractors/analyzers/typescript.js.map +1 -0
- package/dist/audit/extractors/browserExtension.d.ts +12 -0
- package/dist/audit/extractors/browserExtension.d.ts.map +1 -0
- package/dist/audit/extractors/browserExtension.js +388 -0
- package/dist/audit/extractors/browserExtension.js.map +1 -0
- package/dist/audit/extractors/bucketing.d.ts +12 -0
- package/dist/audit/extractors/bucketing.d.ts.map +1 -0
- package/dist/audit/extractors/bucketing.js +56 -0
- package/dist/audit/extractors/bucketing.js.map +1 -0
- package/dist/audit/extractors/designAssessment.d.ts +10 -0
- package/dist/audit/extractors/designAssessment.d.ts.map +1 -0
- package/dist/audit/extractors/designAssessment.js +280 -0
- package/dist/audit/extractors/designAssessment.js.map +1 -0
- package/dist/audit/extractors/disposition.d.ts +76 -0
- package/dist/audit/extractors/disposition.d.ts.map +1 -0
- package/dist/audit/extractors/disposition.js +265 -0
- package/dist/audit/extractors/disposition.js.map +1 -0
- package/dist/audit/extractors/fileInventory.d.ts +8 -0
- package/dist/audit/extractors/fileInventory.d.ts.map +1 -0
- package/dist/audit/extractors/fileInventory.js +36 -0
- package/dist/audit/extractors/fileInventory.js.map +1 -0
- package/dist/audit/extractors/flows.d.ts +9 -0
- package/dist/audit/extractors/flows.d.ts.map +1 -0
- package/dist/audit/extractors/flows.js +111 -0
- package/dist/audit/extractors/flows.js.map +1 -0
- package/dist/audit/extractors/fsIntake.d.ts +9 -0
- package/dist/audit/extractors/fsIntake.d.ts.map +1 -0
- package/dist/audit/extractors/fsIntake.js +95 -0
- package/dist/audit/extractors/fsIntake.js.map +1 -0
- package/dist/audit/extractors/graph.d.ts +11 -0
- package/dist/audit/extractors/graph.d.ts.map +1 -0
- package/dist/audit/extractors/graph.js +472 -0
- package/dist/audit/extractors/graph.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/cargo.d.ts +15 -0
- package/dist/audit/extractors/graphManifestEdges/cargo.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/cargo.js +74 -0
- package/dist/audit/extractors/graphManifestEdges/cargo.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/go.d.ts +6 -0
- package/dist/audit/extractors/graphManifestEdges/go.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/go.js +152 -0
- package/dist/audit/extractors/graphManifestEdges/go.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/index.d.ts +9 -0
- package/dist/audit/extractors/graphManifestEdges/index.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/index.js +12 -0
- package/dist/audit/extractors/graphManifestEdges/index.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/jsonc.d.ts +4 -0
- package/dist/audit/extractors/graphManifestEdges/jsonc.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/jsonc.js +98 -0
- package/dist/audit/extractors/graphManifestEdges/jsonc.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/maven.d.ts +4 -0
- package/dist/audit/extractors/graphManifestEdges/maven.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/maven.js +74 -0
- package/dist/audit/extractors/graphManifestEdges/maven.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/packageJson.d.ts +20 -0
- package/dist/audit/extractors/graphManifestEdges/packageJson.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/packageJson.js +205 -0
- package/dist/audit/extractors/graphManifestEdges/packageJson.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/pnpm.d.ts +10 -0
- package/dist/audit/extractors/graphManifestEdges/pnpm.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/pnpm.js +18 -0
- package/dist/audit/extractors/graphManifestEdges/pnpm.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/pyproject.d.ts +4 -0
- package/dist/audit/extractors/graphManifestEdges/pyproject.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/pyproject.js +45 -0
- package/dist/audit/extractors/graphManifestEdges/pyproject.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/toml.d.ts +25 -0
- package/dist/audit/extractors/graphManifestEdges/toml.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/toml.js +49 -0
- package/dist/audit/extractors/graphManifestEdges/toml.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/typescript.d.ts +4 -0
- package/dist/audit/extractors/graphManifestEdges/typescript.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/typescript.js +57 -0
- package/dist/audit/extractors/graphManifestEdges/typescript.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/workspace.d.ts +11 -0
- package/dist/audit/extractors/graphManifestEdges/workspace.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/workspace.js +73 -0
- package/dist/audit/extractors/graphManifestEdges/workspace.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/yaml.d.ts +24 -0
- package/dist/audit/extractors/graphManifestEdges/yaml.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/yaml.js +57 -0
- package/dist/audit/extractors/graphManifestEdges/yaml.js.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/yamlPaths.d.ts +5 -0
- package/dist/audit/extractors/graphManifestEdges/yamlPaths.d.ts.map +1 -0
- package/dist/audit/extractors/graphManifestEdges/yamlPaths.js +75 -0
- package/dist/audit/extractors/graphManifestEdges/yamlPaths.js.map +1 -0
- package/dist/audit/extractors/graphPathUtils.d.ts +34 -0
- package/dist/audit/extractors/graphPathUtils.d.ts.map +1 -0
- package/dist/audit/extractors/graphPathUtils.js +174 -0
- package/dist/audit/extractors/graphPathUtils.js.map +1 -0
- package/dist/audit/extractors/graphPythonImports.d.ts +19 -0
- package/dist/audit/extractors/graphPythonImports.d.ts.map +1 -0
- package/dist/audit/extractors/graphPythonImports.js +318 -0
- package/dist/audit/extractors/graphPythonImports.js.map +1 -0
- package/dist/audit/extractors/graphRoutes.d.ts +13 -0
- package/dist/audit/extractors/graphRoutes.d.ts.map +1 -0
- package/dist/audit/extractors/graphRoutes.js +447 -0
- package/dist/audit/extractors/graphRoutes.js.map +1 -0
- package/dist/audit/extractors/graphSuites.d.ts +5 -0
- package/dist/audit/extractors/graphSuites.d.ts.map +1 -0
- package/dist/audit/extractors/graphSuites.js +248 -0
- package/dist/audit/extractors/graphSuites.js.map +1 -0
- package/dist/audit/extractors/graphTestSources.d.ts +3 -0
- package/dist/audit/extractors/graphTestSources.d.ts.map +1 -0
- package/dist/audit/extractors/graphTestSources.js +103 -0
- package/dist/audit/extractors/graphTestSources.js.map +1 -0
- package/dist/audit/extractors/ignore.d.ts +2 -0
- package/dist/audit/extractors/ignore.d.ts.map +1 -0
- package/dist/audit/extractors/ignore.js +18 -0
- package/dist/audit/extractors/ignore.js.map +1 -0
- package/dist/audit/extractors/languageMap.generated.d.ts +2 -0
- package/dist/audit/extractors/languageMap.generated.d.ts.map +1 -0
- package/dist/audit/extractors/languageMap.generated.js +1456 -0
- package/dist/audit/extractors/languageMap.generated.js.map +1 -0
- package/dist/audit/extractors/pathPatterns.d.ts +55 -0
- package/dist/audit/extractors/pathPatterns.d.ts.map +1 -0
- package/dist/audit/extractors/pathPatterns.js +303 -0
- package/dist/audit/extractors/pathPatterns.js.map +1 -0
- package/dist/audit/extractors/risk.d.ts +5 -0
- package/dist/audit/extractors/risk.d.ts.map +1 -0
- package/dist/audit/extractors/risk.js +54 -0
- package/dist/audit/extractors/risk.js.map +1 -0
- package/dist/audit/extractors/surfaces.d.ts +10 -0
- package/dist/audit/extractors/surfaces.d.ts.map +1 -0
- package/dist/audit/extractors/surfaces.js +49 -0
- package/dist/audit/extractors/surfaces.js.map +1 -0
- package/dist/audit/index.d.ts +2 -0
- package/dist/audit/index.d.ts.map +1 -0
- package/dist/audit/index.js +3 -0
- package/dist/audit/index.js.map +1 -0
- package/dist/audit/io/artifacts.d.ts +152 -0
- package/dist/audit/io/artifacts.d.ts.map +1 -0
- package/dist/audit/io/artifacts.js +239 -0
- package/dist/audit/io/artifacts.js.map +1 -0
- package/dist/audit/io/runArtifactTypes.d.ts +19 -0
- package/dist/audit/io/runArtifactTypes.d.ts.map +1 -0
- package/dist/audit/io/runArtifactTypes.js +2 -0
- package/dist/audit/io/runArtifactTypes.js.map +1 -0
- package/dist/audit/io/runArtifacts.d.ts +33 -0
- package/dist/audit/io/runArtifacts.d.ts.map +1 -0
- package/dist/audit/io/runArtifacts.js +254 -0
- package/dist/audit/io/runArtifacts.js.map +1 -0
- package/dist/audit/io/toolingManifest.d.ts +4 -0
- package/dist/audit/io/toolingManifest.d.ts.map +1 -0
- package/dist/audit/io/toolingManifest.js +79 -0
- package/dist/audit/io/toolingManifest.js.map +1 -0
- package/dist/audit/orchestrator/advance.d.ts +5 -0
- package/dist/audit/orchestrator/advance.d.ts.map +1 -0
- package/dist/audit/orchestrator/advance.js +172 -0
- package/dist/audit/orchestrator/advance.js.map +1 -0
- package/dist/audit/orchestrator/advanceTypes.d.ts +50 -0
- package/dist/audit/orchestrator/advanceTypes.d.ts.map +1 -0
- package/dist/audit/orchestrator/advanceTypes.js +2 -0
- package/dist/audit/orchestrator/advanceTypes.js.map +1 -0
- package/dist/audit/orchestrator/artifactFreshness.d.ts +4 -0
- package/dist/audit/orchestrator/artifactFreshness.d.ts.map +1 -0
- package/dist/audit/orchestrator/artifactFreshness.js +99 -0
- package/dist/audit/orchestrator/artifactFreshness.js.map +1 -0
- package/dist/audit/orchestrator/artifactMetadata.d.ts +6 -0
- package/dist/audit/orchestrator/artifactMetadata.d.ts.map +1 -0
- package/dist/audit/orchestrator/artifactMetadata.js +98 -0
- package/dist/audit/orchestrator/artifactMetadata.js.map +1 -0
- package/dist/audit/orchestrator/auditTaskUtils.d.ts +10 -0
- package/dist/audit/orchestrator/auditTaskUtils.d.ts.map +1 -0
- package/dist/audit/orchestrator/auditTaskUtils.js +53 -0
- package/dist/audit/orchestrator/auditTaskUtils.js.map +1 -0
- package/dist/audit/orchestrator/autoFixExecutor.d.ts +4 -0
- package/dist/audit/orchestrator/autoFixExecutor.d.ts.map +1 -0
- package/dist/audit/orchestrator/autoFixExecutor.js +152 -0
- package/dist/audit/orchestrator/autoFixExecutor.js.map +1 -0
- package/dist/audit/orchestrator/chunking.d.ts +6 -0
- package/dist/audit/orchestrator/chunking.d.ts.map +1 -0
- package/dist/audit/orchestrator/chunking.js +14 -0
- package/dist/audit/orchestrator/chunking.js.map +1 -0
- package/dist/audit/orchestrator/dependencyMap.d.ts +74 -0
- package/dist/audit/orchestrator/dependencyMap.d.ts.map +1 -0
- package/dist/audit/orchestrator/dependencyMap.js +193 -0
- package/dist/audit/orchestrator/dependencyMap.js.map +1 -0
- package/dist/audit/orchestrator/designReviewProjection.d.ts +66 -0
- package/dist/audit/orchestrator/designReviewProjection.d.ts.map +1 -0
- package/dist/audit/orchestrator/designReviewProjection.js +215 -0
- package/dist/audit/orchestrator/designReviewProjection.js.map +1 -0
- package/dist/audit/orchestrator/designReviewPrompt.d.ts +82 -0
- package/dist/audit/orchestrator/designReviewPrompt.d.ts.map +1 -0
- package/dist/audit/orchestrator/designReviewPrompt.js +474 -0
- package/dist/audit/orchestrator/designReviewPrompt.js.map +1 -0
- package/dist/audit/orchestrator/designReviewSnapshot.d.ts +69 -0
- package/dist/audit/orchestrator/designReviewSnapshot.d.ts.map +1 -0
- package/dist/audit/orchestrator/designReviewSnapshot.js +135 -0
- package/dist/audit/orchestrator/designReviewSnapshot.js.map +1 -0
- package/dist/audit/orchestrator/edgeReasoning.d.ts +40 -0
- package/dist/audit/orchestrator/edgeReasoning.d.ts.map +1 -0
- package/dist/audit/orchestrator/edgeReasoning.js +126 -0
- package/dist/audit/orchestrator/edgeReasoning.js.map +1 -0
- package/dist/audit/orchestrator/executorResult.d.ts +71 -0
- package/dist/audit/orchestrator/executorResult.d.ts.map +1 -0
- package/dist/audit/orchestrator/executorResult.js +2 -0
- package/dist/audit/orchestrator/executorResult.js.map +1 -0
- package/dist/audit/orchestrator/executorRunners.d.ts +34 -0
- package/dist/audit/orchestrator/executorRunners.d.ts.map +1 -0
- package/dist/audit/orchestrator/executorRunners.js +85 -0
- package/dist/audit/orchestrator/executorRunners.js.map +1 -0
- package/dist/audit/orchestrator/executors.d.ts +13 -0
- package/dist/audit/orchestrator/executors.d.ts.map +1 -0
- package/dist/audit/orchestrator/executors.js +114 -0
- package/dist/audit/orchestrator/executors.js.map +1 -0
- package/dist/audit/orchestrator/fileAnchors.d.ts +33 -0
- package/dist/audit/orchestrator/fileAnchors.d.ts.map +1 -0
- package/dist/audit/orchestrator/fileAnchors.js +242 -0
- package/dist/audit/orchestrator/fileAnchors.js.map +1 -0
- package/dist/audit/orchestrator/fileIntegrity.d.ts +9 -0
- package/dist/audit/orchestrator/fileIntegrity.d.ts.map +1 -0
- package/dist/audit/orchestrator/fileIntegrity.js +58 -0
- package/dist/audit/orchestrator/fileIntegrity.js.map +1 -0
- package/dist/audit/orchestrator/flowCoverage.d.ts +5 -0
- package/dist/audit/orchestrator/flowCoverage.d.ts.map +1 -0
- package/dist/audit/orchestrator/flowCoverage.js +46 -0
- package/dist/audit/orchestrator/flowCoverage.js.map +1 -0
- package/dist/audit/orchestrator/flowPlanning.d.ts +8 -0
- package/dist/audit/orchestrator/flowPlanning.d.ts.map +1 -0
- package/dist/audit/orchestrator/flowPlanning.js +65 -0
- package/dist/audit/orchestrator/flowPlanning.js.map +1 -0
- package/dist/audit/orchestrator/flowRequeue.d.ts +6 -0
- package/dist/audit/orchestrator/flowRequeue.d.ts.map +1 -0
- package/dist/audit/orchestrator/flowRequeue.js +73 -0
- package/dist/audit/orchestrator/flowRequeue.js.map +1 -0
- package/dist/audit/orchestrator/graphEnrichmentExecutor.d.ts +30 -0
- package/dist/audit/orchestrator/graphEnrichmentExecutor.d.ts.map +1 -0
- package/dist/audit/orchestrator/graphEnrichmentExecutor.js +227 -0
- package/dist/audit/orchestrator/graphEnrichmentExecutor.js.map +1 -0
- package/dist/audit/orchestrator/ingestionExecutors.d.ts +10 -0
- package/dist/audit/orchestrator/ingestionExecutors.d.ts.map +1 -0
- package/dist/audit/orchestrator/ingestionExecutors.js +262 -0
- package/dist/audit/orchestrator/ingestionExecutors.js.map +1 -0
- package/dist/audit/orchestrator/intakeExecutors.d.ts +26 -0
- package/dist/audit/orchestrator/intakeExecutors.d.ts.map +1 -0
- package/dist/audit/orchestrator/intakeExecutors.js +138 -0
- package/dist/audit/orchestrator/intakeExecutors.js.map +1 -0
- package/dist/audit/orchestrator/intentCheckpointExecutor.d.ts +89 -0
- package/dist/audit/orchestrator/intentCheckpointExecutor.d.ts.map +1 -0
- package/dist/audit/orchestrator/intentCheckpointExecutor.js +264 -0
- package/dist/audit/orchestrator/intentCheckpointExecutor.js.map +1 -0
- package/dist/audit/orchestrator/intentInterpreter.d.ts +49 -0
- package/dist/audit/orchestrator/intentInterpreter.d.ts.map +1 -0
- package/dist/audit/orchestrator/intentInterpreter.js +110 -0
- package/dist/audit/orchestrator/intentInterpreter.js.map +1 -0
- package/dist/audit/orchestrator/lensSelection.d.ts +35 -0
- package/dist/audit/orchestrator/lensSelection.d.ts.map +1 -0
- package/dist/audit/orchestrator/lensSelection.js +81 -0
- package/dist/audit/orchestrator/lensSelection.js.map +1 -0
- package/dist/audit/orchestrator/localCommands.d.ts +16 -0
- package/dist/audit/orchestrator/localCommands.d.ts.map +1 -0
- package/dist/audit/orchestrator/localCommands.js +113 -0
- package/dist/audit/orchestrator/localCommands.js.map +1 -0
- package/dist/audit/orchestrator/nextStep.d.ts +12 -0
- package/dist/audit/orchestrator/nextStep.d.ts.map +1 -0
- package/dist/audit/orchestrator/nextStep.js +63 -0
- package/dist/audit/orchestrator/nextStep.js.map +1 -0
- package/dist/audit/orchestrator/partitionTaskGraph.d.ts +32 -0
- package/dist/audit/orchestrator/partitionTaskGraph.d.ts.map +1 -0
- package/dist/audit/orchestrator/partitionTaskGraph.js +98 -0
- package/dist/audit/orchestrator/partitionTaskGraph.js.map +1 -0
- package/dist/audit/orchestrator/planning.d.ts +5 -0
- package/dist/audit/orchestrator/planning.d.ts.map +1 -0
- package/dist/audit/orchestrator/planning.js +81 -0
- package/dist/audit/orchestrator/planning.js.map +1 -0
- package/dist/audit/orchestrator/planningExecutors.d.ts +21 -0
- package/dist/audit/orchestrator/planningExecutors.d.ts.map +1 -0
- package/dist/audit/orchestrator/planningExecutors.js +228 -0
- package/dist/audit/orchestrator/planningExecutors.js.map +1 -0
- package/dist/audit/orchestrator/providerConfirmation.d.ts +21 -0
- package/dist/audit/orchestrator/providerConfirmation.d.ts.map +1 -0
- package/dist/audit/orchestrator/providerConfirmation.js +54 -0
- package/dist/audit/orchestrator/providerConfirmation.js.map +1 -0
- package/dist/audit/orchestrator/requeue.d.ts +4 -0
- package/dist/audit/orchestrator/requeue.d.ts.map +1 -0
- package/dist/audit/orchestrator/requeue.js +33 -0
- package/dist/audit/orchestrator/requeue.js.map +1 -0
- package/dist/audit/orchestrator/requeueCommand.d.ts +32 -0
- package/dist/audit/orchestrator/requeueCommand.d.ts.map +1 -0
- package/dist/audit/orchestrator/requeueCommand.js +45 -0
- package/dist/audit/orchestrator/requeueCommand.js.map +1 -0
- package/dist/audit/orchestrator/requeueUtils.d.ts +14 -0
- package/dist/audit/orchestrator/requeueUtils.d.ts.map +1 -0
- package/dist/audit/orchestrator/requeueUtils.js +22 -0
- package/dist/audit/orchestrator/requeueUtils.js.map +1 -0
- package/dist/audit/orchestrator/resultIngestion.d.ts +18 -0
- package/dist/audit/orchestrator/resultIngestion.d.ts.map +1 -0
- package/dist/audit/orchestrator/resultIngestion.js +63 -0
- package/dist/audit/orchestrator/resultIngestion.js.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraph.d.ts +5 -0
- package/dist/audit/orchestrator/reviewPacketGraph.d.ts.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraph.js +11 -0
- package/dist/audit/orchestrator/reviewPacketGraph.js.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraphClustering.d.ts +4 -0
- package/dist/audit/orchestrator/reviewPacketGraphClustering.d.ts.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraphClustering.js +481 -0
- package/dist/audit/orchestrator/reviewPacketGraphClustering.js.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraphContext.d.ts +10 -0
- package/dist/audit/orchestrator/reviewPacketGraphContext.d.ts.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraphContext.js +95 -0
- package/dist/audit/orchestrator/reviewPacketGraphContext.js.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraphEdges.d.ts +23 -0
- package/dist/audit/orchestrator/reviewPacketGraphEdges.d.ts.map +1 -0
- package/dist/audit/orchestrator/reviewPacketGraphEdges.js +169 -0
- package/dist/audit/orchestrator/reviewPacketGraphEdges.js.map +1 -0
- package/dist/audit/orchestrator/reviewPacketMetrics.d.ts +17 -0
- package/dist/audit/orchestrator/reviewPacketMetrics.d.ts.map +1 -0
- package/dist/audit/orchestrator/reviewPacketMetrics.js +322 -0
- package/dist/audit/orchestrator/reviewPacketMetrics.js.map +1 -0
- package/dist/audit/orchestrator/reviewPacketSizing.d.ts +27 -0
- package/dist/audit/orchestrator/reviewPacketSizing.d.ts.map +1 -0
- package/dist/audit/orchestrator/reviewPacketSizing.js +64 -0
- package/dist/audit/orchestrator/reviewPacketSizing.js.map +1 -0
- package/dist/audit/orchestrator/reviewPackets.d.ts +54 -0
- package/dist/audit/orchestrator/reviewPackets.d.ts.map +1 -0
- package/dist/audit/orchestrator/reviewPackets.js +318 -0
- package/dist/audit/orchestrator/reviewPackets.js.map +1 -0
- package/dist/audit/orchestrator/rollingDispatch.d.ts +45 -0
- package/dist/audit/orchestrator/rollingDispatch.d.ts.map +1 -0
- package/dist/audit/orchestrator/rollingDispatch.js +103 -0
- package/dist/audit/orchestrator/rollingDispatch.js.map +1 -0
- package/dist/audit/orchestrator/runtimeCommand.d.ts +10 -0
- package/dist/audit/orchestrator/runtimeCommand.d.ts.map +1 -0
- package/dist/audit/orchestrator/runtimeCommand.js +129 -0
- package/dist/audit/orchestrator/runtimeCommand.js.map +1 -0
- package/dist/audit/orchestrator/runtimeValidation.d.ts +13 -0
- package/dist/audit/orchestrator/runtimeValidation.d.ts.map +1 -0
- package/dist/audit/orchestrator/runtimeValidation.js +94 -0
- package/dist/audit/orchestrator/runtimeValidation.js.map +1 -0
- package/dist/audit/orchestrator/runtimeValidationUpdate.d.ts +3 -0
- package/dist/audit/orchestrator/runtimeValidationUpdate.d.ts.map +1 -0
- package/dist/audit/orchestrator/runtimeValidationUpdate.js +57 -0
- package/dist/audit/orchestrator/runtimeValidationUpdate.js.map +1 -0
- package/dist/audit/orchestrator/scope.d.ts +75 -0
- package/dist/audit/orchestrator/scope.d.ts.map +1 -0
- package/dist/audit/orchestrator/scope.js +268 -0
- package/dist/audit/orchestrator/scope.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/conflict.d.ts +9 -0
- package/dist/audit/orchestrator/selectiveDeepening/conflict.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/conflict.js +72 -0
- package/dist/audit/orchestrator/selectiveDeepening/conflict.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/findingFollowup.d.ts +11 -0
- package/dist/audit/orchestrator/selectiveDeepening/findingFollowup.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/findingFollowup.js +53 -0
- package/dist/audit/orchestrator/selectiveDeepening/findingFollowup.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/highRiskClean.d.ts +8 -0
- package/dist/audit/orchestrator/selectiveDeepening/highRiskClean.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/highRiskClean.js +46 -0
- package/dist/audit/orchestrator/selectiveDeepening/highRiskClean.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/index.d.ts +25 -0
- package/dist/audit/orchestrator/selectiveDeepening/index.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/index.js +157 -0
- package/dist/audit/orchestrator/selectiveDeepening/index.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/lensVerification.d.ts +13 -0
- package/dist/audit/orchestrator/selectiveDeepening/lensVerification.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/lensVerification.js +269 -0
- package/dist/audit/orchestrator/selectiveDeepening/lensVerification.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/runtimeValidation.d.ts +14 -0
- package/dist/audit/orchestrator/selectiveDeepening/runtimeValidation.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/runtimeValidation.js +58 -0
- package/dist/audit/orchestrator/selectiveDeepening/runtimeValidation.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/shared.d.ts +42 -0
- package/dist/audit/orchestrator/selectiveDeepening/shared.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/shared.js +121 -0
- package/dist/audit/orchestrator/selectiveDeepening/shared.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/stewardFollowup.d.ts +7 -0
- package/dist/audit/orchestrator/selectiveDeepening/stewardFollowup.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening/stewardFollowup.js +73 -0
- package/dist/audit/orchestrator/selectiveDeepening/stewardFollowup.js.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening.d.ts +3 -0
- package/dist/audit/orchestrator/selectiveDeepening.d.ts.map +1 -0
- package/dist/audit/orchestrator/selectiveDeepening.js +7 -0
- package/dist/audit/orchestrator/selectiveDeepening.js.map +1 -0
- package/dist/audit/orchestrator/staleness.d.ts +3 -0
- package/dist/audit/orchestrator/staleness.d.ts.map +1 -0
- package/dist/audit/orchestrator/staleness.js +102 -0
- package/dist/audit/orchestrator/staleness.js.map +1 -0
- package/dist/audit/orchestrator/state.d.ts +4 -0
- package/dist/audit/orchestrator/state.d.ts.map +1 -0
- package/dist/audit/orchestrator/state.js +158 -0
- package/dist/audit/orchestrator/state.js.map +1 -0
- package/dist/audit/orchestrator/structureExecutors.d.ts +6 -0
- package/dist/audit/orchestrator/structureExecutors.d.ts.map +1 -0
- package/dist/audit/orchestrator/structureExecutors.js +116 -0
- package/dist/audit/orchestrator/structureExecutors.js.map +1 -0
- package/dist/audit/orchestrator/syntaxResolutionExecutor.d.ts +4 -0
- package/dist/audit/orchestrator/syntaxResolutionExecutor.d.ts.map +1 -0
- package/dist/audit/orchestrator/syntaxResolutionExecutor.js +260 -0
- package/dist/audit/orchestrator/syntaxResolutionExecutor.js.map +1 -0
- package/dist/audit/orchestrator/synthesisExecutors.d.ts +13 -0
- package/dist/audit/orchestrator/synthesisExecutors.d.ts.map +1 -0
- package/dist/audit/orchestrator/synthesisExecutors.js +107 -0
- package/dist/audit/orchestrator/synthesisExecutors.js.map +1 -0
- package/dist/audit/orchestrator/taskAffinityGraph.d.ts +154 -0
- package/dist/audit/orchestrator/taskAffinityGraph.d.ts.map +1 -0
- package/dist/audit/orchestrator/taskAffinityGraph.js +216 -0
- package/dist/audit/orchestrator/taskAffinityGraph.js.map +1 -0
- package/dist/audit/orchestrator/taskBuilder.d.ts +43 -0
- package/dist/audit/orchestrator/taskBuilder.d.ts.map +1 -0
- package/dist/audit/orchestrator/taskBuilder.js +355 -0
- package/dist/audit/orchestrator/taskBuilder.js.map +1 -0
- package/dist/audit/orchestrator/trivialAudit.d.ts +5 -0
- package/dist/audit/orchestrator/trivialAudit.d.ts.map +1 -0
- package/dist/audit/orchestrator/trivialAudit.js +50 -0
- package/dist/audit/orchestrator/trivialAudit.js.map +1 -0
- package/dist/audit/orchestrator/unionFind.d.ts +8 -0
- package/dist/audit/orchestrator/unionFind.d.ts.map +1 -0
- package/dist/audit/orchestrator/unionFind.js +43 -0
- package/dist/audit/orchestrator/unionFind.js.map +1 -0
- package/dist/audit/orchestrator/unitBuilder.d.ts +8 -0
- package/dist/audit/orchestrator/unitBuilder.d.ts.map +1 -0
- package/dist/audit/orchestrator/unitBuilder.js +171 -0
- package/dist/audit/orchestrator/unitBuilder.js.map +1 -0
- package/dist/audit/orchestrator.d.ts +7 -0
- package/dist/audit/orchestrator.d.ts.map +1 -0
- package/dist/audit/orchestrator.js +68 -0
- package/dist/audit/orchestrator.js.map +1 -0
- package/dist/audit/prompts/renderWorkerPrompt.d.ts +3 -0
- package/dist/audit/prompts/renderWorkerPrompt.d.ts.map +1 -0
- package/dist/audit/prompts/renderWorkerPrompt.js +87 -0
- package/dist/audit/prompts/renderWorkerPrompt.js.map +1 -0
- package/dist/audit/providers/claudeCodeProvider.d.ts +11 -0
- package/dist/audit/providers/claudeCodeProvider.d.ts.map +1 -0
- package/dist/audit/providers/claudeCodeProvider.js +23 -0
- package/dist/audit/providers/claudeCodeProvider.js.map +1 -0
- package/dist/audit/providers/constants.d.ts +2 -0
- package/dist/audit/providers/constants.d.ts.map +1 -0
- package/dist/audit/providers/constants.js +2 -0
- package/dist/audit/providers/constants.js.map +1 -0
- package/dist/audit/providers/index.d.ts +14 -0
- package/dist/audit/providers/index.d.ts.map +1 -0
- package/dist/audit/providers/index.js +21 -0
- package/dist/audit/providers/index.js.map +1 -0
- package/dist/audit/providers/opencodeProvider.d.ts +5 -0
- package/dist/audit/providers/opencodeProvider.d.ts.map +1 -0
- package/dist/audit/providers/opencodeProvider.js +10 -0
- package/dist/audit/providers/opencodeProvider.js.map +1 -0
- package/dist/audit/quota/discoveredLimits.d.ts +27 -0
- package/dist/audit/quota/discoveredLimits.d.ts.map +1 -0
- package/dist/audit/quota/discoveredLimits.js +91 -0
- package/dist/audit/quota/discoveredLimits.js.map +1 -0
- package/dist/audit/quota/headerExtraction.d.ts +9 -0
- package/dist/audit/quota/headerExtraction.d.ts.map +1 -0
- package/dist/audit/quota/headerExtraction.js +148 -0
- package/dist/audit/quota/headerExtraction.js.map +1 -0
- package/dist/audit/quota/headerExtractors/claudeCodeHeaderExtractor.d.ts +7 -0
- package/dist/audit/quota/headerExtractors/claudeCodeHeaderExtractor.d.ts.map +1 -0
- package/dist/audit/quota/headerExtractors/claudeCodeHeaderExtractor.js +27 -0
- package/dist/audit/quota/headerExtractors/claudeCodeHeaderExtractor.js.map +1 -0
- package/dist/audit/quota/headerExtractors/genericHeaderExtractor.d.ts +10 -0
- package/dist/audit/quota/headerExtractors/genericHeaderExtractor.d.ts.map +1 -0
- package/dist/audit/quota/headerExtractors/genericHeaderExtractor.js +8 -0
- package/dist/audit/quota/headerExtractors/genericHeaderExtractor.js.map +1 -0
- package/dist/audit/quota/headerExtractors/index.d.ts +6 -0
- package/dist/audit/quota/headerExtractors/index.d.ts.map +1 -0
- package/dist/audit/quota/headerExtractors/index.js +11 -0
- package/dist/audit/quota/headerExtractors/index.js.map +1 -0
- package/dist/audit/quota/hostLimits.d.ts +8 -0
- package/dist/audit/quota/hostLimits.d.ts.map +1 -0
- package/dist/audit/quota/hostLimits.js +9 -0
- package/dist/audit/quota/hostLimits.js.map +1 -0
- package/dist/audit/quota/index.d.ts +383 -0
- package/dist/audit/quota/index.d.ts.map +1 -0
- package/dist/audit/quota/index.js +45 -0
- package/dist/audit/quota/index.js.map +1 -0
- package/dist/audit/reporting/findingIdentity.d.ts +34 -0
- package/dist/audit/reporting/findingIdentity.d.ts.map +1 -0
- package/dist/audit/reporting/findingIdentity.js +64 -0
- package/dist/audit/reporting/findingIdentity.js.map +1 -0
- package/dist/audit/reporting/findingRanks.d.ts +2 -0
- package/dist/audit/reporting/findingRanks.d.ts.map +1 -0
- package/dist/audit/reporting/findingRanks.js +7 -0
- package/dist/audit/reporting/findingRanks.js.map +1 -0
- package/dist/audit/reporting/mergeFindings.d.ts +6 -0
- package/dist/audit/reporting/mergeFindings.d.ts.map +1 -0
- package/dist/audit/reporting/mergeFindings.js +326 -0
- package/dist/audit/reporting/mergeFindings.js.map +1 -0
- package/dist/audit/reporting/synthesis.d.ts +124 -0
- package/dist/audit/reporting/synthesis.d.ts.map +1 -0
- package/dist/audit/reporting/synthesis.js +369 -0
- package/dist/audit/reporting/synthesis.js.map +1 -0
- package/dist/audit/reporting/synthesisNarrativePrompt.d.ts +8 -0
- package/dist/audit/reporting/synthesisNarrativePrompt.d.ts.map +1 -0
- package/dist/audit/reporting/synthesisNarrativePrompt.js +66 -0
- package/dist/audit/reporting/synthesisNarrativePrompt.js.map +1 -0
- package/dist/audit/reporting/workBlocks.d.ts +10 -0
- package/dist/audit/reporting/workBlocks.d.ts.map +1 -0
- package/dist/audit/reporting/workBlocks.js +154 -0
- package/dist/audit/reporting/workBlocks.js.map +1 -0
- package/dist/audit/supervisor/operatorHandoff.d.ts +65 -0
- package/dist/audit/supervisor/operatorHandoff.d.ts.map +1 -0
- package/dist/audit/supervisor/operatorHandoff.js +277 -0
- package/dist/audit/supervisor/operatorHandoff.js.map +1 -0
- package/dist/audit/supervisor/runLedger.d.ts +4 -0
- package/dist/audit/supervisor/runLedger.d.ts.map +1 -0
- package/dist/audit/supervisor/runLedger.js +118 -0
- package/dist/audit/supervisor/runLedger.js.map +1 -0
- package/dist/audit/supervisor/sessionConfig.d.ts +12 -0
- package/dist/audit/supervisor/sessionConfig.d.ts.map +1 -0
- package/dist/audit/supervisor/sessionConfig.js +49 -0
- package/dist/audit/supervisor/sessionConfig.js.map +1 -0
- package/dist/audit/types/activeDispatch.d.ts +36 -0
- package/dist/audit/types/activeDispatch.d.ts.map +1 -0
- package/dist/audit/types/activeDispatch.js +3 -0
- package/dist/audit/types/activeDispatch.js.map +1 -0
- package/dist/audit/types/analyzerCapability.d.ts +17 -0
- package/dist/audit/types/analyzerCapability.d.ts.map +1 -0
- package/dist/audit/types/analyzerCapability.js +2 -0
- package/dist/audit/types/analyzerCapability.js.map +1 -0
- package/dist/audit/types/artifactMetadata.d.ts +9 -0
- package/dist/audit/types/artifactMetadata.d.ts.map +1 -0
- package/dist/audit/types/artifactMetadata.js +2 -0
- package/dist/audit/types/artifactMetadata.js.map +1 -0
- package/dist/audit/types/auditScope.d.ts +58 -0
- package/dist/audit/types/auditScope.d.ts.map +1 -0
- package/dist/audit/types/auditScope.js +15 -0
- package/dist/audit/types/auditScope.js.map +1 -0
- package/dist/audit/types/auditState.d.ts +18 -0
- package/dist/audit/types/auditState.d.ts.map +1 -0
- package/dist/audit/types/auditState.js +2 -0
- package/dist/audit/types/auditState.js.map +1 -0
- package/dist/audit/types/designAssessment.d.ts +22 -0
- package/dist/audit/types/designAssessment.d.ts.map +1 -0
- package/dist/audit/types/designAssessment.js +8 -0
- package/dist/audit/types/designAssessment.js.map +1 -0
- package/dist/audit/types/externalAnalyzer.d.ts +225 -0
- package/dist/audit/types/externalAnalyzer.d.ts.map +1 -0
- package/dist/audit/types/externalAnalyzer.js +56 -0
- package/dist/audit/types/externalAnalyzer.js.map +1 -0
- package/dist/audit/types/flowCoverage.d.ts +16 -0
- package/dist/audit/types/flowCoverage.d.ts.map +1 -0
- package/dist/audit/types/flowCoverage.js +6 -0
- package/dist/audit/types/flowCoverage.js.map +1 -0
- package/dist/audit/types/reviewPlanning.d.ts +513 -0
- package/dist/audit/types/reviewPlanning.d.ts.map +1 -0
- package/dist/audit/types/reviewPlanning.js +109 -0
- package/dist/audit/types/reviewPlanning.js.map +1 -0
- package/dist/audit/types/runtimeValidation.d.ts +155 -0
- package/dist/audit/types/runtimeValidation.d.ts.map +1 -0
- package/dist/audit/types/runtimeValidation.js +52 -0
- package/dist/audit/types/runtimeValidation.js.map +1 -0
- package/dist/audit/types/synthesisNarrative.d.ts +8 -0
- package/dist/audit/types/synthesisNarrative.d.ts.map +1 -0
- package/dist/audit/types/synthesisNarrative.js +6 -0
- package/dist/audit/types/synthesisNarrative.js.map +1 -0
- package/dist/audit/types/toolingManifest.d.ts +8 -0
- package/dist/audit/types/toolingManifest.d.ts.map +1 -0
- package/dist/audit/types/toolingManifest.js +2 -0
- package/dist/audit/types/toolingManifest.js.map +1 -0
- package/dist/audit/types/workerResult.d.ts +14 -0
- package/dist/audit/types/workerResult.d.ts.map +1 -0
- package/dist/audit/types/workerResult.js +2 -0
- package/dist/audit/types/workerResult.js.map +1 -0
- package/dist/audit/types/workerSession.d.ts +28 -0
- package/dist/audit/types/workerSession.d.ts.map +1 -0
- package/dist/audit/types/workerSession.js +5 -0
- package/dist/audit/types/workerSession.js.map +1 -0
- package/dist/audit/types.d.ts +1077 -0
- package/dist/audit/types.d.ts.map +1 -0
- package/dist/audit/types.js +160 -0
- package/dist/audit/types.js.map +1 -0
- package/dist/audit/validation/anchorGrounding.d.ts +49 -0
- package/dist/audit/validation/anchorGrounding.d.ts.map +1 -0
- package/dist/audit/validation/anchorGrounding.js +183 -0
- package/dist/audit/validation/anchorGrounding.js.map +1 -0
- package/dist/audit/validation/artifacts.d.ts +4 -0
- package/dist/audit/validation/artifacts.d.ts.map +1 -0
- package/dist/audit/validation/artifacts.js +313 -0
- package/dist/audit/validation/artifacts.js.map +1 -0
- package/dist/audit/validation/auditResults.d.ts +16 -0
- package/dist/audit/validation/auditResults.d.ts.map +1 -0
- package/dist/audit/validation/auditResults.js +619 -0
- package/dist/audit/validation/auditResults.js.map +1 -0
- package/dist/audit/validation/designFindingGrounding.d.ts +33 -0
- package/dist/audit/validation/designFindingGrounding.d.ts.map +1 -0
- package/dist/audit/validation/designFindingGrounding.js +43 -0
- package/dist/audit/validation/designFindingGrounding.js.map +1 -0
- package/dist/audit/validation/quoteGrounding.d.ts +18 -0
- package/dist/audit/validation/quoteGrounding.d.ts.map +1 -0
- package/dist/audit/validation/quoteGrounding.js +18 -0
- package/dist/audit/validation/quoteGrounding.js.map +1 -0
- package/dist/audit/validation/sessionConfig.d.ts +8 -0
- package/dist/audit/validation/sessionConfig.d.ts.map +1 -0
- package/dist/audit/validation/sessionConfig.js +334 -0
- package/dist/audit/validation/sessionConfig.js.map +1 -0
- package/dist/remediate/contractPipeline/artifactStore.d.ts +58 -0
- package/dist/remediate/contractPipeline/artifactStore.d.ts.map +1 -0
- package/dist/remediate/contractPipeline/artifactStore.js +201 -0
- package/dist/remediate/contractPipeline/artifactStore.js.map +1 -0
- package/dist/remediate/contractPipeline/cyclicSeamResolution.d.ts +68 -0
- package/dist/remediate/contractPipeline/cyclicSeamResolution.d.ts.map +1 -0
- package/dist/remediate/contractPipeline/cyclicSeamResolution.js +151 -0
- package/dist/remediate/contractPipeline/cyclicSeamResolution.js.map +1 -0
- package/dist/remediate/contractPipeline/derive.d.ts +88 -0
- package/dist/remediate/contractPipeline/derive.d.ts.map +1 -0
- package/dist/remediate/contractPipeline/derive.js +216 -0
- package/dist/remediate/contractPipeline/derive.js.map +1 -0
- package/dist/remediate/contractPipeline/idRegistry.d.ts +49 -0
- package/dist/remediate/contractPipeline/idRegistry.d.ts.map +1 -0
- package/dist/remediate/contractPipeline/idRegistry.js +57 -0
- package/dist/remediate/contractPipeline/idRegistry.js.map +1 -0
- package/dist/remediate/contractPipeline/reviewSnapshot.d.ts +52 -0
- package/dist/remediate/contractPipeline/reviewSnapshot.d.ts.map +1 -0
- package/dist/remediate/contractPipeline/reviewSnapshot.js +116 -0
- package/dist/remediate/contractPipeline/reviewSnapshot.js.map +1 -0
- package/dist/remediate/contractPipeline/semanticProjection.d.ts +46 -0
- package/dist/remediate/contractPipeline/semanticProjection.d.ts.map +1 -0
- package/dist/remediate/contractPipeline/semanticProjection.js +102 -0
- package/dist/remediate/contractPipeline/semanticProjection.js.map +1 -0
- package/dist/remediate/coverage/findingLedger.d.ts +99 -0
- package/dist/remediate/coverage/findingLedger.d.ts.map +1 -0
- package/dist/remediate/coverage/findingLedger.js +110 -0
- package/dist/remediate/coverage/findingLedger.js.map +1 -0
- package/dist/remediate/dedup/crossLensDedup.d.ts +9 -0
- package/dist/remediate/dedup/crossLensDedup.d.ts.map +1 -0
- package/dist/remediate/dedup/crossLensDedup.js +191 -0
- package/dist/remediate/dedup/crossLensDedup.js.map +1 -0
- package/dist/remediate/dispatch/amendmentClaim.d.ts +41 -0
- package/dist/remediate/dispatch/amendmentClaim.d.ts.map +1 -0
- package/dist/remediate/dispatch/amendmentClaim.js +60 -0
- package/dist/remediate/dispatch/amendmentClaim.js.map +1 -0
- package/dist/remediate/dispatch/ownershipRegistry.d.ts +97 -0
- package/dist/remediate/dispatch/ownershipRegistry.d.ts.map +1 -0
- package/dist/remediate/dispatch/ownershipRegistry.js +217 -0
- package/dist/remediate/dispatch/ownershipRegistry.js.map +1 -0
- package/dist/remediate/findingFilter.d.ts +42 -0
- package/dist/remediate/findingFilter.d.ts.map +1 -0
- package/dist/remediate/findingFilter.js +62 -0
- package/dist/remediate/findingFilter.js.map +1 -0
- package/dist/remediate/index.d.ts +45 -0
- package/dist/remediate/index.d.ts.map +1 -0
- package/dist/remediate/index.js +434 -0
- package/dist/remediate/index.js.map +1 -0
- package/dist/remediate/intake.d.ts +168 -0
- package/dist/remediate/intake.d.ts.map +1 -0
- package/dist/remediate/intake.js +340 -0
- package/dist/remediate/intake.js.map +1 -0
- package/dist/remediate/intent/checkpointFilter.d.ts +14 -0
- package/dist/remediate/intent/checkpointFilter.d.ts.map +1 -0
- package/dist/remediate/intent/checkpointFilter.js +111 -0
- package/dist/remediate/intent/checkpointFilter.js.map +1 -0
- package/dist/remediate/phases/close.d.ts +32 -0
- package/dist/remediate/phases/close.d.ts.map +1 -0
- package/dist/remediate/phases/close.js +992 -0
- package/dist/remediate/phases/close.js.map +1 -0
- package/dist/remediate/phases/constants.d.ts +3 -0
- package/dist/remediate/phases/constants.d.ts.map +1 -0
- package/dist/remediate/phases/constants.js +3 -0
- package/dist/remediate/phases/constants.js.map +1 -0
- package/dist/remediate/phases/grounding.d.ts +77 -0
- package/dist/remediate/phases/grounding.d.ts.map +1 -0
- package/dist/remediate/phases/grounding.js +153 -0
- package/dist/remediate/phases/grounding.js.map +1 -0
- package/dist/remediate/phases/plan.d.ts +113 -0
- package/dist/remediate/phases/plan.d.ts.map +1 -0
- package/dist/remediate/phases/plan.js +988 -0
- package/dist/remediate/phases/plan.js.map +1 -0
- package/dist/remediate/phases/triage.d.ts +4 -0
- package/dist/remediate/phases/triage.d.ts.map +1 -0
- package/dist/remediate/phases/triage.js +175 -0
- package/dist/remediate/phases/triage.js.map +1 -0
- package/dist/remediate/phases/workerTasks.d.ts +21 -0
- package/dist/remediate/phases/workerTasks.d.ts.map +1 -0
- package/dist/remediate/phases/workerTasks.js +31 -0
- package/dist/remediate/phases/workerTasks.js.map +1 -0
- package/dist/remediate/providers/claudeCodeProvider.d.ts +12 -0
- package/dist/remediate/providers/claudeCodeProvider.d.ts.map +1 -0
- package/dist/remediate/providers/claudeCodeProvider.js +24 -0
- package/dist/remediate/providers/claudeCodeProvider.js.map +1 -0
- package/dist/remediate/providers/constants.d.ts +2 -0
- package/dist/remediate/providers/constants.d.ts.map +1 -0
- package/dist/remediate/providers/constants.js +2 -0
- package/dist/remediate/providers/constants.js.map +1 -0
- package/dist/remediate/providers/index.d.ts +15 -0
- package/dist/remediate/providers/index.d.ts.map +1 -0
- package/dist/remediate/providers/index.js +22 -0
- package/dist/remediate/providers/index.js.map +1 -0
- package/dist/remediate/providers/opencodeProvider.d.ts +5 -0
- package/dist/remediate/providers/opencodeProvider.d.ts.map +1 -0
- package/dist/remediate/providers/opencodeProvider.js +10 -0
- package/dist/remediate/providers/opencodeProvider.js.map +1 -0
- package/dist/remediate/quota/hostLimits.d.ts +8 -0
- package/dist/remediate/quota/hostLimits.d.ts.map +1 -0
- package/dist/remediate/quota/hostLimits.js +9 -0
- package/dist/remediate/quota/hostLimits.js.map +1 -0
- package/dist/remediate/quota/index.d.ts +8 -0
- package/dist/remediate/quota/index.d.ts.map +1 -0
- package/dist/remediate/quota/index.js +12 -0
- package/dist/remediate/quota/index.js.map +1 -0
- package/dist/remediate/review/reviewGate.d.ts +72 -0
- package/dist/remediate/review/reviewGate.d.ts.map +1 -0
- package/dist/remediate/review/reviewGate.js +112 -0
- package/dist/remediate/review/reviewGate.js.map +1 -0
- package/dist/remediate/review/reviewNecessity.d.ts +53 -0
- package/dist/remediate/review/reviewNecessity.d.ts.map +1 -0
- package/dist/remediate/review/reviewNecessity.js +129 -0
- package/dist/remediate/review/reviewNecessity.js.map +1 -0
- package/dist/remediate/state/closingActions.d.ts +3 -0
- package/dist/remediate/state/closingActions.d.ts.map +1 -0
- package/dist/remediate/state/closingActions.js +10 -0
- package/dist/remediate/state/closingActions.js.map +1 -0
- package/dist/remediate/state/itemStatus.d.ts +40 -0
- package/dist/remediate/state/itemStatus.d.ts.map +1 -0
- package/dist/remediate/state/itemStatus.js +138 -0
- package/dist/remediate/state/itemStatus.js.map +1 -0
- package/dist/remediate/state/store.d.ts +65 -0
- package/dist/remediate/state/store.d.ts.map +1 -0
- package/dist/remediate/state/store.js +141 -0
- package/dist/remediate/state/store.js.map +1 -0
- package/dist/remediate/state/types.d.ts +766 -0
- package/dist/remediate/state/types.d.ts.map +1 -0
- package/dist/remediate/state/types.js +122 -0
- package/dist/remediate/state/types.js.map +1 -0
- package/dist/remediate/steps/contractPipeline.d.ts +173 -0
- package/dist/remediate/steps/contractPipeline.d.ts.map +1 -0
- package/dist/remediate/steps/contractPipeline.js +1229 -0
- package/dist/remediate/steps/contractPipeline.js.map +1 -0
- package/dist/remediate/steps/contractPipelinePrompts.d.ts +72 -0
- package/dist/remediate/steps/contractPipelinePrompts.d.ts.map +1 -0
- package/dist/remediate/steps/contractPipelinePrompts.js +438 -0
- package/dist/remediate/steps/contractPipelinePrompts.js.map +1 -0
- package/dist/remediate/steps/dispatch.d.ts +434 -0
- package/dist/remediate/steps/dispatch.d.ts.map +1 -0
- package/dist/remediate/steps/dispatch.js +2180 -0
- package/dist/remediate/steps/dispatch.js.map +1 -0
- package/dist/remediate/steps/intakeResolver.d.ts +32 -0
- package/dist/remediate/steps/intakeResolver.d.ts.map +1 -0
- package/dist/remediate/steps/intakeResolver.js +310 -0
- package/dist/remediate/steps/intakeResolver.js.map +1 -0
- package/dist/remediate/steps/leanFastPath.d.ts +49 -0
- package/dist/remediate/steps/leanFastPath.d.ts.map +1 -0
- package/dist/remediate/steps/leanFastPath.js +151 -0
- package/dist/remediate/steps/leanFastPath.js.map +1 -0
- package/dist/remediate/steps/nextStep.d.ts +323 -0
- package/dist/remediate/steps/nextStep.d.ts.map +1 -0
- package/dist/remediate/steps/nextStep.js +2721 -0
- package/dist/remediate/steps/nextStep.js.map +1 -0
- package/dist/remediate/steps/prompts.d.ts +26 -0
- package/dist/remediate/steps/prompts.d.ts.map +1 -0
- package/dist/remediate/steps/prompts.js +370 -0
- package/dist/remediate/steps/prompts.js.map +1 -0
- package/dist/remediate/steps/providerNodeDispatch.d.ts +42 -0
- package/dist/remediate/steps/providerNodeDispatch.d.ts.map +1 -0
- package/dist/remediate/steps/providerNodeDispatch.js +100 -0
- package/dist/remediate/steps/providerNodeDispatch.js.map +1 -0
- package/dist/remediate/steps/rollingSession.d.ts +84 -0
- package/dist/remediate/steps/rollingSession.d.ts.map +1 -0
- package/dist/remediate/steps/rollingSession.js +147 -0
- package/dist/remediate/steps/rollingSession.js.map +1 -0
- package/dist/remediate/steps/stepUtils.d.ts +63 -0
- package/dist/remediate/steps/stepUtils.d.ts.map +1 -0
- package/dist/remediate/steps/stepUtils.js +117 -0
- package/dist/remediate/steps/stepUtils.js.map +1 -0
- package/dist/remediate/steps/stepWriter.d.ts +27 -0
- package/dist/remediate/steps/stepWriter.d.ts.map +1 -0
- package/dist/remediate/steps/stepWriter.js +37 -0
- package/dist/remediate/steps/stepWriter.js.map +1 -0
- package/dist/remediate/steps/types.d.ts +83 -0
- package/dist/remediate/steps/types.d.ts.map +1 -0
- package/dist/remediate/steps/types.js +6 -0
- package/dist/remediate/steps/types.js.map +1 -0
- package/dist/remediate/types/options.d.ts +6 -0
- package/dist/remediate/types/options.d.ts.map +1 -0
- package/dist/remediate/types/options.js +2 -0
- package/dist/remediate/types/options.js.map +1 -0
- package/dist/remediate/types/workerSession.d.ts +36 -0
- package/dist/remediate/types/workerSession.d.ts.map +1 -0
- package/dist/remediate/types/workerSession.js +13 -0
- package/dist/remediate/types/workerSession.js.map +1 -0
- package/dist/remediate/utils/commands.d.ts +17 -0
- package/dist/remediate/utils/commands.d.ts.map +1 -0
- package/dist/remediate/utils/commands.js +26 -0
- package/dist/remediate/utils/commands.js.map +1 -0
- package/dist/remediate/utils/fileIntegrity.d.ts +27 -0
- package/dist/remediate/utils/fileIntegrity.d.ts.map +1 -0
- package/dist/remediate/utils/fileIntegrity.js +201 -0
- package/dist/remediate/utils/fileIntegrity.js.map +1 -0
- package/dist/remediate/utils/hostAssets.d.ts +18 -0
- package/dist/remediate/utils/hostAssets.d.ts.map +1 -0
- package/dist/remediate/utils/hostAssets.js +31 -0
- package/dist/remediate/utils/hostAssets.js.map +1 -0
- package/dist/remediate/validation/artifacts.d.ts +9 -0
- package/dist/remediate/validation/artifacts.d.ts.map +1 -0
- package/dist/remediate/validation/artifacts.js +316 -0
- package/dist/remediate/validation/artifacts.js.map +1 -0
- package/dist/remediate/validation/contractPipeline.d.ts +36 -0
- package/dist/remediate/validation/contractPipeline.d.ts.map +1 -0
- package/dist/remediate/validation/contractPipeline.js +569 -0
- package/dist/remediate/validation/contractPipeline.js.map +1 -0
- package/dist/remediate/validation/contractPipelineGates.d.ts +161 -0
- package/dist/remediate/validation/contractPipelineGates.d.ts.map +1 -0
- package/dist/remediate/validation/contractPipelineGates.js +739 -0
- package/dist/remediate/validation/contractPipelineGates.js.map +1 -0
- package/dist/remediate/validation/remediationState.d.ts +8 -0
- package/dist/remediate/validation/remediationState.d.ts.map +1 -0
- package/dist/remediate/validation/remediationState.js +187 -0
- package/dist/remediate/validation/remediationState.js.map +1 -0
- package/dist/shared/agentReflections.d.ts +61 -0
- package/dist/shared/agentReflections.d.ts.map +1 -0
- package/dist/shared/agentReflections.js +180 -0
- package/dist/shared/agentReflections.js.map +1 -0
- package/dist/shared/concurrency.d.ts +16 -0
- package/dist/shared/concurrency.d.ts.map +1 -0
- package/dist/shared/concurrency.js +34 -0
- package/dist/shared/concurrency.js.map +1 -0
- package/dist/shared/contracts.d.ts +2 -0
- package/dist/shared/contracts.d.ts.map +1 -0
- package/dist/shared/contracts.js +2 -0
- package/dist/shared/contracts.js.map +1 -0
- package/dist/shared/dispatch/rollingDispatch.d.ts +192 -0
- package/dist/shared/dispatch/rollingDispatch.d.ts.map +1 -0
- package/dist/shared/dispatch/rollingDispatch.js +389 -0
- package/dist/shared/dispatch/rollingDispatch.js.map +1 -0
- package/dist/shared/dispatch/tierRank.d.ts +53 -0
- package/dist/shared/dispatch/tierRank.d.ts.map +1 -0
- package/dist/shared/dispatch/tierRank.js +69 -0
- package/dist/shared/dispatch/tierRank.js.map +1 -0
- package/dist/shared/engine/obligationEngine.d.ts +159 -0
- package/dist/shared/engine/obligationEngine.d.ts.map +1 -0
- package/dist/shared/engine/obligationEngine.js +124 -0
- package/dist/shared/engine/obligationEngine.js.map +1 -0
- package/dist/shared/findingIdentitySignature.d.ts +82 -0
- package/dist/shared/findingIdentitySignature.d.ts.map +1 -0
- package/dist/shared/findingIdentitySignature.js +114 -0
- package/dist/shared/findingIdentitySignature.js.map +1 -0
- package/dist/shared/git.d.ts +18 -0
- package/dist/shared/git.d.ts.map +1 -0
- package/dist/shared/git.js +63 -0
- package/dist/shared/git.js.map +1 -0
- package/dist/shared/hash.d.ts +16 -0
- package/dist/shared/hash.d.ts.map +1 -0
- package/dist/shared/hash.js +36 -0
- package/dist/shared/hash.js.map +1 -0
- package/dist/shared/hostAssets.d.ts +40 -0
- package/dist/shared/hostAssets.d.ts.map +1 -0
- package/dist/shared/hostAssets.js +110 -0
- package/dist/shared/hostAssets.js.map +1 -0
- package/dist/shared/ids.d.ts +18 -0
- package/dist/shared/ids.d.ts.map +1 -0
- package/dist/shared/ids.js +27 -0
- package/dist/shared/ids.js.map +1 -0
- package/dist/shared/index.d.ts +150 -0
- package/dist/shared/index.d.ts.map +1 -0
- package/dist/shared/index.js +112 -0
- package/dist/shared/index.js.map +1 -0
- package/dist/shared/intent/clauseInterpreter.d.ts +84 -0
- package/dist/shared/intent/clauseInterpreter.d.ts.map +1 -0
- package/dist/shared/intent/clauseInterpreter.js +183 -0
- package/dist/shared/intent/clauseInterpreter.js.map +1 -0
- package/dist/shared/intent/freeFormIntentInterpreter.d.ts +46 -0
- package/dist/shared/intent/freeFormIntentInterpreter.d.ts.map +1 -0
- package/dist/shared/intent/freeFormIntentInterpreter.js +126 -0
- package/dist/shared/intent/freeFormIntentInterpreter.js.map +1 -0
- package/dist/shared/intent/sharedIntentData.d.ts +16 -0
- package/dist/shared/intent/sharedIntentData.d.ts.map +1 -0
- package/dist/shared/intent/sharedIntentData.js +38 -0
- package/dist/shared/intent/sharedIntentData.js.map +1 -0
- package/dist/shared/io/auditToolsPaths.d.ts +36 -0
- package/dist/shared/io/auditToolsPaths.d.ts.map +1 -0
- package/dist/shared/io/auditToolsPaths.js +47 -0
- package/dist/shared/io/auditToolsPaths.js.map +1 -0
- package/dist/shared/io/json.d.ts +30 -0
- package/dist/shared/io/json.d.ts.map +1 -0
- package/dist/shared/io/json.js +183 -0
- package/dist/shared/io/json.js.map +1 -0
- package/dist/shared/io/stepContractWriter.d.ts +103 -0
- package/dist/shared/io/stepContractWriter.d.ts.map +1 -0
- package/dist/shared/io/stepContractWriter.js +85 -0
- package/dist/shared/io/stepContractWriter.js.map +1 -0
- package/dist/shared/observability/runLog.d.ts +37 -0
- package/dist/shared/observability/runLog.d.ts.map +1 -0
- package/dist/shared/observability/runLog.js +40 -0
- package/dist/shared/observability/runLog.js.map +1 -0
- package/dist/shared/opencodePermissions.d.ts +49 -0
- package/dist/shared/opencodePermissions.d.ts.map +1 -0
- package/dist/shared/opencodePermissions.js +118 -0
- package/dist/shared/opencodePermissions.js.map +1 -0
- package/dist/shared/parsing/stringAwareScanner.d.ts +32 -0
- package/dist/shared/parsing/stringAwareScanner.d.ts.map +1 -0
- package/dist/shared/parsing/stringAwareScanner.js +51 -0
- package/dist/shared/parsing/stringAwareScanner.js.map +1 -0
- package/dist/shared/prompts.d.ts +47 -0
- package/dist/shared/prompts.d.ts.map +1 -0
- package/dist/shared/prompts.js +41 -0
- package/dist/shared/prompts.js.map +1 -0
- package/dist/shared/providers/claudeCodeProvider.d.ts +56 -0
- package/dist/shared/providers/claudeCodeProvider.d.ts.map +1 -0
- package/dist/shared/providers/claudeCodeProvider.js +67 -0
- package/dist/shared/providers/claudeCodeProvider.js.map +1 -0
- package/dist/shared/providers/codexProvider.d.ts +37 -0
- package/dist/shared/providers/codexProvider.d.ts.map +1 -0
- package/dist/shared/providers/codexProvider.js +79 -0
- package/dist/shared/providers/codexProvider.js.map +1 -0
- package/dist/shared/providers/constants.d.ts +4 -0
- package/dist/shared/providers/constants.d.ts.map +1 -0
- package/dist/shared/providers/constants.js +4 -0
- package/dist/shared/providers/constants.js.map +1 -0
- package/dist/shared/providers/localSubprocessProvider.d.ts +10 -0
- package/dist/shared/providers/localSubprocessProvider.d.ts.map +1 -0
- package/dist/shared/providers/localSubprocessProvider.js +20 -0
- package/dist/shared/providers/localSubprocessProvider.js.map +1 -0
- package/dist/shared/providers/openAiCompatibleProvider.d.ts +62 -0
- package/dist/shared/providers/openAiCompatibleProvider.d.ts.map +1 -0
- package/dist/shared/providers/openAiCompatibleProvider.js +333 -0
- package/dist/shared/providers/openAiCompatibleProvider.js.map +1 -0
- package/dist/shared/providers/opencodeLaunch.d.ts +28 -0
- package/dist/shared/providers/opencodeLaunch.d.ts.map +1 -0
- package/dist/shared/providers/opencodeLaunch.js +39 -0
- package/dist/shared/providers/opencodeLaunch.js.map +1 -0
- package/dist/shared/providers/opencodeProvider.d.ts +19 -0
- package/dist/shared/providers/opencodeProvider.d.ts.map +1 -0
- package/dist/shared/providers/opencodeProvider.js +41 -0
- package/dist/shared/providers/opencodeProvider.js.map +1 -0
- package/dist/shared/providers/providerConfirmation.d.ts +56 -0
- package/dist/shared/providers/providerConfirmation.d.ts.map +1 -0
- package/dist/shared/providers/providerConfirmation.js +195 -0
- package/dist/shared/providers/providerConfirmation.js.map +1 -0
- package/dist/shared/providers/providerDiagnostics.d.ts +11 -0
- package/dist/shared/providers/providerDiagnostics.d.ts.map +1 -0
- package/dist/shared/providers/providerDiagnostics.js +28 -0
- package/dist/shared/providers/providerDiagnostics.js.map +1 -0
- package/dist/shared/providers/providerFactory.d.ts +72 -0
- package/dist/shared/providers/providerFactory.d.ts.map +1 -0
- package/dist/shared/providers/providerFactory.js +246 -0
- package/dist/shared/providers/providerFactory.js.map +1 -0
- package/dist/shared/providers/providerKeyedFactory.d.ts +14 -0
- package/dist/shared/providers/providerKeyedFactory.d.ts.map +1 -0
- package/dist/shared/providers/providerKeyedFactory.js +16 -0
- package/dist/shared/providers/providerKeyedFactory.js.map +1 -0
- package/dist/shared/providers/spawnLoggedCommand.d.ts +10 -0
- package/dist/shared/providers/spawnLoggedCommand.d.ts.map +1 -0
- package/dist/shared/providers/spawnLoggedCommand.js +304 -0
- package/dist/shared/providers/spawnLoggedCommand.js.map +1 -0
- package/dist/shared/providers/subprocessTemplateProvider.d.ts +19 -0
- package/dist/shared/providers/subprocessTemplateProvider.d.ts.map +1 -0
- package/dist/shared/providers/subprocessTemplateProvider.js +91 -0
- package/dist/shared/providers/subprocessTemplateProvider.js.map +1 -0
- package/dist/shared/providers/types.d.ts +43 -0
- package/dist/shared/providers/types.d.ts.map +1 -0
- package/dist/shared/providers/types.js +2 -0
- package/dist/shared/providers/types.js.map +1 -0
- package/dist/shared/providers/workerTaskLaunch.d.ts +32 -0
- package/dist/shared/providers/workerTaskLaunch.d.ts.map +1 -0
- package/dist/shared/providers/workerTaskLaunch.js +27 -0
- package/dist/shared/providers/workerTaskLaunch.js.map +1 -0
- package/dist/shared/quota/antigravityQuotaSource.d.ts +44 -0
- package/dist/shared/quota/antigravityQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/antigravityQuotaSource.js +101 -0
- package/dist/shared/quota/antigravityQuotaSource.js.map +1 -0
- package/dist/shared/quota/capacity.d.ts +283 -0
- package/dist/shared/quota/capacity.d.ts.map +1 -0
- package/dist/shared/quota/capacity.js +290 -0
- package/dist/shared/quota/capacity.js.map +1 -0
- package/dist/shared/quota/claudeCodeJsonLines.d.ts +15 -0
- package/dist/shared/quota/claudeCodeJsonLines.d.ts.map +1 -0
- package/dist/shared/quota/claudeCodeJsonLines.js +34 -0
- package/dist/shared/quota/claudeCodeJsonLines.js.map +1 -0
- package/dist/shared/quota/claudeOAuthQuotaSource.d.ts +56 -0
- package/dist/shared/quota/claudeOAuthQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/claudeOAuthQuotaSource.js +136 -0
- package/dist/shared/quota/claudeOAuthQuotaSource.js.map +1 -0
- package/dist/shared/quota/codexQuotaSource.d.ts +49 -0
- package/dist/shared/quota/codexQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/codexQuotaSource.js +96 -0
- package/dist/shared/quota/codexQuotaSource.js.map +1 -0
- package/dist/shared/quota/compositeQuotaSource.d.ts +29 -0
- package/dist/shared/quota/compositeQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/compositeQuotaSource.js +58 -0
- package/dist/shared/quota/compositeQuotaSource.js.map +1 -0
- package/dist/shared/quota/copilotQuotaSource.d.ts +57 -0
- package/dist/shared/quota/copilotQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/copilotQuotaSource.js +141 -0
- package/dist/shared/quota/copilotQuotaSource.js.map +1 -0
- package/dist/shared/quota/errorParsers/claudeCodeErrorParser.d.ts +7 -0
- package/dist/shared/quota/errorParsers/claudeCodeErrorParser.d.ts.map +1 -0
- package/dist/shared/quota/errorParsers/claudeCodeErrorParser.js +33 -0
- package/dist/shared/quota/errorParsers/claudeCodeErrorParser.js.map +1 -0
- package/dist/shared/quota/errorParsers/genericErrorParser.d.ts +10 -0
- package/dist/shared/quota/errorParsers/genericErrorParser.d.ts.map +1 -0
- package/dist/shared/quota/errorParsers/genericErrorParser.js +8 -0
- package/dist/shared/quota/errorParsers/genericErrorParser.js.map +1 -0
- package/dist/shared/quota/errorParsers/index.d.ts +6 -0
- package/dist/shared/quota/errorParsers/index.d.ts.map +1 -0
- package/dist/shared/quota/errorParsers/index.js +16 -0
- package/dist/shared/quota/errorParsers/index.js.map +1 -0
- package/dist/shared/quota/errorParsing.d.ts +8 -0
- package/dist/shared/quota/errorParsing.d.ts.map +1 -0
- package/dist/shared/quota/errorParsing.js +129 -0
- package/dist/shared/quota/errorParsing.js.map +1 -0
- package/dist/shared/quota/fileLock.d.ts +9 -0
- package/dist/shared/quota/fileLock.d.ts.map +1 -0
- package/dist/shared/quota/fileLock.js +202 -0
- package/dist/shared/quota/fileLock.js.map +1 -0
- package/dist/shared/quota/hostLimits.d.ts +16 -0
- package/dist/shared/quota/hostLimits.d.ts.map +1 -0
- package/dist/shared/quota/hostLimits.js +57 -0
- package/dist/shared/quota/hostLimits.js.map +1 -0
- package/dist/shared/quota/httpQuotaSource.d.ts +87 -0
- package/dist/shared/quota/httpQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/httpQuotaSource.js +90 -0
- package/dist/shared/quota/httpQuotaSource.js.map +1 -0
- package/dist/shared/quota/learnedQuotaSource.d.ts +8 -0
- package/dist/shared/quota/learnedQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/learnedQuotaSource.js +26 -0
- package/dist/shared/quota/learnedQuotaSource.js.map +1 -0
- package/dist/shared/quota/limits.d.ts +35 -0
- package/dist/shared/quota/limits.d.ts.map +1 -0
- package/dist/shared/quota/limits.js +110 -0
- package/dist/shared/quota/limits.js.map +1 -0
- package/dist/shared/quota/openCodeQuotaSource.d.ts +18 -0
- package/dist/shared/quota/openCodeQuotaSource.d.ts.map +1 -0
- package/dist/shared/quota/openCodeQuotaSource.js +84 -0
- package/dist/shared/quota/openCodeQuotaSource.js.map +1 -0
- package/dist/shared/quota/quotaSource.d.ts +29 -0
- package/dist/shared/quota/quotaSource.d.ts.map +1 -0
- package/dist/shared/quota/quotaSource.js +12 -0
- package/dist/shared/quota/quotaSource.js.map +1 -0
- package/dist/shared/quota/rollingEngine.d.ts +130 -0
- package/dist/shared/quota/rollingEngine.d.ts.map +1 -0
- package/dist/shared/quota/rollingEngine.js +153 -0
- package/dist/shared/quota/rollingEngine.js.map +1 -0
- package/dist/shared/quota/scheduler.d.ts +94 -0
- package/dist/shared/quota/scheduler.d.ts.map +1 -0
- package/dist/shared/quota/scheduler.js +313 -0
- package/dist/shared/quota/scheduler.js.map +1 -0
- package/dist/shared/quota/slidingWindow.d.ts +5 -0
- package/dist/shared/quota/slidingWindow.d.ts.map +1 -0
- package/dist/shared/quota/slidingWindow.js +29 -0
- package/dist/shared/quota/slidingWindow.js.map +1 -0
- package/dist/shared/quota/state.d.ts +27 -0
- package/dist/shared/quota/state.d.ts.map +1 -0
- package/dist/shared/quota/state.js +204 -0
- package/dist/shared/quota/state.js.map +1 -0
- package/dist/shared/quota/types.d.ts +109 -0
- package/dist/shared/quota/types.d.ts.map +1 -0
- package/dist/shared/quota/types.js +56 -0
- package/dist/shared/quota/types.js.map +1 -0
- package/dist/shared/reReview/projectionDiff.d.ts +65 -0
- package/dist/shared/reReview/projectionDiff.d.ts.map +1 -0
- package/dist/shared/reReview/projectionDiff.js +144 -0
- package/dist/shared/reReview/projectionDiff.js.map +1 -0
- package/dist/shared/rolling/pausedState.d.ts +109 -0
- package/dist/shared/rolling/pausedState.d.ts.map +1 -0
- package/dist/shared/rolling/pausedState.js +100 -0
- package/dist/shared/rolling/pausedState.js.map +1 -0
- package/dist/shared/tokens.d.ts +24 -0
- package/dist/shared/tokens.d.ts.map +1 -0
- package/dist/shared/tokens.js +54 -0
- package/dist/shared/tokens.js.map +1 -0
- package/dist/shared/tooling/allowlistedExec.d.ts +45 -0
- package/dist/shared/tooling/allowlistedExec.d.ts.map +1 -0
- package/dist/shared/tooling/allowlistedExec.js +340 -0
- package/dist/shared/tooling/allowlistedExec.js.map +1 -0
- package/dist/shared/tooling/analyzerDeps.d.ts +65 -0
- package/dist/shared/tooling/analyzerDeps.d.ts.map +1 -0
- package/dist/shared/tooling/analyzerDeps.js +130 -0
- package/dist/shared/tooling/analyzerDeps.js.map +1 -0
- package/dist/shared/tooling/exec.d.ts +99 -0
- package/dist/shared/tooling/exec.d.ts.map +1 -0
- package/dist/shared/tooling/exec.js +217 -0
- package/dist/shared/tooling/exec.js.map +1 -0
- package/dist/shared/tooling/repoConventions.d.ts +23 -0
- package/dist/shared/tooling/repoConventions.d.ts.map +1 -0
- package/dist/shared/tooling/repoConventions.js +177 -0
- package/dist/shared/tooling/repoConventions.js.map +1 -0
- package/dist/shared/tooling/testCommand.d.ts +17 -0
- package/dist/shared/tooling/testCommand.d.ts.map +1 -0
- package/dist/shared/tooling/testCommand.js +106 -0
- package/dist/shared/tooling/testCommand.js.map +1 -0
- package/dist/shared/types/accessDeclaration.d.ts +16 -0
- package/dist/shared/types/accessDeclaration.d.ts.map +1 -0
- package/dist/shared/types/accessDeclaration.js +9 -0
- package/dist/shared/types/accessDeclaration.js.map +1 -0
- package/dist/shared/types/contractPipeline/design.d.ts +74 -0
- package/dist/shared/types/contractPipeline/design.d.ts.map +1 -0
- package/dist/shared/types/contractPipeline/design.js +10 -0
- package/dist/shared/types/contractPipeline/design.js.map +1 -0
- package/dist/shared/types/contractPipeline/goal.d.ts +41 -0
- package/dist/shared/types/contractPipeline/goal.d.ts.map +1 -0
- package/dist/shared/types/contractPipeline/goal.js +10 -0
- package/dist/shared/types/contractPipeline/goal.js.map +1 -0
- package/dist/shared/types/contractPipeline/implementation.d.ts +64 -0
- package/dist/shared/types/contractPipeline/implementation.d.ts.map +1 -0
- package/dist/shared/types/contractPipeline/implementation.js +8 -0
- package/dist/shared/types/contractPipeline/implementation.js.map +1 -0
- package/dist/shared/types/contractPipeline/obligations.d.ts +141 -0
- package/dist/shared/types/contractPipeline/obligations.d.ts.map +1 -0
- package/dist/shared/types/contractPipeline/obligations.js +16 -0
- package/dist/shared/types/contractPipeline/obligations.js.map +1 -0
- package/dist/shared/types/contractPipeline/verification.d.ts +64 -0
- package/dist/shared/types/contractPipeline/verification.d.ts.map +1 -0
- package/dist/shared/types/contractPipeline/verification.js +10 -0
- package/dist/shared/types/contractPipeline/verification.js.map +1 -0
- package/dist/shared/types/contractPipeline.d.ts +36 -0
- package/dist/shared/types/contractPipeline.d.ts.map +1 -0
- package/dist/shared/types/contractPipeline.js +31 -0
- package/dist/shared/types/contractPipeline.js.map +1 -0
- package/dist/shared/types/disposition.d.ts +46 -0
- package/dist/shared/types/disposition.d.ts.map +1 -0
- package/dist/shared/types/disposition.js +22 -0
- package/dist/shared/types/disposition.js.map +1 -0
- package/dist/shared/types/finding.d.ts +1463 -0
- package/dist/shared/types/finding.d.ts.map +1 -0
- package/dist/shared/types/finding.js +234 -0
- package/dist/shared/types/finding.js.map +1 -0
- package/dist/shared/types/flows.d.ts +84 -0
- package/dist/shared/types/flows.d.ts.map +1 -0
- package/dist/shared/types/flows.js +23 -0
- package/dist/shared/types/flows.js.map +1 -0
- package/dist/shared/types/graph.d.ts +359 -0
- package/dist/shared/types/graph.d.ts.map +1 -0
- package/dist/shared/types/graph.js +38 -0
- package/dist/shared/types/graph.js.map +1 -0
- package/dist/shared/types/intentCheckpoint.d.ts +95 -0
- package/dist/shared/types/intentCheckpoint.d.ts.map +1 -0
- package/dist/shared/types/intentCheckpoint.js +2 -0
- package/dist/shared/types/intentCheckpoint.js.map +1 -0
- package/dist/shared/types/intentInterpretation.d.ts +57 -0
- package/dist/shared/types/intentInterpretation.d.ts.map +1 -0
- package/dist/shared/types/intentInterpretation.js +20 -0
- package/dist/shared/types/intentInterpretation.js.map +1 -0
- package/dist/shared/types/lens.d.ts +38 -0
- package/dist/shared/types/lens.d.ts.map +1 -0
- package/dist/shared/types/lens.js +80 -0
- package/dist/shared/types/lens.js.map +1 -0
- package/dist/shared/types/obligationLedger.d.ts +35 -0
- package/dist/shared/types/obligationLedger.d.ts.map +1 -0
- package/dist/shared/types/obligationLedger.js +77 -0
- package/dist/shared/types/obligationLedger.js.map +1 -0
- package/dist/shared/types/providerConfirmation.d.ts +51 -0
- package/dist/shared/types/providerConfirmation.d.ts.map +1 -0
- package/dist/shared/types/providerConfirmation.js +19 -0
- package/dist/shared/types/providerConfirmation.js.map +1 -0
- package/dist/shared/types/remediationOutcome.d.ts +41 -0
- package/dist/shared/types/remediationOutcome.d.ts.map +1 -0
- package/dist/shared/types/remediationOutcome.js +7 -0
- package/dist/shared/types/remediationOutcome.js.map +1 -0
- package/dist/shared/types/risk.d.ts +52 -0
- package/dist/shared/types/risk.d.ts.map +1 -0
- package/dist/shared/types/risk.js +17 -0
- package/dist/shared/types/risk.js.map +1 -0
- package/dist/shared/types/rollingDispatch.d.ts +61 -0
- package/dist/shared/types/rollingDispatch.d.ts.map +1 -0
- package/dist/shared/types/rollingDispatch.js +19 -0
- package/dist/shared/types/rollingDispatch.js.map +1 -0
- package/dist/shared/types/runLedger.d.ts +18 -0
- package/dist/shared/types/runLedger.d.ts.map +1 -0
- package/dist/shared/types/runLedger.js +7 -0
- package/dist/shared/types/runLedger.js.map +1 -0
- package/dist/shared/types/sessionConfig.d.ts +294 -0
- package/dist/shared/types/sessionConfig.d.ts.map +1 -0
- package/dist/shared/types/sessionConfig.js +44 -0
- package/dist/shared/types/sessionConfig.js.map +1 -0
- package/dist/shared/types/stepContract.d.ts +10 -0
- package/dist/shared/types/stepContract.d.ts.map +1 -0
- package/dist/shared/types/stepContract.js +4 -0
- package/dist/shared/types/stepContract.js.map +1 -0
- package/dist/shared/types/surfaces.d.ts +73 -0
- package/dist/shared/types/surfaces.d.ts.map +1 -0
- package/dist/shared/types/surfaces.js +21 -0
- package/dist/shared/types/surfaces.js.map +1 -0
- package/dist/shared/validation/basic.d.ts +24 -0
- package/dist/shared/validation/basic.d.ts.map +1 -0
- package/dist/shared/validation/basic.js +57 -0
- package/dist/shared/validation/basic.js.map +1 -0
- package/dist/shared/validation/findingGrounding.d.ts +45 -0
- package/dist/shared/validation/findingGrounding.d.ts.map +1 -0
- package/dist/shared/validation/findingGrounding.js +103 -0
- package/dist/shared/validation/findingGrounding.js.map +1 -0
- package/dist/shared/validation/findingsReport.d.ts +42 -0
- package/dist/shared/validation/findingsReport.d.ts.map +1 -0
- package/dist/shared/validation/findingsReport.js +76 -0
- package/dist/shared/validation/findingsReport.js.map +1 -0
- package/dist/shared/validation/sessionConfig.d.ts +22 -0
- package/dist/shared/validation/sessionConfig.d.ts.map +1 -0
- package/dist/shared/validation/sessionConfig.js +38 -0
- package/dist/shared/validation/sessionConfig.js.map +1 -0
- package/docs/audit-pkg/contracts.md +227 -0
- package/docs/audit-pkg/development.md +112 -0
- package/docs/audit-pkg/history.md +66 -0
- package/docs/audit-pkg/operator-guide.md +204 -0
- package/docs/audit-pkg/product.md +119 -0
- package/docs/audit-pkg/release.md +131 -0
- package/opencode.json +159 -0
- package/package.json +104 -0
- package/remediate-code.mjs +116 -0
- package/schemas/audit_result.schema.json +510 -0
- package/schemas/audit_results.schema.json +514 -0
- package/schemas/audit_task.schema.json +127 -0
- package/schemas/finding.schema.json +261 -0
- package/schemas/lens.schema.json +19 -0
- package/scripts/audit/postinstall.mjs +385 -0
- package/scripts/postinstall.mjs +24 -0
- package/scripts/remediate/postinstall.mjs +387 -0
- package/skills/audit-code/SKILL.md +166 -0
- package/skills/audit-code/agents/openai.yaml +4 -0
- package/skills/audit-code/audit-code.prompt.md +112 -0
- package/skills/audit-code/opencode-command-template.txt +13 -0
- package/skills/remediate-code/SKILL.md +90 -0
- package/skills/remediate-code/agents/openai.yaml +4 -0
- package/skills/remediate-code/remediate-code.prompt.md +94 -0
- package/templates/AGENTS.remediate-code.md +6 -0
|
@@ -0,0 +1,992 @@
|
|
|
1
|
+
import { dirname, extname, isAbsolute, join } from "node:path";
|
|
2
|
+
import { readFileSync, existsSync } from "node:fs";
|
|
3
|
+
import { AGENT_FEEDBACK_FILENAME, parseReflectionsNdjson, readOptionalJsonFile, readOptionalTextFile, renderProcessFeedbackSection, stagedAndUntracked, writeJsonFile, writeTextFile, } from "audit-tools/shared";
|
|
4
|
+
import { CONTRACT_PIPELINE_VERIFICATION_REPORT_VERSION } from "audit-tools/shared";
|
|
5
|
+
import { runCommand, runShellCommand } from "../utils/commands.js";
|
|
6
|
+
import { FAILURE_OUTPUT_TAIL_CHARS } from "./constants.js";
|
|
7
|
+
import { intakePaths } from "../intake.js";
|
|
8
|
+
import { isAuditFindingsReport } from "./plan.js";
|
|
9
|
+
import { dispositionToOutcomeStatus, isInProgressStatus, isSkipStatus, isVerifiedCompleteStatus, statusToDisposition, } from "../state/itemStatus.js";
|
|
10
|
+
const OUTCOME_KEYS = [
|
|
11
|
+
"resolved",
|
|
12
|
+
"verified_no_change",
|
|
13
|
+
"inappropriate",
|
|
14
|
+
"ignored",
|
|
15
|
+
"blocked",
|
|
16
|
+
];
|
|
17
|
+
/** Retry-oriented final status per outcome (see RemediationOutcomeFinalStatus). */
|
|
18
|
+
const FINAL_STATUS_BY_OUTCOME = {
|
|
19
|
+
resolved: "fixed",
|
|
20
|
+
verified_no_change: "fixed",
|
|
21
|
+
inappropriate: "skipped",
|
|
22
|
+
ignored: "ignored",
|
|
23
|
+
blocked: "failed",
|
|
24
|
+
};
|
|
25
|
+
// Skipped and ignored outcomes must always carry a non-empty reason in the
|
|
26
|
+
// outcomes contract; these defaults cover items whose state lost the rationale.
|
|
27
|
+
const DEFAULT_REASON_BY_OUTCOME = {
|
|
28
|
+
inappropriate: "Deemed inappropriate during remediation.",
|
|
29
|
+
ignored: "Ignored by user.",
|
|
30
|
+
};
|
|
31
|
+
/** Project the documented ItemSpec onto the outcomes contract's summary shape. */
|
|
32
|
+
function summarizeItemSpec(spec) {
|
|
33
|
+
return {
|
|
34
|
+
concrete_change: spec.concrete_change,
|
|
35
|
+
...(spec.no_change !== undefined ? { no_change: spec.no_change } : {}),
|
|
36
|
+
...(spec.touched_files ? { touched_files: spec.touched_files } : {}),
|
|
37
|
+
tests_to_write: (spec.tests_to_write ?? []).map((test) => test.name),
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Phase 7B — capture one outcome per finding (lens, affected file types, how it
|
|
42
|
+
* landed, rework count, closing status). Surface only: the auditor does not
|
|
43
|
+
* consume this automatically.
|
|
44
|
+
*/
|
|
45
|
+
function closingStatusReason(closingResult) {
|
|
46
|
+
if (closingResult.status === "skipped" && closingResult.action === "none") {
|
|
47
|
+
return "closing action is 'none' — no commit/push/publish configured";
|
|
48
|
+
}
|
|
49
|
+
if (closingResult.status === "failed") {
|
|
50
|
+
return `closing action '${closingResult.action}' failed`;
|
|
51
|
+
}
|
|
52
|
+
return undefined;
|
|
53
|
+
}
|
|
54
|
+
function parseTimestamp(value) {
|
|
55
|
+
if (!value)
|
|
56
|
+
return undefined;
|
|
57
|
+
const timestamp = Date.parse(value);
|
|
58
|
+
return Number.isFinite(timestamp) ? timestamp : undefined;
|
|
59
|
+
}
|
|
60
|
+
function durationBetweenMs(startedAt, completedAt) {
|
|
61
|
+
const started = parseTimestamp(startedAt);
|
|
62
|
+
const completed = parseTimestamp(completedAt);
|
|
63
|
+
if (started === undefined || completed === undefined || completed < started) {
|
|
64
|
+
return undefined;
|
|
65
|
+
}
|
|
66
|
+
return completed - started;
|
|
67
|
+
}
|
|
68
|
+
export function buildRemediationOutcomesReport(state, closingResult) {
|
|
69
|
+
const findingsById = new Map((state.plan?.findings ?? []).map((finding) => [finding.id, finding]));
|
|
70
|
+
const blocksById = new Map((state.plan?.blocks ?? []).map((block) => [block.block_id, block]));
|
|
71
|
+
const outcomes = [];
|
|
72
|
+
const closeReason = closingStatusReason(closingResult);
|
|
73
|
+
for (const item of Object.values(state.items ?? {})) {
|
|
74
|
+
// Derive the outcome from the single status→disposition→outcome authority.
|
|
75
|
+
// An in-progress status means the run was force-closed while the item was
|
|
76
|
+
// still mid-flight: record it as a failed (`blocked`) outcome — never drop
|
|
77
|
+
// it — and preserve the original state so a retry sees where it stood.
|
|
78
|
+
let outcome;
|
|
79
|
+
let originalState;
|
|
80
|
+
if (isInProgressStatus(item.status)) {
|
|
81
|
+
outcome = "blocked";
|
|
82
|
+
originalState = item.status;
|
|
83
|
+
}
|
|
84
|
+
else {
|
|
85
|
+
outcome = dispositionToOutcomeStatus(statusToDisposition(item.status));
|
|
86
|
+
}
|
|
87
|
+
const finding = findingsById.get(item.finding_id);
|
|
88
|
+
const fileExts = [
|
|
89
|
+
...new Set((finding?.affected_files ?? [])
|
|
90
|
+
.map((file) => extname(file.path).toLowerCase())
|
|
91
|
+
.filter((ext) => ext.length > 0)),
|
|
92
|
+
].sort();
|
|
93
|
+
const durationMs = durationBetweenMs(item.started_at, item.completed_at);
|
|
94
|
+
const isNonResolved = outcome !== "resolved" && outcome !== "verified_no_change";
|
|
95
|
+
let reason = isNonResolved ? item.failure_reason : undefined;
|
|
96
|
+
if (originalState) {
|
|
97
|
+
reason = `Force-closed while non-terminal (original state '${originalState}').${item.failure_reason ? ` ${item.failure_reason}` : ""}`;
|
|
98
|
+
}
|
|
99
|
+
else if (isNonResolved && !reason) {
|
|
100
|
+
reason = DEFAULT_REASON_BY_OUTCOME[outcome];
|
|
101
|
+
}
|
|
102
|
+
const base = {
|
|
103
|
+
finding_id: item.finding_id,
|
|
104
|
+
lens: finding?.lens ?? "unknown",
|
|
105
|
+
file_exts: fileExts,
|
|
106
|
+
outcome,
|
|
107
|
+
rework_count: item.rework_count ?? 0,
|
|
108
|
+
closing_status: closingResult.status,
|
|
109
|
+
...(closeReason ? { closing_status_reason: closeReason } : {}),
|
|
110
|
+
...(reason ? { reason } : {}),
|
|
111
|
+
...(item.started_at ? { started_at: item.started_at } : {}),
|
|
112
|
+
...(item.completed_at ? { completed_at: item.completed_at } : {}),
|
|
113
|
+
...(durationMs !== undefined ? { duration_ms: durationMs } : {}),
|
|
114
|
+
};
|
|
115
|
+
if (!finding) {
|
|
116
|
+
// Degenerate (corrupt state): without the plan finding there is no payload
|
|
117
|
+
// to carry — emit the lean per-finding outcome rather than inventing one.
|
|
118
|
+
outcomes.push(base);
|
|
119
|
+
continue;
|
|
120
|
+
}
|
|
121
|
+
const enriched = {
|
|
122
|
+
...base,
|
|
123
|
+
finding,
|
|
124
|
+
...(item.item_spec ? { item_spec: summarizeItemSpec(item.item_spec) } : {}),
|
|
125
|
+
block_id: item.block_id,
|
|
126
|
+
block_dependencies: [...(blocksById.get(item.block_id)?.dependencies ?? [])],
|
|
127
|
+
final_status: FINAL_STATUS_BY_OUTCOME[outcome],
|
|
128
|
+
...(originalState ? { original_state: originalState } : {}),
|
|
129
|
+
};
|
|
130
|
+
outcomes.push(enriched);
|
|
131
|
+
}
|
|
132
|
+
outcomes.sort((a, b) => a.finding_id.localeCompare(b.finding_id));
|
|
133
|
+
const byOutcome = Object.fromEntries(OUTCOME_KEYS.map((key) => [key, 0]));
|
|
134
|
+
const byLens = {};
|
|
135
|
+
for (const entry of outcomes) {
|
|
136
|
+
byOutcome[entry.outcome] += 1;
|
|
137
|
+
const lensBucket = (byLens[entry.lens] ??= {});
|
|
138
|
+
lensBucket[entry.outcome] = (lensBucket[entry.outcome] ?? 0) + 1;
|
|
139
|
+
}
|
|
140
|
+
const startedEntries = outcomes
|
|
141
|
+
.map((outcome) => ({
|
|
142
|
+
value: outcome.started_at,
|
|
143
|
+
timestamp: parseTimestamp(outcome.started_at),
|
|
144
|
+
}))
|
|
145
|
+
.filter((entry) => entry.value !== undefined && entry.timestamp !== undefined);
|
|
146
|
+
const completedEntries = outcomes
|
|
147
|
+
.map((outcome) => ({
|
|
148
|
+
value: outcome.completed_at,
|
|
149
|
+
timestamp: parseTimestamp(outcome.completed_at),
|
|
150
|
+
}))
|
|
151
|
+
.filter((entry) => entry.value !== undefined && entry.timestamp !== undefined);
|
|
152
|
+
const aggregateStarted = startedEntries.reduce((earliest, entry) => !earliest || entry.timestamp < earliest.timestamp ? entry : earliest, undefined);
|
|
153
|
+
const aggregateCompleted = completedEntries.reduce((latest, entry) => !latest || entry.timestamp > latest.timestamp ? entry : latest, undefined);
|
|
154
|
+
const aggregateDuration = aggregateStarted && aggregateCompleted
|
|
155
|
+
? durationBetweenMs(aggregateStarted.value, aggregateCompleted.value)
|
|
156
|
+
: undefined;
|
|
157
|
+
return {
|
|
158
|
+
contract_version: "remediate-code-outcomes/v1alpha1",
|
|
159
|
+
total: outcomes.length,
|
|
160
|
+
by_outcome: byOutcome,
|
|
161
|
+
by_lens: byLens,
|
|
162
|
+
...(aggregateStarted ? { started_at: aggregateStarted.value } : {}),
|
|
163
|
+
...(aggregateCompleted ? { completed_at: aggregateCompleted.value } : {}),
|
|
164
|
+
...(aggregateDuration !== undefined ? { duration_ms: aggregateDuration } : {}),
|
|
165
|
+
outcomes,
|
|
166
|
+
};
|
|
167
|
+
}
|
|
168
|
+
/** Drop-reason discriminator per never-planned coverage disposition. */
|
|
169
|
+
const DROP_REASON_BY_DISPOSITION = {
|
|
170
|
+
folded_into: "cross_lens_dedup",
|
|
171
|
+
dropped_by_checkpoint: "intent_checkpoint",
|
|
172
|
+
dropped_no_evidence: "no_evidence",
|
|
173
|
+
dropped_phantom_paths: "phantom_paths",
|
|
174
|
+
declined_by_review: "review_gate",
|
|
175
|
+
};
|
|
176
|
+
/**
|
|
177
|
+
* Best-effort recovery of full Finding payloads for never-planned findings:
|
|
178
|
+
* re-read the run's structured-audit intake source(s) (recorded in
|
|
179
|
+
* intake/source-manifest.json) and index their findings by id. Never-planned
|
|
180
|
+
* findings were removed from the plan before state.json was written, so the
|
|
181
|
+
* intake source is the remaining payload authority for them. Any failure
|
|
182
|
+
* (missing manifest, moved input, free-form source) degrades to an empty map —
|
|
183
|
+
* the coverage entry then keeps its id/title without a payload.
|
|
184
|
+
*/
|
|
185
|
+
async function loadStructuredSourceFindingsById(options) {
|
|
186
|
+
const findingsById = new Map();
|
|
187
|
+
let manifest;
|
|
188
|
+
try {
|
|
189
|
+
manifest = await readOptionalJsonFile(intakePaths(options.artifactsDir).sourceManifest);
|
|
190
|
+
}
|
|
191
|
+
catch {
|
|
192
|
+
return findingsById;
|
|
193
|
+
}
|
|
194
|
+
for (const source of manifest?.sources ?? []) {
|
|
195
|
+
if (source.type !== "structured_audit")
|
|
196
|
+
continue;
|
|
197
|
+
const sourcePath = isAbsolute(source.path)
|
|
198
|
+
? source.path
|
|
199
|
+
: join(options.root, source.path);
|
|
200
|
+
try {
|
|
201
|
+
const parsed = JSON.parse(readFileSync(sourcePath, "utf8"));
|
|
202
|
+
if (!isAuditFindingsReport(parsed))
|
|
203
|
+
continue;
|
|
204
|
+
for (const finding of parsed.findings) {
|
|
205
|
+
if (finding && typeof finding.id === "string" && !findingsById.has(finding.id)) {
|
|
206
|
+
findingsById.set(finding.id, finding);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
catch {
|
|
211
|
+
// Best-effort: an unreadable source just means no payload recovery.
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
return findingsById;
|
|
215
|
+
}
|
|
216
|
+
/**
|
|
217
|
+
* Build the outcomes file's coverage-ledger section: the plan's coverage ledger
|
|
218
|
+
* with every never-planned entry (cross-lens-deduped, checkpoint-dropped,
|
|
219
|
+
* no-evidence, phantom-paths) enriched with a `drop_reason` discriminator and
|
|
220
|
+
* its full `Finding` payload. Payloads resolve from, in order: the ledger entry
|
|
221
|
+
* itself (when the plan recorded one), the live plan findings, and the
|
|
222
|
+
* structured-audit intake source. Must run BEFORE close deletes state.json /
|
|
223
|
+
* the artifacts dir — they are the only payload sources.
|
|
224
|
+
*/
|
|
225
|
+
export async function buildOutcomeCoverageLedger(state, options) {
|
|
226
|
+
const ledger = state.plan_coverage;
|
|
227
|
+
if (!ledger)
|
|
228
|
+
return undefined;
|
|
229
|
+
const plannedById = new Map((state.plan?.findings ?? []).map((finding) => [finding.id, finding]));
|
|
230
|
+
const needsSourcePayloads = ledger.entries.some((entry) => DROP_REASON_BY_DISPOSITION[entry.disposition] !== undefined &&
|
|
231
|
+
!entry.finding &&
|
|
232
|
+
!plannedById.has(entry.finding_id));
|
|
233
|
+
const sourceById = needsSourcePayloads
|
|
234
|
+
? await loadStructuredSourceFindingsById(options)
|
|
235
|
+
: new Map();
|
|
236
|
+
const entries = ledger.entries.map((entry) => {
|
|
237
|
+
const dropReason = DROP_REASON_BY_DISPOSITION[entry.disposition];
|
|
238
|
+
if (!dropReason)
|
|
239
|
+
return entry;
|
|
240
|
+
const finding = entry.finding ??
|
|
241
|
+
plannedById.get(entry.finding_id) ??
|
|
242
|
+
sourceById.get(entry.finding_id);
|
|
243
|
+
return {
|
|
244
|
+
...entry,
|
|
245
|
+
...(finding ? { finding } : {}),
|
|
246
|
+
drop_reason: dropReason,
|
|
247
|
+
};
|
|
248
|
+
});
|
|
249
|
+
return { ...ledger, entries };
|
|
250
|
+
}
|
|
251
|
+
function trimOutput(value) {
|
|
252
|
+
const text = Buffer.isBuffer(value) ? value.toString() : String(value ?? "");
|
|
253
|
+
const trimmed = text.trim().slice(-FAILURE_OUTPUT_TAIL_CHARS);
|
|
254
|
+
return trimmed.length > 0 ? trimmed : undefined;
|
|
255
|
+
}
|
|
256
|
+
function commandResult(command, result) {
|
|
257
|
+
return {
|
|
258
|
+
command,
|
|
259
|
+
exit_code: result.status,
|
|
260
|
+
stdout: trimOutput(result.stdout),
|
|
261
|
+
stderr: trimOutput(result.stderr),
|
|
262
|
+
};
|
|
263
|
+
}
|
|
264
|
+
function runTrackedCommand(root, command, args) {
|
|
265
|
+
const result = runCommand(command, args, {
|
|
266
|
+
cwd: root,
|
|
267
|
+
stdio: ["ignore", "pipe", "pipe"],
|
|
268
|
+
});
|
|
269
|
+
return commandResult([command, ...args], result);
|
|
270
|
+
}
|
|
271
|
+
function isSuccess(result) {
|
|
272
|
+
return result.exit_code === 0;
|
|
273
|
+
}
|
|
274
|
+
const STAGING_EXCLUDE_PATTERNS = [
|
|
275
|
+
/^\.audit-tools\//,
|
|
276
|
+
/^\.env($|\.)/,
|
|
277
|
+
];
|
|
278
|
+
export function collectStagingFiles(root) {
|
|
279
|
+
return stagedAndUntracked(root).filter((f) => !STAGING_EXCLUDE_PATTERNS.some((pattern) => pattern.test(f)));
|
|
280
|
+
}
|
|
281
|
+
/**
|
|
282
|
+
* Generate a commit message derived from item summaries and finding titles.
|
|
283
|
+
* Falls back to a generic message when there are no findings to summarize.
|
|
284
|
+
*/
|
|
285
|
+
function generateCommitMessage(state) {
|
|
286
|
+
const findings = state.plan?.findings ?? [];
|
|
287
|
+
const items = Object.values(state.items ?? {});
|
|
288
|
+
const resolvedFindingIds = new Set(items
|
|
289
|
+
.filter((i) => isVerifiedCompleteStatus(i.status))
|
|
290
|
+
.map((i) => i.finding_id));
|
|
291
|
+
const resolved = findings.filter((f) => resolvedFindingIds.has(f.id));
|
|
292
|
+
if (resolved.length === 0) {
|
|
293
|
+
return "Remediation complete";
|
|
294
|
+
}
|
|
295
|
+
if (resolved.length === 1) {
|
|
296
|
+
return `Fix: ${resolved[0].title ?? resolved[0].id}`;
|
|
297
|
+
}
|
|
298
|
+
const titles = resolved
|
|
299
|
+
.slice(0, 3)
|
|
300
|
+
.map((f) => f.title ?? f.id)
|
|
301
|
+
.join(", ");
|
|
302
|
+
const suffix = resolved.length > 3 ? ` (+${resolved.length - 3} more)` : "";
|
|
303
|
+
return `Fix: ${titles}${suffix}`;
|
|
304
|
+
}
|
|
305
|
+
/** Actions that require user confirmation before executing. */
|
|
306
|
+
const PREVIEW_ACTIONS = new Set(["commit", "push", "open-pr", "publish"]);
|
|
307
|
+
/**
|
|
308
|
+
* Check whether the closing action needs a confirmation preview. Returns the
|
|
309
|
+
* preview data if confirmation is needed, or undefined if the action may
|
|
310
|
+
* proceed immediately (pre_authorized, action === 'none'/'tag'/'custom', or
|
|
311
|
+
* no files to stage).
|
|
312
|
+
*/
|
|
313
|
+
function checkClosingPreview(state, options) {
|
|
314
|
+
const closingPlan = state.closing_plan;
|
|
315
|
+
if (closingPlan.pre_authorized === true)
|
|
316
|
+
return undefined;
|
|
317
|
+
if (!PREVIEW_ACTIONS.has(closingPlan.action))
|
|
318
|
+
return undefined;
|
|
319
|
+
const files = collectStagingFiles(options.root);
|
|
320
|
+
const commitMessage = generateCommitMessage(state);
|
|
321
|
+
return { files, commit_message: commitMessage };
|
|
322
|
+
}
|
|
323
|
+
export function executeClosingAction(state, options) {
|
|
324
|
+
const action = state.closing_plan.action;
|
|
325
|
+
if (action === "none") {
|
|
326
|
+
return {
|
|
327
|
+
contract_version: "remediate-code-closing-result/v1alpha1",
|
|
328
|
+
action,
|
|
329
|
+
status: "skipped",
|
|
330
|
+
commands: [],
|
|
331
|
+
};
|
|
332
|
+
}
|
|
333
|
+
const commands = [];
|
|
334
|
+
const run = (command, args) => {
|
|
335
|
+
const result = runTrackedCommand(options.root, command, args);
|
|
336
|
+
commands.push(result);
|
|
337
|
+
return isSuccess(result);
|
|
338
|
+
};
|
|
339
|
+
if (action === "commit" || action === "push" || action === "open-pr") {
|
|
340
|
+
const files = collectStagingFiles(options.root);
|
|
341
|
+
// Nothing to stage → vacuous success: no commit, push, or PR is attempted,
|
|
342
|
+
// so `commands` stays empty and the status is success.
|
|
343
|
+
if (files.length === 0) {
|
|
344
|
+
console.warn("No modified files to stage — skipping commit.");
|
|
345
|
+
return {
|
|
346
|
+
contract_version: "remediate-code-closing-result/v1alpha1",
|
|
347
|
+
action,
|
|
348
|
+
status: "success",
|
|
349
|
+
commands: [],
|
|
350
|
+
};
|
|
351
|
+
}
|
|
352
|
+
const commitMessage = state.closing_plan.closing_action_preview?.commit_message
|
|
353
|
+
?? generateCommitMessage(state);
|
|
354
|
+
const committed = run("git", ["add", "--", ...files]) &&
|
|
355
|
+
run("git", ["commit", "-m", commitMessage]);
|
|
356
|
+
if (committed && action === "push") {
|
|
357
|
+
run("git", ["push"]);
|
|
358
|
+
}
|
|
359
|
+
else if (committed && action === "open-pr") {
|
|
360
|
+
run("git", ["push"]) && run("gh", ["pr", "create", "--fill"]);
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
else if (action === "publish") {
|
|
364
|
+
run("npm", ["publish"]);
|
|
365
|
+
}
|
|
366
|
+
else if (action === "tag") {
|
|
367
|
+
run("git", ["tag", "auto-remediation"]);
|
|
368
|
+
}
|
|
369
|
+
else if (action === "custom" && state.closing_plan.custom_command?.length) {
|
|
370
|
+
run(state.closing_plan.custom_command[0], state.closing_plan.custom_command.slice(1));
|
|
371
|
+
}
|
|
372
|
+
return {
|
|
373
|
+
contract_version: "remediate-code-closing-result/v1alpha1",
|
|
374
|
+
action,
|
|
375
|
+
status: commands.every(isSuccess) ? "success" : "failed",
|
|
376
|
+
commands,
|
|
377
|
+
};
|
|
378
|
+
}
|
|
379
|
+
/**
|
|
380
|
+
* Run the plan's combined test suite over the fully merged post-remediation
|
|
381
|
+
* state. Returns pass/fail plus the failure-output tail. No test_command =>
|
|
382
|
+
* vacuously passing.
|
|
383
|
+
*/
|
|
384
|
+
function runCombinedTestSuite(state, options) {
|
|
385
|
+
console.log("Running full test suite on combined post-remediation state...");
|
|
386
|
+
if (!state.plan?.test_command) {
|
|
387
|
+
return { passed: true, duration_ms: 0, output: "" };
|
|
388
|
+
}
|
|
389
|
+
const suiteName = Array.isArray(state.plan.test_command)
|
|
390
|
+
? state.plan.test_command.join(" ")
|
|
391
|
+
: state.plan.test_command;
|
|
392
|
+
const startedAt = Date.now();
|
|
393
|
+
const result = runShellCommand(state.plan.test_command, {
|
|
394
|
+
cwd: options.root,
|
|
395
|
+
stdio: ["ignore", "pipe", "pipe"],
|
|
396
|
+
});
|
|
397
|
+
const durationMs = Date.now() - startedAt;
|
|
398
|
+
if (result.status === 0) {
|
|
399
|
+
return { passed: true, suite_name: suiteName, duration_ms: durationMs, output: "" };
|
|
400
|
+
}
|
|
401
|
+
const output = ((result.stdout?.toString() ?? "") + (result.stderr?.toString() ?? ""))
|
|
402
|
+
.trim()
|
|
403
|
+
.slice(-FAILURE_OUTPUT_TAIL_CHARS);
|
|
404
|
+
return { passed: false, suite_name: suiteName, duration_ms: durationMs, output };
|
|
405
|
+
}
|
|
406
|
+
/**
|
|
407
|
+
* Parse test output to extract implicated file paths. Looks for common test
|
|
408
|
+
* runner patterns (e.g. "FAIL src/foo.ts", "at src/foo.ts:12", "● foo.ts").
|
|
409
|
+
*/
|
|
410
|
+
function extractImplicatedPaths(testOutput) {
|
|
411
|
+
const paths = new Set();
|
|
412
|
+
// Match patterns like: FAIL src/foo.ts, at Object.<anonymous> (src/foo.ts:12),
|
|
413
|
+
// src/foo.ts:12:3, ● src/foo.ts
|
|
414
|
+
const pathPattern = /(?:FAIL\s+|at\s+\S+\s+\(|●\s+)?([^\s()]+\.[a-z]{1,6})(?::\d+)?/g;
|
|
415
|
+
let match;
|
|
416
|
+
while ((match = pathPattern.exec(testOutput)) !== null) {
|
|
417
|
+
const candidate = match[1];
|
|
418
|
+
// Only keep plausible repo-relative paths (contain at least one slash or look like a file)
|
|
419
|
+
if (candidate.includes("/") || candidate.includes("\\") || /\.[a-z]{1,6}$/.test(candidate)) {
|
|
420
|
+
// Normalize backslashes, strip leading ./
|
|
421
|
+
const normalized = candidate.replace(/\\/g, "/").replace(/^\.\//, "");
|
|
422
|
+
if (!normalized.startsWith("node_modules/")) {
|
|
423
|
+
paths.add(normalized);
|
|
424
|
+
}
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
return [...paths];
|
|
428
|
+
}
|
|
429
|
+
/**
|
|
430
|
+
* On a combined-test failure, selectively re-block items whose touched_files
|
|
431
|
+
* overlap with the failing tests' implicated paths. When attribution is
|
|
432
|
+
* ambiguous (no overlap found), falls back to re-blocking all resolved items.
|
|
433
|
+
* Returns whether any item was blocked — the caller transitions back to triage.
|
|
434
|
+
*/
|
|
435
|
+
function blockResolvedItemsOnCombinedFailure(state, testOutput) {
|
|
436
|
+
const resolvedItems = Object.values(state.items ?? {}).filter((i) => isVerifiedCompleteStatus(i.status));
|
|
437
|
+
if (resolvedItems.length === 0)
|
|
438
|
+
return false;
|
|
439
|
+
const implicatedPaths = extractImplicatedPaths(testOutput);
|
|
440
|
+
const now = new Date().toISOString();
|
|
441
|
+
// Attempt attribution: find items whose touched_files overlap implicated paths.
|
|
442
|
+
let attributed = [];
|
|
443
|
+
if (implicatedPaths.length > 0) {
|
|
444
|
+
for (const item of resolvedItems) {
|
|
445
|
+
const touchedFiles = item.item_spec?.touched_files ?? [];
|
|
446
|
+
const overlaps = touchedFiles.some((tf) => implicatedPaths.some((ip) => tf === ip || tf.endsWith(`/${ip}`) || ip.endsWith(`/${tf}`) || tf.endsWith(ip) || ip.endsWith(tf)));
|
|
447
|
+
if (overlaps)
|
|
448
|
+
attributed.push(item);
|
|
449
|
+
}
|
|
450
|
+
}
|
|
451
|
+
const fallback = attributed.length === 0;
|
|
452
|
+
const toBlock = fallback ? resolvedItems : attributed;
|
|
453
|
+
const attributionNote = fallback
|
|
454
|
+
? `Attribution attempt found no touched_files overlap with failing paths [${implicatedPaths.slice(0, 5).join(", ")}]; falling back to re-blocking all resolved items.`
|
|
455
|
+
: `Attributed to ${attributed.length} item(s) with overlapping touched_files [${implicatedPaths.slice(0, 5).join(", ")}].`;
|
|
456
|
+
for (const item of toBlock) {
|
|
457
|
+
item.status = "blocked";
|
|
458
|
+
item.completed_at = now;
|
|
459
|
+
item.failure_reason = `Combined test suite failed after remediation. ${attributionNote}${testOutput ? `\n\nTest output:\n${testOutput}` : ""}`;
|
|
460
|
+
}
|
|
461
|
+
return true;
|
|
462
|
+
}
|
|
463
|
+
/**
|
|
464
|
+
* Run end-to-end tests on the fully merged state. E2e runs once here (not
|
|
465
|
+
* per-block) because interdependent refactors can break e2e flows even when
|
|
466
|
+
* per-item unit tests pass. Returns `{ ran: false }` when no e2e_command is
|
|
467
|
+
* configured. Never throws — failure is returned as `passed: false`.
|
|
468
|
+
*/
|
|
469
|
+
function runE2eTests(state, options) {
|
|
470
|
+
if (!state.plan?.e2e_command) {
|
|
471
|
+
return { ran: false, passed: true, output: "" };
|
|
472
|
+
}
|
|
473
|
+
console.log("Running end-to-end tests on combined post-remediation state...");
|
|
474
|
+
const e2eResult = runShellCommand(state.plan.e2e_command, {
|
|
475
|
+
cwd: options.root,
|
|
476
|
+
stdio: ["ignore", "pipe", "pipe"],
|
|
477
|
+
});
|
|
478
|
+
const e2ePassed = e2eResult.status === 0;
|
|
479
|
+
if (!e2ePassed) {
|
|
480
|
+
const e2eOutput = ((e2eResult.stdout?.toString() ?? "") +
|
|
481
|
+
(e2eResult.stderr?.toString() ?? ""))
|
|
482
|
+
.trim()
|
|
483
|
+
.slice(-FAILURE_OUTPUT_TAIL_CHARS);
|
|
484
|
+
console.warn("End-to-end tests failed after remediation. Transitioning to triage.");
|
|
485
|
+
return { ran: true, passed: false, output: e2eOutput };
|
|
486
|
+
}
|
|
487
|
+
console.log("End-to-end tests passed.");
|
|
488
|
+
return { ran: true, passed: true, output: "" };
|
|
489
|
+
}
|
|
490
|
+
/**
|
|
491
|
+
* Partition the terminal items into the report's resolved / verified-no-change
|
|
492
|
+
* / inappropriate / ignored buckets, pulling each resolved item's verification
|
|
493
|
+
* evidence from its `verify_code_against_documentation` result file when present.
|
|
494
|
+
*/
|
|
495
|
+
function collectReportEntries(state, options) {
|
|
496
|
+
const entries = {
|
|
497
|
+
resolved: [],
|
|
498
|
+
verifiedNoChange: [],
|
|
499
|
+
inappropriate: [],
|
|
500
|
+
ignored: [],
|
|
501
|
+
blocked: [],
|
|
502
|
+
};
|
|
503
|
+
for (const item of Object.values(state.items ?? {})) {
|
|
504
|
+
if (isVerifiedCompleteStatus(item.status)) {
|
|
505
|
+
const finding = state.plan?.findings.find((f) => f.id === item.finding_id);
|
|
506
|
+
const title = finding?.title ?? "Unknown";
|
|
507
|
+
let verificationEvidence;
|
|
508
|
+
const verificationResultPath = join(options.artifactsDir, `result_${item.finding_id}_verify_code_against_documentation.json`);
|
|
509
|
+
if (existsSync(verificationResultPath)) {
|
|
510
|
+
try {
|
|
511
|
+
const verRes = JSON.parse(readFileSync(verificationResultPath, "utf8"));
|
|
512
|
+
if (Array.isArray(verRes.reason) && verRes.reason.length > 0) {
|
|
513
|
+
verificationEvidence = verRes.reason;
|
|
514
|
+
}
|
|
515
|
+
}
|
|
516
|
+
catch (error) {
|
|
517
|
+
console.warn(`Failed to parse verification result ${verificationResultPath}.`, error);
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
const entry = {
|
|
521
|
+
finding_id: item.finding_id,
|
|
522
|
+
summary: title,
|
|
523
|
+
verification_evidence: verificationEvidence,
|
|
524
|
+
};
|
|
525
|
+
if (item.status === "resolved_no_change") {
|
|
526
|
+
entries.verifiedNoChange.push(entry);
|
|
527
|
+
}
|
|
528
|
+
else {
|
|
529
|
+
entries.resolved.push(entry);
|
|
530
|
+
}
|
|
531
|
+
}
|
|
532
|
+
else if (item.status === "deemed_inappropriate") {
|
|
533
|
+
entries.inappropriate.push({
|
|
534
|
+
finding_id: item.finding_id,
|
|
535
|
+
rationale: item.failure_reason ?? "Deemed inappropriate",
|
|
536
|
+
});
|
|
537
|
+
}
|
|
538
|
+
else if (item.status === "ignored") {
|
|
539
|
+
entries.ignored.push({
|
|
540
|
+
finding_id: item.finding_id,
|
|
541
|
+
rationale: item.failure_reason ?? "Ignored by user",
|
|
542
|
+
});
|
|
543
|
+
}
|
|
544
|
+
else if (item.status === "blocked") {
|
|
545
|
+
entries.blocked.push({
|
|
546
|
+
finding_id: item.finding_id,
|
|
547
|
+
rationale: item.failure_reason ?? "Blocked",
|
|
548
|
+
});
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
return entries;
|
|
552
|
+
}
|
|
553
|
+
/**
|
|
554
|
+
* Render `remediation-report.md` from the partitioned entries, closing action,
|
|
555
|
+
* e2e result, and per-finding outcomes. Pure string builder (no I/O).
|
|
556
|
+
*/
|
|
557
|
+
function buildRemediationReportMarkdown(state, entries, closingResult, e2ePassed, outcomesReport, combinedTest, reflections = []) {
|
|
558
|
+
let reportContent = `# Remediation Report\n\n`;
|
|
559
|
+
reportContent += `## Resolved — Changed Files\n\n`;
|
|
560
|
+
if (entries.resolved.length === 0) {
|
|
561
|
+
reportContent += `None.\n`;
|
|
562
|
+
}
|
|
563
|
+
else {
|
|
564
|
+
for (const entry of entries.resolved) {
|
|
565
|
+
reportContent += `- **${entry.finding_id}**: ${entry.summary}\n`;
|
|
566
|
+
if (entry.verification_evidence) {
|
|
567
|
+
for (const check of entry.verification_evidence) {
|
|
568
|
+
reportContent += ` - *Verification*: ${check}\n`;
|
|
569
|
+
}
|
|
570
|
+
}
|
|
571
|
+
}
|
|
572
|
+
}
|
|
573
|
+
if (entries.verifiedNoChange.length > 0) {
|
|
574
|
+
reportContent += `\n## Verified Already Correct (no changes made)\n\n`;
|
|
575
|
+
for (const entry of entries.verifiedNoChange) {
|
|
576
|
+
reportContent += `- **${entry.finding_id}**: ${entry.summary}\n`;
|
|
577
|
+
if (entry.verification_evidence) {
|
|
578
|
+
for (const check of entry.verification_evidence) {
|
|
579
|
+
reportContent += ` - *Verification*: ${check}\n`;
|
|
580
|
+
}
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
if (entries.inappropriate.length > 0) {
|
|
585
|
+
reportContent += `\n## Deemed Inappropriate\n\n`;
|
|
586
|
+
for (const entry of entries.inappropriate) {
|
|
587
|
+
reportContent += `- **${entry.finding_id}**: ${entry.rationale}\n`;
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
if (entries.ignored.length > 0) {
|
|
591
|
+
reportContent += `\n## Ignored\n\n`;
|
|
592
|
+
for (const entry of entries.ignored) {
|
|
593
|
+
reportContent += `- **${entry.finding_id}**: ${entry.rationale}\n`;
|
|
594
|
+
}
|
|
595
|
+
}
|
|
596
|
+
const skippedByCheckpoint = (state.plan_coverage?.entries ?? []).filter((e) => e.disposition === "dropped_by_checkpoint");
|
|
597
|
+
if (skippedByCheckpoint.length > 0) {
|
|
598
|
+
reportContent += `\n## Skipped by Intent Checkpoint\n\n`;
|
|
599
|
+
reportContent += `${skippedByCheckpoint.length} finding(s) were excluded from remediation by the intent checkpoint (severity/lens/package/theme filters or excluded scope):\n`;
|
|
600
|
+
for (const entry of skippedByCheckpoint) {
|
|
601
|
+
reportContent += `- **${entry.finding_id}**${entry.title ? `: ${entry.title}` : ""}\n`;
|
|
602
|
+
}
|
|
603
|
+
}
|
|
604
|
+
const droppedByGrounding = (state.plan_coverage?.entries ?? []).filter((e) => e.disposition === "dropped_phantom_paths");
|
|
605
|
+
if (droppedByGrounding.length > 0) {
|
|
606
|
+
reportContent += `\n## Dropped by Grounding\n\n`;
|
|
607
|
+
reportContent += `${droppedByGrounding.length} extracted finding(s) were dropped because every cited path was phantom (does not exist in this repository):\n`;
|
|
608
|
+
for (const entry of droppedByGrounding) {
|
|
609
|
+
const phantoms = entry.phantom_paths_removed?.join(", ");
|
|
610
|
+
reportContent += `- **${entry.finding_id}**${entry.title ? `: ${entry.title}` : ""}${phantoms ? ` (cited: ${phantoms})` : ""}\n`;
|
|
611
|
+
}
|
|
612
|
+
}
|
|
613
|
+
const ungroundedEvidence = (state.plan_coverage?.entries ?? []).filter((e) => e.disposition === "planned" && e.evidence_grounded === false);
|
|
614
|
+
if (ungroundedEvidence.length > 0) {
|
|
615
|
+
reportContent += `\n## Ungrounded Evidence\n\n`;
|
|
616
|
+
reportContent += `${ungroundedEvidence.length} planned finding(s) carried no evidence citing a real repo path and were downgraded to low confidence:\n`;
|
|
617
|
+
for (const entry of ungroundedEvidence) {
|
|
618
|
+
reportContent += `- **${entry.finding_id}**${entry.title ? `: ${entry.title}` : ""}\n`;
|
|
619
|
+
}
|
|
620
|
+
}
|
|
621
|
+
reportContent += `\n## Closing Action\n\nAction: ${state.closing_plan.action}\n`;
|
|
622
|
+
reportContent += `Status: ${closingResult.status}\n`;
|
|
623
|
+
if (e2ePassed !== undefined) {
|
|
624
|
+
reportContent += `\n## End-to-End Tests\n\nResult: ${e2ePassed ? "passed" : "failed"}\n`;
|
|
625
|
+
}
|
|
626
|
+
const o = outcomesReport.by_outcome;
|
|
627
|
+
reportContent += `\n## Remediation Outcomes\n\n`;
|
|
628
|
+
reportContent += `Of ${outcomesReport.total} finding(s): ${o.resolved} resolved, ${o.verified_no_change} verified already correct, ${o.inappropriate} deemed inappropriate, ${o.ignored} ignored, ${o.blocked} blocked.\n`;
|
|
629
|
+
const lensNames = Object.keys(outcomesReport.by_lens).sort();
|
|
630
|
+
if (lensNames.length > 0) {
|
|
631
|
+
reportContent += `\nBy lens:\n`;
|
|
632
|
+
for (const lens of lensNames) {
|
|
633
|
+
const counts = outcomesReport.by_lens[lens];
|
|
634
|
+
const parts = OUTCOME_KEYS.filter((key) => (counts[key] ?? 0) > 0).map((key) => `${key} ${counts[key]}`);
|
|
635
|
+
reportContent += `- ${lens}: ${parts.join(", ")}\n`;
|
|
636
|
+
}
|
|
637
|
+
}
|
|
638
|
+
if (!combinedTest.passed) {
|
|
639
|
+
reportContent += `\n## Combined Test Suite Failure\n\nThe full test suite failed after remediation. No items with a resolved status were available to re-block, so the run completed, but the following failure was recorded:\n\n`;
|
|
640
|
+
if (combinedTest.output)
|
|
641
|
+
reportContent += `\`\`\`\n${combinedTest.output}\n\`\`\`\n`;
|
|
642
|
+
}
|
|
643
|
+
// Opt-in worker reflections, aggregated into the same "Process Feedback"
|
|
644
|
+
// section audit-code renders (parity). Empty → no section.
|
|
645
|
+
const feedbackLines = renderProcessFeedbackSection(reflections);
|
|
646
|
+
if (feedbackLines.length > 0) {
|
|
647
|
+
reportContent += `\n${feedbackLines.join("\n")}`;
|
|
648
|
+
}
|
|
649
|
+
return reportContent;
|
|
650
|
+
}
|
|
651
|
+
/**
|
|
652
|
+
* Clean up the remediator's temporary git branches and the artifact directory.
|
|
653
|
+
* Branches first, artifact dir last so a crash mid-cleanup leaves a recoverable
|
|
654
|
+
* state. Failures are non-fatal but recorded via structured RunLogger context
|
|
655
|
+
* (OBS-003) rather than a bare console.warn.
|
|
656
|
+
*
|
|
657
|
+
* The artifacts directory is only deleted on a fully-green close (all items
|
|
658
|
+
* resolved, combined test passed, closing action succeeded). When the run is
|
|
659
|
+
* not fully green — e2e failed, combined test failed, or closing action failed —
|
|
660
|
+
* the artifacts directory is preserved for diagnosis.
|
|
661
|
+
*/
|
|
662
|
+
async function cleanupTempBranchesAndArtifacts(options, completeState, combinedTest, e2eResult, closingResult, runLogger) {
|
|
663
|
+
try {
|
|
664
|
+
const branchResult = runCommand("git", ["branch"], {
|
|
665
|
+
cwd: options.root,
|
|
666
|
+
encoding: "utf8",
|
|
667
|
+
});
|
|
668
|
+
const branches = (branchResult.stdout?.toString() ?? "").split("\n");
|
|
669
|
+
for (const branch of branches) {
|
|
670
|
+
const b = branch.replace("*", "").trim();
|
|
671
|
+
if (b.startsWith("remediator-block-")) {
|
|
672
|
+
runCommand("git", ["branch", "-D", b], { cwd: options.root });
|
|
673
|
+
}
|
|
674
|
+
}
|
|
675
|
+
}
|
|
676
|
+
catch (error) {
|
|
677
|
+
const reason = error instanceof Error ? error.message : String(error);
|
|
678
|
+
console.warn("Failed to clean up temporary git branches.", error);
|
|
679
|
+
runLogger?.event({
|
|
680
|
+
phase: "close",
|
|
681
|
+
kind: "outcome",
|
|
682
|
+
obligation: "closing",
|
|
683
|
+
note: `Failed to clean up temporary git branches: ${reason}`,
|
|
684
|
+
});
|
|
685
|
+
}
|
|
686
|
+
// Write final state before deleting the artifacts directory so the completion
|
|
687
|
+
// is durable even if cleanup partially fails.
|
|
688
|
+
try {
|
|
689
|
+
const { StateStore } = await import("../state/store.js");
|
|
690
|
+
const store = new StateStore(options.artifactsDir);
|
|
691
|
+
await store.saveState(completeState);
|
|
692
|
+
}
|
|
693
|
+
catch {
|
|
694
|
+
// Non-fatal — we still return complete
|
|
695
|
+
}
|
|
696
|
+
// Only delete artifacts on a fully-green close. When any test or closing
|
|
697
|
+
// action failed, preserve the directory for diagnosis.
|
|
698
|
+
//
|
|
699
|
+
// CE-003 force-close guard: a `blocked` terminal item means the run did NOT
|
|
700
|
+
// fully succeed — the tool-owned final gate (INV-RS-10) coarse-re-blocked or
|
|
701
|
+
// the bounded backstop terminated the run as blocked. Such a run must never be
|
|
702
|
+
// "landed green" (artifacts deleted as if complete); a vacuous/unset
|
|
703
|
+
// plan.test_command (combinedTest vacuously passing) cannot mask a blocked
|
|
704
|
+
// item. Preserve the artifacts so the partial outcome is diagnosable.
|
|
705
|
+
const anyBlocked = Object.values(completeState.items ?? {}).some((it) => it.status === "blocked");
|
|
706
|
+
const fullyGreen = combinedTest.passed &&
|
|
707
|
+
e2eResult.passed &&
|
|
708
|
+
closingResult.status !== "failed" &&
|
|
709
|
+
!anyBlocked;
|
|
710
|
+
if (!fullyGreen) {
|
|
711
|
+
runLogger?.event({
|
|
712
|
+
phase: "close",
|
|
713
|
+
kind: "artifact_write",
|
|
714
|
+
obligation: "closing",
|
|
715
|
+
artifact: options.artifactsDir,
|
|
716
|
+
note: `Artifacts directory preserved for diagnosis (combinedTest.passed=${combinedTest.passed}, e2e.passed=${e2eResult.passed}, closing=${closingResult.status}, anyBlocked=${anyBlocked})`,
|
|
717
|
+
});
|
|
718
|
+
return;
|
|
719
|
+
}
|
|
720
|
+
try {
|
|
721
|
+
const { rm } = await import("node:fs/promises");
|
|
722
|
+
await rm(options.artifactsDir, { recursive: true, force: true });
|
|
723
|
+
}
|
|
724
|
+
catch (error) {
|
|
725
|
+
const reason = error instanceof Error ? error.message : String(error);
|
|
726
|
+
console.warn("Failed to clean up artifacts directory — manual removal may be needed.");
|
|
727
|
+
runLogger?.event({
|
|
728
|
+
phase: "close",
|
|
729
|
+
kind: "artifact_write",
|
|
730
|
+
obligation: "closing",
|
|
731
|
+
artifact: options.artifactsDir,
|
|
732
|
+
note: `Failed to clean up artifacts directory (manual removal may be needed): ${reason}`,
|
|
733
|
+
});
|
|
734
|
+
}
|
|
735
|
+
}
|
|
736
|
+
/**
|
|
737
|
+
* Build a VerificationReport from the post-remediation state. One
|
|
738
|
+
* FindingVerificationTrace per terminal finding, with trace entries for:
|
|
739
|
+
* - combined test suite result (task kind)
|
|
740
|
+
* - each item's verification evidence from result files (file kind)
|
|
741
|
+
* - closing action outcome (command kind)
|
|
742
|
+
*
|
|
743
|
+
* Overall status is "passed" when combined tests passed and all resolved
|
|
744
|
+
* items have at least one passing trace. "failed" otherwise.
|
|
745
|
+
*/
|
|
746
|
+
function buildVerificationReport(state, options, closingResult, combinedTest) {
|
|
747
|
+
const findings = [];
|
|
748
|
+
const findingsById = new Map((state.plan?.findings ?? []).map((f) => [f.id, f]));
|
|
749
|
+
for (const item of Object.values(state.items ?? {})) {
|
|
750
|
+
const finding = findingsById.get(item.finding_id);
|
|
751
|
+
const isResolved = isVerifiedCompleteStatus(item.status);
|
|
752
|
+
const isSkipped = isSkipStatus(item.status);
|
|
753
|
+
const traces = [];
|
|
754
|
+
const itemPassed = isResolved && combinedTest.passed;
|
|
755
|
+
if (isSkipped) {
|
|
756
|
+
// Ignored/inappropriate items are excluded from overall_status — they
|
|
757
|
+
// get a single skipped trace and an overall_status of 'skipped'.
|
|
758
|
+
// The shared FindingVerificationTrace type only allows "passed"|"failed"
|
|
759
|
+
// but remediate-code extends this set with "skipped" so the close phase
|
|
760
|
+
// can exclude settled user decisions from the run verdict. The cast is
|
|
761
|
+
// intentional: the JSON output uses "skipped" as a discriminant even
|
|
762
|
+
// though the shared TS type narrows the union.
|
|
763
|
+
traces.push({
|
|
764
|
+
trace_id: `${item.finding_id}:skipped`,
|
|
765
|
+
kind: "task",
|
|
766
|
+
label: item.status === "ignored" ? "ignored by user" : "deemed inappropriate",
|
|
767
|
+
evidence: [item.failure_reason ?? item.status],
|
|
768
|
+
status: "failed",
|
|
769
|
+
});
|
|
770
|
+
findings.push({
|
|
771
|
+
finding_id: item.finding_id,
|
|
772
|
+
traces,
|
|
773
|
+
overall_status: "skipped",
|
|
774
|
+
});
|
|
775
|
+
continue;
|
|
776
|
+
}
|
|
777
|
+
// Combined test suite trace.
|
|
778
|
+
const suiteLabel = combinedTest.suite_name ?? "combined test suite";
|
|
779
|
+
traces.push({
|
|
780
|
+
trace_id: `${item.finding_id}:combined-tests`,
|
|
781
|
+
kind: "task",
|
|
782
|
+
label: suiteLabel,
|
|
783
|
+
evidence: combinedTest.passed
|
|
784
|
+
? [`${suiteLabel} passed`]
|
|
785
|
+
: [`${suiteLabel} failed`, ...(combinedTest.output ? [combinedTest.output.slice(-500)] : [])],
|
|
786
|
+
status: combinedTest.passed ? "passed" : "failed",
|
|
787
|
+
});
|
|
788
|
+
const contractGoalId = finding?.contract_goal_id ?? state.plan?.goal_id;
|
|
789
|
+
if (contractGoalId) {
|
|
790
|
+
traces.push({
|
|
791
|
+
trace_id: `${item.finding_id}:contract-goal`,
|
|
792
|
+
kind: "requirement",
|
|
793
|
+
label: "contract-pipeline goal",
|
|
794
|
+
evidence: [`goal_id=${contractGoalId}`],
|
|
795
|
+
status: itemPassed ? "passed" : "failed",
|
|
796
|
+
});
|
|
797
|
+
}
|
|
798
|
+
if (finding?.contract_obligation_ids?.length) {
|
|
799
|
+
traces.push({
|
|
800
|
+
trace_id: `${item.finding_id}:contract-obligations`,
|
|
801
|
+
kind: "requirement",
|
|
802
|
+
label: "contract-pipeline obligations satisfied by task",
|
|
803
|
+
evidence: finding.contract_obligation_ids,
|
|
804
|
+
status: itemPassed ? "passed" : "failed",
|
|
805
|
+
});
|
|
806
|
+
}
|
|
807
|
+
if (finding?.verification_obligation_ids?.length) {
|
|
808
|
+
traces.push({
|
|
809
|
+
trace_id: `${item.finding_id}:verification-obligations`,
|
|
810
|
+
kind: "invariant",
|
|
811
|
+
label: "contract-pipeline verification obligations",
|
|
812
|
+
evidence: finding.verification_obligation_ids,
|
|
813
|
+
status: itemPassed ? "passed" : "failed",
|
|
814
|
+
});
|
|
815
|
+
}
|
|
816
|
+
for (const [index, command] of (finding?.targeted_commands ?? []).entries()) {
|
|
817
|
+
traces.push({
|
|
818
|
+
trace_id: `${item.finding_id}:targeted-command-${index + 1}`,
|
|
819
|
+
kind: "command",
|
|
820
|
+
label: "implementation DAG targeted command",
|
|
821
|
+
evidence: [`planned command: ${command}`],
|
|
822
|
+
status: itemPassed ? "passed" : "failed",
|
|
823
|
+
});
|
|
824
|
+
}
|
|
825
|
+
// Verification result file evidence (verify_code_against_documentation).
|
|
826
|
+
const verificationResultPath = join(options.artifactsDir, `result_${item.finding_id}_verify_code_against_documentation.json`);
|
|
827
|
+
if (existsSync(verificationResultPath)) {
|
|
828
|
+
try {
|
|
829
|
+
const verRes = JSON.parse(readFileSync(verificationResultPath, "utf8"));
|
|
830
|
+
const evidence = Array.isArray(verRes.reason) ? verRes.reason : [];
|
|
831
|
+
traces.push({
|
|
832
|
+
trace_id: `${item.finding_id}:verify-doc`,
|
|
833
|
+
kind: "file",
|
|
834
|
+
label: `verify_code_against_documentation for ${item.finding_id}`,
|
|
835
|
+
evidence,
|
|
836
|
+
status: evidence.length > 0 ? "passed" : "failed",
|
|
837
|
+
});
|
|
838
|
+
}
|
|
839
|
+
catch {
|
|
840
|
+
// Non-fatal: evidence file malformed
|
|
841
|
+
}
|
|
842
|
+
}
|
|
843
|
+
// Closing action trace (one per finding so the report is self-contained).
|
|
844
|
+
if (closingResult.action !== "none") {
|
|
845
|
+
traces.push({
|
|
846
|
+
trace_id: `${item.finding_id}:closing`,
|
|
847
|
+
kind: "command",
|
|
848
|
+
label: `closing action: ${closingResult.action}`,
|
|
849
|
+
evidence: [`status=${closingResult.status}`],
|
|
850
|
+
status: closingResult.status === "failed" ? "failed" : "passed",
|
|
851
|
+
});
|
|
852
|
+
}
|
|
853
|
+
findings.push({
|
|
854
|
+
finding_id: item.finding_id,
|
|
855
|
+
traces,
|
|
856
|
+
overall_status: itemPassed ? "passed" : "failed",
|
|
857
|
+
});
|
|
858
|
+
}
|
|
859
|
+
// Sort by finding_id for determinism.
|
|
860
|
+
findings.sort((a, b) => a.finding_id.localeCompare(b.finding_id));
|
|
861
|
+
// Overall status: ignored/inappropriate (skipped) items do NOT contribute
|
|
862
|
+
// to failure — only resolved/non-skipped items count.
|
|
863
|
+
const overallPassed = combinedTest.passed &&
|
|
864
|
+
findings
|
|
865
|
+
.filter((f) => f.overall_status !== "skipped")
|
|
866
|
+
.every((f) => f.overall_status === "passed");
|
|
867
|
+
// Derive goal_id from the plan if available.
|
|
868
|
+
const goalId = state.plan?.goal_id;
|
|
869
|
+
return {
|
|
870
|
+
contract_version: CONTRACT_PIPELINE_VERIFICATION_REPORT_VERSION,
|
|
871
|
+
...(goalId ? { goal_id: goalId } : {}),
|
|
872
|
+
findings,
|
|
873
|
+
overall_status: overallPassed ? "passed" : "failed",
|
|
874
|
+
created_at: new Date().toISOString(),
|
|
875
|
+
};
|
|
876
|
+
}
|
|
877
|
+
export async function runClosePhase(state, options, runLogger) {
|
|
878
|
+
console.log("Running Close Phase...");
|
|
879
|
+
if (!state.plan || !state.items || !state.closing_plan) {
|
|
880
|
+
throw new Error("Cannot run close phase: missing plan, items, or closing_plan from state.");
|
|
881
|
+
}
|
|
882
|
+
// 1. Check whether closing action requires user confirmation (preview).
|
|
883
|
+
// When not pre-authorized and action is confirmable, generate the file list +
|
|
884
|
+
// commit message, attach them to closing_plan.closing_action_preview, and
|
|
885
|
+
// return the updated state so the host can present the preview. The host sets
|
|
886
|
+
// closing_plan.pre_authorized = true before the next next-step call.
|
|
887
|
+
const preview = checkClosingPreview(state, options);
|
|
888
|
+
if (preview) {
|
|
889
|
+
const updatedClosingPlan = { ...state.closing_plan, closing_action_preview: preview };
|
|
890
|
+
return { ...state, closing_plan: updatedClosingPlan };
|
|
891
|
+
}
|
|
892
|
+
// 2. Run the full test suite; on failure re-block resolved items and triage.
|
|
893
|
+
const combinedTest = runCombinedTestSuite(state, options);
|
|
894
|
+
if (!combinedTest.passed) {
|
|
895
|
+
console.log("Full test suite failed. Transitioning back to triage.");
|
|
896
|
+
if (blockResolvedItemsOnCombinedFailure(state, combinedTest.output)) {
|
|
897
|
+
return { ...state, status: "triage" };
|
|
898
|
+
}
|
|
899
|
+
console.warn("Combined test suite failed but no resolved items to re-block — completing with test failure recorded in report.");
|
|
900
|
+
}
|
|
901
|
+
// 3. Run end-to-end tests on the fully merged post-remediation state.
|
|
902
|
+
const e2eResult = runE2eTests(state, options);
|
|
903
|
+
if (!e2eResult.passed) {
|
|
904
|
+
console.log("End-to-end tests failed. Transitioning back to triage.");
|
|
905
|
+
blockResolvedItemsOnCombinedFailure(state, e2eResult.output);
|
|
906
|
+
return { ...state, status: "triage" };
|
|
907
|
+
}
|
|
908
|
+
// 4. Execute the closing action and record exact command outcomes before
|
|
909
|
+
// reporting success.
|
|
910
|
+
console.log(`Executing closing action: ${state.closing_plan.action}`);
|
|
911
|
+
const closingResult = executeClosingAction(state, options);
|
|
912
|
+
await writeJsonFile(join(options.artifactsDir, "remediation-closing-result.json"), closingResult);
|
|
913
|
+
// 4. Generate remediation-report.md and remediation-report.json
|
|
914
|
+
const entries = collectReportEntries(state, options);
|
|
915
|
+
// Phase 7B: capture per-finding outcomes (surface only).
|
|
916
|
+
const outcomesReport = buildRemediationOutcomesReport(state, closingResult);
|
|
917
|
+
// One run-log line per outcome, plus a summary line for the artifact write.
|
|
918
|
+
for (const outcome of outcomesReport.outcomes) {
|
|
919
|
+
runLogger?.event({
|
|
920
|
+
phase: "close",
|
|
921
|
+
kind: "outcome",
|
|
922
|
+
obligation: "closing",
|
|
923
|
+
note: `${outcome.finding_id} [${outcome.lens}] → ${outcome.outcome} (rework ${outcome.rework_count})`,
|
|
924
|
+
});
|
|
925
|
+
}
|
|
926
|
+
const endedAt = new Date().toISOString();
|
|
927
|
+
// Workers may have appended opt-in reflections during document/implement
|
|
928
|
+
// dispatch; parse leniently (malformed lines skipped) and surface them in the
|
|
929
|
+
// report. Workers own the file — it is read-only here.
|
|
930
|
+
const feedbackText = await readOptionalTextFile(join(options.artifactsDir, AGENT_FEEDBACK_FILENAME));
|
|
931
|
+
const reportContent = buildRemediationReportMarkdown(state, entries, closingResult, e2eResult.ran ? e2eResult.passed : undefined, outcomesReport, combinedTest, feedbackText ? parseReflectionsNdjson(feedbackText) : []);
|
|
932
|
+
// Enrich the coverage ledger with never-planned payloads NOW, from the live
|
|
933
|
+
// state and intake artifacts — both are deleted at the end of close, so this
|
|
934
|
+
// must happen strictly before cleanup.
|
|
935
|
+
const outcomeCoverage = await buildOutcomeCoverageLedger(state, options);
|
|
936
|
+
const outcomesFile = {
|
|
937
|
+
...outcomesReport,
|
|
938
|
+
...(state.started_at ? { started_at: state.started_at } : {}),
|
|
939
|
+
ended_at: endedAt,
|
|
940
|
+
step_count: state.step_count ?? 0,
|
|
941
|
+
combined_test_result: {
|
|
942
|
+
passed: combinedTest.passed,
|
|
943
|
+
...(combinedTest.suite_name ? { suite_name: combinedTest.suite_name } : {}),
|
|
944
|
+
duration_ms: combinedTest.duration_ms,
|
|
945
|
+
...(combinedTest.output ? { failure_summary: combinedTest.output } : {}),
|
|
946
|
+
},
|
|
947
|
+
...(e2eResult.ran ? { e2e_result: { passed: e2eResult.passed } } : {}),
|
|
948
|
+
closing_result: {
|
|
949
|
+
action: state.closing_plan.action,
|
|
950
|
+
status: closingResult.status,
|
|
951
|
+
commands: closingResult.commands,
|
|
952
|
+
},
|
|
953
|
+
...(outcomeCoverage ? { plan_coverage: outcomeCoverage } : {}),
|
|
954
|
+
};
|
|
955
|
+
const outputDir = dirname(options.artifactsDir);
|
|
956
|
+
// 5. Write verification_report.json for the contract pipeline closing phase.
|
|
957
|
+
const verificationReport = buildVerificationReport(state, options, closingResult, combinedTest);
|
|
958
|
+
const verificationReportPath = join(outputDir, "verification_report.json");
|
|
959
|
+
const completeState = { ...state, status: "complete" };
|
|
960
|
+
await Promise.all([
|
|
961
|
+
writeTextFile(join(outputDir, "remediation-report.md"), reportContent),
|
|
962
|
+
writeJsonFile(join(outputDir, "remediation-outcomes.json"), outcomesFile),
|
|
963
|
+
writeJsonFile(verificationReportPath, verificationReport),
|
|
964
|
+
writeJsonFile(join(outputDir, "remediation-state.complete.json"), completeState),
|
|
965
|
+
]);
|
|
966
|
+
runLogger?.event({
|
|
967
|
+
phase: "close",
|
|
968
|
+
kind: "artifact_write",
|
|
969
|
+
obligation: "closing",
|
|
970
|
+
artifact: "remediation-outcomes.json",
|
|
971
|
+
note: `${outcomesReport.total} outcome(s)`,
|
|
972
|
+
});
|
|
973
|
+
runLogger?.event({
|
|
974
|
+
phase: "close",
|
|
975
|
+
kind: "artifact_write",
|
|
976
|
+
obligation: "closing",
|
|
977
|
+
artifact: "verification_report.json",
|
|
978
|
+
note: `overall_status=${verificationReport.overall_status}, findings=${verificationReport.findings.length}`,
|
|
979
|
+
});
|
|
980
|
+
runLogger?.event({
|
|
981
|
+
phase: "close",
|
|
982
|
+
kind: "artifact_write",
|
|
983
|
+
obligation: "closing",
|
|
984
|
+
artifact: "remediation-state.complete.json",
|
|
985
|
+
note: "complete remediation state preserved for retry/recovery",
|
|
986
|
+
});
|
|
987
|
+
console.log("Remediation report generated.");
|
|
988
|
+
// 6. Clean up temporary branches and artifact directory (only when fully green).
|
|
989
|
+
await cleanupTempBranchesAndArtifacts(options, completeState, combinedTest, e2eResult, closingResult, runLogger);
|
|
990
|
+
return completeState;
|
|
991
|
+
}
|
|
992
|
+
//# sourceMappingURL=close.js.map
|