Skip to Main Content
Exploring Graphs with Elixir
book

Exploring Graphs with Elixir

by Tony Hammond
November 2022
Intermediate to advanced content levelIntermediate to advanced
294 pages
5h 58m
English
Pragmatic Bookshelf
Content preview from Exploring Graphs with Elixir

Building an RDF Graph

We’ll switch gears here and see how we can build up an RDF graph using RDF.ex rather than writing out the RDF explicitly as in the examples we just saw.

One of the challenges to working with RDF is managing URI strings. We’ll need to deal with node names ourselves (for instance data) as these will generally use application-specific naming. But for edges and node labels, we don’t want to be dealing with URI strings every time we add a property or a class name.

We can use one particular aspect of RDF.ex—its support for RDF vocabularies. This will abstract away the URI strings.

Let’s see how we might do this.

Adding a SCHEMA Vocabulary for Schema.org Terms

We could generate a set of example terms as used in the previous ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Concurrent Data Processing in Elixir

Concurrent Data Processing in Elixir

Svilen Gospodinov

Publisher Resources

ISBN: 9798888650059Errata Page