getHubFunctions() — mcp Function Reference
Architecture documentation for the getHubFunctions() function in overview.ts from the mcp codebase.
Entity Profile
Dependency Diagram
graph TD c65b7123_414d_97e5_1ab3_1575c0eeef30["getHubFunctions()"] d8e22e5c_06d6_3c1a_d1ff_f9f562d53e5d["renderOverview()"] d8e22e5c_06d6_3c1a_d1ff_f9f562d53e5d -->|calls| c65b7123_414d_97e5_1ab3_1575c0eeef30 d6ed9355_f977_306b_b0ef_d7220fdefe68["get()"] c65b7123_414d_97e5_1ab3_1575c0eeef30 -->|calls| d6ed9355_f977_306b_b0ef_d7220fdefe68 6666a1f2_0912_ade3_4b0e_42190c41cd97["normalizePath()"] c65b7123_414d_97e5_1ab3_1575c0eeef30 -->|calls| 6666a1f2_0912_ade3_4b0e_42190c41cd97 style c65b7123_414d_97e5_1ab3_1575c0eeef30 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
src/tools/overview.ts lines 154–173
function getHubFunctions(graph: IndexedGraph, limit: number): { name: string; filePath: string; line: number; callerCount: number }[] {
const hubs: { name: string; filePath: string; line: number; callerCount: number }[] = [];
for (const [nodeId, adj] of graph.callAdj) {
if (adj.in.length < 3) continue;
const node = graph.nodeById.get(nodeId);
if (!node) continue;
const name = node.properties?.name as string;
const filePath = node.properties?.filePath as string;
const line = node.properties?.startLine as number;
if (!name || !filePath) continue;
hubs.push({ name, filePath: normalizePath(filePath), line: line || 0, callerCount: adj.in.length });
}
hubs.sort((a, b) => b.callerCount - a.callerCount);
return hubs.slice(0, limit);
}
Domain
Subdomains
Calls
Called By
Source
Frequently Asked Questions
What does getHubFunctions() do?
getHubFunctions() is a function in the mcp codebase.
What does getHubFunctions() call?
getHubFunctions() calls 2 function(s): get, normalizePath.
What calls getHubFunctions()?
getHubFunctions() is called by 1 function(s): renderOverview.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free