Skip to content

Commit b5c2230

Browse files
committed
Toolbox documentation
1 parent c1cac41 commit b5c2230

File tree

2 files changed

+37
-17
lines changed

2 files changed

+37
-17
lines changed

docs/Glossary/Toolbox.md

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -19,34 +19,33 @@ A toolbox consists of:
1919

2020
The top level schema of a toolbox is:
2121

22-
```json
23-
{
24-
"ID": "string (required)",
25-
"Name": "string (required)",
26-
"Description": "string (optional)"
22+
```
23+
object {
24+
Spaces: array[Space] (required)
25+
Blocks: array[Block] (required)
2726
}
2827
```
2928

3029
And the children schemas are as follows below.
3130

3231
### Block Schema
3332

34-
```json
35-
{
36-
"ID": "string (required)",
37-
"Name": "string (required)",
38-
"Description": "string (optional)"
33+
```
34+
object {
35+
ID: string (required)
36+
Name: string (required)
37+
Description: string
38+
Domain: array[string] (required)
39+
Codomain: array[string] (required)
3940
}
4041
```
4142

4243
### Space Schema
4344

44-
```json
45-
{
46-
"ID": "string (required)",
47-
"Name": "string (required)",
48-
"Description": "string (optional)",
49-
"Domain": "array[Space] (required, can be empty)",
50-
"Codomain": "array[Space] (required, can be empty)"
45+
```
46+
object {
47+
ID: string (required)
48+
Name: string (required)
49+
Description: string
5150
}
5251
```

scratch/schema.ipynb

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,27 @@
135135
"print(format_json_schema_draft07(schema2))\"\"\""
136136
]
137137
},
138+
{
139+
"cell_type": "code",
140+
"execution_count": 5,
141+
"metadata": {},
142+
"outputs": [
143+
{
144+
"name": "stdout",
145+
"output_type": "stream",
146+
"text": [
147+
"array[object {\n",
148+
" ID: string (required)\n",
149+
" Name: string (required)\n",
150+
" Description: string\n",
151+
"}]\n"
152+
]
153+
}
154+
],
155+
"source": [
156+
"print(format_json_schema_draft07(schema[\"properties\"][\"Toolbox\"][\"properties\"][\"Spaces\"]))"
157+
]
158+
},
138159
{
139160
"cell_type": "code",
140161
"execution_count": 2,

0 commit comments

Comments
 (0)