Integrating Web Ontology Language with Neo4j through the neosemantics (n10s) framework enables semantic validation and automated reasoning that are not natively supported by Labeled Property Graphs. However, the choice of graph refactoring pattern influences query performance. This study compares two ontology-based graph refactoring approaches, namely Property-to-Label (P2L) and Property-to-Node (P2N), implemented in Protégé and integrated into Neo4j using n10s and Owlready2. Both models were evaluated for semantic validation and ontology reasoning using the PET ontology, while their query execution performance was benchmarked using 78 Cypher query variants derived from the IMDB dataset. The evaluation examined the relationship between execution time and reductions in WHERE clauses following schema refactoring. The results show that both approaches successfully enforce ontology constraints and infer missing classifications from incomplete data. Performance analysis indicates that both P2L and P2N improved query execution time, with the highest reduction percentage was 89% for queries with four total number of the WHERE. P2L exhibited a more consistent relationship between WHERE clause reduction and execution time improvement due to Neo4j's native label indexing.
No takes yet. Share an insight, caveat, or question.
Hodijah et al. (2026) studied this question.
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: