Getting Started

Install InferaGraph and build your first interactive knowledge graph in minutes.

Installation

Install the core package and your preferred LLM provider.

Core

$ pnpm add @inferagraph/core

LLM Providers (pick one or more)

$ pnpm add @inferagraph/anthropic-provider # Claude
$ pnpm add @inferagraph/openai-provider # GPT
$ pnpm add @inferagraph/azure-foundry-provider # Azure

Peer Dependencies

$ pnpm add react react-dom three

Quick Start

Get up and running with InferaGraph in your framework of choice.

import { InferaGraph } from '@inferagraph/core';
import type { GraphData } from '@inferagraph/core';

const data: GraphData = {
  nodes: [
    { id: 'abraham', attributes: { name: 'Abraham', type: 'person' } },
    { id: 'sarah', attributes: { name: 'Sarah', type: 'person' } },
    { id: 'isaac', attributes: { name: 'Isaac', type: 'person' } },
  ],
  edges: [
    { id: 'e1', sourceId: 'abraham', targetId: 'sarah', attributes: { type: 'husband_of' } },
    { id: 'e2', sourceId: 'abraham', targetId: 'isaac', attributes: { type: 'father_of' } },
  ],
};

function App() {
  return <InferaGraph data={data} layout="graph" />;
}