Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Preliminary support for reasoning over SPARQL query results (#577)
Addresses #569. Based on #564 and #566, so should be merged after those. With this, we can run the following program: ```prolog @import awards :- tsv{ resource=f"https://query.wikidata.org/sparql?query={URIENCODE(?query)}", format=(any, string) }, ?query = """ SELECT ?award ?awardLabel WHERE { wd:Q42 wdt:P166 ?award . ?award rdfs:label ?awardLabel FILTER(LANG(?awardLabel) = "en") } """. @export awards :- csv{resource=""} . ``` This currently yields the following output: ``` [2025-01-04T00:15:11Z INFO nemo::io::formats::dsv::writer] Starting data export ?award,"""?awardLabel""" http://www.wikidata.org/entity/Q906455,"""Ditmar Award@en""" http://www.wikidata.org/entity/Q2687578,"""Inkpot Award@en""" [2025-01-04T00:15:11Z INFO nemo::io::formats::dsv::writer] Finished export: processed 3 tuples (dropped 0) ```
- Loading branch information