Developing a Gen3 Data Dictionary
This repository aims to provide the documentation, learning materials, and software tools to facilitate the creation of a data model in Gen3.
Pre-Reading: Please become familiar with some core data modelling concepts before starting.
Using Gen3SchemaDev as a data modelling tool
- Quickstart
- Guide to creating your first dictionary
- Declaring links in the input_yaml
- Running a Gen3 dictionary repository
- Troubleshooting
generate does not overwrite your files
gen3schemadev generate never overwrites existing files by default. Generating into an empty folder works as it always has; generating into a folder that already contains files stops and lists exactly what it would have replaced, along with the ways forward.
This matters because a dictionary repository can be run in more than one way. Some treat the input_yaml as the source of truth and regenerate from it. Others generate once and then edit the Gen3 schemas directly, at which point the generated files are the dictionary. The tool cannot tell which you are doing, and guessing wrong destroys work.
--input-driven— theinput_yamlis the source of truth; regenerate everything, and fail if the folder holds a file the input cannot produce--only <node>— regenerate named nodes, leaving every other file untouched--check— report whether the folder still matches the input, write nothing, exit non-zero on drift. This is the CI gate--force— overwrite everything, discarding any hand edits
Nodes may also extend the packaged program, project and core_metadata_collection presets, adding properties while inheriting the node-level settings other Gen3 microservices depend on. See Running a Gen3 dictionary repository.
Null description placeholders
gen3schemadev validate warns about description: null placeholders anywhere in the dictionary (commonly in _definitions.yaml's enum definitions). The Gen3 metaschema requires descriptions to be strings; null placeholders cause "No Description" in the data-dictionary viewer and metaschema validation failures that surface on resolved node schemas, far from the offending definition. Remove the null description keys to resolve the warning.
Deep dive into Gen3 Data Modelling
Special Thanks to Marion Shadbolt for providing the source material
- Gen3 Dictionary Overview
- Gen3 Schema Explained
- Example of a Gen3 Schema yaml
- Handy tips
- FAIR Concepts for Data Modelling
For Developers
Installation and testing
# To install
pip install poetry
poetry install
source $(poetry env info --path)/bin/activate
gen3schemadev --version
# To run tests
poetry run pytest
Contributing
Gen3SchemaDev is an open source project, and we highly encourage any contributions and PRs. Specifically we need the community to help with the following:
- Keeping the gen3 metaschema up to date
- Adding business rule logic to the rule validator module.
- For example, a node with the category
data_fileshould have a collection of required data file properties such as md5sum, filesize, etc.
- For example, a node with the category
For PRs, please follow the contributing guidelines.
License
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gen3schemadev-3.2.0.tar.gz.
File metadata
- Download URL: gen3schemadev-3.2.0.tar.gz
- Upload date:
- Size: 55.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
poetry/2.4.1 CPython/3.12.13 Linux/6.17.0-1020-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
76e5f792897095b82947360ab2432eeb77cf65dde96072ddee414fa4091b7e6e
|
|
| MD5 |
df833cfe660a4af332968de0612d5e9a
|
|
| BLAKE2b-256 |
94e00f4694d3ae5a96e1ba91db7df574775a7605c5c1e198fd09a4b9646c8604
|
File details
Details for the file gen3schemadev-3.2.0-py3-none-any.whl.
File metadata
- Download URL: gen3schemadev-3.2.0-py3-none-any.whl
- Upload date:
- Size: 63.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
poetry/2.4.1 CPython/3.12.13 Linux/6.17.0-1020-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4bcde87222f6bd06d10877ad46924d02e1f3c3c0c54150cac9eae1d4dc232a30
|
|
| MD5 |
16344b8e8672a550b42b22cc022ebc17
|
|
| BLAKE2b-256 |
5c750a8a9218beb3850041c0680574a84fc1dde6ecc4f596ad5c1a4127a4adde
|