GithubHelp home page GithubHelp logo

dalk's Introduction

DALK: Dynamic Co-Augmentation of LLMs and KG to answer Alzheimer’s Disease Questions with Scientific Literature

Overview

Dependency

To fully run this project, one is recommended to install the requirement packages listed in requirements.txt.

LLMs for KG

To extract AD-KG for the following steps, one need to first replace the following parts in LLM4KG/api_utils.py:

palm.configure(api_key='')
api_key = ''

Then run LLM4KG/llm2kg_s2s.py or LLM4KG/llm2kg.py to extract AD-KG in generative method or RE method.

We also provide the AD-KG data directly in KG4LLM/Alzheimers/train_s2s.txt and KG4LLM/Alzheimers/train.txt

KG for LLMs

ADQA Benchmark

We put the samples of ADQA benchmark in KG4LLM/Alzheimers/result_filter/ for the original data and KG4LLM/Alzheimers/result_ner for the data with extracted entities.

Augment LLMs with AD-KG

To augment LLMs' inference with AD-KG, one need to first create a Blank Sandbox on Neo4j, and replace the follow parts in KG4LLM/MindMap_revised.py

YOUR_OPENAI_KEY = ''
uri = ""
username = ""
password = ""

And then, run

cd KG4LLM
python MindMap.py

It may take a while to upload the local AD-KG data to neo4j.

Credits: This work began as a fork of MindMap' repository: MindMap.

dalk's People

Contributors

david-li0406 avatar

Stargazers

runman avatar Mphone avatar  avatar normanj avatar  avatar Xinxu Wei avatar 老马 avatar  avatar  avatar  avatar Ao Wang avatar kh.zhu avatar  avatar Sukwon Yun avatar  avatar Youran Qu avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.