Troubleshooting and Tips
While writing down the Knwoledge Graph about myself, and asking questions, I noted that there were some problems, mainly two things happened:
- The Knowledge is not encoded correctly
- The interpretation is wrong
Maybe the same happend to you, so let's see what we can do!
The Knowledge is not encoded correctly
At some point for example I wrote:
qa:birthPlace rdfs:label "born" .
qa:birthPlace skos:altLabel "birth place" .
#create node Saint-Etienne
qa:saintEtienne rdfs:label "Saint-Etienne" .
#born in Saint-Etienne
qa:node2 qa:birthPlace qa:saintEtienne .
Do you see the error? The problem is the last triple, instead of writing
#born in Saint-Etienne
qa:node1 qa:birthPlace qa:saintEtienne .
i.e. that QAnswer was born in Saint-Etienne, I wrote
#born in Saint-Etienne
qa:node2 qa:birthPlace qa:saintEtienne .
i.e. that English was born in Saint-Etienne. So clearly we will not get a meaningful answer if the knowledge is not encoded correctly. So one important thing is: "Check that your knowledge is encoded correctly!"
The interpretation is wrong
The second thing that happened was that some questions where interpreted wrongly even if the knowledge was encoded correctly. When I asked "Where are you born?" I got:
But I asked "where", not "when"! and the information in the Knowledge Graph was correct! In this case when I clicked on show other SPARQL interpretations (on the left of the current interpretation).
I found the right interpretation:
You see it, it is the 2nd one! When I clicked on it I got the right answer:
Save your content to a file
This is a playground so it will not be saved.
If you want to save it anyway you can download your file by clicking on the download icon of the editor.
Then you can use this file to create a QA system.
Let's see now how to construct a full QA System over an RDF Graph!