https://github.com/treecg/tree-guided-link-traversal-query-processing-evaluation
https://github.com/treecg/tree-guided-link-traversal-query-processing-evaluation
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/treecg/tree-guided-link-traversal-query-processing-evaluation
- Owner: TREEcg
- Created: 2023-03-06T14:45:39.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-07-04T06:24:57.000Z (10 months ago)
- Last Synced: 2025-02-03T08:36:47.223Z (3 months ago)
- Language: JavaScript
- Size: 47.4 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# TREE-Guided-Link-Traversal-Query-Processing-Evaluation
## Dependencies
- [Nodejs 18 or higher](https://nodejs.org/en)
- [Rust](https://www.rust-lang.org/fr)## Prepare the data
**Warning: Do not forget to clone the submodule**
### Clone the submodule
```zsh
git submodule init
git submodule update
```or
```zsh
git clone --recurse-submodules -j8 {address of the repo}
```### Generate fragments
```zsh
./run_evaluation.sh install-comunica
yarn install
./run_evaluation.sh install-injestor
./run_evaluation.sh download-dataset
```
to generate the fragmentation with 100 nodes
```zsh
./run_evaluation.sh dahcc-1-participant-one-ary-tree-100 --server
```
to generate the fragmentation with 1000 nodes
```zsh
./run_evaluation.sh dahcc-1-participant-one-ary-tree-1000 --server
```## Queries
Q1
```sparql
PREFIX sosa:
PREFIX xsd:
PREFIX wgs:
PREFIX etsi:
SELECT * WHERE {
?s etsi:hasTimestamp ?t.
?s etsi:hasValue ?result.
?s etsi:measurementMadeBy ?sensor.
?sensor ?stateOf.
?sensorFILTER(?t="2022-01-03T10:57:54.000000"^^xsd:dateTime)
}
```Q2
```sparql
PREFIX sosa:
PREFIX xsd:
PREFIX wgs:
PREFIX etsi:
SELECT * WHERE {
?s etsi:hasTimestamp ?t.
?s etsi:hasValue ?result.
?s etsi:measurementMadeBy ?sensor.
?sensor ?stateOf.
?sensorFILTER(?t="2022-01-03T19:54:22.469000"^^xsd:dateTime)
}
```Q3
```sparql
PREFIX sosa:
PREFIX xsd:
PREFIX wgs:
PREFIX etsi:
SELECT * WHERE {
?s etsi:hasTimestamp ?t.
?s etsi:hasValue ?result.
?s etsi:measurementMadeBy ?sensor.
?sensor ?stateOf.
?sensorFILTER(?t>="2022-01-03T15:00:00.000000"^^xsd:dateTime && ?t<"2022-01-03T15:30:00.000000"^^xsd:dateTime)
}
```Q4
```sparql
PREFIX sosa:
PREFIX xsd:
PREFIX wgs:
PREFIX etsi:
SELECT * WHERE {
?s etsi:hasTimestamp ?t.
?s etsi:hasValue ?result.
?s etsi:measurementMadeBy ?sensor.
?sensor ?stateOf.
?sensorFILTER((?t>="2022-01-03T15:00:00.000000"^^xsd:dateTime && ?t<"2022-01-03T20:00:00.000000"^^xsd:dateTime) && !(?t>="2022-01-03T15:10:00.000000"^^xsd:dateTime && ?t<"2022-01-03T15:40:00.000000"^^xsd:dateTime))
}
```## Run the queries
To run the queries you have to run the following command schema.
```zsh
node comunica_runner.mjs -f ./evaluation/query/{}.ttl -m {TREE-GUIDED|TREE} -r http://localhost:8080/0.ttl -d http://localhost:8080/metadata.ttl
```
For example```zsh
node comunica_runner.mjs -f ./evaluation/query/Q2.ttl -m TREE-GUIDED -r http://localhost:8080/0.ttl -d http://localhost:8080/metadata.ttl
```It will output something like
```json
{"nResults":1,"timeExec":5111.714145,"nRequest":3}
```