Skip to content

Extrapolating knowledge graphs from unstructured text using GPT-3 🕵️‍♂️

License

Notifications You must be signed in to change notification settings

KlausSchaefersAtWork/GraphGPT

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GraphGPT

Natural Language → Knowledge Graph

demo

GraphGPT converts unstructured natural language into a knowledge graph. Pass in the synopsis of your favorite movie, a passage from a confusing Wikipedia page, or transcript from a video to generate a graph visualization of entities and their relationships.

Successive queries can update the existing state of the graph or create an entirely new structure. For example, updating the current state could involve injecting new information through nodes and edges or changing the color of certain nodes.

The current few-shot prompt guides GPT-3 in accurately understanding the JSON formatting GraphGPT requires for proper rendering. You can see the entire prompt in public/prompts/main.prompt. A major issue at the moment is latency. Due to the nature of OpenAI API calls, it takes up to 20 seconds to receive a response.

Setup

  1. Run npm install to download required dependencies (currently just react-graph-vis).
  2. Enter your OPENAI_API_KEY in src/App.js.
  3. Run npm run start. GraphGPT should open up in a new browser tab.

About

Extrapolating knowledge graphs from unstructured text using GPT-3 🕵️‍♂️

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 54.8%
  • CSS 28.9%
  • HTML 16.3%