A Brief User's Guide
A Simple Introduce to RQML
About Orient and EMF
Orient and EMF Integration Demo
Ontology Visualization

A Brief User Guide

The default UI plugin of Orient provides a navigation and editing environment for ontologies formalized in RDF. Users can view information of existing resources, classes, and properties of the underlying model, as well as doing modifications on them. The environment is integrated into the Eclipse Platform. Fig. 1 is a screen snapshot of this UI (Orient V 1.0).

Orient Perspective

fig.1 Overview

A wizard will guide the user to establish an ontology file within the Eclipse workspace. (Fig.2)

fig.2 Wizard

After the wizard is finished, the Orient Perspective will be opened. It will also be automatically opened when the user opens an ontology file. The Orient Perspective contains eight views, namely Resource List, Class List, Property List, Class Hierarchy, Property Hierarchy, Resource Info, Class Info, and Property Info.

The three list views, Resource List, Class List and Property List, show all the existing resources, classes and properties respectively. In these views users could create or delete corresponding objects, and select objects for details in Info views or Hierarchy views.

The two hierarchy views, Class Hierarchy and Property Hierarchy, display the hierarchy tree of classes and properties. Users could shift between showing sub-nodes and showing super-nodes. By the context menu, the user could add/delete child-nodes, set a new focus of the view, or display information of the selected node.

Three information views are used to display detailed information of resource, class and property respectively. In these views users could rename the object, modify the comment, and add/remove entities in the various lists.

Undo/Redo mechanism is provided in the environment, so that users could edit the ontology more conveniently.

RDF inference is also a feature of Orient, which provides two modes of inference, i.e. realtime and non-realtime. In the realtime mode, Orient will do RDF inference whenever the ontology is changed. However, if the ontology is very large, doing inference will be time-consuming, and realtime inference may block the user's editing. In such situation non-realtime mode is desirable, under which Orient will not do inference until the user tells the system to do so.

Orient supports RDF file import/export. An RDF file could be imported to an Orient ontology file, and vice versa. (Fig.3)

fig.3 Import

A Simple Introduction to RQML

  • What is RQML?

    RQML(RDF Query and Manipulation Language) is a SQL like RDF management language. The complete RQML gramma(Non-Terminals) can be found here. RQML is developed from several other RDF quary languages including RDQL and SeRQL. RQML provides lots of powerful query options as well as manipulating commands such as INSERT, DELETE, UPDATE, and RENAME.

  • RQML where clause example

    select ?x where (?x, <rdf:type>, <rdfs:Resource>) sortby ?x descend
    That is, select all resources, sorted by their URI descended.

    select count(?y,?z) where (?x, <!http://test/predicate1>, ?y), (?x, <!http://test/predicate2>, ?z)
    That is, select the quantity of different pairs(?y,?z) such that they have a specified relation with another resource.

  • RQML path clause example

    select ?x, ?y where (?x, <rdf:type>, <!http://test/class1>) path {?x} {<!http://test/predicate1>} {} {<!http://test/predicate2>} {?y}
    That is, select all the distinct pairs of ?x, ?y such that ?x is type of http://test/class1 and ?x have predicate http://test/predicate1 with some resource as the object and that resource have http://test/predicate2 with ?y as the object.

    select ?x path {?x} {<!http://test/predicate1>, <!http://test/predicate2>} {?y} {<!http://test/predicate3>} {"VALUE1"} ; {} {"VALUE2"}
    That is select all ?x such that ?x have a predicate http://test/predicate1 or http://test/predicate2 with some resource ?y as the object and ?y have predicate http://test/predicate3 with a xsd:string typed literal "VALUE1" as the object and ?y have some another predicate with a xsd:string typed literal "VALUE2" as the object.

  • RQML literal evaluation example

    select ?x where (?x, <!http://test/predicate1>, ?y) suchthat ?y > 3
    That is, select all ?x such that ?x have a predicate http://test/predicate1 with a xsd:integer typed literal ?y as the object and the value of ?y is larger than 3.

    select ?x where (?x, <!http://test/predicate1>, ?y) suchthat ?y. > 3
    That is, select all ?x such that ?x have a predicate http://test/predicate1 with a xsd:float typed literal ?y as the object and the value of ?y is larger than 3.

    select ?x where (?x, <!http://test/predicate1>, ?y) suchthat ?y prefix <!http://test>
    That is, select all ?x such that ?x have a predicate http://test/predicate1 with a resource ?y as the object and the URI of ?y have the prefix http://test.

    select ?x where (?x, <!http://test/predicate1>, ?y), (?x <!http://test/predicate2>, ?z) suchthat ?y.>?z. and ?z.>2.5 and (?y.<=6 or ?y.>=8.5)
    That is, select all ?x such that ?x have a predicate http://test/predicate1 with a xsd:float typed literal ?y as the object and have a predicate http://test/predicate2 with a xsd:float typed literal ?z as the object and the value of ?y,?z have the specified limitations.

  • RQML RDF manipulation example

    insert (<!http://test/predicate1>, <rdfs:subPropertyOf>, <!http://test/predicate2>)
    That is, insert a single triple.

    delete * where (?x, <rdf:type>, ?y), (?y, <rdfs:subClassOf>, <!http://test/class1>)
    That is, delete all the triple with the pattern (?x, <rdf:type>, ?y) such that ?y is a subclass of http://test/class1.

    rename <!http://test/class1> to <!http://test/class2>
    That is, rename a certain resource.

About Orient and EMF

  • What is EMF?

EMF (Eclipse Modeling Framework) is an eclipse plugin developed by IBM.
EMF is a modeling framework and code generation facility for building tools and other applications based on a structured data model.
EMF provides the foundation for interoperability with other EMF-based tools and applications.

            To learn more about EMF: http://www.eclipse.org/emf/

  • What is EclipseUML
    A a visual modeling tool, natively integrated with Eclipse. Here we recommend EclipseUML because it supplements EMF with a more user-friendly interface.
    http://www.omondo.com
  • How Orient integrates with EMF?

     With the intention of being a user-friendly ontology engineering environment, Orient provides a synchronization mechanism with EMF models. Users can create and modify an ontology  either in Orient or in any other EMF design environment (such as EclipseUML), and the modifications will be synchronized. All you have to do is to specifiy which Orient model you'd like to synchronize with which EMF models. Orient support 2 directions of synchronization: from Orient to EMF or from EMF to Orient. The following section is a demo of this.

*Note: Synchronization is done only when modifications are saved.

Orient and EMF Integration Demo

    You need install EMF 1.1.1 plugin and EclipseUML 1.2.1.20031103 or 1.2.1.20030806 to run this demo.

  • Initially, our Orient RDF model is empty, and there is an EMF model "library" (see figure 1).
  • Click the "EMF" icon on the Orient Editor tool bar, set the EMF model to be synchronized.
    In this example, we synchronized our Orient model from the "library" EMF model, and then click "OK" button. (see figure 2)
  • Now in the Resource List view, we see the "library" model has been loaded (see figure 3)
  • Then we make some modification of the "library" model via the graphical interface of EclipseUML, say, add a "Book" subclass, class "Fiction". Once the modification is saved by EclipseUML, our Orient model will automatically be synchronized. (see figure 4)
  • Orient also supports synchronization to a target EMF model. In figure 5, there is originally an EMF model--"target"
  • Set "target" model to be the EMF model we'd like to synchronize to (see figure6)
  • Then the target model will be synchronized from our Orient model, whenever our Orient model's change is saved. (see figure7)

Ontology Visualization

OntoViz is an Eclipse plug-in developed on ORIENT system. In OntoViz, we employed a new combine of similarity calculation method to calculate the similarity distance of two class of an ontology. After this, we, arrange these classes as points in a 2D plane according to FDP (Force Direct Placement) algorithm. Then we get a distribution of all the classes, in which two classes have close similarity values were put close to each other.(see figure 8).

Ontoviz

fig.8 Ontology Visualization Overview

In order to show more information about this ontology to user, we display the property information and instance information in the visualization area too. The instance information are rendered as color depth (see figure 9).

instance

fig.9 Property and Instance Information

As it is shown in the above picture.We can get the instance number information of each class by reading the depth of each color easily.From the color of each class, we can detect the "hottest" class in this ontology easily.

© 2005, APEX Lab, Shanghai Jiao Tong University