Hi Laura, I would do this:
- consider the .nt as a ttl file - run riot with a base URI - remove the bad lines with grep -v Example: cat relative.ttl <rel> <p> "v" . java -$CP riotcmd.riot --base=http://nogood.net/ /home/jmv/data/TESTS/relative.ttl <http://nogood.net/rel> <http://nogood.net/p> "v" . 2018-04-27 13:10 GMT+02:00 Laura Morales <[email protected]>: > Here's the problem: I'm downloading a few .nt from the Internet and they > contain some bad triples. "Bad" means that they are syntactically correct > but logically incorrect; for example they contain triples with relative > URLs instead of absolute, or maybe they contain an empty subject like this > <>. I don't know if it's possible to ask RIOT to treat these as Warnings > instead of Errors, but if I use RIOT --validate it only reports then as > errors. > Before you say anything, I know that the original sources should be fixed > and that it's not RIOT's job to fix any errors. But I don't really have > control over those graphs, so I was wondering if it's possible to use RIOT > as some sort of filter like this > > 1. read next triple > 2. if logically correct, append to output > if logically incorrect, do not append to output > -- Jean-Marc Vanel http://www.semantic-forms.cc:9111/display?displayuri=http://jmvanel.free.fr/jmv.rdf%23me#subject <http://www.semantic-forms.cc:9111/display?displayuri=http://jmvanel.free.fr/jmv.rdf%23me> Déductions SARL - Consulting, services, training, Rule-based programming, Semantic Web +33 (0)6 89 16 29 52 Twitter: @jmvanel , @jmvanel_fr ; chat: irc://irc.freenode.net#eulergui
