Summary
The openCAESAR team is currently planning a major revision (v2) of OML that will feature:
Note: you can read about the OML v2 release in May 2023 here.
Syntax Simplifications
Changes to the OML abstract syntax and its Java API that does not impact the textual syntax:
- Merged (and removed) class
AnnotatedElementinto classIdentifiedElement(the impact is thatImportstatements can no longer be annotated). - Collapsed the
Importclass hierarchy into a singleImportclass with an enumeration kind that has literals:extends,uses, andincludes. - Renamed class
FeaturetoProperty, made the latter the supertype of classesAnnotatedPropertyandSemanticProperty, and made classRelationextend fromSemanticProperty. - Collapsed the
Restrictionclass hierarchy into 3 subclasses restricting range, cardinality, or value of a property, and made classEntityhas a single collection for restrictions. - Made class
LinkAssertiona subclass ofPropertyValueAssertionand made classNamedInstancehas a single collection of property value assertions. - Moved the types collection from both classes
ConceptInstanceandRelationInstanceinto their superclassNamedInstance. - Made class
RelationEntityPredicatea subclass of bothUniaryPredicateandBinaryPredicate. - Removed the
Referenceclass hierarchy entirely and merged it into theMemberclass hierarchy (a member can have either a name or a ref to another member).
Syntax Changes
Changes to the OML abstract syntax and its Java API that also impacts the textual syntax:
-
The specialization symbol
:>will be changed into<to better align with the subset symbol (a subclass is a subset of its super class). -
The specialization axiom
(<: superTerm (',' superTerm)*)will now be expressed after the other-details ([..])? of the term, as opposed to before.For example:
concept A < B, C concept D [ key p1 ] < E, F scalar property p1 [ domain C range xsd:string ] < p2 -
The enumerated instances of a
Conceptcan now be specified with the keywordoneOfinstead ofenumerates. For example:concept RockyPlanets [ oneOf Earth, Mars, Venus, Mercury // these are concept instances ] -
Both
FacetedScalarandEnumeratedScalarwere eliminated and merged into a (now concrete)Scalarclass. The enumerated literals can be specified as another facet calledoneOf(along with the other facets likeminLength).For example:
scalar RGBColor <: xsd:string { oneOf "Red", "Green", "Blue" } -
A concept instance is now defined with the intuitive keyword
instanceinstead of the keywordci. It can now be typed by concepts or aspects (instead of concepts only before). -
A relation instance is now defined with the intuitive keyword
relation instanceinstead of the keywordri. It can now be typed by relation entities or aspects (instead of relation entities only before).
New Features
New features to add to the expressivity of OML abstract syntax (and textual syntax):
- Made
Annotationhave either a literal value or a reference (to a member) value. This would allow saying for ex.:@rdfs:label "Aggregates" @rdfs:seeAlso base:Contains relation entity Aggregtes - Added a new class
UnreifiedRelationas a subclass ofRelationand (unlike classesForwardandReverse) it can be declared independently of aRelationEntity. This would allow defining for ex.:relation performs [ // this is an unreified relation from Component to Function reverse isPerformedBy functional ] - Added a new class
BuiltInto represent a builtin function that can be called from aRuleas a predicate. Also, added a the standard vocabulary of SWRL builtins to thecore-vocabulariesset. This should allow saying for ex.rule FullName [ firstName(?x, ?first) ^ lastName(?x, ?last) ^ swrlb:stringConcat(?full, ?first, " ", ?last) -> fullName(?x, ?full) ] -
Added the Ability to add zero or more (comma-separated)
classifier equivalence axiom(s) (intersection of named classifiers and/or restrictions) after an optionalspecialization axiom.Syntax:
Classifier ::= <keyword> NAME (`[`...`]`)? (`<` Specializations)? (`=` Equivalences)? Specializations ::= (REF (`,` REF)*)? (`[` Restriction*`]`)? Equivalences ::= Equivalence (`,` Equivalance)* Equivalence ::= (REF (`&` REF)*)? (`[` Restriction*`]`)For example:
concept SpicyPizza = Pizza [ restricts some hasTopping to SpicyTopping ] aspect A = B & C & D [ restricts p1 to max 1 restricts p2 to exatly 5 P ] concept Z [ key p1 ] = M & N -
Added the Ability to add zero or more (comma-separated)
property equivalence axiom(s) after the optionalspecialization axiom.Syntax:
Property ::= <keyword> NAME (`[`...`]`)? (`<` Specializations)? (`=` Equivalences)? Specializations ::= REF (`,` REF)* Equivalences ::= REF (`,` REF)*For example:
relation hasAunt [ from Person to Woman ] = hasSisterOfParent scalar property p1 [ domain D range xsd:string ] < p2 = p3, p4
Potential Features
Features under consideration that we appreciate your feedback on.
- Add the ability to define nested concept instances with link assertions:
ci c1 : mission:Component [ mission:performs f1 : mission:Function mission:performs f2 : mission:Function [ mission:invokes c1.f1 // or simply f1 ] ] - Add the ability to define multiple (comma-separated) values for a property or link assertion in a description:
ci c1 : mission:Component [ mission:performs f1, f2 base:hasName "123", "abc" ]
Please provide your feedback by posting a discussion thread, or by contacting Maged Elaasar directly.