Monireh2 / python-rdfs-reasoner

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Python RDFS Reasoner

Given a KG generates step by step inferences and report the inferences of each chain in a different file. It is possible to explore a given inference and to retrieve the chain of axioms that generated that inference. Inference is done with the use of the RDFS entailment axioms

The tool filters out those inferences that are not made by Jena.

Inference

To generate the inferences from the axiom you can use the following command.

python2.7 python_rdfs_reasoner.py -f knowledge_graphs/DAO_2.json

You can also run inferences over a set of files in a folder using the following command.

python run_multi_inference.py -f knowledge_graphs/

Chain Retrieval

To print the chain of relation inferences that generated a given axiom you can use the following command.

python2.7 chain_inferences.py -f debug/debug_saved_graph_inferences -i ":Drug rdfs:subClassOf rdfs:Resource"```

About

License:MIT License


Languages

Language:Python 77.4%Language:Jupyter Notebook 16.3%Language:Makefile 6.4%