buildingSMART / buildingSMART/bSDD

Improve SemTech support

Open
#146 11 comments 2 reactions 1 assignee Claimed by @Baars-IT View on GitHub
API enhancement todo
Dominant language
Python
Stars
193
Forks
45
PR merge metrics
No merged PRs in 30d

Description

Prefixes need to end with `“/”` or `“#”`. Right now we have:
```
@prefix dictionary: .
@prefix qudtUnit: .
@prefix ifc4_3: .
```
Resolve this by adding a `“#”` at the end of the URI (here ifc4_3).

Right now the prefixes are declared but not used. For example:
```
@prefix ifc4_3: .
a dictionary:Class;
```
So we can’t do `ifc4_3:IfcWall`, because bSDD has (unfortunatelly) `/class/` and `/prop/`. So an ugly workaround, but I don’t see a better way, is to define two prefixes:

```
@prefix ifc4_3_clas: .
@prefix ifc4_3_prop: .
ifc4_3_clas:IfcWall a dictionary:Class;
ifc4_3_prop:NetVolume a dictionary:Property;
```

The `https://standards.buildingsmart.org/DataDictionary#` doesn’t resolve well. When I go to, for example, `https://standards.buildingsmart.org/DataDictionary#VersionNumber` it resolves to `https://standards.buildingsmart.org/DataDictionary/#VersionNumber` (notice `#` turns to `/#`).

Right now we are creating TTL file but miss SemTech standards (OWL/RDFS). For example, instead of `owl:Class` we do our own `dictionary:Class`. Therefore existing resolvers fail to load our TTL. While we can keep existing attributes, please let’s add the missing ones. I list them below.

Right now, we show TTL on Class and Properties, but when people trim that URI to the dictionary level, it doesn’t return anything. It would help a lot if we could provide it. Yes, that TTL would be huge for some dictionaries, so let’s use a similar approach like with JSON (cache it on the server). Small issue: our URIs have /class/ and /prop/ after the ontology name, so in theory, for every dictionary, we have two ontologies. That TTL should be both available through API mediatype: tuple and via the Search page. That TTL should also include all languages, so for example:
```
rdfs:label "Acceptance Date"@en-gb;
rdfs:label "Data Akceptacji"@pl-PL;
```

**Checklist:**

- [ ] ~~split into separate @prefix for classes and properites~~ remove `/class/` and `/prop/` to allow for the same @prefix for classes and properites
- [ ] use prefixes to avoid outside header
- [ ] stop resolving `#` to `/#` on standards page
- [ ] add a `“#”` at the end of the URI in TTL
- [ ] on all classes replace `a dictionary:Class;` with `a owl:Class;` (example: `ifc4_3_class:IfcWall a owl:Class;`)
- [ ] on all properties replace `a dictionary:Property;` with `a owl:DataProperty;` (example: `ifc4_3_prop:NetVolume a owl:DataProperty "NetVolume";`)
- [ ] on all ClassProperties add `rdfs:domain` pointing to the class they are attached to (example: `ifc4_3_prop:AcceptanceDate rdfs:domain ifc4_3_class:IfcWall;`)
- [ ] instead of `dictionary:DataType` add `rdfs:range` (example: `dictionary:DataType "String";` → `rdfs:range xsd:string;`). Map all the data types.
- [ ] instead of `dictionary:Definition` add ~~`rdfs:comment`~~ skos:definition
- [ ] instead of `dictionary:Name "Wall"@en-gb;` add `rdfs:label "Wall"@en-gb;` (or skos:prefLabel and synonyms: skos:altLabel)
- [ ] provide the content of the "dictionary" namespace as RDF. Currently [https://standards.buildingsmart.org/DataDictionary/](https://standards.buildingsmart.org/DataDictionary/) only returns HTML.
- [ ] add TTL at whole data dictionary level in bSDD
- [ ] change capitalisation to camelCase (e.g. ActivationDateUtc --> activationDateUtc)
- [ ] rename 'domain' --> confusing in the RDF context (use dataDictionary)
- [ ] string values should be URIs (example: status: "Active" --> status: https://id.../active)
- [ ] extend bSDD relations like IsSimilarTo, RelatedIfcEntityNamesList, HasReference to match [SKOS](https://www.w3.org/TR/skos-reference/): skos:broadMatch, skos:closeMatch, skos:exactMatch
- [ ] replace bSDD specific terms with Dublin Core Properties like dct:dateAccepted, dct:description, dct:license etc
- [ ] IsChildOf → rdfs:subClassOf. The JSON already carries parentClassReference; the current TTL publication drops it. Or use [SKOS ](https://www.w3.org/TR/skos-reference/)for existing attributes like dictionary:example --> skos:example, dictionary:(parent/child) --> skos:broader/narrower
- [ ] Units → QUDT (qudt:unit, qudt:quantityKind). QUDT is already in import model
- [ ] rename "dictionary" namespace to "bsdd" for all the remaining attributes that don't find equivalent in OWL/RDF/SKOS/DCT

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.