250 likes | 371 Views
OWL imports Nick Drummond. or “How to make life hard for tool developers”. Overview. Why Modularise? Example of a Modular Ontology Modularisation in OWL Importing in ProtegeOWL Problems with owl:imports Other uses of owl:imports. Why Modularise?.
E N D
OWL importsNick Drummond or “How to make life hard for tool developers”
Overview • Why Modularise? • Example of a Modular Ontology • Modularisation in OWL • Importing in ProtegeOWL • Problems with owl:imports • Other uses of owl:imports
Why Modularise? “We’re rubbish at producing this – we just don’t have the resources”
Why Modularise? “My ontology is HUGE” “The tools are going REALLY slowly” “I can’t find anything”
Why Modularise? “It’s easier to work on bits” “Some parts can be developed independently of the others” “We can control authorship more easily”
Why Modularise? • Distribution of effort (get someone else to build it for you) • Modularity (simplify/cognitive capacity) • Scalability (Tool/Reasoner Performance) • Control over what is published and how it is distributed (private/public access)
Top ontology Domain ontology Utility ontologies (time, geospatial etc) Annotations/metadata ontology (dublin core etc) Biological processes Example of a Modular Ontology Test ontologies
Modules can be… • “Packets” of related concepts • Tidy subtrees in your ontology • Grouped by Semantic Similarity • Engineering artefacts • Useful pieces like tests, annotations that may or may not be useful to all users • Layers of Complexity (or detail)
OWL mechanisms • owl:imports <owl:Ontology rdf:about="“> <owl:imports rdf:resource="http://someUrl.com/amino-acid.owl"/> </owl:Ontology> • external resources<rdf:Description rdf:about=" http://someUrl.com/amino-acid.owl#T"/> • namespacesxmlns:amino=" http://someUrl.com/amino-acid.owl#"
owl:imports rdf:resource="http://someUrl.com/B.owl" Semantics of owl:imports http://someUrl.com/A.owl • What semantics? • Most underspecified part of OWL • Just takes all of the axioms (classes, properties, restrictions etc) in an ontology and bungs into the current one • Transitive importing OK (dependencies) • Circular dependencies are valid – issue for the tools rdf:Description rdf:about=" http://someUrl.com/B.owl#ThatClass rdf:Description rdf:about=" http://someUrl.com/B.owl#SomeClass
Namespaces vs imports • In semantic web languages, resources are identified by URI, and their descriptions can be distributed • Namespaces are just a convenient way of adding a common URI prefix to group of resources • The namespace associated with a resource is independent of the ontology or file it is defined in
Finding imports • The name of the imported ontology can be any URI • Even if it is a (resolvable) URL, it does not have to exist in the “expected” location – although this is arguably Best Practice • In theory, publishing ontologies to an appropriate location on the internet solves a lot of problems, but • Not everyone is always connected to the internet • Web sites go down (hopefully temporarily) • When still in the editing phase, it is difficult to “save to the internet”
Importing in Protégé • Useful to distribute “library” ontologies with your ontology • Consider using current folder or a subfolder ./imports
Ontology Repositories • Local Folder • Relative Folder • Absolute Local file • Remote URL
What happens when I change things? • As we’ve said, OWL is semantic web language - so assertions are distributed • How do we control where the axioms go? • Question: add a restriction to imported class What file is this saved in?? • Answer: in Protégé, they always go into the active ontology
Identifying imported classes (!) so:Something does NOT mean imported from so ontology
Other uses of owl:imports “Describing the overlap between two modules”
Problems with not importing • Without importing the ontology it is unclear what is supposed to happen if an external ref is made • How much (if any) of the referred to object should be brought in to the ontology • Classification? • Problems because external ref has no type (this is defined in the “remote” ontology), therefore OWL Full.sometimes the type information can be guessed at by the tools, depending on the surrounding context of the statement, but this should not be relied upon
Problems with owl:imports • Granularity (all or nothing) • Difficult to resolve the location of the imported ontology from its name • Difficult to track where certain statements have been made (an issue?) • Some of these issues may be looked at for the next version of OWL