Skip to content

Instantly share code, notes, and snippets.

@blokhin
Last active November 27, 2015 21:46
Show Gist options
  • Select an option

  • Save blokhin/8b5cb2ea1f0fcfc101d2 to your computer and use it in GitHub Desktop.

Select an option

Save blokhin/8b5cb2ea1f0fcfc101d2 to your computer and use it in GitHub Desktop.
Semantic Web Technologies on an Example of Family Trees
import rdflib
from RDFClosure import DeductiveClosure, OWLRL_Extension
g = rdflib.Graph()
g.parse("tsar_family.ttl", format="turtle")
DeductiveClosure(OWLRL_Extension).expand(g)
print g.serialize(format="turtle")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment