ProjetPP / Documentation

Documentation and protocol specification of the Projet Pensées Profondes
Creative Commons Zero v1.0 Universal
7 stars 1 forks source link

Adds the inverse abstract operator and the inverse-predicate attribute to triples #56

Closed Tpt closed 9 years ago

Tpt commented 9 years ago

Does not add any additional power to the DataModel but allows to significantly reduce the tree size.

The name "inverse" is taken from the owl:inverseOf property of OWL.

Closes #52

progval commented 9 years ago

Is inverse-predicate mandatory?

Tpt commented 9 years ago

No, I've just updated the PR to reflect this.

Ezibenroc commented 9 years ago

We should not consider the inverse-predicate as optional: it has exactly the same importance as the predicate.

yhamoudi commented 9 years ago

We should not consider the inverse-predicate as optional: it has exactly the same importance as the predicate.

+1 But how can we do if there is no inverse predicate ?

Ezibenroc commented 9 years ago

+1 But how can we do if there is no inverse predicate ?

And if there is no predicate? (this can also happen)

→We allow empty lists for predicate or reverse-predicate.

yhamoudi commented 9 years ago

And if there is no predicate? (this can also happen)

We could reverse the triple (the inverse predicate becomes the predicate), but it would be better to avoid this (otherwise people may think that predicate is enough and inverse-predicate is totally optional).

yhamoudi commented 9 years ago

Can we add the following text at the end of https://github.com/ProjetPP/Documentation/blob/revers/data-model.md#triple ?

Please note that the previous triple is equivalent to:

{
    "type": "triple",
    "subject": {"type": "missing"},
    "predicate": {"type": "resource", "value": "inhabitant"},
    "inverse-predicate": {"type": "resource", "value": "residence"},
    "object": {"type": "resource", "value": "Barack Obama"}
}
Tpt commented 9 years ago

My own thought is that inverse predicate is a hack done in order to reduce the query tree size when we build them using nounification technique. So, yes, when they are present, they are as "important" as regular predicates but I don't see why it is a reason to make this parameter mandatory as it'll have often an empty value. For example, if I write requests by hand, I don't think I'll often use reverse predicates.

More, I think that simple modules (like OEIS) should be able to answer to most of questions without having to deal with inverse predicates that is more an "advanced feature" for big modules like the Wikidata one.

With the risk of repeating myself: the data model is not only there to be a nice output of NLP-grammatical but is a shared languages for our platform modules and so we shouldn't make there life harder only to simplify the job of NLP-grammatical.


Can we add the following text at the end of https://github.com/ProjetPP/Documentation/blob/revers/data-model.md#triple ?

Yes. But we should maybe add a paragraph after the definition of inverse to give an example of use and explain this equality that is, I think, more readable when explained with the abstract notation than with the serialization.

progval commented 9 years ago

:+1: @Tpt

yhamoudi commented 9 years ago

With the risk of repeating myself: the data model is not only there to be a nice output of NLP-grammatical but is a shared languages for our platform modules and so we shouldn't make there life harder only to simplify the job of NLP-grammatical.

If doesn't change anything for the question parsing (we always have something to put into predicate). See https://github.com/ProjetPP/PPP-QuestionParsing-Grammatical/pull/106#issuecomment-73723785 for the reasons why i think we shouldn't depict inverse-predicate as optional.

But leave it at it is (optional), developers will just have to be aware of the importance of inverse-predicate.

(for me, you can merge :+1:)

Ezibenroc commented 9 years ago

But leave it at it is (optional), developers will just have to be aware of the importance of inverse-predicate.

This does not make sense: if the inverse-predicate is important then it should not be optionnal.

yhamoudi commented 9 years ago

This does not make sense: if the inverse-predicate is important then it should not be optionnal.

We could consider that it is optional because sometimes it doesn't exist, not because it is less useful than predicate.

Ezibenroc commented 9 years ago

Alright.

Tpt commented 9 years ago

@s-i-newton Do you have any concerns about this addition to the data model?

yhamoudi commented 9 years ago

Silence is consent. I think we can merge now...

progval commented 9 years ago

I think @s-i-newton just has no Internet connection.

yhamoudi commented 9 years ago

How did he registred on the forum?

progval commented 9 years ago

Hmm, indeed

On 17/02/2015 17:53, Yassine wrote:

How did he registred on the forum?


Reply to this email directly or view it on GitHub: https://github.com/ProjetPP/Documentation/pull/56#issuecomment-74702809