How to import a batch of SWRL rules into an OWL ontology without manually importing them one by one?

70 Views Asked by At

I am currently working on creating Ontology (OWL) files for my project, and I need to specify a large set of SWRL rules (more than 100).

In my current understanding, importing these rules one by one is the only way to do it in the Protege program. However, I am wondering if there is a method to import a batch of SWRL rules into my ontology, bypassing the need to import each rule individually.

I am open to using other programs besides Protege, as long as they offer the functionality to import SWRL rules in bulk.

1

There are 1 best solutions below

0
Chris Mungall On

You can do this using the ROBOT command line tool using the merge operation. For example:

robot merge -i my-ontology.owl -i my-rules.swrl -o combined.owl

The .owl and .swrl files can be any OWL syntax that supports SWRL.