Skip to main content
Newv0.16.0: scoped scan and fix.Read the changelog →
DocsScoring

Scoring.

Every scan returns one number from 0 to 100. Same code in, same score out.

How it works

Every diagnostic contributes a weighted penalty based on its severity. Penalties are multiplied by the engine weight in .aislop/config.yml and by the rule's impact tier. Run aislop rules to see the tier and rationale for each rule.

SeverityBase penalty
Error3.0
Warning1.0
Info0.25

Default engine weights:

scoring:
  weights:
    format: 0.3
    lint: 0.6
    code-quality: 0.8
    ai-slop: 1.0
    architecture: 1.0
    security: 1.5
  smoothing: 20
  maxPerRule: 40

Rule impact tiers

Native rules carry an explicit impact tier so scoring is strict only where the signal justifies it. Style and cleanup still surface as findings, but they move the number less than swallowed errors or missing imports.

TierMultiplierTypical use
strict1.0High-confidence defects, security, missing imports, swallowed failures
standard1.0Real quality issues that may still need judgment
maintainability0.75Refactoring and design debt
mechanical0.5Cleanup that aislop fix can usually handle
style0.5Style, policy, and size pressure
advisory0.25Medium-confidence signals such as hardcoded config

Density and saturation

Each rule contributes at most scoring.maxPerRule weighted penalty points by default, so one noisy family cannot dominate the score. The final number uses logarithmic scaling with issue-density normalization against production and test files, so a large tree is not punished for being large.

Score labels

ScoreLabel
75–100Healthy
50–74Needs Work
0–49Critical
scoring:
  thresholds:
    good: 75
    ok: 50

CI quality gate

aislop ci exits 1 when the score drops below ci.failBelow, or when any error-severity diagnostic is present.

ci:
  failBelow: 70