Skip to main content

Module clustering

Module clustering 

Source
Expand description

Label propagation community detection — GitCortex’s no-LLM answer to Graphify’s Leiden clustering. Deliberately a simpler algorithm: label propagation has no objective function to optimise (just “agree with your neighbours”), so it’s cheap, has no extra dependency, and is easy to keep fully deterministic — a hard requirement for a tool whose entire value proposition is “same input, same answer, every time.”

Adjacency is undirected, built from Contains + Calls edges (same edge set tour.rs uses for its centrality signal — these two are the structurally/behaviourally “close” relationships; Uses/Imports are left out as weaker signals that would blur cluster boundaries).

Structs§

Cluster
ClusterMember

Functions§

find_clusters
Detect communities via synchronous label propagation, returning clusters of min_cluster_size or more members, ranked by size descending (ties broken by label).