Skip to content

Commit

Permalink
version 1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
dachafra committed Mar 12, 2020
1 parent d4eefd4 commit da771b9
Show file tree
Hide file tree
Showing 121 changed files with 358,554 additions and 0 deletions.
18 changes: 18 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
FROM ubuntu:18.04

RUN apt-get update && apt-get install -y openjdk-8-jdk nano less git maven bc
RUN mkdir /morphcsv
RUN mkdir /results
RUN mkdir /data
RUN mkdir /mappings
RUN mkdir /morphcsv/queries
RUN mkdir /morphcsv/output
COPY . /morphcsv

RUN cd /morphcsv && mvn clean compile assembly:single && cp target/morph-csv-1.0-jar-with-dependencies.jar morph-csv.jar

RUN cp /morphcsv/run.sh /run.sh
RUN cp /morphcsv/evaluate.sh /evaluate.sh
RUN cp /morphcsv/config.json /config.json

CMD ["tail", "-f", "/dev/null"]
32 changes: 32 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Morph-CSV
## How to enhance OBDA query-translation over Tabular Open Data?

Use CSVW annotations and RML FnO mappings (following YARRRML spec) to generate R2RML mappings and an enriched RDB to enhance OBDA query translation over Tabular Open Data (CSV) files. This framework can be embedded in the top of any R2RML-compliant engine.

- Docker image: https://hub.docker.com/r/dchaves1/morph-csv

### How it works?
![Morph-csv workflow](figures/morphcsv.png?raw=true "Morph-CSV workflow")

## How to run it?
Using the example of our last tutorial at ESWC2019 - Virtual Knowledge Graph Generation (https://tutorials.oeg-upm.net/vkg2019/)
```bash
git clone https://github.com/oeg-upm/vkg-tutorial-eswc2019
cd vkg-tutorial-eswc2019/morph-csv
docker-compose up -d
cd run-scripts
./run-XXX
```


## Examples:
At the evaluation folder you find original data, mappings, queries and results of 4 examples:
- Comments and persons (at motivating-example folder)
- Linking Open City data (at open-city-data-validation folder)
- Virtual Bio2RDF (at bio2rdf folder)
- Performance over GTFS transport data (at transport-performance folder)

## Publications:
- David Chaves-Fraga, Freddy Priyatna, Idafen Santana-Pérez and Oscar Corcho “Virtual Statistics Knowledge Graph Generation from CSV files”. In:Emerging Topics in Semantic Technologies: ISWC2018 Satellite Events. Vol. 36. Studies on the Semantic Web. IOS Press,2018, pp. 235–244 [Online Version](https://www.researchgate.net/publication/328118582_Virtual_Statistics_Knowledge_Graph_Generation_from_CSV_files)
- Oscar Corcho, Freddy Priyatna, David Chaves-Fraga: "Towards a New Generation of Ontology Based Data Access". In: Semantic Web Journal, 2019. [Preprint version](http://www.semantic-web-journal.net/content/towards-new-generation-ontology-based-data-access)
- Ana Iglesias-Molina, David Chaves-Fraga, Freddy Priyatna, Oscar Corcho: "Enhancing the Maintainability of the Bio2RDF project Using Declarative Mappings". In: 12th International Semantic Web Applications and Tools for Health Care and Life Sciences Conference, 2019.
8 changes: 8 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: "2.0"
services:
morph-csv:
image: dchaves1/morph-csv:1.1
container_name: morphcsv
volumes:
- ./configs:/morphcsv/configs
- ./output:/morphcsv/output
9 changes: 9 additions & 0 deletions evaluation/bio2rdf/config/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"sources":[
{
"csvw":"https://raw.githubusercontent.com/oeg-upm/morph-csv/master/evaluation/bio2rdf/mappings/bio2rdf.csvw.json",
"yarrrml": "https://raw.githubusercontent.com/oeg-upm/morph-csv/master/evaluation/bio2rdf/mappings/bio2rdf.yml",
"db": "bio2rdf"
}
]
}
9 changes: 9 additions & 0 deletions evaluation/bio2rdf/config/config2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"sources":[
{
"csvw":"./evaluation/bio2rdf/mappings/taxonomy.csvw.json",
"yarrrml": "./evaluation/bio2rdf/mappings/bio2rdf.yml",
"db": "bio2rdf"
}
]
}
39 changes: 39 additions & 0 deletions evaluation/bio2rdf/data/homologene/TMhomologene.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
prefixes:
rr: http://www.w3.org/ns/r2rml#
rml: http://semweb.mmlab.be/ns/rml#
ql: http://semweb.mmlab.be/ns/ql#
rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
rdfs: http://www.w3.org/2000/01/rdf-schema#
owl: http://www.w3.org/2002/07/owl#
dcterms: http://purl.org/dc/terms/
xsd: http://www.w3.org/2001/XMLSchema#
fno: http://w3id.org/function/ontology#
sql: http://dchaves.oeg-upm.net/resources/function/sql.ttl#
bv: http://bio2rdf.org/bio2rdf_vocabulary:
homogv: http://bio2rdf.org/homologene_vocabulary:

mappings:
TMhomologene1:
sources:
access: ftp://ftp.ncbi.nih.gov/pub/HomoloGene/current/homologene.data
referenceFormulation: csv
s: http://bio2rdf.org/homologene:$(hid)
po:
- [rdf:type, homogv:Resource]
- [rdf:type, homogv:Homologene-Group]
- [rdfs:label, homologene group $(hid) [homologene:$(hid)]]
- [dcterms:title, homologene group $(hid)]
- [dcterms:identifier, [homologene:$(hid)]]
- p: homogv:x-ncbigene
o:
mapping: TMncbigene-gene_info1
condition:
function: equal
parameters:
- [str1, ncbigene]
- [str2, GeneID]
- [homogv:gene-symbol, $(genesymbol)]
- [homogv:x-gi, gi:$(gi)]
- [homogv:x-refseq, refseq:$(refseq)]


Loading

0 comments on commit da771b9

Please sign in to comment.