arXiv:2502.02216cs.LGstat.ML2025-02NeurIPS被引 12

用Transformer生成图,速度快100倍且无需额外特征。

Flatten Graphs as Sequences: Transformers are Scalable Graph Generators

  • 将图转为随机序列,用解码器模型逐个生成边。
  • 生成速度比主流扩散模型快100倍,训练快3倍。
  • 支持子结构控制生成,适合构建图基础模型。

我们提出AutoGraph,一种基于仅解码器Transformer的可扩展属性图生成模型。通过可逆过程将图随机展平为标记序列,避免依赖昂贵的额外节点特征,与基于扩散的方法形成对比。该方法使采样复杂度和序列长度随边数线性增长,适用于大规模稀疏图。AutoGraph的关键优势在于其序列前缀对应诱导子图,与语言建模中的子句形成直接类比。实验表明,AutoGraph在合成和分子基准上达到当前最优性能,生成速度比领先扩散模型快100倍,训练速度加快3倍。它无需微调即可实现子结构条件生成,并展现出良好迁移能力,连接语言建模与图生成,为图基础模型奠定基础。代码已开源:https://github.com/BorgwardtLab/AutoGraph。

原文摘要 · Abstract (English)

We introduce AutoGraph, a scalable autoregressive model for attributed graph generation using decoder-only transformers. By flattening graphs into random sequences of tokens through a reversible process, AutoGraph enables modeling graphs as sequences without relying on additional node features that are expensive to compute, in contrast to diffusion-based approaches. This results in sampling complexity and sequence lengths that scale optimally linearly with the number of edges, making it scalable and efficient for large, sparse graphs. A key success factor of AutoGraph is that its sequence prefixes represent induced subgraphs, creating a direct link to sub-sentences in language modeling. Empirically, AutoGraph achieves state-of-the-art performance on synthetic and molecular benchmarks, with up to 100x faster generation and 3x faster training than leading diffusion models. It also supports substructure-conditioned generation without fine-tuning and shows promising transferability, bridging language modeling and graph generation to lay the groundwork for graph foundation models. Our code is available at https://github.com/BorgwardtLab/AutoGraph.

图生成Transformer高效生成子结构控制

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。