-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
scenario-completer.json
85 lines (85 loc) · 2.6 KB
/
scenario-completer.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
{
"title": "Completer Scenario Options",
"type": "object",
"properties": {
"editor": {
"title": "Editor type",
"description": "Editor widget to test completion in",
"type": "string",
"enum": ["Notebook", "File Editor"],
"default": "File Editor"
},
"path": {
"title": "Path to document",
"description": "Optional path to an existing document of specified editor type. When empty (default) a new temporary file will be created.",
"type": "string",
"default": ""
},
"setup": {
"title": "Editor setup for completion",
"description": "How should the editor be populated?",
"default": {
"tokenCount": 1000,
"tokenSize": 50
},
"anyOf": [
{
"type": "object",
"title": "Auto-generate tokens to complete",
"properties": {
"tokenCount": {
"title": "Token count",
"description": "The number of completion items to generate",
"type": "number",
"minimum": 1,
"default": 1000
},
"tokenSize": {
"title": "Token size",
"description": "The number characters in each token",
"type": "number",
"minimum": 1,
"default": 50
}
},
"required": ["tokenCount", "tokenSize"]
},
{
"type": "object",
"title": "I will provide a custom text",
"properties": {
"setupText": {
"title": "Trigger code",
"description": "Text to enter into the editor. Last line should include a partial token on which the completion will be riggered.",
"type": "string",
"default": "np."
},
"setupCell": {
"title": "Code to run (notebook only)",
"description": "Code to run prior to invoking completer, e.g. `import numpy as np`. Only has an effect in notebook.",
"type": "string",
"default": "import numpy as np"
}
},
"required": ["setupText", "triggerCell"]
}
]
},
"widgetPosition": {
"title": "Widget position in the layout",
"description": "Where to attach the editor widget in the layout",
"type": "string",
"enum": [
"split-top",
"split-left",
"split-right",
"split-bottom",
"tab-before",
"tab-after"
],
"default": "split-right"
}
},
"required": ["editor", "setup"],
"additionalProperties": false
}