Skip to content

Commit

Permalink
Merge pull request #182 from psychoinformatics-de/towards-v1
Browse files Browse the repository at this point in the history
Major update of the `things` schema
  • Loading branch information
mih authored Dec 7, 2024
2 parents 94693e8 + f40b254 commit 2887a60
Show file tree
Hide file tree
Showing 89 changed files with 1,216 additions and 1,099 deletions.
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ check-models: \
checkmodel/thing/unreleased \
checkmodel/prov/unreleased \
checkmodel/distribution/unreleased \
checkmodel/datalad-dataset/unreleased \
checkmodel/sdd/unreleased
checkmodel/datalad-dataset/unreleased
# checkmodel/sdd/unreleased
checkmodel/%: src/%.yaml
@echo [Check $<]
@echo "Run linter"
Expand Down Expand Up @@ -89,9 +89,9 @@ check-validation: \
convertexamples/distribution/unreleased \
checkvalidation/distribution/unreleased \
convertexamples/datalad-dataset/unreleased \
checkvalidation/datalad-dataset/unreleased \
convertexamples/sdd/unreleased \
checkvalidation/sdd/unreleased
checkvalidation/datalad-dataset/unreleased
# convertexamples/sdd/unreleased \
# checkvalidation/sdd/unreleased
checkvalidation/%:
$(MAKE) checkvalid/$* checkinvalid/$*
checkvalid/%: src/%/validation src/%.yaml
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"id": "annex-key:MD5E-s3214--ba1f2511fc30423bdbb183fe33f3dd0f.csv",
"meta_type": "dldist:Distribution",
"schema_type": "dldist:Distribution",
"byte_size": 3214,
"checksum": [
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,28 +1,36 @@
{
"id": "gitsha:eb4d2457a1165519c61859152fe0e3394200d75d",
"identifier": [
{
"notation": "eb4d2457a1165519c61859152fe0e3394200d75d",
"schema_agency": "https://git-scm.com"
}
],
"meta_type": "dldist:Distribution",
"type": "https://git-scm.com/book/en/v2/Git-Internals-Git-Objects#_git_commit_objects",
"relation": [
"relations": [
{
"id": "https://github.com/datalad-datasets/machinelearning-books.git",
"meta_type": "dldist:DataService",
"schema_type": "dldist:DataService",
"type": "http://usefulinc.com/ns/doap#GitRepository",
"endpoint_url": "https://github.com/datalad-datasets/machinelearning-books.git"
}
],
"has_attributes": [
{
"predicate": "ADMS:identifier",
"has_attributes": [
{
"predicate": "ADMS:SchemaAgency",
"schema_type": "dlthing:AttributeSpecification",
"value": "https://git-scm.com"
}
],
"schema_type": "dlthing:AttributeSpecification",
"value": "eb4d2457a1165519c61859152fe0e3394200d75d"
}
],
"schema_type": "dldist:Distribution",
"type": "https://git-scm.com/book/en/v2/Git-Internals-Git-Objects#_git_commit_objects",
"access_service": [
"https://github.com/datalad-datasets/machinelearning-books.git"
],
"has_part": [
{
"id": "gitsha:f776e30f386b83e13196eab6445f30d3ab54c155",
"meta_type": "dldist:Distribution",
"schema_type": "dldist:Distribution",
"access_service": [
"https://github.com/datalad-datasets/machinelearning-books.git"
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@ id: gitsha:eb4d2457a1165519c61859152fe0e3394200d75d
# abusing the documentation as a type definition URL of a Git commit
# TODO define term in `datalad-dataset` schema
type: https://git-scm.com/book/en/v2/Git-Internals-Git-Objects#_git_commit_objects
identifier:
# a Git SHA
notation: eb4d2457a1165519c61859152fe0e3394200d75d
schema_agency: https://git-scm.com
has_attributes:
- predicate: ADMS:identifier
# a Git SHA
value: eb4d2457a1165519c61859152fe0e3394200d75d
has_attributes:
- predicate: ADMS:SchemaAgency
value: https://git-scm.com
# A hosted (http-accessible) Git repository is the access service for this
# commit and the associated tree.
# We could also consider all of GitHub as an access service, and declare
Expand All @@ -15,14 +18,14 @@ identifier:
# applicable to any Git repo hosted anywhere
access_service:
- https://github.com/datalad-datasets/machinelearning-books.git
relation:
relations:
# we leave inline information on the hosted Git repo in a relation.
# use id from access_service property above
- id: https://github.com/datalad-datasets/machinelearning-books.git
# identify as a dataservice -- not strictly needed for an implementation
# that wants to obtain the commit, because we have the id from `access_service`
# to match against
meta_type: dldist:DataService
schema_type: dldist:DataService
# we use the DOAP (description of a project) term to identify this dataservice
# as a Git repository.
# TODO define term in `datalad-dataset` schema
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"id": "gitsha:9a48c2bf7e97a081f2b1ab68eb909bbfc86267be",
"meta_type": "dldist:Distribution",
"schema_type": "dldist:Distribution",
"is_distribution_of": "gitsha:8d6f033bb2a6109b2c4d64d6f27b0feb181e4d0f",
"qualified_part": [
{
Expand Down

This file was deleted.

This file was deleted.

66 changes: 0 additions & 66 deletions src/datalad-dataset/unreleased/examples/Resource-gitcommit.json

This file was deleted.

63 changes: 0 additions & 63 deletions src/datalad-dataset/unreleased/examples/Resource-gitcommit.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion src/datalad-dataset/unreleased/extra-docs/about.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ TODO: how to declare relationships when no dedicated support for a particular ty

Properties that are used as containers to define related objects support the declaration of specific subtypes of the respective range-defining class.
For example, `was_attributed_to` accepts any `Agent`, but specialized classes maybe be more suitable in particular contexts.
Such a derived class can be indicated via the `meta_type` property.
Such a derived class can be indicated via the `schema_type` property.
If declared, it is then used for data structure definition and validation for this particular record.

Independent of this structure-focused type declaration, the `type` property can be used to detail the semantics of an object.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ schema: src/distribution/unreleased.yaml
target_class: Distribution
data_sources:
- src/distribution/unreleased/examples/Distribution-basic.yaml
- src/datalad-dataset/unreleased/examples/Distribution-annexaccess.yaml
- src/distribution/unreleased/examples/Distribution-customlicense.yaml
- src/distribution/unreleased/examples/Distribution-resource.yaml
- src/distribution/unreleased/examples/Distribution-parts.yaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ schema: src/distribution/unreleased.yaml
target_class: Resource
data_sources:
- src/distribution/unreleased/examples/Resource-study.yaml
- src/datalad-dataset/unreleased/examples/Resource-gitcommit.yaml
- src/datalad-dataset/unreleased/examples/Resource-dataladdataset.yaml
plugins:
JsonschemaValidationPlugin:
closed: true
Expand Down
Loading

0 comments on commit 2887a60

Please sign in to comment.