GNNavi: Navigating the Information Flow in Large Language Models by Graph Neural Network

Shuzhou Yuan, Ercong Nie, Michael Färber, Helmut Schmid, Hinrich Schütze
2/18/2024
cs.CLcs.AI

No official code found. Best implementation: ShuzhouYuan/GNNavi (6 stars, last commit 2024-08-27).

Abstract

Large Language Models (LLMs) exhibit strong In-Context Learning (ICL) capabilities when prompts with demonstrations are used. However, fine-tuning still remains crucial to further enhance their adaptability. Prompt-based fine-tuning proves to be an effective fine-tuning method in low-data scenarios, but high demands on computing resources limit its practicality. We address this issue by introducing a prompt-based parameter-efficient fine-tuning (PEFT) approach. GNNavi leverages insights into ICL's information flow dynamics, which indicates that label words act in prompts as anchors for information propagation. GNNavi employs a Graph Neural Network (GNN) layer to precisely guide the aggregation and distribution of information flow during the processing of prompts by hardwiring the desired information flow into the GNN. Our experiments on text classification tasks with GPT-2 and Llama2 show GNNavi surpasses standard prompt-based fine-tuning methods in few-shot settings by updating just 0.2% to 0.5% of parameters. We compare GNNavi with prevalent PEFT approaches, such as prefix tuning, LoRA and Adapter in terms of performance and efficiency. Our analysis reveals that GNNavi enhances information flow and ensures a clear aggregation process.

View on arXivView PDF

Code Implementations(1)

ShuzhouYuan/GNNaviCommunity100%
60Shell, PythonJan 1, 20242 years ago

Similar Papers

Cite this paper

@article{yuan2024gnnavi,
  title  = {GNNavi: Navigating the Information Flow in Large Language Models by Graph Neural Network},
  author = {Shuzhou Yuan and Ercong Nie and Michael Färber and Helmut Schmid and Hinrich Schütze},
  year   = {2024},
  eprint = {2402.11709},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2402.11709v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2402.11709.svg)](https://codeofpaper.com/paper/2402.11709)

Discussion