Skip to content

examples: centrality distribution, max-norm vs percentile - #170

Open
Anandb71 wants to merge 1 commit into
mainfrom
examples/centrality-distribution
Open

examples: centrality distribution, max-norm vs percentile#170
Anandb71 wants to merge 1 commit into
mainfrom
examples/centrality-distribution

Conversation

@Anandb71

@Anandb71 Anandb71 commented Aug 9, 2026

Copy link
Copy Markdown
Collaborator

Adds the measurement tool used to recalibrate the v2.6.0 risk thresholds.

For any indexed directory it prints what fraction of nodes sit above a given centrality under both the old max-normalised scale and the percentile rank that replaced it, then reports which percentile selects the same population the old bars did.

That comparison is why the thresholds moved. Max-normalisation divides by the single most central node, so one numeric cutoff selects wildly different fractions depending on how peaked a repository's graph happens to be. Percentile rank does not — but the old cutoffs had been tuned against the old scale, and carrying them across unchanged silently redefined what "high risk" meant.

cargo run -p arbor-watcher --example centrality_dist -- <dir>

Examples only. No production code touched.

Adds the measurement tool used to recalibrate the v2.6.0 risk thresholds.

For any indexed directory it prints what fraction of nodes sit above a
given centrality under both the old max-normalised scale and the
percentile rank that replaced it, then reports which percentile selects
the same population the old bars did.

That comparison is why the thresholds moved. Max-normalisation divides by
the single most central node, so one numeric cutoff selects wildly
different fractions depending on how peaked a repository's graph happens
to be. Percentile rank does not — but the old cutoffs had been tuned
against the old scale, and carrying them across unchanged silently
redefined what "high risk" meant.

Usage: cargo run -p arbor-watcher --example centrality_dist -- <dir>
@arbor-cloud

arbor-cloud Bot commented Aug 9, 2026

Copy link
Copy Markdown

🟡 Arbor PR Walk

The file centrality_dist.rs has 1 symbol changed. It has no direct callers. This change reaches 8 downstream points.

Path heat MEDIUM 0%
Branch examples/centrality-distributionmain
Impact 1 file · 1 symbol · 0 reachable callers
Languages Rust

Changed Files

File Risk
crates/arbor-watcher/examples/centrality_dist.rs NONE

✅ Before You Merge

  • Run the full test suite before requesting review.
📊 Analysis confidence: High · 1275 nodes · 8588ms
  • Graph has 1275 nodes and 906 edges — well-connected codebase
  • 1 symbols changed, 0 upstream nodes analyzed

Arbor · View full report → · arbor v2.6.0 · 8588ms · 1275 nodes · verify locally with arbor diff · Deterministic PR blast-radius · Was this useful? 👍 👎

@github-actions

github-actions Bot commented Aug 9, 2026

Copy link
Copy Markdown

🌳 Arbor Impact Report

Risk Level: 🟢 Low | Blast Radius: 8 nodes | Changed Symbols: 1

Changed Files

File Status
crates/arbor-watcher/examples/centrality_dist.rs Modified

📊 Visual Impact Graph

graph TD
  classDef changed fill:#ef4444,stroke:#333,stroke-width:2px,color:#fff;
  classDef caller fill:#f59e0b,stroke:#333,stroke-width:1px,color:#fff;
  class main changed;
Loading

Impact Summary

Metric Count
Direct callers affected 0
Indirect callers affected 0
API entrypoints impacted 0
Files likely requiring updates 4
Total blast radius 8

Powered by Arbor v2.6.0 — graph-native code intelligence

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant