From NeOn Wiki


I2OntLogo.png


Click here for a video demo

i2Ont plugin (Invoices to Ontologies)

[[screenshot:=invoice_05.png|

Screenshot
]]

Developed by iSOCO, Víctor Méndez
Review not available
Status not available
Last Update 2009/05/07
Current Version [[current version:= <ask format="template" template="CurrentVersion" limit="1" searchlabel="" sort="version number" order="descending" default="no version available"> 1.x/I2Ont *</ask>]]
Homepage [http://www.neon-toolkit.org/wiki/i2Ont 1.x/I2Ont Website]
Activity
License EPL
Affiliation
NTKVersion 1.2.3

The i2Ont plugin allows the mapping of the relations between the ontology and the invoices.



Contents

Functional Description

This i2Ont plugin manages the mappings between one invoice and the ontology (in this case the PharmaInnova ontology). It creates instances in the ontology that corresponds to invoices and all its fields. So it can transform files from one model format to another using for this purpose different model formats. The main features to highlight are:

  • Management modelling of invoices about ontologies
  • Create invoices as instances of ontology.
  • Conversions between different types of invoices across ontology instances.

These files model the relations between the invoices and the ontology (currently OWL DL). We can perform invoice imports, creating its corresponding instances in the ontology and, also, it can be exported to another invoice formats through other configuration file mappings.

Translation process for invoices

With i2Ont plugin we add the following translation process: The supplier models his invoice with the ontology, and the buyer does the same. Then the supplier can convert his/her invoice into the ontology with his/her mapping config and the buyer converts the instances of the ontology on his/her buyer invoice with his/her buyer mapping config. This is shown in next image:

Translation process for Invoices

Usage Documentation

Installation

Manual Installation

You can install the i2Ont plugin such as other plugins in Eclipse. First of all, you have to download the plugin i2Ont file from the repository. You can download the plugin and help files from the Versions & Compatibility section; if you are using the Neon Toolkit you have to close it. Then unzip the file into the [Neon Toolkit path]. Also you can download the help plugin to have this help in the eclipse menu Help > Help contents .

If you open the Neon Toolkit now you have access to the new I2Ont Views.


Installation from update site

In the NeOn Toolkit, click on: Help > Software updates > Find and Install... . Search for new features for install and create New Remote Site with name=iSOCO and URL=http://www.isoco.com/ontologies/neon/org.neontoolkit.isoco.updateSite/ . Select the iSOCO site created and click on the Finish button. Select the org.neontoolkit.invoice.feature and install it.

GUI

Show views

Go to Window > Show view > Other. This opens the window shown in the next figure and then click on Invoice >Invoice View. Then you can see the new Invoice view forming part of the OWL perspective. Repeat this process with the Attributes View.


Figure 1: Show Views

Components:

This plugin is composed of two views: the Attributes View and the Invoice View. It also adds elements to the toolbar and to the Manager Menu as show in Figure 2:


  • Invoice View: this view shows the information concerning the loaded invoice. You can use drag&drop on the Attributes View to fill the mappings with invoice items.


  • Attributes View: this view shows the information concerning data properties for the concept selected. The information about relationships between items of invoice and data properties is also displayed. Accepts drag & drop from Attributes View.


  • Menus: perform various actions dedicated to the management of the invoice.
Menus actions are grouped by:
Mapping configuration: actions to load I2OntLoadConfig.gif and save I2OntSaveConfig.gif files of mapping configuration (this is available when you made or loaded a configuration before).
Invoice management: load invoice I2OntLoadInvoice.gif in the Invoice View (this is to configure the mappings). Delete I2OntDeleteInvoice.gif, Import I2OntImportInvoice.gif and export I2OntExportInvoice.gif invoices to convert the invoices in different formats.


Figure 2: Views


The import bottom is available when you made or loaded a configuration before. The export and delete invoice/s bottoms are available when you made or load a configuration and you had selected one or more Invoice concepts from an imported invoice in the Individuals View (You choose your Invoice concept when you make a new configuration).


Figure 3: Export and delete invoice/s

First steps

The first thing to do is modelling the invoice to a mapping file. This should load one invoice in the system. Once loaded the screen appears and you can introduce some important data, like a start point project and ontology as well as the Invoice, Header, Body and Summary concepts, Invoice-Header, Invoice-Body and Invoice-Summary relations (these relations have to be a direct relation between the Invoice Concept and the Header, Body and Summary respectively, these fields implement auto-completing: When the user starts to write the fields propose suggestions), the type of the format to be processed (only CSV available), the CSV separator, the date format (it has to comply with the Java date format), the decimal separator and the path of the invoice file that will be loaded (Figure 4):


Figure 4: Loading New Invoice


In case we want to load an invoice and we have one configuration file loaded we will decide whether to keep the current configuration or discard it and start from scratch again:


Figure 5: Configuration exists



Once made these first steps you can begin to carry out the relation mappings. You can select a concept from the ontology;this will load data properties corresponding to this concept. This concept should be reached from the concepts header, body or summary as it will save the linked path in the next steps. In case it does not find this path an indication in Attributes View will be shown.


Figure 6: Paths not found


In the case of finding several paths the user must select the desired one and if only one is found it will be automatically selected and you can proceed with the assignment of mapping.


Figure 7: Path Selection



To realize the mapping between the ontology and the invoice, the user just has to drag&drop an entity of the ontology(Attribute View) to the invoice field (Invoice View). This process is shown in Figure 8.


Figure 8: Mapping filled



Once we have made the mappings you can import the invoices, create the instances in the ontology and you can see them in the Individuals View as you can see in the Figure 3. Moreover, you can export to other formats through other configuration files.

Once we have made our mapping, you should save it in a file with the menu option to be able to upload this mapping anytime again.

You can see the relation mapped for an invoice field by double-clicking the field as you can see in the figure below.


Figure 9: See the relation for a mapped field


Mapping Suggestions

when the cursor mouse is over an invoice field, some suggestions appear for relation mappings at the right of the Invoice View. If you want to select a mapping suggestion:

  • Set the cursor over the desired invoice field.
Figure 10: Mapping suggestions for an invoice field
  • Press shift button and then move the cursor to the suggestions list (otherwise the suggestions list changes to the invoice fields where the cursor pass over).
Figure 11: Press shift button to keep the suggestions list for an invoice field
  • Unpress shift button and double-clik on the desired suggestion to establish the mapping relation. The views are updated automaticaly with the new mapping relation.
Figure 12: Perform the suggestion by double-cliking

Integration with the NeOn toolkit

The following extension points are used within the plugin:


1. Eclipse extension points:

  • org.eclipse.ui.actionSets
  • org.eclipse.ui.views
  • org.eclipse.ui.perspectiveExtensions
  • org.eclipse.ui.popupMenus
  • org.eclipse.ui.viewActions
  • org.eclipse.help.toc


2. NeOn toolkit popup contributions:

  • com.ontoprise.ontostudio.owl.gui.individualview.IndividualViewItem


The Eclipse Selection Service is used by this plugin. The Selection Service which is offered by the NeOn Toolkit architecture. The Selection Service has been chosen in order to interact the plugins and perform actions depending on the item that is transported by the selection service so there is a bidirectional communication between the plugins. In the Invoice plugin the Invoice View only puts items into the Selection Service and the Attributes View only receives items from the Selection Service.

Support

You can report bugs to Víctor Méndez (vmendez@isoco.com).

Intended Use in Case Study

The plugin is part of the invoicing prototype. This is used for annotating the invoices that are sent to a company.