/ simulated_instruments / instrument-format
Sign in
simulated_instruments / instrument-format
instrument-format / schema / numbl-instrument-v1.schema.json
45 lines · 1.4 KBBlameHistoryRaw
1{
2 "$schema": "https://json-schema.org/draft/2020-12/schema",
3 "$id": "numbl-instrument-v1.schema.json",
4 "title": "numbl instrument bundle, format numbl-instrument-v1",
5 "type": "object",
6 "required": ["format", "id", "name", "knobs", "files"],
7 "additionalProperties": false,
8 "properties": {
9 "format": { "const": "numbl-instrument-v1" },
10 "id": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]*$" },
11 "name": { "type": "string", "minLength": 1 },
12 "description": { "type": "string" },
13 "source": { "type": "string" },
14 "knobs": {
15 "type": "array",
16 "items": {
17 "type": "object",
18 "required": ["key", "label", "min", "max", "default"],
19 "additionalProperties": false,
20 "properties": {
21 "key": { "type": "string", "minLength": 1 },
22 "label": { "type": "string", "minLength": 1 },
23 "min": { "type": "number" },
24 "max": { "type": "number" },
25 "default": { "type": "number" },
26 "step": { "type": "number", "exclusiveMinimum": 0 },
27 "scale": { "const": "log" }
28 }
29 }
30 },
31 "files": {
32 "type": "array",
33 "minItems": 1,
34 "items": {
35 "type": "object",
36 "required": ["name", "content"],
37 "additionalProperties": false,
38 "properties": {
39 "name": { "type": "string", "pattern": "^[^/]+\\.m$" },
40 "content": { "type": "string", "minLength": 1 }
41 }
42 }
43 }
44 }
↑↓ move↵openescclose