comunica / comunica-feature-link-traversal

📬 Comunica packages for link traversal-based query execution
Other
8 stars 11 forks source link

Prioritize certain traversal paths with content policies #46

Open rubensworks opened 2 years ago

rubensworks commented 2 years ago

Issue type:


Description:

For the following query, the query engine could somehow make use of prior knowledge that movie and watch data exists in the same file:

https://comunica.github.io/comunica-feature-link-traversal-web-clients/builds/solid-default/#datasources=https%3A%2F%2Fdrive.verborgh.org%2Fmovies%2F&query=PREFIX%20schema%3A%20%3Chttps%3A%2F%2Fschema.org%2F%3E%0ASELECT%20*%20WHERE%20%7B%0A%20%20%3Fmovie%20a%20schema%3AMovie.%0A%20%20%3Faction%20a%20schema%3AWatchAction%3B%0A%20%20%20%20%20%20%20%20%20%20schema%3Aobject%20%3Fmovie.%0A%7D&solidIdp=https%3A%2F%2Fdrive.verborgh.org%2F

This prior knowledge could be captured in content policies, which could either be predefined (e.g. via shapetrees), or learned dynamically via prior query executions. The next step is then to incorporate these content policies during query execution, for both prioritization and discovery.


One concrete use case is the prioritization of type index links over others, which could be useful for this query: https://comunica.github.io/comunica-feature-link-traversal-web-clients/builds/solid-default/#transientDatasources=https%3A%2F%2Frubensworks.solidcommunity.net%2Fprofile%2Fcard&query=PREFIX%20bookm%3A%20%3Chttp%3A%2F%2Fwww.w3.org%2F2002%2F01%2Fbookmark%23%3E%0ASELECT%20*%20WHERE%20%7B%0A%20%20%3Fbookmark%20a%20bookm%3ABookmark%3B%0A%20%20%20%20bookm%3AhasTopic%20%3Ftopic.%0A%7D

github-actions[bot] commented 2 years ago

Thanks for the suggestion!

rubensworks commented 1 year ago

At the time of writing, the query doesn't work anymore due to a change in the underlying dataset.