在网页图上训练图基础模型
摘要
Acacia是一个仅在Common Crawl网页图上训练的图基础模型,支持任意特征和多种任务,如节点分类和链接预测,以及不依赖预训练LLMs的上下文学习。
arXiv:2609.30894v1 Announce Type: new
Abstract: We introduce Acacia, a graph foundation model, trained on the web graph. Acacia (i) supports arbitrary feature dimensionalities and semantics without additional training, (ii) supports a wide range of tasks, including node classification, link prediction, node clustering, and graph generation, without additional training, (iii) has in-context learning capabilities, and (iv) does not rely on pretrained LLMs. In particular, existing graph foundation models often require training additional classification heads or feature projectors to accommodate new graphs or new labels, whereas Acacia does not. Moreover, existing graph foundation models often gain their capabilities by being stitched together with pretrained LLMs, whereas Acacia is trained from scratch using only the Common Crawl web graph. This is also an important result because it provides evidence that graph models can acquire emergent capabilities from scratch like LLMs.
查看缓存全文
缓存时间: 2026/09/28 09:51
# Training Graph Foundation Models on The Web Graph
Source: [https://arxiv.org/html/2609.30894](https://arxiv.org/html/2609.30894)
###### Abstract
We introduce Acacia, a graph foundation model, trained on the web graph\. Acacia \(i\) supports arbitrary feature dimensionalities and semantics without additional training, \(ii\) supports a wide range of tasks, including node classification, link prediction, node clustering, and graph generation, without additional training, \(iii\) has in\-context learning capabilities, and \(iv\) does not rely on pretrained LLMs\. In particular, existing graph foundation models often require training additional classification heads or feature projectors to accommodate new graphs or new labels, whereas Acacia does not\. Moreover, existing graph foundation models often gain their capabilities by being stitched together with pretrained LLMs, whereas Acacia is trained from scratch using only the Common Crawl web graph\. This is also an important result because it provides evidence that graph models can acquire emergent capabilities from scratch like LLMs\.
## 1Introduction
Graph structures appear in many forms, including social networks, citation networks, transportation networks, chemical compounds, text \(one\-dimensional sequences\), and images \(two\-dimensional grids\)\. Conventional approaches have built separate models for each graph domain or task\. Models such as graph neural networks can use a single architecture for all kinds of graphs, but a particular set of model weights can only be used with a fixed feature dimensionality, fixed feature semantics, and a fixed task\.
Many graph foundation models that can be applied to various tasks have been proposed in recent years\. However, many of them depend on the representational power of LLMs or often require additional classification heads or feature projectors to accommodate new graphs or new labels\[[19](https://arxiv.org/html/2609.30894#bib.bib19),[40](https://arxiv.org/html/2609.30894#bib.bib40)\]\. One For All\[[23](https://arxiv.org/html/2609.30894#bib.bib23)\]addresses the mismatch between feature representations across domains by expressing node features as text, feeding them into an LLM, and using the resulting representations as node embeddings\. However, much of its capability depends on the LLM, and it is difficult to apply to features that are hard to express as text\. AnyGraph\[[38](https://arxiv.org/html/2609.30894#bib.bib38)\]is based on a mixture of experts represented by GCNs and residual MLPs, and improves its capabilities through task\-dependent routing, but does not achieve complete alignment for new graphs or new labels\.
We propose Acacia111Acacia is a tree\. A tree is a graph\. Therefore, Acacia is a graph\., the first graph foundation model that \(i\) supports arbitrary feature dimensionalities and semantics without additional training, \(ii\) supports a wide range of tasks, including node classification, link prediction, node clustering, and graph generation, without additional training, \(iii\) has in\-context learning capabilities, and \(iv\) does not rely on pretrained LLMs\.
One distinguishing feature of Acacia is that it is trained exclusively on the Common Crawl web graph\. Modern LLMs have developed through training on web data\. Extending this idea to graph foundation models is a natural step\. In particular, the web itself has a graph structure, and one could even argue that it is better suited to graph models than to text models\. The web’s link structure contains diverse topologies that are connected in a “natural” way\. Learning this structure is expected to enable graph foundation models to handle a variety of graph structures\.
Acacia is a decoder\-only autoregressive Transformer model, like GPT\. Acacia has three types of token, i\.e\., nodes, edges, and labels, which it generates sequentially\. This approach enables a variety of tasks\. Generating everything from the beginning yields a graph generation model\. Given a graph, filling in its nodes and edges as input to Acacia and generating labels as a continuation enables node classification or node clustering\. If the labels of some nodes are known, filling in those labels as well enables transductive classification\. Retrieving examples from other labeled graphs and prepending them as separate connected components enables in\-context learning\. Thus, a single model can perform various tasks by using a decoder\-only autoregressive Transformer, as in LLMs, and choosing how to arrange the input tokens\.
We trained Acacia\-315m, a model with 315M parameters, on 11 billion tokens, obtaining model weights that achieve nontrivial node clustering accuracy in a fully unsupervised setting and possess in\-context learning capabilities\. These model weights are publicly available on Hugging Face222[https://huggingface\.co/joisino/acacia\-315m](https://huggingface.co/joisino/acacia-315m)\. Obtaining a graph foundation model with such general capabilities entirely from scratch, without relying on pretrained LLMs, is an important result in itself\.
## 2Acacia
Figure 1:Token types\. Acacia has four types of tokens: headers, nodes, edges, and node labels\.### 2\.1Overview
Acacia is a decoder\-only autoregressive Transformer model, like GPT\. Acacia has four types of tokens: headers, nodes, edges, and node labels\. Figure[1](https://arxiv.org/html/2609.30894#S2.F1)shows the vector structure of each token type\. In every case, the last 3 dimensions encode the token type as a one\-hot vector\. A header is a special token that specifies the type of the next token\. For a header, the type in the last block refers to the next token rather than to the header itself\. The first\(d−3\)/2\(d\-3\)/2dimensions represent the node ID, and the following\(d−3\)/2\(d\-3\)/2dimensions are always zero\. For a node, the first\(d−3\)/2\(d\-3\)/2dimensions represent the node ID, and the following\(d−3\)/2\(d\-3\)/2dimensions represent the node features\. For an edge, the first\(d−3\)/2\(d\-3\)/2dimensions and the following\(d−3\)/2\(d\-3\)/2dimensions represent the IDs of its endpoints\. For a node label, the first\(d−3\)/2\(d\-3\)/2dimensions represent the node ID, and the following\(d−3\)/2\(d\-3\)/2dimensions represent the label ID\. This scheme allows all token types to be treated uniformly\.
Figure 2:Examples of tasks supported by Acacia\. Different tasks can be handled by changing the tokens included in the prompt and the generation targets\. These are only examples; tasks such as jointly predicting edges and node labels are also supported\.Node IDs and label IDs are assigned random vectors that remain consistent within an input\. Note that these are not one\-hot vectors\. This scheme can accommodate arbitrary numbers of nodes and labels\. In a high\-dimensional space, most vectors are nearly orthogonal and therefore easy to distinguish\. Although node IDs carry no meaning, assigning consistent node IDs within a graph allows the model to recognize connectivity\. For simplicity, consider identity matrices for both the collection of ID vectors and the embedding matrix \(i\.e\., one\-hot node IDs serve directly as embeddings within the Transformer\)\. In an attention layer, when nodes serve as queries and edges as keys, appropriate masking through the projection matrices allows a node to attend strongly only to edges incident to it\. For example, letd=13d=13, and let the embeddings of node 3, node 5, and the edgeeeconnecting them be
𝒗3\\displaystyle\{\\bm\{v\}\}\_\{3\}=\[0,0,1,0,0,0,0,0,0,0,1,0,0\]⊤\\displaystyle=\[0,0,1,0,0,0,0,0,0,0,1,0,0\]^\{\\top\}\(1\)𝒗5\\displaystyle\{\\bm\{v\}\}\_\{5\}=\[0,0,0,0,1,0,0,0,0,0,1,0,0\]⊤\\displaystyle=\[0,0,0,0,1,0,0,0,0,0,1,0,0\]^\{\\top\}\(2\)𝒗e\\displaystyle\{\\bm\{v\}\}\_\{e\}=\[0,0,1,0,0,0,0,0,0,1,0,1,0\]⊤\\displaystyle=\[0,0,1,0,0,0,0,0,0,1,0,1,0\]^\{\\top\}\(3\)and let the query and key projection matrices be
𝑾q\\displaystyle\{\\bm\{W\}\}\_\{q\}=\(10000000000000100000000000001000000000000010000000000000100000000\)\\displaystyle=\\begin\{pmatrix\}1&0&0&0&0&0&0&0&0&0&0&0&0\\\\ 0&1&0&0&0&0&0&0&0&0&0&0&0\\\\ 0&0&1&0&0&0&0&0&0&0&0&0&0\\\\ 0&0&0&1&0&0&0&0&0&0&0&0&0\\\\ 0&0&0&0&1&0&0&0&0&0&0&0&0\\\\ \\end\{pmatrix\}\(4\)𝑾k\\displaystyle\{\\bm\{W\}\}\_\{k\}=\(10000100000000100001000000001000010000000010000100000000100001000\)\\displaystyle=\\begin\{pmatrix\}1&0&0&0&0&1&0&0&0&0&0&0&0\\\\ 0&1&0&0&0&0&1&0&0&0&0&0&0\\\\ 0&0&1&0&0&0&0&1&0&0&0&0&0\\\\ 0&0&0&1&0&0&0&0&1&0&0&0&0\\\\ 0&0&0&0&1&0&0&0&0&1&0&0&0\\\\ \\end\{pmatrix\}\(5\)Then,
𝑾q𝒗3=\[0,0,1,0,0\]⊤\\displaystyle\{\\bm\{W\}\}\_\{q\}\{\\bm\{v\}\}\_\{3\}=\[0,0,1,0,0\]^\{\\top\}\(6\)𝑾q𝒗5=\[0,0,0,0,1\]⊤\\displaystyle\{\\bm\{W\}\}\_\{q\}\{\\bm\{v\}\}\_\{5\}=\[0,0,0,0,1\]^\{\\top\}\(7\)𝑾k𝒗e=\[0,0,1,0,1\]⊤\\displaystyle\{\\bm\{W\}\}\_\{k\}\{\\bm\{v\}\}\_\{e\}=\[0,0,1,0,1\]^\{\\top\}\(8\)Thus, the corresponding inner products are11, whereas the inner products between other nodes and edgeeeare00\. The same argument holds for non\-one\-hot IDs as long as they are orthogonal\. This encoding scheme is therefore well suited to graph structures\. In practice, instead of using such manually constructed weight matrices, the weights are further optimized for the task in a data\-driven manner\. Moreover, the assignments of node IDs and label IDs are permuted on each run, allowing the model to focus on relationships rather than memorizing particular IDs\.
Acacia assumes that header tokens and other tokens alternate in the input\. After a header token is provided, the model is trained to generate a token of the type specified in the third block for the node ID specified in the first block\. This allows the generation target to be controlled\. For example, after providing a token sequence representing a graph, we can predict the label of node1818by appending a header token that specifies node1818and the label token type, and then performing next\-token prediction \(bottom of Figure[1](https://arxiv.org/html/2609.30894#S2.F1)\)\. Similarly, to predict an edge connected to node1818, we can append a header token that specifies node1818and the edge token type, and use next\-token prediction to generate one edge connected to that node\. In general, users can generate a graph in their desired order by repeatedly adding a header token manually, letting Acacia generate the next token, adding another header token, and letting Acacia generate the next token again\. For tasks such as graph generation, Acacia can also generate the header tokens automatically, allowing it to decide which nodes and edges to generate and in what order\. In what follows, we omit header tokens from the illustrations when they are obvious\.
Figure 3:An example of in\-context learning\. In\-context learning is naturally enabled by taking entire labeled graphs or extracting ego graphs around labeled nodes and adding them to the test graph as new connected components\. The example graphs can be fixed, or graphs with structures similar to the test graph can be retrieved from a database and used as examples, as in retrieval\-augmented generation \(RAG\)\.Combining these tokens enables various tasks \(Figure[2](https://arxiv.org/html/2609.30894#S2.F2)\)\. Because Acacia is a decoder\-only autoregressive Transformer generative model, it generates a graph when no conditioning information is provided\. Given a graph, we can prefill the prompt with that graph and generate a continuation to predict the remaining labels or edges\. In particular, it naturally supports transductive node classification, in which labels are given for some nodes and the labels of the remaining nodes are predicted\. If no labels are provided in the input, the task becomes unsupervised clustering, with no predefined binding for the labels\. With some exceptions\[[27](https://arxiv.org/html/2609.30894#bib.bib27)\], conventional clustering methods require the number of classes to be specified in advance; another advantage of this approach is that it does not\. Furthermore, as illustrated in Figure[3](https://arxiv.org/html/2609.30894#S2.F3), in\-context learning is naturally enabled by taking entire labeled graphs or extracting ego graphs around labeled nodes and adding them to the test graph as new connected components\. The example graphs can be fixed, or graphs with structures similar to the test graph can be retrieved from a database and used as examples, as in retrieval\-augmented generation \(RAG\)\[[20](https://arxiv.org/html/2609.30894#bib.bib20)\]\.
### 2\.2Training on the Web Graph
Table 1:Sampling probabilities for the elements provided as conditions and those predicted autoregressively\.We train Acacia on the Common Crawl web graph\. Nodes represent web pages, edges represent hyperlinks, and labels represent domains\. Training graphs are extracted from the Common Crawl web graph using breadth\-first search starting from 1 or more randomly selected nodes\. The model predicts domains from link structures or additional links from the connections between web pages\. To support different prediction types, we mix different ways of providing token types, as shown in Table[1](https://arxiv.org/html/2609.30894#S2.T1)\. Tokens are randomly shuffled within the conditioning part and within the autoregressive prediction part separately\. The number of nodesnnis sampled from88to128128according toP\(n\)∝n−1\.1P\(n\)\\propto n^\{\-1\.1\}, and breadth\-first search proceeds until that number of nodes is reached\. This enables the model to handle graphs of various sizes\. Training only on large graphs can be too difficult for learning to progress, whereas including graphs with fewer nodes allows learning to progress even in the early stages\. We expect this implicit curriculum to facilitate the smooth acquisition of capabilities\.
In addition to these tasks, we also construct some graphs as shown in Figure[3](https://arxiv.org/html/2609.30894#S2.F3)to develop in\-context learning capabilities\.
### 2\.3A Structure Independent of Feature\-Dimension Alignment
One difficulty in building graph foundation models is that the number and meaning of feature dimensions vary across graphs\. In citation network data, dimension11might indicate whether a paper contains the word “language,” whereas in chemical compound data, dimension11might indicate whether an atom is carbon\. The input vector alone does not reveal which meaning applies\. A model trained on the former data can therefore be confused when presented with the latter data at test time\.
Acacia deliberately corrupts the information in training features to reduce its dependence on individual dimensions\. Specifically, node features are constructed using signed hashing of the text in web page titles and bodies\. For example, each occurrence of “language” might add\+1\+1to dimension1919, while each occurrence of “tour” might add−1\-1to dimension5353\. This converts the text into a6464\-dimensional hashed bag of words\. As a result, each dimension mixes multiple meanings instead of having a specific, concrete meaning\.
To further encourage a focus on relationships, we also replace the features of some randomly selected nodes with samples from the standard normal distribution\. In particular, with a certain probability, we create examples in which the features of every node in the graph are replaced with samples from the standard normal distribution\. This is inspired by theoretical results showing that random features enhance the capabilities of graph neural networks, enabling them to solve various combinatorial problems on graphs\[[31](https://arxiv.org/html/2609.30894#bib.bib31),[30](https://arxiv.org/html/2609.30894#bib.bib30),[29](https://arxiv.org/html/2609.30894#bib.bib29)\]\. This is also useful in practice because it enables the model to handle cases where node features are unavailable at test time\.
At test time, we project node features into6464dimensions using a random projection matrix\. This matrix is shared within each graph and corresponds to the hashing used during training\. This allows the model to be applied to graphs with different feature dimensionalities and semantics, while still processing the graphs using relationships among dimensions and how those dimensions relate to one another within the graph structure\.
### 2\.4The Acacia Recipe
We describe the specific recipe for Acacia\-315M\. Acacia’s architecture is inspired by SmolLM2\-360M\[[1](https://arxiv.org/html/2609.30894#bib.bib1)\]\. Specifically, it is a decoder\-only model with 32 layers, a hidden dimension of 960, and 315M parameters\. However, we draw only on its architectural configuration and do not use any pretrained weights\.
We first trained the model for 10 billion tokens in a simple setting, followed by an additional 1 billion tokens of training\. In the simple setting, only web page titles are used to construct node features, and no data are explicitly constructed for in\-context learning\. During the additional training, we use the first 512 words of the page body, which is more informative than the title, to construct node features, and mix in graphs explicitly constructed for in\-context learning as shown in Figure[3](https://arxiv.org/html/2609.30894#S2.F3)\. Note that our 10 billion tokens are not directly comparable to 10 billion tokens in LLM training\. In LLM training, approximately one word corresponds to one token\. In our training, by contrast, a single web page corresponds to one to a few tokens\. Since a web page contains hundreds of tokens, Acacia may process hundreds of times as many web pages even at the same total of 10 billion tokens\.
Training starts entirely from scratch with random initialization\. We use AdamW, warming up the learning rate from 3e\-6 to 3e\-4 over 20M tokens and then decaying it to 3e\-5 over the remaining tokens with a cosine schedule\. For the additional training, we reinitialize AdamW, warm up the learning rate from 3e\-6 to 1e\-4 over 10M tokens, and then decay it to 1e\-5 with a cosine schedule\.
Initial training used 8 RTX 5090 GPUs and completed in 20 hours\. The additional training used 4 RTX 5090 GPUs and 4 L40S GPUs and completed in 4 hours\. Training took approximately 24 hours in total\.
## 3Experiments
Table 2:Dataset statistics and official data splits\.We experimentally evaluate the performance of Acacia\-315M\. In particular, we examine whether the foundation model works without additional training\. Acacia\-315M can adapt to various tasks and datasets without updating its model weights\.
We use Cora, CiteSeer, PubMed, and ogbn\-products as standard testbeds\. We use the Planetoid public splits\[[32](https://arxiv.org/html/2609.30894#bib.bib32)\]for Cora, CiteSeer, and PubMed, and the official OGB split\[[15](https://arxiv.org/html/2609.30894#bib.bib15)\]for ogbn\-products\. Table[2](https://arxiv.org/html/2609.30894#S3.T2)lists their statistics\. These datasets differ in feature dimensionality and labels, and naturally also in the meanings of their feature dimensions and labels\. In particular, their features, labels, and graph structural properties differ from those of the web graph used for pretraining\. Nevertheless, Acacia achieves nontrivial accuracy on these datasets\.
### 3\.1Node Classification
Table 3:Node classification performance\. Each value is the mean accuracy±\\pmsample standard deviation over 3 seeds\.We first perform standard node classification\. For each test node, we extract a neighborhood graph of up to 128 nodes using breadth\-first search, assign labels only to nodes with training labels, and tokenize the graph\. We then predict the label of the test node\. By its nature, Acacia can ground labels that appear in the input graph, but cannot ground labels that do not; it can only recognize them as “new labels\.” In this experiment, we therefore restrict the output to labels present in the input graph\. If no node in the neighborhood has the same label as the test node’s true label, the prediction is necessarily counted as incorrect\. Conversely, if the input graph contains only nodes labeled with the test node’s true label and unlabeled nodes, even the untrained model is necessarily counted as correct\. This occurs frequently in Cora, Citeseer, and ogbn\-products because of homophily, making the chance level higher than that of uniform selection from all labels\. In contrast, labels are sparse in PubMed, so the entire neighborhood is often unlabeled\. Predictions are necessarily counted as incorrect in such cases, making the chance level lower than that of uniform selection from all labels\. Note that the weights of Acacia\-315M are never updated in this experiment\.
Table[3](https://arxiv.org/html/2609.30894#S3.T3)presents the results\. On the 3 datasets other than PubMed, Acacia outperforms both the randomly initialized, untrained Acacia model and the chance level\. PubMed is the exception because only 60 of its 19,717 nodes are labeled: in many cases, the extracted graph contains no training labels or no node with the correct label, so the prediction is necessarily counted as incorrect\. In\-context learning, described next, is useful in such cases\.
### 3\.2In\-Context Learning
Table 4:Classification performance with In\-Context Learning\. Each value is the mean accuracy±\\pmsample standard deviation over 3 seeds\.For each test node, we extract a neighborhood graph of up to 32 nodes using breadth\-first search\. We additionally select 1 to 2 examples per class from the training nodes and place them in connected components separate from the test node\. There are no edges between components, and no nodes are shared between them\. The entire graph contains at most 128 nodes\. Because labels are always present in the input, the model can select one of them, almost eliminating cases in which a prediction is necessarily incorrect\. We say “almost” because ogbn\-products has labels that appear in the test data but not in the training data\. In such cases, the true label is absent from the examples, so the prediction is necessarily incorrect\. This does not occur in Cora, CiteSeer, or PubMed\. Note that the weights of Acacia\-315M are never updated in this experiment\.
Table[4](https://arxiv.org/html/2609.30894#S3.T4)presents the results\. On every dataset, Acacia outperforms both the randomly initialized, untrained Acacia model and the chance level\. In particular, it exceeds the chance level even on PubMed, where performance without in\-context learning was close to chance\. This is an important result because it demonstrates that LLM\-style in\-context learning through token prompts is possible using graph data alone, without relying on pretrained LLMs\.
### 3\.3Clustering
Table 5:Clustering performance of the untrained model and Acacia\. Each value is the mean±\\pmsample standard deviation over 3 seeds\.Next, we conduct challenging clustering experiments without using any labels\. We construct input graphs in two ways\. The first randomly selects 4 nodes, extracts a graph by breadth\-first search from each, and uses their union as the input graph\. These generally form a disconnected graph, making the clustering structure relatively clear\. The second randomly selects 1 node and extracts a graph using breadth\-first search\. This produces a contiguous region of the graph, making clustering more difficult\. Given a graph, we provide only its nodes and edges to Acacia and generate labels sequentially\. Note that the weights of Acacia\-315M are never updated in this experiment\.
Table[5](https://arxiv.org/html/2609.30894#S3.T5)reports the results\. We use the Adjusted Rand Index \(ARI\) and Adjusted Mutual Information \(AMI\) as clustering metrics\. The true node labels are used only for evaluation\. The chance level is00for both metrics\. In every setting and on every dataset, Acacia outperforms both the randomly initialized, untrained Acacia model and the chance level\. This shows that Acacia can effectively process graph structures even when no labels are used\.
## 4Related Work
There have been many attempts to build graph foundation models\[[24](https://arxiv.org/html/2609.30894#bib.bib24),[26](https://arxiv.org/html/2609.30894#bib.bib26),[35](https://arxiv.org/html/2609.30894#bib.bib35),[33](https://arxiv.org/html/2609.30894#bib.bib33),[38](https://arxiv.org/html/2609.30894#bib.bib38),[37](https://arxiv.org/html/2609.30894#bib.bib37),[4](https://arxiv.org/html/2609.30894#bib.bib4),[42](https://arxiv.org/html/2609.30894#bib.bib42),[3](https://arxiv.org/html/2609.30894#bib.bib3)\]\. However, to the best of our knowledge, none pretrain on the web graph\. Instead, common approaches pretrain on existing graph datasets such as citation or molecular graphs\[[14](https://arxiv.org/html/2609.30894#bib.bib14),[36](https://arxiv.org/html/2609.30894#bib.bib36),[43](https://arxiv.org/html/2609.30894#bib.bib43),[5](https://arxiv.org/html/2609.30894#bib.bib5),[41](https://arxiv.org/html/2609.30894#bib.bib41),[25](https://arxiv.org/html/2609.30894#bib.bib25)\], on in\-house data\[[2](https://arxiv.org/html/2609.30894#bib.bib2),[12](https://arxiv.org/html/2609.30894#bib.bib12)\], or on synthetic data\[[39](https://arxiv.org/html/2609.30894#bib.bib39),[9](https://arxiv.org/html/2609.30894#bib.bib9),[28](https://arxiv.org/html/2609.30894#bib.bib28),[7](https://arxiv.org/html/2609.30894#bib.bib7)\]\. These approaches may improve downstream performance on related datasets, but do not necessarily guarantee generality to other tasks\. Instead, we aim to acquire general capabilities without excessive manual design of inductive biases by avoiding overly curated data and using the Common Crawl web graph as a neutral source of data\.
Although we perform in\-context learning, methods for in\-context learning on graph data already exist\[[16](https://arxiv.org/html/2609.30894#bib.bib16),[10](https://arxiv.org/html/2609.30894#bib.bib10),[44](https://arxiv.org/html/2609.30894#bib.bib44)\]\. However, they may use GNNs, as in PRODIGY\[[16](https://arxiv.org/html/2609.30894#bib.bib16)\], or have difficulty generalizing to unseen graphs with different node features, as in VISION\[[10](https://arxiv.org/html/2609.30894#bib.bib10)\]\. Our strength is that our model can be applied to new graphs with different node features and that we build GPT\-style in\-context learning from scratch\.
Recent advances in LLMs have also prompted efforts to develop graph foundation models based on LLMs\[[13](https://arxiv.org/html/2609.30894#bib.bib13),[18](https://arxiv.org/html/2609.30894#bib.bib18),[17](https://arxiv.org/html/2609.30894#bib.bib17),[34](https://arxiv.org/html/2609.30894#bib.bib34),[21](https://arxiv.org/html/2609.30894#bib.bib21)\]\. Similarly, advances in tabular foundation models have motivated graph foundation models based on models such as TabPFN\[[11](https://arxiv.org/html/2609.30894#bib.bib11),[8](https://arxiv.org/html/2609.30894#bib.bib8),[6](https://arxiv.org/html/2609.30894#bib.bib6),[22](https://arxiv.org/html/2609.30894#bib.bib22)\]\. Because these approaches build on established large models, they tend to achieve high accuracy, but they are difficult to apply to data that are hard to convert into text or tables\. From a scientific perspective, it is also difficult to distinguish whether their performance comes from the capabilities of the pretrained model or from graph learning\. Our position is that, although these directions should be pursued for practical purposes, advancing graph learning also requires research on training pure graph models without relying too heavily on models from other domains\. We believe our work advances graph learning by training a pure graph model from scratch, without relying on pretrained LLMs or similar models, and acquiring emergent capabilities such as in\-context learning and zero\-shot learning\.
## 5Conclusion
We proposed Acacia and trained it on the web graph\. Acacia is the first graph foundation model that \(i\) supports arbitrary feature dimensionalities and semantics without additional training, \(ii\) supports a wide range of tasks, including node classification, link prediction, node clustering, and graph generation, without additional training, \(iii\) has in\-context learning capabilities, and \(iv\) does not rely on pretrained LLMs\. Acacia learns diverse graph structures from the web graph and achieves nontrivial downstream performance without adaptation\. This is also an important result because it provides evidence that graph models can acquire emergent capabilities from scratch like LLMs\.
## References
- \[1\]L\. B\. Allal, A\. Lozhkov, E\. Bakouch, G\. M\. Blázquez, G\. Penedo, L\. Tunstall, A\. Marafioti, H\. Kydlícek, A\. P\. Lajarín, V\. Srivastav, J\. Lochner, C\. Fahlgren, X\.\-S\. Nguyen, C\. Fourrier, B\. Burtenshaw, H\. Larcher, H\. Zhao, C\. Zakka, M\. Morlon, C\. Raffel, L\. von Werra, and T\. Wolf\.SmolLM2: When smol goes big \- Data\-Centric training of a small language model\.*arXiv*, 2025\.doi:10\.48550/arXiv\.2502\.02737\.URL[https://arxiv\.org/abs/2502\.02737](https://arxiv.org/abs/2502.02737)\.
- \[2\]M\. Bechler\-Speicher, Y\. Gottlieb, A\. Isakov, D\. Abensur, A\. Tavory, D\. Haimovich, I\. Guy, and U\. Weinsberg\.Billion\-Scale graph foundation models\.*arXiv*, 2026\.doi:10\.48550/arXiv\.2602\.04768\.URL[https://arxiv\.org/abs/2602\.04768](https://arxiv.org/abs/2602.04768)\.
- \[3\]D\. Chen, M\. Krimmel, and K\. M\. Borgwardt\.Flatten graphs as sequences: Transformers are scalable graph generators\.In*Conference on Neural Information Processing Systems*, 2025a\.doi:10\.48550/arXiv\.2502\.02216\.URL[https://arxiv\.org/abs/2502\.02216](https://arxiv.org/abs/2502.02216)\.
- \[4\]J\. Chen, H\. Zuo, H\. Wang, S\. Miao, P\. Li, and R\. Ying\.Towards a universal graph structural encoder\.In*ACM Web Conference*, pages 1457–1468, 2026\.doi:10\.1145/3774904\.3792656\.URL[https://arxiv\.org/abs/2504\.10917](https://arxiv.org/abs/2504.10917)\.
- \[5\]X\. Chen, Y\. Wang, J\. He, Y\. Du, S\. Hassoun, X\. Xu, and L\. Liu\.Graph generative pre\-trained transformer\.In*International Conference on Machine Learning*, 2025b\.doi:10\.48550/arXiv\.2501\.01073\.URL[https://arxiv\.org/abs/2501\.01073](https://arxiv.org/abs/2501.01073)\.
- \[6\]J\. Choi, W\. Kang, M\. Kim, J\. Kim, and N\. Park\.Can TabPFN compete with GNNs for node classification via graph tabularization?*arXiv*, 2025\.doi:10\.48550/arXiv\.2512\.08798\.URL[https://arxiv\.org/abs/2512\.08798](https://arxiv.org/abs/2512.08798)\.
- \[7\]J\. Choi, J\. Kim, W\. Kang, and N\. Park\.Learning posterior predictive distributions for node classification from synthetic graph priors\.In*International Conference on Learning Representations, ICLR*, 2026\.doi:10\.48550/arXiv\.2604\.19028\.URL[https://arxiv\.org/abs/2604\.19028](https://arxiv.org/abs/2604.19028)\.
- \[8\]D\. Eremeev, G\. Bazhenov, O\. Platonov, A\. Babenko, and L\. Prokhorenkova\.Turning tabular foundation models into graph foundation models\.*arXiv*, 2025a\.doi:10\.48550/arXiv\.2508\.20906\.URL[https://arxiv\.org/abs/2508\.20906](https://arxiv.org/abs/2508.20906)\.
- \[9\]D\. Eremeev, O\. Platonov, G\. Bazhenov, A\. Babenko, and L\. Prokhorenkova\.GraphPFN: A Prior\-Data fitted graph foundation model\.*arXiv*, 2025b\.doi:10\.48550/arXiv\.2509\.21489\.URL[https://arxiv\.org/abs/2509\.21489](https://arxiv.org/abs/2509.21489)\.
- \[10\]R\. Guan, Y\. Wang, C\. Guo, B\. Cao, F\. Giunchiglia, W\. Pang, Y\. Liu, and X\. Feng\.Advancing graph Few\-Shot learning via In\-Context learning\.*arXiv*, 2026\.doi:10\.48550/arXiv\.2605\.24410\.URL[https://arxiv\.org/abs/2605\.24410](https://arxiv.org/abs/2605.24410)\.
- \[11\]A\. Hayler, X\. Huang, I\. I\. Ceylan, M\. M\. Bronstein, and B\. Finkelshtein\.Of graphs and tables: Zero\-Shot node classification with tabular foundation models\.*arXiv*, 2025\.doi:10\.48550/arXiv\.2509\.07143\.URL[https://arxiv\.org/abs/2509\.07143](https://arxiv.org/abs/2509.07143)\.
- \[12\]Y\. He, Z\. Hou, Y\. Cen, J\. Hu, F\. He, X\. Cheng, J\. Tang, and B\. Hooi\.Generalizing graph transformers across diverse graphs and tasks via Pre\-Training on Industrial\-Scale data\.*IEEE Transactions on Knowledge and Data Engineering*, 38\(2\):1114–1128, 2025a\.doi:10\.1109/TKDE\.2025\.3632394\.URL[https://arxiv\.org/abs/2407\.03953](https://arxiv.org/abs/2407.03953)\.
- \[13\]Y\. He, Y\. Sui, X\. He, and B\. Hooi\.UniGraph: Learning a unified Cross\-Domain foundation model for Text\-Attributed graphs\.In*ACM SIGKDD Conference on Knowledge Discovery and Data Mining*, pages 448–459, 2025b\.doi:10\.1145/3690624\.3709277\.URL[https://arxiv\.org/abs/2402\.13630](https://arxiv.org/abs/2402.13630)\.
- \[14\]Y\. He, Y\. Sui, X\. He, Y\. Liu, Y\. Sun, and B\. Hooi\.UniGraph2: Learning a unified embedding space to bind multimodal graphs\.In*ACM Web Conference*, pages 1759–1770, 2025c\.doi:10\.1145/3696410\.3714818\.URL[https://arxiv\.org/abs/2502\.00806](https://arxiv.org/abs/2502.00806)\.
- \[15\]W\. Hu, M\. Fey, M\. Zitnik, Y\. Dong, H\. Ren, B\. Liu, M\. Catasta, and J\. Leskovec\.Open graph benchmark: Datasets for machine learning on graphs\.In*Conference on Neural Information Processing Systems*, 2020\.doi:10\.48550/arxiv\.2005\.00687\.URL[https://arxiv\.org/abs/2005\.00687](https://arxiv.org/abs/2005.00687)\.
- \[16\]Q\. Huang, H\. Ren, P\. Chen, G\. Krzmanc, D\. Zeng, P\. Liang, and J\. Leskovec\.PRODIGY: Enabling in\-context learning over graphs\.In*Conference on Neural Information Processing Systems*, 2023\.doi:10\.52202/075280\-0718\.URL[https://arxiv\.org/abs/2305\.12600](https://arxiv.org/abs/2305.12600)\.
- \[17\]F\. Kimino and R\. Sato\.Why does graph learning fail to fully benefit from a text teacher?*arXiv*, abs/2608\.25741, 2026\.doi:10\.48550/ARXIV\.2608\.25741\.URL[https://doi\.org/10\.48550/arXiv\.2608\.25741](https://doi.org/10.48550/arXiv.2608.25741)\.
- \[18\]L\. Kong, J\. Feng, H\. Liu, C\. Huang, J\. Huang, Y\. Chen, and M\. Zhang\.GOFA: A generative One\-For\-All model for joint graph language modeling\.In*International Conference on Learning Representations*, 2025\.doi:10\.48550/arXiv\.2407\.09709\.URL[https://arxiv\.org/abs/2407\.09709](https://arxiv.org/abs/2407.09709)\.
- \[19\]D\. Lachi, M\. Azabou, V\. Arora, and E\. L\. Dyer\.GraphFM: A generalist graph transformer that learns transferable representations across diverse domains\.*Transactions on Machine Learning Research*, 2025, 2025\.doi:10\.48550/arXiv\.2407\.11907\.URL[https://arxiv\.org/abs/2407\.11907](https://arxiv.org/abs/2407.11907)\.
- \[20\]P\. Lewis, E\. Perez, A\. Piktus, F\. Petroni, V\. Karpukhin, N\. Goyal, H\. Küttler, M\. Lewis, W\. tau Yih, T\. Rocktäschel, S\. Riedel, and D\. Kiela\.Retrieval\-Augmented generation for Knowledge\-Intensive NLP tasks\.In*Conference on Neural Information Processing Systems, NeurIPS*, volume 33, 2020\.doi:10\.48550/arxiv\.2005\.11401\.URL[https://arxiv\.org/abs/2005\.11401](https://arxiv.org/abs/2005.11401)\.
- \[21\]J\. Li, R\. Wu, Y\. Zhu, H\. Zhang, L\. Chen, and Z\. Zheng\.Are large language models In\-Context graph learners?*arXiv*, 2025\.doi:10\.48550/arXiv\.2502\.13562\.URL[https://arxiv\.org/abs/2502\.13562](https://arxiv.org/abs/2502.13562)\.
- \[22\]T\. Liao, C\. Hu, Y\. Sui, X\. Zhang, P\. Cui, J\. Li, and Z\. Zhang\.TFMLinker: Universal link predictor by graph In\-Context learning with tabular foundation models\.*arXiv*, 2026\.doi:10\.48550/arXiv\.2602\.08592\.URL[https://arxiv\.org/abs/2602\.08592](https://arxiv.org/abs/2602.08592)\.
- \[23\]H\. Liu, J\. Feng, L\. Kong, N\. Liang, D\. Tao, Y\. Chen, and M\. Zhang\.One for all: Towards training one graph model for all classification tasks\.In*International Conference on Learning Representations*, 2024\.doi:10\.48550/arXiv\.2310\.00149\.URL[https://arxiv\.org/abs/2310\.00149](https://arxiv.org/abs/2310.00149)\.
- \[24\]J\. Liu, C\. Yang, Z\. Lu, J\. Chen, Y\. Li, M\. Zhang, T\. Bai, Y\. Fang, L\. Sun, P\. S\. Yu, and C\. Shi\.Graph foundation models: Concepts, opportunities and challenges\.*IEEE Transactions on Pattern Analysis and Machine Intelligence, TPAMI*, 47\(6\):5023–5044, 2025\.doi:10\.1109/TPAMI\.2025\.3548729\.URL[https://arxiv\.org/abs/2310\.11829](https://arxiv.org/abs/2310.11829)\.
- \[25\]W\. Ma, Y\. Wang, X\. Wang, L\. Zou, and M\. Zhang\.GILT: An LLM\-Free, Tuning\-Free graph foundational model for In\-Context learning\.*arXiv*, 2025\.doi:10\.48550/arXiv\.2510\.04567\.URL[https://arxiv\.org/abs/2510\.04567](https://arxiv.org/abs/2510.04567)\.
- \[26\]H\. Mao, Z\. Chen, W\. Tang, J\. Zhao, Y\. Ma, T\. Zhao, N\. Shah, M\. Galkin, and J\. Tang\.Position: Graph foundation models are already here\.In*International Conference on Machine Learning*, pages 34670–34692, 2024\.doi:10\.48550/arXiv\.2402\.02216\.URL[https://arxiv\.org/abs/2402\.02216](https://arxiv.org/abs/2402.02216)\.
- \[27\]A\. Pakman, Y\. Wang, Y\. Lee, P\. Basu, J\. Lee, Y\. W\. Teh, and L\. Paninski\.Attentive clustering processes\.*arXiv*, 2020\.doi:10\.48550/arxiv\.2010\.15727\.URL[https://arxiv\.org/abs/2010\.15727](https://arxiv.org/abs/2010.15727)\.
- \[28\]O\. Platonov, G\. Bazhenov, D\. Eremeev, and L\. Prokhorenkova\.A fair evaluation of graph foundation models for node property prediction\.*arXiv*, 2026\.doi:10\.48550/arXiv\.2606\.24509\.URL[https://arxiv\.org/abs/2606\.24509](https://arxiv.org/abs/2606.24509)\.
- \[29\]R\. Sato\.A survey on the expressive power of graph neural networks\.*arXiv*, abs/2003\.04078, 2020\.doi:10\.48550/arxiv\.2003\.04078\.URL[https://arxiv\.org/abs/2003\.04078](https://arxiv.org/abs/2003.04078)\.
- \[30\]R\. Sato, M\. Yamada, and H\. Kashima\.Approximation ratios of graph neural networks for combinatorial problems\.In*Conference on Neural Information Processing Systems, NeurIPS*, pages 4083–4092, 2019\.doi:10\.48550/arxiv\.1905\.10261\.URL[https://arxiv\.org/abs/1905\.10261](https://arxiv.org/abs/1905.10261)\.
- \[31\]R\. Sato, M\. Yamada, and H\. Kashima\.Random features strengthen graph neural networks\.In*SIAM International Conference on Data Mining, SDM*, pages 333–341, 2020\.doi:10\.1137/1\.9781611976700\.38\.URL[https://arxiv\.org/abs/2002\.03155](https://arxiv.org/abs/2002.03155)\.
- \[32\]P\. Sen, G\. Namata, M\. Bilgic, L\. Getoor, B\. Gallagher, and T\. Eliassi\-Rad\.Collective classification in network data\.*AI Magazine*, 29\(3\):93–106, 2008\.doi:10\.1609/aimag\.v29i3\.2157\.URL[https://doi\.org/10\.1609/aimag\.v29i3\.2157](https://doi.org/10.1609/aimag.v29i3.2157)\.
- \[33\]Y\. Shen, J\. Zhou, B\. Bevilacqua, J\. Robinson, C\. I\. Kanatsoulis, J\. Leskovec, and B\. Ribeiro\.Zero\-Shot generalization of GNNs over distinct attribute domains\.In*International Conference on Machine Learning*, 2025\.URL[https://proceedings\.mlr\.press/v267/shen25p\.html](https://proceedings.mlr.press/v267/shen25p.html)\.
- \[34\]Y\. Z\. Sun, Z\. Ma, Y\. Ma, J\. Ma, and Q\. Tan\.GraphICL: Unlocking graph learning potential in LLMs through structured prompt design\.In*Findings of the Association for Computational Linguistics, NAACL*, pages 2440–2459, 2025\.doi:10\.18653/v1/2025\.findings\-naacl\.131\.URL[https://arxiv\.org/abs/2501\.15755](https://arxiv.org/abs/2501.15755)\.
- \[35\]Z\. Tang and J\. Chen\.Toward a graph foundation model: Pre\-Training transformers with random walks\.*arXiv*, 2025\.doi:10\.48550/arXiv\.2506\.14098\.URL[https://arxiv\.org/abs/2506\.14098](https://arxiv.org/abs/2506.14098)\.
- \[36\]S\. Wang, B\. Wang, Z\. Shen, B\. Deng, and Z\. Kang\.Multi\-Domain graph foundation models: Robust knowledge transfer via topology alignment\.In*International Conference on Machine Learning*, 2025a\.doi:10\.48550/arXiv\.2502\.02017\.URL[https://arxiv\.org/abs/2502\.02017](https://arxiv.org/abs/2502.02017)\.
- \[37\]Z\. Wang, Z\. Zhang, T\. Ma, N\. V\. Chawla, C\. Zhang, and Y\. Ye\.Towards graph foundation models: Learning generalities across graphs via Task\-Trees\.In*International Conference on Machine Learning*, 2025b\.doi:10\.48550/arXiv\.2412\.16441\.URL[https://arxiv\.org/abs/2412\.16441](https://arxiv.org/abs/2412.16441)\.
- \[38\]L\. Xia and C\. Huang\.AnyGraph: Graph foundation model in the wild\.In*Findings of the Association for Computational Linguistics, ACL*, pages 882–896, 2026\.doi:10\.18653/v1/2026\.findings\-acl\.44\.URL[https://arxiv\.org/abs/2408\.10700](https://arxiv.org/abs/2408.10700)\.
- \[39\]L\. Xia, B\. Kao, and C\. Huang\.OpenGraph: Towards open graph foundation models\.In*Findings of the Association for Computational Linguistics, EMNLP*, pages 2365–2379, 2024\.doi:10\.18653/v1/2024\.findings\-emnlp\.132\.URL[https://arxiv\.org/abs/2403\.01121](https://arxiv.org/abs/2403.01121)\.
- \[40\]X\. Yu, Z\. Gong, C\. Zhou, Y\. Fang, and H\. Zhang\.SAMGPT: Text\-free graph foundation model for multi\-domain pre\-training and cross\-domain adaptation\.In*ACM Web Conference, WWW*, pages 1142–1153, 2025\.doi:10\.1145/3696410\.3714828\.URL[https://arxiv\.org/abs/2502\.05424](https://arxiv.org/abs/2502.05424)\.
- \[41\]H\. Yuan, Q\. Sun, J\. Tao, X\. Fu, and J\. Li\.RAG\-GFM: Overcoming In\-Memory bottlenecks in graph foundation models via Retrieval\-Augmented generation\.In*ACM Web Conference*, pages 626–637, 2026\.doi:10\.1145/3774904\.3792139\.URL[https://arxiv\.org/abs/2601\.15124](https://arxiv.org/abs/2601.15124)\.
- \[42\]J\. Zhao, H\. Mostafa, M\. Galkin, M\. M\. Bronstein, Z\. Zhu, and J\. Tang\.GraphAny: A foundation model for node classification on any graph\.In*International Conference on Learning Representations*, 2025a\.doi:10\.48550/arXiv\.2405\.20445\.URL[https://arxiv\.org/abs/2405\.20445](https://arxiv.org/abs/2405.20445)\.
- \[43\]Q\. Zhao, W\. Ren, T\. Li, H\. Liu, X\. He, and X\. Xu\.GraphGPT: Graph learning with generative pre\-trained transformers\.In*International Conference on Machine Learning*, 2025b\.doi:10\.48550/arXiv\.2401\.00529\.URL[https://arxiv\.org/abs/2401\.00529](https://arxiv.org/abs/2401.00529)\.
- \[44\]W\. Zhuo and S\. Luo\.Modality\-free graph in\-context alignment\.In*International Conference on Learning Representations, ICLR*, 2026\.doi:10\.48550/arXiv\.2603\.13434\.URL[https://arxiv\.org/abs/2603\.13434](https://arxiv.org/abs/2603.13434)\.相似文章
超越特征与结构对齐:为图基础模型学习可迁移的传播知识
这篇arXiv论文介绍了ProGFM,一种传播感知的图基础模型,将边与特征维度之间的传播关系视为可迁移的知识单元,从而实现自适应聚合并提升跨域泛化能力。
FoundAna:一种用于图异常检测的 GNN 辅助基础模型
FoundAna 引入了一种用于图异常检测的基础模型,它集成了 GNNs 和 transformers,实现了可泛化的跨图性能,在多个基准数据集上展示了优越的结果。
GraphARC:基于图结构的抽象推理综合基准
GraphARC是一个针对图结构数据抽象推理的新基准,将ARC范式扩展到图领域。对最新语言模型的评估揭示了理解与执行之间的差距,且在大规模实例上性能下降,凸显了扩展挑战。
通过共享表示攻击图基础模型
本文识别并攻击了图基础模型的对齐层,表明这是一个独特的攻击面,在低预算扰动下尤其脆弱,特别是对于频谱分词器,并提出基于检测的防御措施。
构建 Agentic GraphRAG 系统:从知识图谱和本体论到作为 AI 智能体 MCP 服务器的统一记忆
作者认为 GraphRAG 本质上是一个数据建模问题,而非单纯的检索算法,并提出了一种包含五个组件的架构,利用本体论、知识图谱和 MCP 服务器为智能体提供统一记忆。