[논문 리뷰] Graph-ToolFormer: To Empower LLMs with Graph Reasoning Ability via Prompt Augmented by ChatGPT
본 논문은 Graph-ToolFormer를 제안하며, 프리 트레인된 LLM이 그래프 추론을 수행하도록 프롬프트를 외부 그래프 도구에 대한 ChatGPT 생성 API 호출로 보강하여 기본에서 고급 그래프 작업에 대한 추론을 가능하게 하는 프레임워크이다. 또한 GPT-J 및 LLaMA와 같은 모델을 특수한 그래프 추론 프롬프트 데이터셋으로 미세조정한다.
In this paper, we aim to develop a large language model (LLM) with the reasoning ability on complex graph data. Currently, LLMs have achieved very impressive performance on various natural language learning tasks, extensions of which have also been applied to study the vision tasks with multi-modal data. However, when it comes to the graph learning tasks, existing LLMs present very serious flaws due to their several inherited weaknesses in performing {multi-step logic reasoning}, {precise mathematical calculation} and {perception about the spatial and temporal factors}. To address such challenges, in this paper, we will investigate the principles, methodologies and algorithms to empower existing LLMs with graph reasoning ability, which will have tremendous impacts on the current research of both LLMs and graph learning. Inspired by the latest ChatGPT and Toolformer models, we propose the Graph-ToolFormer (Graph Reasoning oriented Toolformer) framework to teach LLMs themselves with prompts augmented by ChatGPT to use external graph reasoning API tools. Specifically, we will investigate to teach Graph-ToolFormer to handle various graph data reasoning tasks in this paper, including both (1) very basic graph data loading and graph property reasoning tasks, ranging from simple graph order and size to the graph diameter and periphery, and (2) more advanced reasoning tasks on real-world graph data, such as bibliographic networks, protein molecules, sequential recommender systems, social networks and knowledge graphs.
연구 동기 및 목표
- 여러 도메인에 걸쳐 LLM이 정확한 그래프 추론을 수행하도록 동기를 부여하고 가능하게 한다.
- 외부 그래프 추론 도구를 활용하여 그래프 학습과 현대 LLM 및 AIGC를 연결한다.
- 프롬프트 데이터셋을 만들고 LLM이 언제 어떤 그래프 도구를 사용할지 결정하도록 미세조정한다.
- 기본 그래프 속성 및 실제 그래프 데이터 세트에서의 유효성을 입증한다.
제안 방법
- 그래프 추론 작업에 대한 핸드-크래프된 지시문 및 프롬프트 템플릿을 제작한다.
- ChatGPT를 사용하여 API 호출로 그래프 추론 프롬프트 데이터셋을 주석 처리하고 보강한다.
- LoRA 및 양자화 기법을 사용하여 보강된 프롬프트로 사전 학습된 인과적 LLM(GPT-J, LLaMA 등)을 미세조정한다.
- 출력 문장에서 중첩 및 순차 도구 사용을 가능하게 하는 특수 토큰으로 API 호출을 표현한다.
- API 호출의 구문 분석, 실행 및 후처리를 구현하여 최종 답을 도출한다.
- 데이터, 프롬프트 및 코드를 포함한 공개 GitHub 리포지토리를 제공한다.

실험 결과
연구 질문
- RQ1보강된 프롬프트를 통해 외부 그래프 추론 도구를 LLM이 어떻게 활용하도록 이끈다면?
- RQ2이 프레임워크가 어떤 그래프 추론 작업(기본 속성부터 도메인 특정 작업까지)을 효과적으로 지원할 수 있는가?
- RQ3ChatGPT 보강 프롬프트로 미세조정하는 것이 LLM의 그래프 추론 정확도와 도구 사용 결정에 어떤 영향을 미치는가?
- RQ4이 프레임워크가 도서관적 네트워크, 분자 그래프, 지식 그래프와 같은 실제 그래프 데이터로 확장될 수 있는가?
주요 결과
- Graph-ToolFormer는 LLM이 그래프 추론 API 호출을 생성된 문장에 포함하도록 한다.
- 이 접근 방식은 기본 그래프 로딩과 속성 계산은 물론 여러 도메인에 걸친 고급 작업을 지원한다.
- 실세계 그래프 데이터 세트와 작업에 대한 실험 연구를 통해 프레임워크의 효과를 보여준다.
- 그래프 추론 능력을 갖춘 LLM 시연이 코드 및 데이터 세트와 함께 공개된다.

이 논문 읽기
누빈트 뷰어에서 원문을 열고, 읽으면서 궁금한 곳을 바로 물어보세요.
누빈트에서 이 논문 읽기이 리뷰는 AI가 논문 원문을 바탕으로 만들었습니다. 인용하기 전에 원문을 확인해 주세요.