PyTorch Geometric Contribution: COFT
Dec. 2025 | CS 224W, Machine Learning with Graphs [with Hsin (Newton) Chen]
Contributed a full implementation of COFT (Coarse-to-Fine Highlighting) into the PyTorch Geometric (PyG) framework, enabling structured entity-aware highlighting for hallucination reduction in LLM long-context reasoning tasks. The module includes:
- โก Recaller with Wikidata entity expansion
- ๐ Scorer with TF-ISF + self-information weighting
- ๐ง Selector with dynamic thresholding and flexible granularity
- ๐งช Full test suite & examples integrated into PyG
Our project also includes a Medium deep-dive article explaining our approach, architecture, and integration challenges:
๐ Medium Post
The module is currently under review (Pull Request #10550) in PyTorch Geometric. More demos and docs will be added soon.