diff --git a/docs/design/architecture.qmd b/docs/design/architecture.qmd index 1207ff8a..5edae4e3 100644 --- a/docs/design/architecture.qmd +++ b/docs/design/architecture.qmd @@ -29,6 +29,38 @@ This section describes the different users we expect and design for: add custom checks or ignore certain checks to fit the specific needs of the project. +## Naming + +This section contains a naming scheme for `check-datapackage` that is +inspired by the [Data Package standard](https://datapackage.org/). + +Overall, we follow the Data Package terminology where possible to keep +things consistent. However, we also introduce some new terms and +concepts specific to `check-datapackage`. The main objects and actions +used throughout the package can be found in the tables below. + +### Objects + +| Object | Description | +|----------------------------|--------------------------------------------| +| package | A Data Package that contains a collection of related data resources and descriptor(s). | +| descriptor | A standalone and complete metadata structure contained in a JSON file, for example, in `datapackage.json`. | +| properties | Metadata fields (name-value pairs) of a descriptor loaded as a Python dictionary. This can be a subset of the original descriptor or the entire structure. | +| schema | The JSON schema defining the Data Package standard. | +| config | An object containing settings for modifying the behaviour and output of the check mechanism. | + +: Objects used throughout `check-datapackage`. + +### Actions + +| Action | Description | +|----------------------------|--------------------------------------------| +| check | Check that a descriptor conforms to the Data Package standard. | +| explain | Explain issues flagged by the check action in more detail using non-technical language. | +| read | Read various files, such as a Data Package descriptor or a configuration file. | + +: Actions that `check-datapackage` can perform. + ## C4 Models This section contains the [C4 Models](https://c4model.com/) for @@ -84,40 +116,3 @@ flowchart LR ext_dp_schema --> check in_dp_json --> check ``` - -## Naming - -This section contains a naming scheme for `check-datapackage` that is -inspired by the [Data Package standard](https://datapackage.org/). - -Following Data Package terminology, we simplify "data package" to -"package" and "data resource" to "resource". The Data Package standard -calls a standalone and complete metadata structure -["descriptor"](https://datapackage.org/standard/glossary/#descriptor). -Descriptors are JSON objects contained in JSON files (e.g., -`datapackage.json` contains the Data Package descriptor). We adopt this -usage, but may also use the word "properties" to refer to the metadata -as a whole. - -### Objects - -| Object | Description | -|----------------------------|--------------------------------------------| -| package | A Data Package that contains a collection of related data resources and properties. | -| resource | A single data file within a package including its properties. | -| descriptor | The standalone and complete metadata structure contained in a JSON file, for example, in `datapackage.json`. | -| properties | Individual elements of the metadata structure or the structure as a whole. | -| standard | The JSON schema defining the Data Package standard. | -| config | An object containing settings for modifying the behaviour and output of the check mechanism. | - -: Objects used throughout `check-datapackage`. - -### Actions - -| Action | Description | -|----------------------------|--------------------------------------------| -| check | Check that a descriptor conforms to the Data Package standard. | -| explain | Explain issues flagged by the check mechanism in more detail using non-technical language. | -| read | Read various files, such as the Data Package descriptor or configuration files. | - -: Actions that `check-datapackage` can perform.