Home▸AI & Machine Learning▸Social Network Community Detector — Louvain Live (2D)

Social Network Community Detector — Louvain Live (2D)

Watch the real Louvain modularity-optimization algorithm iteratively merge nodes of a simulated social graph into communities on a flat force-directed canvas, maximizing genuine modularity score live as the network is explored.

AI & Machine Learning2DHard60 FPS📱 Mobile-adapted⇄ 3D version
2d-ai-social-network-community-detection ↗ Open standalone

This 2D companion drives the exact same faithful Louvain community-detection implementation as the 3D version — the incremental modularity-gain bookkeeping, true multi-level aggregation into super-nodes, and a modularity score recomputed directly from the original graph's edges every time — but renders it on a plain force-directed canvas instead of an orbiting 3D scene. A synthetic social graph with hidden ground-truth communities is generated, then Run Phase 1 step sweeps every node through the ΔQ = ki,in/m − γ·Σtot·ki/(2m²) move test, Aggregate → next level collapses discovered communities into super-nodes for the next pass, and Run full algorithm automates both to convergence. Drag any node to reposition it, scroll to zoom, or drag empty space to pan — the flat layout makes it easier to read exactly which nodes jump community on each sweep than the 3D orbit view does.

⚙ Under the hood

Watch the real Louvain modularity-optimization algorithm iteratively merge nodes of a simulated social graph into communities on a flat force-directed canvas, maximizing genuine modularity score live as the network is explored.

Louvain algorithmcommunity detectionmodularitysocial network analysisgraph clusteringforce-directed layout

2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)