Introduction
Combinatorial optimization problems on graphs, such as Graph Coloring (GC) and Minimum Vertex Cover (MVC), are fundamental to numerous real-world applications including scheduling, register allocation, and network routing. Despite their importance, these problems are NP-hard, making them computationally expensive to solve optimally. While classical greedy heuristics offer speed, they often produce suboptimal solutions.
Recent advancements in machine learning have attempted to address these challenges. However, existing ML approaches frequently struggle with two critical issues: generalizing to graph sizes significantly larger than those seen during training, and managing problems where the total number of labels (e.g., the number of colors in GC) is not known a priori. This paper introduces a generalized "combinatorial node labeling" framework designed to learn fast, scalable, and high-quality heuristics that remain effective even in unbounded label spaces.
The Combinatorial Node Labeling Framework
The authors frame the node labeling task as a Markov Decision Process (MDP). A key innovation of this approach is the separation of node selection from label assignment. Instead of requiring a neural network to directly output labels, the model learns an optimal ordering of nodes. Once a node is selected, a simple, deterministic, problem-specific rule assigns the actual label (for instance, "assign the smallest valid color" in Graph Coloring).
The architecture consists of a Graph Attention Network (GAT) encoder that generates node embeddings and an attention-based decoder to select the next node to be labeled. By delegating label assignment to a guaranteed rule, the model avoids generating invalid solutions and simplifies the learning objective. The policy is trained end-to-end using the REINFORCE algorithm with a greedy rollout baseline.
Inductive Biases for Scalability
To overcome the quadratic complexity of standard global attention mechanisms, the authors inject two specific inductive biases into the architecture:
- Spatial Locality: Inspired by classical heuristics, the model only updates the attention weights for the neighbors of the most recently labeled node. This reduces decoding complexity from $O(n^2)$ to nearly linear, allowing the model to scale to massive graphs.
- Temporal Locality: The context embedding used for node selection only considers the global graph state and the last labeled node, rather than the entire history of actions.
Experimental Evaluation
The model was evaluated on synthetic graphs (Erdős-Rényi, Barabási-Albert, Watts-Strogatz) and real-world benchmarks.
- Graph Coloring: On the COLOR02/03 benchmark, the learned policy (using 100 samples) achieved a mean cost of 9.65, outperforming classical greedy baselines like Largest-First (10.65) and DSATUR (9.85).
- Minimum Vertex Cover: The model achieved an approximation ratio of 1.044 on ER graphs, beating both classical heuristics and ML baselines like S2V-DQN. On a real-world
memetrackergraph with nearly 1,000 nodes, it found a near-optimal cover in less than one second, whereas competing ML methods required 25 minutes. - Scalability: Thanks to the spatial locality bias, the model successfully colored graphs with over 20,000 vertices and 100,000 edges in under 23 seconds. In contrast, a global attention variant took over 150 seconds for the same task.
Key Insights and Conclusion
Qualitative analysis reveals that the model learns topology-aware strategies rather than simple fixed heuristics. For example, on scale-free Barabási-Albert graphs, it prioritizes high-degree hubs, while on Watts-Strogatz graphs, it tends to color neighboring nodes sequentially.
While the framework currently requires manual definition of cost functions and labeling rules for new problems, its success on unweighted node labeling tasks is promising. Future work aims to extend this architecture to weighted graphs and edge labeling problems, potentially addressing complex challenges like the Traveling Salesperson Problem or Maximum Cut.
Summary updated