INCATools / semantic-sql

SQL and SQLite builds of OWL ontologies
https://incatools.github.io/semantic-sql/
BSD 3-Clause "New" or "Revised" License
36 stars 3 forks source link

Make semsql prefix maps configurable #51

Open matentzn opened 1 year ago

cmungall commented 1 year ago

We definitely want to do this, in addition to using any shacl triple namespace declarations in the file itself

Currently this is a bit awkward as everything is coordinated via a Makefile

Our options are:

  1. add some parameterization to the Makefile, and pass this via the calling script
  2. bite the bullet and do #41 now, or at least switching out the rdftab part, which will make all this easier
cmungall commented 1 year ago

If we wanted to go with (1) here is the relevant section of the Makefile:

https://github.com/INCATools/semantic-sql/blob/36a3d83d626280f594ad0c19f56cc544887bfc99/src/semsql/builder/build.Makefile#L45-L56

You need to load the additional prefixes into the prefix table prior to calling rdftab, as rdftab takes care of contracting the URIs

But from our discussion on slack, it seems this is less of a priority as we will just merge the prefixes you need in to curated_prefixes

cmungall commented 1 year ago

but it's looking like direct loading with https://github.com/ozekik/lightrdf is easiest

cmungall commented 1 year ago

now possible with:

semsql make foo.db --prefix-csv-path /path/to/my/prefixes.csv

caveat: you must make sure ALL prefixes are in the csv, including owl, rdf, xsd, etc

the next release of oak will make this more transparent when querying owl via the sql adapter