uncefact / spec-jsonld

Exposing the UN/CEFACT vocabulary as web semantics
https://service.unece.org/trade/uncefact/vocabulary/uncefact/
13 stars 5 forks source link

split Communication to subclasses #60

Closed VladimirAlexiev closed 2 years ago

VladimirAlexiev commented 2 years ago

Commnuication (better called CommnuicationChannel) is a busy class:

PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX uncefact: <https://service.unece.org/trade/uncefact/trade/uncefact/vocabulary/uncefact#>
PREFIX schema: <http://schema.org/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
select * {
    {?out schema:domainIncludes uncefact:Communication; rdfs:comment ?descr}
    union {?in schema:rangeIncludes uncefact:Communication; rdfs:comment ?descr}
}
outgoing (attribs) descr
areaNumberCode "The code specifying the area number for this telecommunication."
communicationChannelCode "The code specifying the channel or manner in which a universal communication can be made, such as telephone or email."
completeNumber "The text string of characters that make up the complete number."
countryNumberCode "The country access code for this telecommunication number."
extensionNumber "The extension number, expressed as text, assigned to this telecommunication number."
internalAccess "Access information, expressed as text, for the internal access telecommunication number, such as the United States Defense Network Service number."
localNumber "The communication number, expressed as text and not including country access code or the area number code, for this telecommunication."
specialDeviceType "The special device type, expressed as text, for this telecommunication communication, such as a device for the hearing impaired."
uRIId "A Uniform Resource Identifier (URI) for the binary file, communication or standard."
usagePreference "The specified preference for the usage of this telecommunication method."
useCode "The code specifying the use of this telecommunication such as for business purposes or private."
incoming (rels) descr
directTelephoneCommunication "The direct telephone communication information for this trade contact."
emailURICommunication "An email URI (Uniform Resource Identifier) communication information."
endPointURICommunication "The communication address of the end point URI for this trade party."
faxCommunication "Fax communication information"
instantMessagingCommunication "Instant messaging communication information for this trade contact."
landlineTelephoneCommunication "Landline telephone communication information for this transport person."
mobileTelephoneCommunication "Mobile telephone communication information."
telephoneCommunication "A telephone communication for the contact, party or person."
telexCommunication "Telegraphy (Telex) communication information for this trade contact."
uRICommunication "A Uniform Resource Identifier (URI) communication for the party or service, such as a web or email address."
vOIPCommunication "Voice Over Internet Protocol (VOIP) communication information for this trade contact."

The problem is that there's no correlation between incoming (rels) and outgoing (attribs). Eg what would be the meaning of this data:

<trader> landlineTelephoneCommunication <trader/comm>.
<trader/comm> a Communication; 
  uRIId <cannot call here>;
  # phone attribs missing

It'd be better to split it to a subclass hierarchy, eg

Communication: usagePreference, useCode
  URICommunication: uri
    WebsiteCommunication
    VOIPCommunication
    EmailCommunication
  PhoneCommunication: phone attributes
    LandlineTelephoneCommunication 
    MobileTelephoneCommunication