/** * Cluster super-graph (change: add-hierarchical-map-navigation). * * Aggregates the EXISTING label-propagation communities (`communityId` / * `communityLabel` on every FunctionNode -- set during call-graph build) into a * coarse "map of regions": each community becomes one super-node, and calls that * cross community boundaries become weighted super-edges. This is the high-level * planner's view -- the lay of the land an agent reads before drilling into one * region. No re-clustering and no new threshold; it only recombines what the * graph already carries. */ import type { SerializedCallGraph } from './call-graph.js'; export interface ClusterSuperNode { communityId: string; label: string; memberCount: number; fileCount: number; /** Files the community spans, most-populated first (absolute paths; caller relativizes). */ topFiles: string[]; /** Highest-fan-in member name -- the community's structural anchor. */ topLandmark: string | null; } export interface ClusterSuperEdge { fromCommunity: string; toCommunity: string; /** Number of distinct cross-community call edges from -> to. */ callCount: number; } export interface ClusterGraph { superNodes: ClusterSuperNode[]; superEdges: ClusterSuperEdge[]; } /** * Build the region-tier super-graph from a serialized call graph. Super-nodes are * communities; super-edges count distinct cross-community `calls` edges. External * and test nodes are excluded; self-edges (intra-community) are not super-edges. */ export declare function buildClusterGraph(graph: SerializedCallGraph): ClusterGraph; //# sourceMappingURL=cluster-graph.d.ts.map