Coder Social home page Coder Social logo

mindmap's Introduction

MindMap: Knowledge Graph Prompting Sparks Graph of Thoughts in Large Language Models

This is the official codebase of the MindMap โ„๏ธ framework for eliciting the graph-of-thoughts reasoning capability in LLMs, proposed in MindMap: Knowledge Graph Prompting Sparks Graph of Thoughts in Large Language Models.

Overview

We present MindMap, a plug-and-play prompting approach, which enables LLMs to comprehend graphical inputs to build their own mind map that supports evidence-grounded generation. Here is an overview of our model architecture: https://github.com/willing510/MindMap/blob/main/fig/mind%20map.png

Run MindMap

As the chatdoctor5k dataset for example. First, you need to create a Blank Sandbox on https://sandbox.neo4j.com/, click "connect via drivers", find your url and user password. Then replace the following parts in MindMap.py:

uri = "Your_url"
username = "Your_user"     
password = "Your_password"

Note that the data of CMCKG is too large, and it will take about two days to wait. We recommend clicking "extend your project" in neo4j sandbox. But don't worry, the EMCKG used by chatdoctor5k will be ready to build on your facility in no time. Then, don't forget to replace your openai_key in MindMap.py.

python MindMap.py

Citation

If you find this paper interesting, please consider cite it through

@article{wen2023mindmap,
  title={MindMap: Knowledge Graph Prompting Sparks Graph of Thoughts in Large Language Models},
  author={Wen, Yilin and Wang, Zifeng and Sun, Jimeng},
  journal={arXiv preprint arXiv:2308.09729},
  year={2023}
}

mindmap's People

Contributors

wyl-willing 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.