orey / csv2rdf

CSV to RDF semantic converter
GNU General Public License v3.0
0 stars 0 forks source link
grammar rdf rdf-converter semantic semantic-parser

CSV To RDF Converter

This program is a utility to transform CSV files into RDF files. It has 2 modes:

Usage

$ csv2rdf -o [OPTIONS.ini] [-v]

Options:

Sample of option file

[./tests/test1.csv]
domain = https://www.example.com/rdf/design#
type = ConfigurationItem
predicate_prefix = CI_
delimiter = ;

[./tests/test2.csv]
domain = https://www.example.com/rdf/design#
type = ConfigurationItem
predicate_prefix = CI_
delimiter = ;
semantics = ./tests/semantics.csv

CSV To RDF Comments

Comments about the semantic parser

Vocabulary hypothesis: triples are decomposed in subject, predicate, object. Subjects and objects are roles that can be endorsed by URIRefs or Literal or blank nodes.

Despite the fact that there may be lists in some fields, we'll try not to use any blank node concept.

Principle

Principle

Translation in semantic web

Here is a sample of interpretation that wa can have reading a CSV file.

The table is containing lines of ConceptName:

1. Li a ConceptName .

Depending on the value in the cell, if the value is an object:

2. Cij a Kj .
3. Cij Kj Li .
or
3. Li Kj Cij .

If the value oi the cell is a web semantic value:

3. Li kJ Cij .

(Cij does not have a type).

Grammar

The semantic parser works with a semantic simplistic grammar. The idea of this grammar is to identify how the 3 following informations should be dealt with:

The grammar proposes the following semantic:

Examples:

Note: the parser eliminates UTF8 errors.


See also: