dice-group / dice-group/COPAAL

Enable usage of local file(s) as KB

Open
#11 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
12
Forks
3
PR merge metrics
No merged PRs in 30d

Description

### User story

As a user, I would like to be able to use a (small) local file as reference knowledge base. This is already possible but it would mean that I have to setup a SPARQL endpoint. It would be better if COPAAL could simply load the file.

### Solution

* Change COPAAL so that we can use dependency injection to provide a `QueryExecutionFactory` instance (similar to [this class](https://github.com/dice-group/Squirrel/blob/324a1a320f1a590a2879a209895a76915f6baa45/squirrel.worker/src/main/java/org/dice_research/squirrel/sink/impl/sparql/SparqlBasedSink.java#L73) but without the update part)
* Use the jena library to load the given file(s), add them to a single `Dataset` object and use a dataset-based `QueryExecutionFactory` to SPARQL (similar to [this test implementation](https://github.com/dice-group/Squirrel/blob/master/squirrel.worker/src/test/java/org/dice_research/squirrel/sink/impl/sparql/SparqlBasedSinkTest.java#L34-L36))

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating where COPAAL currently creates or receives its SPARQL QueryExecutionFactory. Read the linked Squirrel SparqlBasedSink and SparqlBasedSinkTest examples, then trace how Jena can load the requested local files into one Dataset. Done means dependency injection supplies a dataset-based factory and local reference files work without a SPARQL endpoint.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend, databases
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.