From ccc6676040c94d37b0159752a9f97d07554642dc Mon Sep 17 00:00:00 2001 From: Christian Monch Date: Fri, 14 Feb 2025 16:01:18 +0100 Subject: [PATCH] allow strings as `Thing.relations`-values This commit adds the type "string" as possible value for an entry in the `relations`-slot of `Thing`. This allows to represent pure links to "related" objects by storing a key-value pair where the key is the `id` of a related record and the value is ''. This allows for a much nicer representation of extracted records (see issue ) --- src/things/unreleased.yaml | 5 ++++- src/types/unreleased.yaml | 6 ++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/things/unreleased.yaml b/src/things/unreleased.yaml index 6a7c93d..67a460d 100644 --- a/src/things/unreleased.yaml +++ b/src/things/unreleased.yaml @@ -260,7 +260,10 @@ slots: inlined: true inlined_as_list: false multivalued: true - range: Thing + range: Any + any_of: + - range: Thing + - range: string relational_role: OBJECT symmetric: true exact_mappings: diff --git a/src/types/unreleased.yaml b/src/types/unreleased.yaml index b7cb49a..5fe69a7 100644 --- a/src/types/unreleased.yaml +++ b/src/types/unreleased.yaml @@ -104,3 +104,9 @@ slots: exact_mappings: - dcterms:type + +classes: + Any: + description: >- + Use this type to state that the value of a slot can by any type. + class_uri: linkml:Any