rlay-project / rlay-ontology

Implementation of the Rlay decentralized ontology format
Other
12 stars 0 forks source link

Spec Entity field types #22

Open hobofan opened 5 years ago

hobofan commented 5 years ago

(Late night thoughts)

Currently the Entity fields (fields of the different entity kinds) are not that concretely specified. A lot of them are currently states as being either an "IRI" (taken from OWL spec, but not really applicable) or just plain bytes.

The rough idea is that all fields that represent relationships to other entities should be CIDs, while all fields that represent "data" should be Multicodec-prefixed bytes (which could also be CIDs given that https://github.com/multiformats/multicodec/issues/49 is added).

By making the data fields Multicodecs, we bascially get a very good equivalent to Literals/Datatypes in OWL2 for free.

Data fields: Annotation->value, (Negative)DataPropertyAssertion->target

hobofan commented 5 years ago

Related implementation: #24

hobofan commented 4 years ago

Since there doesn't seem to be any progress on multiformats/multicodec#49, I would propose the following:

For literal values: Use multicodec prefixed value (once they add support for CIDs, this will just add more expressiveness to literal values) For "CID" (/Link) values: Use custom temporary multicodec signaling a CID as a prefix followed by CIDv1 bytes; Once multiformats/multicodec#49 is implemented, directly using CIDs in those positions too.