A framework that aims to achieve interoperability between software such as simulation engines, databases and data repositories using a knowledge graph as the common language.
Possibility to import and export triples with predicates which are object properties and point to IRIs that do not belong to any class or belong to a class that is not defined on the ontology #806
When using the import_file and export_file methods, if an RDF triple has an ontology relationship as predicate, SimPhoNy checks that both the subject and the object of such triple refer to a valid ontology individual, that is, that an additional triple defining their types exist. When this is not the case, SimPhoNy omits the triple (on export, unless the whole session is being exported). In some use cases, importing and exporting those triples may be needed. This PR adds an additional all_triples argument to both methods to enable that. In addition, also an argument all_triples has been added to the add method of the Session class so that this behaviour is also possible when copying individuals between sessions.
When using the
import_file
andexport_file
methods, if an RDF triple has an ontology relationship as predicate, SimPhoNy checks that both the subject and the object of such triple refer to a valid ontology individual, that is, that an additional triple defining their types exist. When this is not the case, SimPhoNy omits the triple (on export, unless the whole session is being exported). In some use cases, importing and exporting those triples may be needed. This PR adds an additionalall_triples
argument to both methods to enable that. In addition, also an argumentall_triples
has been added to theadd
method of theSession
class so that this behaviour is also possible when copying individuals between sessions.