Risk Data Library Standard
Technical review report
○ e.g. .model and .value are required in anyOf.exposure, but .value has no
required properties. This leaves open the possibility of a user having to
include an empty object to satisfy the schema.
Data model
The data model defines the structural and conceptual relationships between the elements
that make up the data standard. It can therefore have a significant impact on the usability
and extensibility of the standard.
The top-level conceptual object is a data file with spatial properties. The standard started life
as an SQL database designed to hold these data files themselves (the Risk Data Library)
and not just catalogue the metadata and access points. This is likely to account for some of
the structural decisions seen in the JSON schema. The use cases and ambitions for the
standard are however more far reaching, intending to create a standard that can be used by
others to expose their data from their own host locations.
JSON format allows for multiple layers of nesting. Multiple layers of nesting can make a
schema harder to read for human users, and introduce complexity when flattening the data
structure in order to present it in a flat field format such as a CSV file or an SQL database.
The nesting in the schema is both minimal (reflecting the standard’s origins as an SQL
database) and unnecessarily complicated.
● common consists of two nested objects, contribution (of type object) and
resources (of type array). This separation is required if multiple files are to be
described by resources, e.g. different formats or resolutions of the same data.
● The four objects representing the four components, hazard, exposure,
vulnerability and loss are nested within anyOf, these should be at the same
level as common. This would ease human readability.
● It’s unclear why the nesting within three of these four is necessary, e.g.
○ exposure is divided into model and value
○ vulnerability divided into model and specifics
○ loss having a further nested object model.
If the intended user of the standard is most likely to be working with spreadsheets
and relational databases it makes sense to leave the schema with as few layers of
hierarchy as possible. We suggest removing this second level nesting within each of
these three objects.
Nesting doesn’t have to create additional complexity, it can be used to reduce repetition and
therefore simplify the schema. Such a use would be through the creation of common objects.
The benefit of this is that the common objects only need to be defined once in
definitions, and the different contexts in which they are used can be given in the
20
Open Data Services Co-operative Limited is a company limited by shares, operated as a Workers' Co-operative |
Registered in England. Company number: 09506232 | Registered address: 1st Floor, Holyoake House, Hanover
Street, Manchester
, Greater Manchester
, M60 0AS | Correspondence to
[email protected]