ggaction 0.0.8 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +40 -0
- package/README.md +34 -6
- package/knowledge/action-cards.json +10941 -0
- package/knowledge/extension-authoring.md +248 -0
- package/knowledge/intent-taxonomy.json +183 -0
- package/knowledge/mcp-resources.json +95 -0
- package/knowledge/task-packet.schema.json +159 -0
- package/knowledge/task-resolver.js +1230 -0
- package/package.json +11 -1
- package/src/actions/basic.js +3 -3
- package/src/actions/coordinates/actions.js +4 -0
- package/src/actions/encodings/position/policies/line.js +5 -1
- package/src/actions/guides/legends/categorical/index.js +85 -2
- package/src/actions/guides/legends/categorical/symbols.js +2 -76
- package/src/actions/index.js +1 -1
- package/src/actions/primitives/index.js +27 -0
- package/src/actions/primitives/semantic.js +22 -185
- package/src/actions/primitives/semanticAction.js +188 -0
- package/src/actions/primitives/semanticValidation/dataset.js +7 -3
- package/src/actions/primitives/semanticValidation/index.js +28 -15
- package/src/actions/primitives/semanticValidation/layer.js +20 -16
- package/src/core/action.js +20 -5
- package/src/core/extensionRegistry.js +104 -0
- package/src/extension.js +8 -1
- package/src/grammar/transformTopology.js +18 -0
- package/src/grammar/transforms.js +21 -20
- package/src/materialization/dataProvenance.js +2 -2
- package/src/materialization/marks/pathOrder.js +2 -2
- package/src/mcp/adapter.js +206 -0
- package/src/mcp/cli.js +11 -0
- package/src/mcp/server.js +101 -0
- package/types/extension.d.ts +19 -0
- package/types/program.d.ts +4 -0
- package/src/actions/coordinates/index.js +0 -5
- package/src/actions/primitives/semanticValue.js +0 -1
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://ggaction.github.io/ggaction/schemas/task-packet.schema.json",
|
|
4
|
+
"title": "ggaction compact task packet",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"schemaVersion",
|
|
9
|
+
"query",
|
|
10
|
+
"matchedConstraints",
|
|
11
|
+
"actionPlan",
|
|
12
|
+
"exactCalls",
|
|
13
|
+
"authoring",
|
|
14
|
+
"unsupported",
|
|
15
|
+
"unresolved",
|
|
16
|
+
"candidates"
|
|
17
|
+
],
|
|
18
|
+
"properties": {
|
|
19
|
+
"schemaVersion": { "const": 3 },
|
|
20
|
+
"query": { "type": "string", "minLength": 1, "maxLength": 500 },
|
|
21
|
+
"matchedConstraints": {
|
|
22
|
+
"type": "array",
|
|
23
|
+
"maxItems": 30,
|
|
24
|
+
"uniqueItems": true,
|
|
25
|
+
"items": { "type": "string", "minLength": 3, "maxLength": 100 }
|
|
26
|
+
},
|
|
27
|
+
"actionPlan": {
|
|
28
|
+
"type": "array",
|
|
29
|
+
"maxItems": 20,
|
|
30
|
+
"items": {
|
|
31
|
+
"type": "object",
|
|
32
|
+
"additionalProperties": false,
|
|
33
|
+
"required": [
|
|
34
|
+
"step",
|
|
35
|
+
"id",
|
|
36
|
+
"kind",
|
|
37
|
+
"name",
|
|
38
|
+
"constraints",
|
|
39
|
+
"requiredOptions",
|
|
40
|
+
"signature",
|
|
41
|
+
"route"
|
|
42
|
+
],
|
|
43
|
+
"properties": {
|
|
44
|
+
"step": { "type": "integer", "minimum": 1 },
|
|
45
|
+
"id": { "type": "string", "minLength": 3 },
|
|
46
|
+
"kind": { "enum": ["action", "runtime"] },
|
|
47
|
+
"name": { "type": "string", "pattern": "^[A-Za-z][A-Za-z0-9]*$" },
|
|
48
|
+
"constraints": {
|
|
49
|
+
"type": "array",
|
|
50
|
+
"minItems": 1,
|
|
51
|
+
"uniqueItems": true,
|
|
52
|
+
"items": { "type": "string", "minLength": 3 }
|
|
53
|
+
},
|
|
54
|
+
"requiredOptions": {
|
|
55
|
+
"type": "array",
|
|
56
|
+
"uniqueItems": true,
|
|
57
|
+
"items": { "type": "string", "pattern": "^[A-Za-z][A-Za-z0-9]*$" }
|
|
58
|
+
},
|
|
59
|
+
"signature": { "type": "string", "minLength": 8 },
|
|
60
|
+
"route": { "type": "string", "pattern": "^/reference/" }
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"exactCalls": {
|
|
65
|
+
"type": "array",
|
|
66
|
+
"maxItems": 20,
|
|
67
|
+
"items": { "type": "string", "minLength": 3, "maxLength": 700 }
|
|
68
|
+
},
|
|
69
|
+
"authoring": {
|
|
70
|
+
"type": "object",
|
|
71
|
+
"additionalProperties": false,
|
|
72
|
+
"required": ["imports", "initialize", "prerequisites", "steps"],
|
|
73
|
+
"properties": {
|
|
74
|
+
"imports": {
|
|
75
|
+
"type": "array",
|
|
76
|
+
"minItems": 1,
|
|
77
|
+
"maxItems": 4,
|
|
78
|
+
"uniqueItems": true,
|
|
79
|
+
"items": { "type": "string", "minLength": 30, "maxLength": 90 }
|
|
80
|
+
},
|
|
81
|
+
"initialize": { "const": "let program = chart()" },
|
|
82
|
+
"prerequisites": {
|
|
83
|
+
"type": "array",
|
|
84
|
+
"minItems": 2,
|
|
85
|
+
"maxItems": 2,
|
|
86
|
+
"items": {
|
|
87
|
+
"type": "object",
|
|
88
|
+
"additionalProperties": false,
|
|
89
|
+
"required": ["id", "signature", "call", "bindings"],
|
|
90
|
+
"properties": {
|
|
91
|
+
"id": { "enum": ["action.createCanvas", "action.createData"] },
|
|
92
|
+
"signature": { "type": "string", "minLength": 8, "maxLength": 180 },
|
|
93
|
+
"call": { "type": "string", "minLength": 12, "maxLength": 180 },
|
|
94
|
+
"bindings": {
|
|
95
|
+
"type": "array",
|
|
96
|
+
"maxItems": 4,
|
|
97
|
+
"uniqueItems": true,
|
|
98
|
+
"items": { "type": "string", "pattern": "^[A-Za-z][A-Za-z0-9]*$" }
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
"steps": {
|
|
104
|
+
"type": "array",
|
|
105
|
+
"maxItems": 20,
|
|
106
|
+
"items": { "type": "string", "minLength": 3, "maxLength": 760 }
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
"unsupported": {
|
|
111
|
+
"type": "array",
|
|
112
|
+
"maxItems": 10,
|
|
113
|
+
"items": {
|
|
114
|
+
"type": "object",
|
|
115
|
+
"additionalProperties": false,
|
|
116
|
+
"required": ["constraint", "reason"],
|
|
117
|
+
"properties": {
|
|
118
|
+
"constraint": { "type": "string", "pattern": "^unsupported\\." },
|
|
119
|
+
"reason": { "type": "string", "minLength": 10, "maxLength": 240 }
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"unresolved": {
|
|
124
|
+
"type": "array",
|
|
125
|
+
"maxItems": 30,
|
|
126
|
+
"items": {
|
|
127
|
+
"type": "object",
|
|
128
|
+
"additionalProperties": false,
|
|
129
|
+
"required": ["constraint", "reason", "resources"],
|
|
130
|
+
"properties": {
|
|
131
|
+
"constraint": { "type": "string", "minLength": 3 },
|
|
132
|
+
"reason": { "type": "string", "minLength": 10, "maxLength": 240 },
|
|
133
|
+
"resources": {
|
|
134
|
+
"type": "array",
|
|
135
|
+
"minItems": 1,
|
|
136
|
+
"maxItems": 2,
|
|
137
|
+
"uniqueItems": true,
|
|
138
|
+
"items": { "type": "string", "pattern": "^ggaction://docs/[a-z0-9-]+$" }
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
"candidates": {
|
|
144
|
+
"type": "array",
|
|
145
|
+
"maxItems": 3,
|
|
146
|
+
"items": {
|
|
147
|
+
"type": "object",
|
|
148
|
+
"additionalProperties": false,
|
|
149
|
+
"required": ["id", "kind", "name", "route"],
|
|
150
|
+
"properties": {
|
|
151
|
+
"id": { "type": "string", "minLength": 3 },
|
|
152
|
+
"kind": { "enum": ["action", "runtime"] },
|
|
153
|
+
"name": { "type": "string", "minLength": 2 },
|
|
154
|
+
"route": { "type": "string", "pattern": "^/reference/" }
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|