liveBook · Manning

ReFeX

As explained in Knowledge Graphs and LLMs in Action

Recursive feature extraction is the repeated aggregation of existing graph features to derive increasingly extensive structural representations.

ReFeX (Recursive Feature eXtraction) automates structural feature engineering while retaining interpretable, deterministic representations. It provides a practical middle ground between manually designed graph metrics and black-box representation learning. section 10.3 section 10.3.2

A ReFeX pipeline progressively expands each node’s structural description:

  • Extract local features such as node degree. section 10.3.1
  • Compute egonet features, including node counts, internal edges, and edges reaching outside the egonet. section 10.3.1
  • Aggregate neighboring feature values repeatedly with operators such as SUM and MEAN. section 10.3.1
  • Prune redundant features after recursive iterations to control complexity and improve selection. section 10.3.2

Manual calculation for node A

For node A, degree is 6, the egonet contains 7 nodes and 7 internal edges, the first neighbor-degree sum is 17, and the second aggregated sum is 69. MEAN produces approximately 2.83 and 11.5 at the corresponding iterations. section 10.3.1

Figure 10.8 ReFeX converts each node into a vector representing the node’s topological feature at different scales [8].
figure

Visualizes how ReFeX converts each node into a vector containing topological features at multiple structural scales. section 10.3

How Knowledge Graphs and LLMs in Action covers it

How deep it goes
Explains local, egonet, recursive, and pruning stages with manual calculations and implementation details, but omits node attributes and edge types.
Examples
Uses a small fraudulent network, node A’s egonet, degree tables, recursive SUM and MEAN calculations, and a Neo4j-based Hetionet exercise.
What it assumes
Assumes basic graph structures and feature engineering while teaching degree, egonets, recursive aggregation, and pruning through a small graph.
What you can do after
Build interpretable node feature vectors, trace their calculations, reproduce outputs, and selectively recompute affected features.
How it connects
Connects graph feature engineering, feature pruning, fraud detection, and representation learning.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Knowledge Graphs and LLMs in Action. The section links point to the parts of the book it draws on.