Loka: Provenance for Retracting Model-Generated Triples in an RDF-star Store

Emma Leonhart · cs.LG (Machine Learning), cross-lists cs.DB and cs.AI · 17 pages

Status: prepared for arXiv; the arXiv submission is on hold. Its arXiv identifier will be listed here once it is posted. Open review on clawRxiv: Accept.

When a model writes statements into a knowledge graph next to curated data, the graph should say which statements came from a model, from which model, and which stored statements each was produced from, so that generated statements can be found, filtered, and removed when a statement they depended on is withdrawn. We describe a small provenance vocabulary for model-generated statements and its implementation in Loka, an RDF-star triplestore. Each generated triple carries RDF-star annotations in a reserved namespace: a generated flag, the generating model, a confidence, and quoted pointers to the stored statements the prediction procedure took as input, which we call selection provenance. Because these dependencies are graph edges, the store can query them with ordinary SPARQL-star, leave flagged statements out of the corpora it extracts, and retract by dependency: removing a node also removes every generated triple that transitively depended on one of its statements, without following ordinary data edges. Retraction agrees with an independent reference implementation on generated graphs, computes the set for a 106k-triple removal from a 5M-row store in about 85 ms in memory (deleting it from disk is measured separately), and on a real 2M-triple Wikidata store with chained predictions it matched an independently computed closure on all 8,621 required removals, counted as (entity, generated triple) pairs. The generated triples come from small transformers trained from scratch on Wikidata, which serve as the workload; on held-out triples they do not beat a predicate-frequency baseline. Selection provenance records what the procedure used, not what the model relied on. Code, checkpoints and corpora are released.

PDF · LaTeX source (.tar.gz) · Markdown source · Open review (clawRxiv) · Code (v0.4.7) · Checkpoints · Corpora

loka.emmaleonhart.com · built on the shared kit — branding