From ca1297b356f26288c2dfe518dbd19208779d426b Mon Sep 17 00:00:00 2001 From: Michael Baudis <675030+mbaudis@users.noreply.github.com> Date: Thu, 22 Dec 2022 12:37:07 +0100 Subject: [PATCH 01/37] removing the validation directories The validation directories are confusing & not part of the framework itself. --- docs/formats-standards.md | 12 +- .../validation/beaconCommonComponents.json | 54 --------- .../requests/validation/filteringTerms.json | 109 ------------------ .../validation/beaconCommonComponents.yaml | 37 ------ .../requests/validation/filteringTerms.yaml | 88 -------------- 5 files changed, 4 insertions(+), 296 deletions(-) delete mode 100644 framework/json/common/validation/beaconCommonComponents.json delete mode 100644 framework/json/requests/validation/filteringTerms.json delete mode 100644 framework/src/common/validation/beaconCommonComponents.yaml delete mode 100644 framework/src/requests/validation/filteringTerms.yaml diff --git a/docs/formats-standards.md b/docs/formats-standards.md index e22885c73..403a666fe 100644 --- a/docs/formats-standards.md +++ b/docs/formats-standards.md @@ -23,28 +23,24 @@ The Beacon v2 specification is written in [YAML](https://yaml.org). The original framework |-- json | |-- common - | | |-- examples - | | `-- validation + | | `-- examples | |-- configuration | | `-- examples | |-- requests | | |-- examples-fullDocuments - | | |-- examples-sections - | | `-- validation + | | `-- examples-sections | `-- responses | |-- examples-fullDocuments | |-- examples-sections | `-- sections `-- src |-- common - | |-- examples - | `-- validation + | `-- examples |-- configuration | `-- examples |-- requests | |-- examples-fullDocuments - | |-- examples-sections - | `-- validation + | `-- examples-sections `-- responses |-- examples-fullDocuments |-- examples-sections diff --git a/framework/json/common/validation/beaconCommonComponents.json b/framework/json/common/validation/beaconCommonComponents.json deleted file mode 100644 index 99bb55603..000000000 --- a/framework/json/common/validation/beaconCommonComponents.json +++ /dev/null @@ -1,54 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": false, - "properties": { - "$schema": { - "description": "Added here to allow the example to comply with the 'additionalProperties:true' restriction.", - "type": "string" - }, - "apiVersion": { - "$ref": "../beaconCommonComponents.json#/definitions/ApiVersion" - }, - "beaconError": { - "$ref": "../beaconCommonComponents.json#/definitions/BeaconError" - }, - "beaconId": { - "$ref": "../beaconCommonComponents.json#/definitions/BeaconId" - }, - "exists": { - "$ref": "../beaconCommonComponents.json#/definitions/Exists" - }, - "filters": { - "$ref": "../beaconCommonComponents.json#/definitions/Filters" - }, - "handover": { - "$ref": "../beaconCommonComponents.json#/definitions/Handover" - }, - "handoverType": { - "$ref": "../beaconCommonComponents.json#/definitions/HandoverType" - }, - "includeResultsetResponses": { - "$ref": "../beaconCommonComponents.json#/definitions/IncludeResultsetResponses" - }, - "info": { - "$ref": "../beaconCommonComponents.json#/definitions/Info" - }, - "listOfHandovers": { - "$ref": "../beaconCommonComponents.json#/definitions/ListOfHandovers" - }, - "listOfSchemas": { - "$ref": "../beaconCommonComponents.json#/definitions/ListOfSchemas" - }, - "numTotalResults": { - "$ref": "../beaconCommonComponents.json#/definitions/NumTotalResults" - }, - "pagination": { - "$ref": "../beaconCommonComponents.json#/definitions/Pagination" - }, - "schemasPerEntity": { - "$ref": "../beaconCommonComponents.json#/definitions/SchemasPerEntity" - } - }, - "title": "Schema for validating Beacon Common Components examples", - "type": "object" -} \ No newline at end of file diff --git a/framework/json/requests/validation/filteringTerms.json b/framework/json/requests/validation/filteringTerms.json deleted file mode 100644 index e4d51516e..000000000 --- a/framework/json/requests/validation/filteringTerms.json +++ /dev/null @@ -1,109 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": false, - "definitions": { - "AlphanumericFilter": { - "description": "Filter results based on operators and values applied to alphanumeric fields.", - "properties": { - "id": { - "description": "Field identfier to be queried.", - "example": "age", - "type": "string" - }, - "operator": { - "default": "=", - "description": "Defines how the value relates to the field `id`.", - "enum": [ - "=", - "<", - ">", - "!", - ">=", - "<=" - ], - "example": ">", - "type": "string" - }, - "value": { - "description": "Alphanumeric search term to be used within the query which can contain wildcard characters (%) to denote any number of unknown characters. Values can be assocatied with units if applicable.", - "example": "P70Y", - "type": "string" - } - }, - "required": [ - "id", - "operator", - "value" - ], - "type": "object" - }, - "CustomFilter": { - "description": "Filter results to include records that contain a custom term defined by this Beacon.", - "properties": { - "id": { - "description": "Custom filter terms should contain a unique identifier.", - "example": "demographic.ethnicity:asian", - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "OntologyFilter": { - "description": "Filter results to include records that contain a specific ontology term.", - "properties": { - "id": { - "description": "Term ID to be queried, using CURIE syntax where possible.", - "example": "HP:0002664", - "type": "string" - }, - "includeDescendantTerms": { - "default": true, - "description": "Define if the Beacon should implement the ontology hierarchy, thus query the descendant terms of `id`.", - "type": "boolean" - }, - "similarity": { - "default": "exact", - "description": "Allow the Beacon to return results which do not match the filter exactly, but do match to a certain degree of similarity. The Beacon defines the semantic similarity model implemented and how to apply the thresholds of 'high', 'medium' and 'low' similarity.", - "enum": [ - "exact", - "high", - "medium", - "low" - ], - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - }, - "description": "Rules for selecting records based upon the field values those records contain. Filters are seperated by the logical AND operator.", - "properties": { - "$schema": { - "description": "Added here to allow the example to comply with the 'additionalProperties:true' restriction.", - "type": "string" - }, - "filters": { - "items": { - "anyOf": [ - { - "$ref": "#/definitions/OntologyFilter" - }, - { - "$ref": "#/definitions/AlphanumericFilter" - }, - { - "$ref": "#/definitions/CustomFilter" - } - ] - }, - "type": "array" - } - }, - "title": "Filtering Term Element" -} \ No newline at end of file diff --git a/framework/src/common/validation/beaconCommonComponents.yaml b/framework/src/common/validation/beaconCommonComponents.yaml deleted file mode 100644 index ac0b6d9f3..000000000 --- a/framework/src/common/validation/beaconCommonComponents.yaml +++ /dev/null @@ -1,37 +0,0 @@ -$schema: https://json-schema.org/draft/2020-12/schema -title: Schema for validating Beacon Common Components examples -type: object -properties: - $schema: - type: string - description: Added here to allow the example to comply with the 'additionalProperties:true' - restriction. - beaconId: - $ref: ../beaconCommonComponents.yaml#/definitions/BeaconId - apiVersion: - $ref: ../beaconCommonComponents.yaml#/definitions/ApiVersion - beaconError: - $ref: ../beaconCommonComponents.yaml#/definitions/BeaconError - listOfSchemas: - $ref: ../beaconCommonComponents.yaml#/definitions/ListOfSchemas - schemasPerEntity: - $ref: ../beaconCommonComponents.yaml#/definitions/SchemasPerEntity - pagination: - $ref: ../beaconCommonComponents.yaml#/definitions/Pagination - includeResultsetResponses: - $ref: ../beaconCommonComponents.yaml#/definitions/IncludeResultsetResponses - filters: - $ref: ../beaconCommonComponents.yaml#/definitions/Filters - exists: - $ref: ../beaconCommonComponents.yaml#/definitions/Exists - numTotalResults: - $ref: ../beaconCommonComponents.yaml#/definitions/NumTotalResults - info: - $ref: ../beaconCommonComponents.yaml#/definitions/Info - handover: - $ref: ../beaconCommonComponents.yaml#/definitions/Handover - handoverType: - $ref: ../beaconCommonComponents.yaml#/definitions/HandoverType - listOfHandovers: - $ref: ../beaconCommonComponents.yaml#/definitions/ListOfHandovers -additionalProperties: false diff --git a/framework/src/requests/validation/filteringTerms.yaml b/framework/src/requests/validation/filteringTerms.yaml deleted file mode 100644 index 6fa00be82..000000000 --- a/framework/src/requests/validation/filteringTerms.yaml +++ /dev/null @@ -1,88 +0,0 @@ -$schema: https://json-schema.org/draft/2020-12/schema -title: Filtering Term Element -description: Rules for selecting records based upon the field values those records - contain. Filters are seperated by the logical AND operator. -properties: - $schema: - type: string - description: Added here to allow the example to comply with the 'additionalProperties:true' - restriction. - filters: - type: array - items: - anyOf: - - $ref: '#/definitions/OntologyFilter' - - $ref: '#/definitions/AlphanumericFilter' - - $ref: '#/definitions/CustomFilter' -definitions: - OntologyFilter: - type: object - description: Filter results to include records that contain a specific ontology - term. - required: - - id - properties: - id: - type: string - description: Term ID to be queried, using CURIE syntax where possible. - example: HP:0002664 - includeDescendantTerms: - type: boolean - default: true - description: Define if the Beacon should implement the ontology hierarchy, - thus query the descendant terms of `id`. - similarity: - type: string - enum: - - exact - - high - - medium - - low - default: exact - description: Allow the Beacon to return results which do not match the filter - exactly, but do match to a certain degree of similarity. The Beacon defines - the semantic similarity model implemented and how to apply the thresholds - of 'high', 'medium' and 'low' similarity. - AlphanumericFilter: - description: Filter results based on operators and values applied to alphanumeric - fields. - type: object - required: - - id - - operator - - value - properties: - id: - type: string - description: Field identfier to be queried. - example: age - operator: - type: string - enum: - - '=' - - < - - '>' - - '!' - - '>=' - - <= - description: Defines how the value relates to the field `id`. - default: '=' - example: '>' - value: - type: string - description: Alphanumeric search term to be used within the query which can - contain wildcard characters (%) to denote any number of unknown characters. Values - can be assocatied with units if applicable. - example: P70Y - CustomFilter: - type: object - description: Filter results to include records that contain a custom term defined - by this Beacon. - required: - - id - properties: - id: - type: string - description: Custom filter terms should contain a unique identifier. - example: demographic.ethnicity:asian -additionalProperties: false From 2b12b2311178c8e64eb5366d62ca665816072d58 Mon Sep 17 00:00:00 2001 From: Jordi Rambla Date: Tue, 28 Mar 2023 18:26:48 +0200 Subject: [PATCH 02/37] Removing mentions to "aggregated" granularity in the code. --- framework/src/common/beaconCommonComponents.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/framework/src/common/beaconCommonComponents.yaml b/framework/src/common/beaconCommonComponents.yaml index c0044ed5c..5ffee4cd0 100644 --- a/framework/src/common/beaconCommonComponents.yaml +++ b/framework/src/common/beaconCommonComponents.yaml @@ -137,7 +137,6 @@ definitions: * `boolean`: returns true/false' responses * `count`: adds the total number of positive results found - * `aggregated`: returns summary, aggregated or distribution like responses * `record`: returns details for every row. In cases where a Beacon prefers to return records with fewer than allattributes, different strategies have to be considered w/o adding them to the current design, e.g.: @@ -147,7 +146,6 @@ definitions: enum: - boolean - count - - aggregated - record default: boolean TestMode: From d490eb74ebbe363043ed53443cec067ea02ddb58 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Wed, 24 May 2023 11:24:54 +0200 Subject: [PATCH 03/37] missing object type fix `ResultsetInstance` was missing the "type" parameter which leads to errors when creating instances. --- framework/json/responses/sections/beaconResultsets.json | 3 ++- framework/src/responses/sections/beaconResultsets.yaml | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/framework/json/responses/sections/beaconResultsets.json b/framework/json/responses/sections/beaconResultsets.json index 6ddeb3a88..a54e43030 100644 --- a/framework/json/responses/sections/beaconResultsets.json +++ b/framework/json/responses/sections/beaconResultsets.json @@ -44,7 +44,8 @@ "exists", "resultsCount", "results" - ] + ], + "type": "object" } }, "description": "Sets of results to be returned as query response.", diff --git a/framework/src/responses/sections/beaconResultsets.yaml b/framework/src/responses/sections/beaconResultsets.yaml index 246ef8277..09835db13 100644 --- a/framework/src/responses/sections/beaconResultsets.yaml +++ b/framework/src/responses/sections/beaconResultsets.yaml @@ -15,6 +15,7 @@ required: additionalProperties: true definitions: ResultsetInstance: + type: object properties: id: description: id of the resultset From 634283dcc64cfd33f6b44215da11ac5cb82c22eb Mon Sep 17 00:00:00 2001 From: Michael Baudis <675030+mbaudis@users.noreply.github.com> Date: Fri, 26 May 2023 10:31:26 +0200 Subject: [PATCH 04/37] Update CHANGELOG.md --- CHANGELOG.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0f94b2408..bd0848c0f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -34,7 +34,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed * Fixed `POST`queries for `g_variant` (w/ examples) - * Removed 'json' references inside the yaml version (PR [#43] (https://github.com/ga4gh-beacon/beacon-v2/pull/43)) + * Removed 'json' references inside the yaml version (PR [#43](https://github.com/ga4gh-beacon/beacon-v2/pull/43)) + * added missing `type: object` to `ResultsetInstance` (PR [#82](https://github.com/ga4gh-beacon/beacon-v2/pull/82)) ### Deprecated From 80653761a31ad21785e137a9495cf9ed2eee4998 Mon Sep 17 00:00:00 2001 From: Michael Baudis <675030+mbaudis@users.noreply.github.com> Date: Thu, 1 Jun 2023 14:49:00 +0200 Subject: [PATCH 05/37] fix disease ageOfOnset examples Fixes https://github.com/ga4gh-beacon/beacon-v2/issues/59 --- .../common/disease.json | 26 +++++++------------ .../common/disease.yaml | 20 ++++++-------- 2 files changed, 17 insertions(+), 29 deletions(-) diff --git a/models/json/beacon-v2-default-model/common/disease.json b/models/json/beacon-v2-default-model/common/disease.json index 5da7a797d..d50bbfdfa 100644 --- a/models/json/beacon-v2-default-model/common/disease.json +++ b/models/json/beacon-v2-default-model/common/disease.json @@ -6,30 +6,22 @@ "$ref": "./timeElement.json", "examples": [ { - "ageGroup": { - "id": "NCIT:C49685", - "label": "Adult 18-65 Years Old" - } + "id": "NCIT:C49685", + "label": "Adult 18-65 Years Old" }, { - "age": { - "iso8601duration": "P32Y6M1D" - } + "iso8601duration": "P32Y6M1D" }, { - "ageRange": { - "end": { - "iso8601duration": "P59Y" - }, - "start": { - "iso8601duration": "P18Y" - } + "end": { + "iso8601duration": "P59Y" + }, + "start": { + "iso8601duration": "P18Y" } }, { - "age": { - "iso8601duration": "P2M4D" - } + "iso8601duration": "P2M4D" } ] }, diff --git a/models/src/beacon-v2-default-model/common/disease.yaml b/models/src/beacon-v2-default-model/common/disease.yaml index a4f5f5719..c6472dad6 100644 --- a/models/src/beacon-v2-default-model/common/disease.yaml +++ b/models/src/beacon-v2-default-model/common/disease.yaml @@ -20,18 +20,14 @@ properties: ageOfOnset: $ref: ./timeElement.yaml examples: - - ageGroup: - id: NCIT:C49685 - label: Adult 18-65 Years Old - - age: - iso8601duration: P32Y6M1D - - ageRange: - start: - iso8601duration: P18Y - end: - iso8601duration: P59Y - - age: - iso8601duration: P2M4D + - id: NCIT:C49685 + label: Adult 18-65 Years Old + - iso8601duration: P32Y6M1D + - start: + iso8601duration: P18Y + end: + iso8601duration: P59Y + - iso8601duration: P2M4D stage: description: 'Ontology term from Ontology for General Medical Science (OGMS), e.g. acute onset (OGMS:0000119). Provenance: GA4GH Phenopackets v2 `Disease.disease_stage`' From 11312cd0bd0374c31b4e7902609b365eed459c3c Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 10 Jun 2023 10:57:32 +0200 Subject: [PATCH 06/37] fixing the ontology term CUSTOM format This is a pure documentation change for the handover format. Addresses https://github.com/ga4gh-beacon/beacon-v2/issues/83 --- framework/json/common/beaconCommonComponents.json | 14 +++++++++----- framework/src/common/beaconCommonComponents.yaml | 14 ++++++++------ 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/framework/json/common/beaconCommonComponents.json b/framework/json/common/beaconCommonComponents.json index 728c35267..768d938c4 100644 --- a/framework/json/common/beaconCommonComponents.json +++ b/framework/json/common/beaconCommonComponents.json @@ -111,15 +111,19 @@ }, "HandoverType": { "$ref": "./ontologyTerm.json", - "description": "Handover type, as an Ontology_term object with CURIE syntax for the `id` value. Use `CUSTOM` for the `id` when no ontology is available.", + "description": "Handover type, as an Ontology_term object with CURIE syntax for the `id` value. Use \"CUSTOM:123455\" CURIE-style `id` when no ontology is available.", "examples": [ { - "id": "EFO:0004157", - "label": "BAM format" + "id": "EDAM:2572", + "label": "BAM" }, { - "id": "CUSTOM", - "label": "download genomic variants in .pgxseg file format" + "id": "EDAM:3016", + "label": "VCF" + }, + { + "id": "CUSTOM:pgxseg", + "label": "genomic variants in .pgxseg file format" } ] }, diff --git a/framework/src/common/beaconCommonComponents.yaml b/framework/src/common/beaconCommonComponents.yaml index c0044ed5c..53296705a 100644 --- a/framework/src/common/beaconCommonComponents.yaml +++ b/framework/src/common/beaconCommonComponents.yaml @@ -265,11 +265,13 @@ definitions: example: https://api.mygenomeservice.org/Handover/9dcc48d7-fc88-11e8-9110-b0c592dbf8c0/ HandoverType: description: >- - Handover type, as an Ontology_term object with CURIE syntax for the `id` value. - Use `CUSTOM` for the `id` when no ontology is available. + Handover type, as an Ontology_term object with CURIE syntax for the `id` + value. Use "CUSTOM:123455" CURIE-style `id` when no ontology is available. $ref: ./ontologyTerm.yaml examples: - - id: EFO:0004157 - label: BAM format - - id: CUSTOM - label: download genomic variants in .pgxseg file format + - id: EDAM:2572 + label: BAM + - id: EDAM:3016 + label: VCF + - id: CUSTOM:pgxseg + label: genomic variants in .pgxseg file format From 5b47a87236b304317ad1964d7a81c0a1f48f7a5a Mon Sep 17 00:00:00 2001 From: Michael Baudis <675030+mbaudis@users.noreply.github.com> Date: Sat, 17 Jun 2023 17:42:10 -0700 Subject: [PATCH 07/37] Update entryTypeDefinition.yaml The parameter descriptions in the EntryTypeDefinitions schema seem somewhat hard to parse and potentially misleading - this is a go at cleaning them up a bit. --- .../configuration/entryTypeDefinition.yaml | 51 +++++++++---------- 1 file changed, 25 insertions(+), 26 deletions(-) diff --git a/framework/src/configuration/entryTypeDefinition.yaml b/framework/src/configuration/entryTypeDefinition.yaml index 99f3ef974..4ca04013f 100644 --- a/framework/src/configuration/entryTypeDefinition.yaml +++ b/framework/src/configuration/entryTypeDefinition.yaml @@ -1,23 +1,22 @@ $schema: https://json-schema.org/draft/2020-12/schema title: '' -description: "Definition of an element or entry type including the Beacon v2 required\ - \ and suggested attributes. This schema purpose is to describe each type of entities\ - \ included in a Beacon, hence Beacon clients could have some metadata about such\ - \ entities.\n\nThe `id` attribute is the key that should be used in other parts\ - \ of the Beacon Model to allow Beacon clients to identify the different parts (e.g.\ - \ endpoints, filteringTerms, request parameters, etc.) that fully describe an entry\ - \ type." +description: >- + Definition of an element or entity, to describe each type of entity included in + a beacon. + The `id` attribute is the key that should be used in other parts of the data model + to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, + request parameters, etc.) that relvant for an entity. type: object -$comment: 'TO DO: The tagged parts should reference to `common/ontologizedElement.json`. - But that configuration fails to validate. Further investigation is required, but - should not affect the resulting schema.' properties: $schema: $ref: ../common/beaconCommonComponents.yaml#/definitions/$schema id: - $comments: ++++++ THIS IS THE START OF THE ontologized element ++++++ type: string description: A (unique) identifier of the element. + examples: + - biosample + - individual + - dataset name: type: string description: A distinctive name for the element. @@ -26,7 +25,6 @@ properties: description: A textual description for the element. ontologyTermForThisType: $ref: ../common/ontologyTerm.yaml - $comments: ++++++ THIS IS THE END OF THE ontologized element ++++++ partOfSpecification: description: This is label to group together entry types that are part of the same specification. @@ -42,25 +40,26 @@ properties: items: $ref: ../common/referenceToAnSchema.yaml aCollectionOf: - description: If the entry type is a collection of other entry types, (e.g. a Dataset - is a collection of Records), then this attribute must list the entry types that - could be included. One collection type could be defined as included more than - one entry type (e.g. a Dataset could include Individuals or Genomic Variants), - in such cases the entries are alternative, meaning that a given instance of - this entry type could be of only one of the types (e.g. a given Dataset contains - Individuals, while another Dataset could contain Genomic Variants, but not both - at once). + description: >- + If the entry type is a collection of other entities, (e.g. a Dataset + is a collection of Records), then this attribute must list the entities that + can be included. One _collection_ can include more than one entity + (e.g. a Dataset in teh Beacon cdefault model could include Individuals, Biosamples, + GenomicVariations, Analyses amnd Runs). In such cases in each individual + response (e.g. `resultSetsResponse` of collections of type "dataset") will + contain entries of a single entity type (e.g. biosamples) even if a dataset + may contain records of multiple types. includedConcepts: type: array $ref: ../common/basicElement.yaml filteringTerms: - description: Reference to the file with the list of filtering terms that could - be used to filter this concept in this instance of Beacon. The referenced file - could be used to populate the `filteringTerms`endpoint. Having it independently - should allow for updating the list of accepted filtering terms when it is necessary. + description: >- + Reference to the list of filtering terms that could be used to filter records + of this entity in this beacon. type: string - $comment: "TO DO: Double-check the proper way of referencing a path or relative\ - \ path. 'format: uri' is throwing validation errors for relative file paths" + $comment: >- + TO DO: Evaluate switch this to `url` or a more specific way for allowing + URLs and local file paths (is this necessary?). nonFilteredQueriesAllowed: $ref: ../common/beaconCommonComponents.yaml#/definitions/NonFilteredQueriesAllowed required: From 6aeb06ffebea6284c7b57f569b981bd08d4a081c Mon Sep 17 00:00:00 2001 From: Michael Baudis <675030+mbaudis@users.noreply.github.com> Date: Mon, 19 Jun 2023 13:11:35 +0200 Subject: [PATCH 08/37] Update entryTypeDefinition.json --- .../json/configuration/entryTypeDefinition.json | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/framework/json/configuration/entryTypeDefinition.json b/framework/json/configuration/entryTypeDefinition.json index 434bebcf6..13c094cc1 100644 --- a/framework/json/configuration/entryTypeDefinition.json +++ b/framework/json/configuration/entryTypeDefinition.json @@ -1,14 +1,13 @@ { - "$comment": "TO DO: The tagged parts should reference to `common/ontologizedElement.json`. But that configuration fails to validate. Further investigation is required, but should not affect the resulting schema.", "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Definition of an element or entry type including the Beacon v2 required and suggested attributes. This schema purpose is to describe each type of entities included in a Beacon, hence Beacon clients could have some metadata about such entities.\n\nThe `id` attribute is the key that should be used in other parts of the Beacon Model to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, request parameters, etc.) that fully describe an entry type.", + "description": "Definition of an element or entity, to describe each type of entity included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, request parameters, etc.) that relvant for an entity.", "properties": { "$schema": { "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" }, "aCollectionOf": { - "description": "If the entry type is a collection of other entry types, (e.g. a Dataset is a collection of Records), then this attribute must list the entry types that could be included. One collection type could be defined as included more than one entry type (e.g. a Dataset could include Individuals or Genomic Variants), in such cases the entries are alternative, meaning that a given instance of this entry type could be of only one of the types (e.g. a given Dataset contains Individuals, while another Dataset could contain Genomic Variants, but not both at once).", + "description": "If the entry type is a collection of other entities, (e.g. a Dataset is a collection of Records), then this attribute must list the entities that can be included. One _collection_ can include more than one entity (e.g. a Dataset in teh Beacon cdefault model could include Individuals, Biosamples, GenomicVariations, Analyses amnd Runs). In such cases in each individual response (e.g. `resultSetsResponse` of collections of type \"dataset\") will contain entries of a single entity type (e.g. biosamples) even if a dataset may contain records of multiple types.", "includedConcepts": { "$ref": "../common/basicElement.json", "type": "array" @@ -30,13 +29,17 @@ "type": "string" }, "filteringTerms": { - "$comment": "TO DO: Double-check the proper way of referencing a path or relative path. 'format: uri' is throwing validation errors for relative file paths", - "description": "Reference to the file with the list of filtering terms that could be used to filter this concept in this instance of Beacon. The referenced file could be used to populate the `filteringTerms`endpoint. Having it independently should allow for updating the list of accepted filtering terms when it is necessary.", + "$comment": "TO DO: Evaluate switch this to `url` or a more specific way for allowing URLs and local file paths (is this necessary?).", + "description": "Reference to the list of filtering terms that could be used to filter records of this entity in this beacon.", "type": "string" }, "id": { - "$comments": "++++++ THIS IS THE START OF THE ontologized element ++++++", "description": "A (unique) identifier of the element.", + "examples": [ + "biosample", + "individual", + "dataset" + ], "type": "string" }, "name": { @@ -47,7 +50,6 @@ "$ref": "../common/beaconCommonComponents.json#/definitions/NonFilteredQueriesAllowed" }, "ontologyTermForThisType": { - "$comments": "++++++ THIS IS THE END OF THE ontologized element ++++++", "$ref": "../common/ontologyTerm.json" }, "partOfSpecification": { From d3f7a9262e0b93d1e562f6fd2979d04cca1b941d Mon Sep 17 00:00:00 2001 From: Michael Baudis <675030+mbaudis@users.noreply.github.com> Date: Mon, 19 Jun 2023 13:26:37 +0200 Subject: [PATCH 09/37] removed ontologyTermForThisType requirement It is not clear how to use ontologyTermForThisType w/o examples (i.e. terms for biosample, individual... - added some but incomplete...) and there is also a logical duplication having a "unique" id and an ontology term. Overall this should be clarified but the current modification seems (a) sensible (step). --- .../json/configuration/entryTypeDefinition.json | 17 +++++++++++++---- .../src/configuration/entryTypeDefinition.yaml | 12 ++++++++---- 2 files changed, 21 insertions(+), 8 deletions(-) diff --git a/framework/json/configuration/entryTypeDefinition.json b/framework/json/configuration/entryTypeDefinition.json index 13c094cc1..400fdb004 100644 --- a/framework/json/configuration/entryTypeDefinition.json +++ b/framework/json/configuration/entryTypeDefinition.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Definition of an element or entity, to describe each type of entity included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, request parameters, etc.) that relvant for an entity.", + "description": "Definition of an element or entity, to describe each type of entity included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filtering terms, request parameters, etc.) that are relvant for an entity.", "properties": { "$schema": { "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" @@ -34,7 +34,7 @@ "type": "string" }, "id": { - "description": "A (unique) identifier of the element.", + "description": "A unique identifier of the element.", "examples": [ "biosample", "individual", @@ -50,7 +50,17 @@ "$ref": "../common/beaconCommonComponents.json#/definitions/NonFilteredQueriesAllowed" }, "ontologyTermForThisType": { - "$ref": "../common/ontologyTerm.json" + "$ref": "../common/ontologyTerm.json", + "examples": [ + { + "id": "EFO:0000542", + "label": "individual" + }, + { + "id": "OBI:0000747", + "label": "material sample" + } + ] }, "partOfSpecification": { "description": "This is label to group together entry types that are part of the same specification.", @@ -61,7 +71,6 @@ "required": [ "id", "name", - "ontologyTermForThisType", "partOfSpecification", "defaultSchema" ], diff --git a/framework/src/configuration/entryTypeDefinition.yaml b/framework/src/configuration/entryTypeDefinition.yaml index 4ca04013f..a101afe75 100644 --- a/framework/src/configuration/entryTypeDefinition.yaml +++ b/framework/src/configuration/entryTypeDefinition.yaml @@ -4,15 +4,15 @@ description: >- Definition of an element or entity, to describe each type of entity included in a beacon. The `id` attribute is the key that should be used in other parts of the data model - to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, - request parameters, etc.) that relvant for an entity. + to allow Beacon clients to identify the different parts (e.g. endpoints, filtering + terms, request parameters, etc.) that are relvant for an entity. type: object properties: $schema: $ref: ../common/beaconCommonComponents.yaml#/definitions/$schema id: type: string - description: A (unique) identifier of the element. + description: A unique identifier of the element. examples: - biosample - individual @@ -25,6 +25,11 @@ properties: description: A textual description for the element. ontologyTermForThisType: $ref: ../common/ontologyTerm.yaml + examples: + - id: EFO:0000542 + label: individual + - id: OBI:0000747 + label: material sample partOfSpecification: description: This is label to group together entry types that are part of the same specification. @@ -65,7 +70,6 @@ properties: required: - id - name - - ontologyTermForThisType - partOfSpecification - defaultSchema additionalProperties: true From dd943aece56a0f814cc1af4272da306e39344c8d Mon Sep 17 00:00:00 2001 From: Michael Baudis <675030+mbaudis@users.noreply.github.com> Date: Mon, 19 Jun 2023 14:43:28 +0200 Subject: [PATCH 10/37] entry type as default instead entity --- .../json/configuration/entryTypeDefinition.json | 6 +++--- framework/src/configuration/entryTypeDefinition.yaml | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/framework/json/configuration/entryTypeDefinition.json b/framework/json/configuration/entryTypeDefinition.json index 400fdb004..b20352764 100644 --- a/framework/json/configuration/entryTypeDefinition.json +++ b/framework/json/configuration/entryTypeDefinition.json @@ -1,13 +1,13 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Definition of an element or entity, to describe each type of entity included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filtering terms, request parameters, etc.) that are relvant for an entity.", + "description": "Definition of an element or entry type, to describe each type of entry type included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filtering terms, request parameters, etc.) that are relvant for an entry type.", "properties": { "$schema": { "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" }, "aCollectionOf": { - "description": "If the entry type is a collection of other entities, (e.g. a Dataset is a collection of Records), then this attribute must list the entities that can be included. One _collection_ can include more than one entity (e.g. a Dataset in teh Beacon cdefault model could include Individuals, Biosamples, GenomicVariations, Analyses amnd Runs). In such cases in each individual response (e.g. `resultSetsResponse` of collections of type \"dataset\") will contain entries of a single entity type (e.g. biosamples) even if a dataset may contain records of multiple types.", + "description": "If the entry type is a collection of other entities, (e.g. a Dataset is a collection of Records), then this attribute must list the entities that can be included. One _collection_ can include more than one entry type (e.g. a Dataset in teh Beacon cdefault model could include Individuals, Biosamples, GenomicVariations, Analyses amnd Runs). In such cases in each individual response (e.g. `resultSetsResponse` of collections of type \"dataset\") will contain entries of a single entry type (e.g. biosamples) even if a dataset may contain records of multiple types.", "includedConcepts": { "$ref": "../common/basicElement.json", "type": "array" @@ -30,7 +30,7 @@ }, "filteringTerms": { "$comment": "TO DO: Evaluate switch this to `url` or a more specific way for allowing URLs and local file paths (is this necessary?).", - "description": "Reference to the list of filtering terms that could be used to filter records of this entity in this beacon.", + "description": "Reference to the list of filtering terms that could be used to filter records of this entry type in this beacon.", "type": "string" }, "id": { diff --git a/framework/src/configuration/entryTypeDefinition.yaml b/framework/src/configuration/entryTypeDefinition.yaml index a101afe75..136c2980a 100644 --- a/framework/src/configuration/entryTypeDefinition.yaml +++ b/framework/src/configuration/entryTypeDefinition.yaml @@ -1,11 +1,11 @@ $schema: https://json-schema.org/draft/2020-12/schema title: '' description: >- - Definition of an element or entity, to describe each type of entity included in - a beacon. + Definition of an element or entry type, to describe each type of entry type included + in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filtering - terms, request parameters, etc.) that are relvant for an entity. + terms, request parameters, etc.) that are relvant for an entry type. type: object properties: $schema: @@ -48,11 +48,11 @@ properties: description: >- If the entry type is a collection of other entities, (e.g. a Dataset is a collection of Records), then this attribute must list the entities that - can be included. One _collection_ can include more than one entity + can be included. One _collection_ can include more than one entry type (e.g. a Dataset in teh Beacon cdefault model could include Individuals, Biosamples, GenomicVariations, Analyses amnd Runs). In such cases in each individual response (e.g. `resultSetsResponse` of collections of type "dataset") will - contain entries of a single entity type (e.g. biosamples) even if a dataset + contain entries of a single entry type (e.g. biosamples) even if a dataset may contain records of multiple types. includedConcepts: type: array @@ -60,7 +60,7 @@ properties: filteringTerms: description: >- Reference to the list of filtering terms that could be used to filter records - of this entity in this beacon. + of this entry type in this beacon. type: string $comment: >- TO DO: Evaluate switch this to `url` or a more specific way for allowing From 94b789198ec296830c67877097c0c828eef77e30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oriol=20L=C3=B3pez-Doriga?= Date: Tue, 20 Jun 2023 16:46:19 +0200 Subject: [PATCH 11/37] update entryType description --- framework/json/configuration/entryTypeDefinition.json | 2 +- framework/src/configuration/entryTypeDefinition.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/json/configuration/entryTypeDefinition.json b/framework/json/configuration/entryTypeDefinition.json index b20352764..27d425770 100644 --- a/framework/json/configuration/entryTypeDefinition.json +++ b/framework/json/configuration/entryTypeDefinition.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Definition of an element or entry type, to describe each type of entry type included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filtering terms, request parameters, etc.) that are relvant for an entry type.", + "description": "Definition of an element or scope of the element, to describe each type of entry type included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filtering terms, request parameters, etc.) that are relvant for an entry type.", "properties": { "$schema": { "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" diff --git a/framework/src/configuration/entryTypeDefinition.yaml b/framework/src/configuration/entryTypeDefinition.yaml index 136c2980a..61916df7e 100644 --- a/framework/src/configuration/entryTypeDefinition.yaml +++ b/framework/src/configuration/entryTypeDefinition.yaml @@ -1,7 +1,7 @@ $schema: https://json-schema.org/draft/2020-12/schema title: '' description: >- - Definition of an element or entry type, to describe each type of entry type included + Definition of an element or scope of the element, to describe each type of entry type included in a beacon. The `id` attribute is the key that should be used in other parts of the data model to allow Beacon clients to identify the different parts (e.g. endpoints, filtering From cb3b2ff3c80f80a7f012914efe33a7ac306f7cc5 Mon Sep 17 00:00:00 2001 From: redmitry Date: Tue, 5 Sep 2023 15:11:08 +0200 Subject: [PATCH 12/37] for templates the format must be "uri-template". --- framework/json/configuration/beaconMapSchema.json | 6 +++--- framework/src/configuration/beaconMapSchema.yaml | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/framework/json/configuration/beaconMapSchema.json b/framework/json/configuration/beaconMapSchema.json index b5335e28b..47fec6701 100644 --- a/framework/json/configuration/beaconMapSchema.json +++ b/framework/json/configuration/beaconMapSchema.json @@ -18,7 +18,7 @@ }, "filteringTermsUrl": { "description": "Optional. Returns the list of filtering terms that could be applied to this entry type. It is added here for convenience of the Beacon clients, so they don't need to parse the OpenAPI endpoints definition to get that endpoint. Also, in very simple Beacons, that endpoint could be the one of the few implemented, together with \u00b4rootUrl` and \u00b4singleEntryUrl`, in which case the whole map of endpoints is found in the current Map.", - "format": "uri", + "format": "uri-template", "type": "string" }, "openAPIEndpointsDefinition": { @@ -32,7 +32,7 @@ }, "singleEntryUrl": { "description": "Optional, but recommended. Returns only one instance of this entry, identified by an `id`. It is added here for convenience of the Beacon clients, so they don't need to parse the OpenAPI endpoints definition to get that base endpoint. Also, in very simple Beacons, that endpoint could be the only one implemented, together with \u00b4rootUrl`, in which case the whole map of endpoints is found in the current Map.", - "format": "uri", + "format": "uri-template", "type": "string" } }, @@ -50,7 +50,7 @@ }, "url": { "description": "Endpoint URL", - "format": "uri", + "format": "uri-template", "type": "string" } }, diff --git a/framework/src/configuration/beaconMapSchema.yaml b/framework/src/configuration/beaconMapSchema.yaml index ce1cff2c2..83170dab6 100644 --- a/framework/src/configuration/beaconMapSchema.yaml +++ b/framework/src/configuration/beaconMapSchema.yaml @@ -46,7 +46,7 @@ definitions: be the only one implemented, together with ´rootUrl`, in which case the whole map of endpoints is found in the current Map. type: string - format: uri + format: uri-template filteringTermsUrl: description: Optional. Returns the list of filtering terms that could be applied to this entry type. It is added here for convenience of the Beacon clients, @@ -55,7 +55,7 @@ definitions: the few implemented, together with ´rootUrl` and ´singleEntryUrl`, in which case the whole map of endpoints is found in the current Map. type: string - format: uri + format: uri-template endpoints: description: Optional. A list describing additional endpoints implemented by this Beacon instance for that entry type. Additional details on the endpoint @@ -74,7 +74,7 @@ definitions: url: description: Endpoint URL type: string - format: uri + format: uri-template returnedEntryType: description: Which entry type is returned by querying this endpoint. It MUST match one of the entry types defined in the Beacon configuration file (`beaconConfiguration.json`). From 971a2adb46c2c6a7706d58e1493c06108c049e06 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 6 Jul 2024 15:59:49 +0200 Subject: [PATCH 13/37] Update requestParameters.yaml for at least 1 end value --- .../genomicVariations/requestParameters.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml b/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml index 37c5b9e48..112bdb2ab 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml @@ -16,7 +16,7 @@ g_variant: - typical use are queries for SNV and small InDels - the use of `start` without an `end` parameter requires the use of `alternateBases` - * `start` and `end`: + * 1 value in both `start` and `end`: - for searching any variant falling fully or partially within the range between `start` and `end` (a.k.a. "range query") - additional use of `variantType` OR `alternateBases` can limit the @@ -48,7 +48,7 @@ g_variant: type: integer format: int64 minimum: 1 - minItems: 0 + minItems: 1 maxItems: 2 referenceBases: $ref: ./requestParametersComponents.yaml#/definitions/ReferenceBases From 33d22289f1c6355be8014d545abe02b4b0cee58e Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 6 Jul 2024 16:03:38 +0200 Subject: [PATCH 14/37] Update requestParameters.json for at least 1 value in end --- .../genomicVariations/requestParameters.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json b/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json index 48381aaf7..e469211f4 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json +++ b/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json @@ -17,14 +17,14 @@ "$ref": "./requestParametersComponents.json#/definitions/Assembly" }, "end": { - "description": "Precise or bracketing the end of the variants of interest: * (0-based, exclusive) - see `start` * for bracket queries, provide 2 values (e.g. [111,222]).\"", + "description": "Precise or bracketing the end of the variants of interest: * (0-based, exclusive) - see `start` * for bracket queries, provide 2 values (e.g. [111,222]).", "items": { "format": "int64", "minimum": 1, "type": "integer" }, "maxItems": 2, - "minItems": 0, + "minItems": 1, "type": "array" }, "geneId": { @@ -52,7 +52,7 @@ "$ref": "./requestParametersComponents.json#/definitions/RefSeqId" }, "start": { - "description": "Precise or fuzzy start coordinate position(s), allele locus (0-based, inclusive). * `start` only:\n - for single positions, e.g. the start of a specified sequence\n alteration where the size is given through the specified `alternateBases`\n - typical use are queries for SNV and small InDels\n - the use of `start` without an `end` parameter requires the use of\n `alternateBases`\n* `start` and `end`:\n - for searching any variant falling fully or partially within the range\n between `start` and `end` (a.k.a. \"range query\")\n - additional use of `variantType` OR `alternateBases` can limit the\n scope of the query\n - by convention, partial overlaps of variants with the indicated genomic\n range are accepted; for specific overlap requirements the 4-parameter\n \"Bracket Queries\" should be employed\n* 2 values in both `start` and `end` for constructing a \"Bracket Query\":\n - can be used to match any contiguous genomic interval, e.g. for querying\n imprecise positions\n - identifies all structural variants starting between `start[0]` and `start[1]`,\n and ending between `end[0]` <-> `end[1]`\n - single or double sided precise matches can be achieved by setting\n `start[1]=start[0]+1` and `end[1]=end[0]+1`", + "description": "Precise or fuzzy start coordinate position(s), allele locus (0-based, inclusive). * `start` only:\n - for single positions, e.g. the start of a specified sequence\nalteration where the size is given through the specified `alternateBases`\n - typical use are queries for SNV and small InDels\n - the use of `start` without an `end` parameter requires the use of\n`alternateBases`\n* 1 value each in both `start` and `end`:\n - for searching any variant falling fully or partially within the range\n between `start` and `end` (a.k.a. \"range query\")\n - additional use of `variantType` OR `alternateBases` can limit the\n scope of the query\n - by convention, partial overlaps of variants with the indicated genomic\n range are accepted; for specific overlap requirements the 4-parameter\n \"Bracket Queries\" should be employed\n* 2 values in both `start` and `end` for constructing a \"Bracket Query\":\n - can be used to match any contiguous genomic interval, e.g. for querying\n imprecise positions\n - identifies all structural variants starting between `start[0]` and `start[1]`,\n and ending between `end[0]` <-> `end[1]`\n - single or double sided precise matches can be achieved by setting\n `start[1]=start[0]+1` and `end[1]=end[0]+1`", "items": { "format": "int64", "minimum": 0, @@ -87,4 +87,4 @@ }, "type": "object" } -} \ No newline at end of file +} From 9f9c96ab9f6c4f2b5b14ed33db10b26325d9ac14 Mon Sep 17 00:00:00 2001 From: Oriol Lopez-Doriga Date: Wed, 10 Jul 2024 14:59:03 +0200 Subject: [PATCH 15/37] renaming endpoints for beaconMap --- .../beacon-v2-default-model/beaconMap.json | 62 +++++++++---------- .../beacon-v2-default-model/beaconMap.yaml | 62 +++++++++---------- 2 files changed, 62 insertions(+), 62 deletions(-) diff --git a/models/json/beacon-v2-default-model/beaconMap.json b/models/json/beacon-v2-default-model/beaconMap.json index 4c9a12a78..a7681a24f 100644 --- a/models/json/beacon-v2-default-model/beaconMap.json +++ b/models/json/beacon-v2-default-model/beaconMap.json @@ -1,9 +1,9 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "endpointSets": { - "analysis": { + "analysisEndpoints": { "endpoints": { - "genomicVariant": { + "genomicVariantLookup": { "returnedEntryType": "genomicVariant", "url": "https://exampleBeacons.org/analyses/{id}/g_variants" } @@ -13,17 +13,17 @@ "rootUrl": "https://exampleBeacons.org/analyses", "singleEntryUrl": "https://exampleBeacons.org/analyses/{id}" }, - "biosample": { + "biosampleEndpoints": { "endpoints": { - "analysis": { + "analysisLookup": { "returnedEntryType": "analysis", "url": "https://exampleBeacons.org/biosamples/{id}/analyses" }, - "genomicVariant": { + "genomicVariantLookup": { "returnedEntryType": "genomicVariant", "url": "https://exampleBeacons.org/biosamples/{id}/g_variants" }, - "run": { + "runLookup": { "returnedEntryType": "run", "url": "https://exampleBeacons.org/biosamples/{id}/runs" } @@ -33,25 +33,25 @@ "rootUrl": "https://exampleBeacons.org/biosamples", "singleEntryUrl": "https://exampleBeacons.org/biosamples/{id}" }, - "cohort": { + "cohortEndpoints": { "endpoints": { - "analyses": { + "analysisLookup": { "returnedEntryType": "analysis", "url": "https://exampleBeacons.org/cohorts/{id}/analyses" }, - "biosample": { + "biosampleLookup": { "returnedEntryType": "biosample", "url": "https://exampleBeacons.org/cohorts/{id}/biosamples" }, - "genomicVariant": { + "genomicVariantLookup": { "returnedEntryType": "genomicVariant", "url": "https://exampleBeacons.org/cohorts/{id}/g_variants" }, - "individual": { + "individualLookup": { "returnedEntryType": "individual", "url": "https://exampleBeacons.org/cohorts/{id}/individuals" }, - "runs": { + "runLookup": { "returnedEntryType": "run", "url": "https://exampleBeacons.org/cohorts/{id}/runs" } @@ -62,25 +62,25 @@ "rootUrl": "https://exampleBeacons.org/cohorts", "singleEntryUrl": "https://exampleBeacons.org/cohorts/{id}" }, - "dataset": { + "datasetEndpoints": { "endpoints": { - "analyses": { + "analysisLookup": { "returnedEntryType": "analysis", "url": "https://exampleBeacons.org/datasets/{id}/analyses" }, - "biosample": { + "biosampleLookup": { "returnedEntryType": "biosample", "url": "https://exampleBeacons.org/datasets/{id}/biosamples" }, - "genomicVariant": { + "genomicVariantLookup": { "returnedEntryType": "genomicVariant", "url": "https://exampleBeacons.org/datasets/{id}/g_variants" }, - "individual": { + "individualLookup": { "returnedEntryType": "individual", "url": "https://exampleBeacons.org/datasets/{id}/individuals" }, - "runs": { + "runLookup": { "returnedEntryType": "run", "url": "https://exampleBeacons.org/datasets/{id}/runs" } @@ -91,21 +91,21 @@ "rootUrl": "https://exampleBeacons.org/datasets", "singleEntryUrl": "https://exampleBeacons.org/datasets/{id}" }, - "genomicVariant": { + "genomicVariantEndpoints": { "endpoints": { - "analyses": { + "analysisLookup": { "returnedEntryType": "analysis", "url": "https://exampleBeacons.org/g_variants/{id}/analyses" }, - "biosample": { + "biosampleLookup": { "returnedEntryType": "biosample", "url": "https://exampleBeacons.org/g_variants/{id}/biosamples" }, - "individual": { + "individualLookup": { "returnedEntryType": "individual", "url": "https://exampleBeacons.org/g_variants/{id}/individuals" }, - "runs": { + "runLookup": { "returnedEntryType": "run", "url": "https://exampleBeacons.org/g_variants/{id}/runs" } @@ -115,21 +115,21 @@ "rootUrl": "https://exampleBeacons.org/g_variants", "singleEntryUrl": "https://exampleBeacons.org/g_variants/{id}" }, - "individual": { + "individualEndpoints": { "endpoints": { - "analyses": { + "analysisLookup": { "returnedEntryType": "analysis", "url": "https://exampleBeacons.org/individuals/{id}/analyses" }, - "biosample": { + "biosampleLookup": { "returnedEntryType": "biosample", "url": "https://exampleBeacons.org/individuals/{id}/biosamples" }, - "genomicVariant": { + "genomicVariantLookup": { "returnedEntryType": "genomicVariant", "url": "https://exampleBeacons.org/individuals/{id}/g_variants" }, - "runs": { + "runLookup": { "returnedEntryType": "run", "url": "https://exampleBeacons.org/individuals/{id}/runs" } @@ -140,13 +140,13 @@ "rootUrl": "https://exampleBeacons.org/individuals", "singleEntryUrl": "https://exampleBeacons.org/individuals/{id}" }, - "run": { + "runEndpoints": { "endpoints": { - "analysis": { + "analysisLookup": { "returnedEntryType": "analysis", "url": "https://exampleBeacons.org/runs/{id}/analyses" }, - "genomicVariant": { + "genomicVariantLookup": { "returnedEntryType": "genomicVariant", "url": "https://exampleBeacons.org/runs/{id}/g_variants" } diff --git a/models/src/beacon-v2-default-model/beaconMap.yaml b/models/src/beacon-v2-default-model/beaconMap.yaml index 3da0cd2a4..823d60f74 100644 --- a/models/src/beacon-v2-default-model/beaconMap.yaml +++ b/models/src/beacon-v2-default-model/beaconMap.yaml @@ -1,119 +1,119 @@ $schema: https://json-schema.org/draft/2020-12/schema endpointSets: - dataset: + datasetEndpoints: entryType: dataset openAPIEndpointsDefinition: https://exampleBeacons.org/datasets/endpoints.json rootUrl: https://exampleBeacons.org/datasets singleEntryUrl: https://exampleBeacons.org/datasets/{id} filteringTermsUrl: https://exampleBeacons.org/datasets/{id}/filtering_terms endpoints: - genomicVariant: + genomicVariantLookup: returnedEntryType: genomicVariant url: https://exampleBeacons.org/datasets/{id}/g_variants - biosample: + biosampleLookup: returnedEntryType: biosample url: https://exampleBeacons.org/datasets/{id}/biosamples - individual: + individualLookup: returnedEntryType: individual url: https://exampleBeacons.org/datasets/{id}/individuals - runs: + runLookup: returnedEntryType: run url: https://exampleBeacons.org/datasets/{id}/runs - analyses: + analysisLookup: returnedEntryType: analysis url: https://exampleBeacons.org/datasets/{id}/analyses - cohort: + cohortEndpoints: entryType: cohort openAPIEndpointsDefinition: https://exampleBeacons.org/cohorts/endpoints.json rootUrl: https://exampleBeacons.org/cohorts singleEntryUrl: https://exampleBeacons.org/cohorts/{id} filteringTermsUrl: https://exampleBeacons.org/cohorts/{id}/filtering_terms endpoints: - individual: + individualLookup: returnedEntryType: individual url: https://exampleBeacons.org/cohorts/{id}/individuals - genomicVariant: + genomicVariantLookup: returnedEntryType: genomicVariant url: https://exampleBeacons.org/cohorts/{id}/g_variants - biosample: + biosampleLookup: returnedEntryType: biosample url: https://exampleBeacons.org/cohorts/{id}/biosamples - runs: + runLookup: returnedEntryType: run url: https://exampleBeacons.org/cohorts/{id}/runs - analyses: + analysisLookup: returnedEntryType: analysis url: https://exampleBeacons.org/cohorts/{id}/analyses - genomicVariant: + genomicVariantEndpoints: entryType: genomicVariant openAPIEndpointsDefinition: https://exampleBeacons.org/genomicVariations/endpoints.json rootUrl: https://exampleBeacons.org/g_variants singleEntryUrl: https://exampleBeacons.org/g_variants/{id} endpoints: - biosample: + biosampleLookup: returnedEntryType: biosample url: https://exampleBeacons.org/g_variants/{id}/biosamples - individual: + individualLookup: returnedEntryType: individual url: https://exampleBeacons.org/g_variants/{id}/individuals - runs: + runLookup: returnedEntryType: run url: https://exampleBeacons.org/g_variants/{id}/runs - analyses: + analysisLookup: returnedEntryType: analysis url: https://exampleBeacons.org/g_variants/{id}/analyses - individual: + individualEndpoints: entryType: individual openAPIEndpointsDefinition: https://exampleBeacons.org/individuals/endpoints.json rootUrl: https://exampleBeacons.org/individuals singleEntryUrl: https://exampleBeacons.org/individuals/{id} filteringTermsUrl: https://exampleBeacons.org/individuals/{id}/filtering_terms endpoints: - genomicVariant: + genomicVariantLookup: returnedEntryType: genomicVariant url: https://exampleBeacons.org/individuals/{id}/g_variants - biosample: + biosampleLookup: returnedEntryType: biosample url: https://exampleBeacons.org/individuals/{id}/biosamples - runs: + runLookup: returnedEntryType: run url: https://exampleBeacons.org/individuals/{id}/runs - analyses: + analysisLookup: returnedEntryType: analysis url: https://exampleBeacons.org/individuals/{id}/analyses - biosample: + biosampleEndpoints: entryType: biosample openAPIEndpointsDefinition: https://exampleBeacons.org/biosamples/endpoints.json rootUrl: https://exampleBeacons.org/biosamples singleEntryUrl: https://exampleBeacons.org/biosamples/{id} endpoints: - run: + runLookup: returnedEntryType: run url: https://exampleBeacons.org/biosamples/{id}/runs - analysis: + analysisLookup: returnedEntryType: analysis url: https://exampleBeacons.org/biosamples/{id}/analyses - genomicVariant: + genomicVariantLookup: returnedEntryType: genomicVariant url: https://exampleBeacons.org/biosamples/{id}/g_variants - run: + runEndpoints: entryType: run openAPIEndpointsDefinition: https://exampleBeacons.org/runs/endpoints.json rootUrl: https://exampleBeacons.org/runs singleEntryUrl: https://exampleBeacons.org/runs/{id} endpoints: - analysis: + analysisLookup: returnedEntryType: analysis url: https://exampleBeacons.org/runs/{id}/analyses - genomicVariant: + genomicVariantLookup: returnedEntryType: genomicVariant url: https://exampleBeacons.org/runs/{id}/g_variants - analysis: + analysisEndpoints: entryType: analysis openAPIEndpointsDefinition: https://exampleBeacons.org/analyses/endpoints.json rootUrl: https://exampleBeacons.org/analyses singleEntryUrl: https://exampleBeacons.org/analyses/{id} endpoints: - genomicVariant: + genomicVariantLookup: returnedEntryType: genomicVariant url: https://exampleBeacons.org/analyses/{id}/g_variants From de829f38908493751d38a8fc9278a339d16bc9e8 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 13 Jul 2024 16:51:32 +0200 Subject: [PATCH 16/37] updated CNV term mapping table This brings it in line with the hCNV version where it is being maintained (adjustment for VRS official status etc.). See https://cnvar.org/resources/CNV-annotation-standards/ --- docs/variant-queries.md | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/docs/variant-queries.md b/docs/variant-queries.md index 698ccc016..9ffc7e393 100644 --- a/docs/variant-queries.md +++ b/docs/variant-queries.md @@ -374,18 +374,19 @@ values to underlying genomic variations had not been precisely defined. This table is maintained in parallel with the [hCNV community documentation](https://cnvar.org/resources/CNV-annotation-standards/#cnv-term-use-comparison-in-computational-fileschema-formats). -| [EFO](https://www.ebi.ac.uk/efo/EFO_0030063) | Beacon | [VCF](https://samtools.github.io/hts-specs/) | SO | GA4GH [VRS](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) ⇒
[VRS proposal](https://github.com/ga4gh/vrs/issues/404)[^1] | Notes | +| [EFO](http://www.ebi.ac.uk/efo/EFO_0030063) | Beacon | [VCF](https://samtools.github.io/hts-specs/) | SO | GA4GH [VRS](https://vrs.ga4gh.org/en/latest/terms_and_model.html#copynumberchange)[^1] | Notes | | ------------------------------------------- | ------------------------------------------------------------------------------ | -------------------------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ----- | -| [`EFO:0030070`](https://www.ebi.ac.uk/efo/EFO_0030070) copy number gain | `DUP`[^2] or
[`EFO:0030070`](https://www.ebi.ac.uk/efo/EFO_0030070) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](https://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`low-level gain`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) (implicit) ⇒ [`EFO:0030070`](https://www.ebi.ac.uk/efo/EFO_0030070) copy number gain | a sequence alteration whereby the copy number of a given genomic region is greater than the reference sequence | -| [`EFO:0030071`](https://www.ebi.ac.uk/efo/EFO_0030071) low-level copy number gain| `DUP`[^2] or
[`EFO:0030071`](https://www.ebi.ac.uk/efo/EFO_0030071) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](https://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`low-level gain`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) ⇒ [`EFO:0030071`](https://www.ebi.ac.uk/efo/EFO_0030071) low-level copy number gain | | -| [`EFO:0030072`](https://www.ebi.ac.uk/efo/EFO_0030072) high-level copy number gain | `DUP`[^2] or
[`EFO:0030072`](https://www.ebi.ac.uk/efo/EFO_0030072) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](https://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`high-level gain`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) ⇒ [`EFO:0030072`](https://www.ebi.ac.uk/efo/EFO_0030072) high-level copy number gain | commonly but not consistently used for >=5 copies on a bi-allelic genome region | -| [`EFO:0030073`](https://www.ebi.ac.uk/efo/EFO_0030073) focal genome amplification | `DUP`[^2] or
[`EFO:0030073`](https://www.ebi.ac.uk/efo/EFO_0030073) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](https://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`high-level gain`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) ⇒ [`EFO:0030073`](https://www.ebi.ac.uk/efo/EFO_0030073) focal genome amplification | commonly but not consistently used for >=5 copies on a bi-allelic genome region, of limited size (operationally max. 1-5Mb) | -| [`EFO:0030067`](https://www.ebi.ac.uk/efo/EFO_0030067) copy number loss | `DEL`[^2] or
[`EFO:0030067`](https://www.ebi.ac.uk/efo/EFO_0030067) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](https://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`partial loss`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) (implicit) ⇒ [`EFO:0030067`](https://www.ebi.ac.uk/efo/EFO_0030067) copy number loss | a sequence alteration whereby the copy number of a given genomic region is smaller than the reference sequence | -| [`EFO:0030068`](https://www.ebi.ac.uk/efo/EFO_0030068) low-level copy number loss | `DEL`[^2] or
[`EFO:0030068`](https://www.ebi.ac.uk/efo/EFO_0030068) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](https://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`partial loss`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) ⇒ [`EFO:0030068`](https://www.ebi.ac.uk/efo/EFO_0030068) low-level copy number loss | | -| [`EFO:0020073`](https://www.ebi.ac.uk/efo/EFO_0020073) high-level copy number loss | `DEL`[^2] or
[`EFO:0020073`](https://github.com/EBISPOT/efo/issues/1941) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](https://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`partial loss`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) ⇒ [`EFO:0020073`](https://github.com/EBISPOT/efo/issues/1941) high-level copy number loss | a loss of several copies; also used in cases where a complete genomic deletion cannot be asserted | -| [`EFO:0030069`](https://www.ebi.ac.uk/efo/EFO_0030069) complete genomic deletion | `DEL`[^2] or
[`EFO:0030069`](https://www.ebi.ac.uk/efo/EFO_0030069) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](https://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`complete loss`](https://vrs.ga4gh.org/en/latest/terms_and_model.html#relativecopynumber) ⇒ [`EFO:0030069`](https://www.ebi.ac.uk/efo/EFO_0030069) complete genomic deletion | complete genomic deletion (e.g. homozygous deletion on a bi-allelic genome region) | - -##### Last updated 2023-03-22 by @mbaudis (EFO:0020073) +| [`EFO:0030070`](http://www.ebi.ac.uk/efo/EFO_0030070) copy number gain | `DUP`[^2] or
[`EFO:0030070`](http://www.ebi.ac.uk/efo/EFO_0030070) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](http://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`EFO:0030070`](http://www.ebi.ac.uk/efo/EFO_0030070) gain | a sequence alteration whereby the copy number of a given genomic region is greater than the reference sequence | +| [`EFO:0030071`](http://www.ebi.ac.uk/efo/EFO_0030071) low-level copy number gain| `DUP`[^2] or
[`EFO:0030071`](http://www.ebi.ac.uk/efo/EFO_0030071) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](http://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`EFO:0030071`](http://www.ebi.ac.uk/efo/EFO_0030071) low-level gain | | +| [`EFO:0030072`](http://www.ebi.ac.uk/efo/EFO_0030072) high-level copy number gain | `DUP`[^2] or
[`EFO:0030072`](http://www.ebi.ac.uk/efo/EFO_0030072) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](http://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`EFO:0030072`](http://www.ebi.ac.uk/efo/EFO_0030072) high-level gain | commonly but not consistently used for >=5 copies on a bi-allelic genome region | +| [`EFO:0030073`](http://www.ebi.ac.uk/efo/EFO_0030073) focal genome amplification | `DUP`[^2] or
[`EFO:0030073`](http://www.ebi.ac.uk/efo/EFO_0030073) | `DUP`
`SVCLAIM=D`[^3] | [`SO:0001742`](http://www.sequenceontology.org/browser/current_release/term/SO:0001742) copy_number_gain | [`EFO:0030072`](http://www.ebi.ac.uk/efo/EFO_0030072) high-level gain[^4] | commonly but not consistently used for >=5 copies on a bi-allelic genome region, of limited size (operationally max. 1-5Mb) | +| [`EFO:0030067`](http://www.ebi.ac.uk/efo/EFO_0030067) copy number loss | `DEL`[^2] or
[`EFO:0030067`](http://www.ebi.ac.uk/efo/EFO_0030067) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](http://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`EFO:0030067`](http://www.ebi.ac.uk/efo/EFO_0030067) loss | a sequence alteration whereby the copy number of a given genomic region is smaller than the reference sequence | +| [`EFO:0030068`](http://www.ebi.ac.uk/efo/EFO_0030068) low-level copy number loss | `DEL`[^2] or
[`EFO:0030068`](http://www.ebi.ac.uk/efo/EFO_0030068) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](http://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`EFO:0030068`](http://www.ebi.ac.uk/efo/EFO_0030068) low-level loss | | +| [`EFO:0020073`](http://www.ebi.ac.uk/efo/EFO_0020073) high-level copy number loss | `DEL`[^2] or
[`EFO:0020073`](https://github.com/EBISPOT/efo/issues/1941) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](http://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`EFO:0020073`](https://github.com/EBISPOT/efo/issues/1941) high-level loss | a loss of several copies; also used in cases where a complete genomic deletion cannot be asserted | +| [`EFO:0030069`](http://www.ebi.ac.uk/efo/EFO_0030069) complete genomic deletion | `DEL`[^2] or
[`EFO:0030069`](http://www.ebi.ac.uk/efo/EFO_0030069) | `DEL`
`SVCLAIM=D`[^3] | [`SO:0001743`](http://www.sequenceontology.org/browser/current_release/term/SO:0001743) copy_number_loss | [`EFO:0030069`](http://www.ebi.ac.uk/efo/EFO_0030069) complete genomic loss | complete genomic deletion (e.g. homozygous deletion on a bi-allelic genome region) | + + +##### Last updated 2023-07-13 to align with 2023-03-22 hCNV documentation (VRS 1.3 adjustment) by @mbaudis ##### updated 2023-03-20 by @mbaudis (VRS proposal) ## Query Parameter Change Log @@ -417,17 +418,17 @@ recommended for query forms and `alternateBases` -[^1]: The VRS annotations refer to the status at v1.2 (2022). The GA4GH VRS team -is currently (Spring 2023) preparing an updated specification which will introduce -the new class `CopyNumberChange` ([discussion...](https://github.com/ga4gh/vrs/issues/404#issuecomment-1472599849)) with the use of the EFO terms (including a new term -for `high level deletion (EFO:0020073)` in the April 2023 EFO release). +[^1]: The VRS annotations refer to the status from v1.3 (2022) when +the new class `CopyNumberChange` ([discussion...](https://github.com/ga4gh/vrs/issues/404#issuecomment-1472599849)) +with the use of the EFO terms. [^2]: While the use of VCF derived (`DUP`, `DEL`) values had been introduced with beacon v1, usage of these terms has always been a _recommendation_ rather than an integral part of the API. We now encourage the support of more specific terms (particularly EFO) -by Beacon developers. As example, the Progentix Beacon API [uses EFO terms](https://progenetix.org/search/) but +by Beacon developers. As example, the Progentix Beacon API [uses EFO terms](http://progenetix.org/search/) but provides an internal term expansion for legacy `DUP`, `DEL` support. [^3]: VCFv4.4 introduces an `SVCLAIM` field to disambiguate between _in situ_ events (such as tandem duplications; known _adjacency_/ _break junction_: `SVCLAIM=J`) and events where e.g. only the change in _abundance_ / _read depth_ (`SVCLAIM=D`) has been determined. Both **J** and **D** flags can be combined. +[^4]: VRS did not adopt the "amplification" term due to possible inconsistencies From 18eff1cd645c312fe17f205b0b22e49ce5fb356a Mon Sep 17 00:00:00 2001 From: Oriol Lopez-Doriga Date: Tue, 16 Jul 2024 10:42:38 +0200 Subject: [PATCH 17/37] deleting aggregated from Granularity enum --- framework/json/common/beaconCommonComponents.json | 1 - framework/src/common/beaconCommonComponents.yaml | 1 - 2 files changed, 2 deletions(-) diff --git a/framework/json/common/beaconCommonComponents.json b/framework/json/common/beaconCommonComponents.json index 768d938c4..f53235861 100644 --- a/framework/json/common/beaconCommonComponents.json +++ b/framework/json/common/beaconCommonComponents.json @@ -80,7 +80,6 @@ "enum": [ "boolean", "count", - "aggregated", "record" ], "type": "string" diff --git a/framework/src/common/beaconCommonComponents.yaml b/framework/src/common/beaconCommonComponents.yaml index 53296705a..09b1340b9 100644 --- a/framework/src/common/beaconCommonComponents.yaml +++ b/framework/src/common/beaconCommonComponents.yaml @@ -147,7 +147,6 @@ definitions: enum: - boolean - count - - aggregated - record default: boolean TestMode: From 556e5b5bc11f37b1cc1c1a718c00c1ea6501720a Mon Sep 17 00:00:00 2001 From: Oriol Lopez-Doriga Date: Tue, 16 Jul 2024 10:45:31 +0200 Subject: [PATCH 18/37] deleting aggregated from Granularity description --- framework/json/common/beaconCommonComponents.json | 2 +- framework/src/common/beaconCommonComponents.yaml | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/framework/json/common/beaconCommonComponents.json b/framework/json/common/beaconCommonComponents.json index f53235861..a6b922664 100644 --- a/framework/json/common/beaconCommonComponents.json +++ b/framework/json/common/beaconCommonComponents.json @@ -76,7 +76,7 @@ }, "Granularity": { "default": "boolean", - "description": "Level of detail of the response:\n* `boolean`: returns true/false' responses * `count`: adds the total number of positive results found * `aggregated`: returns summary, aggregated or distribution like responses * `record`: returns details for every row. In cases where a Beacon prefers to return records with fewer than allattributes, different strategies have to be considered w/o adding them to the current design, e.g.:\n - keeping non-mandatory attributes empty\n - Beacon to provide a minimal record definition", + "description": "Level of detail of the response:\n* `boolean`: returns true/false' responses * `count`: adds the total number of positive results found * `record`: returns details for every row. In cases where a Beacon prefers to return records with fewer than allattributes, different strategies have to be considered w/o adding them to the current design, e.g.:\n - keeping non-mandatory attributes empty\n - Beacon to provide a minimal record definition", "enum": [ "boolean", "count", diff --git a/framework/src/common/beaconCommonComponents.yaml b/framework/src/common/beaconCommonComponents.yaml index 09b1340b9..f8f479fa5 100644 --- a/framework/src/common/beaconCommonComponents.yaml +++ b/framework/src/common/beaconCommonComponents.yaml @@ -137,7 +137,6 @@ definitions: * `boolean`: returns true/false' responses * `count`: adds the total number of positive results found - * `aggregated`: returns summary, aggregated or distribution like responses * `record`: returns details for every row. In cases where a Beacon prefers to return records with fewer than allattributes, different strategies have to be considered w/o adding them to the current design, e.g.: From a6fe8ada50c47429b0b5fa6406cf2b3766231a1e Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Wed, 17 Jul 2024 13:47:28 +0200 Subject: [PATCH 19/37] Cleanup of descriptions in endpoints files The OpenAPI `endpoints` files included a number of leftover or potentially misleading descripions, e.g.: * "get a list of..." as description for responses, although responses depend on granularity and delivered in different Beacon response schemas * frequent use of "variant" instead "variation" * some wrong labels (e.g. C&P errors or leftover "examples" response) Additionally the leftover commented lines from the yamlerRunner have been removed. --- bin/yamlerRunner.sh | 15 ------- .../analyses/endpoints.json | 12 +++--- .../biosamples/endpoints.json | 24 +++++------ .../cohorts/endpoints.json | 12 +++--- .../datasets/endpoints.json | 18 ++++---- .../genomicVariations/endpoints.json | 24 +++++------ .../individuals/endpoints.json | 12 +++--- .../runs/endpoints.json | 20 ++++----- .../analyses/endpoints.yaml | 20 +++++---- .../biosamples/endpoints.yaml | 42 +++++++++++-------- .../cohorts/endpoints.yaml | 20 +++++---- .../datasets/endpoints.yaml | 30 ++++++++----- .../genomicVariations/endpoints.yaml | 40 ++++++++++-------- .../individuals/endpoints.yaml | 20 +++++---- .../runs/endpoints.yaml | 31 ++++++++------ 15 files changed, 181 insertions(+), 159 deletions(-) diff --git a/bin/yamlerRunner.sh b/bin/yamlerRunner.sh index a7821edfa..f6c16395b 100755 --- a/bin/yamlerRunner.sh +++ b/bin/yamlerRunner.sh @@ -1,28 +1,13 @@ BASEDIR=$(dirname $0) UNITYPATH=$BASEDIR/.. - -# initial conversion from separate schemas -# DEPRECATED -# BEACONMODELPATH=$BASEDIR/../../beacon-v2-Models/BEACON-V2-Model -# BEACONFRAMEWORKPATH=$BASEDIR/../../beacon-framework-v2 - BEACONMODELNAME=beacon-v2-default-model -# for UPSTREAM in $BEACONMODELPATH $BEACONFRAMEWORKPATH -# do -# echo "pulling $UPSTREAM" -# git -C $UPSTREAM pull -# done - for KIND in src json do mkdir -p $UNITYPATH/models/$KIND/$BEACONMODELNAME mkdir -p $UNITYPATH/framework/$KIND done -# $BASEDIR/beaconYamler.py -i $BEACONMODELPATH -t json -x yaml -o $UNITYPATH/models/src/$BEACONMODELNAME -# $BASEDIR/beaconYamler.py -i $BEACONFRAMEWORKPATH -t json -x yaml -o $UNITYPATH/framework/src - # recurring conversion from the source files to the exported versions $BASEDIR/beaconYamler.py -i $UNITYPATH/models/src/$BEACONMODELNAME -t yaml -x json -o $UNITYPATH/models/json/$BEACONMODELNAME $BASEDIR/beaconYamler.py -i $UNITYPATH/framework/src -t yaml -x json -o $UNITYPATH/framework/json diff --git a/models/json/beacon-v2-default-model/analyses/endpoints.json b/models/json/beacon-v2-default-model/analyses/endpoints.json index 570d7201d..62387053c 100644 --- a/models/json/beacon-v2-default-model/analyses/endpoints.json +++ b/models/json/beacon-v2-default-model/analyses/endpoints.json @@ -91,7 +91,7 @@ "paths": { "/analyses": { "get": { - "description": "Get a list of bioinformatics analysis", + "description": "Get a Beacon response for bioinformatics analyses", "operationId": "getAnalyses", "parameters": [ { @@ -123,7 +123,7 @@ ] }, "post": { - "description": "Get a list of bioinformatics analysis", + "description": "Get a Beacon response for bioinformatics analyses", "operationId": "postAnalysesRequest", "requestBody": { "content": { @@ -207,8 +207,8 @@ }, "/analyses/{id}/g_variants": { "get": { - "description": "Get the list of variants instances for one bioinformatics analysis, identified by its (unique) 'id'", - "operationId": "getOneAnalysisVariants", + "description": "Get a *genomic variations* response for one bioinformatics analysis, identified by its (unique) 'id'", + "operationId": "getOneAnalysisVariationsRequest", "parameters": [ { "$ref": "#/components/parameters/requestedSchema" @@ -239,8 +239,8 @@ } ], "post": { - "description": "Get the list of variants instances for one bioinformatics analysis, identified by its (unique) 'id'", - "operationId": "postOneAnalysisVariantsRequest", + "description": "Get a *genomic variations* response for one bioinformatics analysis, identified by its (unique) 'id'", + "operationId": "postOneAnalysisVariationsRequest", "requestBody": { "content": { "application/json": { diff --git a/models/json/beacon-v2-default-model/biosamples/endpoints.json b/models/json/beacon-v2-default-model/biosamples/endpoints.json index 533d5ceda..c9c94bfa5 100644 --- a/models/json/beacon-v2-default-model/biosamples/endpoints.json +++ b/models/json/beacon-v2-default-model/biosamples/endpoints.json @@ -95,7 +95,7 @@ "paths": { "/biosamples": { "get": { - "description": "Get a list of biosamples", + "description": "Get a Beacon response for biosamples", "operationId": "getBiosamples", "parameters": [ { @@ -127,7 +127,7 @@ ] }, "post": { - "description": "Get a list of biosamples", + "description": "Get a Beacon response for biosamples", "operationId": "postBiosamplesRequest", "requestBody": { "content": { @@ -204,8 +204,8 @@ }, "/biosamples/{id}/analyses": { "get": { - "description": "Get the analysis list from one biosample, identified by its (unique) 'id'", - "operationId": "getOneBiosampleAnalysis", + "description": "Get an *analyses* response from one biosample, identified by its (unique) 'id'", + "operationId": "getOneBiosampleAnalyses", "parameters": [ { "$ref": "#/components/parameters/requestedSchema" @@ -236,8 +236,8 @@ } ], "post": { - "description": "Get the analysis list from one biosample, identified by its (unique) 'id'", - "operationId": "postOneBiosampleAnalysis", + "description": "Get an *analyses* response from one biosample, identified by its (unique) 'id'", + "operationId": "postOneBiosampleAnalyses", "requestBody": { "content": { "application/json": { @@ -264,8 +264,8 @@ }, "/biosamples/{id}/g_variants": { "get": { - "description": "Get the genomic variants list from one biosample, identified by its (unique) 'id'", - "operationId": "getOneBiosampleGenomicVariants", + "description": "Get a *genomic variations* response from one biosample, identified by its (unique) 'id'", + "operationId": "getOneBiosampleGenomicVariations", "parameters": [ { "$ref": "#/components/parameters/requestedSchema" @@ -296,8 +296,8 @@ } ], "post": { - "description": "Get the genomic variants list from one biosample, identified by its (unique) 'id'", - "operationId": "postOneBiosampleGenomicVariants", + "description": "Get a *genomic variations* response from one biosample, identified by its (unique) 'id'", + "operationId": "postOneBiosampleGenomicVariations", "requestBody": { "content": { "application/json": { @@ -324,7 +324,7 @@ }, "/biosamples/{id}/runs": { "get": { - "description": "Get the runs list from one biosample, identified by its (unique) 'id'", + "description": "Get a *runs* response from one biosample, identified by its (unique) 'id'", "operationId": "getOneBiosampleRuns", "parameters": [ { @@ -363,7 +363,7 @@ } ], "post": { - "description": "Get the runs list from one biosample, identified by its (unique) 'id'", + "description": "Get a *runs* response from one biosample, identified by its (unique) 'id'", "operationId": "postOneBiosampleRuns", "requestBody": { "content": { diff --git a/models/json/beacon-v2-default-model/cohorts/endpoints.json b/models/json/beacon-v2-default-model/cohorts/endpoints.json index 1e36b7462..588b0746e 100644 --- a/models/json/beacon-v2-default-model/cohorts/endpoints.json +++ b/models/json/beacon-v2-default-model/cohorts/endpoints.json @@ -108,7 +108,7 @@ "paths": { "/cohorts": { "get": { - "description": "Get a list of cohorts", + "description": "Get a Beacon *cohorts* response", "operationId": "getCohorts", "parameters": [ { @@ -137,7 +137,7 @@ ] }, "post": { - "description": "Get a list of cohorts", + "description": "Get a Beacon *cohorts* response", "operationId": "postCohortsRequest", "requestBody": { "content": { @@ -219,7 +219,7 @@ }, "/cohorts/{id}/filtering_terms": { "get": { - "description": "Get the list of filtering terms that could be used with a given cohort, identified by its (unique) 'id'", + "description": "Get a response about the *filtering terms* that could be used with a given cohort, identified by its (unique) 'id'", "operationId": "getOneCohortFilteringTerms", "parameters": [ { @@ -255,7 +255,7 @@ } ], "post": { - "description": "Get the list of filtering terms that could be used with a given cohort, identified by its (unique) 'id'", + "description": "Get a response about the *filtering terms* that could be used with a given cohort, identified by its (unique) 'id'", "operationId": "postOneCohortFilteringTerms", "requestBody": { "content": { @@ -290,7 +290,7 @@ }, "/cohorts/{id}/individuals": { "get": { - "description": "Get the individuals from one cohort, identified by its (unique) 'id'", + "description": "Get an *individuals* response for one cohort, identified by its (unique) 'id'", "operationId": "getOneCohortIndividuals", "parameters": [ { @@ -322,7 +322,7 @@ } ], "post": { - "description": "Get the individuals from one cohort, identified by its (unique) 'id'", + "description": "Get an *individuals* response for one cohort, identified by its (unique) 'id'", "operationId": "postOneCohortEntries", "requestBody": { "content": { diff --git a/models/json/beacon-v2-default-model/datasets/endpoints.json b/models/json/beacon-v2-default-model/datasets/endpoints.json index 3fdc832a4..56079f6e2 100644 --- a/models/json/beacon-v2-default-model/datasets/endpoints.json +++ b/models/json/beacon-v2-default-model/datasets/endpoints.json @@ -135,7 +135,7 @@ ] }, "post": { - "description": "Get a list of datasets", + "description": "Get a Beacon *datasets* response", "operationId": "postDatasetsRequest", "requestBody": { "content": { @@ -217,7 +217,7 @@ }, "/datasets/{id}/biosamples": { "get": { - "description": "Get the biosamples list from one dataset, identified by its (unique) 'id'", + "description": "Get a *biosamples* response for one dataset, identified by its (unique) 'id'", "operationId": "getOneDatasetBiosamples", "parameters": [ { @@ -249,7 +249,7 @@ } ], "post": { - "description": "Get the biosamples list from one dataset, identified by its (unique) 'id'", + "description": "Get a *biosamples* response for one dataset, identified by its (unique) 'id'", "operationId": "postOneDatasetBiosamples", "requestBody": { "content": { @@ -277,7 +277,7 @@ }, "/datasets/{id}/filtering_terms": { "get": { - "description": "Get the list of filtering terms that could be used with a given dataset, identified by its (unique) 'id'", + "description": "Get a response about the *filtering terms* that could be used with a given dataset, identified by its (unique) 'id'", "operationId": "getOneDatasetFilteringTerms", "parameters": [ { @@ -313,7 +313,7 @@ } ], "post": { - "description": "Get the list of filtering terms that could be used with a given dataset, identified by its (unique) 'id'", + "description": "Get a response about the *filtering terms* that could be used with a given dataset, identified by its (unique) 'id'", "operationId": "postOneDatasetFilteringTerms", "requestBody": { "content": { @@ -348,7 +348,7 @@ }, "/datasets/{id}/g_variants": { "get": { - "description": "Get the genomic variants list from one dataset, identified by its (unique) 'id'", + "description": "Get a *genomic variations* response for one dataset, identified by its (unique) 'id'", "operationId": "getOneDatasetEntries", "parameters": [ { @@ -380,7 +380,7 @@ } ], "post": { - "description": "Get the genomic variants list from one dataset, identified by its (unique) 'id'", + "description": "Get a *genomic variations* response for one dataset, identified by its (unique) 'id'", "operationId": "postOneDatasetEntries", "requestBody": { "content": { @@ -408,7 +408,7 @@ }, "/datasets/{id}/individuals": { "get": { - "description": "Get the individuals list from one dataset, identified by its (unique) 'id'", + "description": "Get an *individuals* response for one dataset, identified by its (unique) 'id'", "operationId": "getOneDatasetIndividuals", "parameters": [ { @@ -440,7 +440,7 @@ } ], "post": { - "description": "Get the biosamples list from one dataset, identified by its (unique) 'id'", + "description": "Get an *individuals* response for one dataset, identified by its (unique) 'id'", "operationId": "postOneDatasetIndividuals", "requestBody": { "content": { diff --git a/models/json/beacon-v2-default-model/genomicVariations/endpoints.json b/models/json/beacon-v2-default-model/genomicVariations/endpoints.json index e9101f04f..4ba82ba62 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/endpoints.json +++ b/models/json/beacon-v2-default-model/genomicVariations/endpoints.json @@ -193,8 +193,8 @@ "paths": { "/g_variants": { "get": { - "description": "Get a list of example entries", - "operationId": "getExampleEntries", + "description": "Get a Beacon response for genomic variations", + "operationId": "getGenomicVariations", "parameters": [ { "$ref": "#/components/parameters/requestedSchema" @@ -258,8 +258,8 @@ ] }, "post": { - "description": "Get a list of example entries", - "operationId": "postExampleEntriesRequest", + "description": "Get a Beacon response for genomic variations", + "operationId": "postGenomicVariationsRequest", "requestBody": { "content": { "application/json": { @@ -335,8 +335,8 @@ }, "/g_variants/{id}/biosamples": { "get": { - "description": "Get the biosamples list from one genomic variant, identified by its (unique) 'id'", - "operationId": "getOneGenomicVariantBiosamples", + "description": "Get a *biosamples* response from one genomic variant, identified by its (unique) 'id'", + "operationId": "getOneGenomicVariationBiosamples", "parameters": [ { "$ref": "#/components/parameters/requestedSchema" @@ -367,8 +367,8 @@ } ], "post": { - "description": "Get the biosamples list from one genomic variant, identified by its (unique) 'id'", - "operationId": "postOneGenomicVariantBiosamples", + "description": "Get a *biosamples* response from one genomic variant, identified by its (unique) 'id'", + "operationId": "postOneGenomicVariationBiosamples", "requestBody": { "content": { "application/json": { @@ -395,8 +395,8 @@ }, "/g_variants/{id}/individuals": { "get": { - "description": "Get the individuals list from one genomic variant, identified by its (unique) 'id'", - "operationId": "getOneGenomicVariantIndividuals", + "description": "Get an *individuals* response from one genomic variant, identified by its (unique) 'id'", + "operationId": "getOneGenomicVariationIndividuals", "parameters": [ { "$ref": "#/components/parameters/requestedSchema" @@ -427,8 +427,8 @@ } ], "post": { - "description": "Get the biosamples list from one genomic variant, identified by its (unique) 'id'", - "operationId": "postOneGenomicVariantIndividuals", + "description": "Get an *individuals* response from one genomic variant, identified by its (unique) 'id'", + "operationId": "postOneGenomicVariationIndividuals", "requestBody": { "content": { "application/json": { diff --git a/models/json/beacon-v2-default-model/individuals/endpoints.json b/models/json/beacon-v2-default-model/individuals/endpoints.json index 32898cb17..9da047ddd 100644 --- a/models/json/beacon-v2-default-model/individuals/endpoints.json +++ b/models/json/beacon-v2-default-model/individuals/endpoints.json @@ -123,7 +123,7 @@ ] }, "post": { - "description": "Get a list of example entries", + "description": "Get a Beacon response for individuals", "operationId": "postIndividualsRequest", "requestBody": { "content": { @@ -238,7 +238,7 @@ } ], "post": { - "description": "Get details about one Individual, identified by its (unique) 'id'", + "description": "Get details about one individual, identified by its (unique) 'id'", "operationId": "postOneIndividual", "requestBody": { "content": { @@ -266,7 +266,7 @@ }, "/individuals/{id}/biosamples": { "get": { - "description": "Get the biosamples list from one individual, identified by its (unique) 'id'", + "description": "Get a *biosamples* response for one individual, identified by its (unique) 'id'", "operationId": "getOneIndividualBiosamples", "parameters": [ { @@ -298,7 +298,7 @@ } ], "post": { - "description": "Get the biosamples list from one individual, identified by its (unique) 'id'", + "description": "Get a *biosamples* response for one individual, identified by its (unique) 'id'", "operationId": "postOneIndividualBiosamples", "requestBody": { "content": { @@ -326,7 +326,7 @@ }, "/individuals/{id}/g_variants": { "get": { - "description": "Get the genomic variants list from one individual, identified by its (unique) 'id'", + "description": "Get a *genomic variations* response for one individual, identified by its (unique) 'id'", "operationId": "getOneIndividualGenomicVariants", "parameters": [ { @@ -358,7 +358,7 @@ } ], "post": { - "description": "Get the genomic variants list from one individual, identified by its (unique) 'id'", + "description": "Get a *genomic variations* response for one individual, identified by its (unique) 'id'", "operationId": "potOneIndividualGenomicVariants", "requestBody": { "content": { diff --git a/models/json/beacon-v2-default-model/runs/endpoints.json b/models/json/beacon-v2-default-model/runs/endpoints.json index b5084bba7..06283d53b 100644 --- a/models/json/beacon-v2-default-model/runs/endpoints.json +++ b/models/json/beacon-v2-default-model/runs/endpoints.json @@ -107,7 +107,7 @@ "paths": { "/runs": { "get": { - "description": "Get a list of sequencing runs", + "description": "Get a Beacon response for experimental runs", "operationId": "getRuns", "parameters": [ { @@ -139,7 +139,7 @@ ] }, "post": { - "description": "Get a list of sequencing runs", + "description": "Get a Beacon response for experimental runs", "operationId": "postRunsRequest", "requestBody": { "content": { @@ -167,7 +167,7 @@ }, "/runs/{id}": { "get": { - "description": "Get details about one sequencing run, identified by its (unique) 'id'", + "description": "Get details about one experimental run, identified by its (unique) 'id'", "operationId": "getOneRun", "responses": { "200": { @@ -188,7 +188,7 @@ } ], "post": { - "description": "Get details about one Run, identified by its (unique) 'id'", + "description": "Get details about one experimental run, identified by its (unique) 'id'", "operationId": "postOneRun", "requestBody": { "content": { @@ -216,7 +216,7 @@ }, "/runs/{id}/analyses": { "get": { - "description": "Get the analysis list from one sequencing run, identified by its (unique) 'id'", + "description": "Get a *analyses* response for one experimental run, identified by its (unique) 'id'", "operationId": "getOneRunAnalysis", "parameters": [ { @@ -248,7 +248,7 @@ } ], "post": { - "description": "Get the analysis list from one sequencing run, identified by its (unique) 'id'", + "description": "Get a *analyses* response for one experimental run, identified by its (unique) 'id'", "operationId": "postOneRunAnalysis", "requestBody": { "content": { @@ -276,8 +276,8 @@ }, "/runs/{id}/g_variants": { "get": { - "description": "Get the genomic variants list from one run, identified by its (unique) 'id'", - "operationId": "getOneRunGenomicVariants", + "description": "Get a *genomic variations* response for one experimental run, identified by its (unique) 'id'", + "operationId": "getOneRunGenomicVariations", "parameters": [ { "$ref": "#/components/parameters/requestedSchema" @@ -308,8 +308,8 @@ } ], "post": { - "description": "Get the genomic variants list from one run, identified by its (unique) 'id'", - "operationId": "potOneRunGenomicVariants", + "description": "Get a *genomic variations* response for one experimental run, identified by its (unique) 'id'", + "operationId": "potOneRunGenomicVariations", "requestBody": { "content": { "application/json": { diff --git a/models/src/beacon-v2-default-model/analyses/endpoints.yaml b/models/src/beacon-v2-default-model/analyses/endpoints.yaml index 8f5d5457a..69d8c0249 100644 --- a/models/src/beacon-v2-default-model/analyses/endpoints.yaml +++ b/models/src/beacon-v2-default-model/analyses/endpoints.yaml @@ -18,7 +18,7 @@ paths: - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/includeResultsetResponses' - $ref: '#/components/parameters/filters' - description: Get a list of bioinformatics analysis + description: Get a Beacon response for bioinformatics analyses operationId: getAnalyses tags: - GET Endpoints @@ -28,7 +28,7 @@ paths: default: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get a list of bioinformatics analysis + description: Get a Beacon response for bioinformatics analyses operationId: postAnalysesRequest tags: - POST Endpoints @@ -52,7 +52,8 @@ paths: parameters: - $ref: '#/components/parameters/entryId' get: - description: Get details about one bioinformatics analysis, identified by its + description: >- + Get details about one bioinformatics analysis, identified by its (unique) 'id' operationId: getOneAnalysis tags: @@ -64,7 +65,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get details about one bioinformatics analysis, identified by its + description: >- + Get details about one bioinformatics analysis, identified by its (unique) 'id' operationId: postOneAnalysisRequest tags: @@ -89,9 +91,10 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the list of variants instances for one bioinformatics analysis, + description: >- + Get a *genomic variations* response for one bioinformatics analysis, identified by its (unique) 'id' - operationId: getOneAnalysisVariants + operationId: getOneAnalysisVariationsRequest tags: - GET Endpoints responses: @@ -101,9 +104,10 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the list of variants instances for one bioinformatics analysis, + description: >- + Get a *genomic variations* response for one bioinformatics analysis, identified by its (unique) 'id' - operationId: postOneAnalysisVariantsRequest + operationId: postOneAnalysisVariationsRequest tags: - POST Endpoints requestBody: diff --git a/models/src/beacon-v2-default-model/biosamples/endpoints.yaml b/models/src/beacon-v2-default-model/biosamples/endpoints.yaml index 50b80d8bb..187e8dad7 100644 --- a/models/src/beacon-v2-default-model/biosamples/endpoints.yaml +++ b/models/src/beacon-v2-default-model/biosamples/endpoints.yaml @@ -18,7 +18,7 @@ paths: - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/includeResultsetResponses' - $ref: '#/components/parameters/filters' - description: Get a list of biosamples + description: Get a Beacon response for biosamples operationId: getBiosamples tags: - GET Endpoints @@ -28,7 +28,7 @@ paths: default: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get a list of biosamples + description: Get a Beacon response for biosamples operationId: postBiosamplesRequest tags: - POST Endpoints @@ -48,7 +48,8 @@ paths: parameters: - $ref: '#/components/parameters/entryId' get: - description: Get details about one biosample, identified by its (unique) 'id' + description: >- + Get details about one biosample, identified by its (unique) 'id' operationId: getOneBiosample tags: - GET Endpoints @@ -59,7 +60,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get details about one Biosample, identified by its (unique) 'id' + description: >- + Get details about one Biosample, identified by its (unique) 'id' operationId: postOneBiosample tags: - POST Endpoints @@ -83,9 +85,10 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the genomic variants list from one biosample, identified by + description: >- + Get a *genomic variations* response from one biosample, identified by its (unique) 'id' - operationId: getOneBiosampleGenomicVariants + operationId: getOneBiosampleGenomicVariations tags: - GET Endpoints responses: @@ -95,9 +98,10 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the genomic variants list from one biosample, identified by + description: >- + Get a *genomic variations* response from one biosample, identified by its (unique) 'id' - operationId: postOneBiosampleGenomicVariants + operationId: postOneBiosampleGenomicVariations tags: - POST Endpoints requestBody: @@ -120,9 +124,10 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the analysis list from one biosample, identified by its (unique) - 'id' - operationId: getOneBiosampleAnalysis + description: >- + Get an *analyses* response from one biosample, identified by its + (unique) 'id' + operationId: getOneBiosampleAnalyses tags: - GET Endpoints responses: @@ -132,9 +137,10 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the analysis list from one biosample, identified by its (unique) - 'id' - operationId: postOneBiosampleAnalysis + description: >- + Get an *analyses* response from one biosample, identified by its + (unique) 'id' + operationId: postOneBiosampleAnalyses tags: - POST Endpoints requestBody: @@ -157,8 +163,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the runs list from one biosample, identified by its (unique) - 'id' + description: >- + Get a *runs* response from one biosample, identified by its (unique) 'id' operationId: getOneBiosampleRuns tags: - GET Endpoints @@ -173,8 +179,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the runs list from one biosample, identified by its (unique) - 'id' + description: >- + Get a *runs* response from one biosample, identified by its (unique) 'id' operationId: postOneBiosampleRuns tags: - POST Endpoints diff --git a/models/src/beacon-v2-default-model/cohorts/endpoints.yaml b/models/src/beacon-v2-default-model/cohorts/endpoints.yaml index 9fd0e999a..2b7693669 100644 --- a/models/src/beacon-v2-default-model/cohorts/endpoints.yaml +++ b/models/src/beacon-v2-default-model/cohorts/endpoints.yaml @@ -22,7 +22,7 @@ paths: - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/filters' - description: Get a list of cohorts + description: Get a Beacon *cohorts* response operationId: getCohorts tags: - GET Endpoints @@ -32,7 +32,7 @@ paths: default: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get a list of cohorts + description: Get a Beacon *cohorts* response operationId: postCohortsRequest tags: - POST Endpoints @@ -89,7 +89,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the individuals from one cohort, identified by its (unique) + description: >- + Get an *individuals* response for one cohort, identified by its (unique) 'id' operationId: getOneCohortIndividuals tags: @@ -101,7 +102,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the individuals from one cohort, identified by its (unique) + description: >- + Get an *individuals* response for one cohort, identified by its (unique) 'id' operationId: postOneCohortEntries tags: @@ -125,8 +127,9 @@ paths: parameters: - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the list of filtering terms that could be used with a given - cohort, identified by its (unique) 'id' + description: >- + Get a response about the *filtering terms* that could be used with a + given cohort, identified by its (unique) 'id' operationId: getOneCohortFilteringTerms tags: - GET Endpoints @@ -141,8 +144,9 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the list of filtering terms that could be used with a given - cohort, identified by its (unique) 'id' + description: >- + Get a response about the *filtering terms* that could be used with a + given cohort, identified by its (unique) 'id' operationId: postOneCohortFilteringTerms tags: - POST Endpoints diff --git a/models/src/beacon-v2-default-model/datasets/endpoints.yaml b/models/src/beacon-v2-default-model/datasets/endpoints.yaml index dc2c34d31..b8d70eb68 100644 --- a/models/src/beacon-v2-default-model/datasets/endpoints.yaml +++ b/models/src/beacon-v2-default-model/datasets/endpoints.yaml @@ -32,7 +32,7 @@ paths: default: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get a list of datasets + description: Get a Beacon *datasets* response operationId: postDatasetsRequest tags: - POST Endpoints @@ -89,7 +89,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the genomic variants list from one dataset, identified by its + description: >- + Get a *genomic variations* response for one dataset, identified by its (unique) 'id' operationId: getOneDatasetEntries tags: @@ -101,7 +102,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the genomic variants list from one dataset, identified by its + description: >- + Get a *genomic variations* response for one dataset, identified by its (unique) 'id' operationId: postOneDatasetEntries tags: @@ -126,7 +128,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the biosamples list from one dataset, identified by its (unique) + description: >- + Get a *biosamples* response for one dataset, identified by its (unique) 'id' operationId: getOneDatasetBiosamples tags: @@ -138,7 +141,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the biosamples list from one dataset, identified by its (unique) + description: >- + Get a *biosamples* response for one dataset, identified by its (unique) 'id' operationId: postOneDatasetBiosamples tags: @@ -163,7 +167,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the individuals list from one dataset, identified by its (unique) + description: >- + Get an *individuals* response for one dataset, identified by its (unique) 'id' operationId: getOneDatasetIndividuals tags: @@ -175,7 +180,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the biosamples list from one dataset, identified by its (unique) + description: >- + Get an *individuals* response for one dataset, identified by its (unique) 'id' operationId: postOneDatasetIndividuals tags: @@ -199,8 +205,9 @@ paths: parameters: - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the list of filtering terms that could be used with a given - dataset, identified by its (unique) 'id' + description: >- + Get a response about the *filtering terms* that could be used with a + given dataset, identified by its (unique) 'id' operationId: getOneDatasetFilteringTerms tags: - GET Endpoints @@ -215,8 +222,9 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the list of filtering terms that could be used with a given - dataset, identified by its (unique) 'id' + description: >- + Get a response about the *filtering terms* that could be used with a + given dataset, identified by its (unique) 'id' operationId: postOneDatasetFilteringTerms tags: - POST Endpoints diff --git a/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml b/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml index 44b59a736..351bccb27 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml @@ -29,8 +29,8 @@ paths: - $ref: '#/components/parameters/geneId' - $ref: '#/components/parameters/aminoacidChange' - $ref: '#/components/parameters/filters' - description: Get a list of example entries - operationId: getExampleEntries + description: Get a Beacon response for genomic variations + operationId: getGenomicVariations tags: - GET Endpoints responses: @@ -39,8 +39,8 @@ paths: default: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get a list of example entries - operationId: postExampleEntriesRequest + description: Get a Beacon response for genomic variations + operationId: postGenomicVariationsRequest tags: - POST Endpoints requestBody: @@ -59,8 +59,8 @@ paths: parameters: - $ref: '#/components/parameters/entryId' get: - description: Get details about one genomic variation, identified by its (unique) - 'id' + description: >- + Get details about one genomic variation, identified by its (unique) 'id' operationId: getOneGenomicVariation tags: - GET Endpoints @@ -71,8 +71,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get details about one genomic variation, identified by its (unique) - 'id' + description: >- + Get details about one genomic variation, identified by its (unique) 'id' operationId: postOneGenomicVariation tags: - POST Endpoints @@ -96,9 +96,10 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the biosamples list from one genomic variant, identified by - its (unique) 'id' - operationId: getOneGenomicVariantBiosamples + description: >- + Get a *biosamples* response from one genomic variant, identified by its + (unique) 'id' + operationId: getOneGenomicVariationBiosamples tags: - GET Endpoints responses: @@ -108,9 +109,10 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the biosamples list from one genomic variant, identified by - its (unique) 'id' - operationId: postOneGenomicVariantBiosamples + description: >- + Get a *biosamples* response from one genomic variant, identified by its + (unique) 'id' + operationId: postOneGenomicVariationBiosamples tags: - POST Endpoints requestBody: @@ -133,9 +135,10 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the individuals list from one genomic variant, identified by + description: >- + Get an *individuals* response from one genomic variant, identified by its (unique) 'id' - operationId: getOneGenomicVariantIndividuals + operationId: getOneGenomicVariationIndividuals tags: - GET Endpoints responses: @@ -145,9 +148,10 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the biosamples list from one genomic variant, identified by + description: >- + Get an *individuals* response from one genomic variant, identified by its (unique) 'id' - operationId: postOneGenomicVariantIndividuals + operationId: postOneGenomicVariationIndividuals tags: - POST Endpoints requestBody: diff --git a/models/src/beacon-v2-default-model/individuals/endpoints.yaml b/models/src/beacon-v2-default-model/individuals/endpoints.yaml index 7ed5a46fe..156e19851 100644 --- a/models/src/beacon-v2-default-model/individuals/endpoints.yaml +++ b/models/src/beacon-v2-default-model/individuals/endpoints.yaml @@ -28,7 +28,7 @@ paths: default: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get a list of example entries + description: Get a Beacon response for individuals operationId: postIndividualsRequest tags: - POST Endpoints @@ -48,7 +48,8 @@ paths: parameters: - $ref: '#/components/parameters/entryId' get: - description: Get details about one individual, identified by its (unique) 'id' + description: >- + Get details about one individual, identified by its (unique) 'id' operationId: getOneIndividual tags: - GET Endpoints @@ -59,7 +60,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get details about one Individual, identified by its (unique) 'id' + description: >- + Get details about one individual, identified by its (unique) 'id' operationId: postOneIndividual tags: - POST Endpoints @@ -83,7 +85,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the genomic variants list from one individual, identified by + description: >- + Get a *genomic variations* response for one individual, identified by its (unique) 'id' operationId: getOneIndividualGenomicVariants tags: @@ -95,7 +98,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the genomic variants list from one individual, identified by + description: >- + Get a *genomic variations* response for one individual, identified by its (unique) 'id' operationId: potOneIndividualGenomicVariants tags: @@ -120,7 +124,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the biosamples list from one individual, identified by its + description: >- + Get a *biosamples* response for one individual, identified by its (unique) 'id' operationId: getOneIndividualBiosamples tags: @@ -132,7 +137,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the biosamples list from one individual, identified by its + description: >- + Get a *biosamples* response for one individual, identified by its (unique) 'id' operationId: postOneIndividualBiosamples tags: diff --git a/models/src/beacon-v2-default-model/runs/endpoints.yaml b/models/src/beacon-v2-default-model/runs/endpoints.yaml index 473bea53c..9e3a97442 100644 --- a/models/src/beacon-v2-default-model/runs/endpoints.yaml +++ b/models/src/beacon-v2-default-model/runs/endpoints.yaml @@ -18,7 +18,7 @@ paths: - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/includeResultsetResponses' - $ref: '#/components/parameters/filters' - description: Get a list of sequencing runs + description: Get a Beacon response for experimental runs operationId: getRuns tags: - GET Endpoints @@ -28,7 +28,7 @@ paths: default: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get a list of sequencing runs + description: Get a Beacon response for experimental runs operationId: postRunsRequest tags: - POST Endpoints @@ -48,8 +48,8 @@ paths: parameters: - $ref: '#/components/parameters/entryId' get: - description: Get details about one sequencing run, identified by its (unique) - 'id' + description: >- + Get details about one experimental run, identified by its (unique) 'id' operationId: getOneRun tags: - GET Endpoints @@ -60,7 +60,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get details about one Run, identified by its (unique) 'id' + description: >- + Get details about one experimental run, identified by its (unique) 'id' operationId: postOneRun tags: - POST Endpoints @@ -84,9 +85,10 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the genomic variants list from one run, identified by its (unique) - 'id' - operationId: getOneRunGenomicVariants + description: >- + Get a *genomic variations* response for one experimental run, identified + by its (unique) 'id' + operationId: getOneRunGenomicVariations tags: - GET Endpoints responses: @@ -96,9 +98,10 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the genomic variants list from one run, identified by its (unique) - 'id' - operationId: potOneRunGenomicVariants + description: >- + Get a *genomic variations* response for one experimental run, identified + by its (unique) 'id' + operationId: potOneRunGenomicVariations tags: - POST Endpoints requestBody: @@ -121,7 +124,8 @@ paths: - $ref: '#/components/parameters/requestedSchema' - $ref: '#/components/parameters/skip' - $ref: '#/components/parameters/limit' - description: Get the analysis list from one sequencing run, identified by its + description: >- + Get a *analyses* response for one experimental run, identified by its (unique) 'id' operationId: getOneRunAnalysis tags: @@ -133,7 +137,8 @@ paths: description: An unsuccessful operation $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconErrorResponse.json post: - description: Get the analysis list from one sequencing run, identified by its + description: >- + Get a *analyses* response for one experimental run, identified by its (unique) 'id' operationId: postOneRunAnalysis tags: From bcec830809ebefb22500b78665318e5d00e4ffb3 Mon Sep 17 00:00:00 2001 From: Oriol Lopez-Doriga Date: Thu, 18 Jul 2024 09:55:43 +0200 Subject: [PATCH 20/37] updated changelog of versions --- README.md | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e54f57934..05aef44a8 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,29 @@ As with other schema projects, here we separate between the schema source files There is a set of tools in [`/bin`](./bin/) to facilitate the conversion. ATM, after editing `...yaml` schema files somewhere in the `/src` tree, a (local) run of `bin/yamlerRunner.sh` - which re-generates the `....json` files in the `/json` tree) has to be performed before pushing changes. -### Changes +### Changelog + +## 2.1.0 + +*To be released September, 30, 2024* + +* Relocated TypedQuantity required to proper level of the schema for complexValue +* Added end and start entities for ageRange and iso8601duration for age +* Filtering terms scopes changed from string to array of strings + +## 2.0.1 + +*Released July, 16, 2024* + +* Replaced ENSGLOSSARY for SO ontology family in documentation examples +* Moved CURIE to beaconCommonComponents +* Created filtering terms entity +* Removed validation directories +* Several fixes to entity types, typos and other non-breaking changes + +## 2.0.0 + +*Released June, 21, 2022* * change notes with respect to the repository & documentation are now in [docs.genomebeacons.org](https://docs.genomebeacons.org/changes-todo/) * NOTE: on 2022-06-20 the previous development repositories have been archived: From fb343167f8a44df5499c2b9b6f92a5a24006eee3 Mon Sep 17 00:00:00 2001 From: Oriol Lopez-Doriga Date: Thu, 18 Jul 2024 16:07:54 +0200 Subject: [PATCH 21/37] updated release date for version 2.1 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 05aef44a8..48e72a7cd 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ There is a set of tools in [`/bin`](./bin/) to facilitate the conversion. ATM, a ## 2.1.0 -*To be released September, 30, 2024* +*Released, July, 19, 2024* * Relocated TypedQuantity required to proper level of the schema for complexValue * Added end and start entities for ageRange and iso8601duration for age From 44ec3840f9580b6e0a607c628ee4ea4777d3057d Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Fri, 19 Jul 2024 10:43:33 +0200 Subject: [PATCH 22/37] update of inline descriptions in the analysis schema document * clarifications, rewording, example * no schema changes --- .../sections/beaconFilteringTermsResults.json | 32 +++++++++------ .../analyses/defaultSchema.json | 34 +++++++++------- .../beacon-v2-default-model/common/age.json | 4 +- .../common/ageRange.json | 4 +- .../common/complexValue.json | 4 +- .../genomicVariations/requestParameters.json | 6 +-- .../analyses/defaultSchema.yaml | 39 ++++++++++++------- 7 files changed, 75 insertions(+), 48 deletions(-) diff --git a/framework/json/responses/sections/beaconFilteringTermsResults.json b/framework/json/responses/sections/beaconFilteringTermsResults.json index 1755fb582..556d35993 100644 --- a/framework/json/responses/sections/beaconFilteringTermsResults.json +++ b/framework/json/responses/sections/beaconFilteringTermsResults.json @@ -21,6 +21,25 @@ ], "type": "string" }, + "scopes": { + "description": "Entry types affected by this filter.", + "examples": [ + [ + "individual", + "biosample", + "analysis", + "run", + "genomicVariation" + ], + [ + "biosample" + ] + ], + "items": { + "type": "string" + }, + "type": "array" + }, "type": { "description": "Either \"custom\", \"alphanumeric\" or ontology/terminology full name. TODO: An ontology ... with a registered prefix does not need a full name so one may better use CURIE to indicate that the resource can be retrieved from the id. This also will allow to provide an enum here.", "examples": [ @@ -28,17 +47,6 @@ "alphanumeric" ], "type": "string" - }, - "scopes": { - "description": "Entry types affected by this filter.", - "examples": [ - ["individual", "biosample", "analysis", "run", "genomicVariation"], - ["biosample"] - ], - "type": "array", - "items": { - "type": "string" - } } }, "required": [ @@ -115,4 +123,4 @@ } }, "type": "object" -} +} \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/analyses/defaultSchema.json b/models/json/beacon-v2-default-model/analyses/defaultSchema.json index e2fd84089..ef5646e01 100644 --- a/models/json/beacon-v2-default-model/analyses/defaultSchema.json +++ b/models/json/beacon-v2-default-model/analyses/defaultSchema.json @@ -2,17 +2,17 @@ "$comment": "version: ga4gh-beacon-analysis-v2.0.0", "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Schema for a sequencing bioinformatics analysis.", + "description": "The `analysis` schema represents a information about the data analysis steps leading to (a set of) genomic variation call(s).", "properties": { "aligner": { - "description": "Reference to mapping/alignment software", + "description": "Name or identifier of the mapping/alignment software/pipeline", "examples": [ "bwa-0.7.8" ], "type": "string" }, "analysisDate": { - "description": "Date at which analysis was performed.", + "description": "Date at which analysis was performed.\n", "examples": [ "2021-10-17" ], @@ -20,20 +20,22 @@ "type": "string" }, "biosampleId": { - "description": "Reference to the `id` of the biosample this analysis is reporting on.", + "description": "Local reference to the `id` of the biosample this analysis is reporting on.", "examples": [ - "S0001" + "S0001", + "onekgbs-NA07346" ], "type": "string" }, "id": { - "description": "Analysis reference ID (external accession or internal ID)", + "description": "Analysis id for internal referencing; unique in the dataset.", "type": "string" }, "individualId": { - "description": "Reference to the `id` of the individual this analysis is reporting on.", + "description": "Local reference to the `id` of the individual this analysis is reporting on.", "examples": [ - "P0001" + "P0001", + "onekgind-NA07346" ], "type": "string" }, @@ -41,30 +43,32 @@ "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info" }, "pipelineName": { - "description": "Analysis pipeline and version if a standardized pipeline was used", + "description": "Analysis pipeline and version.", "examples": [ "Pipeline-panel-0001-v1" ], "type": "string" }, "pipelineRef": { - "description": "Link to Analysis pipeline resource", + "description": "Link to information about or repository of the analysis pipeline.", "examples": [ - "https://doi.org/10.48511/workflowhub.workflow.111.1" + "https://doi.org/10.48511/workflowhub.workflow.111.1", + "https://doi.org/10.1093/bib/bbad541" ], "type": "string" }, "runId": { - "description": "Run identifier (external accession or internal ID).", + "description": "Local reference to the associated experimental run.", "examples": [ "SRR10903401" ], "type": "string" }, "variantCaller": { - "description": "Reference to variant calling software / pipeline", + "description": "Name or identifier of the variant calling software/pipeline", "examples": [ - "GATK4.0" + "GATK4.0", + "labelSeg" ], "type": "string" } @@ -74,6 +78,6 @@ "analysisDate", "pipelineName" ], - "title": "Sequencing bioinformatics analysis", + "title": "Bioinformatics analysis", "type": "object" } \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/common/age.json b/models/json/beacon-v2-default-model/common/age.json index e7f4a6c66..f6b941fde 100644 --- a/models/json/beacon-v2-default-model/common/age.json +++ b/models/json/beacon-v2-default-model/common/age.json @@ -3,7 +3,7 @@ "description": "Age value definition. Provenance: GA4GH Phenopackets v2 `Age`", "properties": { "iso8601duration": { - "description": "Represents age as a ISO8601 duration (e.g., 'P40Y10M05D').", + "description": "Represents age as a ISO8601 duration (e.g., P40Y10M05D).", "example": "P32Y6M1D", "type": "string" } @@ -13,4 +13,4 @@ ], "title": "Age", "type": "object" -} +} \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/common/ageRange.json b/models/json/beacon-v2-default-model/common/ageRange.json index 31fb79c76..1bb6ff693 100644 --- a/models/json/beacon-v2-default-model/common/ageRange.json +++ b/models/json/beacon-v2-default-model/common/ageRange.json @@ -12,8 +12,8 @@ } }, "required": [ - "end", - "start" + "start", + "end" ], "title": "AgeRange", "type": "object" diff --git a/models/json/beacon-v2-default-model/common/complexValue.json b/models/json/beacon-v2-default-model/common/complexValue.json index fd9993392..e60d69cb8 100644 --- a/models/json/beacon-v2-default-model/common/complexValue.json +++ b/models/json/beacon-v2-default-model/common/complexValue.json @@ -40,7 +40,9 @@ "type": "array" } }, - "required": [ "typedQuantities" ], + "required": [ + "typedQuantities" + ], "title": "Complex Value", "type": "object" } \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json b/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json index e469211f4..5831f13cf 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json +++ b/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json @@ -17,7 +17,7 @@ "$ref": "./requestParametersComponents.json#/definitions/Assembly" }, "end": { - "description": "Precise or bracketing the end of the variants of interest: * (0-based, exclusive) - see `start` * for bracket queries, provide 2 values (e.g. [111,222]).", + "description": "Precise or bracketing the end of the variants of interest: * (0-based, exclusive) - see `start` * for bracket queries, provide 2 values (e.g. [111,222]).\"", "items": { "format": "int64", "minimum": 1, @@ -52,7 +52,7 @@ "$ref": "./requestParametersComponents.json#/definitions/RefSeqId" }, "start": { - "description": "Precise or fuzzy start coordinate position(s), allele locus (0-based, inclusive). * `start` only:\n - for single positions, e.g. the start of a specified sequence\nalteration where the size is given through the specified `alternateBases`\n - typical use are queries for SNV and small InDels\n - the use of `start` without an `end` parameter requires the use of\n`alternateBases`\n* 1 value each in both `start` and `end`:\n - for searching any variant falling fully or partially within the range\n between `start` and `end` (a.k.a. \"range query\")\n - additional use of `variantType` OR `alternateBases` can limit the\n scope of the query\n - by convention, partial overlaps of variants with the indicated genomic\n range are accepted; for specific overlap requirements the 4-parameter\n \"Bracket Queries\" should be employed\n* 2 values in both `start` and `end` for constructing a \"Bracket Query\":\n - can be used to match any contiguous genomic interval, e.g. for querying\n imprecise positions\n - identifies all structural variants starting between `start[0]` and `start[1]`,\n and ending between `end[0]` <-> `end[1]`\n - single or double sided precise matches can be achieved by setting\n `start[1]=start[0]+1` and `end[1]=end[0]+1`", + "description": "Precise or fuzzy start coordinate position(s), allele locus (0-based, inclusive). * `start` only:\n - for single positions, e.g. the start of a specified sequence\n alteration where the size is given through the specified `alternateBases`\n - typical use are queries for SNV and small InDels\n - the use of `start` without an `end` parameter requires the use of\n `alternateBases`\n* 1 value in both `start` and `end`:\n - for searching any variant falling fully or partially within the range\n between `start` and `end` (a.k.a. \"range query\")\n - additional use of `variantType` OR `alternateBases` can limit the\n scope of the query\n - by convention, partial overlaps of variants with the indicated genomic\n range are accepted; for specific overlap requirements the 4-parameter\n \"Bracket Queries\" should be employed\n* 2 values in both `start` and `end` for constructing a \"Bracket Query\":\n - can be used to match any contiguous genomic interval, e.g. for querying\n imprecise positions\n - identifies all structural variants starting between `start[0]` and `start[1]`,\n and ending between `end[0]` <-> `end[1]`\n - single or double sided precise matches can be achieved by setting\n `start[1]=start[0]+1` and `end[1]=end[0]+1`", "items": { "format": "int64", "minimum": 0, @@ -87,4 +87,4 @@ }, "type": "object" } -} +} \ No newline at end of file diff --git a/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml b/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml index 8eb87b5be..118bc5dd6 100644 --- a/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml @@ -1,55 +1,68 @@ $schema: https://json-schema.org/draft/2020-12/schema -title: Sequencing bioinformatics analysis +title: Bioinformatics analysis $comment: 'version: ga4gh-beacon-analysis-v2.0.0' -description: Schema for a sequencing bioinformatics analysis. +description: >- + The `analysis` schema represents a information about the data analysis steps + leading to (a set of) genomic variation call(s). type: object properties: id: - description: Analysis reference ID (external accession or internal ID) + description: >- + Analysis id for internal referencing; unique in the dataset. type: string runId: - description: Run identifier (external accession or internal ID). + description: >- + Local reference to the associated experimental run. type: string examples: - SRR10903401 biosampleId: - description: Reference to the `id` of the biosample this analysis is reporting - on. + description: >- + Local reference to the `id` of the biosample this analysis is reporting on. type: string examples: - S0001 + - onekgbs-NA07346 individualId: - description: Reference to the `id` of the individual this analysis is reporting - on. + description: >- + Local reference to the `id` of the individual this analysis is reporting on. type: string examples: - P0001 + - onekgind-NA07346 analysisDate: - description: Date at which analysis was performed. + description: > + Date at which analysis was performed. type: string format: date examples: - '2021-10-17' pipelineName: - description: Analysis pipeline and version if a standardized pipeline was used + description: >- + Analysis pipeline and version. type: string examples: - Pipeline-panel-0001-v1 pipelineRef: - description: Link to Analysis pipeline resource + description: >- + Link to information about or repository of the analysis pipeline. type: string examples: - https://doi.org/10.48511/workflowhub.workflow.111.1 + - https://doi.org/10.1093/bib/bbad541 aligner: - description: Reference to mapping/alignment software + description: >- + Name or identifier of the mapping/alignment software/pipeline type: string examples: - bwa-0.7.8 variantCaller: - description: Reference to variant calling software / pipeline + description: >- + Name or identifier of the variant calling software/pipeline type: string examples: - GATK4.0 + - labelSeg info: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info required: From 1cc8914fbcfeb0fc7bce2d09ff8ebbe213f9b253 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Thu, 25 Jul 2024 09:25:33 +0900 Subject: [PATCH 23/37] definitions -> $defs This aligns the use of the "definitions" parameter to the "$defs" keyword as required from https://json-schema.org/draft/2020-12/schema Editing of the YAML files with conversion... Additional changes include a change in the beaconYamler.py utility (use of system Python instead of fixed path) and a few updates of json files due to previous manual editing and now re-arranged parameter order after autoconversion from yaml. --- bin/beaconYamler.py | 2 +- .../biosamples/defaultSchema.yaml | 4 +- bin/deref_schemas/cohorts/defaultSchema.yaml | 8 ++-- bin/deref_schemas/datasets/defaultSchema.yaml | 2 +- .../genomicVariations/defaultSchema.yaml | 2 +- .../individuals/defaultSchema.yaml | 6 +-- bin/deref_schemas/obj/Complex Value.yaml | 2 +- bin/deref_schemas/obj/dataUseConditions.yaml | 2 +- bin/deref_schemas/obj/exclusionCriteria.yaml | 2 +- bin/deref_schemas/obj/inclusionCriteria.yaml | 2 +- bin/deref_schemas/obj/measurementValue.yaml | 2 +- bin/deref_schemas/obj/measurements.yaml | 2 +- bin/deref_schemas/obj/measures.yaml | 2 +- bin/deref_schemas/obj/pedigrees.yaml | 2 +- .../obj/phenotypicConditions.yaml | 2 +- bin/deref_schemas/obj/phenotypicFeatures.yaml | 2 +- .../json/common/beaconCommonComponents.json | 20 ++++----- framework/json/common/ontologyTerm.json | 2 +- .../beaconConfigurationSchema.json | 12 +++--- .../json/configuration/beaconMapSchema.json | 12 +++--- .../configuration/entryTypeDefinition.json | 4 +- .../json/configuration/entryTypesSchema.json | 8 ++-- .../configuration/filteringTermsSchema.json | 8 ++-- framework/json/endpoints.json | 4 +- .../json/requests/beaconRequestBody.json | 16 +++---- .../json/requests/beaconRequestMeta.json | 6 +-- framework/json/requests/filteringTerms.json | 14 +++---- .../json/responses/beaconBooleanResponse.json | 4 +- .../responses/beaconCollectionsResponse.json | 4 +- .../json/responses/beaconCountResponse.json | 4 +- .../json/responses/beaconErrorResponse.json | 2 +- .../responses/beaconResultsetsResponse.json | 4 +- .../ga4gh-service-info-1-0-0-schema.json | 6 +-- .../beaconBooleanResponseSection.json | 2 +- .../sections/beaconCountResponseSection.json | 4 +- .../sections/beaconFilteringTermsResults.json | 42 +++++++++++-------- .../responses/sections/beaconInfoResults.json | 18 ++++---- .../beaconInformationalResponseMeta.json | 6 +-- .../beaconReceivedRequestSummary.json | 14 +++---- .../sections/beaconResponseMeta.json | 10 ++--- .../responses/sections/beaconResultsets.json | 12 +++--- .../beaconSummaryResponseSection.json | 4 +- .../src/common/beaconCommonComponents.yaml | 18 ++++---- framework/src/common/ontologyTerm.yaml | 2 +- .../beaconConfigurationSchema.yaml | 8 ++-- .../src/configuration/beaconMapSchema.yaml | 8 ++-- .../configuration/entryTypeDefinition.yaml | 4 +- .../src/configuration/entryTypesSchema.yaml | 4 +- .../configuration/filteringTermsSchema.yaml | 4 +- framework/src/endpoints.yaml | 4 +- framework/src/requests/beaconRequestBody.yaml | 14 +++---- framework/src/requests/beaconRequestMeta.yaml | 6 +-- framework/src/requests/filteringTerms.yaml | 10 ++--- .../src/responses/beaconBooleanResponse.yaml | 4 +- .../responses/beaconCollectionsResponse.yaml | 4 +- .../src/responses/beaconCountResponse.yaml | 4 +- .../src/responses/beaconErrorResponse.yaml | 2 +- .../responses/beaconResultsetsResponse.yaml | 4 +- .../ga4gh-service-info-1-0-0-schema.yaml | 4 +- .../beaconBooleanResponseSection.yaml | 2 +- .../sections/beaconCountResponseSection.yaml | 4 +- .../sections/beaconFilteringTermsResults.yaml | 6 +-- .../responses/sections/beaconInfoResults.yaml | 14 +++---- .../beaconInformationalResponseMeta.yaml | 6 +-- .../beaconReceivedRequestSummary.yaml | 14 +++---- .../sections/beaconResponseMeta.yaml | 10 ++--- .../responses/sections/beaconResultsets.yaml | 8 ++-- .../beaconSummaryResponseSection.yaml | 4 +- .../analyses/defaultSchema.json | 2 +- .../analyses/endpoints.json | 6 +-- .../biosamples/defaultSchema.json | 2 +- .../biosamples/endpoints.json | 6 +-- .../cohorts/defaultSchema.json | 34 +++++++-------- .../cohorts/endpoints.json | 4 +- .../beacon-v2-default-model/common/age.json | 4 +- .../common/ageRange.json | 4 +- .../common/commonDefinitions.json | 4 +- .../common/complexValue.json | 10 +++-- .../common/dataUseConditions.json | 8 ++-- .../common/disease.json | 2 +- .../common/exposure.json | 2 +- .../common/pedigree.json | 8 ++-- .../common/phenotypicFeature.json | 4 +- .../common/quantity.json | 2 +- .../common/referenceRange.json | 2 +- .../common/timeElement.json | 2 +- .../common/timeInterval.json | 4 +- .../datasets/defaultSchema.json | 6 +-- .../datasets/endpoints.json | 4 +- .../beacon-v2-default-model/endpoints.json | 4 +- .../genomicVariations/defaultSchema.json | 32 +++++++------- .../genomicVariations/endpoints.json | 6 +-- .../genomicVariations/requestParameters.json | 16 +++---- .../requestParametersComponents.json | 4 +- .../individuals/defaultSchema.json | 10 ++--- .../individuals/endpoints.json | 6 +-- .../runs/defaultSchema.json | 2 +- .../runs/endpoints.json | 6 +-- .../analyses/defaultSchema.yaml | 2 +- .../analyses/endpoints.yaml | 6 +-- .../biosamples/defaultSchema.yaml | 2 +- .../biosamples/endpoints.yaml | 6 +-- .../cohorts/defaultSchema.yaml | 30 ++++++------- .../cohorts/endpoints.yaml | 4 +- .../common/commonDefinitions.yaml | 2 +- .../common/complexValue.yaml | 4 +- .../common/dataUseConditions.yaml | 4 +- .../common/disease.yaml | 2 +- .../common/exposure.yaml | 2 +- .../common/pedigree.yaml | 4 +- .../common/phenotypicFeature.yaml | 4 +- .../common/quantity.yaml | 2 +- .../common/referenceRange.yaml | 2 +- .../common/timeElement.yaml | 2 +- .../common/timeInterval.yaml | 4 +- .../datasets/defaultSchema.yaml | 6 +-- .../datasets/endpoints.yaml | 4 +- .../beacon-v2-default-model/endpoints.yaml | 4 +- .../genomicVariations/defaultSchema.yaml | 28 ++++++------- .../genomicVariations/endpoints.yaml | 6 +-- .../genomicVariations/requestParameters.yaml | 10 ++--- .../requestParametersComponents.yaml | 2 +- .../individuals/defaultSchema.yaml | 10 ++--- .../individuals/endpoints.yaml | 6 +-- .../runs/defaultSchema.yaml | 2 +- .../runs/endpoints.yaml | 6 +-- 126 files changed, 420 insertions(+), 410 deletions(-) diff --git a/bin/beaconYamler.py b/bin/beaconYamler.py index 022ea5fc2..e0d05d78e 100755 --- a/bin/beaconYamler.py +++ b/bin/beaconYamler.py @@ -1,4 +1,4 @@ -#!/usr/local/bin/python3 +#!/usr/bin/env python3 import sys, re, json import pathlib diff --git a/bin/deref_schemas/biosamples/defaultSchema.yaml b/bin/deref_schemas/biosamples/defaultSchema.yaml index 79c3e36de..02f5b5571 100644 --- a/bin/deref_schemas/biosamples/defaultSchema.yaml +++ b/bin/deref_schemas/biosamples/defaultSchema.yaml @@ -260,7 +260,7 @@ properties: title: Value type: object - $schema: https://json-schema.org/draft/2020-12/schema - definitions: + $defs: TypedQuantity: properties: quantity: @@ -1064,7 +1064,7 @@ properties: description: List of phenotypic abnormalities of the sample. RECOMMENDED. items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: evidence: diff --git a/bin/deref_schemas/cohorts/defaultSchema.yaml b/bin/deref_schemas/cohorts/defaultSchema.yaml index 9290fc70a..6baeed72a 100644 --- a/bin/deref_schemas/cohorts/defaultSchema.yaml +++ b/bin/deref_schemas/cohorts/defaultSchema.yaml @@ -2,7 +2,7 @@ $comment: 'version: ga4gh-beacon-cohort-v2.0.0' $schema: https://json-schema.org/draft/2020-12/schema additionalProperties: &1 !!perl/scalar:JSON::PP::Boolean 1 -definitions: +$defs: CohortCriteria: description: Criteria used for defining the cohort. It is assumed that all cohort participants will match or NOT match such criteria. properties: @@ -366,7 +366,7 @@ definitions: description: Phenotypic condition(s) in cohort inclusion criteria items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: evidence: @@ -1660,7 +1660,7 @@ properties: description: Phenotypic condition(s) in cohort inclusion criteria items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: evidence: @@ -2406,7 +2406,7 @@ properties: description: Phenotypic condition(s) in cohort inclusion criteria items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: evidence: diff --git a/bin/deref_schemas/datasets/defaultSchema.yaml b/bin/deref_schemas/datasets/defaultSchema.yaml index 434a04245..237fb9e92 100644 --- a/bin/deref_schemas/datasets/defaultSchema.yaml +++ b/bin/deref_schemas/datasets/defaultSchema.yaml @@ -13,7 +13,7 @@ properties: dataUseConditions: $schema: https://json-schema.org/draft/2020-12/schema additionalProperties: 1 - definitions: + $defs: DUODataUse: allOf: - description: 'Data Use Ontology codes and additional information associated with a data object (e.g. sample, dataset).' diff --git a/bin/deref_schemas/genomicVariations/defaultSchema.yaml b/bin/deref_schemas/genomicVariations/defaultSchema.yaml index 2894f3ca3..4705bbe43 100644 --- a/bin/deref_schemas/genomicVariations/defaultSchema.yaml +++ b/bin/deref_schemas/genomicVariations/defaultSchema.yaml @@ -2,7 +2,7 @@ $comment: 'version: ga4gh-beacon-variant-v2.0.0' $schema: https://json-schema.org/draft/2020-12/schema additionalProperties: &1 !!perl/scalar:JSON::PP::Boolean 1 -definitions: +$defs: CaseLevelVariant: description: '' properties: diff --git a/bin/deref_schemas/individuals/defaultSchema.yaml b/bin/deref_schemas/individuals/defaultSchema.yaml index 3a9eaa481..6eaa3028a 100644 --- a/bin/deref_schemas/individuals/defaultSchema.yaml +++ b/bin/deref_schemas/individuals/defaultSchema.yaml @@ -739,7 +739,7 @@ properties: title: Value type: object - $schema: https://json-schema.org/draft/2020-12/schema - definitions: + $defs: TypedQuantity: properties: quantity: @@ -1299,7 +1299,7 @@ properties: items: $schema: https://json-schema.org/draft/2020-12/schema additionalProperties: 1 - definitions: + $defs: pedigreeMember: examples: - membersInProband: @@ -1696,7 +1696,7 @@ properties: phenotypicFeatures: items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: evidence: diff --git a/bin/deref_schemas/obj/Complex Value.yaml b/bin/deref_schemas/obj/Complex Value.yaml index de5657e33..98d47cc3a 100644 --- a/bin/deref_schemas/obj/Complex Value.yaml +++ b/bin/deref_schemas/obj/Complex Value.yaml @@ -1,7 +1,7 @@ --- Complex Value: $schema: https://json-schema.org/draft/2020-12/schema - definitions: + $defs: TypedQuantity: properties: quantity: diff --git a/bin/deref_schemas/obj/dataUseConditions.yaml b/bin/deref_schemas/obj/dataUseConditions.yaml index 111618b4c..90a3154d8 100644 --- a/bin/deref_schemas/obj/dataUseConditions.yaml +++ b/bin/deref_schemas/obj/dataUseConditions.yaml @@ -2,7 +2,7 @@ dataUseConditions: $schema: https://json-schema.org/draft/2020-12/schema additionalProperties: 1 - definitions: + $defs: DUODataUse: allOf: - description: Data Use Ontology codes and additional information associated diff --git a/bin/deref_schemas/obj/exclusionCriteria.yaml b/bin/deref_schemas/obj/exclusionCriteria.yaml index 15cfa272c..36cd4cf00 100644 --- a/bin/deref_schemas/obj/exclusionCriteria.yaml +++ b/bin/deref_schemas/obj/exclusionCriteria.yaml @@ -413,7 +413,7 @@ exclusionCriteria: description: Phenotypic condition(s) in cohort inclusion criteria items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: diff --git a/bin/deref_schemas/obj/inclusionCriteria.yaml b/bin/deref_schemas/obj/inclusionCriteria.yaml index 25521d4c3..65c5db613 100644 --- a/bin/deref_schemas/obj/inclusionCriteria.yaml +++ b/bin/deref_schemas/obj/inclusionCriteria.yaml @@ -413,7 +413,7 @@ inclusionCriteria: description: Phenotypic condition(s) in cohort inclusion criteria items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: diff --git a/bin/deref_schemas/obj/measurementValue.yaml b/bin/deref_schemas/obj/measurementValue.yaml index 97cc689fe..98cc0ed0e 100644 --- a/bin/deref_schemas/obj/measurementValue.yaml +++ b/bin/deref_schemas/obj/measurementValue.yaml @@ -3,7 +3,7 @@ measurementValue: properties: Complex Value: $schema: https://json-schema.org/draft/2020-12/schema - definitions: + $defs: TypedQuantity: properties: quantity: diff --git a/bin/deref_schemas/obj/measurements.yaml b/bin/deref_schemas/obj/measurements.yaml index eafeb9ca9..e2d027a48 100644 --- a/bin/deref_schemas/obj/measurements.yaml +++ b/bin/deref_schemas/obj/measurements.yaml @@ -168,7 +168,7 @@ measurements: title: Value type: object - $schema: https://json-schema.org/draft/2020-12/schema - definitions: + $defs: TypedQuantity: properties: quantity: diff --git a/bin/deref_schemas/obj/measures.yaml b/bin/deref_schemas/obj/measures.yaml index 907476373..13657c498 100644 --- a/bin/deref_schemas/obj/measures.yaml +++ b/bin/deref_schemas/obj/measures.yaml @@ -166,7 +166,7 @@ measures: title: Value type: object - $schema: https://json-schema.org/draft/2020-12/schema - definitions: + $defs: TypedQuantity: properties: quantity: diff --git a/bin/deref_schemas/obj/pedigrees.yaml b/bin/deref_schemas/obj/pedigrees.yaml index a6212e677..959351274 100644 --- a/bin/deref_schemas/obj/pedigrees.yaml +++ b/bin/deref_schemas/obj/pedigrees.yaml @@ -3,7 +3,7 @@ pedigrees: items: $schema: https://json-schema.org/draft/2020-12/schema additionalProperties: 1 - definitions: + $defs: pedigreeMember: examples: - membersInProband: diff --git a/bin/deref_schemas/obj/phenotypicConditions.yaml b/bin/deref_schemas/obj/phenotypicConditions.yaml index 235f70bd7..609b02201 100644 --- a/bin/deref_schemas/obj/phenotypicConditions.yaml +++ b/bin/deref_schemas/obj/phenotypicConditions.yaml @@ -3,7 +3,7 @@ phenotypicConditions: description: Phenotypic condition(s) in cohort inclusion criteria items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: evidence: diff --git a/bin/deref_schemas/obj/phenotypicFeatures.yaml b/bin/deref_schemas/obj/phenotypicFeatures.yaml index 4a8323a07..d41141008 100644 --- a/bin/deref_schemas/obj/phenotypicFeatures.yaml +++ b/bin/deref_schemas/obj/phenotypicFeatures.yaml @@ -2,7 +2,7 @@ phenotypicFeatures: items: $schema: https://json-schema.org/draft/2020-12/schema - definitions: {} + $defs: {} description: Used to describe a phenotype that characterizes the subject or biosample. properties: evidence: diff --git a/framework/json/common/beaconCommonComponents.json b/framework/json/common/beaconCommonComponents.json index a6b922664..10ee8912a 100644 --- a/framework/json/common/beaconCommonComponents.json +++ b/framework/json/common/beaconCommonComponents.json @@ -1,6 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "definitions": { + "$defs": { "$schema": { "$comment": "TO REVIEW: adding a `format` or `regex` attribute that validates correctly against a file path (relative).", "description": "Refers to the JSON Schema which describes the set of valid attributes for this particular document type. This attribute is mostly used in schemas that should be tested in Beacon implementations.", @@ -88,7 +87,7 @@ "description": "A handover is a typed link for attaching actionable links to results, non purely informational, requests. The goal of the handovers is to list the different actions available, e.g.:\n* a link to a request access page * linking to a file for download, e.g. a VCF file\nAnother common scenario is to provide a fast summary response (e.g. BeconCountResponse) and to provide access to different endpoints for the entities matched by the query using temporary access tokens in the handover URLs.", "properties": { "handoverType": { - "$ref": "#/definitions/HandoverType" + "$ref": "#/$defs/HandoverType" }, "note": { "description": "An optional text including considerations on the handover link provided.", @@ -157,7 +156,7 @@ "ListOfHandovers": { "description": "Set of handovers to be added in one section the response.", "items": { - "$ref": "#/definitions/Handover", + "$ref": "#/$defs/Handover", "description": "Requested schema to be used for individuals in the response." }, "type": "array" @@ -165,7 +164,7 @@ "ListOfSchemas": { "description": "Set of schemas to be used in the response to a request.", "items": { - "$ref": "#/definitions/SchemasPerEntity" + "$ref": "#/$defs/SchemasPerEntity" }, "type": "array" }, @@ -191,22 +190,22 @@ "description": "Pagination to apply or that has been applied on the results.", "properties": { "currentPage": { - "$ref": "#/definitions/PageToken", + "$ref": "#/$defs/PageToken", "description": "Token of the returned page. To be used only in the response to allow the client to check if the returned page is the one requested." }, "limit": { - "$ref": "#/definitions/Limit" + "$ref": "#/$defs/Limit" }, "nextPage": { - "$ref": "#/definitions/PageToken", + "$ref": "#/$defs/PageToken", "description": "Token of the next page. Used to navigate forward. If empty, it is assumed that no more pages are available" }, "previousPage": { - "$ref": "#/definitions/PageToken", + "$ref": "#/$defs/PageToken", "description": "Token of the previous page. Used to navigate backwards. If empty, it is assumed that the current page is the first one." }, "skip": { - "$ref": "#/definitions/Skip" + "$ref": "#/$defs/Skip" } }, "type": "object" @@ -243,6 +242,7 @@ "type": "boolean" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", "description": "Definition of relatively simple components used in different points of the Beacon specification, both in requests and responses, therefore not associated exclusively with one or the other. Separate schema documents are provided for complex components.", "title": "Beacon Common Components", "type": "object" diff --git a/framework/json/common/ontologyTerm.json b/framework/json/common/ontologyTerm.json index 6d092cf08..0a351caa0 100644 --- a/framework/json/common/ontologyTerm.json +++ b/framework/json/common/ontologyTerm.json @@ -4,7 +4,7 @@ "description": "Definition of an ontology term.", "properties": { "id": { - "$ref": "./beaconCommonComponents.json#/definitions/CURIE" + "$ref": "./beaconCommonComponents.json#/$defs/CURIE" }, "label": { "description": "The text that describes the term. By default it could be the preferred text of the term, but is it acceptable to customize it for a clearer description and understanding of the term in an specific context.", diff --git a/framework/json/configuration/beaconConfigurationSchema.json b/framework/json/configuration/beaconConfigurationSchema.json index 02d54a3a0..7b3b448ec 100644 --- a/framework/json/configuration/beaconConfigurationSchema.json +++ b/framework/json/configuration/beaconConfigurationSchema.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "EntryTypes": { "additionalProperties": { "$ref": "./entryTypeDefinition.json", @@ -12,13 +10,15 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Files complaint with this schema are the configuration ones. The details returned in `service-info` are mirroring the ones in this configuration file.", "properties": { "$schema": { - "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" + "$ref": "../common/beaconCommonComponents.json#/$defs/$schema" }, "entryTypes": { - "$ref": "#/definitions/EntryTypes" + "$ref": "#/$defs/EntryTypes" }, "maturityAttributes": { "description": "Declares the level of maturity of the Beacon instance.", @@ -39,7 +39,7 @@ "description": "Configuration of the security aspects of the Beacon. By default, a Beacon that does not declare the configuration settings would return `boolean` (true/false) responses, and only if the user is authenticated and explicitly authorized to access the Beacon resources. Although this is the safest set of settings, it is not recommended unless the Beacon shares very sensitive information. Non sensitive Beacons should preferably opt for a `record` and `PUBLIC` combination.", "properties": { "defaultGranularity": { - "$ref": "../common/beaconCommonComponents.json#/definitions/Granularity", + "$ref": "../common/beaconCommonComponents.json#/$defs/Granularity", "description": "Default granularity. Some responses could return higher detail, but this would be the granularity by default." }, "securityLevels": { diff --git a/framework/json/configuration/beaconMapSchema.json b/framework/json/configuration/beaconMapSchema.json index b5335e28b..3ca6c9259 100644 --- a/framework/json/configuration/beaconMapSchema.json +++ b/framework/json/configuration/beaconMapSchema.json @@ -1,12 +1,10 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "Endpoint": { "properties": { "endpoints": { "additionalProperties": { - "$ref": "#/definitions/RelatedEndpoint" + "$ref": "#/$defs/RelatedEndpoint" }, "description": "Optional. A list describing additional endpoints implemented by this Beacon instance for that entry type. Additional details on the endpoint parameters, supported HTTP verbs, etc. could be obtained by parsing the OpenAPI definition referenced in the `openAPIEndpointsDefinition` attribute.", "minProperties": 0, @@ -61,14 +59,16 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Map of a Beacon, its entry types and endpoints. It isconceptually similar to a website sitemap.", "properties": { "$schema": { - "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" + "$ref": "../common/beaconCommonComponents.json#/$defs/$schema" }, "endpointSets": { "additionalProperties": { - "$ref": "#/definitions/Endpoint" + "$ref": "#/$defs/Endpoint" }, "description": "List of enpoints included in this Beacon instance. This is list is meant to inform Beacon clients, e.g. a Beacon Network, about the available endpoints, it is not used to generate any automatic list, but could be used for Beacon validation purposes.", "minProperties": 1, diff --git a/framework/json/configuration/entryTypeDefinition.json b/framework/json/configuration/entryTypeDefinition.json index 434bebcf6..ff8824678 100644 --- a/framework/json/configuration/entryTypeDefinition.json +++ b/framework/json/configuration/entryTypeDefinition.json @@ -5,7 +5,7 @@ "description": "Definition of an element or entry type including the Beacon v2 required and suggested attributes. This schema purpose is to describe each type of entities included in a Beacon, hence Beacon clients could have some metadata about such entities.\n\nThe `id` attribute is the key that should be used in other parts of the Beacon Model to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, request parameters, etc.) that fully describe an entry type.", "properties": { "$schema": { - "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" + "$ref": "../common/beaconCommonComponents.json#/$defs/$schema" }, "aCollectionOf": { "description": "If the entry type is a collection of other entry types, (e.g. a Dataset is a collection of Records), then this attribute must list the entry types that could be included. One collection type could be defined as included more than one entry type (e.g. a Dataset could include Individuals or Genomic Variants), in such cases the entries are alternative, meaning that a given instance of this entry type could be of only one of the types (e.g. a given Dataset contains Individuals, while another Dataset could contain Genomic Variants, but not both at once).", @@ -44,7 +44,7 @@ "type": "string" }, "nonFilteredQueriesAllowed": { - "$ref": "../common/beaconCommonComponents.json#/definitions/NonFilteredQueriesAllowed" + "$ref": "../common/beaconCommonComponents.json#/$defs/NonFilteredQueriesAllowed" }, "ontologyTermForThisType": { "$comments": "++++++ THIS IS THE END OF THE ontologized element ++++++", diff --git a/framework/json/configuration/entryTypesSchema.json b/framework/json/configuration/entryTypesSchema.json index 7e6c47285..1b75804f6 100644 --- a/framework/json/configuration/entryTypesSchema.json +++ b/framework/json/configuration/entryTypesSchema.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "EntryTypes": { "additionalProperties": { "$ref": "./entryTypeDefinition.json", @@ -11,10 +9,12 @@ "minProperties": 1 } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Schema for the Enrty Types list.", "properties": { "entryTypes": { - "$ref": "#/definitions/EntryTypes", + "$ref": "#/$defs/EntryTypes", "description": "List of entry types." } }, diff --git a/framework/json/configuration/filteringTermsSchema.json b/framework/json/configuration/filteringTermsSchema.json index 462e04b2f..ba7d19d9c 100644 --- a/framework/json/configuration/filteringTermsSchema.json +++ b/framework/json/configuration/filteringTermsSchema.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "FilterTerm": { "properties": { "ftType": { @@ -47,12 +45,14 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Schema for the Filtering Terms list related to the hosting entry type. It is kept separated to allow updating it independently.", "properties": { "filteringTerms": { "description": "List of filtering terms that could be used to filter this concept in this instance of Beacon.", "items": { - "$ref": "#/definitions/FilterTerm" + "$ref": "#/$defs/FilterTerm" }, "minItems": 0, "type": "array" diff --git a/framework/json/endpoints.json b/framework/json/endpoints.json index e394ad28f..5f7fe9da4 100644 --- a/framework/json/endpoints.json +++ b/framework/json/endpoints.json @@ -5,7 +5,7 @@ "in": "query", "name": "limit", "schema": { - "$ref": "./common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "./common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -22,7 +22,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "./common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "./common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/framework/json/requests/beaconRequestBody.json b/framework/json/requests/beaconRequestBody.json index 8b6116bf7..3d6088cff 100644 --- a/framework/json/requests/beaconRequestBody.json +++ b/framework/json/requests/beaconRequestBody.json @@ -1,6 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "definitions": { + "$defs": { "BeaconQuery": { "description": "Parameters to limit the list of returned results.", "properties": { @@ -9,10 +8,10 @@ "description": "Ontology based filters. Using CURIE syntax is encouraged." }, "includeResultsetResponses": { - "$ref": "../common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses" + "$ref": "../common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses" }, "pagination": { - "$ref": "../common/beaconCommonComponents.json#/definitions/Pagination", + "$ref": "../common/beaconCommonComponents.json#/$defs/Pagination", "description": "Pagination parameters applied to response documents, in case of record level granularity." }, "requestParameters": { @@ -20,28 +19,29 @@ "description": "Parameters used for the entry type specific query elements." }, "requestedGranularity": { - "$ref": "../common/beaconCommonComponents.json#/definitions/Granularity", + "$ref": "../common/beaconCommonComponents.json#/$defs/Granularity", "description": "Requested granularity for the response. Beacons do not have to respond with the requested granularity, e.g. may respond with count results although record level granularity had been requested but indicate the granularity of the response in the response's metadata." }, "testMode": { - "$ref": "../common/beaconCommonComponents.json#/definitions/TestMode", + "$ref": "../common/beaconCommonComponents.json#/$defs/TestMode", "description": "Used for indicating that a request or response is done in a test context." } }, "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", "description": "Schema for the Beacon request. It is named `RequestBody` to keep the same nomenclature used by OpenAPI v3, but it actually contains the definition of the whole HTTP POST request payload.", "properties": { "$schema": { - "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" + "$ref": "../common/beaconCommonComponents.json#/$defs/$schema" }, "meta": { "$ref": "./beaconRequestMeta.json", "description": "Information relevant for building the response." }, "query": { - "$ref": "#/definitions/BeaconQuery" + "$ref": "#/$defs/BeaconQuery" } }, "required": [ diff --git a/framework/json/requests/beaconRequestMeta.json b/framework/json/requests/beaconRequestMeta.json index 79b6a6e87..36e0d46fc 100644 --- a/framework/json/requests/beaconRequestMeta.json +++ b/framework/json/requests/beaconRequestMeta.json @@ -3,14 +3,14 @@ "description": "Meta section of the Beacon request. It includes request context details relevant for the Beacon server when processing the request.", "properties": { "$schema": { - "$ref": "../common/beaconCommonComponents.json#/definitions/$schema" + "$ref": "../common/beaconCommonComponents.json#/$defs/$schema" }, "apiVersion": { - "$ref": "../common/beaconCommonComponents.json#/definitions/ApiVersion", + "$ref": "../common/beaconCommonComponents.json#/$defs/ApiVersion", "description": "API version expected by the client to be supported by the server and used in the response format." }, "requestedSchemas": { - "$ref": "../common/beaconCommonComponents.json#/definitions/ListOfSchemas", + "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfSchemas", "description": "Set of schemas to be used in the response." } }, diff --git a/framework/json/requests/filteringTerms.json b/framework/json/requests/filteringTerms.json index 3c0550f7f..732b49c56 100644 --- a/framework/json/requests/filteringTerms.json +++ b/framework/json/requests/filteringTerms.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "AlphanumericFilter": { "description": "Filter results based on operators and values applied to alphanumeric fields.", "properties": { @@ -64,13 +62,13 @@ "FilteringTerm": { "anyOf": [ { - "$ref": "#/definitions/OntologyFilter" + "$ref": "#/$defs/OntologyFilter" }, { - "$ref": "#/definitions/AlphanumericFilter" + "$ref": "#/$defs/AlphanumericFilter" }, { - "$ref": "#/definitions/CustomFilter" + "$ref": "#/$defs/CustomFilter" } ] }, @@ -110,9 +108,11 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Filtering terms are the main means to select subsets of records from a Beacon response. While the name implies the application to a generated response, in practice implementations may apply them at the query stage. Note: In the processing of Beacon v2.0 requests multiple filters are assumed to be chained by the logical AND operator.", "items": { - "$ref": "#/definitions/FilteringTerm" + "$ref": "#/$defs/FilteringTerm" }, "title": "Filtering Term Element", "type": "array" diff --git a/framework/json/responses/beaconBooleanResponse.json b/framework/json/responses/beaconBooleanResponse.json index 7aae7ffe6..8491ca4bd 100644 --- a/framework/json/responses/beaconBooleanResponse.json +++ b/framework/json/responses/beaconBooleanResponse.json @@ -3,11 +3,11 @@ "description": "Complete definition for a minimal response that provides *only* a `Boolean` exists true|false answer.", "properties": { "beaconHandovers": { - "$ref": "../common/beaconCommonComponents.json#/definitions/ListOfHandovers", + "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/definitions/Info", + "$ref": "../common/beaconCommonComponents.json#/$defs/Info", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/beaconCollectionsResponse.json b/framework/json/responses/beaconCollectionsResponse.json index 61f294744..6728e3342 100644 --- a/framework/json/responses/beaconCollectionsResponse.json +++ b/framework/json/responses/beaconCollectionsResponse.json @@ -4,11 +4,11 @@ "description": "Beacon response that includes details about the collections in this Beacon.", "properties": { "beaconHandovers": { - "$ref": "../common/beaconCommonComponents.json#/definitions/ListOfHandovers", + "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/definitions/Info", + "$ref": "../common/beaconCommonComponents.json#/$defs/Info", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/beaconCountResponse.json b/framework/json/responses/beaconCountResponse.json index 7c5b1ad46..9222ae90d 100644 --- a/framework/json/responses/beaconCountResponse.json +++ b/framework/json/responses/beaconCountResponse.json @@ -3,11 +3,11 @@ "description": "Complete definition for a response that does not include record level details but provides `Boolean` and `count` information.", "properties": { "beaconHandovers": { - "$ref": "../common/beaconCommonComponents.json#/definitions/ListOfHandovers", + "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/definitions/Info", + "$ref": "../common/beaconCommonComponents.json#/$defs/Info", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/beaconErrorResponse.json b/framework/json/responses/beaconErrorResponse.json index 07da8d70c..db7b0c0f0 100644 --- a/framework/json/responses/beaconErrorResponse.json +++ b/framework/json/responses/beaconErrorResponse.json @@ -4,7 +4,7 @@ "description": "An unsuccessful operation.", "properties": { "error": { - "$ref": "../common/beaconCommonComponents.json#/definitions/BeaconError" + "$ref": "../common/beaconCommonComponents.json#/$defs/BeaconError" }, "meta": { "$ref": "./sections/beaconResponseMeta.json" diff --git a/framework/json/responses/beaconResultsetsResponse.json b/framework/json/responses/beaconResultsetsResponse.json index 159fadaab..8efe9617a 100644 --- a/framework/json/responses/beaconResultsetsResponse.json +++ b/framework/json/responses/beaconResultsetsResponse.json @@ -4,11 +4,11 @@ "description": "Beacon response that includes record level details, grouped in Resultsets.", "properties": { "beaconHandovers": { - "$ref": "../common/beaconCommonComponents.json#/definitions/ListOfHandovers", + "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/definitions/Info", + "$ref": "../common/beaconCommonComponents.json#/$defs/Info", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/ga4gh-service-info-1-0-0-schema.json b/framework/json/responses/ga4gh-service-info-1-0-0-schema.json index 326fd13ea..61811fe83 100644 --- a/framework/json/responses/ga4gh-service-info-1-0-0-schema.json +++ b/framework/json/responses/ga4gh-service-info-1-0-0-schema.json @@ -1,6 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "definitions": { + "$defs": { "ServiceType": { "description": "Type of a GA4GH service", "properties": { @@ -28,6 +27,7 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", "description": "A way for a service to describe basic metadata concerning a service alongside a set of capabilities and/or limitations of the service. More information on [GitHub](https://github.com/ga4gh-discovery/ga4gh-service-info/).", "properties": { "contactUrl": { @@ -90,7 +90,7 @@ "type": "object" }, "type": { - "$ref": "#/definitions/ServiceType" + "$ref": "#/$defs/ServiceType" }, "updatedAt": { "description": "Timestamp describing when the service was last updated (RFC 3339 format)", diff --git a/framework/json/responses/sections/beaconBooleanResponseSection.json b/framework/json/responses/sections/beaconBooleanResponseSection.json index 80c8d0cb0..12b5a01af 100644 --- a/framework/json/responses/sections/beaconBooleanResponseSection.json +++ b/framework/json/responses/sections/beaconBooleanResponseSection.json @@ -3,7 +3,7 @@ "description": "Boolean (true/false) response section.", "properties": { "exists": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Exists" + "$ref": "../../common/beaconCommonComponents.json#/$defs/Exists" } }, "required": [ diff --git a/framework/json/responses/sections/beaconCountResponseSection.json b/framework/json/responses/sections/beaconCountResponseSection.json index 6a9e95e86..a23871775 100644 --- a/framework/json/responses/sections/beaconCountResponseSection.json +++ b/framework/json/responses/sections/beaconCountResponseSection.json @@ -3,10 +3,10 @@ "description": "Payload definition for the \"count\" response.", "properties": { "exists": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Exists" + "$ref": "../../common/beaconCommonComponents.json#/$defs/Exists" }, "numTotalResults": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/NumTotalResults", + "$ref": "../../common/beaconCommonComponents.json#/$defs/NumTotalResults", "description": "Total number of results." } }, diff --git a/framework/json/responses/sections/beaconFilteringTermsResults.json b/framework/json/responses/sections/beaconFilteringTermsResults.json index 1755fb582..75a582dd4 100644 --- a/framework/json/responses/sections/beaconFilteringTermsResults.json +++ b/framework/json/responses/sections/beaconFilteringTermsResults.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "FilteringTerm": { "description": "Entities can be filtered using this term.", "properties": { @@ -21,6 +19,25 @@ ], "type": "string" }, + "scopes": { + "description": "Entry types affected by this filter.", + "examples": [ + [ + "individual", + "biosample", + "analysis", + "run", + "genomicVariation" + ], + [ + "biosample" + ] + ], + "items": { + "type": "string" + }, + "type": "array" + }, "type": { "description": "Either \"custom\", \"alphanumeric\" or ontology/terminology full name. TODO: An ontology ... with a registered prefix does not need a full name so one may better use CURIE to indicate that the resource can be retrieved from the id. This also will allow to provide an enum here.", "examples": [ @@ -28,17 +45,6 @@ "alphanumeric" ], "type": "string" - }, - "scopes": { - "description": "Entry types affected by this filter.", - "examples": [ - ["individual", "biosample", "analysis", "run", "genomicVariation"], - ["biosample"] - ], - "type": "array", - "items": { - "type": "string" - } } }, "required": [ @@ -99,20 +105,22 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Filtering terms and ontology resources utilised in this Beacon.", "properties": { "filteringTerms": { "items": { - "$ref": "#/definitions/FilteringTerm" + "$ref": "#/$defs/FilteringTerm" }, "type": "array" }, "resources": { "items": { - "$ref": "#/definitions/Resource" + "$ref": "#/$defs/Resource" }, "type": "array" } }, "type": "object" -} +} \ No newline at end of file diff --git a/framework/json/responses/sections/beaconInfoResults.json b/framework/json/responses/sections/beaconInfoResults.json index 9b431df0b..f795b2dbe 100644 --- a/framework/json/responses/sections/beaconInfoResults.json +++ b/framework/json/responses/sections/beaconInfoResults.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "BeaconOrganization": { "description": "Organization owning the Beacon.", "properties": { @@ -22,7 +20,7 @@ "type": "string" }, "info": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Info", + "$ref": "../../common/beaconCommonComponents.json#/$defs/Info", "description": "Additional unspecified metadata about the host Organization." }, "logoUrl": { @@ -45,6 +43,8 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Metadata describing a Beacon instance.", "properties": { "alternativeUrl": { @@ -55,7 +55,7 @@ "type": "string" }, "apiVersion": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ApiVersion" + "$ref": "../../common/beaconCommonComponents.json#/$defs/ApiVersion" }, "createDateTime": { "description": "The date/time the Beacon was created (ISO 8601 format).", @@ -83,10 +83,10 @@ "type": "string" }, "id": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/BeaconId" + "$ref": "../../common/beaconCommonComponents.json#/$defs/BeaconId" }, "info": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Info", + "$ref": "../../common/beaconCommonComponents.json#/$defs/Info", "description": "Additional unspecified metadata about the Beacon service." }, "name": { @@ -94,7 +94,7 @@ "type": "string" }, "organization": { - "$ref": "#/definitions/BeaconOrganization" + "$ref": "#/$defs/BeaconOrganization" }, "updateDateTime": { "description": "The time the Beacon was updated in (ISO 8601 format).", @@ -105,7 +105,7 @@ "type": "string" }, "version": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ApiVersion", + "$ref": "../../common/beaconCommonComponents.json#/$defs/ApiVersion", "description": "TODO: This is a legacy use / duplication?" }, "welcomeUrl": { diff --git a/framework/json/responses/sections/beaconInformationalResponseMeta.json b/framework/json/responses/sections/beaconInformationalResponseMeta.json index 5031198c8..c3fd53353 100644 --- a/framework/json/responses/sections/beaconInformationalResponseMeta.json +++ b/framework/json/responses/sections/beaconInformationalResponseMeta.json @@ -5,13 +5,13 @@ "description": "Meta information about the response.", "properties": { "apiVersion": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ApiVersion" + "$ref": "../../common/beaconCommonComponents.json#/$defs/ApiVersion" }, "beaconId": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/BeaconId" + "$ref": "../../common/beaconCommonComponents.json#/$defs/BeaconId" }, "returnedSchemas": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ListOfSchemas" + "$ref": "../../common/beaconCommonComponents.json#/$defs/ListOfSchemas" } }, "required": [ diff --git a/framework/json/responses/sections/beaconReceivedRequestSummary.json b/framework/json/responses/sections/beaconReceivedRequestSummary.json index 56ad90674..c0abbad4d 100644 --- a/framework/json/responses/sections/beaconReceivedRequestSummary.json +++ b/framework/json/responses/sections/beaconReceivedRequestSummary.json @@ -3,18 +3,18 @@ "description": "Section of the response that summarize the request received as it has been interpreted by the Beacon server. This summary can help to identify differences between the incoming request and its interpretation or processing, e.g. in the response granularity or pagination. The required properties include those that should be part of every request.", "properties": { "apiVersion": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ApiVersion", + "$ref": "../../common/beaconCommonComponents.json#/$defs/ApiVersion", "description": "API version expected by the client to be supported by the server and used in the response format." }, "filters": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Filters", + "$ref": "../../common/beaconCommonComponents.json#/$defs/Filters", "description": "Filters as submitted in the request." }, "includeResultsetResponses": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses" + "$ref": "../../common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses" }, "pagination": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Pagination", + "$ref": "../../common/beaconCommonComponents.json#/$defs/Pagination", "description": "Pagination as requested for the results." }, "requestParameters": { @@ -22,17 +22,17 @@ "description": "Dictionary of request parameters received in the `RequestBody` or as part of a GET request." }, "requestedGranularity": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Granularity", + "$ref": "../../common/beaconCommonComponents.json#/$defs/Granularity", "description": "Requested granularity for the response which may differe from the response's actual granularity." }, "requestedSchemas": { "$comment": "TODO: Add the format attribute as a uri.", - "$ref": "../../common/beaconCommonComponents.json#/definitions/ListOfSchemas", + "$ref": "../../common/beaconCommonComponents.json#/$defs/ListOfSchemas", "description": "Set of schemas to be used in the response to a request. `minItems: 0` is used to confirm that an empty array is acceptable here.", "minItems": 0 }, "testMode": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/TestMode", + "$ref": "../../common/beaconCommonComponents.json#/$defs/TestMode", "description": "Used for indicating that a request was received in a test context." } }, diff --git a/framework/json/responses/sections/beaconResponseMeta.json b/framework/json/responses/sections/beaconResponseMeta.json index b2206fe2e..85eff8f95 100644 --- a/framework/json/responses/sections/beaconResponseMeta.json +++ b/framework/json/responses/sections/beaconResponseMeta.json @@ -3,24 +3,24 @@ "description": "Information about the response that could be relevant for the Beacon client in order to interpret the results.", "properties": { "apiVersion": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ApiVersion" + "$ref": "../../common/beaconCommonComponents.json#/$defs/ApiVersion" }, "beaconId": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/BeaconId" + "$ref": "../../common/beaconCommonComponents.json#/$defs/BeaconId" }, "receivedRequestSummary": { "$ref": "./beaconReceivedRequestSummary.json" }, "returnedGranularity": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Granularity", + "$ref": "../../common/beaconCommonComponents.json#/$defs/Granularity", "description": "Granularity of the Beacon response which may differ from the requested one. For details see the prototype definition." }, "returnedSchemas": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ListOfSchemas", + "$ref": "../../common/beaconCommonComponents.json#/$defs/ListOfSchemas", "description": "The `returnedSchemas` parameter indicates that the request has been interpreted for the indicated entity. This helps to disambiguate between negative responses due to e.g. no hit on a well understood request and failures to interpret or answer the request due to a missing entity. " }, "testMode": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/TestMode" + "$ref": "../../common/beaconCommonComponents.json#/$defs/TestMode" } }, "required": [ diff --git a/framework/json/responses/sections/beaconResultsets.json b/framework/json/responses/sections/beaconResultsets.json index a54e43030..0d56cd50f 100644 --- a/framework/json/responses/sections/beaconResultsets.json +++ b/framework/json/responses/sections/beaconResultsets.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "ResultsetInstance": { "additionalProperties": true, "properties": { @@ -29,7 +27,7 @@ "type": "integer" }, "resultsHandovers": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/ListOfHandovers", + "$ref": "../../common/beaconCommonComponents.json#/$defs/ListOfHandovers", "description": "List of handovers that apply to this resultset, not to the whole Beacon or to a result in particular." }, "setType": { @@ -48,14 +46,16 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Sets of results to be returned as query response.", "properties": { "$schema": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/$schema" + "$ref": "../../common/beaconCommonComponents.json#/$defs/$schema" }, "resultSets": { "items": { - "$ref": "#/definitions/ResultsetInstance" + "$ref": "#/$defs/ResultsetInstance" }, "minItems": 0, "type": "array" diff --git a/framework/json/responses/sections/beaconSummaryResponseSection.json b/framework/json/responses/sections/beaconSummaryResponseSection.json index cc64e55d8..9e19e647c 100644 --- a/framework/json/responses/sections/beaconSummaryResponseSection.json +++ b/framework/json/responses/sections/beaconSummaryResponseSection.json @@ -3,10 +3,10 @@ "description": "Beacon results summary section.", "properties": { "exists": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/Exists" + "$ref": "../../common/beaconCommonComponents.json#/$defs/Exists" }, "numTotalResults": { - "$ref": "../../common/beaconCommonComponents.json#/definitions/NumTotalResults" + "$ref": "../../common/beaconCommonComponents.json#/$defs/NumTotalResults" } }, "required": [ diff --git a/framework/src/common/beaconCommonComponents.yaml b/framework/src/common/beaconCommonComponents.yaml index f8f479fa5..b77fab3ce 100644 --- a/framework/src/common/beaconCommonComponents.yaml +++ b/framework/src/common/beaconCommonComponents.yaml @@ -6,7 +6,7 @@ description: >- exclusively with one or the other. Separate schema documents are provided for complex components. type: object -definitions: +$defs: $schema: type: string $comment: 'TO REVIEW: adding a `format` or `regex` attribute that validates correctly @@ -67,7 +67,7 @@ definitions: Set of schemas to be used in the response to a request. type: array items: - $ref: '#/definitions/SchemasPerEntity' + $ref: '#/$defs/SchemasPerEntity' SchemasPerEntity: description: >- Schema to be used for the requested entry type in the response. @@ -91,24 +91,24 @@ definitions: type: object properties: skip: - $ref: '#/definitions/Skip' + $ref: '#/$defs/Skip' limit: - $ref: '#/definitions/Limit' + $ref: '#/$defs/Limit' currentPage: description: >- Token of the returned page. To be used only in the response to allow the client to check if the returned page is the one requested. - $ref: '#/definitions/PageToken' + $ref: '#/$defs/PageToken' nextPage: description: >- Token of the next page. Used to navigate forward. If empty, it is assumed that no more pages are available - $ref: '#/definitions/PageToken' + $ref: '#/$defs/PageToken' previousPage: description: >- Token of the previous page. Used to navigate backwards. If empty, it is assumed that the current page is the first one. - $ref: '#/definitions/PageToken' + $ref: '#/$defs/PageToken' Skip: description: >- * In the request: number of pages to skip @@ -227,7 +227,7 @@ definitions: type: array items: description: Requested schema to be used for individuals in the response. - $ref: '#/definitions/Handover' + $ref: '#/$defs/Handover' Handover: type: object description: >- @@ -247,7 +247,7 @@ definitions: - url properties: handoverType: - $ref: '#/definitions/HandoverType' + $ref: '#/$defs/HandoverType' note: type: string description: >- diff --git a/framework/src/common/ontologyTerm.yaml b/framework/src/common/ontologyTerm.yaml index bc1ad7bc5..1978ff0b8 100644 --- a/framework/src/common/ontologyTerm.yaml +++ b/framework/src/common/ontologyTerm.yaml @@ -4,7 +4,7 @@ description: Definition of an ontology term. type: object properties: id: - $ref: './beaconCommonComponents.yaml#/definitions/CURIE' + $ref: './beaconCommonComponents.yaml#/$defs/CURIE' label: type: string description: The text that describes the term. By default it could be the preferred diff --git a/framework/src/configuration/beaconConfigurationSchema.yaml b/framework/src/configuration/beaconConfigurationSchema.yaml index f6f013d92..bcd6a64e4 100644 --- a/framework/src/configuration/beaconConfigurationSchema.yaml +++ b/framework/src/configuration/beaconConfigurationSchema.yaml @@ -5,7 +5,7 @@ description: Files complaint with this schema are the configuration ones. The de type: object properties: $schema: - $ref: ../common/beaconCommonComponents.yaml#/definitions/$schema + $ref: ../common/beaconCommonComponents.yaml#/$defs/$schema maturityAttributes: description: Declares the level of maturity of the Beacon instance. type: object @@ -31,7 +31,7 @@ properties: defaultGranularity: description: Default granularity. Some responses could return higher detail, but this would be the granularity by default. - $ref: ../common/beaconCommonComponents.yaml#/definitions/Granularity + $ref: ../common/beaconCommonComponents.yaml#/$defs/Granularity securityLevels: description: All access levels supported by the Beacon. Any combination is valid, as every option would apply to different parts of the Beacon. @@ -44,8 +44,8 @@ properties: default: - CONTROLLED entryTypes: - $ref: '#/definitions/EntryTypes' -definitions: + $ref: '#/$defs/EntryTypes' +$defs: EntryTypes: description: This is a dictionary of the entry types implemented in this Beacon instance. diff --git a/framework/src/configuration/beaconMapSchema.yaml b/framework/src/configuration/beaconMapSchema.yaml index ce1cff2c2..ad36f0074 100644 --- a/framework/src/configuration/beaconMapSchema.yaml +++ b/framework/src/configuration/beaconMapSchema.yaml @@ -5,7 +5,7 @@ description: Map of a Beacon, its entry types and endpoints. It isconceptually s type: object properties: $schema: - $ref: ../common/beaconCommonComponents.yaml#/definitions/$schema + $ref: ../common/beaconCommonComponents.yaml#/$defs/$schema endpointSets: description: List of enpoints included in this Beacon instance. This is list is meant to inform Beacon clients, e.g. a Beacon Network, about the available endpoints, @@ -13,9 +13,9 @@ properties: validation purposes. type: object additionalProperties: - $ref: '#/definitions/Endpoint' + $ref: '#/$defs/Endpoint' minProperties: 1 -definitions: +$defs: Endpoint: type: object properties: @@ -63,7 +63,7 @@ definitions: OpenAPI definition referenced in the `openAPIEndpointsDefinition` attribute. type: object additionalProperties: - $ref: '#/definitions/RelatedEndpoint' + $ref: '#/$defs/RelatedEndpoint' minProperties: 0 required: - entryType diff --git a/framework/src/configuration/entryTypeDefinition.yaml b/framework/src/configuration/entryTypeDefinition.yaml index 99f3ef974..8f6fe509f 100644 --- a/framework/src/configuration/entryTypeDefinition.yaml +++ b/framework/src/configuration/entryTypeDefinition.yaml @@ -13,7 +13,7 @@ $comment: 'TO DO: The tagged parts should reference to `common/ontologizedElemen should not affect the resulting schema.' properties: $schema: - $ref: ../common/beaconCommonComponents.yaml#/definitions/$schema + $ref: ../common/beaconCommonComponents.yaml#/$defs/$schema id: $comments: ++++++ THIS IS THE START OF THE ontologized element ++++++ type: string @@ -62,7 +62,7 @@ properties: $comment: "TO DO: Double-check the proper way of referencing a path or relative\ \ path. 'format: uri' is throwing validation errors for relative file paths" nonFilteredQueriesAllowed: - $ref: ../common/beaconCommonComponents.yaml#/definitions/NonFilteredQueriesAllowed + $ref: ../common/beaconCommonComponents.yaml#/$defs/NonFilteredQueriesAllowed required: - id - name diff --git a/framework/src/configuration/entryTypesSchema.yaml b/framework/src/configuration/entryTypesSchema.yaml index 5f69a408f..8b88438e0 100644 --- a/framework/src/configuration/entryTypesSchema.yaml +++ b/framework/src/configuration/entryTypesSchema.yaml @@ -5,8 +5,8 @@ type: object properties: entryTypes: description: List of entry types. - $ref: '#/definitions/EntryTypes' -definitions: + $ref: '#/$defs/EntryTypes' +$defs: EntryTypes: description: This is a dictionary of the entry types implemented in this Beacon instance. diff --git a/framework/src/configuration/filteringTermsSchema.yaml b/framework/src/configuration/filteringTermsSchema.yaml index c20f5bd42..8fa414db8 100644 --- a/framework/src/configuration/filteringTermsSchema.yaml +++ b/framework/src/configuration/filteringTermsSchema.yaml @@ -9,9 +9,9 @@ properties: in this instance of Beacon. type: array items: - $ref: '#/definitions/FilterTerm' + $ref: '#/$defs/FilterTerm' minItems: 0 -definitions: +$defs: FilterTerm: type: object properties: diff --git a/framework/src/endpoints.yaml b/framework/src/endpoints.yaml index 9e26e10ec..b1af44b9f 100644 --- a/framework/src/endpoints.yaml +++ b/framework/src/endpoints.yaml @@ -143,9 +143,9 @@ components: name: skip in: query schema: - $ref: ./common/beaconCommonComponents.yaml#/definitions/Skip + $ref: ./common/beaconCommonComponents.yaml#/$defs/Skip limit: name: limit in: query schema: - $ref: ./common/beaconCommonComponents.yaml#/definitions/Limit + $ref: ./common/beaconCommonComponents.yaml#/$defs/Limit diff --git a/framework/src/requests/beaconRequestBody.yaml b/framework/src/requests/beaconRequestBody.yaml index 18fc1586b..3649f7c87 100644 --- a/framework/src/requests/beaconRequestBody.yaml +++ b/framework/src/requests/beaconRequestBody.yaml @@ -6,14 +6,14 @@ description: >- type: object properties: $schema: - $ref: ../common/beaconCommonComponents.yaml#/definitions/$schema + $ref: ../common/beaconCommonComponents.yaml#/$defs/$schema meta: description: >- Information relevant for building the response. $ref: ./beaconRequestMeta.yaml query: - $ref: '#/definitions/BeaconQuery' -definitions: + $ref: '#/$defs/BeaconQuery' +$defs: BeaconQuery: description: >- Parameters to limit the list of returned results. @@ -28,23 +28,23 @@ definitions: Ontology based filters. Using CURIE syntax is encouraged. $ref: ./filteringTerms.yaml includeResultsetResponses: - $ref: ../common/beaconCommonComponents.yaml#/definitions/IncludeResultsetResponses + $ref: ../common/beaconCommonComponents.yaml#/$defs/IncludeResultsetResponses pagination: description: >- Pagination parameters applied to response documents, in case of record level granularity. - $ref: ../common/beaconCommonComponents.yaml#/definitions/Pagination + $ref: ../common/beaconCommonComponents.yaml#/$defs/Pagination requestedGranularity: description: >- Requested granularity for the response. Beacons do not have to respond with the requested granularity, e.g. may respond with count results although record level granularity had been requested but indicate the granularity of the response in the response's metadata. - $ref: ../common/beaconCommonComponents.yaml#/definitions/Granularity + $ref: ../common/beaconCommonComponents.yaml#/$defs/Granularity testMode: description: >- Used for indicating that a request or response is done in a test context. - $ref: ../common/beaconCommonComponents.yaml#/definitions/TestMode + $ref: ../common/beaconCommonComponents.yaml#/$defs/TestMode required: - meta diff --git a/framework/src/requests/beaconRequestMeta.yaml b/framework/src/requests/beaconRequestMeta.yaml index c7da2f44d..4b3f934b8 100644 --- a/framework/src/requests/beaconRequestMeta.yaml +++ b/framework/src/requests/beaconRequestMeta.yaml @@ -4,13 +4,13 @@ description: Meta section of the Beacon request. It includes request context det type: object properties: $schema: - $ref: ../common/beaconCommonComponents.yaml#/definitions/$schema + $ref: ../common/beaconCommonComponents.yaml#/$defs/$schema apiVersion: description: API version expected by the client to be supported by the server and used in the response format. - $ref: ../common/beaconCommonComponents.yaml#/definitions/ApiVersion + $ref: ../common/beaconCommonComponents.yaml#/$defs/ApiVersion requestedSchemas: description: Set of schemas to be used in the response. - $ref: ../common/beaconCommonComponents.yaml#/definitions/ListOfSchemas + $ref: ../common/beaconCommonComponents.yaml#/$defs/ListOfSchemas required: - apiVersion diff --git a/framework/src/requests/filteringTerms.yaml b/framework/src/requests/filteringTerms.yaml index 23b7cddd0..2b1a8fbbc 100644 --- a/framework/src/requests/filteringTerms.yaml +++ b/framework/src/requests/filteringTerms.yaml @@ -8,13 +8,13 @@ description: >- to be chained by the logical AND operator. type: array items: - $ref: '#/definitions/FilteringTerm' -definitions: + $ref: '#/$defs/FilteringTerm' +$defs: FilteringTerm: anyOf: - - $ref: '#/definitions/OntologyFilter' - - $ref: '#/definitions/AlphanumericFilter' - - $ref: '#/definitions/CustomFilter' + - $ref: '#/$defs/OntologyFilter' + - $ref: '#/$defs/AlphanumericFilter' + - $ref: '#/$defs/CustomFilter' OntologyFilter: type: object description: Filter results to include records that contain a specific ontology diff --git a/framework/src/responses/beaconBooleanResponse.yaml b/framework/src/responses/beaconBooleanResponse.yaml index 976a03628..97811e09c 100644 --- a/framework/src/responses/beaconBooleanResponse.yaml +++ b/framework/src/responses/beaconBooleanResponse.yaml @@ -17,13 +17,13 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/definitions/Info + $ref: ../common/beaconCommonComponents.yaml#/$defs/Info beaconHandovers: description: >- List of handovers that apply to the whole response, not to any resultset or result in particular. - $ref: ../common/beaconCommonComponents.yaml#/definitions/ListOfHandovers + $ref: ../common/beaconCommonComponents.yaml#/$defs/ListOfHandovers required: - meta - responseSummary diff --git a/framework/src/responses/beaconCollectionsResponse.yaml b/framework/src/responses/beaconCollectionsResponse.yaml index ed30f724b..8b895ce6f 100644 --- a/framework/src/responses/beaconCollectionsResponse.yaml +++ b/framework/src/responses/beaconCollectionsResponse.yaml @@ -27,11 +27,11 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/definitions/Info + $ref: ../common/beaconCommonComponents.yaml#/$defs/Info beaconHandovers: description: List of handovers that apply to the whole response, not to any resultset or result in particular. - $ref: ../common/beaconCommonComponents.yaml#/definitions/ListOfHandovers + $ref: ../common/beaconCommonComponents.yaml#/$defs/ListOfHandovers required: - meta - responseSummary diff --git a/framework/src/responses/beaconCountResponse.yaml b/framework/src/responses/beaconCountResponse.yaml index 7b9d11570..f083849bd 100644 --- a/framework/src/responses/beaconCountResponse.yaml +++ b/framework/src/responses/beaconCountResponse.yaml @@ -17,12 +17,12 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/definitions/Info + $ref: ../common/beaconCommonComponents.yaml#/$defs/Info beaconHandovers: description: >- List of handovers that apply to the whole response, not to any resultset or result in particular. - $ref: ../common/beaconCommonComponents.yaml#/definitions/ListOfHandovers + $ref: ../common/beaconCommonComponents.yaml#/$defs/ListOfHandovers required: - meta - responseSummary diff --git a/framework/src/responses/beaconErrorResponse.yaml b/framework/src/responses/beaconErrorResponse.yaml index beaf8afa8..e902a32fa 100644 --- a/framework/src/responses/beaconErrorResponse.yaml +++ b/framework/src/responses/beaconErrorResponse.yaml @@ -6,7 +6,7 @@ properties: meta: $ref: ./sections/beaconResponseMeta.yaml error: - $ref: ../common/beaconCommonComponents.yaml#/definitions/BeaconError + $ref: ../common/beaconCommonComponents.yaml#/$defs/BeaconError required: - meta - error diff --git a/framework/src/responses/beaconResultsetsResponse.yaml b/framework/src/responses/beaconResultsetsResponse.yaml index bbb8a0e18..11e8b732c 100644 --- a/framework/src/responses/beaconResultsetsResponse.yaml +++ b/framework/src/responses/beaconResultsetsResponse.yaml @@ -15,12 +15,12 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/definitions/Info + $ref: ../common/beaconCommonComponents.yaml#/$defs/Info beaconHandovers: description: >- List of handovers that apply to the whole response, not to any resultset or result in particular. - $ref: ../common/beaconCommonComponents.yaml#/definitions/ListOfHandovers + $ref: ../common/beaconCommonComponents.yaml#/$defs/ListOfHandovers response: description: >- Response for queries that recovers any result. diff --git a/framework/src/responses/ga4gh-service-info-1-0-0-schema.yaml b/framework/src/responses/ga4gh-service-info-1-0-0-schema.yaml index a00ce4b3d..97842018e 100644 --- a/framework/src/responses/ga4gh-service-info-1-0-0-schema.yaml +++ b/framework/src/responses/ga4gh-service-info-1-0-0-schema.yaml @@ -25,7 +25,7 @@ properties: Name of this service. Should be human readable. example: My project type: - $ref: '#/definitions/ServiceType' + $ref: '#/$defs/ServiceType' description: type: string description: >- @@ -91,7 +91,7 @@ properties: but other identifiers, such as dates or commit hashes, are also allowed. The version should be changed whenever the service is updated. example: 1.0.0 -definitions: +$defs: ServiceType: description: Type of a GA4GH service type: object diff --git a/framework/src/responses/sections/beaconBooleanResponseSection.yaml b/framework/src/responses/sections/beaconBooleanResponseSection.yaml index 928331fad..bd4052ecf 100644 --- a/framework/src/responses/sections/beaconBooleanResponseSection.yaml +++ b/framework/src/responses/sections/beaconBooleanResponseSection.yaml @@ -5,4 +5,4 @@ required: - exists properties: exists: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Exists + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Exists diff --git a/framework/src/responses/sections/beaconCountResponseSection.yaml b/framework/src/responses/sections/beaconCountResponseSection.yaml index 6ee9924c4..14c1994d3 100644 --- a/framework/src/responses/sections/beaconCountResponseSection.yaml +++ b/framework/src/responses/sections/beaconCountResponseSection.yaml @@ -4,10 +4,10 @@ description: >- type: object properties: exists: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Exists + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Exists numTotalResults: description: Total number of results. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/NumTotalResults + $ref: ../../common/beaconCommonComponents.yaml#/$defs/NumTotalResults required: - exists - numTotalResults diff --git a/framework/src/responses/sections/beaconFilteringTermsResults.yaml b/framework/src/responses/sections/beaconFilteringTermsResults.yaml index 05748d8cc..f0a654b46 100644 --- a/framework/src/responses/sections/beaconFilteringTermsResults.yaml +++ b/framework/src/responses/sections/beaconFilteringTermsResults.yaml @@ -6,12 +6,12 @@ properties: resources: type: array items: - $ref: '#/definitions/Resource' + $ref: '#/$defs/Resource' filteringTerms: type: array items: - $ref: '#/definitions/FilteringTerm' -definitions: + $ref: '#/$defs/FilteringTerm' +$defs: FilteringTerm: type: object description: >- diff --git a/framework/src/responses/sections/beaconInfoResults.yaml b/framework/src/responses/sections/beaconInfoResults.yaml index db432fe09..2127e4a1f 100644 --- a/framework/src/responses/sections/beaconInfoResults.yaml +++ b/framework/src/responses/sections/beaconInfoResults.yaml @@ -10,13 +10,13 @@ required: - organization properties: id: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/BeaconId + $ref: ../../common/beaconCommonComponents.yaml#/$defs/BeaconId name: type: string description: >- Name of the Beacon. apiVersion: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ApiVersion + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ApiVersion environment: type: string description: "Environment the service is running in. Use this to distinguish\n\ @@ -29,7 +29,7 @@ properties: examples: - dev organization: - $ref: '#/definitions/BeaconOrganization' + $ref: '#/$defs/BeaconOrganization' description: type: string description: >- @@ -37,7 +37,7 @@ properties: version: description: >- TODO: This is a legacy use / duplication? - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ApiVersion + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ApiVersion welcomeUrl: type: string description: >- @@ -67,8 +67,8 @@ properties: info: description: >- Additional unspecified metadata about the Beacon service. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Info -definitions: + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Info +$defs: BeaconOrganization: description: >- Organization owning the Beacon. @@ -109,5 +109,5 @@ definitions: 3986 format). info: description: Additional unspecified metadata about the host Organization. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Info + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Info additionalProperties: true diff --git a/framework/src/responses/sections/beaconInformationalResponseMeta.yaml b/framework/src/responses/sections/beaconInformationalResponseMeta.yaml index c1255cd4c..6bcc2beb4 100644 --- a/framework/src/responses/sections/beaconInformationalResponseMeta.yaml +++ b/framework/src/responses/sections/beaconInformationalResponseMeta.yaml @@ -4,11 +4,11 @@ description: >- type: object properties: beaconId: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/BeaconId + $ref: ../../common/beaconCommonComponents.yaml#/$defs/BeaconId apiVersion: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ApiVersion + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ApiVersion returnedSchemas: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ListOfSchemas + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ListOfSchemas $comment: 'TO REVIEW: the required properties below results in a warning in the example.' required: - beaconId diff --git a/framework/src/responses/sections/beaconReceivedRequestSummary.yaml b/framework/src/responses/sections/beaconReceivedRequestSummary.yaml index c15df32dc..6c6774507 100644 --- a/framework/src/responses/sections/beaconReceivedRequestSummary.yaml +++ b/framework/src/responses/sections/beaconReceivedRequestSummary.yaml @@ -11,39 +11,39 @@ properties: description: >- API version expected by the client to be supported by the server and used in the response format. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ApiVersion + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ApiVersion requestedSchemas: description: >- Set of schemas to be used in the response to a request. `minItems: 0` is used to confirm that an empty array is acceptable here. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ListOfSchemas + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ListOfSchemas minItems: 0 $comment: >- TODO: Add the format attribute as a uri. filters: description: >- Filters as submitted in the request. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Filters + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Filters requestParameters: description: >- Dictionary of request parameters received in the `RequestBody` or as part of a GET request. $ref: ../../requests/requestParameters.yaml includeResultsetResponses: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/IncludeResultsetResponses + $ref: ../../common/beaconCommonComponents.yaml#/$defs/IncludeResultsetResponses pagination: description: >- Pagination as requested for the results. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Pagination + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Pagination requestedGranularity: description: >- Requested granularity for the response which may differe from the response's actual granularity. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Granularity + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Granularity testMode: description: >- Used for indicating that a request was received in a test context. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/TestMode + $ref: ../../common/beaconCommonComponents.yaml#/$defs/TestMode required: - apiVersion - requestedSchemas diff --git a/framework/src/responses/sections/beaconResponseMeta.yaml b/framework/src/responses/sections/beaconResponseMeta.yaml index 84239c672..6155d035f 100644 --- a/framework/src/responses/sections/beaconResponseMeta.yaml +++ b/framework/src/responses/sections/beaconResponseMeta.yaml @@ -5,23 +5,23 @@ description: >- type: object properties: beaconId: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/BeaconId + $ref: ../../common/beaconCommonComponents.yaml#/$defs/BeaconId apiVersion: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ApiVersion + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ApiVersion returnedSchemas: description: >- The `returnedSchemas` parameter indicates that the request has been interpreted for the indicated entity. This helps to disambiguate between negative responses due to e.g. no hit on a well understood request and failures to interpret or answer the request due to a missing entity. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ListOfSchemas + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ListOfSchemas returnedGranularity: description: >- Granularity of the Beacon response which may differ from the requested one. For details see the prototype definition. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Granularity + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Granularity testMode: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/TestMode + $ref: ../../common/beaconCommonComponents.yaml#/$defs/TestMode receivedRequestSummary: $ref: ./beaconReceivedRequestSummary.yaml required: diff --git a/framework/src/responses/sections/beaconResultsets.yaml b/framework/src/responses/sections/beaconResultsets.yaml index 09835db13..4f257ca90 100644 --- a/framework/src/responses/sections/beaconResultsets.yaml +++ b/framework/src/responses/sections/beaconResultsets.yaml @@ -4,16 +4,16 @@ description: Sets of results to be returned as query response. type: object properties: $schema: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/$schema + $ref: ../../common/beaconCommonComponents.yaml#/$defs/$schema resultSets: type: array items: - $ref: '#/definitions/ResultsetInstance' + $ref: '#/$defs/ResultsetInstance' minItems: 0 required: - resultSets additionalProperties: true -definitions: +$defs: ResultsetInstance: type: object properties: @@ -34,7 +34,7 @@ definitions: resultsHandovers: description: List of handovers that apply to this resultset, not to the whole Beacon or to a result in particular. - $ref: ../../common/beaconCommonComponents.yaml#/definitions/ListOfHandovers + $ref: ../../common/beaconCommonComponents.yaml#/$defs/ListOfHandovers info: description: Additional details that could be of interest about the Resultset. Provided to clearly enclose any attribute that is not part of the Beacon diff --git a/framework/src/responses/sections/beaconSummaryResponseSection.yaml b/framework/src/responses/sections/beaconSummaryResponseSection.yaml index 7fb855a15..2f9dfa433 100644 --- a/framework/src/responses/sections/beaconSummaryResponseSection.yaml +++ b/framework/src/responses/sections/beaconSummaryResponseSection.yaml @@ -3,8 +3,8 @@ description: Beacon results summary section. type: object properties: exists: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/Exists + $ref: ../../common/beaconCommonComponents.yaml#/$defs/Exists numTotalResults: - $ref: ../../common/beaconCommonComponents.yaml#/definitions/NumTotalResults + $ref: ../../common/beaconCommonComponents.yaml#/$defs/NumTotalResults required: - exists diff --git a/models/json/beacon-v2-default-model/analyses/defaultSchema.json b/models/json/beacon-v2-default-model/analyses/defaultSchema.json index e2fd84089..a082caa73 100644 --- a/models/json/beacon-v2-default-model/analyses/defaultSchema.json +++ b/models/json/beacon-v2-default-model/analyses/defaultSchema.json @@ -38,7 +38,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" }, "pipelineName": { "description": "Analysis pipeline and version if a standardized pipeline was used", diff --git a/models/json/beacon-v2-default-model/analyses/endpoints.json b/models/json/beacon-v2-default-model/analyses/endpoints.json index 570d7201d..165a5e9b9 100644 --- a/models/json/beacon-v2-default-model/analyses/endpoints.json +++ b/models/json/beacon-v2-default-model/analyses/endpoints.json @@ -25,13 +25,13 @@ } }, "includeResultsetResponses": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses" }, "limit": { "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -48,7 +48,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/models/json/beacon-v2-default-model/biosamples/defaultSchema.json b/models/json/beacon-v2-default-model/biosamples/defaultSchema.json index c1a2d65da..392f5988a 100644 --- a/models/json/beacon-v2-default-model/biosamples/defaultSchema.json +++ b/models/json/beacon-v2-default-model/biosamples/defaultSchema.json @@ -82,7 +82,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" }, "measurements": { "description": "List of measurements of the sample.", diff --git a/models/json/beacon-v2-default-model/biosamples/endpoints.json b/models/json/beacon-v2-default-model/biosamples/endpoints.json index 533d5ceda..20f297fe5 100644 --- a/models/json/beacon-v2-default-model/biosamples/endpoints.json +++ b/models/json/beacon-v2-default-model/biosamples/endpoints.json @@ -29,13 +29,13 @@ } }, "includeResultsetResponses": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses" }, "limit": { "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -52,7 +52,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/models/json/beacon-v2-default-model/cohorts/defaultSchema.json b/models/json/beacon-v2-default-model/cohorts/defaultSchema.json index 95541595a..72449f3a4 100644 --- a/models/json/beacon-v2-default-model/cohorts/defaultSchema.json +++ b/models/json/beacon-v2-default-model/cohorts/defaultSchema.json @@ -1,8 +1,6 @@ { "$comment": "version: ga4gh-beacon-cohort-v2.0.0", - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "CohortCriteria": { "description": "Criteria used for defining the cohort. It is assumed that all cohort participants will match or NOT match such criteria.", "properties": { @@ -20,21 +18,21 @@ "ethnicities": { "description": "Ethnias in cohort inclusion criteria", "items": { - "$ref": "../common/commonDefinitions.json#/definitions/Ethnicity" + "$ref": "../common/commonDefinitions.json#/$defs/Ethnicity" }, "type": "array" }, "genders": { "description": "Gender(s) in cohort inclusion criteria", "items": { - "$ref": "../common/commonDefinitions.json#/definitions/Sex" + "$ref": "../common/commonDefinitions.json#/$defs/Sex" }, "type": "array" }, "locations": { "description": "Geographic location(s) in cohort inclusion criteria", "items": { - "$ref": "../common/commonDefinitions.json#/definitions/GeographicLocation" + "$ref": "../common/commonDefinitions.json#/$defs/GeographicLocation" }, "type": "array" }, @@ -52,7 +50,7 @@ "description": "TBD", "properties": { "eventAgeRange": { - "$ref": "#/definitions/DataAvailabilityAndDistribution", + "$ref": "#/$defs/DataAvailabilityAndDistribution", "description": "Individual age range, obtained from individual level info of the cohort members" }, "eventCases": { @@ -72,7 +70,7 @@ "type": "integer" }, "eventDataTypes": { - "$ref": "#/definitions/DataAvailabilityAndDistribution", + "$ref": "#/$defs/DataAvailabilityAndDistribution", "description": "Aggregated data type information available for each cohort data type as declared in `cohortDataTypes`, and obtained from individual level info of the cohort members", "type": "object" }, @@ -87,19 +85,19 @@ "type": "string" }, "eventDiseases": { - "$ref": "#/definitions/DataAvailabilityAndDistribution", + "$ref": "#/$defs/DataAvailabilityAndDistribution", "description": "Aggregated information of disease/condition(s) obtained from individual level info of the cohort members" }, "eventEthnicities": { - "$ref": "#/definitions/DataAvailabilityAndDistribution", + "$ref": "#/$defs/DataAvailabilityAndDistribution", "description": "Aggregated information of ethnicity obtained from individual level info of the cohort members" }, "eventGenders": { - "$ref": "#/definitions/DataAvailabilityAndDistribution", + "$ref": "#/$defs/DataAvailabilityAndDistribution", "description": "Aggregated information of gender(s) obtained from individual level info of the cohort members" }, "eventLocations": { - "$ref": "#/definitions/DataAvailabilityAndDistribution", + "$ref": "#/$defs/DataAvailabilityAndDistribution", "description": "Aggregated information of geographic location obtained from individual level info of the cohort members" }, "eventNum": { @@ -113,7 +111,7 @@ "type": "integer" }, "eventPhenotypes": { - "$ref": "#/definitions/DataAvailabilityAndDistribution", + "$ref": "#/$defs/DataAvailabilityAndDistribution", "description": "Aggregated information of phenotype(s) obtained from individual level info of the cohort members" }, "eventSize": { @@ -208,10 +206,12 @@ "type": "array" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "A cohort available in the beacon.", "properties": { "cohortDataTypes": { - "$ref": "#/definitions/DataTypesArray" + "$ref": "#/$defs/DataTypesArray" }, "cohortDesign": { "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/ontologyTerm.json", @@ -252,12 +252,12 @@ "collectionEvents": { "description": "TBD", "items": { - "$ref": "#/definitions/CollectionEvent" + "$ref": "#/$defs/CollectionEvent" }, "type": "array" }, "exclusionCriteria": { - "$ref": "#/definitions/CohortCriteria", + "$ref": "#/$defs/CohortCriteria", "description": "Exclusion criteria used for defining the cohort. It is assumed that NONE of the cohort participants will match such criteria.", "type": "object" }, @@ -269,7 +269,7 @@ "type": "string" }, "inclusionCriteria": { - "$ref": "#/definitions/CohortCriteria", + "$ref": "#/$defs/CohortCriteria", "description": "Inclusion criteria used for defining the cohort. It is assumed that all cohort participants will match such criteria.", "type": "object" }, diff --git a/models/json/beacon-v2-default-model/cohorts/endpoints.json b/models/json/beacon-v2-default-model/cohorts/endpoints.json index 1e36b7462..b56550bc5 100644 --- a/models/json/beacon-v2-default-model/cohorts/endpoints.json +++ b/models/json/beacon-v2-default-model/cohorts/endpoints.json @@ -28,7 +28,7 @@ "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -45,7 +45,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/models/json/beacon-v2-default-model/common/age.json b/models/json/beacon-v2-default-model/common/age.json index e7f4a6c66..f6b941fde 100644 --- a/models/json/beacon-v2-default-model/common/age.json +++ b/models/json/beacon-v2-default-model/common/age.json @@ -3,7 +3,7 @@ "description": "Age value definition. Provenance: GA4GH Phenopackets v2 `Age`", "properties": { "iso8601duration": { - "description": "Represents age as a ISO8601 duration (e.g., 'P40Y10M05D').", + "description": "Represents age as a ISO8601 duration (e.g., P40Y10M05D).", "example": "P32Y6M1D", "type": "string" } @@ -13,4 +13,4 @@ ], "title": "Age", "type": "object" -} +} \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/common/ageRange.json b/models/json/beacon-v2-default-model/common/ageRange.json index 31fb79c76..1bb6ff693 100644 --- a/models/json/beacon-v2-default-model/common/ageRange.json +++ b/models/json/beacon-v2-default-model/common/ageRange.json @@ -12,8 +12,8 @@ } }, "required": [ - "end", - "start" + "start", + "end" ], "title": "AgeRange", "type": "object" diff --git a/models/json/beacon-v2-default-model/common/commonDefinitions.json b/models/json/beacon-v2-default-model/common/commonDefinitions.json index 197e950ad..73d8c3f61 100644 --- a/models/json/beacon-v2-default-model/common/commonDefinitions.json +++ b/models/json/beacon-v2-default-model/common/commonDefinitions.json @@ -1,6 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "definitions": { + "$defs": { "Ethnicity": { "$ref": "../../../../framework/json/common/ontologyTerm.json", "description": "Ethnic background of the individual. Recommended is the use of a value from NCIT Race (NCIT:C17049) ontology term descendants, e.g. NCIT:C126531 (Latin American). A geographic ancestral origin category that is assigned to a population group based mainly on physical characteristics that are thought to be distinct and inherent. [ NCI ]", @@ -148,6 +147,7 @@ ] } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", "description": "Definitions for concepts used in several entry types, but that having only one property are not complex enough to require a full independent schema document.", "title": "Common Definitions" } \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/common/complexValue.json b/models/json/beacon-v2-default-model/common/complexValue.json index fd9993392..3dd34192d 100644 --- a/models/json/beacon-v2-default-model/common/complexValue.json +++ b/models/json/beacon-v2-default-model/common/complexValue.json @@ -1,6 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "definitions": { + "$defs": { "TypedQuantity": { "properties": { "quantity": { @@ -30,17 +29,20 @@ ] } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", "description": "Definition of a complex value class. Provenance: GA4GH Phenopackets v2 `TypedQuantity`", "properties": { "typedQuantities": { "description": "List of quantities required to fully describe the complex value", "items": { - "$ref": "#/definitions/TypedQuantity" + "$ref": "#/$defs/TypedQuantity" }, "type": "array" } }, - "required": [ "typedQuantities" ], + "required": [ + "typedQuantities" + ], "title": "Complex Value", "type": "object" } \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/common/dataUseConditions.json b/models/json/beacon-v2-default-model/common/dataUseConditions.json index 4c4548a9b..df4aec7fe 100644 --- a/models/json/beacon-v2-default-model/common/dataUseConditions.json +++ b/models/json/beacon-v2-default-model/common/dataUseConditions.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "DUODataUse": { "allOf": [ { @@ -60,11 +58,13 @@ ] } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Data use conditions", "properties": { "duoDataUse": { "items": { - "$ref": "#/definitions/DUODataUse" + "$ref": "#/$defs/DUODataUse" }, "minItems": 1, "type": "array" diff --git a/models/json/beacon-v2-default-model/common/disease.json b/models/json/beacon-v2-default-model/common/disease.json index d50bbfdfa..c3b0041cd 100644 --- a/models/json/beacon-v2-default-model/common/disease.json +++ b/models/json/beacon-v2-default-model/common/disease.json @@ -58,7 +58,7 @@ "type": "string" }, "severity": { - "$ref": "./commonDefinitions.json#/definitions/SeverityLevel", + "$ref": "./commonDefinitions.json#/$defs/SeverityLevel", "examples": [ { "id": "HP:0012828", diff --git a/models/json/beacon-v2-default-model/common/exposure.json b/models/json/beacon-v2-default-model/common/exposure.json index 6fd27fd63..9e139e0ca 100644 --- a/models/json/beacon-v2-default-model/common/exposure.json +++ b/models/json/beacon-v2-default-model/common/exposure.json @@ -33,7 +33,7 @@ ] }, "unit": { - "$ref": "../common/commonDefinitions.json#/definitions/Unit", + "$ref": "../common/commonDefinitions.json#/$defs/Unit", "description": "Unit of the exposure. Recommended from NCIT Unit of Category ontology term (NCIT:C42568) descendants." }, "value": { diff --git a/models/json/beacon-v2-default-model/common/pedigree.json b/models/json/beacon-v2-default-model/common/pedigree.json index 2b769f09e..1516d075b 100644 --- a/models/json/beacon-v2-default-model/common/pedigree.json +++ b/models/json/beacon-v2-default-model/common/pedigree.json @@ -1,7 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "pedigreeMember": { "examples": [ { @@ -97,6 +95,8 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Pedigree studies in which the individual is part of.", "properties": { "disease": { @@ -110,7 +110,7 @@ "members": { "description": "List of members of the pedigree. If the current pedigree definition is attached to the proband, it contains the whole list of pedigree members, including the proband. If the definition is attached to an individual different than the proband, it only contains two entries: one that describes that member, e.g. the proband mother or father, and one that points to the proband.", "items": { - "$ref": "#/definitions/pedigreeMember" + "$ref": "#/$defs/pedigreeMember" }, "minItems": 1, "type": "array" diff --git a/models/json/beacon-v2-default-model/common/phenotypicFeature.json b/models/json/beacon-v2-default-model/common/phenotypicFeature.json index edcf1581f..695e3a1d3 100644 --- a/models/json/beacon-v2-default-model/common/phenotypicFeature.json +++ b/models/json/beacon-v2-default-model/common/phenotypicFeature.json @@ -1,6 +1,6 @@ { + "$defs": {}, "$schema": "https://json-schema.org/draft/2020-12/schema", - "definitions": {}, "description": "Used to describe a phenotype that characterizes the subject or biosample.", "properties": { "evidence": { @@ -61,7 +61,7 @@ "description": "Age or time at which the feature resolved or abated." }, "severity": { - "$ref": "./commonDefinitions.json#/definitions/SeverityLevel", + "$ref": "./commonDefinitions.json#/$defs/SeverityLevel", "examples": [ { "id": "HP:0012828", diff --git a/models/json/beacon-v2-default-model/common/quantity.json b/models/json/beacon-v2-default-model/common/quantity.json index 1a9969704..c3af5dc07 100644 --- a/models/json/beacon-v2-default-model/common/quantity.json +++ b/models/json/beacon-v2-default-model/common/quantity.json @@ -9,7 +9,7 @@ "example": {} }, "unit": { - "$ref": "./commonDefinitions.json#/definitions/Unit" + "$ref": "./commonDefinitions.json#/$defs/Unit" }, "value": { "description": "The value of the quantity in the units", diff --git a/models/json/beacon-v2-default-model/common/referenceRange.json b/models/json/beacon-v2-default-model/common/referenceRange.json index 2f538934c..70b45e102 100644 --- a/models/json/beacon-v2-default-model/common/referenceRange.json +++ b/models/json/beacon-v2-default-model/common/referenceRange.json @@ -18,7 +18,7 @@ "type": "number" }, "unit": { - "$ref": "./commonDefinitions.json#/definitions/Unit", + "$ref": "./commonDefinitions.json#/$defs/Unit", "description": "The kind of unit.", "examples": [ { diff --git a/models/json/beacon-v2-default-model/common/timeElement.json b/models/json/beacon-v2-default-model/common/timeElement.json index a6c00035c..22b26e3f4 100644 --- a/models/json/beacon-v2-default-model/common/timeElement.json +++ b/models/json/beacon-v2-default-model/common/timeElement.json @@ -13,7 +13,7 @@ "$ref": "./gestationalAge.json" }, { - "$ref": "./commonDefinitions.json#/definitions/Timestamp" + "$ref": "./commonDefinitions.json#/$defs/Timestamp" }, { "$ref": "./timeInterval.json" diff --git a/models/json/beacon-v2-default-model/common/timeInterval.json b/models/json/beacon-v2-default-model/common/timeInterval.json index 1d4a2a475..94f8b9862 100644 --- a/models/json/beacon-v2-default-model/common/timeInterval.json +++ b/models/json/beacon-v2-default-model/common/timeInterval.json @@ -5,13 +5,13 @@ "description": "Time interval with start and end defined as ISO8601 time stamps.", "properties": { "end": { - "$ref": "./commonDefinitions.json#/definitions/Timestamp", + "$ref": "./commonDefinitions.json#/$defs/Timestamp", "examples": [ "2022-03-10T15:25:07Z" ] }, "start": { - "$ref": "./commonDefinitions.json#/definitions/Timestamp", + "$ref": "./commonDefinitions.json#/$defs/Timestamp", "examples": [ "1999-08-05T17:21:00+01:00", "2002-09-21T02:37:00-08:00" diff --git a/models/json/beacon-v2-default-model/datasets/defaultSchema.json b/models/json/beacon-v2-default-model/datasets/defaultSchema.json index 41acb023d..3efa64e7d 100644 --- a/models/json/beacon-v2-default-model/datasets/defaultSchema.json +++ b/models/json/beacon-v2-default-model/datasets/defaultSchema.json @@ -5,7 +5,7 @@ "description": "A dataset available in the beacon", "properties": { "createDateTime": { - "$ref": "../common/commonDefinitions.json#/definitions/Timestamp", + "$ref": "../common/commonDefinitions.json#/$defs/Timestamp", "description": "The time the dataset was created (ISO 8601 format)", "examples": [ "2017-01-17T20:33:40Z" @@ -37,7 +37,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" }, "name": { "description": "Name of the dataset", @@ -47,7 +47,7 @@ "type": "string" }, "updateDateTime": { - "$ref": "../common/commonDefinitions.json#/definitions/Timestamp", + "$ref": "../common/commonDefinitions.json#/$defs/Timestamp", "description": "The time the dataset was updated in (ISO 8601 format)", "examples": [ "2017-01-17T20:33:40Z" diff --git a/models/json/beacon-v2-default-model/datasets/endpoints.json b/models/json/beacon-v2-default-model/datasets/endpoints.json index 3fdc832a4..53831fffa 100644 --- a/models/json/beacon-v2-default-model/datasets/endpoints.json +++ b/models/json/beacon-v2-default-model/datasets/endpoints.json @@ -26,7 +26,7 @@ "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -43,7 +43,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/models/json/beacon-v2-default-model/endpoints.json b/models/json/beacon-v2-default-model/endpoints.json index 9c72ad0ef..0116f2fdf 100644 --- a/models/json/beacon-v2-default-model/endpoints.json +++ b/models/json/beacon-v2-default-model/endpoints.json @@ -5,7 +5,7 @@ "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -22,7 +22,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json b/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json index fc3b7f047..5ec02a7fd 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json +++ b/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json @@ -1,8 +1,6 @@ { "$comment": "version: ga4gh-beacon-variant-v2.0.0", - "$schema": "https://json-schema.org/draft/2020-12/schema", - "additionalProperties": true, - "definitions": { + "$defs": { "CaseLevelVariant": { "description": "", "properties": { @@ -56,7 +54,7 @@ }, "clinicalInterpretations": { "items": { - "$ref": "#/definitions/PhenoClinicEffect" + "$ref": "#/$defs/PhenoClinicEffect" }, "type": "array" }, @@ -76,7 +74,7 @@ }, "phenotypicEffects": { "items": { - "$ref": "#/definitions/PhenoClinicEffect" + "$ref": "#/$defs/PhenoClinicEffect" }, "type": "array" }, @@ -115,7 +113,7 @@ "properties": { "frequencies": { "items": { - "$ref": "#/definitions/PopulationFrequency" + "$ref": "#/$defs/PopulationFrequency" }, "minItems": 1, "type": "array" @@ -340,7 +338,7 @@ "genomicFeatures": { "description": "List of Genomic feature(s) affected by the variant.", "items": { - "$ref": "#/definitions/GenomicFeature" + "$ref": "#/$defs/GenomicFeature" }, "type": "array" }, @@ -368,7 +366,7 @@ "description": "List of annotated effects on disease or phenotypes.", "properties": { "annotatedWith": { - "$ref": "#/definitions/SoftwareTool" + "$ref": "#/$defs/SoftwareTool" }, "category": { "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/ontologyTerm.json", @@ -508,13 +506,13 @@ "properties": { "clinicalInterpretations": { "items": { - "$ref": "#/definitions/PhenoClinicEffect" + "$ref": "#/$defs/PhenoClinicEffect" }, "type": "array" }, "phenotypicEffects": { "items": { - "$ref": "#/definitions/PhenoClinicEffect" + "$ref": "#/$defs/PhenoClinicEffect" }, "type": "array" } @@ -522,26 +520,28 @@ "type": "object" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", + "additionalProperties": true, "description": "Schema for a genomic variant entry.", "properties": { "caseLevelData": { "description": "caseLevelData reports about the variation instances observed in individual analyses.", "items": { - "$ref": "#/definitions/CaseLevelVariant" + "$ref": "#/$defs/CaseLevelVariant" }, "type": "array" }, "frequencyInPopulations": { "items": { - "$ref": "#/definitions/FrequencyInPopulations" + "$ref": "#/$defs/FrequencyInPopulations" }, "type": "array" }, "identifiers": { - "$ref": "#/definitions/Identifiers" + "$ref": "#/$defs/Identifiers" }, "molecularAttributes": { - "$ref": "#/definitions/MolecularAttributes" + "$ref": "#/$defs/MolecularAttributes" }, "variantInternalId": { "description": "Reference to the **internal** variant ID. This represents the primary key/identifier of that variant **inside** a given Beacon instance. Different Beacon instances may use identical id values, referring to unrelated variants. Public identifiers such as the GA4GH Variant Representation Id (VRSid) MUST be returned in the `identifiers` section. A Beacon instance can, of course, use the VRSid as their own internal id but still MUST represent this then in the `identifiers` section.", @@ -552,7 +552,7 @@ "type": "string" }, "variantLevelData": { - "$ref": "#/definitions/VariantLevelData" + "$ref": "#/$defs/VariantLevelData" }, "variation": { "oneOf": [ @@ -563,7 +563,7 @@ "$ref": "https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/SystemicVariation" }, { - "$ref": "#/definitions/LegacyVariation" + "$ref": "#/$defs/LegacyVariation" } ] } diff --git a/models/json/beacon-v2-default-model/genomicVariations/endpoints.json b/models/json/beacon-v2-default-model/genomicVariations/endpoints.json index e9101f04f..2d29ed7be 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/endpoints.json +++ b/models/json/beacon-v2-default-model/genomicVariations/endpoints.json @@ -81,13 +81,13 @@ } }, "includeResultsetResponses": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses" }, "limit": { "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "referenceBases": { @@ -118,7 +118,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } }, "start": { diff --git a/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json b/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json index e469211f4..0651ccf29 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json +++ b/models/json/beacon-v2-default-model/genomicVariations/requestParameters.json @@ -3,7 +3,7 @@ "g_variant": { "properties": { "alternateBases": { - "$ref": "./requestParametersComponents.json#/definitions/AlternateBases" + "$ref": "./requestParametersComponents.json#/$defs/AlternateBases" }, "aminoacidChange": { "description": "Aminoacid alteration of interest. Format 1 letter", @@ -14,10 +14,10 @@ "type": "string" }, "assemblyId": { - "$ref": "./requestParametersComponents.json#/definitions/Assembly" + "$ref": "./requestParametersComponents.json#/$defs/Assembly" }, "end": { - "description": "Precise or bracketing the end of the variants of interest: * (0-based, exclusive) - see `start` * for bracket queries, provide 2 values (e.g. [111,222]).", + "description": "Precise or bracketing the end of the variants of interest: * (0-based, exclusive) - see `start` * for bracket queries, provide 2 values (e.g. [111,222]).\"", "items": { "format": "int64", "minimum": 1, @@ -43,16 +43,16 @@ "type": "string" }, "mateName": { - "$ref": "./requestParametersComponents.json#/definitions/RefSeqId" + "$ref": "./requestParametersComponents.json#/$defs/RefSeqId" }, "referenceBases": { - "$ref": "./requestParametersComponents.json#/definitions/ReferenceBases" + "$ref": "./requestParametersComponents.json#/$defs/ReferenceBases" }, "referenceName": { - "$ref": "./requestParametersComponents.json#/definitions/RefSeqId" + "$ref": "./requestParametersComponents.json#/$defs/RefSeqId" }, "start": { - "description": "Precise or fuzzy start coordinate position(s), allele locus (0-based, inclusive). * `start` only:\n - for single positions, e.g. the start of a specified sequence\nalteration where the size is given through the specified `alternateBases`\n - typical use are queries for SNV and small InDels\n - the use of `start` without an `end` parameter requires the use of\n`alternateBases`\n* 1 value each in both `start` and `end`:\n - for searching any variant falling fully or partially within the range\n between `start` and `end` (a.k.a. \"range query\")\n - additional use of `variantType` OR `alternateBases` can limit the\n scope of the query\n - by convention, partial overlaps of variants with the indicated genomic\n range are accepted; for specific overlap requirements the 4-parameter\n \"Bracket Queries\" should be employed\n* 2 values in both `start` and `end` for constructing a \"Bracket Query\":\n - can be used to match any contiguous genomic interval, e.g. for querying\n imprecise positions\n - identifies all structural variants starting between `start[0]` and `start[1]`,\n and ending between `end[0]` <-> `end[1]`\n - single or double sided precise matches can be achieved by setting\n `start[1]=start[0]+1` and `end[1]=end[0]+1`", + "description": "Precise or fuzzy start coordinate position(s), allele locus (0-based, inclusive). * `start` only:\n - for single positions, e.g. the start of a specified sequence\n alteration where the size is given through the specified `alternateBases`\n - typical use are queries for SNV and small InDels\n - the use of `start` without an `end` parameter requires the use of\n `alternateBases`\n* 1 value in both `start` and `end`:\n - for searching any variant falling fully or partially within the range\n between `start` and `end` (a.k.a. \"range query\")\n - additional use of `variantType` OR `alternateBases` can limit the\n scope of the query\n - by convention, partial overlaps of variants with the indicated genomic\n range are accepted; for specific overlap requirements the 4-parameter\n \"Bracket Queries\" should be employed\n* 2 values in both `start` and `end` for constructing a \"Bracket Query\":\n - can be used to match any contiguous genomic interval, e.g. for querying\n imprecise positions\n - identifies all structural variants starting between `start[0]` and `start[1]`,\n and ending between `end[0]` <-> `end[1]`\n - single or double sided precise matches can be achieved by setting\n `start[1]=start[0]+1` and `end[1]=end[0]+1`", "items": { "format": "int64", "minimum": 0, @@ -87,4 +87,4 @@ }, "type": "object" } -} +} \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/genomicVariations/requestParametersComponents.json b/models/json/beacon-v2-default-model/genomicVariations/requestParametersComponents.json index 60ff1da6e..fbe5026cb 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/requestParametersComponents.json +++ b/models/json/beacon-v2-default-model/genomicVariations/requestParametersComponents.json @@ -1,6 +1,5 @@ { - "$schema": "https://json-schema.org/draft/2020-12/schema", - "definitions": { + "$defs": { "AlternateBases": { "description": "Alternate bases for this variant (starting from `start`). * Accepted values: `[ACGTN]*` * The current specification supports allelic variants, **not** genotype queries\n (i.e. multiple co-occurring alleles).\n* N is a wildcard, that denotes the position of any base,\n and can be used as a standalone base of any type or within a partially known\n sequence. As example, a query of `ANNT` the Ns can take take any form of [ACGT]\n and will match `ANNT`, `ACNT`, `ACCT`, `ACGT` ... and so forth.\n* an *empty value* is used in the case of deletions with the maximally trimmed,\n deleted sequence being indicated in `ReferenceBases`\n* Categorical variant queries, e.g. such *not* being represented through\n sequence & position, make use of the `variantType` parameter.", "pattern": "^([ACGTUNRYSWKMBDHV\\-\\.]*)$", @@ -30,5 +29,6 @@ "type": "string" } }, + "$schema": "https://json-schema.org/draft/2020-12/schema", "description": "Component definitions used in `requestParameters`." } \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/individuals/defaultSchema.json b/models/json/beacon-v2-default-model/individuals/defaultSchema.json index 69f989a65..e5b6876a6 100644 --- a/models/json/beacon-v2-default-model/individuals/defaultSchema.json +++ b/models/json/beacon-v2-default-model/individuals/defaultSchema.json @@ -12,7 +12,7 @@ "type": "array" }, "ethnicity": { - "$ref": "../common/commonDefinitions.json#/definitions/Ethnicity", + "$ref": "../common/commonDefinitions.json#/$defs/Ethnicity", "description": "Ethnic background of the individual. Value from NCIT Race (NCIT:C17049) ontology term descendants, e.g. NCIT:C126531 (Latin American). A geographic ancestral origin category that is assigned to a population group based mainly on physical characteristics that are thought to be distinct and inherent. [ NCI ] " }, "exposures": { @@ -22,7 +22,7 @@ "type": "array" }, "geographicOrigin": { - "$ref": "../common/commonDefinitions.json#/definitions/GeographicLocation", + "$ref": "../common/commonDefinitions.json#/$defs/GeographicLocation", "description": "Individual's country or region of origin (birthplace or residence place regardless of ethnic origin). Value from GAZ Geographic Location ontology (GAZ:00000448), e.g. GAZ:00002459 (United States of America)." }, "id": { @@ -31,7 +31,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" }, "interventionsOrProcedures": { "items": { @@ -40,7 +40,7 @@ "type": "array" }, "karyotypicSex": { - "$ref": "../common/commonDefinitions.json#/definitions/KaryotypicSex", + "$ref": "../common/commonDefinitions.json#/$defs/KaryotypicSex", "description": "The chromosomal sex of an individual represented from a selection of options." }, "measures": { @@ -62,7 +62,7 @@ "type": "array" }, "sex": { - "$ref": "../common/commonDefinitions.json#/definitions/Sex", + "$ref": "../common/commonDefinitions.json#/$defs/Sex", "description": "Sex of the individual. Value from NCIT General Qualifier (NCIT:C27993): 'unknown' (not assessed or not available) (NCIT:C17998), 'female' (NCIT:C16576), or 'male', (NCIT:C20197)." }, "treatments": { diff --git a/models/json/beacon-v2-default-model/individuals/endpoints.json b/models/json/beacon-v2-default-model/individuals/endpoints.json index 32898cb17..819709917 100644 --- a/models/json/beacon-v2-default-model/individuals/endpoints.json +++ b/models/json/beacon-v2-default-model/individuals/endpoints.json @@ -25,13 +25,13 @@ } }, "includeResultsetResponses": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses" }, "limit": { "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -48,7 +48,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/models/json/beacon-v2-default-model/runs/defaultSchema.json b/models/json/beacon-v2-default-model/runs/defaultSchema.json index 6e49d8dfb..61d090df2 100644 --- a/models/json/beacon-v2-default-model/runs/defaultSchema.json +++ b/models/json/beacon-v2-default-model/runs/defaultSchema.json @@ -26,7 +26,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" }, "libraryLayout": { "description": "Ontology value for the library layout e.g \"PAIRED\", \"SINGLE\" #todo add Ontology name?", diff --git a/models/json/beacon-v2-default-model/runs/endpoints.json b/models/json/beacon-v2-default-model/runs/endpoints.json index b5084bba7..c76e63cd5 100644 --- a/models/json/beacon-v2-default-model/runs/endpoints.json +++ b/models/json/beacon-v2-default-model/runs/endpoints.json @@ -33,7 +33,7 @@ } }, "includeResultsetResponses": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses" }, "individualId": { "in": "path", @@ -47,7 +47,7 @@ "in": "query", "name": "limit", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit" } }, "requestedSchema": { @@ -64,7 +64,7 @@ "in": "query", "name": "skip", "schema": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip" + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip" } } }, diff --git a/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml b/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml index 8eb87b5be..5c454121a 100644 --- a/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml @@ -51,7 +51,7 @@ properties: examples: - GATK4.0 info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info required: - id - analysisDate diff --git a/models/src/beacon-v2-default-model/analyses/endpoints.yaml b/models/src/beacon-v2-default-model/analyses/endpoints.yaml index 8f5d5457a..251990791 100644 --- a/models/src/beacon-v2-default-model/analyses/endpoints.yaml +++ b/models/src/beacon-v2-default-model/analyses/endpoints.yaml @@ -143,14 +143,14 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit includeResultsetResponses: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses entryId: name: id in: path diff --git a/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml b/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml index 8a9b7eae7..008c4575b 100644 --- a/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml @@ -160,7 +160,7 @@ properties: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/ontologyTerm.json example: {} info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info required: - id - biosampleStatus diff --git a/models/src/beacon-v2-default-model/biosamples/endpoints.yaml b/models/src/beacon-v2-default-model/biosamples/endpoints.yaml index 50b80d8bb..8959192a5 100644 --- a/models/src/beacon-v2-default-model/biosamples/endpoints.yaml +++ b/models/src/beacon-v2-default-model/biosamples/endpoints.yaml @@ -219,14 +219,14 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit includeResultsetResponses: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses entryId: name: id in: path diff --git a/models/src/beacon-v2-default-model/cohorts/defaultSchema.yaml b/models/src/beacon-v2-default-model/cohorts/defaultSchema.yaml index 755184103..314679448 100644 --- a/models/src/beacon-v2-default-model/cohorts/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/cohorts/defaultSchema.yaml @@ -52,13 +52,13 @@ properties: Inclusion criteria used for defining the cohort. It is assumed that all cohort participants will match such criteria. type: object - $ref: '#/definitions/CohortCriteria' + $ref: '#/$defs/CohortCriteria' exclusionCriteria: description: >- Exclusion criteria used for defining the cohort. It is assumed that NONE of the cohort participants will match such criteria. type: object - $ref: '#/definitions/CohortCriteria' + $ref: '#/$defs/CohortCriteria' cohortSize: description: >- Count of unique Individuals in cohort (individuals meeting criteria @@ -69,13 +69,13 @@ properties: - 14765 - 20000 cohortDataTypes: - $ref: '#/definitions/DataTypesArray' + $ref: '#/$defs/DataTypesArray' collectionEvents: description: TBD type: array items: - $ref: '#/definitions/CollectionEvent' -definitions: + $ref: '#/$defs/CollectionEvent' +$defs: CollectionEvent: description: TBD type: object @@ -145,39 +145,39 @@ definitions: description: >- Aggregated information of geographic location obtained from individual level info of the cohort members - $ref: '#/definitions/DataAvailabilityAndDistribution' + $ref: '#/$defs/DataAvailabilityAndDistribution' eventGenders: description: >- Aggregated information of gender(s) obtained from individual level info of the cohort members - $ref: '#/definitions/DataAvailabilityAndDistribution' + $ref: '#/$defs/DataAvailabilityAndDistribution' eventEthnicities: description: >- Aggregated information of ethnicity obtained from individual level info of the cohort members - $ref: '#/definitions/DataAvailabilityAndDistribution' + $ref: '#/$defs/DataAvailabilityAndDistribution' eventAgeRange: description: >- Individual age range, obtained from individual level info of the cohort members - $ref: '#/definitions/DataAvailabilityAndDistribution' + $ref: '#/$defs/DataAvailabilityAndDistribution' eventDiseases: description: >- Aggregated information of disease/condition(s) obtained from individual level info of the cohort members - $ref: '#/definitions/DataAvailabilityAndDistribution' + $ref: '#/$defs/DataAvailabilityAndDistribution' eventPhenotypes: description: >- Aggregated information of phenotype(s) obtained from individual level info of the cohort members - $ref: '#/definitions/DataAvailabilityAndDistribution' + $ref: '#/$defs/DataAvailabilityAndDistribution' eventDataTypes: description: >- Aggregated data type information available for each cohort data type as declared in `cohortDataTypes`, and obtained from individual level info of the cohort members type: object - $ref: '#/definitions/DataAvailabilityAndDistribution' + $ref: '#/$defs/DataAvailabilityAndDistribution' CohortCriteria: description: >- Criteria used for defining the cohort. It is assumed that all cohort @@ -189,19 +189,19 @@ definitions: Geographic location(s) in cohort inclusion criteria type: array items: - $ref: ../common/commonDefinitions.yaml#/definitions/GeographicLocation + $ref: ../common/commonDefinitions.yaml#/$defs/GeographicLocation genders: description: >- Gender(s) in cohort inclusion criteria type: array items: - $ref: ../common/commonDefinitions.yaml#/definitions/Sex + $ref: ../common/commonDefinitions.yaml#/$defs/Sex ethnicities: description: >- Ethnias in cohort inclusion criteria type: array items: - $ref: ../common/commonDefinitions.yaml#/definitions/Ethnicity + $ref: ../common/commonDefinitions.yaml#/$defs/Ethnicity diseaseConditions: description: >- Diseases in cohort inclusion criteria diff --git a/models/src/beacon-v2-default-model/cohorts/endpoints.yaml b/models/src/beacon-v2-default-model/cohorts/endpoints.yaml index 9fd0e999a..ec525f0af 100644 --- a/models/src/beacon-v2-default-model/cohorts/endpoints.yaml +++ b/models/src/beacon-v2-default-model/cohorts/endpoints.yaml @@ -196,12 +196,12 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit entryId: name: id in: path diff --git a/models/src/beacon-v2-default-model/common/commonDefinitions.yaml b/models/src/beacon-v2-default-model/common/commonDefinitions.yaml index 08a7b1756..75d2129f8 100644 --- a/models/src/beacon-v2-default-model/common/commonDefinitions.yaml +++ b/models/src/beacon-v2-default-model/common/commonDefinitions.yaml @@ -2,7 +2,7 @@ $schema: https://json-schema.org/draft/2020-12/schema title: Common Definitions description: Definitions for concepts used in several entry types, but that having only one property are not complex enough to require a full independent schema document. -definitions: +$defs: Sex: description: 'Sex of the individual. Recommended values from NCIT General Qualifier (NCIT:C27993): "unknown" (not assessed or not available) - NCIT:C17998; "female" diff --git a/models/src/beacon-v2-default-model/common/complexValue.yaml b/models/src/beacon-v2-default-model/common/complexValue.yaml index 058a91b9f..c32435cbf 100644 --- a/models/src/beacon-v2-default-model/common/complexValue.yaml +++ b/models/src/beacon-v2-default-model/common/complexValue.yaml @@ -8,11 +8,11 @@ properties: description: List of quantities required to fully describe the complex value type: array items: - $ref: '#/definitions/TypedQuantity' + $ref: '#/$defs/TypedQuantity' required: - typedQuantities -definitions: +$defs: TypedQuantity: properties: quantityType: diff --git a/models/src/beacon-v2-default-model/common/dataUseConditions.yaml b/models/src/beacon-v2-default-model/common/dataUseConditions.yaml index ebb110d79..40bd7d1d2 100644 --- a/models/src/beacon-v2-default-model/common/dataUseConditions.yaml +++ b/models/src/beacon-v2-default-model/common/dataUseConditions.yaml @@ -6,9 +6,9 @@ properties: duoDataUse: type: array items: - $ref: '#/definitions/DUODataUse' + $ref: '#/$defs/DUODataUse' minItems: 1 -definitions: +$defs: DUODataUse: allOf: - description: Data Use Ontology codes and additional information associated diff --git a/models/src/beacon-v2-default-model/common/disease.yaml b/models/src/beacon-v2-default-model/common/disease.yaml index c6472dad6..dac18f852 100644 --- a/models/src/beacon-v2-default-model/common/disease.yaml +++ b/models/src/beacon-v2-default-model/common/disease.yaml @@ -40,7 +40,7 @@ properties: - id: OGMS:0000106 label: remission severity: - $ref: ./commonDefinitions.yaml#/definitions/SeverityLevel + $ref: ./commonDefinitions.yaml#/$defs/SeverityLevel examples: - id: HP:0012828 label: Severe diff --git a/models/src/beacon-v2-default-model/common/exposure.yaml b/models/src/beacon-v2-default-model/common/exposure.yaml index 70fa94cfb..635c87491 100644 --- a/models/src/beacon-v2-default-model/common/exposure.yaml +++ b/models/src/beacon-v2-default-model/common/exposure.yaml @@ -22,7 +22,7 @@ properties: description: >- Unit of the exposure. Recommended from NCIT Unit of Category ontology term (NCIT:C42568) descendants. - $ref: ../common/commonDefinitions.yaml#/definitions/Unit + $ref: ../common/commonDefinitions.yaml#/$defs/Unit duration: description: >- Exposure duration in ISO8601 format diff --git a/models/src/beacon-v2-default-model/common/pedigree.yaml b/models/src/beacon-v2-default-model/common/pedigree.yaml index b4cb0d7d4..67b542a76 100644 --- a/models/src/beacon-v2-default-model/common/pedigree.yaml +++ b/models/src/beacon-v2-default-model/common/pedigree.yaml @@ -21,9 +21,9 @@ properties: than the proband, it only contains two entries: one that describes that member, e.g. the proband mother or father, and one that points to the proband.' items: - $ref: '#/definitions/pedigreeMember' + $ref: '#/$defs/pedigreeMember' minItems: 1 -definitions: +$defs: pedigreeMember: type: object properties: diff --git a/models/src/beacon-v2-default-model/common/phenotypicFeature.yaml b/models/src/beacon-v2-default-model/common/phenotypicFeature.yaml index e73b22f9e..8f28393c4 100644 --- a/models/src/beacon-v2-default-model/common/phenotypicFeature.yaml +++ b/models/src/beacon-v2-default-model/common/phenotypicFeature.yaml @@ -50,7 +50,7 @@ properties: description: The evidence for an assertion of the observation of a type. RECOMMENDED. $ref: ./evidence.yaml severity: - $ref: ./commonDefinitions.yaml#/definitions/SeverityLevel + $ref: ./commonDefinitions.yaml#/$defs/SeverityLevel examples: - id: HP:0012828 label: Severe @@ -61,6 +61,6 @@ properties: feature. type: string example: Some free text -definitions: {} +$defs: {} required: - featureType diff --git a/models/src/beacon-v2-default-model/common/quantity.yaml b/models/src/beacon-v2-default-model/common/quantity.yaml index 5cf191123..56a409f0e 100644 --- a/models/src/beacon-v2-default-model/common/quantity.yaml +++ b/models/src/beacon-v2-default-model/common/quantity.yaml @@ -4,7 +4,7 @@ description: 'Definition of a quantity class. Provenance: GA4GH Phenopackets v2 type: object properties: unit: - $ref: ./commonDefinitions.yaml#/definitions/Unit + $ref: ./commonDefinitions.yaml#/$defs/Unit value: description: The value of the quantity in the units type: number diff --git a/models/src/beacon-v2-default-model/common/referenceRange.yaml b/models/src/beacon-v2-default-model/common/referenceRange.yaml index a6316d379..8e882e44f 100644 --- a/models/src/beacon-v2-default-model/common/referenceRange.yaml +++ b/models/src/beacon-v2-default-model/common/referenceRange.yaml @@ -5,7 +5,7 @@ type: object properties: unit: description: The kind of unit. - $ref: ./commonDefinitions.yaml#/definitions/Unit + $ref: ./commonDefinitions.yaml#/$defs/Unit examples: - id: NCIT:C49670 label: Millimeter of Mercury diff --git a/models/src/beacon-v2-default-model/common/timeElement.yaml b/models/src/beacon-v2-default-model/common/timeElement.yaml index 2c09a3468..febb4fd38 100644 --- a/models/src/beacon-v2-default-model/common/timeElement.yaml +++ b/models/src/beacon-v2-default-model/common/timeElement.yaml @@ -9,6 +9,6 @@ oneOf: - $ref: ./age.yaml - $ref: ./ageRange.yaml - $ref: ./gestationalAge.yaml - - $ref: ./commonDefinitions.yaml#/definitions/Timestamp + - $ref: ./commonDefinitions.yaml#/$defs/Timestamp - $ref: ./timeInterval.yaml - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/ontologyTerm.json diff --git a/models/src/beacon-v2-default-model/common/timeInterval.yaml b/models/src/beacon-v2-default-model/common/timeInterval.yaml index 023953e46..1c9ac2ed6 100644 --- a/models/src/beacon-v2-default-model/common/timeInterval.yaml +++ b/models/src/beacon-v2-default-model/common/timeInterval.yaml @@ -5,12 +5,12 @@ type: object $comments: From https://github.com/phenopackets/phenopacket-schema/blob/v2/docs/time-interval.rst properties: start: - $ref: ./commonDefinitions.yaml#/definitions/Timestamp + $ref: ./commonDefinitions.yaml#/$defs/Timestamp examples: - '1999-08-05T17:21:00+01:00' - '2002-09-21T02:37:00-08:00' end: - $ref: ./commonDefinitions.yaml#/definitions/Timestamp + $ref: ./commonDefinitions.yaml#/$defs/Timestamp examples: - '2022-03-10T15:25:07Z' required: diff --git a/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml b/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml index d9f8cbe30..7741c5707 100644 --- a/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml @@ -19,12 +19,12 @@ properties: examples: - This dataset provides examples of the actual data in this Beacon instance. createDateTime: - $ref: ../common/commonDefinitions.yaml#/definitions/Timestamp + $ref: ../common/commonDefinitions.yaml#/$defs/Timestamp description: The time the dataset was created (ISO 8601 format) examples: - '2017-01-17T20:33:40Z' updateDateTime: - $ref: ../common/commonDefinitions.yaml#/definitions/Timestamp + $ref: ../common/commonDefinitions.yaml#/$defs/Timestamp description: The time the dataset was updated in (ISO 8601 format) examples: - '2017-01-17T20:33:40Z' @@ -40,7 +40,7 @@ properties: examples: - https://example.org/wiki/Main_Page info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info dataUseConditions: description: Data use conditions applying to this dataset. $ref: ../common/dataUseConditions.yaml diff --git a/models/src/beacon-v2-default-model/datasets/endpoints.yaml b/models/src/beacon-v2-default-model/datasets/endpoints.yaml index dc2c34d31..cf1d47fdd 100644 --- a/models/src/beacon-v2-default-model/datasets/endpoints.yaml +++ b/models/src/beacon-v2-default-model/datasets/endpoints.yaml @@ -270,12 +270,12 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit entryId: name: id in: path diff --git a/models/src/beacon-v2-default-model/endpoints.yaml b/models/src/beacon-v2-default-model/endpoints.yaml index a8b5716f0..3b744b30e 100644 --- a/models/src/beacon-v2-default-model/endpoints.yaml +++ b/models/src/beacon-v2-default-model/endpoints.yaml @@ -143,9 +143,9 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit diff --git a/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml b/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml index 7011dd6a7..96c3dbff7 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml @@ -12,7 +12,7 @@ properties: oneOf: - $ref: https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/MolecularVariation - $ref: https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/SystemicVariation - - $ref: '#/definitions/LegacyVariation' + - $ref: '#/$defs/LegacyVariation' variantInternalId: description: >- Reference to the **internal** variant ID. This represents the primary @@ -27,22 +27,22 @@ properties: - var00001 - v110112 identifiers: - $ref: '#/definitions/Identifiers' + $ref: '#/$defs/Identifiers' molecularAttributes: - $ref: '#/definitions/MolecularAttributes' + $ref: '#/$defs/MolecularAttributes' caseLevelData: type: array description: caseLevelData reports about the variation instances observed in individual analyses. items: - $ref: '#/definitions/CaseLevelVariant' + $ref: '#/$defs/CaseLevelVariant' variantLevelData: - $ref: '#/definitions/VariantLevelData' + $ref: '#/$defs/VariantLevelData' frequencyInPopulations: type: array items: - $ref: '#/definitions/FrequencyInPopulations' -definitions: + $ref: '#/$defs/FrequencyInPopulations' +$defs: LegacyVariation: type: object required: @@ -168,7 +168,7 @@ definitions: description: List of Genomic feature(s) affected by the variant. type: array items: - $ref: '#/definitions/GenomicFeature' + $ref: '#/$defs/GenomicFeature' molecularEffects: description: >- Ontology term that includes describes the class of molecular @@ -270,7 +270,7 @@ definitions: - id: ECO:0000006 label: experimental evidence annotatedWith: - $ref: '#/definitions/SoftwareTool' + $ref: '#/$defs/SoftwareTool' required: - conditionId - effect @@ -297,7 +297,7 @@ definitions: frequencies: type: array items: - $ref: '#/definitions/PopulationFrequency' + $ref: '#/$defs/PopulationFrequency' minItems: 1 required: - source @@ -394,11 +394,11 @@ definitions: clinicalInterpretations: type: array items: - $ref: '#/definitions/PhenoClinicEffect' + $ref: '#/$defs/PhenoClinicEffect' phenotypicEffects: type: array items: - $ref: '#/definitions/PhenoClinicEffect' + $ref: '#/$defs/PhenoClinicEffect' required: - biosampleId VariantLevelData: @@ -407,11 +407,11 @@ definitions: clinicalInterpretations: type: array items: - $ref: '#/definitions/PhenoClinicEffect' + $ref: '#/$defs/PhenoClinicEffect' phenotypicEffects: type: array items: - $ref: '#/definitions/PhenoClinicEffect' + $ref: '#/$defs/PhenoClinicEffect' SoftwareTool: type: object properties: diff --git a/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml b/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml index 44b59a736..4c9bbdae6 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/endpoints.yaml @@ -187,14 +187,14 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit includeResultsetResponses: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses entryId: name: id in: path diff --git a/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml b/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml index 112bdb2ab..166bccf12 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/requestParameters.yaml @@ -3,9 +3,9 @@ g_variant: type: object properties: assemblyId: - $ref: ./requestParametersComponents.yaml#/definitions/Assembly + $ref: ./requestParametersComponents.yaml#/$defs/Assembly referenceName: - $ref: ./requestParametersComponents.yaml#/definitions/RefSeqId + $ref: ./requestParametersComponents.yaml#/$defs/RefSeqId start: description: >- Precise or fuzzy start coordinate position(s), allele locus @@ -51,9 +51,9 @@ g_variant: minItems: 1 maxItems: 2 referenceBases: - $ref: ./requestParametersComponents.yaml#/definitions/ReferenceBases + $ref: ./requestParametersComponents.yaml#/$defs/ReferenceBases alternateBases: - $ref: ./requestParametersComponents.yaml#/definitions/AlternateBases + $ref: ./requestParametersComponents.yaml#/$defs/AlternateBases variantType: description: >- The `variantType` is used to query variants which are not defined through @@ -98,7 +98,7 @@ g_variant: format: int64 minimum: 1 mateName: - $ref: ./requestParametersComponents.yaml#/definitions/RefSeqId + $ref: ./requestParametersComponents.yaml#/$defs/RefSeqId geneId: description: >- * A gene identifier diff --git a/models/src/beacon-v2-default-model/genomicVariations/requestParametersComponents.yaml b/models/src/beacon-v2-default-model/genomicVariations/requestParametersComponents.yaml index 82f13b863..af503ad40 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/requestParametersComponents.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/requestParametersComponents.yaml @@ -1,7 +1,7 @@ $schema: https://json-schema.org/draft/2020-12/schema description: >- Component definitions used in `requestParameters`. -definitions: +$defs: Assembly: description: >- Genomic assembly accession and version as RefSqeq assembly accession diff --git a/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml b/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml index 50dcd46e2..adc28d3e3 100644 --- a/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml @@ -12,23 +12,23 @@ properties: description: "Sex of the individual. Value from NCIT General Qualifier (NCIT:C27993):\ \ 'unknown' (not assessed or not available) (NCIT:C17998), 'female' (NCIT:C16576),\ \ or 'male', (NCIT:C20197)." - $ref: ../common/commonDefinitions.yaml#/definitions/Sex + $ref: ../common/commonDefinitions.yaml#/$defs/Sex karyotypicSex: description: The chromosomal sex of an individual represented from a selection of options. - $ref: ../common/commonDefinitions.yaml#/definitions/KaryotypicSex + $ref: ../common/commonDefinitions.yaml#/$defs/KaryotypicSex ethnicity: description: 'Ethnic background of the individual. Value from NCIT Race (NCIT:C17049) ontology term descendants, e.g. NCIT:C126531 (Latin American). A geographic ancestral origin category that is assigned to a population group based mainly on physical characteristics that are thought to be distinct and inherent. [ NCI ] ' - $ref: ../common/commonDefinitions.yaml#/definitions/Ethnicity + $ref: ../common/commonDefinitions.yaml#/$defs/Ethnicity geographicOrigin: description: Individual's country or region of origin (birthplace or residence place regardless of ethnic origin). Value from GAZ Geographic Location ontology (GAZ:00000448), e.g. GAZ:00002459 (United States of America). - $ref: ../common/commonDefinitions.yaml#/definitions/GeographicLocation + $ref: ../common/commonDefinitions.yaml#/$defs/GeographicLocation diseases: description: List of disease(s) been diagnosed to the individual, defined by disease ontology ID(s), age of onset, stage and the presence of family history. @@ -60,7 +60,7 @@ properties: items: $ref: ../common/exposure.yaml info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info required: - id - sex diff --git a/models/src/beacon-v2-default-model/individuals/endpoints.yaml b/models/src/beacon-v2-default-model/individuals/endpoints.yaml index 7ed5a46fe..b220dd86c 100644 --- a/models/src/beacon-v2-default-model/individuals/endpoints.yaml +++ b/models/src/beacon-v2-default-model/individuals/endpoints.yaml @@ -214,14 +214,14 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit includeResultsetResponses: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses entryId: name: id in: path diff --git a/models/src/beacon-v2-default-model/runs/defaultSchema.yaml b/models/src/beacon-v2-default-model/runs/defaultSchema.yaml index ac04dda4b..1ba08836f 100644 --- a/models/src/beacon-v2-default-model/runs/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/runs/defaultSchema.yaml @@ -74,7 +74,7 @@ properties: - id: EFO:0010938 label: large-insert clone DNA microarray info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Info + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info required: - id - biosampleId diff --git a/models/src/beacon-v2-default-model/runs/endpoints.yaml b/models/src/beacon-v2-default-model/runs/endpoints.yaml index 473bea53c..1b3606410 100644 --- a/models/src/beacon-v2-default-model/runs/endpoints.yaml +++ b/models/src/beacon-v2-default-model/runs/endpoints.yaml @@ -175,14 +175,14 @@ components: name: skip in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Skip + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Skip limit: name: limit in: query schema: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/Limit + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Limit includeResultsetResponses: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/definitions/IncludeResultsetResponses + $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/IncludeResultsetResponses entryId: name: id in: path From 748988278dab399184d657c4a092ae429beac1b4 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Mon, 23 Sep 2024 16:25:40 +0200 Subject: [PATCH 24/37] remove conflicting specifications in filteringTerms This addresses https://github.com/ga4gh-beacon/beacon-v2/issues/159 - see comments there. --- .../cohorts/filteringTerms.json | 9 +-------- .../datasets/filteringTerms.json | 9 +-------- .../genomicVariations/filteringTerms.json | 11 +---------- .../cohorts/filteringTerms.yaml | 6 +----- .../datasets/filteringTerms.yaml | 6 +----- .../genomicVariations/filteringTerms.yaml | 6 +----- 6 files changed, 6 insertions(+), 41 deletions(-) diff --git a/models/json/beacon-v2-default-model/cohorts/filteringTerms.json b/models/json/beacon-v2-default-model/cohorts/filteringTerms.json index d53359eb0..9cd753def 100644 --- a/models/json/beacon-v2-default-model/cohorts/filteringTerms.json +++ b/models/json/beacon-v2-default-model/cohorts/filteringTerms.json @@ -1,11 +1,4 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", - "filteringTerms": [ - { - "ftType": "ontologyTerm", - "id": "DUO:0000006", - "label": "health or medical or biomedical research", - "version": "2021-02-23" - } - ] + "filteringTerms": [] } \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/datasets/filteringTerms.json b/models/json/beacon-v2-default-model/datasets/filteringTerms.json index d53359eb0..9cd753def 100644 --- a/models/json/beacon-v2-default-model/datasets/filteringTerms.json +++ b/models/json/beacon-v2-default-model/datasets/filteringTerms.json @@ -1,11 +1,4 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", - "filteringTerms": [ - { - "ftType": "ontologyTerm", - "id": "DUO:0000006", - "label": "health or medical or biomedical research", - "version": "2021-02-23" - } - ] + "filteringTerms": [] } \ No newline at end of file diff --git a/models/json/beacon-v2-default-model/genomicVariations/filteringTerms.json b/models/json/beacon-v2-default-model/genomicVariations/filteringTerms.json index 3241f2272..9cd753def 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/filteringTerms.json +++ b/models/json/beacon-v2-default-model/genomicVariations/filteringTerms.json @@ -1,13 +1,4 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", - "filteringTerms": [ - { - "ftType": "alphanumeric", - "id": "gene" - }, - { - "ftType": "alphanumeric", - "id": "aminoacidChanges" - } - ] + "filteringTerms": [] } \ No newline at end of file diff --git a/models/src/beacon-v2-default-model/cohorts/filteringTerms.yaml b/models/src/beacon-v2-default-model/cohorts/filteringTerms.yaml index 92b6ef659..42a7c53bb 100644 --- a/models/src/beacon-v2-default-model/cohorts/filteringTerms.yaml +++ b/models/src/beacon-v2-default-model/cohorts/filteringTerms.yaml @@ -1,6 +1,2 @@ $schema: https://json-schema.org/draft/2020-12/schema -filteringTerms: - - ftType: ontologyTerm - id: DUO:0000006 - label: health or medical or biomedical research - version: '2021-02-23' +filteringTerms: [] \ No newline at end of file diff --git a/models/src/beacon-v2-default-model/datasets/filteringTerms.yaml b/models/src/beacon-v2-default-model/datasets/filteringTerms.yaml index 92b6ef659..42a7c53bb 100644 --- a/models/src/beacon-v2-default-model/datasets/filteringTerms.yaml +++ b/models/src/beacon-v2-default-model/datasets/filteringTerms.yaml @@ -1,6 +1,2 @@ $schema: https://json-schema.org/draft/2020-12/schema -filteringTerms: - - ftType: ontologyTerm - id: DUO:0000006 - label: health or medical or biomedical research - version: '2021-02-23' +filteringTerms: [] \ No newline at end of file diff --git a/models/src/beacon-v2-default-model/genomicVariations/filteringTerms.yaml b/models/src/beacon-v2-default-model/genomicVariations/filteringTerms.yaml index ca25a1cd9..42a7c53bb 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/filteringTerms.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/filteringTerms.yaml @@ -1,6 +1,2 @@ $schema: https://json-schema.org/draft/2020-12/schema -filteringTerms: - - ftType: alphanumeric - id: gene - - ftType: alphanumeric - id: aminoacidChanges +filteringTerms: [] \ No newline at end of file From f05d7e7397cf3f49b094b98e370eada33db54401 Mon Sep 17 00:00:00 2001 From: costero-e Date: Tue, 8 Oct 2024 13:18:22 +0200 Subject: [PATCH 25/37] changelog updated with 2.1.1 --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 48e72a7cd..b52bd0b92 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,13 @@ There is a set of tools in [`/bin`](./bin/) to facilitate the conversion. ATM, a ### Changelog +## 2.1.1 + +*Released, October, 8, 2024* + +* Changed uri for uri-template in Endpoint.singleEntryUrl + + ## 2.1.0 *Released, July, 19, 2024* From 6044850bc1ee15e387d1646112299e2ebd132e89 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 9 Nov 2024 16:48:24 +0900 Subject: [PATCH 26/37] type => set type in example This fixes a well hidden example. Thanks to @Deepthi-v-s for #177 --- .../examples-sections/beaconResultsets-MAX-example.json | 2 +- .../examples-sections/beaconResultsets-MAX-example.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/json/responses/examples-sections/beaconResultsets-MAX-example.json b/framework/json/responses/examples-sections/beaconResultsets-MAX-example.json index 1406dc8f6..8ec48fb86 100644 --- a/framework/json/responses/examples-sections/beaconResultsets-MAX-example.json +++ b/framework/json/responses/examples-sections/beaconResultsets-MAX-example.json @@ -30,7 +30,7 @@ "url": "https://api.mygenomeservice.org/Handover/9dcc48d7-fc88-11e8-9110-b0c592dbf8c0" } ], - "type": "dataset" + "setType": "dataset" } ] } \ No newline at end of file diff --git a/framework/src/responses/examples-sections/beaconResultsets-MAX-example.yaml b/framework/src/responses/examples-sections/beaconResultsets-MAX-example.yaml index f2ae4015b..d7f5a0c80 100644 --- a/framework/src/responses/examples-sections/beaconResultsets-MAX-example.yaml +++ b/framework/src/responses/examples-sections/beaconResultsets-MAX-example.yaml @@ -4,7 +4,7 @@ resultSets: type: dataset exists: false - id: datasetB - type: dataset + setType: dataset exists: true resultsCount: 2 resultsHandovers: From 98b899c3400d475c020a1adad24d7be122f1afe4 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Mon, 11 Nov 2024 12:49:21 +0900 Subject: [PATCH 27/37] re-writing of some inline schema descriptions This commit re-writes some of the root descriptions of the response type schemas (mostly) into slightly more verbose and formatted texts. Besides the "documentation is good" paradigm one reason is the intended use of these for generating documentation pages - see the (under construction) rendering at https://bycon.progenetix.org/generated/beacon-responses/ --- .../beaconConfigurationSchema.yaml | 17 +++++++++++------ .../configuration/entryTypeDefinition.yaml | 19 +++++++++++-------- .../src/responses/beaconBooleanResponse.yaml | 7 +++++-- .../responses/beaconCollectionsResponse.yaml | 6 +++++- .../beaconConfigurationResponse.yaml | 6 ++++-- .../src/responses/beaconCountResponse.yaml | 8 ++++++-- .../responses/beaconEntryTypesResponse.yaml | 4 +++- .../src/responses/beaconErrorResponse.yaml | 3 ++- .../src/responses/beaconInfoResponse.yaml | 10 ++++++++-- .../src/responses/beaconMapResponse.yaml | 6 ++++-- .../responses/beaconResultsetsResponse.yaml | 12 +++++++++++- 11 files changed, 70 insertions(+), 28 deletions(-) diff --git a/framework/src/configuration/beaconConfigurationSchema.yaml b/framework/src/configuration/beaconConfigurationSchema.yaml index bcd6a64e4..6eaef9f28 100644 --- a/framework/src/configuration/beaconConfigurationSchema.yaml +++ b/framework/src/configuration/beaconConfigurationSchema.yaml @@ -1,7 +1,9 @@ $schema: https://json-schema.org/draft/2020-12/schema title: Beacon Configuration -description: Files complaint with this schema are the configuration ones. The details - returned in `service-info` are mirroring the ones in this configuration file. +description: >- + The Beacon configuration reports several attributes of the beacon instance related + to security, maturity and available entry types. + Where appropriate the details returned in `service-info` should mirror the ones in this configuration. type: object properties: $schema: @@ -11,16 +13,19 @@ properties: type: object properties: productionStatus: - description: "`DEV`= 'Service potentially unstable, not real data', which\ - \ availability and data should not be used in production setups. `TEST`=\ - \ 'Service stable, not real data'. 'PROD'= 'Service stable, actual data'." + description: >- + * `DEV`: Service potentially unstable, _i.e._ potentially not real data, + inconsistent availability; data should not be used in production setups + * `TEST`: Service is stable but data should be considered synthetic + * `PROD`: Service stable with real world data type: string enum: - DEV - TEST - PROD securityAttributes: - description: Configuration of the security aspects of the Beacon. By default, + description: >- + Configuration of the security aspects of the Beacon. By default, a Beacon that does not declare the configuration settings would return `boolean` (true/false) responses, and only if the user is authenticated and explicitly authorized to access the Beacon resources. Although this is the safest set of diff --git a/framework/src/configuration/entryTypeDefinition.yaml b/framework/src/configuration/entryTypeDefinition.yaml index 8f6fe509f..ae7af9215 100644 --- a/framework/src/configuration/entryTypeDefinition.yaml +++ b/framework/src/configuration/entryTypeDefinition.yaml @@ -1,14 +1,17 @@ $schema: https://json-schema.org/draft/2020-12/schema title: '' -description: "Definition of an element or entry type including the Beacon v2 required\ - \ and suggested attributes. This schema purpose is to describe each type of entities\ - \ included in a Beacon, hence Beacon clients could have some metadata about such\ - \ entities.\n\nThe `id` attribute is the key that should be used in other parts\ - \ of the Beacon Model to allow Beacon clients to identify the different parts (e.g.\ - \ endpoints, filteringTerms, request parameters, etc.) that fully describe an entry\ - \ type." +description: >- + Definition of an element or entry type including the Beacon v2 required + and suggested attributes. This schema purpose is to describe each type of entities + included in a Beacon, hence Beacon clients could have some metadata about such + entities. + + The `id` attribute is the key that should be used in other parts of the Beacon + Model to allow Beacon clients to identify the different parts (e.g. endpoints, + filteringTerms, request parameters, etc.) that fully describe an entry type. type: object -$comment: 'TO DO: The tagged parts should reference to `common/ontologizedElement.json`. +$comment: >- + TODO: The tagged parts should reference to `common/ontologizedElement.json`. But that configuration fails to validate. Further investigation is required, but should not affect the resulting schema.' properties: diff --git a/framework/src/responses/beaconBooleanResponse.yaml b/framework/src/responses/beaconBooleanResponse.yaml index 97811e09c..0cf7ac716 100644 --- a/framework/src/responses/beaconBooleanResponse.yaml +++ b/framework/src/responses/beaconBooleanResponse.yaml @@ -1,7 +1,10 @@ $schema: https://json-schema.org/draft/2020-12/schema description: >- - Complete definition for a minimal response that provides *only* a `Boolean` - exists true|false answer. + Complete definition for a minimal response that provides *only* an aggregate + Boolean `"exists": true` or `"exists": false` answer to the query. + + Additional information - which should not consist of record-level information - + can be provided through `beaconHandovers`. type: object properties: meta: diff --git a/framework/src/responses/beaconCollectionsResponse.yaml b/framework/src/responses/beaconCollectionsResponse.yaml index 8b895ce6f..948fd2931 100644 --- a/framework/src/responses/beaconCollectionsResponse.yaml +++ b/framework/src/responses/beaconCollectionsResponse.yaml @@ -1,5 +1,9 @@ $schema: https://json-schema.org/draft/2020-12/schema -description: Beacon response that includes details about the collections in this Beacon. +description: >- + A type of Beacon response that includes details about the **collections** in a + beacon. The types of collections are defined in each beacon's configuration; + if using the Beacon v2+ default model usually the types `dataset` and `cohort` + are supported. type: object properties: meta: diff --git a/framework/src/responses/beaconConfigurationResponse.yaml b/framework/src/responses/beaconConfigurationResponse.yaml index 28d38626d..f4ee49954 100644 --- a/framework/src/responses/beaconConfigurationResponse.yaml +++ b/framework/src/responses/beaconConfigurationResponse.yaml @@ -1,8 +1,10 @@ $schema: https://json-schema.org/draft/2020-12/schema type: object description: >- - Information about the Beacon. Aimed to Beacon clients like web pages - or Beacon networks. + The `beaconConfigurationResponse` returns information about configuration + parameters of a given beacon instance such as maturity or security attributes + or supported entry types. It is directed towards Beacon clients like web pages + or network aggregators. properties: meta: description: >- diff --git a/framework/src/responses/beaconCountResponse.yaml b/framework/src/responses/beaconCountResponse.yaml index f083849bd..f4c854fc6 100644 --- a/framework/src/responses/beaconCountResponse.yaml +++ b/framework/src/responses/beaconCountResponse.yaml @@ -1,7 +1,11 @@ $schema: https://json-schema.org/draft/2020-12/schema description: >- - Complete definition for a response that does not include record level - details but provides `Boolean` and `count` information. + Complete definition for a minimal response that provides an aggregate Boolean + `"exists": true` or `"exists": false` answer to the query as well as the count + of the matched records. + + Additional information - which should not consist of record-level information - + can be provided through `beaconHandovers`. type: object properties: meta: diff --git a/framework/src/responses/beaconEntryTypesResponse.yaml b/framework/src/responses/beaconEntryTypesResponse.yaml index 16e5aef37..2919bf009 100644 --- a/framework/src/responses/beaconEntryTypesResponse.yaml +++ b/framework/src/responses/beaconEntryTypesResponse.yaml @@ -1,7 +1,9 @@ $schema: https://json-schema.org/draft/2020-12/schema type: object description: >- - Response including a list of Entry types definitions. + The `beaconEntryTypesResponse` provides information about the entry types + served through a beacon, including their definitions and pointers to their + schemas. properties: meta: description: >- diff --git a/framework/src/responses/beaconErrorResponse.yaml b/framework/src/responses/beaconErrorResponse.yaml index e902a32fa..eb1669d3a 100644 --- a/framework/src/responses/beaconErrorResponse.yaml +++ b/framework/src/responses/beaconErrorResponse.yaml @@ -1,7 +1,8 @@ $schema: https://json-schema.org/draft/2020-12/schema type: object description: >- - An unsuccessful operation. + A `beaconErrorResponse` denotes an unsuccessful operation, e.g. due to a missing + parameter or an invalid query. The response contains an error object. properties: meta: $ref: ./sections/beaconResponseMeta.yaml diff --git a/framework/src/responses/beaconInfoResponse.yaml b/framework/src/responses/beaconInfoResponse.yaml index 720015f8f..011610860 100644 --- a/framework/src/responses/beaconInfoResponse.yaml +++ b/framework/src/responses/beaconInfoResponse.yaml @@ -1,8 +1,14 @@ $schema: https://json-schema.org/draft/2020-12/schema type: object description: >- - Information about the Beacon. Aimed at Beacon clients like web pages - or Beacon networks. + The `beaconInfoResponse` provides metadata describing a Beacon instance, such + as its name, the organization responsible for the Beacon, contact information, + site logo and alternative URLs and importantly the beacon's API version. It is + based on the GA4GH `service-info` standard. + + The content of the `beaconInfoResponse` can be used by clients such as web front + ends or beacon aggregators to evaluate potential access patterns and to display + information about the beacon. properties: meta: description: >- diff --git a/framework/src/responses/beaconMapResponse.yaml b/framework/src/responses/beaconMapResponse.yaml index 08a70e0ad..c230024bb 100644 --- a/framework/src/responses/beaconMapResponse.yaml +++ b/framework/src/responses/beaconMapResponse.yaml @@ -1,8 +1,10 @@ $schema: https://json-schema.org/draft/2020-12/schema type: object description: >- - Information about the Beacon. Aimed to Beacon clients like web pages - or Beacon networks. + A `beaconMapResponse` provides information about the beacon instance such as the + different endpoints supported by this implementation of the Beacon API. This response + is aimed to allow Beacon clients such as web front ends and Beacon network aggregators + to evaluate which access patterns can be implemented against individual beacons. properties: meta: description: >- diff --git a/framework/src/responses/beaconResultsetsResponse.yaml b/framework/src/responses/beaconResultsetsResponse.yaml index 11e8b732c..b1c54d52c 100644 --- a/framework/src/responses/beaconResultsetsResponse.yaml +++ b/framework/src/responses/beaconResultsetsResponse.yaml @@ -1,5 +1,15 @@ $schema: https://json-schema.org/draft/2020-12/schema -description: Beacon response that includes record level details, grouped in Resultsets. +description: >- + A `beaconResultsetsResponse` returns the results of a query against a beacon + or beacon aggregator. Beyond the `responseSummary` for overall matches the + response contains details about the matches in individual **collections** in + the beacon or beacon network. This type of response is required when serving + a request with a "record" level `responseGranularity`, and `beaconResultsets` + typically contain a list of records matched by the query. + + The types of `beaconResultsets` objects are defined in the beacon's configuration; + e.g. if using the Beacon v2+ default model the types `dataset` and `cohort` are + supported as result sets. type: object properties: meta: From cd1d46028ed237bc159dc2bf0935da3d73e981e1 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Mon, 11 Nov 2024 19:41:40 +0900 Subject: [PATCH 28/37] JSON versions of last commit --- framework/json/configuration/beaconConfigurationSchema.json | 4 ++-- framework/json/configuration/entryTypeDefinition.json | 4 ++-- framework/json/responses/beaconBooleanResponse.json | 2 +- framework/json/responses/beaconCollectionsResponse.json | 2 +- framework/json/responses/beaconConfigurationResponse.json | 2 +- framework/json/responses/beaconCountResponse.json | 2 +- framework/json/responses/beaconEntryTypesResponse.json | 2 +- framework/json/responses/beaconErrorResponse.json | 2 +- framework/json/responses/beaconInfoResponse.json | 2 +- framework/json/responses/beaconMapResponse.json | 2 +- framework/json/responses/beaconResultsetsResponse.json | 2 +- 11 files changed, 13 insertions(+), 13 deletions(-) diff --git a/framework/json/configuration/beaconConfigurationSchema.json b/framework/json/configuration/beaconConfigurationSchema.json index 7b3b448ec..20c2e0556 100644 --- a/framework/json/configuration/beaconConfigurationSchema.json +++ b/framework/json/configuration/beaconConfigurationSchema.json @@ -12,7 +12,7 @@ }, "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Files complaint with this schema are the configuration ones. The details returned in `service-info` are mirroring the ones in this configuration file.", + "description": "The Beacon configuration reports several attributes of the beacon instance related to security, maturity and available entry types. Where appropriate the details returned in `service-info` should mirror the ones in this configuration.", "properties": { "$schema": { "$ref": "../common/beaconCommonComponents.json#/$defs/$schema" @@ -24,7 +24,7 @@ "description": "Declares the level of maturity of the Beacon instance.", "properties": { "productionStatus": { - "description": "`DEV`= 'Service potentially unstable, not real data', which availability and data should not be used in production setups. `TEST`= 'Service stable, not real data'. 'PROD'= 'Service stable, actual data'.", + "description": "* `DEV`: Service potentially unstable, _i.e._ potentially not real data,\n inconsistent availability; data should not be used in production setups \n* `TEST`: Service is stable but data should be considered synthetic * `PROD`: Service stable with real world data ", "enum": [ "DEV", "TEST", diff --git a/framework/json/configuration/entryTypeDefinition.json b/framework/json/configuration/entryTypeDefinition.json index ff8824678..cf9013827 100644 --- a/framework/json/configuration/entryTypeDefinition.json +++ b/framework/json/configuration/entryTypeDefinition.json @@ -1,8 +1,8 @@ { - "$comment": "TO DO: The tagged parts should reference to `common/ontologizedElement.json`. But that configuration fails to validate. Further investigation is required, but should not affect the resulting schema.", + "$comment": "TODO: The tagged parts should reference to `common/ontologizedElement.json`. But that configuration fails to validate. Further investigation is required, but should not affect the resulting schema.'", "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Definition of an element or entry type including the Beacon v2 required and suggested attributes. This schema purpose is to describe each type of entities included in a Beacon, hence Beacon clients could have some metadata about such entities.\n\nThe `id` attribute is the key that should be used in other parts of the Beacon Model to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, request parameters, etc.) that fully describe an entry type.", + "description": "Definition of an element or entry type including the Beacon v2 required and suggested attributes. This schema purpose is to describe each type of entities included in a Beacon, hence Beacon clients could have some metadata about such entities. \nThe `id` attribute is the key that should be used in other parts of the Beacon Model to allow Beacon clients to identify the different parts (e.g. endpoints, filteringTerms, request parameters, etc.) that fully describe an entry type.", "properties": { "$schema": { "$ref": "../common/beaconCommonComponents.json#/$defs/$schema" diff --git a/framework/json/responses/beaconBooleanResponse.json b/framework/json/responses/beaconBooleanResponse.json index 8491ca4bd..5f1a24f46 100644 --- a/framework/json/responses/beaconBooleanResponse.json +++ b/framework/json/responses/beaconBooleanResponse.json @@ -1,6 +1,6 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", - "description": "Complete definition for a minimal response that provides *only* a `Boolean` exists true|false answer.", + "description": "Complete definition for a minimal response that provides *only* an aggregate Boolean `\"exists\": true` or `\"exists\": false` answer to the query. \nAdditional information - which should not consist of record-level information - can be provided through `beaconHandovers`. ", "properties": { "beaconHandovers": { "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", diff --git a/framework/json/responses/beaconCollectionsResponse.json b/framework/json/responses/beaconCollectionsResponse.json index 6728e3342..afc01ea1d 100644 --- a/framework/json/responses/beaconCollectionsResponse.json +++ b/framework/json/responses/beaconCollectionsResponse.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Beacon response that includes details about the collections in this Beacon.", + "description": "A type of Beacon response that includes details about the **collections** in a beacon. The types of collections are defined in each beacon's configuration; if using the Beacon v2+ default model usually the types `dataset` and `cohort` are supported.", "properties": { "beaconHandovers": { "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", diff --git a/framework/json/responses/beaconConfigurationResponse.json b/framework/json/responses/beaconConfigurationResponse.json index ccd15687e..3551db860 100644 --- a/framework/json/responses/beaconConfigurationResponse.json +++ b/framework/json/responses/beaconConfigurationResponse.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Information about the Beacon. Aimed to Beacon clients like web pages or Beacon networks.", + "description": "The `beaconConfigurationResponse` returns information about configuration parameters of a given beacon instance such as maturity or security attributes or supported entry types. It is directed towards Beacon clients like web pages or network aggregators.", "properties": { "meta": { "$ref": "./sections/beaconInformationalResponseMeta.json", diff --git a/framework/json/responses/beaconCountResponse.json b/framework/json/responses/beaconCountResponse.json index 9222ae90d..769f90894 100644 --- a/framework/json/responses/beaconCountResponse.json +++ b/framework/json/responses/beaconCountResponse.json @@ -1,6 +1,6 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", - "description": "Complete definition for a response that does not include record level details but provides `Boolean` and `count` information.", + "description": "Complete definition for a minimal response that provides an aggregate Boolean `\"exists\": true` or `\"exists\": false` answer to the query as well as the count of the matched records.\nAdditional information - which should not consist of record-level information - can be provided through `beaconHandovers`. ", "properties": { "beaconHandovers": { "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", diff --git a/framework/json/responses/beaconEntryTypesResponse.json b/framework/json/responses/beaconEntryTypesResponse.json index 2c2cc5514..d18fa8137 100644 --- a/framework/json/responses/beaconEntryTypesResponse.json +++ b/framework/json/responses/beaconEntryTypesResponse.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Response including a list of Entry types definitions.", + "description": "The `beaconEntryTypesResponse` provides information about the entry types served through a beacon, including their definitions and pointers to their schemas.", "properties": { "meta": { "$ref": "./sections/beaconInformationalResponseMeta.json", diff --git a/framework/json/responses/beaconErrorResponse.json b/framework/json/responses/beaconErrorResponse.json index db7b0c0f0..3f01c1a16 100644 --- a/framework/json/responses/beaconErrorResponse.json +++ b/framework/json/responses/beaconErrorResponse.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "An unsuccessful operation.", + "description": "A `beaconErrorResponse` denotes an unsuccessful operation, e.g. due to a missing parameter or an invalid query. The response contains an error object.", "properties": { "error": { "$ref": "../common/beaconCommonComponents.json#/$defs/BeaconError" diff --git a/framework/json/responses/beaconInfoResponse.json b/framework/json/responses/beaconInfoResponse.json index a221e746c..5ed2651fe 100644 --- a/framework/json/responses/beaconInfoResponse.json +++ b/framework/json/responses/beaconInfoResponse.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Information about the Beacon. Aimed at Beacon clients like web pages or Beacon networks.", + "description": "The `beaconInfoResponse` provides metadata describing a Beacon instance, such as its name, the organization responsible for the Beacon, contact information, site logo and alternative URLs and importantly the beacon's API version. It is based on the GA4GH `service-info` standard.\nThe content of the `beaconInfoResponse` can be used by clients such as web front ends or beacon aggregators to evaluate potential access patterns and to display information about the beacon.", "properties": { "meta": { "$ref": "./sections/beaconInformationalResponseMeta.json", diff --git a/framework/json/responses/beaconMapResponse.json b/framework/json/responses/beaconMapResponse.json index d915b4a29..f2c059151 100644 --- a/framework/json/responses/beaconMapResponse.json +++ b/framework/json/responses/beaconMapResponse.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Information about the Beacon. Aimed to Beacon clients like web pages or Beacon networks.", + "description": "A `beaconMapResponse` provides information about the beacon instance such as the different endpoints supported by this implementation of the Beacon API. This response is aimed to allow Beacon clients such as web front ends and Beacon network aggregators to evaluate which access patterns can be implemented against individual beacons.", "properties": { "meta": { "$ref": "./sections/beaconInformationalResponseMeta.json", diff --git a/framework/json/responses/beaconResultsetsResponse.json b/framework/json/responses/beaconResultsetsResponse.json index 8efe9617a..cf6d1660b 100644 --- a/framework/json/responses/beaconResultsetsResponse.json +++ b/framework/json/responses/beaconResultsetsResponse.json @@ -1,7 +1,7 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", "additionalProperties": true, - "description": "Beacon response that includes record level details, grouped in Resultsets.", + "description": "A `beaconResultsetsResponse` returns the results of a query against a beacon or beacon aggregator. Beyond the `responseSummary` for overall matches the response contains details about the matches in individual **collections** in the beacon or beacon network. This type of response is required when serving a request with a \"record\" level `responseGranularity`, and `beaconResultsets` typically contain a list of records matched by the query.\nThe types of `beaconResultsets` objects are defined in the beacon's configuration; e.g. if using the Beacon v2+ default model the types `dataset` and `cohort` are supported as result sets. ", "properties": { "beaconHandovers": { "$ref": "../common/beaconCommonComponents.json#/$defs/ListOfHandovers", From dce8dffdfd6cc7b8ddd54115688faed263426c40 Mon Sep 17 00:00:00 2001 From: costero-e Date: Tue, 12 Nov 2024 16:07:45 +0100 Subject: [PATCH 29/37] adding links in changelog to point to each of the beacon v2 versions --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index b52bd0b92..0868929e1 100644 --- a/README.md +++ b/README.md @@ -33,6 +33,7 @@ There is a set of tools in [`/bin`](./bin/) to facilitate the conversion. ATM, a ## 2.1.1 *Released, October, 8, 2024* +[Beacon-v2.1.1](https://github.com/ga4gh-beacon/beacon-v2/tree/5ea17fbd0d2ba533aa1e85f7271f9a2cc9be6794) * Changed uri for uri-template in Endpoint.singleEntryUrl @@ -40,6 +41,7 @@ There is a set of tools in [`/bin`](./bin/) to facilitate the conversion. ATM, a ## 2.1.0 *Released, July, 19, 2024* +[Beacon-v2.1.0](https://github.com/ga4gh-beacon/beacon-v2/tree/16862205c79294fae5473f7fa330bf5929b3b120) * Relocated TypedQuantity required to proper level of the schema for complexValue * Added end and start entities for ageRange and iso8601duration for age @@ -48,6 +50,7 @@ There is a set of tools in [`/bin`](./bin/) to facilitate the conversion. ATM, a ## 2.0.1 *Released July, 16, 2024* +[Beacon-v2.0.1](https://github.com/ga4gh-beacon/beacon-v2/tree/f6f85c445922831bd398552384593206c86287de) * Replaced ENSGLOSSARY for SO ontology family in documentation examples * Moved CURIE to beaconCommonComponents @@ -58,6 +61,7 @@ There is a set of tools in [`/bin`](./bin/) to facilitate the conversion. ATM, a ## 2.0.0 *Released June, 21, 2022* +[Beacon-v2.0.0](https://github.com/ga4gh-beacon/beacon-v2/tree/d07ef1626321f7428374a4f68d864dfa5e98370f) * change notes with respect to the repository & documentation are now in [docs.genomebeacons.org](https://docs.genomebeacons.org/changes-todo/) * NOTE: on 2022-06-20 the previous development repositories have been archived: From 5c7f5a9299292ca6248d83ed40cf6c0cafa240ef Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Fri, 15 Nov 2024 15:45:13 +0900 Subject: [PATCH 30/37] refactoring "info" and its links This PR addresses part of the "deep link to the framework" problems. It: * moves the framework "info" to a separate file * adds another info.yaml / .json to the models in "common" and changes refereces from model schemas to this local version Both steps are complementary; if also going with the separate version in the model we might consider this for e.g. ontologyTerm, too (already a separate file in the framework). --- framework/json/common/beaconCommonComponents.json | 4 ---- framework/json/common/info.json | 6 ++++++ framework/json/responses/beaconBooleanResponse.json | 2 +- .../json/responses/beaconCollectionsResponse.json | 2 +- framework/json/responses/beaconCountResponse.json | 2 +- .../json/responses/beaconResultsetsResponse.json | 2 +- .../json/responses/sections/beaconInfoResults.json | 4 ++-- framework/src/common/beaconCommonComponents.yaml | 10 ---------- framework/src/common/info.yaml | 11 +++++++++++ framework/src/responses/beaconBooleanResponse.yaml | 2 +- .../src/responses/beaconCollectionsResponse.yaml | 2 +- framework/src/responses/beaconCountResponse.yaml | 2 +- framework/src/responses/beaconResultsetsResponse.yaml | 2 +- .../src/responses/sections/beaconInfoResults.yaml | 4 ++-- .../analyses/defaultSchema.json | 2 +- .../biosamples/defaultSchema.json | 2 +- .../datasets/defaultSchema.json | 2 +- .../individuals/defaultSchema.json | 4 ++-- .../beacon-v2-default-model/runs/defaultSchema.json | 2 +- .../analyses/defaultSchema.yaml | 2 +- .../biosamples/defaultSchema.yaml | 2 +- .../datasets/defaultSchema.yaml | 2 +- .../individuals/defaultSchema.yaml | 10 ++++++---- .../beacon-v2-default-model/runs/defaultSchema.yaml | 2 +- 24 files changed, 45 insertions(+), 40 deletions(-) create mode 100644 framework/json/common/info.json create mode 100644 framework/src/common/info.yaml diff --git a/framework/json/common/beaconCommonComponents.json b/framework/json/common/beaconCommonComponents.json index 10ee8912a..8c73c1074 100644 --- a/framework/json/common/beaconCommonComponents.json +++ b/framework/json/common/beaconCommonComponents.json @@ -142,10 +142,6 @@ ], "type": "string" }, - "Info": { - "description": "Placeholder to allow the Beacon to return any additional information that is necessary or could be of interest in relation to the query or the entry returned. It is recommended to encapsulate additional informations in this attribute instead of directly adding attributes at the same level than the others in order to avoid collision in the names of attributes in future versions of the specification.", - "type": "object" - }, "Limit": { "default": 10, "description": "Size of the page. Use `0` to return all the results or the maximum allowed by the Beacon, if there is any.", diff --git a/framework/json/common/info.json b/framework/json/common/info.json new file mode 100644 index 000000000..69826f5ed --- /dev/null +++ b/framework/json/common/info.json @@ -0,0 +1,6 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "description": "Placeholder to allow the Beacon to return any additional information that is necessary or could be of interest in relation to the query or the entry returned. It is recommended to encapsulate additional informations in this attribute instead of directly adding attributes at the same level than the others in order to avoid collision in the names of attributes in future versions of the specification.", + "title": "Info", + "type": "object" +} \ No newline at end of file diff --git a/framework/json/responses/beaconBooleanResponse.json b/framework/json/responses/beaconBooleanResponse.json index 8491ca4bd..dc36a6ddb 100644 --- a/framework/json/responses/beaconBooleanResponse.json +++ b/framework/json/responses/beaconBooleanResponse.json @@ -7,7 +7,7 @@ "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/$defs/Info", + "$ref": "../common/info.json", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/beaconCollectionsResponse.json b/framework/json/responses/beaconCollectionsResponse.json index 6728e3342..ca8cdb726 100644 --- a/framework/json/responses/beaconCollectionsResponse.json +++ b/framework/json/responses/beaconCollectionsResponse.json @@ -8,7 +8,7 @@ "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/$defs/Info", + "$ref": "../common/info.json", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/beaconCountResponse.json b/framework/json/responses/beaconCountResponse.json index 9222ae90d..acf4ffcc7 100644 --- a/framework/json/responses/beaconCountResponse.json +++ b/framework/json/responses/beaconCountResponse.json @@ -7,7 +7,7 @@ "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/$defs/Info", + "$ref": "../common/info.json", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/beaconResultsetsResponse.json b/framework/json/responses/beaconResultsetsResponse.json index 8efe9617a..094ed57a6 100644 --- a/framework/json/responses/beaconResultsetsResponse.json +++ b/framework/json/responses/beaconResultsetsResponse.json @@ -8,7 +8,7 @@ "description": "List of handovers that apply to the whole response, not to any resultset or result in particular." }, "info": { - "$ref": "../common/beaconCommonComponents.json#/$defs/Info", + "$ref": "../common/info.json", "description": "Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification." }, "meta": { diff --git a/framework/json/responses/sections/beaconInfoResults.json b/framework/json/responses/sections/beaconInfoResults.json index f795b2dbe..0773b1dba 100644 --- a/framework/json/responses/sections/beaconInfoResults.json +++ b/framework/json/responses/sections/beaconInfoResults.json @@ -20,7 +20,7 @@ "type": "string" }, "info": { - "$ref": "../../common/beaconCommonComponents.json#/$defs/Info", + "$ref": "../../common/info.json", "description": "Additional unspecified metadata about the host Organization." }, "logoUrl": { @@ -86,7 +86,7 @@ "$ref": "../../common/beaconCommonComponents.json#/$defs/BeaconId" }, "info": { - "$ref": "../../common/beaconCommonComponents.json#/$defs/Info", + "$ref": "../../common/info.json", "description": "Additional unspecified metadata about the Beacon service." }, "name": { diff --git a/framework/src/common/beaconCommonComponents.yaml b/framework/src/common/beaconCommonComponents.yaml index b77fab3ce..8af76d1a9 100644 --- a/framework/src/common/beaconCommonComponents.yaml +++ b/framework/src/common/beaconCommonComponents.yaml @@ -212,16 +212,6 @@ $defs: minimum: 0 examples: - 123 - Info: - description: >- - Placeholder to allow the Beacon to return any additional information that - is necessary or could be of interest in relation to the query or the entry - returned. - It is recommended to encapsulate additional informations in this attribute - instead of directly adding attributes at the same level than the others in - order to avoid collision in the names of attributes in future versions of - the specification. - type: object ListOfHandovers: description: Set of handovers to be added in one section the response. type: array diff --git a/framework/src/common/info.yaml b/framework/src/common/info.yaml new file mode 100644 index 000000000..2b29ef3fd --- /dev/null +++ b/framework/src/common/info.yaml @@ -0,0 +1,11 @@ +$schema: https://json-schema.org/draft/2020-12/schema +title: Info +description: >- + Placeholder to allow the Beacon to return any additional information that + is necessary or could be of interest in relation to the query or the entry + returned. + It is recommended to encapsulate additional informations in this attribute + instead of directly adding attributes at the same level than the others in + order to avoid collision in the names of attributes in future versions of + the specification. +type: object diff --git a/framework/src/responses/beaconBooleanResponse.yaml b/framework/src/responses/beaconBooleanResponse.yaml index 97811e09c..b68dc849d 100644 --- a/framework/src/responses/beaconBooleanResponse.yaml +++ b/framework/src/responses/beaconBooleanResponse.yaml @@ -17,7 +17,7 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/$defs/Info + $ref: ../common/info.yaml beaconHandovers: description: >- List of handovers that apply to the whole response, not to any resultset diff --git a/framework/src/responses/beaconCollectionsResponse.yaml b/framework/src/responses/beaconCollectionsResponse.yaml index 8b895ce6f..93a35702c 100644 --- a/framework/src/responses/beaconCollectionsResponse.yaml +++ b/framework/src/responses/beaconCollectionsResponse.yaml @@ -27,7 +27,7 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/$defs/Info + $ref: ../common/info.yaml beaconHandovers: description: List of handovers that apply to the whole response, not to any resultset or result in particular. diff --git a/framework/src/responses/beaconCountResponse.yaml b/framework/src/responses/beaconCountResponse.yaml index f083849bd..27d1dddbf 100644 --- a/framework/src/responses/beaconCountResponse.yaml +++ b/framework/src/responses/beaconCountResponse.yaml @@ -17,7 +17,7 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/$defs/Info + $ref: ../common/info.yaml beaconHandovers: description: >- List of handovers that apply to the whole response, not to any resultset diff --git a/framework/src/responses/beaconResultsetsResponse.yaml b/framework/src/responses/beaconResultsetsResponse.yaml index 11e8b732c..39601cbda 100644 --- a/framework/src/responses/beaconResultsetsResponse.yaml +++ b/framework/src/responses/beaconResultsetsResponse.yaml @@ -15,7 +15,7 @@ properties: description: >- Additional details that could be of interest. Provided to clearly enclose any attribute that is not part of the Beacon specification. - $ref: ../common/beaconCommonComponents.yaml#/$defs/Info + $ref: ../common/info.yaml beaconHandovers: description: >- List of handovers that apply to the whole response, not to any resultset diff --git a/framework/src/responses/sections/beaconInfoResults.yaml b/framework/src/responses/sections/beaconInfoResults.yaml index 2127e4a1f..3c5cbaebc 100644 --- a/framework/src/responses/sections/beaconInfoResults.yaml +++ b/framework/src/responses/sections/beaconInfoResults.yaml @@ -67,7 +67,7 @@ properties: info: description: >- Additional unspecified metadata about the Beacon service. - $ref: ../../common/beaconCommonComponents.yaml#/$defs/Info + $ref: ../../common/info.yaml $defs: BeaconOrganization: description: >- @@ -109,5 +109,5 @@ $defs: 3986 format). info: description: Additional unspecified metadata about the host Organization. - $ref: ../../common/beaconCommonComponents.yaml#/$defs/Info + $ref: ../../common/info.yaml additionalProperties: true diff --git a/models/json/beacon-v2-default-model/analyses/defaultSchema.json b/models/json/beacon-v2-default-model/analyses/defaultSchema.json index a082caa73..7def347a9 100644 --- a/models/json/beacon-v2-default-model/analyses/defaultSchema.json +++ b/models/json/beacon-v2-default-model/analyses/defaultSchema.json @@ -38,7 +38,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" + "$ref": "../common/info.json" }, "pipelineName": { "description": "Analysis pipeline and version if a standardized pipeline was used", diff --git a/models/json/beacon-v2-default-model/biosamples/defaultSchema.json b/models/json/beacon-v2-default-model/biosamples/defaultSchema.json index 392f5988a..e6eca7082 100644 --- a/models/json/beacon-v2-default-model/biosamples/defaultSchema.json +++ b/models/json/beacon-v2-default-model/biosamples/defaultSchema.json @@ -82,7 +82,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" + "$ref": "../common/info.json" }, "measurements": { "description": "List of measurements of the sample.", diff --git a/models/json/beacon-v2-default-model/datasets/defaultSchema.json b/models/json/beacon-v2-default-model/datasets/defaultSchema.json index 3efa64e7d..51e28141c 100644 --- a/models/json/beacon-v2-default-model/datasets/defaultSchema.json +++ b/models/json/beacon-v2-default-model/datasets/defaultSchema.json @@ -37,7 +37,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" + "$ref": "../common/info.json" }, "name": { "description": "Name of the dataset", diff --git a/models/json/beacon-v2-default-model/individuals/defaultSchema.json b/models/json/beacon-v2-default-model/individuals/defaultSchema.json index e5b6876a6..7ab944772 100644 --- a/models/json/beacon-v2-default-model/individuals/defaultSchema.json +++ b/models/json/beacon-v2-default-model/individuals/defaultSchema.json @@ -31,7 +31,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" + "$ref": "../common/info.json" }, "interventionsOrProcedures": { "items": { @@ -63,7 +63,7 @@ }, "sex": { "$ref": "../common/commonDefinitions.json#/$defs/Sex", - "description": "Sex of the individual. Value from NCIT General Qualifier (NCIT:C27993): 'unknown' (not assessed or not available) (NCIT:C17998), 'female' (NCIT:C16576), or 'male', (NCIT:C20197)." + "description": "Sex of the individual. Value from NCIT General Qualifier `NCIT:C27993`: * `unknown`: not assessed or not availablel `NCIT:C17998` * `female`: `NCIT:C16576)` * `male`: `NCIT:C20197`" }, "treatments": { "items": { diff --git a/models/json/beacon-v2-default-model/runs/defaultSchema.json b/models/json/beacon-v2-default-model/runs/defaultSchema.json index 61d090df2..e3f4040d9 100644 --- a/models/json/beacon-v2-default-model/runs/defaultSchema.json +++ b/models/json/beacon-v2-default-model/runs/defaultSchema.json @@ -26,7 +26,7 @@ "type": "string" }, "info": { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info" + "$ref": "../common/info.json" }, "libraryLayout": { "description": "Ontology value for the library layout e.g \"PAIRED\", \"SINGLE\" #todo add Ontology name?", diff --git a/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml b/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml index 5c454121a..3022bb09f 100644 --- a/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/analyses/defaultSchema.yaml @@ -51,7 +51,7 @@ properties: examples: - GATK4.0 info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info + $ref: ../common/info.yaml required: - id - analysisDate diff --git a/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml b/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml index 008c4575b..c90eda4d0 100644 --- a/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/biosamples/defaultSchema.yaml @@ -160,7 +160,7 @@ properties: $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/ontologyTerm.json example: {} info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info + $ref: ../common/info.yaml required: - id - biosampleStatus diff --git a/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml b/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml index 7741c5707..1747613c6 100644 --- a/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/datasets/defaultSchema.yaml @@ -40,7 +40,7 @@ properties: examples: - https://example.org/wiki/Main_Page info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info + $ref: ../common/info.yaml dataUseConditions: description: Data use conditions applying to this dataset. $ref: ../common/dataUseConditions.yaml diff --git a/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml b/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml index adc28d3e3..c9f66d993 100644 --- a/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml @@ -9,9 +9,11 @@ properties: type: string example: P0001 sex: - description: "Sex of the individual. Value from NCIT General Qualifier (NCIT:C27993):\ - \ 'unknown' (not assessed or not available) (NCIT:C17998), 'female' (NCIT:C16576),\ - \ or 'male', (NCIT:C20197)." + description: >- + Sex of the individual. Value from NCIT General Qualifier `NCIT:C27993`: + * `unknown`: not assessed or not availablel `NCIT:C17998` + * `female`: `NCIT:C16576)` + * `male`: `NCIT:C20197` $ref: ../common/commonDefinitions.yaml#/$defs/Sex karyotypicSex: description: The chromosomal sex of an individual represented from a selection @@ -60,7 +62,7 @@ properties: items: $ref: ../common/exposure.yaml info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info + $ref: ../common/info.yaml required: - id - sex diff --git a/models/src/beacon-v2-default-model/runs/defaultSchema.yaml b/models/src/beacon-v2-default-model/runs/defaultSchema.yaml index 1ba08836f..fc7efff95 100644 --- a/models/src/beacon-v2-default-model/runs/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/runs/defaultSchema.yaml @@ -74,7 +74,7 @@ properties: - id: EFO:0010938 label: large-insert clone DNA microarray info: - $ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/beaconCommonComponents.json#/$defs/Info + $ref: ../common/info.yaml required: - id - biosampleId From beeb5f90a7a00ee3dc0312bca4eaf4a33a9953e9 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 16 Nov 2024 08:52:41 +0900 Subject: [PATCH 31/37] VRS references fix Fixes the broken `https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json` entries to the now canonical `https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json` --- bin/beacon_yaml2md.pl | 4 ++-- bin/deref_schemas/obj/CopyNumber.yaml | 2 +- docs/schemas-md/obj/CopyNumber.md | 2 +- .../genomicVariations/defaultSchema.json | 6 +++--- .../genomicVariations/defaultSchema.yaml | 6 +++--- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/bin/beacon_yaml2md.pl b/bin/beacon_yaml2md.pl index 96e59c17f..9fc75fe5d 100755 --- a/bin/beacon_yaml2md.pl +++ b/bin/beacon_yaml2md.pl @@ -729,9 +729,9 @@ sub add_properties_vrs { my ( $property, $data ) = @_; my %url = ( 'SequenceExpression' => -'https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/', +'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/', 'CopyNumber' => -'https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/' +'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/' ); if ( exists $url{$property} ) { $data->{properties} = diff --git a/bin/deref_schemas/obj/CopyNumber.yaml b/bin/deref_schemas/obj/CopyNumber.yaml index 0ac7b7d77..37906e038 100644 --- a/bin/deref_schemas/obj/CopyNumber.yaml +++ b/bin/deref_schemas/obj/CopyNumber.yaml @@ -1,4 +1,4 @@ --- CopyNumber: - properties: '[VRS definition for CopyNumber](https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/CopyNumber)' + properties: '[VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber)' type: allOf diff --git a/docs/schemas-md/obj/CopyNumber.md b/docs/schemas-md/obj/CopyNumber.md index f4738d0fb..88e7a5ee7 100644 --- a/docs/schemas-md/obj/CopyNumber.md +++ b/docs/schemas-md/obj/CopyNumber.md @@ -1,3 +1,3 @@ |Term | Description | Type | Properties | Example | Enum| | ---| ---| ---| ---| ---| --- | -| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/CopyNumber) | NA | NA| +| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber) | NA | NA| diff --git a/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json b/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json index 5ec02a7fd..394bef5c4 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json +++ b/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json @@ -272,7 +272,7 @@ "type": "string" }, "location": { - "$ref": "https://raw.githubusercontent.com/ga4gh/vrs/main/schema/vrs.json#/definitions/Location" + "$ref": "https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/Location" }, "referenceBases": { "description": "Reference bases for this variant (starting from `start`). * Accepted values: IUPAC codes for nucleotides (e.g. `https://www.bioinformatics.org/sms/iupac.html`). * N is a wildcard, that denotes the position of any base, and can be used\n as a standalone base of any type or within a partially known sequence.\n* an *empty value* is used in the case of insertions with the maximally\n trimmed, inserted sequence being indicated in `AlternateBases`.", @@ -557,10 +557,10 @@ "variation": { "oneOf": [ { - "$ref": "https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/MolecularVariation" + "$ref": "https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/MolecularVariation" }, { - "$ref": "https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/SystemicVariation" + "$ref": "https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/SystemicVariation" }, { "$ref": "#/$defs/LegacyVariation" diff --git a/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml b/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml index 96c3dbff7..b5e5cc9ec 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml @@ -10,8 +10,8 @@ required: properties: variation: oneOf: - - $ref: https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/MolecularVariation - - $ref: https://raw.githubusercontent.com/ga4gh/vrs/1.2/schema/vrs.json#/definitions/SystemicVariation + - $ref: https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/MolecularVariation + - $ref: https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/SystemicVariation - $ref: '#/$defs/LegacyVariation' variantInternalId: description: >- @@ -51,7 +51,7 @@ $defs: - location properties: location: - $ref: https://raw.githubusercontent.com/ga4gh/vrs/main/schema/vrs.json#/definitions/Location + $ref: https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/Location variantType: description: >- The `variantType` declares the nature of the variation in relation From c634b81c6c012c0d2973fcf256df762c5fbb0516 Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 16 Nov 2024 09:08:49 +0900 Subject: [PATCH 32/37] VRS references from 1.2 => 1.3 The Beacon schema for genomic allows 3 options: * VRS MolecularVariation * VRS SystemicVariation * Beacon LegacyVariation (which adopts the VRS location object but uses separate definitions otherwise) Unfortunately, during Beacon v2 approval only VRS 1.2. was available and then explicitly referenced in the schema. It fast superseded by 1.3 which allows a *much* better definition of "Systemic Variations" such as CNV. This PR changes all VRS references from 1.2 => 1.3 and should be very welcome to implementers (1.3. has been the longstanding standard now until the future 2.x is out; in fact, the `bycon` based implementations such as progenetix.org have been using it for their Beacons for ~2years). --- bin/beacon_yaml2md.pl | 4 ++-- bin/deref_schemas/obj/CopyNumber.yaml | 2 +- docs/schemas-md/obj/CopyNumber.md | 2 +- .../genomicVariations/defaultSchema.json | 8 ++++---- .../genomicVariations/defaultSchema.yaml | 8 ++++---- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/bin/beacon_yaml2md.pl b/bin/beacon_yaml2md.pl index 9fc75fe5d..1285de4de 100755 --- a/bin/beacon_yaml2md.pl +++ b/bin/beacon_yaml2md.pl @@ -729,9 +729,9 @@ sub add_properties_vrs { my ( $property, $data ) = @_; my %url = ( 'SequenceExpression' => -'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/', +'https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/', 'CopyNumber' => -'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/' +'https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/' ); if ( exists $url{$property} ) { $data->{properties} = diff --git a/bin/deref_schemas/obj/CopyNumber.yaml b/bin/deref_schemas/obj/CopyNumber.yaml index 37906e038..ec96fa12b 100644 --- a/bin/deref_schemas/obj/CopyNumber.yaml +++ b/bin/deref_schemas/obj/CopyNumber.yaml @@ -1,4 +1,4 @@ --- CopyNumber: - properties: '[VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber)' + properties: '[VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/CopyNumber)' type: allOf diff --git a/docs/schemas-md/obj/CopyNumber.md b/docs/schemas-md/obj/CopyNumber.md index 88e7a5ee7..e55d7cca3 100644 --- a/docs/schemas-md/obj/CopyNumber.md +++ b/docs/schemas-md/obj/CopyNumber.md @@ -1,3 +1,3 @@ |Term | Description | Type | Properties | Example | Enum| | ---| ---| ---| ---| ---| --- | -| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber) | NA | NA| +| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/CopyNumber) | NA | NA| diff --git a/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json b/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json index 394bef5c4..19d42db14 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json +++ b/models/json/beacon-v2-default-model/genomicVariations/defaultSchema.json @@ -1,5 +1,5 @@ { - "$comment": "version: ga4gh-beacon-variant-v2.0.0", + "$comment": "version: ga4gh-beacon-variant-v2.1.0", "$defs": { "CaseLevelVariant": { "description": "", @@ -272,7 +272,7 @@ "type": "string" }, "location": { - "$ref": "https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/Location" + "$ref": "https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/Location" }, "referenceBases": { "description": "Reference bases for this variant (starting from `start`). * Accepted values: IUPAC codes for nucleotides (e.g. `https://www.bioinformatics.org/sms/iupac.html`). * N is a wildcard, that denotes the position of any base, and can be used\n as a standalone base of any type or within a partially known sequence.\n* an *empty value* is used in the case of insertions with the maximally\n trimmed, inserted sequence being indicated in `AlternateBases`.", @@ -557,10 +557,10 @@ "variation": { "oneOf": [ { - "$ref": "https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/MolecularVariation" + "$ref": "https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/MolecularVariation" }, { - "$ref": "https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/SystemicVariation" + "$ref": "https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/SystemicVariation" }, { "$ref": "#/$defs/LegacyVariation" diff --git a/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml b/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml index b5e5cc9ec..df68f4d7d 100644 --- a/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/genomicVariations/defaultSchema.yaml @@ -1,6 +1,6 @@ $schema: https://json-schema.org/draft/2020-12/schema title: Genomic Variation -$comment: 'version: ga4gh-beacon-variant-v2.0.0' +$comment: 'version: ga4gh-beacon-variant-v2.1.0' description: >- Schema for a genomic variant entry. type: object @@ -10,8 +10,8 @@ required: properties: variation: oneOf: - - $ref: https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/MolecularVariation - - $ref: https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/SystemicVariation + - $ref: https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/MolecularVariation + - $ref: https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/SystemicVariation - $ref: '#/$defs/LegacyVariation' variantInternalId: description: >- @@ -51,7 +51,7 @@ $defs: - location properties: location: - $ref: https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/Location + $ref: https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/Location variantType: description: >- The `variantType` declares the nature of the variation in relation From b1f81dcf9e280f79e3db5050a623bbb2bbd4addb Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sat, 16 Nov 2024 09:22:14 +0900 Subject: [PATCH 33/37] removing the schema deparser changes The `beacon_yaml2md.pl` doc generator contains hard coded definitions to VRS 1.2 `CopyNumber` which doesn't exist in 1.3. This should be fixed separately, possibly w/ revision of the schema documentation method/engine. --- bin/beacon_yaml2md.pl | 4 ++-- bin/deref_schemas/obj/CopyNumber.yaml | 2 +- docs/schemas-md/obj/CopyNumber.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bin/beacon_yaml2md.pl b/bin/beacon_yaml2md.pl index 1285de4de..9fc75fe5d 100755 --- a/bin/beacon_yaml2md.pl +++ b/bin/beacon_yaml2md.pl @@ -729,9 +729,9 @@ sub add_properties_vrs { my ( $property, $data ) = @_; my %url = ( 'SequenceExpression' => -'https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/', +'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/', 'CopyNumber' => -'https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/' +'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/' ); if ( exists $url{$property} ) { $data->{properties} = diff --git a/bin/deref_schemas/obj/CopyNumber.yaml b/bin/deref_schemas/obj/CopyNumber.yaml index ec96fa12b..37906e038 100644 --- a/bin/deref_schemas/obj/CopyNumber.yaml +++ b/bin/deref_schemas/obj/CopyNumber.yaml @@ -1,4 +1,4 @@ --- CopyNumber: - properties: '[VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/CopyNumber)' + properties: '[VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber)' type: allOf diff --git a/docs/schemas-md/obj/CopyNumber.md b/docs/schemas-md/obj/CopyNumber.md index e55d7cca3..88e7a5ee7 100644 --- a/docs/schemas-md/obj/CopyNumber.md +++ b/docs/schemas-md/obj/CopyNumber.md @@ -1,3 +1,3 @@ |Term | Description | Type | Properties | Example | Enum| | ---| ---| ---| ---| ---| --- | -| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/CopyNumber) | NA | NA| +| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber) | NA | NA| From 4c2b35bc0637bdf16e946365d37ae7f56dbcb71b Mon Sep 17 00:00:00 2001 From: Michael Baudis Date: Sun, 24 Nov 2024 20:32:44 +0900 Subject: [PATCH 34/37] fix typo in example Thanks @costero-e for https://github.com/ga4gh-beacon/beacon-v2/pull/184#pullrequestreview-2454894933 ... --- .../json/beacon-v2-default-model/individuals/defaultSchema.json | 2 +- .../src/beacon-v2-default-model/individuals/defaultSchema.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/models/json/beacon-v2-default-model/individuals/defaultSchema.json b/models/json/beacon-v2-default-model/individuals/defaultSchema.json index 7ab944772..c916b09bd 100644 --- a/models/json/beacon-v2-default-model/individuals/defaultSchema.json +++ b/models/json/beacon-v2-default-model/individuals/defaultSchema.json @@ -63,7 +63,7 @@ }, "sex": { "$ref": "../common/commonDefinitions.json#/$defs/Sex", - "description": "Sex of the individual. Value from NCIT General Qualifier `NCIT:C27993`: * `unknown`: not assessed or not availablel `NCIT:C17998` * `female`: `NCIT:C16576)` * `male`: `NCIT:C20197`" + "description": "Sex of the individual. Value from NCIT General Qualifier `NCIT:C27993`: * `unknown`: not assessed or not availablel `NCIT:C17998` * `female`: `NCIT:C16576` * `male`: `NCIT:C20197`" }, "treatments": { "items": { diff --git a/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml b/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml index c9f66d993..ede6165f2 100644 --- a/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml +++ b/models/src/beacon-v2-default-model/individuals/defaultSchema.yaml @@ -12,7 +12,7 @@ properties: description: >- Sex of the individual. Value from NCIT General Qualifier `NCIT:C27993`: * `unknown`: not assessed or not availablel `NCIT:C17998` - * `female`: `NCIT:C16576)` + * `female`: `NCIT:C16576` * `male`: `NCIT:C20197` $ref: ../common/commonDefinitions.yaml#/$defs/Sex karyotypicSex: From 07a6f025e99cd30d39016027691e9cfddaafa205 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oriol=20L=C3=B3pez-Doriga?= <79700502+costero-e@users.noreply.github.com> Date: Thu, 12 Dec 2024 16:35:32 +0100 Subject: [PATCH 35/37] Update CopyNumber.md --- docs/schemas-md/obj/CopyNumber.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/schemas-md/obj/CopyNumber.md b/docs/schemas-md/obj/CopyNumber.md index 88e7a5ee7..e55d7cca3 100644 --- a/docs/schemas-md/obj/CopyNumber.md +++ b/docs/schemas-md/obj/CopyNumber.md @@ -1,3 +1,3 @@ |Term | Description | Type | Properties | Example | Enum| | ---| ---| ---| ---| ---| --- | -| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber) | NA | NA| +| CopyNumber | NA | allOf | [VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/CopyNumber) | NA | NA| From 7bf20b80cff07b5be5d0b370f3054c3e79c8f4ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oriol=20L=C3=B3pez-Doriga?= <79700502+costero-e@users.noreply.github.com> Date: Thu, 12 Dec 2024 16:36:18 +0100 Subject: [PATCH 36/37] Update beacon_yaml2md.pl --- bin/beacon_yaml2md.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/beacon_yaml2md.pl b/bin/beacon_yaml2md.pl index 9fc75fe5d..1285de4de 100755 --- a/bin/beacon_yaml2md.pl +++ b/bin/beacon_yaml2md.pl @@ -729,9 +729,9 @@ sub add_properties_vrs { my ( $property, $data ) = @_; my %url = ( 'SequenceExpression' => -'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/', +'https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/', 'CopyNumber' => -'https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/' +'https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/' ); if ( exists $url{$property} ) { $data->{properties} = From 507da0a579583974bca4dc130a0ac84c0b3adc8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oriol=20L=C3=B3pez-Doriga?= <79700502+costero-e@users.noreply.github.com> Date: Thu, 12 Dec 2024 16:37:43 +0100 Subject: [PATCH 37/37] Update CopyNumber.yaml --- bin/deref_schemas/obj/CopyNumber.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/deref_schemas/obj/CopyNumber.yaml b/bin/deref_schemas/obj/CopyNumber.yaml index 37906e038..ec96fa12b 100644 --- a/bin/deref_schemas/obj/CopyNumber.yaml +++ b/bin/deref_schemas/obj/CopyNumber.yaml @@ -1,4 +1,4 @@ --- CopyNumber: - properties: '[VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.2/vrs.json#/definitions/CopyNumber)' + properties: '[VRS definition for CopyNumber](https://w3id.org/ga4gh/schema/vrs/1.3/vrs.json#/definitions/CopyNumber)' type: allOf