own-pt / openWordnet-PT

OpenWordnet-PT: an open access wordnet for Portuguese
http://openwordnet-pt.org
Other
154 stars 35 forks source link

property synsetId #179

Closed fredsonaguiar closed 3 years ago

fredsonaguiar commented 3 years ago

The property synsetId has being used to describe the synset_offset from https://wordnet.princeton.edu/documentation/wndb5wn, wich isn't unique among synsets of different types (preciselly, different POS). We should replace this information by wn30:offset, and instantiate the unique wn30:synsetId as described.

For instance, the triple

<https://w3id.org/own-pt/wn30-en/instances/synset-02734835-n> wn30:synsetId "02734835" .

should be expanded into

<https://w3id.org/own-pt/wn30-en/instances/synset-02734835-n> wn30:synsetId "02734835-n" .
<https://w3id.org/own-pt/wn30-en/instances/synset-02734835-n> wn30:offset "02734835" .
fredsonaguiar commented 3 years ago

In 2d7e15c39967680e85249f133f548ca31accd0ed we apply this script. We got the outputs:

python3 pyownpt/cli/property_synset_id.py openWordnet-PT/own-files/own-en-synsets.ttl -o own-en-synsets.ttl -v
INFO:root:loading data from file 'openWordnet-PT/own-files/own-en-synsets.ttl'
INFO:ownpt:start formatting property synsetId
INFO:ownpt:action applied to 117659 cases
    total: 235318 triples added
    total: 117659 triples removed
INFO:root:serializing output to 'own-en-synsets.ttl'
python3 pyownpt/cli/property_synset_id.py openWordnet-PT/own-files/own-pt-synsets.ttl-o own-pt-synnsets.ttl -v
INFO:root:loading data from file 'openWordnet-PT/own-files/own-pt-synsets.ttl'
INFO:ownpt:start formatting property synsetId
INFO:ownpt:action applied to 117659 cases
    total: 235318 triples added
    total: 117659 triples removed
INFO:root:serializing output to 'own-pt-synnsets.ttl'