drobilla / serd

A lightweight C library for RDF syntax
https://gitlab.com/drobilla/serd
ISC License
86 stars 15 forks source link
nquads ntriples parser rdf semantic-web serializer turtle

Serd

Serd is a lightweight C library for working with RDF data.

Serd can be used by high-performance or resource-limited applications to read or write Turtle, TriG, NTriples, and NQuads. The included serdi tool can be used to efficiently process RDF documents in scripts or on the command-line.

Features

Performance

The benchmarks below compare serdi, rapper, and riot re-serialising Turtle data generated by sp2b on an AMD 1950x. Of the three, serdi is the fastest by a wide margin, and the only one that uses a constant amount of memory for all input sizes.

Throughput Time Memory

Documentation

Versioning

Serd uses strict semantic versioning, which reflects the ABI of the C library. The shared library name, include directory, and pkg-config file are all suffixed with the major version number to allow for parallel installation of several major versions (which distribution packages should preserve). To build against serd, use the pkg-config package serd-0:

pkg-config --cflags --libs serd-0

-- David Robillard d@drobilla.net