Skip to main content
QUICK REVIEW

[Paper Review] Making Large Language Models Perform Better in Knowledge Graph Completion

Yichi Zhang, Zhuo Chen|arXiv (Cornell University)|Oct 10, 2023
Advanced Graph Neural NetworksComputer Science14 citations
TL;DR

The paper proposes KoPA, a Knowledge Prefix Adapter, to inject KG structural information into LLMs for knowledge graph completion, improving structural-aware reasoning and performance on triple classification. It compares KoPA to zero-shot, in-context learning, and instruction-tuning baselines across three benchmarks.

ABSTRACT

Large language model (LLM) based knowledge graph completion (KGC) aims to predict the missing triples in the KGs with LLMs. However, research about LLM-based KGC fails to sufficiently harness LLMs' inference proficiencies, overlooking critical structural information integral to KGs. In this paper, we explore methods to incorporate structural information into the LLMs, with the overarching goal of facilitating structure-aware reasoning. We first discuss on the existing LLM paradigms like in-context learning and instruction tuning, proposing basic structural information injection approaches. Then we propose a Knowledge Prefix Adapter (KoPA) to fulfill this stated goal. The KoPA uses a structural pre-training phase to comprehend the intricate entities and relations within KGs, representing them as structural embeddings. Then KoPA communicates such cross-modal structural information understanding to the LLMs through a knowledge prefix adapter which projects the structural embeddings into the textual space and obtains virtual knowledge tokens positioned as a prefix of the input prompt. We conduct comprehensive experiments and provide incisive analysis concerning how the introduction of cross-modal structural information would be better for LLM's factual knowledge reasoning ability. Our code and data are available at https://github.com/zjukg/KoPA .

Motivation & Objective

  • Motivate improving KGC with LLMs by leveraging KG structural information.
  • Propose a two-stage KoPA framework that fuses KG structural embeddings with LLMs via a prefix adapter.
  • Evaluate structural-aware LLM-based KGC methods on multiple benchmarks and analyze effectiveness of structural information usage.

Proposed method

  • Introduce KoPA: structural embedding pre-training for entities and relations.
  • Project structural embeddings into textual space with a knowledge prefix adapter to create virtual knowledge tokens as a prompt prefix.
  • Combine KoPA with instruction tuning to enable structural-aware KGC via LLMs.
  • Compare KoPA against zero-shot, ICL, vanilla IT, and structural-aware IT baselines.
  • Provide complexity analysis of prompt length and efficiency versus neighborhood-text approaches.
  • Experiment with three KG benchmarks (UMLS, CoDeX-S, FB15K-237N) using Alpaca-7B and LoRA; report ACC, P, R, F1.

Experimental results

Research questions

  • RQ1Can KG structural information be effectively incorporated into LLMs to improve KGC performance?
  • RQ2How do different LLM paradigms (ZSR, ICL, IT) perform for KGC when augmented with structural information?
  • RQ3Does KoPA offer advantages in prompt length, scalability, and transferability over text-based neighborhood prompts?
  • RQ4What is the impact of structural embeddings on triple classification accuracy across standard KG benchmarks?

Key findings

  • KoPA outperforms vanilla IT and structural-aware IT on the triple classification task across benchmarks.
  • KoPA achieves strong results on UMLS, CoDeX-S, and FB15K-237N, with competitive or superior accuracy and F1 scores compared to baselines.
  • Structural embeddings projected via KoPA provide a compact, fixed-length prompt prefix (three virtual tokens per triple head/relation/tail) that is more efficient than neighborhood-text prompts.
  • Training with KoPA yields better structural-aware reasoning and transferability than text-only prompts across LLM backbones and settings.
  • KoPA demonstrates favorable prompt-length characteristics and competitive performance under fine-tuning with LoRA.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.