Skip to content

Commit

Permalink
fix: Update label_config_schema.json according to LS backend (#344)
Browse files Browse the repository at this point in the history
  • Loading branch information
makseq authored Oct 28, 2024
1 parent 238b0f4 commit d34495f
Showing 1 changed file with 42 additions and 11 deletions.
53 changes: 42 additions & 11 deletions src/label_studio_sdk/_legacy/schema/label_config_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,22 +35,44 @@
}
}
},
"tag_with_value_required_name": {
"tag_with_name_and_toname": {
"type": "object",
"anyOf": [
{
"required": [
"@name",
"@valueList"
]
},
"oneOf": [
{
"required": [
"@name",
"@value"
"@toName"
]
}
],
"properties": {
"@name": {
"$ref": "#/definitions/@name"
},
"@toName": {
"$ref": "#/definitions/@toName"
},
"$": {
"$ref": "#/definitions/$"
}
}
},
"tag_with_value_required_name": {
"type": "object",
"oneOf": [
{
"required": [
"@name",
"@value"
]
},
{
"required": [
"@name",
"@valueList"
]
}
],
"properties": {
"@value": {
"$ref": "#/definitions/@value"
Expand Down Expand Up @@ -80,6 +102,13 @@
"items": {"$ref": "#/definitions/tag_with_value_required_name"}
}, {"$ref": "#/definitions/tag_with_value_required_name"}]
},
"tags_with_name_and_toname": {
"anyOf": [{"$ref": "#/definitions/tag_with_name_and_toname"},
{
"type": "array",
"items": {"$ref": "#/definitions/tag_with_name_and_toname"}
}]
},
"View": {
"type": "object",
"additionalProperties": true,
Expand All @@ -92,7 +121,8 @@
"Text": {"$ref": "#/definitions/tags_with_value_required_name"},
"HyperText": {"$ref": "#/definitions/tags_with_value_required_name"},
"View": {"$ref": "#/definitions/MaybeMultipleView"},
"TextArea": {"$ref": "#/definitions/MaybeMultipleTextAreas"}
"TextArea": {"$ref": "#/definitions/MaybeMultipleTextAreas"},
"Number": {"$ref": "#/definitions/tags_with_name_and_toname"}
}
},
"MaybeMultipleView": {
Expand Down Expand Up @@ -219,7 +249,8 @@
"Image": {"$ref": "#/definitions/tags_with_value_required_name"},
"Text": {"$ref": "#/definitions/tags_with_value_required_name"},
"HyperText": {"$ref": "#/definitions/tags_with_value_required_name"},
"TextArea": {"$ref": "#/definitions/MaybeMultipleTextAreas"}
"TextArea": {"$ref": "#/definitions/MaybeMultipleTextAreas"},
"Number": {"$ref": "#/definitions/tags_with_name_and_toname"}
}
}
}
Expand Down

0 comments on commit d34495f

Please sign in to comment.