Skip to main content

Module analyses

Module analyses 

Expand description

Analysis implementations. Each is a SQL view over the fact store plus a thin Rust orchestrator.

Modules§

arch_violations
architecture-violations analysis.
architecture_metrics
architecture-metrics analysis — repo-level structural-health numbers over the resolved import graph, the kind you trend over time.
architecture_roles
architecture-roles analysis — per-file architectural role from the structural import graph’s “hidden structure” (Baldwin, MacCormack & Rusnak 2014).
architecture_trend
architecture-trend analysis — structural decay over the commit sequence.
authors
authors analysis — number of distinct authors per file (modernised).
bus_factor
bus-factor analysis.
centrality
Centrality analysis on the behavioural coupling graph.
churn
Churn analyses per spec §1.1:
clone_coupling
Clone-coupling intersection. The strategic differentiator vs every existing clone detector: only flag clones that ALSO change together at Fisher-significant rates. CodeScene calls this “X-Ray”; we ship the same analytical pattern with our published-formula transparency.
clones
Clones analysis. Walks the working tree at HEAD, fingerprints every function in every Tier-1 file, groups by structural digest, emits one row per clone-family member.
code_age
Code age analysis — entity → time since last modification.
code_familiarity
code-familiarity analysis — what fraction of SLOC is actively known by the team’s current contributors.
code_health
Code Health composite analysis.
communication
Communication analysis per spec §1.1 — Conway’s law shared-work author pairs.
communities
Leiden community detection on the behavioural coupling graph.
coordination_needs
coordination-needs analysis — per-file coordination overhead signal.
coupling
Change-coupling analysis per spec §3.2.1 correctness invariants:
crossing
crossing analysis — the “X” of Kazman & Cai’s DV8 hotspot patterns (Mo, Cai, Kazman, Xiao 2015 Hotspot Patterns).
cycle_health
cycle-health analysis — per-cycle behavioral heat, live/fossil verdict, and the cheapest cut point for each import tangle.
cycle_origins
cycle-origins analysis — pinpoint the commit where each HEAD dependency cycle first formed.
dashboard
Dashboard-specific analyses: the parameterised SQL queries that feed the single-file SPA dashboard’s widgets.
defect_validation
defect-validation analysis — surfaces a defect-calibration artifact’s own evidence as flat, human-scannable (metric, value) rows.
delivery_friction
delivery-friction analysis — where technical debt actively slows delivery.
delivery_metrics
delivery-metrics analysis — repo-level delivery flow distributions.
delta_health
delta-health — change-level health verdict for codelore diff.
dependency_cycles
dependency-cycles analysis — non-trivial strongly-connected components of the structural import graph.
effort_exposure
effort-exposure analysis — what fraction of engineering activity (commits, churn) flows into each code-health band (red / yellow / green).
entity_effort
entity-effort analysis — code-maat parity.
entity_ownership
entity-ownership analysis — code-maat parity.
factors
Zero-config four-factor dashboard header tiles.
finding_hotspot_overlap
finding-hotspot-overlap — external scanner findings fused with behavioral hotspot and code-health signal.
function_coupling
function-coupling analysis.
function_hotspots
function-hotspots analysis — repo-wide function-level hotspot ranking.
function_xray
function-xray analysis.
god_classes
god-classes analysis — files combining high cognitive complexity with high coupling (both inbound + outbound). Classic god-class symptom (Brown et al. 1998 AntiPatterns §3.1; Riel 1996 Object-Oriented Design Heuristics).
grouped_complexity
Shared helper for routing complexity-metric reads through complexity_metrics_grouped when opts.group_file is set.
health_trend
Repo Health Timeline: architectural, code, and combined health (each 0–100, higher = healthier) across evenly-spaced historical revisions. Reuses the architecture_trend sampler for the rev set and the rev-parameterizable code_health engine for the per-rev code score. On-demand, never cached.
hotspot_velocity
hotspot-velocity analysis — which files are heating up.
hotspots
Hotspot ranking analysis. cognitive_health is on [0, 100] (higher = healthier); percentile_rank is on [0, 1]; the score formula combines them so unhealthy + frequently-changed + complex files rank highest. Output range is [0, 10]:
import_graph
Shared structural-import-graph kernel.
instability
instability analysis — Robert C. Martin’s package-coupling metrics per file (Martin 1994, “OO Design Quality Metrics: An Analysis of Dependencies”; canonised in Clean Architecture 2017).
knowledge
Decayed-knowledge and Degree-of-Expertise (DOE) materialisation layer.
knowledge_islands
knowledge-islands analysis — automatic bus-factor / knowledge-loss detection per file.
lead_time
lead-time analysis.
lineage
Shared helper for routing analysis SQL through changes_lineage when opts.use_canonical_lineage is on. Each path-aggregating analysis calls materialize_if_needed once at the top of its run_* function, then wraps its SQL with rewrite (or uses source_table if it builds the SQL via format!()).
main_dev
main-dev / main-dev-by-revs / main-dev-by-deletions analyses.
marginal_owner_risk
Marginal-owner risk: ownership concentration × code-health fusion.
memo
Process-local analysis memos, owned by the analyses layer.
messages
messages analysis — code-maat parity. Match commit messages against a user-supplied regex; count one row per (file, matching-commit). High match counts surface files repeatedly touched by commits matching the regex — useful for “where do my bug-fix commits land?” or “which files get the most refactor mentions?”.
mi
Maintainability Index banding — repo-relative, not absolute.
modularity_violations
modularity-violations analysis — file pairs that co-change (Fisher-significant) yet have NO structural import edge between them.
new_code
new-code gate scope — the born/touched partition of the active working set that the [new_code] two-band gate evaluates.
ownership
Code ownership analysis per spec §1.1 — Fractal Value (1 − HHI).
pair_programming
pair-programming analysis.
query
Shared prepare → query_map → collect → format!()-wrapped errors boilerplate. Without this helper every analysis would copy-paste the same 7-line pattern with only the SQL constant, params, and mapper closure varying, and the error-message format would drift across analyses.
refactoring_targets
refactoring-targets analysis.
release_cadence
Release-cadence analysis — inter-release gap statistics from git tags.
revisions
revisions analysis — file → revision count. Code-maat parity output: (entity, n-revs). See spec §1.1 (“authors and revisions are addressable standalone”).
soc
Sum of Coupling (soc) — code-maat parity.
stale_code
stale-code analysis.
summary
Summary analysis per spec §1.1 — 4-row repo overview.
team_composition
Team-composition analysis — contribution-span buckets with a behavioral veteran gate and onboarding-velocity metric.
top_committers
top-committers analysis — per-author commit leaderboard.
unstable_interface
unstable-interface analysis — heavily-depended-on files that change often AND drag their dependents along when they do.