@kevinrabun/judges-cli 3.124.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.md +24 -0
- package/agents/accessibility.judge.md +44 -0
- package/agents/agent-instructions.judge.md +44 -0
- package/agents/ai-code-safety.judge.md +55 -0
- package/agents/api-contract.judge.md +37 -0
- package/agents/api-design.judge.md +55 -0
- package/agents/authentication.judge.md +61 -0
- package/agents/backwards-compatibility.judge.md +44 -0
- package/agents/caching.judge.md +44 -0
- package/agents/ci-cd.judge.md +44 -0
- package/agents/cloud-readiness.judge.md +51 -0
- package/agents/code-structure.judge.md +48 -0
- package/agents/compliance.judge.md +47 -0
- package/agents/concurrency.judge.md +46 -0
- package/agents/configuration-management.judge.md +44 -0
- package/agents/cost-effectiveness.judge.md +40 -0
- package/agents/cybersecurity.judge.md +61 -0
- package/agents/data-security.judge.md +48 -0
- package/agents/data-sovereignty.judge.md +58 -0
- package/agents/database.judge.md +49 -0
- package/agents/dependency-health.judge.md +46 -0
- package/agents/documentation.judge.md +53 -0
- package/agents/error-handling.judge.md +53 -0
- package/agents/ethics-bias.judge.md +46 -0
- package/agents/false-positive-review.judge.md +85 -0
- package/agents/framework-safety.judge.md +47 -0
- package/agents/hallucination-detection.judge.md +46 -0
- package/agents/iac-security.judge.md +45 -0
- package/agents/intent-alignment.judge.md +44 -0
- package/agents/internationalization.judge.md +42 -0
- package/agents/logging-privacy.judge.md +44 -0
- package/agents/logic-review.judge.md +34 -0
- package/agents/maintainability.judge.md +44 -0
- package/agents/model-fingerprint.judge.md +31 -0
- package/agents/multi-turn-coherence.judge.md +36 -0
- package/agents/observability.judge.md +52 -0
- package/agents/over-engineering.judge.md +48 -0
- package/agents/performance.judge.md +44 -0
- package/agents/portability.judge.md +44 -0
- package/agents/rate-limiting.judge.md +53 -0
- package/agents/reliability.judge.md +55 -0
- package/agents/scalability.judge.md +50 -0
- package/agents/security.judge.md +62 -0
- package/agents/software-practices.judge.md +54 -0
- package/agents/testing.judge.md +52 -0
- package/agents/ux.judge.md +44 -0
- package/bin/judges.js +8 -0
- package/dist/a2a-protocol.d.ts +136 -0
- package/dist/a2a-protocol.js +218 -0
- package/dist/agent-loader.d.ts +107 -0
- package/dist/agent-loader.js +260 -0
- package/dist/api.d.ts +169 -0
- package/dist/api.js +195 -0
- package/dist/ast/cross-file-taint.d.ts +42 -0
- package/dist/ast/cross-file-taint.js +679 -0
- package/dist/ast/index.d.ts +25 -0
- package/dist/ast/index.js +148 -0
- package/dist/ast/structural-parser.d.ts +2 -0
- package/dist/ast/structural-parser.js +756 -0
- package/dist/ast/taint-tracker.d.ts +48 -0
- package/dist/ast/taint-tracker.js +1033 -0
- package/dist/ast/tree-sitter-ast.d.ts +33 -0
- package/dist/ast/tree-sitter-ast.js +1164 -0
- package/dist/ast/types.d.ts +50 -0
- package/dist/ast/types.js +7 -0
- package/dist/audit-trail.d.ts +245 -0
- package/dist/audit-trail.js +257 -0
- package/dist/auto-tune.d.ts +146 -0
- package/dist/auto-tune.js +373 -0
- package/dist/cache.d.ts +53 -0
- package/dist/cache.js +86 -0
- package/dist/calibration.d.ts +108 -0
- package/dist/calibration.js +219 -0
- package/dist/cli-dispatch.d.ts +7 -0
- package/dist/cli-dispatch.js +654 -0
- package/dist/cli-formatters.d.ts +6 -0
- package/dist/cli-formatters.js +186 -0
- package/dist/cli-helpers.d.ts +29 -0
- package/dist/cli-helpers.js +129 -0
- package/dist/cli.d.ts +30 -0
- package/dist/cli.js +1487 -0
- package/dist/commands/adoption-report.d.ts +7 -0
- package/dist/commands/adoption-report.js +218 -0
- package/dist/commands/adoption-track.d.ts +4 -0
- package/dist/commands/adoption-track.js +246 -0
- package/dist/commands/ai-gate.d.ts +7 -0
- package/dist/commands/ai-gate.js +212 -0
- package/dist/commands/ai-model-trust.d.ts +16 -0
- package/dist/commands/ai-model-trust.js +234 -0
- package/dist/commands/ai-output-compare.d.ts +8 -0
- package/dist/commands/ai-output-compare.js +202 -0
- package/dist/commands/ai-pattern-trend.d.ts +8 -0
- package/dist/commands/ai-pattern-trend.js +223 -0
- package/dist/commands/ai-prompt-audit.d.ts +22 -0
- package/dist/commands/ai-prompt-audit.js +254 -0
- package/dist/commands/ai-provenance.d.ts +4 -0
- package/dist/commands/ai-provenance.js +247 -0
- package/dist/commands/api-audit.d.ts +8 -0
- package/dist/commands/api-audit.js +359 -0
- package/dist/commands/api-misuse.d.ts +4 -0
- package/dist/commands/api-misuse.js +260 -0
- package/dist/commands/api-versioning-audit.d.ts +5 -0
- package/dist/commands/api-versioning-audit.js +233 -0
- package/dist/commands/approve-chain.d.ts +7 -0
- package/dist/commands/approve-chain.js +234 -0
- package/dist/commands/arch-audit.d.ts +8 -0
- package/dist/commands/arch-audit.js +283 -0
- package/dist/commands/assertion-density.d.ts +4 -0
- package/dist/commands/assertion-density.js +263 -0
- package/dist/commands/assign-findings.d.ts +36 -0
- package/dist/commands/assign-findings.js +177 -0
- package/dist/commands/async-safety.d.ts +4 -0
- package/dist/commands/async-safety.js +266 -0
- package/dist/commands/audit-bundle.d.ts +28 -0
- package/dist/commands/audit-bundle.js +234 -0
- package/dist/commands/audit-trail.d.ts +17 -0
- package/dist/commands/audit-trail.js +154 -0
- package/dist/commands/auto-approve.d.ts +4 -0
- package/dist/commands/auto-approve.js +188 -0
- package/dist/commands/auto-calibrate.d.ts +14 -0
- package/dist/commands/auto-calibrate.js +106 -0
- package/dist/commands/auto-detect.d.ts +61 -0
- package/dist/commands/auto-detect.js +328 -0
- package/dist/commands/auto-fix.d.ts +17 -0
- package/dist/commands/auto-fix.js +240 -0
- package/dist/commands/auto-triage.d.ts +31 -0
- package/dist/commands/auto-triage.js +125 -0
- package/dist/commands/baseline.d.ts +47 -0
- package/dist/commands/baseline.js +353 -0
- package/dist/commands/batch-review.d.ts +4 -0
- package/dist/commands/batch-review.js +180 -0
- package/dist/commands/benchmark-advanced.d.ts +14 -0
- package/dist/commands/benchmark-advanced.js +5057 -0
- package/dist/commands/benchmark-ai-agents.d.ts +8 -0
- package/dist/commands/benchmark-ai-agents.js +4123 -0
- package/dist/commands/benchmark-ai-output.d.ts +9 -0
- package/dist/commands/benchmark-ai-output.js +365 -0
- package/dist/commands/benchmark-compliance-ethics.d.ts +8 -0
- package/dist/commands/benchmark-compliance-ethics.js +3060 -0
- package/dist/commands/benchmark-expanded-2.d.ts +12 -0
- package/dist/commands/benchmark-expanded-2.js +5530 -0
- package/dist/commands/benchmark-expanded.d.ts +12 -0
- package/dist/commands/benchmark-expanded.js +2599 -0
- package/dist/commands/benchmark-infrastructure.d.ts +8 -0
- package/dist/commands/benchmark-infrastructure.js +2882 -0
- package/dist/commands/benchmark-languages.d.ts +8 -0
- package/dist/commands/benchmark-languages.js +1963 -0
- package/dist/commands/benchmark-quality-ops.d.ts +8 -0
- package/dist/commands/benchmark-quality-ops.js +3415 -0
- package/dist/commands/benchmark-security-deep.d.ts +9 -0
- package/dist/commands/benchmark-security-deep.js +2335 -0
- package/dist/commands/benchmark.d.ts +233 -0
- package/dist/commands/benchmark.js +3214 -0
- package/dist/commands/blame-review.d.ts +4 -0
- package/dist/commands/blame-review.js +266 -0
- package/dist/commands/boundary-enforce.d.ts +5 -0
- package/dist/commands/boundary-enforce.js +255 -0
- package/dist/commands/build-optimize.d.ts +6 -0
- package/dist/commands/build-optimize.js +256 -0
- package/dist/commands/burndown.d.ts +26 -0
- package/dist/commands/burndown.js +179 -0
- package/dist/commands/cache-audit.d.ts +4 -0
- package/dist/commands/cache-audit.js +219 -0
- package/dist/commands/calibration-dashboard.d.ts +1 -0
- package/dist/commands/calibration-dashboard.js +294 -0
- package/dist/commands/calibration-share.d.ts +30 -0
- package/dist/commands/calibration-share.js +182 -0
- package/dist/commands/chat-notify.d.ts +8 -0
- package/dist/commands/chat-notify.js +258 -0
- package/dist/commands/ci-template.d.ts +14 -0
- package/dist/commands/ci-template.js +211 -0
- package/dist/commands/ci-templates.d.ts +9 -0
- package/dist/commands/ci-templates.js +89 -0
- package/dist/commands/clarity-score.d.ts +8 -0
- package/dist/commands/clarity-score.js +260 -0
- package/dist/commands/clone-detect.d.ts +4 -0
- package/dist/commands/clone-detect.js +232 -0
- package/dist/commands/coach-mode.d.ts +7 -0
- package/dist/commands/coach-mode.js +229 -0
- package/dist/commands/code-health.d.ts +4 -0
- package/dist/commands/code-health.js +195 -0
- package/dist/commands/code-owner-suggest.d.ts +16 -0
- package/dist/commands/code-owner-suggest.js +214 -0
- package/dist/commands/code-similarity.d.ts +8 -0
- package/dist/commands/code-similarity.js +231 -0
- package/dist/commands/comment-drift.d.ts +4 -0
- package/dist/commands/comment-drift.js +228 -0
- package/dist/commands/commit-hygiene.d.ts +5 -0
- package/dist/commands/commit-hygiene.js +175 -0
- package/dist/commands/community-patterns.d.ts +1 -0
- package/dist/commands/community-patterns.js +131 -0
- package/dist/commands/compare-runs.d.ts +37 -0
- package/dist/commands/compare-runs.js +228 -0
- package/dist/commands/completion-audit.d.ts +4 -0
- package/dist/commands/completion-audit.js +296 -0
- package/dist/commands/completions.d.ts +1 -0
- package/dist/commands/completions.js +257 -0
- package/dist/commands/compliance-map.d.ts +8 -0
- package/dist/commands/compliance-map.js +374 -0
- package/dist/commands/compliance-report.d.ts +34 -0
- package/dist/commands/compliance-report.js +161 -0
- package/dist/commands/compliance-weight.d.ts +8 -0
- package/dist/commands/compliance-weight.js +272 -0
- package/dist/commands/config-drift.d.ts +24 -0
- package/dist/commands/config-drift.js +213 -0
- package/dist/commands/config-lint.d.ts +4 -0
- package/dist/commands/config-lint.js +187 -0
- package/dist/commands/config-migrate.d.ts +43 -0
- package/dist/commands/config-migrate.js +240 -0
- package/dist/commands/config-share.d.ts +95 -0
- package/dist/commands/config-share.js +406 -0
- package/dist/commands/context-blind.d.ts +4 -0
- package/dist/commands/context-blind.js +272 -0
- package/dist/commands/context-inject.d.ts +8 -0
- package/dist/commands/context-inject.js +211 -0
- package/dist/commands/contract-verify.d.ts +4 -0
- package/dist/commands/contract-verify.js +316 -0
- package/dist/commands/correlate.d.ts +27 -0
- package/dist/commands/correlate.js +241 -0
- package/dist/commands/cost-forecast.d.ts +18 -0
- package/dist/commands/cost-forecast.js +193 -0
- package/dist/commands/coverage-map.d.ts +22 -0
- package/dist/commands/coverage-map.js +222 -0
- package/dist/commands/coverage.d.ts +40 -0
- package/dist/commands/coverage.js +147 -0
- package/dist/commands/cross-file-consistency.d.ts +4 -0
- package/dist/commands/cross-file-consistency.js +254 -0
- package/dist/commands/cross-pr-regression.d.ts +8 -0
- package/dist/commands/cross-pr-regression.js +297 -0
- package/dist/commands/custom-rule.d.ts +4 -0
- package/dist/commands/custom-rule.js +210 -0
- package/dist/commands/dead-code-detect.d.ts +4 -0
- package/dist/commands/dead-code-detect.js +255 -0
- package/dist/commands/dedup-report.d.ts +12 -0
- package/dist/commands/dedup-report.js +137 -0
- package/dist/commands/dep-audit.d.ts +52 -0
- package/dist/commands/dep-audit.js +277 -0
- package/dist/commands/dep-correlate.d.ts +8 -0
- package/dist/commands/dep-correlate.js +207 -0
- package/dist/commands/deploy-readiness.d.ts +5 -0
- package/dist/commands/deploy-readiness.js +211 -0
- package/dist/commands/deprecated.d.ts +47 -0
- package/dist/commands/deprecated.js +201 -0
- package/dist/commands/deps.d.ts +5 -0
- package/dist/commands/deps.js +122 -0
- package/dist/commands/design-audit.d.ts +8 -0
- package/dist/commands/design-audit.js +301 -0
- package/dist/commands/dev-score.d.ts +36 -0
- package/dist/commands/dev-score.js +203 -0
- package/dist/commands/diff-explain.d.ts +4 -0
- package/dist/commands/diff-explain.js +142 -0
- package/dist/commands/diff-only.d.ts +33 -0
- package/dist/commands/diff-only.js +151 -0
- package/dist/commands/diff-review.d.ts +4 -0
- package/dist/commands/diff-review.js +190 -0
- package/dist/commands/diff.d.ts +6 -0
- package/dist/commands/diff.js +449 -0
- package/dist/commands/digest.d.ts +19 -0
- package/dist/commands/digest.js +221 -0
- package/dist/commands/doc-drift.d.ts +8 -0
- package/dist/commands/doc-drift.js +258 -0
- package/dist/commands/doc-gen.d.ts +7 -0
- package/dist/commands/doc-gen.js +208 -0
- package/dist/commands/docs.d.ts +1 -0
- package/dist/commands/docs.js +156 -0
- package/dist/commands/doctor.d.ts +55 -0
- package/dist/commands/doctor.js +362 -0
- package/dist/commands/encoding-safety.d.ts +4 -0
- package/dist/commands/encoding-safety.js +275 -0
- package/dist/commands/error-taxonomy.d.ts +5 -0
- package/dist/commands/error-taxonomy.js +226 -0
- package/dist/commands/error-ux.d.ts +4 -0
- package/dist/commands/error-ux.js +252 -0
- package/dist/commands/event-leak.d.ts +4 -0
- package/dist/commands/event-leak.js +262 -0
- package/dist/commands/evidence-chain.d.ts +4 -0
- package/dist/commands/evidence-chain.js +309 -0
- package/dist/commands/example-leak.d.ts +4 -0
- package/dist/commands/example-leak.js +232 -0
- package/dist/commands/exception-consistency.d.ts +6 -0
- package/dist/commands/exception-consistency.js +192 -0
- package/dist/commands/exec-report.d.ts +8 -0
- package/dist/commands/exec-report.js +271 -0
- package/dist/commands/explain-finding.d.ts +7 -0
- package/dist/commands/explain-finding.js +278 -0
- package/dist/commands/false-negatives.d.ts +34 -0
- package/dist/commands/false-negatives.js +165 -0
- package/dist/commands/feedback-rules.d.ts +28 -0
- package/dist/commands/feedback-rules.js +173 -0
- package/dist/commands/feedback.d.ts +182 -0
- package/dist/commands/feedback.js +550 -0
- package/dist/commands/finding-age-analysis.d.ts +4 -0
- package/dist/commands/finding-age-analysis.js +144 -0
- package/dist/commands/finding-age-report.d.ts +4 -0
- package/dist/commands/finding-age-report.js +154 -0
- package/dist/commands/finding-age-tracker.d.ts +7 -0
- package/dist/commands/finding-age-tracker.js +152 -0
- package/dist/commands/finding-age.d.ts +4 -0
- package/dist/commands/finding-age.js +145 -0
- package/dist/commands/finding-ancestry-trace.d.ts +1 -0
- package/dist/commands/finding-ancestry-trace.js +69 -0
- package/dist/commands/finding-annotation-export.d.ts +1 -0
- package/dist/commands/finding-annotation-export.js +97 -0
- package/dist/commands/finding-annotation-layer.d.ts +4 -0
- package/dist/commands/finding-annotation-layer.js +128 -0
- package/dist/commands/finding-auto-categorize.d.ts +1 -0
- package/dist/commands/finding-auto-categorize.js +109 -0
- package/dist/commands/finding-auto-fix-suggest.d.ts +1 -0
- package/dist/commands/finding-auto-fix-suggest.js +76 -0
- package/dist/commands/finding-auto-fix.d.ts +4 -0
- package/dist/commands/finding-auto-fix.js +188 -0
- package/dist/commands/finding-auto-group.d.ts +4 -0
- package/dist/commands/finding-auto-group.js +108 -0
- package/dist/commands/finding-auto-label.d.ts +4 -0
- package/dist/commands/finding-auto-label.js +220 -0
- package/dist/commands/finding-auto-priority.d.ts +1 -0
- package/dist/commands/finding-auto-priority.js +100 -0
- package/dist/commands/finding-auto-suppress.d.ts +4 -0
- package/dist/commands/finding-auto-suppress.js +126 -0
- package/dist/commands/finding-auto-tag.d.ts +4 -0
- package/dist/commands/finding-auto-tag.js +113 -0
- package/dist/commands/finding-auto-triage.d.ts +4 -0
- package/dist/commands/finding-auto-triage.js +108 -0
- package/dist/commands/finding-autofix-preview.d.ts +4 -0
- package/dist/commands/finding-autofix-preview.js +86 -0
- package/dist/commands/finding-batch-resolve.d.ts +4 -0
- package/dist/commands/finding-batch-resolve.js +165 -0
- package/dist/commands/finding-batch-suppress.d.ts +4 -0
- package/dist/commands/finding-batch-suppress.js +85 -0
- package/dist/commands/finding-batch-triage.d.ts +1 -0
- package/dist/commands/finding-batch-triage.js +90 -0
- package/dist/commands/finding-blast-radius.d.ts +4 -0
- package/dist/commands/finding-blast-radius.js +91 -0
- package/dist/commands/finding-budget.d.ts +4 -0
- package/dist/commands/finding-budget.js +232 -0
- package/dist/commands/finding-category-map.d.ts +4 -0
- package/dist/commands/finding-category-map.js +103 -0
- package/dist/commands/finding-category-stats.d.ts +4 -0
- package/dist/commands/finding-category-stats.js +104 -0
- package/dist/commands/finding-category.d.ts +4 -0
- package/dist/commands/finding-category.js +109 -0
- package/dist/commands/finding-change-impact.d.ts +4 -0
- package/dist/commands/finding-change-impact.js +107 -0
- package/dist/commands/finding-cluster-analysis.d.ts +4 -0
- package/dist/commands/finding-cluster-analysis.js +133 -0
- package/dist/commands/finding-cluster-group.d.ts +4 -0
- package/dist/commands/finding-cluster-group.js +105 -0
- package/dist/commands/finding-cluster-summary.d.ts +1 -0
- package/dist/commands/finding-cluster-summary.js +85 -0
- package/dist/commands/finding-cluster.d.ts +4 -0
- package/dist/commands/finding-cluster.js +157 -0
- package/dist/commands/finding-code-context.d.ts +4 -0
- package/dist/commands/finding-code-context.js +96 -0
- package/dist/commands/finding-code-smell.d.ts +4 -0
- package/dist/commands/finding-code-smell.js +113 -0
- package/dist/commands/finding-compare-runs.d.ts +4 -0
- package/dist/commands/finding-compare-runs.js +105 -0
- package/dist/commands/finding-compliance-tag.d.ts +1 -0
- package/dist/commands/finding-compliance-tag.js +106 -0
- package/dist/commands/finding-confidence-boost.d.ts +1 -0
- package/dist/commands/finding-confidence-boost.js +88 -0
- package/dist/commands/finding-confidence-calibrate.d.ts +4 -0
- package/dist/commands/finding-confidence-calibrate.js +111 -0
- package/dist/commands/finding-confidence-filter.d.ts +4 -0
- package/dist/commands/finding-confidence-filter.js +77 -0
- package/dist/commands/finding-contest.d.ts +7 -0
- package/dist/commands/finding-contest.js +192 -0
- package/dist/commands/finding-context-enrich.d.ts +4 -0
- package/dist/commands/finding-context-enrich.js +89 -0
- package/dist/commands/finding-context-expand.d.ts +4 -0
- package/dist/commands/finding-context-expand.js +102 -0
- package/dist/commands/finding-context-link.d.ts +1 -0
- package/dist/commands/finding-context-link.js +94 -0
- package/dist/commands/finding-context-summary.d.ts +1 -0
- package/dist/commands/finding-context-summary.js +85 -0
- package/dist/commands/finding-context-window.d.ts +4 -0
- package/dist/commands/finding-context-window.js +126 -0
- package/dist/commands/finding-context.d.ts +4 -0
- package/dist/commands/finding-context.js +140 -0
- package/dist/commands/finding-correlate.d.ts +4 -0
- package/dist/commands/finding-correlate.js +88 -0
- package/dist/commands/finding-correlation-map.d.ts +4 -0
- package/dist/commands/finding-correlation-map.js +101 -0
- package/dist/commands/finding-correlation.d.ts +4 -0
- package/dist/commands/finding-correlation.js +103 -0
- package/dist/commands/finding-cross-file-link.d.ts +1 -0
- package/dist/commands/finding-cross-file-link.js +101 -0
- package/dist/commands/finding-cross-ref.d.ts +4 -0
- package/dist/commands/finding-cross-ref.js +98 -0
- package/dist/commands/finding-cve-lookup.d.ts +4 -0
- package/dist/commands/finding-cve-lookup.js +97 -0
- package/dist/commands/finding-cwe-lookup.d.ts +4 -0
- package/dist/commands/finding-cwe-lookup.js +148 -0
- package/dist/commands/finding-cwe-map.d.ts +4 -0
- package/dist/commands/finding-cwe-map.js +133 -0
- package/dist/commands/finding-dedup-cross-file.d.ts +4 -0
- package/dist/commands/finding-dedup-cross-file.js +95 -0
- package/dist/commands/finding-dedup-cross.d.ts +4 -0
- package/dist/commands/finding-dedup-cross.js +90 -0
- package/dist/commands/finding-dedup-merge.d.ts +1 -0
- package/dist/commands/finding-dedup-merge.js +107 -0
- package/dist/commands/finding-dedup-report.d.ts +4 -0
- package/dist/commands/finding-dedup-report.js +101 -0
- package/dist/commands/finding-dedup-smart.d.ts +1 -0
- package/dist/commands/finding-dedup-smart.js +109 -0
- package/dist/commands/finding-deduplicate.d.ts +4 -0
- package/dist/commands/finding-deduplicate.js +141 -0
- package/dist/commands/finding-dependency-check.d.ts +4 -0
- package/dist/commands/finding-dependency-check.js +119 -0
- package/dist/commands/finding-dependency-impact.d.ts +1 -0
- package/dist/commands/finding-dependency-impact.js +97 -0
- package/dist/commands/finding-dependency-link.d.ts +4 -0
- package/dist/commands/finding-dependency-link.js +73 -0
- package/dist/commands/finding-dependency-risk.d.ts +4 -0
- package/dist/commands/finding-dependency-risk.js +117 -0
- package/dist/commands/finding-dependency-tree.d.ts +4 -0
- package/dist/commands/finding-dependency-tree.js +116 -0
- package/dist/commands/finding-diff-highlight.d.ts +4 -0
- package/dist/commands/finding-diff-highlight.js +107 -0
- package/dist/commands/finding-dismiss-workflow.d.ts +4 -0
- package/dist/commands/finding-dismiss-workflow.js +119 -0
- package/dist/commands/finding-duplicate-detect.d.ts +4 -0
- package/dist/commands/finding-duplicate-detect.js +113 -0
- package/dist/commands/finding-duplicate-rule.d.ts +4 -0
- package/dist/commands/finding-duplicate-rule.js +103 -0
- package/dist/commands/finding-effort-rank.d.ts +1 -0
- package/dist/commands/finding-effort-rank.js +93 -0
- package/dist/commands/finding-evidence-chain.d.ts +4 -0
- package/dist/commands/finding-evidence-chain.js +147 -0
- package/dist/commands/finding-evidence-collect.d.ts +4 -0
- package/dist/commands/finding-evidence-collect.js +114 -0
- package/dist/commands/finding-explain.d.ts +4 -0
- package/dist/commands/finding-explain.js +93 -0
- package/dist/commands/finding-export-csv.d.ts +4 -0
- package/dist/commands/finding-export-csv.js +78 -0
- package/dist/commands/finding-false-neg-check.d.ts +8 -0
- package/dist/commands/finding-false-neg-check.js +139 -0
- package/dist/commands/finding-false-positive-learn.d.ts +4 -0
- package/dist/commands/finding-false-positive-learn.js +85 -0
- package/dist/commands/finding-false-positive-log.d.ts +4 -0
- package/dist/commands/finding-false-positive-log.js +150 -0
- package/dist/commands/finding-false-positive.d.ts +4 -0
- package/dist/commands/finding-false-positive.js +134 -0
- package/dist/commands/finding-filter-view.d.ts +4 -0
- package/dist/commands/finding-filter-view.js +107 -0
- package/dist/commands/finding-fix-chain.d.ts +1 -0
- package/dist/commands/finding-fix-chain.js +78 -0
- package/dist/commands/finding-fix-estimate.d.ts +1 -0
- package/dist/commands/finding-fix-estimate.js +95 -0
- package/dist/commands/finding-fix-playbook.d.ts +1 -0
- package/dist/commands/finding-fix-playbook.js +110 -0
- package/dist/commands/finding-fix-priority.d.ts +4 -0
- package/dist/commands/finding-fix-priority.js +98 -0
- package/dist/commands/finding-fix-rate.d.ts +4 -0
- package/dist/commands/finding-fix-rate.js +141 -0
- package/dist/commands/finding-fix-suggest.d.ts +4 -0
- package/dist/commands/finding-fix-suggest.js +88 -0
- package/dist/commands/finding-fix-validation.d.ts +4 -0
- package/dist/commands/finding-fix-validation.js +115 -0
- package/dist/commands/finding-fix-verify.d.ts +4 -0
- package/dist/commands/finding-fix-verify.js +198 -0
- package/dist/commands/finding-group-by.d.ts +4 -0
- package/dist/commands/finding-group-by.js +86 -0
- package/dist/commands/finding-group.d.ts +15 -0
- package/dist/commands/finding-group.js +164 -0
- package/dist/commands/finding-groupby-file.d.ts +4 -0
- package/dist/commands/finding-groupby-file.js +94 -0
- package/dist/commands/finding-hotfix-suggest.d.ts +7 -0
- package/dist/commands/finding-hotfix-suggest.js +170 -0
- package/dist/commands/finding-hotspot-detect.d.ts +1 -0
- package/dist/commands/finding-hotspot-detect.js +120 -0
- package/dist/commands/finding-hotspot-map.d.ts +4 -0
- package/dist/commands/finding-hotspot-map.js +106 -0
- package/dist/commands/finding-hotspot.d.ts +4 -0
- package/dist/commands/finding-hotspot.js +115 -0
- package/dist/commands/finding-impact-radius.d.ts +1 -0
- package/dist/commands/finding-impact-radius.js +94 -0
- package/dist/commands/finding-impact-rank.d.ts +4 -0
- package/dist/commands/finding-impact-rank.js +85 -0
- package/dist/commands/finding-impact-score.d.ts +4 -0
- package/dist/commands/finding-impact-score.js +123 -0
- package/dist/commands/finding-impact.d.ts +4 -0
- package/dist/commands/finding-impact.js +135 -0
- package/dist/commands/finding-line-blame.d.ts +7 -0
- package/dist/commands/finding-line-blame.js +129 -0
- package/dist/commands/finding-link-graph.d.ts +4 -0
- package/dist/commands/finding-link-graph.js +144 -0
- package/dist/commands/finding-link.d.ts +4 -0
- package/dist/commands/finding-link.js +128 -0
- package/dist/commands/finding-merge-results.d.ts +4 -0
- package/dist/commands/finding-merge-results.js +110 -0
- package/dist/commands/finding-merge-strategy.d.ts +1 -0
- package/dist/commands/finding-merge-strategy.js +84 -0
- package/dist/commands/finding-metadata-enrich.d.ts +4 -0
- package/dist/commands/finding-metadata-enrich.js +92 -0
- package/dist/commands/finding-noise-filter.d.ts +7 -0
- package/dist/commands/finding-noise-filter.js +140 -0
- package/dist/commands/finding-noise-reduce.d.ts +1 -0
- package/dist/commands/finding-noise-reduce.js +81 -0
- package/dist/commands/finding-noise-score.d.ts +1 -0
- package/dist/commands/finding-noise-score.js +93 -0
- package/dist/commands/finding-owner-assign.d.ts +4 -0
- package/dist/commands/finding-owner-assign.js +133 -0
- package/dist/commands/finding-owner-notify.d.ts +1 -0
- package/dist/commands/finding-owner-notify.js +121 -0
- package/dist/commands/finding-ownership-assign.d.ts +4 -0
- package/dist/commands/finding-ownership-assign.js +101 -0
- package/dist/commands/finding-ownership-map.d.ts +4 -0
- package/dist/commands/finding-ownership-map.js +118 -0
- package/dist/commands/finding-patch-chain.d.ts +1 -0
- package/dist/commands/finding-patch-chain.js +90 -0
- package/dist/commands/finding-patch-preview.d.ts +4 -0
- package/dist/commands/finding-patch-preview.js +103 -0
- package/dist/commands/finding-pattern-detect.d.ts +4 -0
- package/dist/commands/finding-pattern-detect.js +127 -0
- package/dist/commands/finding-pattern-library.d.ts +4 -0
- package/dist/commands/finding-pattern-library.js +145 -0
- package/dist/commands/finding-pattern-match.d.ts +4 -0
- package/dist/commands/finding-pattern-match.js +165 -0
- package/dist/commands/finding-prioritize.d.ts +4 -0
- package/dist/commands/finding-prioritize.js +119 -0
- package/dist/commands/finding-priority-matrix.d.ts +4 -0
- package/dist/commands/finding-priority-matrix.js +102 -0
- package/dist/commands/finding-priority-queue.d.ts +4 -0
- package/dist/commands/finding-priority-queue.js +131 -0
- package/dist/commands/finding-priority-rank.d.ts +1 -0
- package/dist/commands/finding-priority-rank.js +82 -0
- package/dist/commands/finding-quality-gate.d.ts +4 -0
- package/dist/commands/finding-quality-gate.js +107 -0
- package/dist/commands/finding-rank.d.ts +4 -0
- package/dist/commands/finding-rank.js +138 -0
- package/dist/commands/finding-reachability-check.d.ts +4 -0
- package/dist/commands/finding-reachability-check.js +102 -0
- package/dist/commands/finding-reachability.d.ts +4 -0
- package/dist/commands/finding-reachability.js +131 -0
- package/dist/commands/finding-recurrence-check.d.ts +1 -0
- package/dist/commands/finding-recurrence-check.js +103 -0
- package/dist/commands/finding-recurrence-detect.d.ts +4 -0
- package/dist/commands/finding-recurrence-detect.js +77 -0
- package/dist/commands/finding-recurrence.d.ts +4 -0
- package/dist/commands/finding-recurrence.js +135 -0
- package/dist/commands/finding-regression-check.d.ts +4 -0
- package/dist/commands/finding-regression-check.js +112 -0
- package/dist/commands/finding-regression-detect.d.ts +1 -0
- package/dist/commands/finding-regression-detect.js +86 -0
- package/dist/commands/finding-related-rules.d.ts +4 -0
- package/dist/commands/finding-related-rules.js +151 -0
- package/dist/commands/finding-remediation-cost.d.ts +1 -0
- package/dist/commands/finding-remediation-cost.js +79 -0
- package/dist/commands/finding-remediation-plan.d.ts +4 -0
- package/dist/commands/finding-remediation-plan.js +107 -0
- package/dist/commands/finding-reopen-detect.d.ts +1 -0
- package/dist/commands/finding-reopen-detect.js +77 -0
- package/dist/commands/finding-repeat-detect.d.ts +1 -0
- package/dist/commands/finding-repeat-detect.js +92 -0
- package/dist/commands/finding-resolution-track.d.ts +4 -0
- package/dist/commands/finding-resolution-track.js +150 -0
- package/dist/commands/finding-resolution-tracker.d.ts +4 -0
- package/dist/commands/finding-resolution-tracker.js +163 -0
- package/dist/commands/finding-resolution-workflow.d.ts +1 -0
- package/dist/commands/finding-resolution-workflow.js +91 -0
- package/dist/commands/finding-resolution.d.ts +4 -0
- package/dist/commands/finding-resolution.js +142 -0
- package/dist/commands/finding-risk-label.d.ts +1 -0
- package/dist/commands/finding-risk-label.js +72 -0
- package/dist/commands/finding-risk-matrix.d.ts +4 -0
- package/dist/commands/finding-risk-matrix.js +126 -0
- package/dist/commands/finding-risk-score.d.ts +4 -0
- package/dist/commands/finding-risk-score.js +95 -0
- package/dist/commands/finding-root-cause.d.ts +4 -0
- package/dist/commands/finding-root-cause.js +184 -0
- package/dist/commands/finding-rule-explain.d.ts +4 -0
- package/dist/commands/finding-rule-explain.js +140 -0
- package/dist/commands/finding-scope-filter.d.ts +1 -0
- package/dist/commands/finding-scope-filter.js +77 -0
- package/dist/commands/finding-scope-impact.d.ts +1 -0
- package/dist/commands/finding-scope-impact.js +83 -0
- package/dist/commands/finding-search-index.d.ts +4 -0
- package/dist/commands/finding-search-index.js +99 -0
- package/dist/commands/finding-security-hotspot.d.ts +4 -0
- package/dist/commands/finding-security-hotspot.js +175 -0
- package/dist/commands/finding-severity-dist.d.ts +4 -0
- package/dist/commands/finding-severity-dist.js +105 -0
- package/dist/commands/finding-severity-drift.d.ts +4 -0
- package/dist/commands/finding-severity-drift.js +92 -0
- package/dist/commands/finding-severity-heatmap.d.ts +4 -0
- package/dist/commands/finding-severity-heatmap.js +108 -0
- package/dist/commands/finding-severity-histogram.d.ts +4 -0
- package/dist/commands/finding-severity-histogram.js +66 -0
- package/dist/commands/finding-severity-override.d.ts +4 -0
- package/dist/commands/finding-severity-override.js +131 -0
- package/dist/commands/finding-severity-rebalance.d.ts +1 -0
- package/dist/commands/finding-severity-rebalance.js +108 -0
- package/dist/commands/finding-severity-trend.d.ts +4 -0
- package/dist/commands/finding-severity-trend.js +127 -0
- package/dist/commands/finding-similar-match.d.ts +1 -0
- package/dist/commands/finding-similar-match.js +112 -0
- package/dist/commands/finding-snippet.d.ts +4 -0
- package/dist/commands/finding-snippet.js +102 -0
- package/dist/commands/finding-summary-digest.d.ts +7 -0
- package/dist/commands/finding-summary-digest.js +145 -0
- package/dist/commands/finding-suppress-pattern.d.ts +4 -0
- package/dist/commands/finding-suppress-pattern.js +148 -0
- package/dist/commands/finding-suppress.d.ts +4 -0
- package/dist/commands/finding-suppress.js +164 -0
- package/dist/commands/finding-suppression-audit.d.ts +4 -0
- package/dist/commands/finding-suppression-audit.js +137 -0
- package/dist/commands/finding-suppression-list.d.ts +4 -0
- package/dist/commands/finding-suppression-list.js +119 -0
- package/dist/commands/finding-suppression-log.d.ts +4 -0
- package/dist/commands/finding-suppression-log.js +174 -0
- package/dist/commands/finding-time-to-fix.d.ts +1 -0
- package/dist/commands/finding-time-to-fix.js +98 -0
- package/dist/commands/finding-timeline-view.d.ts +4 -0
- package/dist/commands/finding-timeline-view.js +98 -0
- package/dist/commands/finding-timeline.d.ts +4 -0
- package/dist/commands/finding-timeline.js +143 -0
- package/dist/commands/finding-top-offender.d.ts +1 -0
- package/dist/commands/finding-top-offender.js +75 -0
- package/dist/commands/finding-trace.d.ts +4 -0
- package/dist/commands/finding-trace.js +118 -0
- package/dist/commands/finding-trend-alert.d.ts +1 -0
- package/dist/commands/finding-trend-alert.js +126 -0
- package/dist/commands/finding-trend-analysis.d.ts +4 -0
- package/dist/commands/finding-trend-analysis.js +95 -0
- package/dist/commands/finding-trend-forecast.d.ts +4 -0
- package/dist/commands/finding-trend-forecast.js +106 -0
- package/dist/commands/finding-trend-report.d.ts +4 -0
- package/dist/commands/finding-trend-report.js +107 -0
- package/dist/commands/finding-trend.d.ts +4 -0
- package/dist/commands/finding-trend.js +118 -0
- package/dist/commands/fix-pr.d.ts +22 -0
- package/dist/commands/fix-pr.js +286 -0
- package/dist/commands/fix-suggest.d.ts +4 -0
- package/dist/commands/fix-suggest.js +171 -0
- package/dist/commands/fix-verify.d.ts +4 -0
- package/dist/commands/fix-verify.js +123 -0
- package/dist/commands/fix.d.ts +117 -0
- package/dist/commands/fix.js +445 -0
- package/dist/commands/focus-area.d.ts +5 -0
- package/dist/commands/focus-area.js +192 -0
- package/dist/commands/generate.d.ts +7 -0
- package/dist/commands/generate.js +403 -0
- package/dist/commands/governance.d.ts +31 -0
- package/dist/commands/governance.js +202 -0
- package/dist/commands/group-findings.d.ts +22 -0
- package/dist/commands/group-findings.js +154 -0
- package/dist/commands/guided-tour.d.ts +8 -0
- package/dist/commands/guided-tour.js +287 -0
- package/dist/commands/habit-tracker.d.ts +7 -0
- package/dist/commands/habit-tracker.js +194 -0
- package/dist/commands/hallucination-detect.d.ts +4 -0
- package/dist/commands/hallucination-detect.js +350 -0
- package/dist/commands/hallucination-score.d.ts +8 -0
- package/dist/commands/hallucination-score.js +316 -0
- package/dist/commands/help.d.ts +7 -0
- package/dist/commands/help.js +302 -0
- package/dist/commands/hook-install.d.ts +21 -0
- package/dist/commands/hook-install.js +142 -0
- package/dist/commands/hook.d.ts +8 -0
- package/dist/commands/hook.js +145 -0
- package/dist/commands/iac-lint.d.ts +7 -0
- package/dist/commands/iac-lint.js +312 -0
- package/dist/commands/idempotency-audit.d.ts +4 -0
- package/dist/commands/idempotency-audit.js +222 -0
- package/dist/commands/ignore-list.d.ts +18 -0
- package/dist/commands/ignore-list.js +152 -0
- package/dist/commands/impact-scan.d.ts +8 -0
- package/dist/commands/impact-scan.js +281 -0
- package/dist/commands/incident-response.d.ts +7 -0
- package/dist/commands/incident-response.js +254 -0
- package/dist/commands/incremental-review.d.ts +4 -0
- package/dist/commands/incremental-review.js +236 -0
- package/dist/commands/init.d.ts +10 -0
- package/dist/commands/init.js +265 -0
- package/dist/commands/input-guard.d.ts +4 -0
- package/dist/commands/input-guard.js +255 -0
- package/dist/commands/interactive-fix.d.ts +22 -0
- package/dist/commands/interactive-fix.js +139 -0
- package/dist/commands/judge-author.d.ts +7 -0
- package/dist/commands/judge-author.js +260 -0
- package/dist/commands/judge-config.d.ts +4 -0
- package/dist/commands/judge-config.js +151 -0
- package/dist/commands/judge-learn.d.ts +8 -0
- package/dist/commands/judge-learn.js +217 -0
- package/dist/commands/judge-reputation.d.ts +28 -0
- package/dist/commands/judge-reputation.js +198 -0
- package/dist/commands/kb.d.ts +40 -0
- package/dist/commands/kb.js +228 -0
- package/dist/commands/language-packs.d.ts +42 -0
- package/dist/commands/language-packs.js +150 -0
- package/dist/commands/learn.d.ts +26 -0
- package/dist/commands/learn.js +288 -0
- package/dist/commands/learning-path.d.ts +8 -0
- package/dist/commands/learning-path.js +325 -0
- package/dist/commands/license-scan.d.ts +8 -0
- package/dist/commands/license-scan.js +183 -0
- package/dist/commands/llm-benchmark-optimizer.d.ts +78 -0
- package/dist/commands/llm-benchmark-optimizer.js +241 -0
- package/dist/commands/llm-benchmark.d.ts +156 -0
- package/dist/commands/llm-benchmark.js +670 -0
- package/dist/commands/log-quality.d.ts +5 -0
- package/dist/commands/log-quality.js +211 -0
- package/dist/commands/logic-lint.d.ts +4 -0
- package/dist/commands/logic-lint.js +255 -0
- package/dist/commands/lsp.d.ts +23 -0
- package/dist/commands/lsp.js +285 -0
- package/dist/commands/merge-verdict.d.ts +4 -0
- package/dist/commands/merge-verdict.js +287 -0
- package/dist/commands/metrics-dashboard.d.ts +21 -0
- package/dist/commands/metrics-dashboard.js +334 -0
- package/dist/commands/metrics.d.ts +57 -0
- package/dist/commands/metrics.js +241 -0
- package/dist/commands/migration-safety.d.ts +5 -0
- package/dist/commands/migration-safety.js +256 -0
- package/dist/commands/model-report.d.ts +8 -0
- package/dist/commands/model-report.js +194 -0
- package/dist/commands/model-risk.d.ts +27 -0
- package/dist/commands/model-risk.js +220 -0
- package/dist/commands/monorepo.d.ts +37 -0
- package/dist/commands/monorepo.js +232 -0
- package/dist/commands/multi-lang-review.d.ts +4 -0
- package/dist/commands/multi-lang-review.js +230 -0
- package/dist/commands/noise-advisor.d.ts +29 -0
- package/dist/commands/noise-advisor.js +170 -0
- package/dist/commands/notify.d.ts +78 -0
- package/dist/commands/notify.js +324 -0
- package/dist/commands/null-safety-audit.d.ts +5 -0
- package/dist/commands/null-safety-audit.js +221 -0
- package/dist/commands/observability-gap.d.ts +5 -0
- package/dist/commands/observability-gap.js +211 -0
- package/dist/commands/onboard.d.ts +12 -0
- package/dist/commands/onboard.js +178 -0
- package/dist/commands/org-metrics.d.ts +23 -0
- package/dist/commands/org-metrics.js +237 -0
- package/dist/commands/org-policy.d.ts +7 -0
- package/dist/commands/org-policy.js +207 -0
- package/dist/commands/over-abstraction.d.ts +4 -0
- package/dist/commands/over-abstraction.js +307 -0
- package/dist/commands/override.d.ts +61 -0
- package/dist/commands/override.js +268 -0
- package/dist/commands/ownership-map.d.ts +5 -0
- package/dist/commands/ownership-map.js +217 -0
- package/dist/commands/parity.d.ts +30 -0
- package/dist/commands/parity.js +212 -0
- package/dist/commands/pattern-registry.d.ts +22 -0
- package/dist/commands/pattern-registry.js +226 -0
- package/dist/commands/perf-compare.d.ts +8 -0
- package/dist/commands/perf-compare.js +245 -0
- package/dist/commands/perf-hotspot.d.ts +7 -0
- package/dist/commands/perf-hotspot.js +273 -0
- package/dist/commands/phantom-import.d.ts +4 -0
- package/dist/commands/phantom-import.js +260 -0
- package/dist/commands/pii-scan.d.ts +7 -0
- package/dist/commands/pii-scan.js +299 -0
- package/dist/commands/plugin-search.d.ts +39 -0
- package/dist/commands/plugin-search.js +327 -0
- package/dist/commands/plugins.d.ts +12 -0
- package/dist/commands/plugins.js +104 -0
- package/dist/commands/policy-audit.d.ts +52 -0
- package/dist/commands/policy-audit.js +160 -0
- package/dist/commands/pr-quality-gate.d.ts +28 -0
- package/dist/commands/pr-quality-gate.js +207 -0
- package/dist/commands/pr-summary.d.ts +25 -0
- package/dist/commands/pr-summary.js +187 -0
- package/dist/commands/predict.d.ts +7 -0
- package/dist/commands/predict.js +218 -0
- package/dist/commands/privilege-path.d.ts +4 -0
- package/dist/commands/privilege-path.js +233 -0
- package/dist/commands/profile.d.ts +37 -0
- package/dist/commands/profile.js +101 -0
- package/dist/commands/prompt-replay.d.ts +7 -0
- package/dist/commands/prompt-replay.js +176 -0
- package/dist/commands/quality-gate.d.ts +69 -0
- package/dist/commands/quality-gate.js +252 -0
- package/dist/commands/query.d.ts +19 -0
- package/dist/commands/query.js +229 -0
- package/dist/commands/quick-check.d.ts +4 -0
- package/dist/commands/quick-check.js +173 -0
- package/dist/commands/recommend.d.ts +20 -0
- package/dist/commands/recommend.js +282 -0
- package/dist/commands/refactor-safety.d.ts +8 -0
- package/dist/commands/refactor-safety.js +273 -0
- package/dist/commands/reg-watch.d.ts +20 -0
- package/dist/commands/reg-watch.js +219 -0
- package/dist/commands/regression-alert.d.ts +31 -0
- package/dist/commands/regression-alert.js +215 -0
- package/dist/commands/remediation-lib.d.ts +8 -0
- package/dist/commands/remediation-lib.js +265 -0
- package/dist/commands/remediation.d.ts +20 -0
- package/dist/commands/remediation.js +256 -0
- package/dist/commands/report-template.d.ts +16 -0
- package/dist/commands/report-template.js +290 -0
- package/dist/commands/report.d.ts +12 -0
- package/dist/commands/report.js +139 -0
- package/dist/commands/resource-cleanup.d.ts +6 -0
- package/dist/commands/resource-cleanup.js +235 -0
- package/dist/commands/retro.d.ts +22 -0
- package/dist/commands/retro.js +211 -0
- package/dist/commands/retry-pattern-audit.d.ts +5 -0
- package/dist/commands/retry-pattern-audit.js +215 -0
- package/dist/commands/review-ab-test.d.ts +4 -0
- package/dist/commands/review-ab-test.js +224 -0
- package/dist/commands/review-access-log.d.ts +4 -0
- package/dist/commands/review-access-log.js +65 -0
- package/dist/commands/review-action-item-gen.d.ts +1 -0
- package/dist/commands/review-action-item-gen.js +72 -0
- package/dist/commands/review-adoption-metrics.d.ts +4 -0
- package/dist/commands/review-adoption-metrics.js +95 -0
- package/dist/commands/review-adoption-score.d.ts +1 -0
- package/dist/commands/review-adoption-score.js +181 -0
- package/dist/commands/review-ai-feedback-loop.d.ts +1 -0
- package/dist/commands/review-ai-feedback-loop.js +116 -0
- package/dist/commands/review-annotate.d.ts +4 -0
- package/dist/commands/review-annotate.js +122 -0
- package/dist/commands/review-annotation-export.d.ts +4 -0
- package/dist/commands/review-annotation-export.js +105 -0
- package/dist/commands/review-annotation.d.ts +4 -0
- package/dist/commands/review-annotation.js +133 -0
- package/dist/commands/review-api-export.d.ts +4 -0
- package/dist/commands/review-api-export.js +98 -0
- package/dist/commands/review-approval-criteria.d.ts +1 -0
- package/dist/commands/review-approval-criteria.js +99 -0
- package/dist/commands/review-approval-gate.d.ts +7 -0
- package/dist/commands/review-approval-gate.js +190 -0
- package/dist/commands/review-approval.d.ts +4 -0
- package/dist/commands/review-approval.js +133 -0
- package/dist/commands/review-archive-search.d.ts +4 -0
- package/dist/commands/review-archive-search.js +70 -0
- package/dist/commands/review-archive.d.ts +4 -0
- package/dist/commands/review-archive.js +135 -0
- package/dist/commands/review-audit-export.d.ts +4 -0
- package/dist/commands/review-audit-export.js +93 -0
- package/dist/commands/review-audit-log.d.ts +4 -0
- package/dist/commands/review-audit-log.js +140 -0
- package/dist/commands/review-audit-trail.d.ts +4 -0
- package/dist/commands/review-audit-trail.js +96 -0
- package/dist/commands/review-auto-merge.d.ts +4 -0
- package/dist/commands/review-auto-merge.js +175 -0
- package/dist/commands/review-badge.d.ts +4 -0
- package/dist/commands/review-badge.js +152 -0
- package/dist/commands/review-batch-files.d.ts +4 -0
- package/dist/commands/review-batch-files.js +82 -0
- package/dist/commands/review-batch-mode.d.ts +4 -0
- package/dist/commands/review-batch-mode.js +97 -0
- package/dist/commands/review-batch-run.d.ts +4 -0
- package/dist/commands/review-batch-run.js +149 -0
- package/dist/commands/review-benchmark-self.d.ts +4 -0
- package/dist/commands/review-benchmark-self.js +140 -0
- package/dist/commands/review-blame-map.d.ts +4 -0
- package/dist/commands/review-blame-map.js +100 -0
- package/dist/commands/review-branch-compare.d.ts +4 -0
- package/dist/commands/review-branch-compare.js +108 -0
- package/dist/commands/review-branch-policy.d.ts +4 -0
- package/dist/commands/review-branch-policy.js +102 -0
- package/dist/commands/review-bulk-action.d.ts +4 -0
- package/dist/commands/review-bulk-action.js +109 -0
- package/dist/commands/review-bulk-apply.d.ts +4 -0
- package/dist/commands/review-bulk-apply.js +102 -0
- package/dist/commands/review-cache-clear.d.ts +4 -0
- package/dist/commands/review-cache-clear.js +160 -0
- package/dist/commands/review-cache-warm.d.ts +4 -0
- package/dist/commands/review-cache-warm.js +70 -0
- package/dist/commands/review-cache.d.ts +22 -0
- package/dist/commands/review-cache.js +134 -0
- package/dist/commands/review-changelog-entry.d.ts +7 -0
- package/dist/commands/review-changelog-entry.js +109 -0
- package/dist/commands/review-changelog-gen.d.ts +4 -0
- package/dist/commands/review-changelog-gen.js +117 -0
- package/dist/commands/review-changelog-impact.d.ts +1 -0
- package/dist/commands/review-changelog-impact.js +89 -0
- package/dist/commands/review-checklist.d.ts +4 -0
- package/dist/commands/review-checklist.js +144 -0
- package/dist/commands/review-checkpoint.d.ts +4 -0
- package/dist/commands/review-checkpoint.js +163 -0
- package/dist/commands/review-ci-gate.d.ts +4 -0
- package/dist/commands/review-ci-gate.js +114 -0
- package/dist/commands/review-ci-insight.d.ts +1 -0
- package/dist/commands/review-ci-insight.js +100 -0
- package/dist/commands/review-ci-integration.d.ts +4 -0
- package/dist/commands/review-ci-integration.js +125 -0
- package/dist/commands/review-ci-status.d.ts +4 -0
- package/dist/commands/review-ci-status.js +200 -0
- package/dist/commands/review-cicd-integrate.d.ts +4 -0
- package/dist/commands/review-cicd-integrate.js +122 -0
- package/dist/commands/review-code-health-score.d.ts +1 -0
- package/dist/commands/review-code-health-score.js +100 -0
- package/dist/commands/review-code-owner.d.ts +7 -0
- package/dist/commands/review-code-owner.js +164 -0
- package/dist/commands/review-code-ownership.d.ts +1 -0
- package/dist/commands/review-code-ownership.js +88 -0
- package/dist/commands/review-comment.d.ts +4 -0
- package/dist/commands/review-comment.js +165 -0
- package/dist/commands/review-commit-hook.d.ts +7 -0
- package/dist/commands/review-commit-hook.js +134 -0
- package/dist/commands/review-commit-quality.d.ts +1 -0
- package/dist/commands/review-commit-quality.js +94 -0
- package/dist/commands/review-comparative.d.ts +4 -0
- package/dist/commands/review-comparative.js +149 -0
- package/dist/commands/review-compare-version.d.ts +4 -0
- package/dist/commands/review-compare-version.js +108 -0
- package/dist/commands/review-compare.d.ts +4 -0
- package/dist/commands/review-compare.js +200 -0
- package/dist/commands/review-compliance-check.d.ts +4 -0
- package/dist/commands/review-compliance-check.js +202 -0
- package/dist/commands/review-compliance-gate.d.ts +4 -0
- package/dist/commands/review-compliance-gate.js +151 -0
- package/dist/commands/review-compliance-map.d.ts +4 -0
- package/dist/commands/review-compliance-map.js +110 -0
- package/dist/commands/review-compliance-report.d.ts +4 -0
- package/dist/commands/review-compliance-report.js +127 -0
- package/dist/commands/review-confidence-explain.d.ts +1 -0
- package/dist/commands/review-confidence-explain.js +99 -0
- package/dist/commands/review-config-diff.d.ts +4 -0
- package/dist/commands/review-config-diff.js +108 -0
- package/dist/commands/review-config-export.d.ts +4 -0
- package/dist/commands/review-config-export.js +124 -0
- package/dist/commands/review-config-health.d.ts +1 -0
- package/dist/commands/review-config-health.js +172 -0
- package/dist/commands/review-config-migrate.d.ts +4 -0
- package/dist/commands/review-config-migrate.js +123 -0
- package/dist/commands/review-config-template.d.ts +4 -0
- package/dist/commands/review-config-template.js +112 -0
- package/dist/commands/review-config-validate.d.ts +4 -0
- package/dist/commands/review-config-validate.js +110 -0
- package/dist/commands/review-contract.d.ts +4 -0
- package/dist/commands/review-contract.js +199 -0
- package/dist/commands/review-coverage-gap.d.ts +4 -0
- package/dist/commands/review-coverage-gap.js +120 -0
- package/dist/commands/review-coverage-map.d.ts +4 -0
- package/dist/commands/review-coverage-map.js +194 -0
- package/dist/commands/review-custom-judge-config.d.ts +4 -0
- package/dist/commands/review-custom-judge-config.js +103 -0
- package/dist/commands/review-custom-judge.d.ts +4 -0
- package/dist/commands/review-custom-judge.js +182 -0
- package/dist/commands/review-custom-prompt.d.ts +4 -0
- package/dist/commands/review-custom-prompt.js +170 -0
- package/dist/commands/review-custom-rule.d.ts +4 -0
- package/dist/commands/review-custom-rule.js +169 -0
- package/dist/commands/review-dashboard-data.d.ts +4 -0
- package/dist/commands/review-dashboard-data.js +142 -0
- package/dist/commands/review-dashboard.d.ts +4 -0
- package/dist/commands/review-dashboard.js +140 -0
- package/dist/commands/review-data-retention.d.ts +4 -0
- package/dist/commands/review-data-retention.js +119 -0
- package/dist/commands/review-dependency-graph.d.ts +4 -0
- package/dist/commands/review-dependency-graph.js +94 -0
- package/dist/commands/review-dependency-review.d.ts +1 -0
- package/dist/commands/review-dependency-review.js +104 -0
- package/dist/commands/review-deployment-gate.d.ts +4 -0
- package/dist/commands/review-deployment-gate.js +94 -0
- package/dist/commands/review-depth.d.ts +4 -0
- package/dist/commands/review-depth.js +142 -0
- package/dist/commands/review-diff-annotate.d.ts +4 -0
- package/dist/commands/review-diff-annotate.js +104 -0
- package/dist/commands/review-diff-context.d.ts +4 -0
- package/dist/commands/review-diff-context.js +158 -0
- package/dist/commands/review-diff-highlight.d.ts +4 -0
- package/dist/commands/review-diff-highlight.js +179 -0
- package/dist/commands/review-diff-stats.d.ts +4 -0
- package/dist/commands/review-diff-stats.js +90 -0
- package/dist/commands/review-diff-summary.d.ts +4 -0
- package/dist/commands/review-diff-summary.js +154 -0
- package/dist/commands/review-digest-gen.d.ts +1 -0
- package/dist/commands/review-digest-gen.js +100 -0
- package/dist/commands/review-digest.d.ts +4 -0
- package/dist/commands/review-digest.js +265 -0
- package/dist/commands/review-dry-run.d.ts +4 -0
- package/dist/commands/review-dry-run.js +120 -0
- package/dist/commands/review-engagement-score.d.ts +1 -0
- package/dist/commands/review-engagement-score.js +111 -0
- package/dist/commands/review-env-check.d.ts +4 -0
- package/dist/commands/review-env-check.js +115 -0
- package/dist/commands/review-environment-config.d.ts +4 -0
- package/dist/commands/review-environment-config.js +102 -0
- package/dist/commands/review-escalation-path.d.ts +1 -0
- package/dist/commands/review-escalation-path.js +86 -0
- package/dist/commands/review-exclude-vendor.d.ts +4 -0
- package/dist/commands/review-exclude-vendor.js +158 -0
- package/dist/commands/review-explain.d.ts +5 -0
- package/dist/commands/review-explain.js +194 -0
- package/dist/commands/review-export-pdf.d.ts +7 -0
- package/dist/commands/review-export-pdf.js +131 -0
- package/dist/commands/review-export.d.ts +4 -0
- package/dist/commands/review-export.js +179 -0
- package/dist/commands/review-feedback-loop.d.ts +4 -0
- package/dist/commands/review-feedback-loop.js +113 -0
- package/dist/commands/review-feedback-summary.d.ts +1 -0
- package/dist/commands/review-feedback-summary.js +130 -0
- package/dist/commands/review-feedback.d.ts +4 -0
- package/dist/commands/review-feedback.js +145 -0
- package/dist/commands/review-file-complexity.d.ts +4 -0
- package/dist/commands/review-file-complexity.js +137 -0
- package/dist/commands/review-file-filter.d.ts +4 -0
- package/dist/commands/review-file-filter.js +121 -0
- package/dist/commands/review-file-stats.d.ts +4 -0
- package/dist/commands/review-file-stats.js +130 -0
- package/dist/commands/review-filter.d.ts +4 -0
- package/dist/commands/review-filter.js +161 -0
- package/dist/commands/review-finding-link.d.ts +7 -0
- package/dist/commands/review-finding-link.js +115 -0
- package/dist/commands/review-focus-area.d.ts +1 -0
- package/dist/commands/review-focus-area.js +96 -0
- package/dist/commands/review-focus.d.ts +4 -0
- package/dist/commands/review-focus.js +196 -0
- package/dist/commands/review-gate-config.d.ts +4 -0
- package/dist/commands/review-gate-config.js +153 -0
- package/dist/commands/review-gate.d.ts +4 -0
- package/dist/commands/review-gate.js +212 -0
- package/dist/commands/review-goal-track.d.ts +1 -0
- package/dist/commands/review-goal-track.js +123 -0
- package/dist/commands/review-guardrail.d.ts +4 -0
- package/dist/commands/review-guardrail.js +155 -0
- package/dist/commands/review-handoff.d.ts +4 -0
- package/dist/commands/review-handoff.js +208 -0
- package/dist/commands/review-health-check.d.ts +4 -0
- package/dist/commands/review-health-check.js +148 -0
- package/dist/commands/review-health-trend.d.ts +1 -0
- package/dist/commands/review-health-trend.js +107 -0
- package/dist/commands/review-history-compare.d.ts +4 -0
- package/dist/commands/review-history-compare.js +93 -0
- package/dist/commands/review-history-search.d.ts +4 -0
- package/dist/commands/review-history-search.js +214 -0
- package/dist/commands/review-ide-sync.d.ts +4 -0
- package/dist/commands/review-ide-sync.js +91 -0
- package/dist/commands/review-ignore-path.d.ts +4 -0
- package/dist/commands/review-ignore-path.js +147 -0
- package/dist/commands/review-ignore-pattern.d.ts +5 -0
- package/dist/commands/review-ignore-pattern.js +138 -0
- package/dist/commands/review-incident-link.d.ts +4 -0
- package/dist/commands/review-incident-link.js +93 -0
- package/dist/commands/review-incremental.d.ts +4 -0
- package/dist/commands/review-incremental.js +128 -0
- package/dist/commands/review-integration-health.d.ts +4 -0
- package/dist/commands/review-integration-health.js +84 -0
- package/dist/commands/review-integration-test.d.ts +4 -0
- package/dist/commands/review-integration-test.js +145 -0
- package/dist/commands/review-integration.d.ts +4 -0
- package/dist/commands/review-integration.js +236 -0
- package/dist/commands/review-interactive.d.ts +4 -0
- package/dist/commands/review-interactive.js +85 -0
- package/dist/commands/review-knowledge-capture.d.ts +1 -0
- package/dist/commands/review-knowledge-capture.js +94 -0
- package/dist/commands/review-language-profile.d.ts +4 -0
- package/dist/commands/review-language-profile.js +72 -0
- package/dist/commands/review-language-stats.d.ts +4 -0
- package/dist/commands/review-language-stats.js +152 -0
- package/dist/commands/review-lock-file.d.ts +4 -0
- package/dist/commands/review-lock-file.js +153 -0
- package/dist/commands/review-lock.d.ts +4 -0
- package/dist/commands/review-lock.js +107 -0
- package/dist/commands/review-log.d.ts +22 -0
- package/dist/commands/review-log.js +164 -0
- package/dist/commands/review-mentor-suggest.d.ts +1 -0
- package/dist/commands/review-mentor-suggest.js +112 -0
- package/dist/commands/review-merge-check.d.ts +4 -0
- package/dist/commands/review-merge-check.js +101 -0
- package/dist/commands/review-merge-config.d.ts +4 -0
- package/dist/commands/review-merge-config.js +119 -0
- package/dist/commands/review-merge-readiness.d.ts +1 -0
- package/dist/commands/review-merge-readiness.js +90 -0
- package/dist/commands/review-merge-request.d.ts +4 -0
- package/dist/commands/review-merge-request.js +95 -0
- package/dist/commands/review-merge.d.ts +4 -0
- package/dist/commands/review-merge.js +145 -0
- package/dist/commands/review-metric-export.d.ts +4 -0
- package/dist/commands/review-metric-export.js +62 -0
- package/dist/commands/review-milestone.d.ts +4 -0
- package/dist/commands/review-milestone.js +136 -0
- package/dist/commands/review-multi-repo-sync.d.ts +4 -0
- package/dist/commands/review-multi-repo-sync.js +115 -0
- package/dist/commands/review-multi-repo.d.ts +4 -0
- package/dist/commands/review-multi-repo.js +145 -0
- package/dist/commands/review-note.d.ts +4 -0
- package/dist/commands/review-note.js +104 -0
- package/dist/commands/review-notification-config.d.ts +4 -0
- package/dist/commands/review-notification-config.js +122 -0
- package/dist/commands/review-notification-digest.d.ts +4 -0
- package/dist/commands/review-notification-digest.js +64 -0
- package/dist/commands/review-notification.d.ts +4 -0
- package/dist/commands/review-notification.js +126 -0
- package/dist/commands/review-notify.d.ts +4 -0
- package/dist/commands/review-notify.js +143 -0
- package/dist/commands/review-offline.d.ts +4 -0
- package/dist/commands/review-offline.js +125 -0
- package/dist/commands/review-onboard-checklist.d.ts +4 -0
- package/dist/commands/review-onboard-checklist.js +119 -0
- package/dist/commands/review-onboard-wizard.d.ts +4 -0
- package/dist/commands/review-onboard-wizard.js +92 -0
- package/dist/commands/review-onboard.d.ts +4 -0
- package/dist/commands/review-onboard.js +154 -0
- package/dist/commands/review-onboarding-check.d.ts +1 -0
- package/dist/commands/review-onboarding-check.js +93 -0
- package/dist/commands/review-org-dashboard.d.ts +4 -0
- package/dist/commands/review-org-dashboard.js +68 -0
- package/dist/commands/review-output-filter.d.ts +4 -0
- package/dist/commands/review-output-filter.js +112 -0
- package/dist/commands/review-output-format.d.ts +4 -0
- package/dist/commands/review-output-format.js +144 -0
- package/dist/commands/review-output-transform.d.ts +4 -0
- package/dist/commands/review-output-transform.js +119 -0
- package/dist/commands/review-owner.d.ts +4 -0
- package/dist/commands/review-owner.js +129 -0
- package/dist/commands/review-parallel-diff.d.ts +4 -0
- package/dist/commands/review-parallel-diff.js +146 -0
- package/dist/commands/review-parallel-files.d.ts +7 -0
- package/dist/commands/review-parallel-files.js +134 -0
- package/dist/commands/review-parallel-run.d.ts +4 -0
- package/dist/commands/review-parallel-run.js +116 -0
- package/dist/commands/review-parallel.d.ts +4 -0
- package/dist/commands/review-parallel.js +164 -0
- package/dist/commands/review-perf-profile.d.ts +4 -0
- package/dist/commands/review-perf-profile.js +98 -0
- package/dist/commands/review-permission-model.d.ts +4 -0
- package/dist/commands/review-permission-model.js +149 -0
- package/dist/commands/review-pipeline-status.d.ts +4 -0
- package/dist/commands/review-pipeline-status.js +54 -0
- package/dist/commands/review-plugin-config.d.ts +4 -0
- package/dist/commands/review-plugin-config.js +167 -0
- package/dist/commands/review-plugin-list.d.ts +4 -0
- package/dist/commands/review-plugin-list.js +99 -0
- package/dist/commands/review-plugin-manage.d.ts +4 -0
- package/dist/commands/review-plugin-manage.js +137 -0
- package/dist/commands/review-plugin-status.d.ts +4 -0
- package/dist/commands/review-plugin-status.js +53 -0
- package/dist/commands/review-policy-enforce.d.ts +1 -0
- package/dist/commands/review-policy-enforce.js +92 -0
- package/dist/commands/review-policy-engine.d.ts +4 -0
- package/dist/commands/review-policy-engine.js +135 -0
- package/dist/commands/review-pr-comment-gen.d.ts +4 -0
- package/dist/commands/review-pr-comment-gen.js +62 -0
- package/dist/commands/review-pr-comment.d.ts +4 -0
- package/dist/commands/review-pr-comment.js +106 -0
- package/dist/commands/review-pr-label-suggest.d.ts +1 -0
- package/dist/commands/review-pr-label-suggest.js +77 -0
- package/dist/commands/review-pr-size-check.d.ts +1 -0
- package/dist/commands/review-pr-size-check.js +98 -0
- package/dist/commands/review-pr-template.d.ts +4 -0
- package/dist/commands/review-pr-template.js +104 -0
- package/dist/commands/review-preset-save.d.ts +4 -0
- package/dist/commands/review-preset-save.js +159 -0
- package/dist/commands/review-priority.d.ts +4 -0
- package/dist/commands/review-priority.js +157 -0
- package/dist/commands/review-profile.d.ts +4 -0
- package/dist/commands/review-profile.js +168 -0
- package/dist/commands/review-progress-bar.d.ts +4 -0
- package/dist/commands/review-progress-bar.js +157 -0
- package/dist/commands/review-progress-report.d.ts +1 -0
- package/dist/commands/review-progress-report.js +95 -0
- package/dist/commands/review-progress-track.d.ts +4 -0
- package/dist/commands/review-progress-track.js +94 -0
- package/dist/commands/review-quality-baseline.d.ts +1 -0
- package/dist/commands/review-quality-baseline.js +134 -0
- package/dist/commands/review-quality-gate.d.ts +1 -0
- package/dist/commands/review-quality-gate.js +86 -0
- package/dist/commands/review-quality-score.d.ts +4 -0
- package/dist/commands/review-quality-score.js +127 -0
- package/dist/commands/review-quality-trend.d.ts +4 -0
- package/dist/commands/review-quality-trend.js +57 -0
- package/dist/commands/review-queue.d.ts +33 -0
- package/dist/commands/review-queue.js +225 -0
- package/dist/commands/review-quickstart.d.ts +4 -0
- package/dist/commands/review-quickstart.js +107 -0
- package/dist/commands/review-quota-check.d.ts +4 -0
- package/dist/commands/review-quota-check.js +97 -0
- package/dist/commands/review-quota.d.ts +4 -0
- package/dist/commands/review-quota.js +126 -0
- package/dist/commands/review-rate-limit.d.ts +4 -0
- package/dist/commands/review-rate-limit.js +130 -0
- package/dist/commands/review-readiness-check.d.ts +1 -0
- package/dist/commands/review-readiness-check.js +98 -0
- package/dist/commands/review-receipt.d.ts +4 -0
- package/dist/commands/review-receipt.js +220 -0
- package/dist/commands/review-release-gate.d.ts +1 -0
- package/dist/commands/review-release-gate.js +81 -0
- package/dist/commands/review-replay.d.ts +8 -0
- package/dist/commands/review-replay.js +264 -0
- package/dist/commands/review-repo-onboard.d.ts +4 -0
- package/dist/commands/review-repo-onboard.js +114 -0
- package/dist/commands/review-report-archive.d.ts +4 -0
- package/dist/commands/review-report-archive.js +100 -0
- package/dist/commands/review-report-merge.d.ts +4 -0
- package/dist/commands/review-report-merge.js +90 -0
- package/dist/commands/review-report-pdf.d.ts +4 -0
- package/dist/commands/review-report-pdf.js +163 -0
- package/dist/commands/review-report-schedule.d.ts +4 -0
- package/dist/commands/review-report-schedule.js +96 -0
- package/dist/commands/review-retrospective.d.ts +1 -0
- package/dist/commands/review-retrospective.js +118 -0
- package/dist/commands/review-retry.d.ts +4 -0
- package/dist/commands/review-retry.js +91 -0
- package/dist/commands/review-review-cadence.d.ts +1 -0
- package/dist/commands/review-review-cadence.js +85 -0
- package/dist/commands/review-review-comments.d.ts +4 -0
- package/dist/commands/review-review-comments.js +84 -0
- package/dist/commands/review-reviewer-match.d.ts +1 -0
- package/dist/commands/review-reviewer-match.js +108 -0
- package/dist/commands/review-risk-matrix.d.ts +1 -0
- package/dist/commands/review-risk-matrix.js +96 -0
- package/dist/commands/review-risk-score.d.ts +4 -0
- package/dist/commands/review-risk-score.js +156 -0
- package/dist/commands/review-role-assignment.d.ts +4 -0
- package/dist/commands/review-role-assignment.js +98 -0
- package/dist/commands/review-rollback.d.ts +4 -0
- package/dist/commands/review-rollback.js +171 -0
- package/dist/commands/review-rollout-plan.d.ts +4 -0
- package/dist/commands/review-rollout-plan.js +123 -0
- package/dist/commands/review-rule-filter.d.ts +4 -0
- package/dist/commands/review-rule-filter.js +116 -0
- package/dist/commands/review-rule-stats.d.ts +4 -0
- package/dist/commands/review-rule-stats.js +161 -0
- package/dist/commands/review-sandbox.d.ts +4 -0
- package/dist/commands/review-sandbox.js +191 -0
- package/dist/commands/review-schedule.d.ts +4 -0
- package/dist/commands/review-schedule.js +169 -0
- package/dist/commands/review-scope-limit.d.ts +4 -0
- package/dist/commands/review-scope-limit.js +100 -0
- package/dist/commands/review-scope-lock.d.ts +7 -0
- package/dist/commands/review-scope-lock.js +138 -0
- package/dist/commands/review-scope-select.d.ts +4 -0
- package/dist/commands/review-scope-select.js +98 -0
- package/dist/commands/review-scope-suggest.d.ts +1 -0
- package/dist/commands/review-scope-suggest.js +112 -0
- package/dist/commands/review-scope.d.ts +4 -0
- package/dist/commands/review-scope.js +197 -0
- package/dist/commands/review-score-history.d.ts +4 -0
- package/dist/commands/review-score-history.js +137 -0
- package/dist/commands/review-security-posture.d.ts +1 -0
- package/dist/commands/review-security-posture.js +105 -0
- package/dist/commands/review-session-replay.d.ts +4 -0
- package/dist/commands/review-session-replay.js +81 -0
- package/dist/commands/review-session-save.d.ts +4 -0
- package/dist/commands/review-session-save.js +173 -0
- package/dist/commands/review-session.d.ts +4 -0
- package/dist/commands/review-session.js +150 -0
- package/dist/commands/review-skip-list.d.ts +4 -0
- package/dist/commands/review-skip-list.js +135 -0
- package/dist/commands/review-skip-rule.d.ts +4 -0
- package/dist/commands/review-skip-rule.js +105 -0
- package/dist/commands/review-sla-config.d.ts +4 -0
- package/dist/commands/review-sla-config.js +88 -0
- package/dist/commands/review-slack-format.d.ts +4 -0
- package/dist/commands/review-slack-format.js +113 -0
- package/dist/commands/review-snapshot-diff.d.ts +4 -0
- package/dist/commands/review-snapshot-diff.js +100 -0
- package/dist/commands/review-sprint-plan.d.ts +1 -0
- package/dist/commands/review-sprint-plan.js +79 -0
- package/dist/commands/review-stakeholder-notify.d.ts +1 -0
- package/dist/commands/review-stakeholder-notify.js +134 -0
- package/dist/commands/review-stakeholder-report.d.ts +4 -0
- package/dist/commands/review-stakeholder-report.js +75 -0
- package/dist/commands/review-stale-finding-clean.d.ts +1 -0
- package/dist/commands/review-stale-finding-clean.js +81 -0
- package/dist/commands/review-standup.d.ts +4 -0
- package/dist/commands/review-standup.js +95 -0
- package/dist/commands/review-stats.d.ts +4 -0
- package/dist/commands/review-stats.js +175 -0
- package/dist/commands/review-status-badge.d.ts +4 -0
- package/dist/commands/review-status-badge.js +120 -0
- package/dist/commands/review-streak.d.ts +4 -0
- package/dist/commands/review-streak.js +150 -0
- package/dist/commands/review-summary-dashboard.d.ts +4 -0
- package/dist/commands/review-summary-dashboard.js +96 -0
- package/dist/commands/review-summary-email.d.ts +4 -0
- package/dist/commands/review-summary-email.js +102 -0
- package/dist/commands/review-summary.d.ts +4 -0
- package/dist/commands/review-summary.js +174 -0
- package/dist/commands/review-tag-manager.d.ts +4 -0
- package/dist/commands/review-tag-manager.js +128 -0
- package/dist/commands/review-tag.d.ts +4 -0
- package/dist/commands/review-tag.js +136 -0
- package/dist/commands/review-team-analytics.d.ts +1 -0
- package/dist/commands/review-team-analytics.js +94 -0
- package/dist/commands/review-team-assign.d.ts +7 -0
- package/dist/commands/review-team-assign.js +211 -0
- package/dist/commands/review-team-coverage.d.ts +1 -0
- package/dist/commands/review-team-coverage.js +95 -0
- package/dist/commands/review-team-dashboard.d.ts +4 -0
- package/dist/commands/review-team-dashboard.js +98 -0
- package/dist/commands/review-team-rotation.d.ts +1 -0
- package/dist/commands/review-team-rotation.js +99 -0
- package/dist/commands/review-team-skill-map.d.ts +1 -0
- package/dist/commands/review-team-skill-map.js +102 -0
- package/dist/commands/review-team-stats.d.ts +4 -0
- package/dist/commands/review-team-stats.js +97 -0
- package/dist/commands/review-team-summary.d.ts +4 -0
- package/dist/commands/review-team-summary.js +155 -0
- package/dist/commands/review-team-velocity.d.ts +1 -0
- package/dist/commands/review-team-velocity.js +103 -0
- package/dist/commands/review-template-export.d.ts +4 -0
- package/dist/commands/review-template-export.js +146 -0
- package/dist/commands/review-template-library.d.ts +4 -0
- package/dist/commands/review-template-library.js +155 -0
- package/dist/commands/review-template-suggest.d.ts +1 -0
- package/dist/commands/review-template-suggest.js +119 -0
- package/dist/commands/review-template.d.ts +4 -0
- package/dist/commands/review-template.js +212 -0
- package/dist/commands/review-tenant-config.d.ts +4 -0
- package/dist/commands/review-tenant-config.js +116 -0
- package/dist/commands/review-threshold-tune.d.ts +4 -0
- package/dist/commands/review-threshold-tune.js +135 -0
- package/dist/commands/review-timeline.d.ts +4 -0
- package/dist/commands/review-timeline.js +76 -0
- package/dist/commands/review-token-budget.d.ts +4 -0
- package/dist/commands/review-token-budget.js +117 -0
- package/dist/commands/review-velocity-track.d.ts +1 -0
- package/dist/commands/review-velocity-track.js +94 -0
- package/dist/commands/review-watch-mode.d.ts +7 -0
- package/dist/commands/review-watch-mode.js +132 -0
- package/dist/commands/review-webhook-dispatch.d.ts +4 -0
- package/dist/commands/review-webhook-dispatch.js +99 -0
- package/dist/commands/review-webhook-notify.d.ts +4 -0
- package/dist/commands/review-webhook-notify.js +145 -0
- package/dist/commands/review-webhook.d.ts +4 -0
- package/dist/commands/review-webhook.js +140 -0
- package/dist/commands/review-whitelist.d.ts +4 -0
- package/dist/commands/review-whitelist.js +150 -0
- package/dist/commands/review-workflow-suggest.d.ts +1 -0
- package/dist/commands/review-workflow-suggest.js +129 -0
- package/dist/commands/review-workload-balance.d.ts +1 -0
- package/dist/commands/review-workload-balance.js +86 -0
- package/dist/commands/review-workspace-init.d.ts +4 -0
- package/dist/commands/review-workspace-init.js +104 -0
- package/dist/commands/review-workspace-scan.d.ts +4 -0
- package/dist/commands/review-workspace-scan.js +144 -0
- package/dist/commands/review.d.ts +155 -0
- package/dist/commands/review.js +1114 -0
- package/dist/commands/risk-heatmap.d.ts +7 -0
- package/dist/commands/risk-heatmap.js +223 -0
- package/dist/commands/rollback-safety.d.ts +4 -0
- package/dist/commands/rollback-safety.js +191 -0
- package/dist/commands/rule-catalog.d.ts +4 -0
- package/dist/commands/rule-catalog.js +128 -0
- package/dist/commands/rule-metrics.d.ts +43 -0
- package/dist/commands/rule-metrics.js +113 -0
- package/dist/commands/rule-owner.d.ts +30 -0
- package/dist/commands/rule-owner.js +181 -0
- package/dist/commands/rule-share.d.ts +34 -0
- package/dist/commands/rule-share.js +202 -0
- package/dist/commands/rule-test.d.ts +4 -0
- package/dist/commands/rule-test.js +201 -0
- package/dist/commands/rule.d.ts +114 -0
- package/dist/commands/rule.js +295 -0
- package/dist/commands/sbom-export.d.ts +7 -0
- package/dist/commands/sbom-export.js +161 -0
- package/dist/commands/scaffold-plugin.d.ts +15 -0
- package/dist/commands/scaffold-plugin.js +270 -0
- package/dist/commands/secret-age.d.ts +5 -0
- package/dist/commands/secret-age.js +214 -0
- package/dist/commands/secret-scan.d.ts +7 -0
- package/dist/commands/secret-scan.js +244 -0
- package/dist/commands/security-maturity.d.ts +7 -0
- package/dist/commands/security-maturity.js +312 -0
- package/dist/commands/security-theater.d.ts +4 -0
- package/dist/commands/security-theater.js +278 -0
- package/dist/commands/setup-wizard.d.ts +4 -0
- package/dist/commands/setup-wizard.js +174 -0
- package/dist/commands/severity-tune.d.ts +4 -0
- package/dist/commands/severity-tune.js +208 -0
- package/dist/commands/sla-track.d.ts +56 -0
- package/dist/commands/sla-track.js +268 -0
- package/dist/commands/smart-output.d.ts +38 -0
- package/dist/commands/smart-output.js +175 -0
- package/dist/commands/smart-select.d.ts +26 -0
- package/dist/commands/smart-select.js +345 -0
- package/dist/commands/snapshot.d.ts +139 -0
- package/dist/commands/snapshot.js +478 -0
- package/dist/commands/snippet-eval.d.ts +7 -0
- package/dist/commands/snippet-eval.js +223 -0
- package/dist/commands/spec-conform.d.ts +4 -0
- package/dist/commands/spec-conform.js +304 -0
- package/dist/commands/stale-pattern.d.ts +4 -0
- package/dist/commands/stale-pattern.js +293 -0
- package/dist/commands/state-integrity.d.ts +4 -0
- package/dist/commands/state-integrity.js +283 -0
- package/dist/commands/suppress.d.ts +39 -0
- package/dist/commands/suppress.js +203 -0
- package/dist/commands/team-config.d.ts +4 -0
- package/dist/commands/team-config.js +234 -0
- package/dist/commands/team-leaderboard.d.ts +24 -0
- package/dist/commands/team-leaderboard.js +227 -0
- package/dist/commands/team-rules-sync.d.ts +7 -0
- package/dist/commands/team-rules-sync.js +250 -0
- package/dist/commands/team-trust.d.ts +7 -0
- package/dist/commands/team-trust.js +174 -0
- package/dist/commands/test-correlate.d.ts +7 -0
- package/dist/commands/test-correlate.js +221 -0
- package/dist/commands/test-isolation.d.ts +5 -0
- package/dist/commands/test-isolation.js +234 -0
- package/dist/commands/test-quality.d.ts +5 -0
- package/dist/commands/test-quality.js +160 -0
- package/dist/commands/test-suggest.d.ts +8 -0
- package/dist/commands/test-suggest.js +247 -0
- package/dist/commands/ticket-sync.d.ts +25 -0
- package/dist/commands/ticket-sync.js +235 -0
- package/dist/commands/timeout-audit.d.ts +4 -0
- package/dist/commands/timeout-audit.js +210 -0
- package/dist/commands/trace.d.ts +64 -0
- package/dist/commands/trace.js +245 -0
- package/dist/commands/trend-report.d.ts +4 -0
- package/dist/commands/trend-report.js +148 -0
- package/dist/commands/triage.d.ts +15 -0
- package/dist/commands/triage.js +171 -0
- package/dist/commands/trust-adaptive.d.ts +8 -0
- package/dist/commands/trust-adaptive.js +193 -0
- package/dist/commands/trust-ramp.d.ts +29 -0
- package/dist/commands/trust-ramp.js +189 -0
- package/dist/commands/tune.d.ts +24 -0
- package/dist/commands/tune.js +380 -0
- package/dist/commands/type-boundary.d.ts +4 -0
- package/dist/commands/type-boundary.js +235 -0
- package/dist/commands/upload.d.ts +13 -0
- package/dist/commands/upload.js +172 -0
- package/dist/commands/validate-config.d.ts +16 -0
- package/dist/commands/validate-config.js +267 -0
- package/dist/commands/vendor-lock-detect.d.ts +7 -0
- package/dist/commands/vendor-lock-detect.js +288 -0
- package/dist/commands/vote.d.ts +31 -0
- package/dist/commands/vote.js +200 -0
- package/dist/commands/warm-cache.d.ts +30 -0
- package/dist/commands/warm-cache.js +165 -0
- package/dist/commands/watch-judge.d.ts +7 -0
- package/dist/commands/watch-judge.js +179 -0
- package/dist/commands/watch.d.ts +22 -0
- package/dist/commands/watch.js +147 -0
- package/dist/comparison.d.ts +67 -0
- package/dist/comparison.js +253 -0
- package/dist/config.d.ts +108 -0
- package/dist/config.js +694 -0
- package/dist/context/context-snippets.d.ts +15 -0
- package/dist/context/context-snippets.js +36 -0
- package/dist/context/embedding-cache.d.ts +30 -0
- package/dist/context/embedding-cache.js +48 -0
- package/dist/data-adapter.d.ts +123 -0
- package/dist/data-adapter.js +212 -0
- package/dist/dedup.d.ts +105 -0
- package/dist/dedup.js +606 -0
- package/dist/disk-cache.d.ts +59 -0
- package/dist/disk-cache.js +236 -0
- package/dist/errors.d.ts +43 -0
- package/dist/errors.js +63 -0
- package/dist/escalation.d.ts +100 -0
- package/dist/escalation.js +292 -0
- package/dist/evaluation-session.d.ts +74 -0
- package/dist/evaluation-session.js +152 -0
- package/dist/evaluators/accessibility.d.ts +2 -0
- package/dist/evaluators/accessibility.js +559 -0
- package/dist/evaluators/agent-instructions.d.ts +2 -0
- package/dist/evaluators/agent-instructions.js +214 -0
- package/dist/evaluators/ai-code-safety.d.ts +8 -0
- package/dist/evaluators/ai-code-safety.js +410 -0
- package/dist/evaluators/api-contract.d.ts +9 -0
- package/dist/evaluators/api-contract.js +203 -0
- package/dist/evaluators/api-design.d.ts +2 -0
- package/dist/evaluators/api-design.js +260 -0
- package/dist/evaluators/app-builder.d.ts +33 -0
- package/dist/evaluators/app-builder.js +155 -0
- package/dist/evaluators/authentication.d.ts +2 -0
- package/dist/evaluators/authentication.js +455 -0
- package/dist/evaluators/backwards-compatibility.d.ts +2 -0
- package/dist/evaluators/backwards-compatibility.js +168 -0
- package/dist/evaluators/caching.d.ts +2 -0
- package/dist/evaluators/caching.js +171 -0
- package/dist/evaluators/ci-cd.d.ts +2 -0
- package/dist/evaluators/ci-cd.js +218 -0
- package/dist/evaluators/cloud-readiness.d.ts +2 -0
- package/dist/evaluators/cloud-readiness.js +231 -0
- package/dist/evaluators/code-structure.d.ts +21 -0
- package/dist/evaluators/code-structure.js +195 -0
- package/dist/evaluators/compliance.d.ts +2 -0
- package/dist/evaluators/compliance.js +329 -0
- package/dist/evaluators/concurrency.d.ts +2 -0
- package/dist/evaluators/concurrency.js +307 -0
- package/dist/evaluators/configuration-management.d.ts +2 -0
- package/dist/evaluators/configuration-management.js +232 -0
- package/dist/evaluators/cost-effectiveness.d.ts +2 -0
- package/dist/evaluators/cost-effectiveness.js +418 -0
- package/dist/evaluators/cybersecurity.d.ts +2 -0
- package/dist/evaluators/cybersecurity.js +1197 -0
- package/dist/evaluators/data-security.d.ts +2 -0
- package/dist/evaluators/data-security.js +467 -0
- package/dist/evaluators/data-sovereignty.d.ts +2 -0
- package/dist/evaluators/data-sovereignty.js +495 -0
- package/dist/evaluators/database.d.ts +2 -0
- package/dist/evaluators/database.js +240 -0
- package/dist/evaluators/dependencies.d.ts +5 -0
- package/dist/evaluators/dependencies.js +228 -0
- package/dist/evaluators/dependency-health.d.ts +2 -0
- package/dist/evaluators/dependency-health.js +477 -0
- package/dist/evaluators/documentation.d.ts +2 -0
- package/dist/evaluators/documentation.js +432 -0
- package/dist/evaluators/error-handling.d.ts +2 -0
- package/dist/evaluators/error-handling.js +426 -0
- package/dist/evaluators/ethics-bias.d.ts +2 -0
- package/dist/evaluators/ethics-bias.js +263 -0
- package/dist/evaluators/false-positive-review.d.ts +21 -0
- package/dist/evaluators/false-positive-review.js +1246 -0
- package/dist/evaluators/framework-rules.d.ts +58 -0
- package/dist/evaluators/framework-rules.js +291 -0
- package/dist/evaluators/framework-safety.d.ts +12 -0
- package/dist/evaluators/framework-safety.js +1205 -0
- package/dist/evaluators/hallucination-detection.d.ts +2 -0
- package/dist/evaluators/hallucination-detection.js +1250 -0
- package/dist/evaluators/iac-security.d.ts +8 -0
- package/dist/evaluators/iac-security.js +701 -0
- package/dist/evaluators/index.d.ts +167 -0
- package/dist/evaluators/index.js +994 -0
- package/dist/evaluators/intent-alignment.d.ts +18 -0
- package/dist/evaluators/intent-alignment.js +405 -0
- package/dist/evaluators/internationalization.d.ts +2 -0
- package/dist/evaluators/internationalization.js +287 -0
- package/dist/evaluators/judge-selector.d.ts +19 -0
- package/dist/evaluators/judge-selector.js +141 -0
- package/dist/evaluators/logging-privacy.d.ts +2 -0
- package/dist/evaluators/logging-privacy.js +190 -0
- package/dist/evaluators/logic-review.d.ts +2 -0
- package/dist/evaluators/logic-review.js +289 -0
- package/dist/evaluators/maintainability.d.ts +2 -0
- package/dist/evaluators/maintainability.js +430 -0
- package/dist/evaluators/model-fingerprint.d.ts +2 -0
- package/dist/evaluators/model-fingerprint.js +151 -0
- package/dist/evaluators/multi-turn-coherence.d.ts +13 -0
- package/dist/evaluators/multi-turn-coherence.js +149 -0
- package/dist/evaluators/observability.d.ts +2 -0
- package/dist/evaluators/observability.js +238 -0
- package/dist/evaluators/over-engineering.d.ts +2 -0
- package/dist/evaluators/over-engineering.js +160 -0
- package/dist/evaluators/performance.d.ts +2 -0
- package/dist/evaluators/performance.js +649 -0
- package/dist/evaluators/portability.d.ts +2 -0
- package/dist/evaluators/portability.js +254 -0
- package/dist/evaluators/project.d.ts +48 -0
- package/dist/evaluators/project.js +817 -0
- package/dist/evaluators/rate-limiting.d.ts +2 -0
- package/dist/evaluators/rate-limiting.js +193 -0
- package/dist/evaluators/recall-boost.d.ts +27 -0
- package/dist/evaluators/recall-boost.js +409 -0
- package/dist/evaluators/reliability.d.ts +2 -0
- package/dist/evaluators/reliability.js +245 -0
- package/dist/evaluators/scalability.d.ts +2 -0
- package/dist/evaluators/scalability.js +230 -0
- package/dist/evaluators/security.d.ts +12 -0
- package/dist/evaluators/security.js +1013 -0
- package/dist/evaluators/shared.d.ts +219 -0
- package/dist/evaluators/shared.js +1169 -0
- package/dist/evaluators/software-practices.d.ts +2 -0
- package/dist/evaluators/software-practices.js +395 -0
- package/dist/evaluators/suppressions.d.ts +49 -0
- package/dist/evaluators/suppressions.js +185 -0
- package/dist/evaluators/testing.d.ts +2 -0
- package/dist/evaluators/testing.js +348 -0
- package/dist/evaluators/ux.d.ts +2 -0
- package/dist/evaluators/ux.js +309 -0
- package/dist/evaluators/v2.d.ts +26 -0
- package/dist/evaluators/v2.js +354 -0
- package/dist/ext-to-lang.d.ts +16 -0
- package/dist/ext-to-lang.js +60 -0
- package/dist/feedback-loop.d.ts +62 -0
- package/dist/feedback-loop.js +179 -0
- package/dist/finding-lifecycle.d.ts +215 -0
- package/dist/finding-lifecycle.js +547 -0
- package/dist/fingerprint.d.ts +39 -0
- package/dist/fingerprint.js +179 -0
- package/dist/fix-history.d.ts +103 -0
- package/dist/fix-history.js +164 -0
- package/dist/formatters/badge.d.ts +16 -0
- package/dist/formatters/badge.js +78 -0
- package/dist/formatters/codeclimate.d.ts +24 -0
- package/dist/formatters/codeclimate.js +80 -0
- package/dist/formatters/csv.d.ts +16 -0
- package/dist/formatters/csv.js +53 -0
- package/dist/formatters/diagnostics.d.ts +81 -0
- package/dist/formatters/diagnostics.js +152 -0
- package/dist/formatters/github-actions.d.ts +6 -0
- package/dist/formatters/github-actions.js +68 -0
- package/dist/formatters/html.d.ts +12 -0
- package/dist/formatters/html.js +194 -0
- package/dist/formatters/junit.d.ts +6 -0
- package/dist/formatters/junit.js +68 -0
- package/dist/formatters/pdf.d.ts +12 -0
- package/dist/formatters/pdf.js +114 -0
- package/dist/formatters/sarif.d.ts +92 -0
- package/dist/formatters/sarif.js +256 -0
- package/dist/formatters/shared.d.ts +4 -0
- package/dist/formatters/shared.js +29 -0
- package/dist/git-diff.d.ts +62 -0
- package/dist/git-diff.js +282 -0
- package/dist/github-app.d.ts +152 -0
- package/dist/github-app.js +716 -0
- package/dist/import-resolver.d.ts +51 -0
- package/dist/import-resolver.js +213 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +38 -0
- package/dist/judge-registry.d.ts +156 -0
- package/dist/judge-registry.js +272 -0
- package/dist/judges/accessibility.d.ts +2 -0
- package/dist/judges/accessibility.js +46 -0
- package/dist/judges/agent-instructions.d.ts +2 -0
- package/dist/judges/agent-instructions.js +46 -0
- package/dist/judges/ai-code-safety.d.ts +2 -0
- package/dist/judges/ai-code-safety.js +57 -0
- package/dist/judges/api-contract.d.ts +2 -0
- package/dist/judges/api-contract.js +40 -0
- package/dist/judges/api-design.d.ts +2 -0
- package/dist/judges/api-design.js +57 -0
- package/dist/judges/authentication.d.ts +2 -0
- package/dist/judges/authentication.js +63 -0
- package/dist/judges/backwards-compatibility.d.ts +2 -0
- package/dist/judges/backwards-compatibility.js +46 -0
- package/dist/judges/caching.d.ts +2 -0
- package/dist/judges/caching.js +46 -0
- package/dist/judges/ci-cd.d.ts +2 -0
- package/dist/judges/ci-cd.js +46 -0
- package/dist/judges/cloud-readiness.d.ts +2 -0
- package/dist/judges/cloud-readiness.js +53 -0
- package/dist/judges/code-structure.d.ts +2 -0
- package/dist/judges/code-structure.js +50 -0
- package/dist/judges/compliance.d.ts +2 -0
- package/dist/judges/compliance.js +49 -0
- package/dist/judges/concurrency.d.ts +2 -0
- package/dist/judges/concurrency.js +48 -0
- package/dist/judges/configuration-management.d.ts +2 -0
- package/dist/judges/configuration-management.js +46 -0
- package/dist/judges/cost-effectiveness.d.ts +2 -0
- package/dist/judges/cost-effectiveness.js +42 -0
- package/dist/judges/cybersecurity.d.ts +2 -0
- package/dist/judges/cybersecurity.js +63 -0
- package/dist/judges/data-security.d.ts +2 -0
- package/dist/judges/data-security.js +50 -0
- package/dist/judges/data-sovereignty.d.ts +2 -0
- package/dist/judges/data-sovereignty.js +60 -0
- package/dist/judges/database.d.ts +2 -0
- package/dist/judges/database.js +51 -0
- package/dist/judges/dependency-health.d.ts +2 -0
- package/dist/judges/dependency-health.js +48 -0
- package/dist/judges/documentation.d.ts +2 -0
- package/dist/judges/documentation.js +55 -0
- package/dist/judges/error-handling.d.ts +2 -0
- package/dist/judges/error-handling.js +55 -0
- package/dist/judges/ethics-bias.d.ts +2 -0
- package/dist/judges/ethics-bias.js +48 -0
- package/dist/judges/false-positive-review.d.ts +2 -0
- package/dist/judges/false-positive-review.js +85 -0
- package/dist/judges/framework-safety.d.ts +2 -0
- package/dist/judges/framework-safety.js +49 -0
- package/dist/judges/hallucination-detection.d.ts +2 -0
- package/dist/judges/hallucination-detection.js +48 -0
- package/dist/judges/iac-security.d.ts +2 -0
- package/dist/judges/iac-security.js +47 -0
- package/dist/judges/index.d.ts +88 -0
- package/dist/judges/index.js +128 -0
- package/dist/judges/intent-alignment.d.ts +2 -0
- package/dist/judges/intent-alignment.js +46 -0
- package/dist/judges/internationalization.d.ts +2 -0
- package/dist/judges/internationalization.js +44 -0
- package/dist/judges/logging-privacy.d.ts +2 -0
- package/dist/judges/logging-privacy.js +46 -0
- package/dist/judges/logic-review.d.ts +2 -0
- package/dist/judges/logic-review.js +36 -0
- package/dist/judges/maintainability.d.ts +2 -0
- package/dist/judges/maintainability.js +46 -0
- package/dist/judges/model-fingerprint.d.ts +2 -0
- package/dist/judges/model-fingerprint.js +35 -0
- package/dist/judges/multi-turn-coherence.d.ts +2 -0
- package/dist/judges/multi-turn-coherence.js +39 -0
- package/dist/judges/observability.d.ts +2 -0
- package/dist/judges/observability.js +54 -0
- package/dist/judges/over-engineering.d.ts +2 -0
- package/dist/judges/over-engineering.js +50 -0
- package/dist/judges/performance.d.ts +2 -0
- package/dist/judges/performance.js +46 -0
- package/dist/judges/portability.d.ts +2 -0
- package/dist/judges/portability.js +46 -0
- package/dist/judges/rate-limiting.d.ts +2 -0
- package/dist/judges/rate-limiting.js +55 -0
- package/dist/judges/reliability.d.ts +2 -0
- package/dist/judges/reliability.js +57 -0
- package/dist/judges/scalability.d.ts +2 -0
- package/dist/judges/scalability.js +52 -0
- package/dist/judges/security.d.ts +2 -0
- package/dist/judges/security.js +64 -0
- package/dist/judges/software-practices.d.ts +2 -0
- package/dist/judges/software-practices.js +56 -0
- package/dist/judges/testing.d.ts +2 -0
- package/dist/judges/testing.js +54 -0
- package/dist/judges/ux.d.ts +2 -0
- package/dist/judges/ux.js +46 -0
- package/dist/language-patterns.d.ts +653 -0
- package/dist/language-patterns.js +851 -0
- package/dist/parallel.d.ts +52 -0
- package/dist/parallel.js +157 -0
- package/dist/patches/apply.d.ts +15 -0
- package/dist/patches/apply.js +37 -0
- package/dist/patches/index.d.ts +9 -0
- package/dist/patches/index.js +2544 -0
- package/dist/plugins.d.ts +59 -0
- package/dist/plugins.js +76 -0
- package/dist/presets.d.ts +35 -0
- package/dist/presets.js +406 -0
- package/dist/probabilistic/llm-response-validator.d.ts +26 -0
- package/dist/probabilistic/llm-response-validator.js +122 -0
- package/dist/reports/public-repo-report.d.ts +42 -0
- package/dist/reports/public-repo-report.js +579 -0
- package/dist/review-conversation.d.ts +87 -0
- package/dist/review-conversation.js +307 -0
- package/dist/sast-integration.d.ts +112 -0
- package/dist/sast-integration.js +215 -0
- package/dist/scoring.d.ts +36 -0
- package/dist/scoring.js +437 -0
- package/dist/security-ids.d.ts +23 -0
- package/dist/security-ids.js +239 -0
- package/dist/skill-loader.d.ts +33 -0
- package/dist/skill-loader.js +167 -0
- package/dist/tools/command-safety.d.ts +13 -0
- package/dist/tools/command-safety.js +95 -0
- package/dist/tools/deep-review.d.ts +38 -0
- package/dist/tools/deep-review.js +302 -0
- package/dist/tools/prompts.d.ts +27 -0
- package/dist/tools/prompts.js +122 -0
- package/dist/tools/register-evaluation.d.ts +6 -0
- package/dist/tools/register-evaluation.js +587 -0
- package/dist/tools/register-fix.d.ts +5 -0
- package/dist/tools/register-fix.js +175 -0
- package/dist/tools/register-resources.d.ts +6 -0
- package/dist/tools/register-resources.js +177 -0
- package/dist/tools/register-review.d.ts +6 -0
- package/dist/tools/register-review.js +564 -0
- package/dist/tools/register-scaffold.d.ts +2 -0
- package/dist/tools/register-scaffold.js +398 -0
- package/dist/tools/register-workflow.d.ts +6 -0
- package/dist/tools/register-workflow.js +1037 -0
- package/dist/tools/register-workspace.d.ts +2 -0
- package/dist/tools/register-workspace.js +214 -0
- package/dist/tools/register.d.ts +6 -0
- package/dist/tools/register.js +21 -0
- package/dist/tools/schemas.d.ts +25 -0
- package/dist/tools/schemas.js +41 -0
- package/dist/tools/validation.d.ts +13 -0
- package/dist/tools/validation.js +77 -0
- package/dist/types.d.ts +898 -0
- package/dist/types.js +1 -0
- package/package.json +54 -0
- package/skills/ai-code-review.skill.md +57 -0
- package/skills/release-gate.skill.md +27 -0
- package/skills/security-review.skill.md +32 -0
|
@@ -0,0 +1,1164 @@
|
|
|
1
|
+
// ─────────────────────────────────────────────────────────────────────────────
|
|
2
|
+
// Tree-sitter AST — Unified real syntax-tree analysis for all languages
|
|
3
|
+
// ─────────────────────────────────────────────────────────────────────────────
|
|
4
|
+
// Uses web-tree-sitter (WASM-based, zero native deps) to parse source code
|
|
5
|
+
// into a full syntax tree, then walks the tree to extract function metrics,
|
|
6
|
+
// dead code, deep nesting, type-safety issues, and imports.
|
|
7
|
+
//
|
|
8
|
+
// Supports: TypeScript, JavaScript, Python, Go, Rust, Java, C#, C++
|
|
9
|
+
//
|
|
10
|
+
// Graceful degradation: if tree-sitter WASM grammars aren't available at
|
|
11
|
+
// runtime, the caller can fall back to the structural parser.
|
|
12
|
+
// ─────────────────────────────────────────────────────────────────────────────
|
|
13
|
+
import { createRequire } from "node:module";
|
|
14
|
+
import { fileURLToPath } from "node:url";
|
|
15
|
+
import { dirname, join } from "node:path";
|
|
16
|
+
import { existsSync, mkdirSync, renameSync, unlinkSync, writeFileSync } from "node:fs";
|
|
17
|
+
import { homedir } from "node:os";
|
|
18
|
+
// Support both ESM (import.meta.url) and CJS (esbuild bundle) environments.
|
|
19
|
+
// When bundled by esbuild with --format=cjs, import.meta.url is undefined,
|
|
20
|
+
// so we fall back to __filename (which esbuild injects for CJS bundles).
|
|
21
|
+
const _importMetaUrl = typeof import.meta?.url === "string" ? import.meta.url : undefined;
|
|
22
|
+
const require = _importMetaUrl
|
|
23
|
+
? createRequire(_importMetaUrl)
|
|
24
|
+
: typeof globalThis.require === "function"
|
|
25
|
+
? globalThis.require
|
|
26
|
+
: createRequire(__filename ?? import.meta.url);
|
|
27
|
+
// ─── Lazy Initialization ────────────────────────────────────────────────────
|
|
28
|
+
let initPromise = null;
|
|
29
|
+
let parserModule = null;
|
|
30
|
+
// Grammar file name mapping
|
|
31
|
+
const GRAMMAR_FILES = {
|
|
32
|
+
typescript: "tree-sitter-typescript.wasm",
|
|
33
|
+
javascript: "tree-sitter-typescript.wasm", // TS grammar is a superset of JS
|
|
34
|
+
python: "tree-sitter-python.wasm",
|
|
35
|
+
go: "tree-sitter-go.wasm",
|
|
36
|
+
rust: "tree-sitter-rust.wasm",
|
|
37
|
+
java: "tree-sitter-java.wasm",
|
|
38
|
+
csharp: "tree-sitter-c_sharp.wasm",
|
|
39
|
+
cpp: "tree-sitter-cpp.wasm",
|
|
40
|
+
php: "tree-sitter-php.wasm",
|
|
41
|
+
ruby: "tree-sitter-ruby.wasm",
|
|
42
|
+
kotlin: "tree-sitter-kotlin.wasm",
|
|
43
|
+
swift: "tree-sitter-swift.wasm",
|
|
44
|
+
};
|
|
45
|
+
// Cached language instances
|
|
46
|
+
const languageCache = new Map();
|
|
47
|
+
// Resolve grammar directory relative to this module.
|
|
48
|
+
// In ESM: use import.meta.url; in CJS (esbuild bundle): use __filename.
|
|
49
|
+
const _moduleDir = _importMetaUrl
|
|
50
|
+
? dirname(fileURLToPath(_importMetaUrl))
|
|
51
|
+
: typeof __dirname === "string"
|
|
52
|
+
? __dirname
|
|
53
|
+
: dirname(__filename ?? "");
|
|
54
|
+
// In development: src/ast/ → ../../grammars/
|
|
55
|
+
// In dist: dist/ast/ → ../../grammars/
|
|
56
|
+
// In vscode bundle: out/ → ../grammars/ (but tree-sitter gracefully degrades)
|
|
57
|
+
const GRAMMAR_DIR = join(_moduleDir, "..", "..", "grammars");
|
|
58
|
+
const GRAMMAR_CACHE_DIR = join(homedir(), ".judges", "grammars");
|
|
59
|
+
const GRAMMAR_BASE_URL = process.env.JUDGES_GRAMMAR_BASE_URL?.replace(/\/+$/, "") ||
|
|
60
|
+
"https://raw.githubusercontent.com/KevinRabun/judges/main/grammars";
|
|
61
|
+
async function downloadGrammar(file, targetPath) {
|
|
62
|
+
if (typeof fetch !== "function")
|
|
63
|
+
return false;
|
|
64
|
+
const tempPath = `${targetPath}.tmp`;
|
|
65
|
+
try {
|
|
66
|
+
const response = await fetch(`${GRAMMAR_BASE_URL}/${file}`);
|
|
67
|
+
if (!response.ok)
|
|
68
|
+
return false;
|
|
69
|
+
const bytes = new Uint8Array(await response.arrayBuffer());
|
|
70
|
+
mkdirSync(GRAMMAR_CACHE_DIR, { recursive: true });
|
|
71
|
+
writeFileSync(tempPath, bytes);
|
|
72
|
+
renameSync(tempPath, targetPath);
|
|
73
|
+
return true;
|
|
74
|
+
}
|
|
75
|
+
catch {
|
|
76
|
+
try {
|
|
77
|
+
unlinkSync(tempPath);
|
|
78
|
+
}
|
|
79
|
+
catch {
|
|
80
|
+
// ignore cleanup errors
|
|
81
|
+
}
|
|
82
|
+
return false;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
async function ensureGrammarPath(file) {
|
|
86
|
+
const bundledPath = join(GRAMMAR_DIR, file);
|
|
87
|
+
if (existsSync(bundledPath))
|
|
88
|
+
return bundledPath;
|
|
89
|
+
const cachedPath = join(GRAMMAR_CACHE_DIR, file);
|
|
90
|
+
if (existsSync(cachedPath))
|
|
91
|
+
return cachedPath;
|
|
92
|
+
const downloaded = await downloadGrammar(file, cachedPath);
|
|
93
|
+
return downloaded ? cachedPath : null;
|
|
94
|
+
}
|
|
95
|
+
async function ensureInit() {
|
|
96
|
+
if (initPromise)
|
|
97
|
+
return initPromise;
|
|
98
|
+
initPromise = (async () => {
|
|
99
|
+
try {
|
|
100
|
+
const mod = require("web-tree-sitter");
|
|
101
|
+
await mod.Parser.init();
|
|
102
|
+
parserModule = mod;
|
|
103
|
+
return true;
|
|
104
|
+
}
|
|
105
|
+
catch {
|
|
106
|
+
return false;
|
|
107
|
+
}
|
|
108
|
+
})();
|
|
109
|
+
return initPromise;
|
|
110
|
+
}
|
|
111
|
+
async function getLanguage(lang) {
|
|
112
|
+
if (languageCache.has(lang))
|
|
113
|
+
return languageCache.get(lang);
|
|
114
|
+
const file = GRAMMAR_FILES[lang];
|
|
115
|
+
if (!file)
|
|
116
|
+
return null;
|
|
117
|
+
try {
|
|
118
|
+
const grammarPath = await ensureGrammarPath(file);
|
|
119
|
+
if (!grammarPath)
|
|
120
|
+
return null;
|
|
121
|
+
const grammar = await parserModule.Language.load(grammarPath);
|
|
122
|
+
languageCache.set(lang, grammar);
|
|
123
|
+
return grammar;
|
|
124
|
+
}
|
|
125
|
+
catch {
|
|
126
|
+
return null;
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
// ─── Public API ──────────────────────────────────────────────────────────────
|
|
130
|
+
/**
|
|
131
|
+
* Check whether tree-sitter analysis is available for a given language.
|
|
132
|
+
* Must be called (and awaited) before analyzeWithTreeSitter.
|
|
133
|
+
*/
|
|
134
|
+
export async function isTreeSitterAvailable(lang) {
|
|
135
|
+
const ready = await ensureInit();
|
|
136
|
+
if (!ready)
|
|
137
|
+
return false;
|
|
138
|
+
const grammar = await getLanguage(lang);
|
|
139
|
+
return grammar !== null;
|
|
140
|
+
}
|
|
141
|
+
/**
|
|
142
|
+
* Synchronous readiness check — returns true only if tree-sitter's WASM
|
|
143
|
+
* runtime AND the grammar for `lang` have already been loaded into memory.
|
|
144
|
+
* This is safe to call from synchronous code paths; if the async init
|
|
145
|
+
* hasn't finished yet, it simply returns false and the caller falls back
|
|
146
|
+
* to the structural parser.
|
|
147
|
+
*/
|
|
148
|
+
export function isTreeSitterReadySync(lang) {
|
|
149
|
+
return parserModule !== null && languageCache.has(lang);
|
|
150
|
+
}
|
|
151
|
+
/**
|
|
152
|
+
* Synchronous tree-sitter analysis. Can ONLY be called when
|
|
153
|
+
* isTreeSitterReadySync(lang) returns true (i.e. parser module and grammar
|
|
154
|
+
* are already loaded). parser.parse() is synchronous in web-tree-sitter
|
|
155
|
+
* once the WASM runtime and grammar are in memory.
|
|
156
|
+
*
|
|
157
|
+
* Returns the same CodeStructure interface as analyzeWithTreeSitter.
|
|
158
|
+
* Throws if preconditions are not met.
|
|
159
|
+
*/
|
|
160
|
+
export function analyzeWithTreeSitterSync(code, language) {
|
|
161
|
+
if (!parserModule)
|
|
162
|
+
throw new Error("Tree-sitter not initialized");
|
|
163
|
+
const grammar = languageCache.get(language);
|
|
164
|
+
if (!grammar)
|
|
165
|
+
throw new Error(`Tree-sitter grammar for ${language} not loaded`);
|
|
166
|
+
return parseAndAnalyze(code, language, grammar);
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Analyse source code using tree-sitter's real syntax tree.
|
|
170
|
+
* Returns the same CodeStructure interface as the TypeScript and
|
|
171
|
+
* structural parsers — but with much higher precision for non-JS/TS languages.
|
|
172
|
+
*
|
|
173
|
+
* IMPORTANT: Call isTreeSitterAvailable(lang) first. If it returns false,
|
|
174
|
+
* fall back to analyzeStructurally().
|
|
175
|
+
*/
|
|
176
|
+
export async function analyzeWithTreeSitter(code, language) {
|
|
177
|
+
if (!parserModule)
|
|
178
|
+
throw new Error("Tree-sitter not initialized");
|
|
179
|
+
const grammar = await getLanguage(language);
|
|
180
|
+
if (!grammar)
|
|
181
|
+
throw new Error(`Tree-sitter grammar for ${language} not available`);
|
|
182
|
+
return parseAndAnalyze(code, language, grammar);
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Shared parsing + analysis logic used by both sync and async entry points.
|
|
186
|
+
*/
|
|
187
|
+
function parseAndAnalyze(code, language, grammar) {
|
|
188
|
+
const parser = new parserModule.Parser();
|
|
189
|
+
parser.setLanguage(grammar);
|
|
190
|
+
const tree = parser.parse(code);
|
|
191
|
+
const root = tree.rootNode;
|
|
192
|
+
const lines = code.split("\n");
|
|
193
|
+
// Extract all analysis data from the tree
|
|
194
|
+
const functions = extractFunctions(root, language);
|
|
195
|
+
const deadCodeLines = detectDeadCode(root, language);
|
|
196
|
+
const deepNestLines = detectDeepNesting(root, language);
|
|
197
|
+
const typeAnyLines = detectWeakTypes(root, language);
|
|
198
|
+
const imports = extractImports(root, language);
|
|
199
|
+
const classes = extractClasses(root, language);
|
|
200
|
+
// Compute file-level metrics
|
|
201
|
+
const fileCyclomaticComplexity = functions.reduce((sum, f) => sum + f.cyclomaticComplexity, 0) || 1;
|
|
202
|
+
const maxNestingDepth = functions.reduce((max, f) => Math.max(max, f.maxNestingDepth), 0);
|
|
203
|
+
return {
|
|
204
|
+
language,
|
|
205
|
+
totalLines: lines.length,
|
|
206
|
+
functions,
|
|
207
|
+
fileCyclomaticComplexity,
|
|
208
|
+
maxNestingDepth,
|
|
209
|
+
deadCodeLines,
|
|
210
|
+
deepNestLines,
|
|
211
|
+
typeAnyLines,
|
|
212
|
+
imports,
|
|
213
|
+
classes: classes.length > 0 ? classes : undefined,
|
|
214
|
+
};
|
|
215
|
+
}
|
|
216
|
+
// ─── Function Extraction ────────────────────────────────────────────────────
|
|
217
|
+
/** Node types that represent function/method definitions per language */
|
|
218
|
+
const FUNCTION_NODE_TYPES = {
|
|
219
|
+
typescript: [
|
|
220
|
+
"function_declaration",
|
|
221
|
+
"method_definition",
|
|
222
|
+
"arrow_function",
|
|
223
|
+
"function_expression",
|
|
224
|
+
"generator_function_declaration",
|
|
225
|
+
"generator_function",
|
|
226
|
+
],
|
|
227
|
+
javascript: [
|
|
228
|
+
"function_declaration",
|
|
229
|
+
"method_definition",
|
|
230
|
+
"arrow_function",
|
|
231
|
+
"function_expression",
|
|
232
|
+
"generator_function_declaration",
|
|
233
|
+
"generator_function",
|
|
234
|
+
],
|
|
235
|
+
python: ["function_definition"],
|
|
236
|
+
go: ["function_declaration", "method_declaration"],
|
|
237
|
+
rust: ["function_item"],
|
|
238
|
+
java: ["method_declaration", "constructor_declaration"],
|
|
239
|
+
csharp: ["method_declaration", "constructor_declaration", "local_function_statement"],
|
|
240
|
+
cpp: ["function_definition"],
|
|
241
|
+
php: ["function_definition", "method_declaration"],
|
|
242
|
+
ruby: ["method", "singleton_method"],
|
|
243
|
+
kotlin: ["function_declaration"],
|
|
244
|
+
swift: ["function_declaration", "init_declaration"],
|
|
245
|
+
};
|
|
246
|
+
function extractFunctions(root, language) {
|
|
247
|
+
const funcTypes = FUNCTION_NODE_TYPES[language] || [];
|
|
248
|
+
const functions = [];
|
|
249
|
+
const classRanges = extractClassRanges(root, language);
|
|
250
|
+
walkTree(root, (node) => {
|
|
251
|
+
if (funcTypes.includes(node.type)) {
|
|
252
|
+
const info = analyzeFunctionNode(node, language, classRanges);
|
|
253
|
+
if (info)
|
|
254
|
+
functions.push(info);
|
|
255
|
+
}
|
|
256
|
+
});
|
|
257
|
+
return functions;
|
|
258
|
+
}
|
|
259
|
+
function extractClassRanges(root, language) {
|
|
260
|
+
const classTypes = CLASS_NODE_TYPES[language] || [];
|
|
261
|
+
const ranges = [];
|
|
262
|
+
walkTree(root, (node) => {
|
|
263
|
+
if (classTypes.includes(node.type)) {
|
|
264
|
+
const nameNode = node.childForFieldName("name");
|
|
265
|
+
if (nameNode) {
|
|
266
|
+
ranges.push({
|
|
267
|
+
name: nameNode.text,
|
|
268
|
+
startLine: node.startPosition.row + 1,
|
|
269
|
+
endLine: node.endPosition.row + 1,
|
|
270
|
+
});
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
});
|
|
274
|
+
return ranges;
|
|
275
|
+
}
|
|
276
|
+
function analyzeFunctionNode(node, language, classRanges) {
|
|
277
|
+
// Get function name
|
|
278
|
+
const nameNode = node.childForFieldName("name");
|
|
279
|
+
let name = nameNode?.text || "<anonymous>";
|
|
280
|
+
// C++: name is inside the declarator chain
|
|
281
|
+
// function_definition → declarator (function_declarator) → declarator (identifier / qualified_identifier)
|
|
282
|
+
if (language === "cpp" && name === "<anonymous>") {
|
|
283
|
+
const decl = node.childForFieldName("declarator");
|
|
284
|
+
if (decl) {
|
|
285
|
+
const nameDecl = decl.childForFieldName("declarator");
|
|
286
|
+
if (nameDecl) {
|
|
287
|
+
name = nameDecl.text;
|
|
288
|
+
}
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
// TypeScript/JavaScript: arrow functions and function expressions get their
|
|
292
|
+
// name from the parent variable_declarator or property assignment
|
|
293
|
+
if ((language === "typescript" || language === "javascript") && name === "<anonymous>" && node.parent) {
|
|
294
|
+
if (node.parent.type === "variable_declarator") {
|
|
295
|
+
const nameChild = node.parent.childForFieldName("name");
|
|
296
|
+
if (nameChild)
|
|
297
|
+
name = nameChild.text;
|
|
298
|
+
}
|
|
299
|
+
else if (node.parent.type === "pair" || node.parent.type === "property_assignment") {
|
|
300
|
+
const key = node.parent.childForFieldName("key");
|
|
301
|
+
if (key)
|
|
302
|
+
name = key.text;
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
// For Go method_declaration, extract receiver type
|
|
306
|
+
if (language === "go" && node.type === "method_declaration") {
|
|
307
|
+
const receiver = node.childForFieldName("receiver");
|
|
308
|
+
if (receiver) {
|
|
309
|
+
// Extract the type from the receiver parameter list
|
|
310
|
+
const typeNode = findFirstByType(receiver, "type_identifier");
|
|
311
|
+
if (typeNode) {
|
|
312
|
+
name = `${typeNode.text}.${name}`;
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
// Check if function is inside a class
|
|
317
|
+
const startLine = node.startPosition.row + 1;
|
|
318
|
+
const endLine = node.endPosition.row + 1;
|
|
319
|
+
const containingClass = classRanges.find((c) => startLine >= c.startLine && endLine <= c.endLine);
|
|
320
|
+
if (containingClass && language !== "go") {
|
|
321
|
+
name = `${containingClass.name}.${name}`;
|
|
322
|
+
}
|
|
323
|
+
// Count parameters
|
|
324
|
+
const paramCount = countParameters(node, language);
|
|
325
|
+
// Compute cyclomatic complexity
|
|
326
|
+
const complexity = computeCyclomaticComplexity(node, language);
|
|
327
|
+
// Compute max nesting depth
|
|
328
|
+
const maxNesting = computeMaxNesting(node, language, 0);
|
|
329
|
+
// Check for decorators (Python, Java, C#)
|
|
330
|
+
const decorators = extractDecorators(node, language);
|
|
331
|
+
// Check for async
|
|
332
|
+
const isAsync = checkIsAsync(node, language);
|
|
333
|
+
const info = {
|
|
334
|
+
name,
|
|
335
|
+
startLine,
|
|
336
|
+
endLine,
|
|
337
|
+
lineCount: endLine - startLine + 1,
|
|
338
|
+
parameterCount: paramCount,
|
|
339
|
+
cyclomaticComplexity: complexity,
|
|
340
|
+
maxNestingDepth: maxNesting,
|
|
341
|
+
};
|
|
342
|
+
if (decorators.length > 0)
|
|
343
|
+
info.decorators = decorators;
|
|
344
|
+
if (containingClass)
|
|
345
|
+
info.className = containingClass.name;
|
|
346
|
+
if (isAsync)
|
|
347
|
+
info.isAsync = true;
|
|
348
|
+
return info;
|
|
349
|
+
}
|
|
350
|
+
// ─── Parameter Counting ─────────────────────────────────────────────────────
|
|
351
|
+
function countParameters(funcNode, language) {
|
|
352
|
+
let paramsNode;
|
|
353
|
+
switch (language) {
|
|
354
|
+
case "typescript":
|
|
355
|
+
case "javascript":
|
|
356
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
357
|
+
if (!paramsNode)
|
|
358
|
+
return 0;
|
|
359
|
+
return paramsNode.namedChildren.filter((c) => c.type === "required_parameter" || c.type === "optional_parameter" || c.type === "rest_parameter").length;
|
|
360
|
+
case "python":
|
|
361
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
362
|
+
if (!paramsNode)
|
|
363
|
+
return 0;
|
|
364
|
+
// Count identifier children, excluding 'self' and 'cls'
|
|
365
|
+
return paramsNode.namedChildren.filter((c) => {
|
|
366
|
+
if (c.type === "identifier" && (c.text === "self" || c.text === "cls"))
|
|
367
|
+
return false;
|
|
368
|
+
// Also handle typed_parameter, typed_default_parameter, etc.
|
|
369
|
+
if (c.type === "identifier" ||
|
|
370
|
+
c.type === "default_parameter" ||
|
|
371
|
+
c.type === "typed_parameter" ||
|
|
372
|
+
c.type === "typed_default_parameter" ||
|
|
373
|
+
c.type === "list_splat_pattern" ||
|
|
374
|
+
c.type === "dictionary_splat_pattern") {
|
|
375
|
+
// For typed_parameter, check if it's self/cls
|
|
376
|
+
if (c.type === "typed_parameter") {
|
|
377
|
+
const nameChild = c.namedChildren[0];
|
|
378
|
+
if (nameChild && (nameChild.text === "self" || nameChild.text === "cls"))
|
|
379
|
+
return false;
|
|
380
|
+
}
|
|
381
|
+
return true;
|
|
382
|
+
}
|
|
383
|
+
return false;
|
|
384
|
+
}).length;
|
|
385
|
+
case "go":
|
|
386
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
387
|
+
if (!paramsNode)
|
|
388
|
+
return 0;
|
|
389
|
+
return paramsNode.namedChildren.filter((c) => c.type === "parameter_declaration").length;
|
|
390
|
+
case "rust":
|
|
391
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
392
|
+
if (!paramsNode)
|
|
393
|
+
return 0;
|
|
394
|
+
return paramsNode.namedChildren.filter((c) => c.type === "parameter" || c.type === "self_parameter").length;
|
|
395
|
+
case "java":
|
|
396
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
397
|
+
if (!paramsNode)
|
|
398
|
+
return 0;
|
|
399
|
+
return paramsNode.namedChildren.filter((c) => c.type === "formal_parameter" || c.type === "spread_parameter")
|
|
400
|
+
.length;
|
|
401
|
+
case "csharp":
|
|
402
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
403
|
+
if (!paramsNode)
|
|
404
|
+
return 0;
|
|
405
|
+
return paramsNode.namedChildren.filter((c) => c.type === "parameter").length;
|
|
406
|
+
case "cpp": {
|
|
407
|
+
// C++: parameters sit inside function_definition → declarator (function_declarator) → parameters
|
|
408
|
+
const declarator = funcNode.childForFieldName("declarator");
|
|
409
|
+
if (!declarator)
|
|
410
|
+
return 0;
|
|
411
|
+
paramsNode = declarator.childForFieldName("parameters");
|
|
412
|
+
if (!paramsNode)
|
|
413
|
+
return 0;
|
|
414
|
+
return paramsNode.namedChildren.filter((c) => c.type === "parameter_declaration" || c.type === "variadic_parameter_declaration").length;
|
|
415
|
+
}
|
|
416
|
+
case "php":
|
|
417
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
418
|
+
if (!paramsNode)
|
|
419
|
+
return 0;
|
|
420
|
+
return paramsNode.namedChildren.filter((c) => c.type === "simple_parameter" || c.type === "variadic_parameter")
|
|
421
|
+
.length;
|
|
422
|
+
case "ruby":
|
|
423
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
424
|
+
if (!paramsNode)
|
|
425
|
+
return 0;
|
|
426
|
+
return paramsNode.namedChildren.length;
|
|
427
|
+
case "kotlin":
|
|
428
|
+
paramsNode = funcNode.childForFieldName("parameters") ?? funcNode.childForFieldName("value_parameters");
|
|
429
|
+
if (!paramsNode)
|
|
430
|
+
return 0;
|
|
431
|
+
return paramsNode.namedChildren.filter((c) => c.type === "parameter").length;
|
|
432
|
+
case "swift":
|
|
433
|
+
paramsNode = funcNode.childForFieldName("parameters");
|
|
434
|
+
if (!paramsNode)
|
|
435
|
+
return 0;
|
|
436
|
+
return paramsNode.namedChildren.filter((c) => c.type === "parameter").length;
|
|
437
|
+
default:
|
|
438
|
+
return 0;
|
|
439
|
+
}
|
|
440
|
+
}
|
|
441
|
+
// ─── Cyclomatic Complexity ──────────────────────────────────────────────────
|
|
442
|
+
// CC = 1 + number of decision points
|
|
443
|
+
const DECISION_NODE_TYPES = {
|
|
444
|
+
typescript: new Set([
|
|
445
|
+
"if_statement",
|
|
446
|
+
"for_statement",
|
|
447
|
+
"for_in_statement",
|
|
448
|
+
"while_statement",
|
|
449
|
+
"do_statement",
|
|
450
|
+
"switch_case",
|
|
451
|
+
"catch_clause",
|
|
452
|
+
"ternary_expression",
|
|
453
|
+
]),
|
|
454
|
+
javascript: new Set([
|
|
455
|
+
"if_statement",
|
|
456
|
+
"for_statement",
|
|
457
|
+
"for_in_statement",
|
|
458
|
+
"while_statement",
|
|
459
|
+
"do_statement",
|
|
460
|
+
"switch_case",
|
|
461
|
+
"catch_clause",
|
|
462
|
+
"ternary_expression",
|
|
463
|
+
]),
|
|
464
|
+
python: new Set([
|
|
465
|
+
"if_statement",
|
|
466
|
+
"elif_clause",
|
|
467
|
+
"for_statement",
|
|
468
|
+
"while_statement",
|
|
469
|
+
"except_clause",
|
|
470
|
+
"conditional_expression",
|
|
471
|
+
"for_in_clause",
|
|
472
|
+
// Boolean operators — each 'and'/'or' is a decision point
|
|
473
|
+
"boolean_operator",
|
|
474
|
+
]),
|
|
475
|
+
go: new Set(["if_statement", "for_statement", "expression_case", "default_case", "type_case", "communication_case"]),
|
|
476
|
+
rust: new Set(["if_expression", "for_expression", "while_expression", "loop_expression", "match_arm"]),
|
|
477
|
+
java: new Set([
|
|
478
|
+
"if_statement",
|
|
479
|
+
"for_statement",
|
|
480
|
+
"enhanced_for_statement",
|
|
481
|
+
"while_statement",
|
|
482
|
+
"do_statement",
|
|
483
|
+
"catch_clause",
|
|
484
|
+
"switch_block_statement_group",
|
|
485
|
+
"ternary_expression",
|
|
486
|
+
]),
|
|
487
|
+
csharp: new Set([
|
|
488
|
+
"if_statement",
|
|
489
|
+
"for_statement",
|
|
490
|
+
"for_each_statement",
|
|
491
|
+
"while_statement",
|
|
492
|
+
"do_statement",
|
|
493
|
+
"catch_clause",
|
|
494
|
+
"switch_section",
|
|
495
|
+
"conditional_expression",
|
|
496
|
+
]),
|
|
497
|
+
cpp: new Set([
|
|
498
|
+
"if_statement",
|
|
499
|
+
"for_statement",
|
|
500
|
+
"for_range_loop",
|
|
501
|
+
"while_statement",
|
|
502
|
+
"do_statement",
|
|
503
|
+
"case_statement",
|
|
504
|
+
"catch_clause",
|
|
505
|
+
"conditional_expression",
|
|
506
|
+
]),
|
|
507
|
+
php: new Set([
|
|
508
|
+
"if_statement",
|
|
509
|
+
"for_statement",
|
|
510
|
+
"foreach_statement",
|
|
511
|
+
"while_statement",
|
|
512
|
+
"do_statement",
|
|
513
|
+
"catch_clause",
|
|
514
|
+
"switch_case",
|
|
515
|
+
"conditional_expression",
|
|
516
|
+
]),
|
|
517
|
+
ruby: new Set(["if", "elsif", "unless", "for", "while", "until", "case", "when", "rescue", "conditional"]),
|
|
518
|
+
kotlin: new Set([
|
|
519
|
+
"if_expression",
|
|
520
|
+
"for_statement",
|
|
521
|
+
"while_statement",
|
|
522
|
+
"do_while_statement",
|
|
523
|
+
"catch_block",
|
|
524
|
+
"when_entry",
|
|
525
|
+
]),
|
|
526
|
+
swift: new Set([
|
|
527
|
+
"if_statement",
|
|
528
|
+
"for_in_statement",
|
|
529
|
+
"while_statement",
|
|
530
|
+
"repeat_while_statement",
|
|
531
|
+
"catch_clause",
|
|
532
|
+
"switch_case",
|
|
533
|
+
"ternary_expression",
|
|
534
|
+
]),
|
|
535
|
+
};
|
|
536
|
+
function computeCyclomaticComplexity(funcNode, language) {
|
|
537
|
+
let complexity = 1; // base path
|
|
538
|
+
const decisionTypes = DECISION_NODE_TYPES[language] || new Set();
|
|
539
|
+
walkTree(funcNode, (node) => {
|
|
540
|
+
if (decisionTypes.has(node.type)) {
|
|
541
|
+
complexity++;
|
|
542
|
+
}
|
|
543
|
+
// Check binary expressions for logical operators (&&, ||)
|
|
544
|
+
if (node.type === "binary_expression") {
|
|
545
|
+
const op = node.children.find((c) => c.type === "&&" || c.type === "||" || c.text === "&&" || c.text === "||");
|
|
546
|
+
if (op)
|
|
547
|
+
complexity++;
|
|
548
|
+
}
|
|
549
|
+
});
|
|
550
|
+
return complexity;
|
|
551
|
+
}
|
|
552
|
+
// ─── Nesting Depth ──────────────────────────────────────────────────────────
|
|
553
|
+
const NESTING_NODE_TYPES = {
|
|
554
|
+
typescript: new Set([
|
|
555
|
+
"if_statement",
|
|
556
|
+
"for_statement",
|
|
557
|
+
"for_in_statement",
|
|
558
|
+
"while_statement",
|
|
559
|
+
"do_statement",
|
|
560
|
+
"switch_statement",
|
|
561
|
+
"try_statement",
|
|
562
|
+
"arrow_function",
|
|
563
|
+
"function_expression",
|
|
564
|
+
]),
|
|
565
|
+
javascript: new Set([
|
|
566
|
+
"if_statement",
|
|
567
|
+
"for_statement",
|
|
568
|
+
"for_in_statement",
|
|
569
|
+
"while_statement",
|
|
570
|
+
"do_statement",
|
|
571
|
+
"switch_statement",
|
|
572
|
+
"try_statement",
|
|
573
|
+
"arrow_function",
|
|
574
|
+
"function_expression",
|
|
575
|
+
]),
|
|
576
|
+
python: new Set([
|
|
577
|
+
"if_statement",
|
|
578
|
+
"for_statement",
|
|
579
|
+
"while_statement",
|
|
580
|
+
"with_statement",
|
|
581
|
+
"try_statement",
|
|
582
|
+
"except_clause",
|
|
583
|
+
"for_in_clause",
|
|
584
|
+
"function_definition",
|
|
585
|
+
"class_definition",
|
|
586
|
+
]),
|
|
587
|
+
go: new Set([
|
|
588
|
+
"if_statement",
|
|
589
|
+
"for_statement",
|
|
590
|
+
"select_statement",
|
|
591
|
+
"type_switch_statement",
|
|
592
|
+
"expression_switch_statement",
|
|
593
|
+
"func_literal",
|
|
594
|
+
]),
|
|
595
|
+
rust: new Set([
|
|
596
|
+
"if_expression",
|
|
597
|
+
"for_expression",
|
|
598
|
+
"while_expression",
|
|
599
|
+
"loop_expression",
|
|
600
|
+
"match_expression",
|
|
601
|
+
"closure_expression",
|
|
602
|
+
]),
|
|
603
|
+
java: new Set([
|
|
604
|
+
"if_statement",
|
|
605
|
+
"for_statement",
|
|
606
|
+
"enhanced_for_statement",
|
|
607
|
+
"while_statement",
|
|
608
|
+
"do_statement",
|
|
609
|
+
"try_statement",
|
|
610
|
+
"switch_expression",
|
|
611
|
+
"lambda_expression",
|
|
612
|
+
]),
|
|
613
|
+
csharp: new Set([
|
|
614
|
+
"if_statement",
|
|
615
|
+
"for_statement",
|
|
616
|
+
"for_each_statement",
|
|
617
|
+
"while_statement",
|
|
618
|
+
"do_statement",
|
|
619
|
+
"try_statement",
|
|
620
|
+
"switch_statement",
|
|
621
|
+
"lambda_expression",
|
|
622
|
+
]),
|
|
623
|
+
cpp: new Set([
|
|
624
|
+
"if_statement",
|
|
625
|
+
"for_statement",
|
|
626
|
+
"for_range_loop",
|
|
627
|
+
"while_statement",
|
|
628
|
+
"do_statement",
|
|
629
|
+
"try_statement",
|
|
630
|
+
"switch_statement",
|
|
631
|
+
"lambda_expression",
|
|
632
|
+
]),
|
|
633
|
+
php: new Set([
|
|
634
|
+
"if_statement",
|
|
635
|
+
"for_statement",
|
|
636
|
+
"foreach_statement",
|
|
637
|
+
"while_statement",
|
|
638
|
+
"do_statement",
|
|
639
|
+
"try_statement",
|
|
640
|
+
"switch_statement",
|
|
641
|
+
]),
|
|
642
|
+
ruby: new Set(["if", "unless", "for", "while", "until", "begin", "case", "block", "do_block"]),
|
|
643
|
+
kotlin: new Set([
|
|
644
|
+
"if_expression",
|
|
645
|
+
"for_statement",
|
|
646
|
+
"while_statement",
|
|
647
|
+
"do_while_statement",
|
|
648
|
+
"try_expression",
|
|
649
|
+
"when_expression",
|
|
650
|
+
"lambda_literal",
|
|
651
|
+
]),
|
|
652
|
+
swift: new Set([
|
|
653
|
+
"if_statement",
|
|
654
|
+
"for_in_statement",
|
|
655
|
+
"while_statement",
|
|
656
|
+
"repeat_while_statement",
|
|
657
|
+
"do_statement",
|
|
658
|
+
"switch_statement",
|
|
659
|
+
"closure_expression",
|
|
660
|
+
]),
|
|
661
|
+
};
|
|
662
|
+
function computeMaxNesting(node, language, currentDepth) {
|
|
663
|
+
const nestingTypes = NESTING_NODE_TYPES[language] || new Set();
|
|
664
|
+
let maxDepth = currentDepth;
|
|
665
|
+
for (const child of node.namedChildren) {
|
|
666
|
+
let childDepth = currentDepth;
|
|
667
|
+
if (nestingTypes.has(child.type)) {
|
|
668
|
+
childDepth = currentDepth + 1;
|
|
669
|
+
if (childDepth > maxDepth)
|
|
670
|
+
maxDepth = childDepth;
|
|
671
|
+
}
|
|
672
|
+
const subMax = computeMaxNesting(child, language, childDepth);
|
|
673
|
+
if (subMax > maxDepth)
|
|
674
|
+
maxDepth = subMax;
|
|
675
|
+
}
|
|
676
|
+
return maxDepth;
|
|
677
|
+
}
|
|
678
|
+
// ─── Dead Code Detection ────────────────────────────────────────────────────
|
|
679
|
+
/** Node types that represent terminal statements (control flow never continues past them) */
|
|
680
|
+
const TERMINAL_TYPES = {
|
|
681
|
+
typescript: new Set(["return_statement", "throw_statement", "break_statement", "continue_statement"]),
|
|
682
|
+
javascript: new Set(["return_statement", "throw_statement", "break_statement", "continue_statement"]),
|
|
683
|
+
python: new Set(["return_statement", "raise_statement", "break_statement", "continue_statement"]),
|
|
684
|
+
go: new Set(["return_statement", "break_statement", "continue_statement"]),
|
|
685
|
+
rust: new Set(["return_expression", "break_expression", "continue_expression"]),
|
|
686
|
+
java: new Set(["return_statement", "throw_statement", "break_statement", "continue_statement"]),
|
|
687
|
+
csharp: new Set(["return_statement", "throw_statement", "break_statement", "continue_statement"]),
|
|
688
|
+
cpp: new Set(["return_statement", "throw_statement", "break_statement", "continue_statement"]),
|
|
689
|
+
php: new Set(["return_statement", "throw_expression", "break_statement", "continue_statement"]),
|
|
690
|
+
ruby: new Set(["return", "raise", "break", "next"]),
|
|
691
|
+
kotlin: new Set(["return_expression", "throw_expression", "break_expression", "continue_expression"]),
|
|
692
|
+
swift: new Set(["return_statement", "throw_statement", "break_statement", "continue_statement"]),
|
|
693
|
+
};
|
|
694
|
+
/** Node types that represent blocks containing sequential statements */
|
|
695
|
+
const BLOCK_TYPES = {
|
|
696
|
+
typescript: new Set(["statement_block"]),
|
|
697
|
+
javascript: new Set(["statement_block"]),
|
|
698
|
+
python: new Set(["block"]),
|
|
699
|
+
go: new Set(["block"]),
|
|
700
|
+
rust: new Set(["block"]),
|
|
701
|
+
java: new Set(["block"]),
|
|
702
|
+
csharp: new Set(["block"]),
|
|
703
|
+
cpp: new Set(["compound_statement"]),
|
|
704
|
+
php: new Set(["compound_statement"]),
|
|
705
|
+
ruby: new Set(["body_statement", "do"]),
|
|
706
|
+
kotlin: new Set(["function_body", "control_structure_body"]),
|
|
707
|
+
swift: new Set(["code_block"]),
|
|
708
|
+
};
|
|
709
|
+
function detectDeadCode(root, language) {
|
|
710
|
+
const deadLines = [];
|
|
711
|
+
const terminalTypes = TERMINAL_TYPES[language] || new Set();
|
|
712
|
+
const blockTypes = BLOCK_TYPES[language] || new Set();
|
|
713
|
+
walkTree(root, (node) => {
|
|
714
|
+
if (!blockTypes.has(node.type))
|
|
715
|
+
return;
|
|
716
|
+
const children = node.namedChildren;
|
|
717
|
+
let foundTerminal = false;
|
|
718
|
+
for (const child of children) {
|
|
719
|
+
if (foundTerminal) {
|
|
720
|
+
// Everything after a terminal statement is dead code
|
|
721
|
+
for (let line = child.startPosition.row + 1; line <= child.endPosition.row + 1; line++) {
|
|
722
|
+
deadLines.push(line);
|
|
723
|
+
}
|
|
724
|
+
}
|
|
725
|
+
// Check if this child IS a terminal or CONTAINS a bare terminal
|
|
726
|
+
// (only direct children, not nested in sub-blocks)
|
|
727
|
+
if (terminalTypes.has(child.type)) {
|
|
728
|
+
foundTerminal = true;
|
|
729
|
+
}
|
|
730
|
+
// For expression_statement wrapping a return (Rust)
|
|
731
|
+
if (child.type === "expression_statement") {
|
|
732
|
+
const expr = child.namedChildren[0];
|
|
733
|
+
if (expr && terminalTypes.has(expr.type)) {
|
|
734
|
+
foundTerminal = true;
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
}
|
|
738
|
+
});
|
|
739
|
+
return [...new Set(deadLines)].sort((a, b) => a - b);
|
|
740
|
+
}
|
|
741
|
+
// ─── Deep Nesting Detection ─────────────────────────────────────────────────
|
|
742
|
+
function detectDeepNesting(root, language) {
|
|
743
|
+
const deepLines = [];
|
|
744
|
+
const nestingTypes = NESTING_NODE_TYPES[language] || new Set();
|
|
745
|
+
const threshold = 4; // Depth > 4 is "deep"
|
|
746
|
+
function walk(node, depth) {
|
|
747
|
+
for (const child of node.namedChildren) {
|
|
748
|
+
let childDepth = depth;
|
|
749
|
+
if (nestingTypes.has(child.type)) {
|
|
750
|
+
childDepth = depth + 1;
|
|
751
|
+
}
|
|
752
|
+
if (childDepth > threshold) {
|
|
753
|
+
// Mark all lines in this deeply-nested node
|
|
754
|
+
for (let line = child.startPosition.row + 1; line <= child.endPosition.row + 1; line++) {
|
|
755
|
+
deepLines.push(line);
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
walk(child, childDepth);
|
|
759
|
+
}
|
|
760
|
+
}
|
|
761
|
+
walk(root, 0);
|
|
762
|
+
return [...new Set(deepLines)].sort((a, b) => a - b);
|
|
763
|
+
}
|
|
764
|
+
// ─── Weak Type Detection ────────────────────────────────────────────────────
|
|
765
|
+
const WEAK_TYPE_PATTERNS = {
|
|
766
|
+
typescript: (node) => {
|
|
767
|
+
// 'any' keyword in type annotations
|
|
768
|
+
if (node.type === "predefined_type" && node.text === "any")
|
|
769
|
+
return true;
|
|
770
|
+
if (node.type === "type_identifier" && node.text === "any")
|
|
771
|
+
return true;
|
|
772
|
+
return false;
|
|
773
|
+
},
|
|
774
|
+
javascript: () => false, // JS has no static type annotations
|
|
775
|
+
python: (node) => {
|
|
776
|
+
// typing.Any or just Any in type annotations
|
|
777
|
+
if (node.type === "type" || node.type === "annotation") {
|
|
778
|
+
return node.text.includes("Any");
|
|
779
|
+
}
|
|
780
|
+
return false;
|
|
781
|
+
},
|
|
782
|
+
go: (node) => {
|
|
783
|
+
// Go's interface{} and `any` are idiomatic, not weak types.
|
|
784
|
+
// Only flag unsafe pointer operations which genuinely bypass the type system.
|
|
785
|
+
if (node.type === "call_expression" && node.text.includes("unsafe.Pointer"))
|
|
786
|
+
return true;
|
|
787
|
+
return false;
|
|
788
|
+
},
|
|
789
|
+
rust: (node) => {
|
|
790
|
+
// unsafe blocks and unsafe function declarations
|
|
791
|
+
if (node.type === "unsafe_block")
|
|
792
|
+
return true;
|
|
793
|
+
// unsafe fn ... — the function_item's text starts with "unsafe"
|
|
794
|
+
if (node.type === "function_item" && node.text.trimStart().startsWith("unsafe "))
|
|
795
|
+
return true;
|
|
796
|
+
if (node.type === "type_cast_expression") {
|
|
797
|
+
return node.text.includes("*const") || node.text.includes("*mut");
|
|
798
|
+
}
|
|
799
|
+
return false;
|
|
800
|
+
},
|
|
801
|
+
java: (node) => {
|
|
802
|
+
// Object type, Class<?>
|
|
803
|
+
if (node.type === "type_identifier" && node.text === "Object")
|
|
804
|
+
return true;
|
|
805
|
+
if (node.type === "generic_type" && node.text.includes("Class<?>"))
|
|
806
|
+
return true;
|
|
807
|
+
return false;
|
|
808
|
+
},
|
|
809
|
+
csharp: (node) => {
|
|
810
|
+
// dynamic, object
|
|
811
|
+
if (node.type === "predefined_type" && (node.text === "dynamic" || node.text === "object")) {
|
|
812
|
+
return true;
|
|
813
|
+
}
|
|
814
|
+
if (node.type === "identifier" && node.text === "dynamic")
|
|
815
|
+
return true;
|
|
816
|
+
return false;
|
|
817
|
+
},
|
|
818
|
+
cpp: (node) => {
|
|
819
|
+
// void* pointers (unsafe), auto keyword (type-erased)
|
|
820
|
+
if (node.type === "pointer_declarator") {
|
|
821
|
+
const parent = node.parent;
|
|
822
|
+
if (parent && parent.text.includes("void"))
|
|
823
|
+
return true;
|
|
824
|
+
}
|
|
825
|
+
if (node.type === "auto" || (node.type === "primitive_type" && node.text === "auto"))
|
|
826
|
+
return true;
|
|
827
|
+
return false;
|
|
828
|
+
},
|
|
829
|
+
php: (node) => {
|
|
830
|
+
// mixed type
|
|
831
|
+
if (node.type === "named_type" && node.text === "mixed")
|
|
832
|
+
return true;
|
|
833
|
+
return false;
|
|
834
|
+
},
|
|
835
|
+
kotlin: (node) => {
|
|
836
|
+
// Any, Any?
|
|
837
|
+
if (node.type === "user_type" && (node.text === "Any" || node.text === "Any?"))
|
|
838
|
+
return true;
|
|
839
|
+
return false;
|
|
840
|
+
},
|
|
841
|
+
swift: (node) => {
|
|
842
|
+
// Any, AnyObject
|
|
843
|
+
if (node.type === "type_identifier" && (node.text === "Any" || node.text === "AnyObject"))
|
|
844
|
+
return true;
|
|
845
|
+
return false;
|
|
846
|
+
},
|
|
847
|
+
};
|
|
848
|
+
function detectWeakTypes(root, language) {
|
|
849
|
+
const weakLines = [];
|
|
850
|
+
const checker = WEAK_TYPE_PATTERNS[language];
|
|
851
|
+
if (!checker)
|
|
852
|
+
return weakLines;
|
|
853
|
+
walkTree(root, (node) => {
|
|
854
|
+
if (checker(node)) {
|
|
855
|
+
weakLines.push(node.startPosition.row + 1);
|
|
856
|
+
}
|
|
857
|
+
});
|
|
858
|
+
return [...new Set(weakLines)].sort((a, b) => a - b);
|
|
859
|
+
}
|
|
860
|
+
// ─── Import Extraction ──────────────────────────────────────────────────────
|
|
861
|
+
const IMPORT_NODE_TYPES = {
|
|
862
|
+
typescript: ["import_statement"],
|
|
863
|
+
javascript: ["import_statement"],
|
|
864
|
+
python: ["import_statement", "import_from_statement"],
|
|
865
|
+
go: ["import_declaration"],
|
|
866
|
+
rust: ["use_declaration"],
|
|
867
|
+
java: ["import_declaration"],
|
|
868
|
+
csharp: ["using_directive"],
|
|
869
|
+
cpp: ["preproc_include"],
|
|
870
|
+
php: ["namespace_use_declaration"],
|
|
871
|
+
ruby: ["call"],
|
|
872
|
+
kotlin: ["import_header"],
|
|
873
|
+
swift: ["import_declaration"],
|
|
874
|
+
};
|
|
875
|
+
function extractImports(root, language) {
|
|
876
|
+
const imports = [];
|
|
877
|
+
const importTypes = IMPORT_NODE_TYPES[language] || [];
|
|
878
|
+
walkTree(root, (node) => {
|
|
879
|
+
if (!importTypes.includes(node.type))
|
|
880
|
+
return;
|
|
881
|
+
switch (language) {
|
|
882
|
+
case "typescript":
|
|
883
|
+
case "javascript":
|
|
884
|
+
// import { foo } from "module"; import "module"; import * as x from "module"
|
|
885
|
+
{
|
|
886
|
+
const source = node.childForFieldName("source");
|
|
887
|
+
if (source) {
|
|
888
|
+
imports.push(source.text.replace(/['"]/g, ""));
|
|
889
|
+
}
|
|
890
|
+
}
|
|
891
|
+
break;
|
|
892
|
+
case "python":
|
|
893
|
+
if (node.type === "import_statement") {
|
|
894
|
+
// import os, import os.path
|
|
895
|
+
for (const child of node.namedChildren) {
|
|
896
|
+
if (child.type === "dotted_name" || child.type === "aliased_import") {
|
|
897
|
+
const name = child.type === "aliased_import" ? child.childForFieldName("name")?.text || child.text : child.text;
|
|
898
|
+
if (name)
|
|
899
|
+
imports.push(name);
|
|
900
|
+
}
|
|
901
|
+
}
|
|
902
|
+
}
|
|
903
|
+
else if (node.type === "import_from_statement") {
|
|
904
|
+
// from flask import Flask
|
|
905
|
+
const moduleNode = node.childForFieldName("module_name");
|
|
906
|
+
if (moduleNode)
|
|
907
|
+
imports.push(moduleNode.text);
|
|
908
|
+
}
|
|
909
|
+
break;
|
|
910
|
+
case "go":
|
|
911
|
+
// import "fmt" or import ( "fmt" "net/http" )
|
|
912
|
+
walkTree(node, (child) => {
|
|
913
|
+
if (child.type === "import_spec" || child.type === "interpreted_string_literal") {
|
|
914
|
+
const text = child.text.replace(/"/g, "");
|
|
915
|
+
if (text && text !== "(" && text !== ")")
|
|
916
|
+
imports.push(text);
|
|
917
|
+
}
|
|
918
|
+
});
|
|
919
|
+
break;
|
|
920
|
+
case "rust":
|
|
921
|
+
// use std::io; use crate::module_name;
|
|
922
|
+
{
|
|
923
|
+
const pathNode = node.namedChildren.find((c) => c.type === "scoped_identifier" ||
|
|
924
|
+
c.type === "identifier" ||
|
|
925
|
+
c.type === "use_wildcard" ||
|
|
926
|
+
c.type === "use_list" ||
|
|
927
|
+
c.type === "scoped_use_list");
|
|
928
|
+
if (pathNode) {
|
|
929
|
+
// Extract the root crate/module name
|
|
930
|
+
const fullPath = pathNode.text;
|
|
931
|
+
const rootModule = fullPath.split("::")[0];
|
|
932
|
+
if (rootModule)
|
|
933
|
+
imports.push(rootModule);
|
|
934
|
+
}
|
|
935
|
+
}
|
|
936
|
+
break;
|
|
937
|
+
case "java":
|
|
938
|
+
// import com.example.Foo;
|
|
939
|
+
{
|
|
940
|
+
const nameNode = node.namedChildren.find((c) => c.type === "scoped_identifier" || c.type === "identifier");
|
|
941
|
+
if (nameNode)
|
|
942
|
+
imports.push(nameNode.text);
|
|
943
|
+
}
|
|
944
|
+
break;
|
|
945
|
+
case "csharp":
|
|
946
|
+
// using System.IO;
|
|
947
|
+
{
|
|
948
|
+
const nameNode = node.namedChildren.find((c) => c.type === "qualified_name" || c.type === "identifier");
|
|
949
|
+
if (nameNode)
|
|
950
|
+
imports.push(nameNode.text);
|
|
951
|
+
}
|
|
952
|
+
break;
|
|
953
|
+
case "cpp":
|
|
954
|
+
// #include <header> or #include "header"
|
|
955
|
+
{
|
|
956
|
+
const pathNode = node.namedChildren.find((c) => c.type === "string_literal" || c.type === "system_lib_string");
|
|
957
|
+
if (pathNode) {
|
|
958
|
+
imports.push(pathNode.text.replace(/[<>"]/g, ""));
|
|
959
|
+
}
|
|
960
|
+
}
|
|
961
|
+
break;
|
|
962
|
+
case "php":
|
|
963
|
+
// use App\Models\User;
|
|
964
|
+
{
|
|
965
|
+
const nameNode = node.namedChildren.find((c) => c.type === "qualified_name" || c.type === "name");
|
|
966
|
+
if (nameNode)
|
|
967
|
+
imports.push(nameNode.text);
|
|
968
|
+
}
|
|
969
|
+
break;
|
|
970
|
+
case "ruby":
|
|
971
|
+
// require 'json' — Ruby imports are method calls
|
|
972
|
+
if (node.type === "call" && node.text.match(/^(?:require|require_relative|gem)\b/)) {
|
|
973
|
+
const argNode = node.namedChildren.find((c) => c.type === "argument_list");
|
|
974
|
+
if (argNode) {
|
|
975
|
+
const strNode = argNode.namedChildren.find((c) => c.type === "string");
|
|
976
|
+
if (strNode)
|
|
977
|
+
imports.push(strNode.text.replace(/['"]/g, ""));
|
|
978
|
+
}
|
|
979
|
+
}
|
|
980
|
+
break;
|
|
981
|
+
case "kotlin":
|
|
982
|
+
// import kotlin.coroutines.flow
|
|
983
|
+
{
|
|
984
|
+
const identifier = node.namedChildren.find((c) => c.type === "identifier" || c.type === "type_identifier");
|
|
985
|
+
if (identifier)
|
|
986
|
+
imports.push(identifier.text);
|
|
987
|
+
else if (node.text) {
|
|
988
|
+
const m = node.text.match(/import\s+([\w.]+)/);
|
|
989
|
+
if (m)
|
|
990
|
+
imports.push(m[1]);
|
|
991
|
+
}
|
|
992
|
+
}
|
|
993
|
+
break;
|
|
994
|
+
case "swift":
|
|
995
|
+
// import Foundation
|
|
996
|
+
{
|
|
997
|
+
const nameNode = node.namedChildren.find((c) => c.type === "identifier");
|
|
998
|
+
if (nameNode)
|
|
999
|
+
imports.push(nameNode.text);
|
|
1000
|
+
}
|
|
1001
|
+
break;
|
|
1002
|
+
}
|
|
1003
|
+
});
|
|
1004
|
+
// TypeScript/JavaScript: also detect require("module") calls
|
|
1005
|
+
if (language === "typescript" || language === "javascript") {
|
|
1006
|
+
walkTree(root, (node) => {
|
|
1007
|
+
if (node.type !== "call_expression")
|
|
1008
|
+
return;
|
|
1009
|
+
const fn = node.childForFieldName("function");
|
|
1010
|
+
if (!fn || fn.text !== "require")
|
|
1011
|
+
return;
|
|
1012
|
+
const args = node.childForFieldName("arguments");
|
|
1013
|
+
if (!args)
|
|
1014
|
+
return;
|
|
1015
|
+
const firstArg = args.namedChildren[0];
|
|
1016
|
+
if (firstArg && (firstArg.type === "string" || firstArg.type === "template_string")) {
|
|
1017
|
+
imports.push(firstArg.text.replace(/['"]/g, ""));
|
|
1018
|
+
}
|
|
1019
|
+
});
|
|
1020
|
+
}
|
|
1021
|
+
return imports;
|
|
1022
|
+
}
|
|
1023
|
+
// ─── Class Extraction ───────────────────────────────────────────────────────
|
|
1024
|
+
const CLASS_NODE_TYPES = {
|
|
1025
|
+
typescript: ["class_declaration"],
|
|
1026
|
+
javascript: ["class_declaration"],
|
|
1027
|
+
python: ["class_definition"],
|
|
1028
|
+
go: ["type_declaration"],
|
|
1029
|
+
rust: ["struct_item", "enum_item"],
|
|
1030
|
+
java: ["class_declaration", "interface_declaration", "enum_declaration"],
|
|
1031
|
+
csharp: ["class_declaration", "struct_declaration", "interface_declaration", "enum_declaration"],
|
|
1032
|
+
cpp: ["class_specifier", "struct_specifier"],
|
|
1033
|
+
php: ["class_declaration", "interface_declaration", "trait_declaration"],
|
|
1034
|
+
ruby: ["class", "module"],
|
|
1035
|
+
kotlin: ["class_declaration", "object_declaration"],
|
|
1036
|
+
swift: ["class_declaration", "struct_declaration", "protocol_declaration"],
|
|
1037
|
+
};
|
|
1038
|
+
function extractClasses(root, language) {
|
|
1039
|
+
const classes = [];
|
|
1040
|
+
const classTypes = CLASS_NODE_TYPES[language] || [];
|
|
1041
|
+
walkTree(root, (node) => {
|
|
1042
|
+
if (!classTypes.includes(node.type))
|
|
1043
|
+
return;
|
|
1044
|
+
if (language === "go" && node.type === "type_declaration") {
|
|
1045
|
+
// Only count struct types: type Foo struct { ... }
|
|
1046
|
+
const spec = node.namedChildren.find((c) => c.type === "type_spec");
|
|
1047
|
+
if (spec) {
|
|
1048
|
+
const typeBody = spec.childForFieldName("type");
|
|
1049
|
+
if (typeBody && typeBody.type === "struct_type") {
|
|
1050
|
+
const nameNode = spec.childForFieldName("name");
|
|
1051
|
+
if (nameNode)
|
|
1052
|
+
classes.push(nameNode.text);
|
|
1053
|
+
}
|
|
1054
|
+
}
|
|
1055
|
+
return;
|
|
1056
|
+
}
|
|
1057
|
+
const nameNode = node.childForFieldName("name");
|
|
1058
|
+
if (nameNode)
|
|
1059
|
+
classes.push(nameNode.text);
|
|
1060
|
+
});
|
|
1061
|
+
return classes;
|
|
1062
|
+
}
|
|
1063
|
+
// ─── Decorator / Annotation Extraction ──────────────────────────────────────
|
|
1064
|
+
function extractDecorators(funcNode, language) {
|
|
1065
|
+
const decorators = [];
|
|
1066
|
+
switch (language) {
|
|
1067
|
+
case "typescript": {
|
|
1068
|
+
// TypeScript decorators are similar to Python
|
|
1069
|
+
const parent = funcNode.parent;
|
|
1070
|
+
if (parent) {
|
|
1071
|
+
for (const child of parent.namedChildren) {
|
|
1072
|
+
if (child.type === "decorator" && child.endPosition.row < funcNode.startPosition.row) {
|
|
1073
|
+
decorators.push(child.text.replace(/^@/, "").split("(")[0]);
|
|
1074
|
+
}
|
|
1075
|
+
}
|
|
1076
|
+
}
|
|
1077
|
+
break;
|
|
1078
|
+
}
|
|
1079
|
+
case "python": {
|
|
1080
|
+
// Decorators are siblings before the function_definition, but in the
|
|
1081
|
+
// tree-sitter grammar they're children of a decorated_definition parent.
|
|
1082
|
+
const parent = funcNode.parent;
|
|
1083
|
+
if (parent && parent.type === "decorated_definition") {
|
|
1084
|
+
for (const child of parent.namedChildren) {
|
|
1085
|
+
if (child.type === "decorator") {
|
|
1086
|
+
// Extract decorator name (without the @)
|
|
1087
|
+
const text = child.text.replace(/^@/, "").split("(")[0];
|
|
1088
|
+
decorators.push(text);
|
|
1089
|
+
}
|
|
1090
|
+
}
|
|
1091
|
+
}
|
|
1092
|
+
break;
|
|
1093
|
+
}
|
|
1094
|
+
case "java": {
|
|
1095
|
+
// Annotations are modifiers before the method
|
|
1096
|
+
const modifiers = funcNode.childForFieldName("modifiers") || funcNode.childForFieldName("modifier");
|
|
1097
|
+
if (modifiers) {
|
|
1098
|
+
for (const child of modifiers.namedChildren) {
|
|
1099
|
+
if (child.type === "marker_annotation" || child.type === "annotation") {
|
|
1100
|
+
decorators.push(child.text.replace(/^@/, "").split("(")[0]);
|
|
1101
|
+
}
|
|
1102
|
+
}
|
|
1103
|
+
}
|
|
1104
|
+
break;
|
|
1105
|
+
}
|
|
1106
|
+
case "csharp": {
|
|
1107
|
+
// Attribute lists before the method
|
|
1108
|
+
const parent = funcNode.parent;
|
|
1109
|
+
if (parent) {
|
|
1110
|
+
for (const child of parent.namedChildren) {
|
|
1111
|
+
if (child.type === "attribute_list" && child.endPosition.row < funcNode.startPosition.row) {
|
|
1112
|
+
decorators.push(child.text.replace(/[[\]]/g, "").split("(")[0]);
|
|
1113
|
+
}
|
|
1114
|
+
}
|
|
1115
|
+
}
|
|
1116
|
+
break;
|
|
1117
|
+
}
|
|
1118
|
+
}
|
|
1119
|
+
return decorators;
|
|
1120
|
+
}
|
|
1121
|
+
// ─── Async Detection ────────────────────────────────────────────────────────
|
|
1122
|
+
function checkIsAsync(funcNode, language) {
|
|
1123
|
+
switch (language) {
|
|
1124
|
+
case "typescript":
|
|
1125
|
+
case "javascript":
|
|
1126
|
+
// async keyword is a direct child of the function node
|
|
1127
|
+
return funcNode.children.some((c) => c.type === "async");
|
|
1128
|
+
case "python":
|
|
1129
|
+
// In Python tree-sitter, async functions have type "function_definition"
|
|
1130
|
+
// but the parent is a "decorated_definition" or the text starts with "async"
|
|
1131
|
+
return funcNode.text.trimStart().startsWith("async ");
|
|
1132
|
+
case "rust":
|
|
1133
|
+
// async fn
|
|
1134
|
+
return funcNode.text.trimStart().startsWith("async ");
|
|
1135
|
+
case "java":
|
|
1136
|
+
case "csharp": {
|
|
1137
|
+
// Check modifiers for 'async' keyword
|
|
1138
|
+
const modifiers = funcNode.childForFieldName("modifiers");
|
|
1139
|
+
if (modifiers) {
|
|
1140
|
+
return modifiers.children.some((c) => c.text === "async");
|
|
1141
|
+
}
|
|
1142
|
+
return false;
|
|
1143
|
+
}
|
|
1144
|
+
default:
|
|
1145
|
+
return false;
|
|
1146
|
+
}
|
|
1147
|
+
}
|
|
1148
|
+
// ─── Tree Walking Helper ────────────────────────────────────────────────────
|
|
1149
|
+
function walkTree(node, callback) {
|
|
1150
|
+
callback(node);
|
|
1151
|
+
for (const child of node.children) {
|
|
1152
|
+
walkTree(child, callback);
|
|
1153
|
+
}
|
|
1154
|
+
}
|
|
1155
|
+
function findFirstByType(node, type) {
|
|
1156
|
+
if (node.type === type)
|
|
1157
|
+
return node;
|
|
1158
|
+
for (const child of node.children) {
|
|
1159
|
+
const found = findFirstByType(child, type);
|
|
1160
|
+
if (found)
|
|
1161
|
+
return found;
|
|
1162
|
+
}
|
|
1163
|
+
return null;
|
|
1164
|
+
}
|