arXiv:2609.01441cs.LGSep 2026

Manuscript Offprint

arXiv:2609.01441

Edge-Girth as a Structural Edge Feature for Graph Neural Networks

Lilian Marey, Charlotte Laclau

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Graph neural networks (GNN) based on message passing are provably no more powerful than the one-dimensional Weisfeiler–Leman colour-refinement test (1-WL): starting from a uniform colouring, each node is repeatedly recoloured as a function of its own colour and the multiset of its neighbours' colours, and two graphs the process cannot tell apart receive identical representations, however deep or wide the network. A common remedy augments node or edge features with precomputed structural descriptors, most often counts of a fixed small subgraph such as triangles or longer cycles, but such counts require committing in advance to the size of the substructure being counted, a choice usually made blind to the data. We study a descriptor that avoids this choice. The edge-girth of an edge is the length of a shortest cycle through it, and its multiplicity is the number of such shortest cycles; together they form a per-edge invariant that reports cycles of arbitrary length and is computable exactly by a single breadth-first search per edge. Like other structural encodings, it is computed once from the graph alone, before and independently of any supervision, and is therefore not specific to a downstream objective. We evaluate it on two tasks of different kinds. Injected into a gated message-passing architecture, EGAGNN, it reaches a test MAE a factor three below the closest gated comparator on the ZINC-12k regression benchmark at 104k parameters; compared against bounded cycle-counting descriptors under the same architecture, it matches only a dictionary that explicitly counts cycles up to length eight, which requires twice as many channels, while a dictionary capped at length four performs no better than no structural information at all. On graph discrimination we prove a matching limitation: on graphs where every edge sees the same number of shortest cycles of the same length, the descriptor becomes constant and any model built on it collapses back to the 1-WL bound. This prediction holds without exception across all 400 pairs of the BREC graph-isomorphism benchmark: not one of the 90 such pairs is distinguished.

Code and datasets are available at https://anonymous.4open.science/r/GDDL_EGAGNN-5154

1 Introduction

Message-passing neural networks (MPNNs) are limited in expressive power by the one-dimensional Weisfeiler-Leman test (1-WL): two graphs that 1-WL fails to separate receive identical representations, no matter how many layers or parameters are used [18, 13]. A standard remedy is to enrich node or edge inputs with precomputed structural descriptors, most commonly counts of small subgraphs [3] or random-walk and spectral encodings [6]. Higher-order approaches such as cellular complexes [2] make cycle structure explicit at the message-passing level, while recent work on the cycle counting expressiveness of MPNNs [9] has quantified the limits of cycle-based augmentation. Subgraph counting carries an assumption that is rarely made explicit: the informative substructure must be bounded in size and fixed in advance. The limitation is one of coverage rather than of budget. A dictionary of motifs of size at most k cannot report a cycle of length k+1k+1, however much computation is spent on it; enlarging k trades one ceiling for a higher one but never removes it. The choice is consequential and is made blind: on a molecular dataset such as ZINC, a per-edge cycle dictionary capped at k = 4 leaves the model no better than one given no structural descriptor at all, while the same dictionary at k = 8 recovers almost all of the available gain.

In this article, we study a descriptor that does not require this choice. The edge-girth geg_e of an edge ee is the length of a shortest cycle containing ee, with ge=∞g_e = \infty when no such cycle exists; alongside it, we carry λe\lambda_e, the

*LTCI, Télécom Paris, Institut Polytechnique de Paris, Palaiseau, France (lilian.marey@telecom-paris.fr).

†LTCI, Télécom Paris, Institut Polytechnique de Paris, Palaiseau, France (charlotte.laclau@telecom-paris.fr).

number of cycles of that length through e. The pair is attached to each edge, is invariant under isomorphism, and reports a cycle of unbounded length: an edge lying only on a 20-cycle is described as faithfully as one lying on a triangle, with no dictionary to enlarge. It is also exactly computable, by a single breadth-first search per edge: the quantity equals one plus the length of a shortest path between the endpoints of e that avoids e, the object of the replacement path problem [1]. It carries meaning in applications, governing transition rates in active flow networks [16], and short cycles through an edge – exactly the small edge-girth values – are a dominant cause of decoding failure in the Tanner graphs of LDPC codes [17]. The collection of these values over all edges, the edge-girth sequence, has recently been characterised up to realizability [11].

That characterisation also indicates how the descriptor should not be used: the sequence is additive under vertex identification and does not determine the number of vertices of the graph, so it is a poor graph signature. We therefore propose to treat edge-girth locally, injecting the per-edge pair into message passing so that it modulates the flow of node information rather than summarising the graph on its own. The resulting model, EGAGNN (Edge-Gated Aligned GNN), gates each message by a learned function of the edge it travels along, and lets edge states absorb the context of their endpoints so that edge-girth information diffuses beyond immediate neighbourhoods.

The descriptor is effective on molecular property prediction and provably powerless on a precisely identifiable family of graphs. On ZINC-12k at a matched parameter budget, EGAGNN reaches a test MAE of 0.0932±0.00350.0932 \pm 0.0035, a factor three below the closest gated comparator. Holding the architecture and the chemical inputs fixed and varying only the structural descriptor, we compare (ge,λe)(g_e, \lambda_e) (together with a bridge indicator, three channels per edge in total) against bounded cycle-count dictionaries of increasing length. The three-channel descriptor is matched only by a six-channel dictionary reaching length eight, and dictionaries capped at four are worthless on this data: the advantage lies less in what edge-girth sees than in not having to guess where to stop looking. In the opposite direction, on edge-girth-regular graphs (those in which every edge lies on the same number of shortest cycles, all of the same length, [10]) the descriptor is constant by definition, and any model built on it computes what it would compute from a constant edge input: its expressive power falls back to the 1-WL bound. The prediction holds without a single exception on the BREC benchmark [15], a purpose-built collection of graph pairs designed to be hard for the Weisfeiler–Leman hierarchy. It does not, however, account for every hard case in that benchmark, as we discuss in Section 6.