RDF JavaScript Libraries

Specifications

Data Model

Basic RDF Data Model (Terms & Quads)

Dataset

Dataset extending the basic Data Model

Streams

Quad stream processing

Query

Query execution in RDF

Documentation

RDF + JS = ❤

A website that documents, demos and reviews a selection of JavaScript libraries and how they can be used to manage RDF graphs

Libraries

@rdfjs/data-model

Basic implementation of RDFJS Data Model.

DataFactory
@rdfjs/dataset

Basic implementation of RDFJS Dataset.

DatasetCore DatasetCoreFactory
n3

Lightning fast, spec-compatible, streaming RDF for JavaScript.

DataFactory Sink
quadstore

An embedded and persistent graph database for JS runtimes (incl. browsers) supporting SPARQL queries and RDF/JS interfaces

Store Sink Source
graphy

A collection of RDF libraries for JavaScript developers with a focus on performance and usability.

DataFactory Dataset Source Sink
Comunica

Comunica is a highly modular and flexible meta query engine for the Web.

DataFactory Source
JSON-LD Streaming parser

A fast and lightweight streaming JSON-LD parser for JavaScript.

DataFactory Sink
RDF/XML Streaming parser

A highly efficient streaming RDF/XML parser.

DataFactory Sink
JSON-LD context parser

A generic JSON-LD context parser.

DataFactory
RDF Test Suite

Executes the RDF and SPARQL test suites.

DataFactory
RDF Isomorphic

Determines if two RDF graphs are isomorphic.

DataFactory
GraphQL to SPARQL

Converts GraphQL queries to SPARQL queries.

DataFactory
Jest RDF

Jest utilities for RDF(JS)

DataFactory
RDF Object

Loads RDF as JSON objects.

DataFactory
LDflex

A JavaScript DSL for querying Linked Data on the Web

DataFactory
Fetch SPARQL endpoint

A simple, lightweight module to send queries to SPARQL endpoints and retrieve their results in a streaming fashion.

DataFactory
SPARQL/XML Parser

Parses SPARQL XML query results.

DataFactory Sink
SPARQL/JSON Parser

Parses SPARQL JSON query results.

DataFactory Sink
RDF Quad

A convenience constructor for RDF quads.

DataFactory
RDF String

Convenience functions for creating and serializing RDF terms and quads.

DataFactory
rdflib.js

Javascript RDF library for browsers and Node.js.

DataFactory
SPARQLAlgebra.js

SPARQL to SPARQL Algebra converter.

DataFactory
RDF Store Stream

Create an RDF store from an RDF stream.

DataFactory Source
JSON-LD Streaming Serializer

A fast and lightweight streaming JSON-LD serializer for JavaScript.

DataFactory Stream
RDFa Streaming Parser

A fast and lightweight streaming RDFa parser for JavaScript.

DataFactory Sink
Microdata to RDF Streaming Parser

A fast and lightweight streaming Microdata to RDF parser for JavaScript.

DataFactory Sink
RDF Parse

Parses RDF from any serialization.

DataFactory Sink
RDF Literal

Translates between RDF literals and JavaScript primitives

DataFactory
RDF Dereference

Dereference any URL for its RDF contents

DataFactory Sink
@tpluscode/rdf-string

The easiet way possible to stringify RDF/JS terms

Dataset
@tpluscode/rdf-ns-builders

Wrappers of @rdfjs/namespace for common vocabularies. Includes Typescript declarations of vocabulary terms extracted from their respective sources

DataFactory
@tpluscode/sparql-builder

A high level API to simply the construction of SPARQL queries

DataFactory
@ontologies/core

An RDF data factory for using ontologies in your JS projects

DataFactory
@rdf-esm/formats-common

A browser-friendly set of sinks (parsers and serializers) for common RDF formats

Sink
@rdfjs-elements/formats-pretty

A browser-friendly set of sinks, with serializers optimized for pretty output

Sink
@rdfjs-elements

Web components for editing RDF

clownface

High level graph traversal library

clownface-shacl-path

Work with SHACL Property Paths using clownface

webpack-loader-rdf

Bundle RDF documents statically using webpack, without requiring parsers in runtime

DataFactory
LINCD

Library & registry for UI components tied to SHACL shapes, with automatic data validation

DataFactory
express-rdf-request

Express middleware for working with RDF payloads using clownface

express-middleware-shacl

Express middleware for validating RDF payloads with SHACL

grapoi

Grapoi is a JavaScript graph traversal library inspired by Gremlin. It allows querying RDF/JS Datasets readable and intuitive way. Grapoi makes processing RDF data in JavaScript fun again.

housemd

Contains an RDF dataset about people, places, and events of the TV series House.

rdf-ext

RDF-Ext is a JavaScript library that extends the RDF/JS specs to handle RDF data in a developer-friendly way.

DataFactory DatasetCoreFactory Sink Stream
rdf-sparql-builder

rdf-sparql-builder helps building SPARQL queries in JavaScript code. Instead of error-prone string concatenations, method chaining allows writing queries without switching the programming language. The RDF/JS data model is used for terms like named nodes and variables.

shacl-engine

A fast SHACL engine for data provided as RDF/JS objects.

@rdfjs/environment

This package provides a flexible RDF/JS factory. The Environment class takes one or more RDF/JS factory classes and creates a new, merged instance. All factory methods will use the Environment instance as factory to create new object instances. Clones can be created to manipulate an instance isolated from other instances.

@rdfjs/express-handler

The @rdfjs/express-handler middleware provides methods to parse incoming RDF data from request with content like POST or PUT requests. It also provides methods to serialize outgoing RDF data.

Stream
@rdfjs/fetch

Wrapper for fetch to simplify sending and retrieving RDF data.

Stream
@rdfjs/fetch-lite

Wrapper for fetch to simplify sending and retrieving RDF data. This is a light version of the @rdfjs/fetch package, without the @rdfjs/formats-common dependency. It is useful when you want to make a build for the browser with a reduced set of parsers and serializers.

Stream
@rdfjs/formats-common

This module bundles parsers and serializers for the most common RDF formats. Instances of SinkMap are used to handle different media types.

Sink Stream
@rdfjs/namespace

Named Node builder.

@rdfjs/normalize

RDF Dataset Normalization as described in the spec from the Credentials W3C community group. Subtitle is "A Standard RDF Dataset Normalization Algorithm".

@rdfjs/parser-jsonld

JSON-LD parser that implements the RDF/JS Sink interface using jsonld-streaming-parser.

Sink Stream
@rdfjs/parser-n3

N3 parser which implements the RDF/JS Sink interface using the N3.js library.

Sink Stream
@rdfjs/prefix-map

A Map for RDF/JS prefixes. This package implements the JavaScript Map interface for RDF prefixes. Key-Value pairs are stored with the prefix as the key as a string and the namespaces as the value in an RDF/JS NamedNode object. There are some additional convenience methods to handle CURIEs and prefix events of RDF/JS Quad streams.

@rdfjs/score

Scores RDF/JS terms inside a dataset

@rdfjs/serializer-jsonld

JSON-LD serializer that implements the RDF/JS Sink interface.

Sink Stream
@rdfjs/serializer-jsonld-ext

JSON-LD serializer that implements the RDF/JS Sink interface and supports different output styles. This package handles the stream processing and uses jsonld.js for the actual serialization process.

Sink Stream
@rdfjs/serializer-ntriples

N-Triples serializer that implements the RDF/JS Sink interface.

@rdfjs/serializer-rdfjs

RDF/JS JavaScript code serializer that implements the RDF/JS Sink interface. It serializes the given quads to a JavaScript module that exports a single function. The created function will return an array of the re-created quads.

Sink Stream
@rdfjs/serializer-turtle

A Turtle serializer that implements the RDF/JS Sink interface. It serializes the given quads to a pretty-printed Turtle string.

Sink Stream
@rdfjs/sink

Abstract RDF/JS Sink interface implementation.

Sink
@rdfjs/sink-map

Map for RDF/JS Sink including shortcut methods.

@rdfjs/sink-to-duplex

Creates a duplex wrapper for RDF/JS Sink. With the duplex wrapper it's possible to use a RDF/JS Sink like a Node.js duplex stream with a Readable and Writable interface.

Stream
@rdfjs/term-map

A Map for RDF/JS Terms keys. This package implements the JavaScript Map interface exclusively for RDF/JS Terms keys and treats Terms with the same N-Triples representation as they are the same object.

@rdfjs/term-set

A Set for RDF/JS Terms. This package implements the JavaScript Set interface exclusively for RDF/JS Terms and treats Terms with the same N-Triples representation as they are the same object.

@rdfjs/to-ntriples

Converts RDF/JS Terms, Quads and Datasets to N-Triple strings.

@rdfjs/traverser

This package provides a generic traverser for RDF/JS Datasets.

@rdfjs/tree

A tree structure for a set of RDF/JS Quads.

LDkit

Linked Data object graph mapping toolkit with end-to-end TypeScript support.

DataFactory
mocha-chai-rdf

Helpers to simplify testing code which uses RDF/JS data models.

eslint-plugin-rdf

Linting rules for RDF/JS projects