@adaptabletools/adaptable-mcp 0.1.0-canary.3 → 0.1.0
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/README.md +3 -3
- package/data/changes/21-22.json +1 -1
- package/data/changes/22-23.json +1 -1
- package/data/changes/23-24.json +3 -3
- package/data/manifest.snapshot.json +16 -16
- package/dist/core/extract/ts-literal.js +50 -3
- package/dist/core/extract/ts-literal.js.map +1 -1
- package/dist/core/scaffold/capabilities.js +9 -3
- package/dist/core/scaffold/capabilities.js.map +1 -1
- package/dist/core/scaffold/generate.js +22 -4
- package/dist/core/scaffold/generate.js.map +1 -1
- package/dist/core/scaffold/infer.js +61 -12
- package/dist/core/scaffold/infer.js.map +1 -1
- package/dist/skills/adaptable-debug/SKILL.md +3 -3
- package/dist/skills/adaptable-debug/VERSION.md +1 -1
- package/dist/skills/adaptable-debug/references/_shared/agents-snippet.md +1 -1
- package/dist/skills/adaptable-debug/references/_shared/capabilities.md +1 -1
- package/dist/skills/adaptable-debug/references/_shared/grounding.md +23 -7
- package/dist/skills/adaptable-dev/SKILL.md +7 -6
- package/dist/skills/adaptable-dev/VERSION.md +1 -1
- package/dist/skills/adaptable-dev/references/_shared/agents-snippet.md +1 -1
- package/dist/skills/adaptable-dev/references/_shared/capabilities.md +1 -1
- package/dist/skills/adaptable-dev/references/_shared/grounding.md +23 -7
- package/dist/skills/adaptable-dev/references/recommendations.md +1 -0
- package/dist/skills/adaptable-setup/SKILL.md +43 -11
- package/dist/skills/adaptable-setup/VERSION.md +1 -1
- package/dist/skills/adaptable-setup/references/_shared/agents-snippet.md +1 -1
- package/dist/skills/adaptable-setup/references/_shared/capabilities.md +1 -1
- package/dist/skills/adaptable-setup/references/_shared/grounding.md +23 -7
- package/dist/skills/adaptable-upgrade/SKILL.md +5 -5
- package/dist/skills/adaptable-upgrade/VERSION.md +1 -1
- package/dist/skills/adaptable-upgrade/references/_shared/agents-snippet.md +1 -1
- package/dist/skills/adaptable-upgrade/references/_shared/capabilities.md +1 -1
- package/dist/skills/adaptable-upgrade/references/_shared/grounding.md +23 -7
- package/dist/skills/adaptable-upgrade/references/apply-order.md +13 -11
- package/dist/skills/adaptable-upgrade/scripts/adaptable.mjs +1 -1
- package/package.json +1 -1
|
@@ -33,8 +33,11 @@ package and the environment minimums.
|
|
|
33
33
|
|
|
34
34
|
**Gate — AG Grid edition and version.** AdapTable needs AG Grid Enterprise at
|
|
35
35
|
the paired version. If `detect` shows AG Grid Community, or an AG Grid below
|
|
36
|
-
the pairing: **ask** — upgrade AG Grid first
|
|
37
|
-
|
|
36
|
+
the pairing: **ask** — upgrade AG Grid first or stop. The upgrade bumps every
|
|
37
|
+
`ag-grid-*` package to the pairing `compat` names (adding `ag-grid-enterprise`
|
|
38
|
+
when only Community is installed); AG Grid's own breaking changes go through
|
|
39
|
+
the AG Grid fallback (grounding). Do not install AdapTable onto an unpaired
|
|
40
|
+
grid and hope.
|
|
38
41
|
|
|
39
42
|
**Ask once, for everything this phase needs:** the AdapTable and AG Grid
|
|
40
43
|
licence keys (or confirmation to use trial placeholders — keys go to the
|
|
@@ -45,7 +48,7 @@ no obvious unique column. One round of questions, then proceed.
|
|
|
45
48
|
## Phase 3 — Shell (path C only)
|
|
46
49
|
|
|
47
50
|
```bash
|
|
48
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
51
|
+
npx -y @adaptabletools/adaptable-mcp@^0 scaffold --dry-run --framework <framework> --out <dir> [--data <file> | --sample <file.json> | --source-url <url>]
|
|
49
52
|
```
|
|
50
53
|
|
|
51
54
|
Pass the data source agreed in Phase 2 (without it the dry run previews the
|
|
@@ -69,7 +72,7 @@ re-run `detect` in the new folder.
|
|
|
69
72
|
3. Migrate ColDef-owned layout and styling:
|
|
70
73
|
|
|
71
74
|
```bash
|
|
72
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
75
|
+
npx -y @adaptabletools/adaptable-mcp@^0 convert coldefs <columnDefs file>
|
|
73
76
|
```
|
|
74
77
|
|
|
75
78
|
It returns a Layout for the new Initial State, a `remove[]` list of
|
|
@@ -80,21 +83,50 @@ re-run `detect` in the new folder.
|
|
|
80
83
|
|
|
81
84
|
**Gate — ColDef migration.** **Ask** which Layout-owned properties to move
|
|
82
85
|
(default: all — leaving them in the ColDef means the Layout and the ColDef
|
|
83
|
-
fight) and which candidates to re-express now (default:
|
|
84
|
-
|
|
85
|
-
|
|
86
|
+
fight) and which candidates to re-express now (default: every candidate
|
|
87
|
+
AdapTable can express — AdapTable objects persist in State, are editable at
|
|
88
|
+
run time and are seen by the rest of AdapTable; a ColDef function is none
|
|
89
|
+
of these). Before asking, map each candidate to its AdapTable object:
|
|
90
|
+
|
|
91
|
+
- `valueFormatter` → a Format Column `DisplayFormat` when the built-in
|
|
92
|
+
Number, Date or String formatter options reproduce it; otherwise a
|
|
93
|
+
`formatColumnOptions.customDisplayFormatters` entry referenced from the
|
|
94
|
+
Format Column's `CustomDisplayFormats`. One formatter shared by several
|
|
95
|
+
columns is one Format Column whose Scope lists those columns.
|
|
96
|
+
- `cellStyle` / `cellClassRules` → a Format Column `Style`, with a `Rule`
|
|
97
|
+
for the conditional cases.
|
|
98
|
+
- `valueGetter` → a Calculated Column when an AdapTableQL Expression can
|
|
99
|
+
compute the value.
|
|
100
|
+
- `cellRenderer` → a Styled Column (gradient, percent bar, sparkline,
|
|
101
|
+
badge, bullet chart, rating, range bar, icon) or an Action Column
|
|
102
|
+
(buttons).
|
|
103
|
+
|
|
104
|
+
Recommend keeping a candidate in the ColDef only when it has no AdapTable
|
|
105
|
+
equivalent (a `valueGetter` that needs JavaScript state an Expression
|
|
106
|
+
cannot reach, a bespoke renderer), and say why for each. Take every target
|
|
107
|
+
shape from `docs search`, not memory, and remove the ColDef property you
|
|
108
|
+
re-express — the ColDef and the AdapTable object would otherwise both
|
|
109
|
+
apply. Apply the agreed edits, then `check setup` and `check state` on the
|
|
110
|
+
new Initial State.
|
|
86
111
|
|
|
87
112
|
### Paths B/C — scaffold the overlay
|
|
88
113
|
|
|
89
114
|
```bash
|
|
90
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
115
|
+
npx -y @adaptabletools/adaptable-mcp@^0 scaffold --dry-run --out <dir> [--data <file> | --sample <file.json> | --source-url <url>]
|
|
91
116
|
```
|
|
92
117
|
|
|
93
118
|
**Gate — columns and primary key.** **Show** the inferred columns (field,
|
|
94
119
|
type, nullability) and the primary-key choice from the dry run and **ask**
|
|
95
120
|
the user to confirm or correct them — a wrong type or key here is baked into
|
|
96
|
-
every file.
|
|
97
|
-
|
|
121
|
+
every file. When source column names contain spaces, the dry run has already
|
|
122
|
+
renamed them to camelCase fields (`Order Cost` → `orderCost`, the header
|
|
123
|
+
stays `Order Cost`; each renamed column carries its `sourceField`): **show**
|
|
124
|
+
the renames and **ask** whether to keep them (default: yes — recommended;
|
|
125
|
+
kept as they are, the names are quoted in the row type and every row access,
|
|
126
|
+
and the column id, `Order_Cost`, differs from the field) or to use the
|
|
127
|
+
names as they are (`--field-names keep`). Then run without `--dry-run`
|
|
128
|
+
with the agreed flags (add `--force` only for files the user has agreed to
|
|
129
|
+
overwrite). The run writes `columnDefs.ts`, `rowData.ts`,
|
|
98
130
|
`adaptableOptions.ts`, `gridOptions.ts`, `agGridModules.ts`, `licenses.ts` and
|
|
99
131
|
`onAdaptableReady.ts` into the framework's source folder, pins the paired
|
|
100
132
|
dependencies in `package.json`, and writes the `AGENTS.md` snippet when the
|
|
@@ -113,7 +145,7 @@ confirmed columns (column ids and Scopes change; shapes come from the demo),
|
|
|
113
145
|
and validate the merged Initial State:
|
|
114
146
|
|
|
115
147
|
```bash
|
|
116
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
148
|
+
npx -y @adaptabletools/adaptable-mcp@^0 check state <adaptableOptions file> --columns <columnDefs file>
|
|
117
149
|
```
|
|
118
150
|
|
|
119
151
|
**Ask** which suggestions to include (default: none — a clean minimal grid
|
|
@@ -1 +1 @@
|
|
|
1
|
-
0.1.0
|
|
1
|
+
0.1.0
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
<!-- BEGIN:adaptable-agent-rules -->
|
|
2
|
-
AdapTable (`@adaptabletools/*`) is used in this project. Its Options, State shapes, API and AdapTableQL change between majors, so do not rely on recalled knowledge. Before writing or changing AdapTable code use the `adaptable-dev` skill; for first-time integration `adaptable-setup`; for a misbehaving running grid `adaptable-debug`; for version upgrades `adaptable-upgrade`. Validate State, expressions and setup with `npx -y @adaptabletools/adaptable-mcp
|
|
2
|
+
AdapTable (`@adaptabletools/*`) is used in this project. Its Options, State shapes, API and AdapTableQL change between majors, so do not rely on recalled knowledge. Before writing or changing AdapTable code use the `adaptable-dev` skill; for first-time integration `adaptable-setup`; for a misbehaving running grid `adaptable-debug`; for version upgrades `adaptable-upgrade`. Validate State, expressions and setup with `npx -y @adaptabletools/adaptable-mcp@^0 check …` (or the `check_*` MCP tools when configured); read the docs for the installed version with `npx -y @adaptabletools/adaptable-mcp@^0 docs search "<topic>"`. The columnDefs, gridOptions and AG Grid modules of an AdapTable grid are covered by these skills too; consult the `ag-dev` / `ag-update` skills or AG Grid's documentation only for what the AdapTable docs and checks do not cover.
|
|
3
3
|
<!-- END:adaptable-agent-rules -->
|
|
@@ -29,7 +29,7 @@ Every capability of `@adaptabletools/adaptable-mcp` (response schema 1) has a CL
|
|
|
29
29
|
|
|
30
30
|
## Choosing a binding
|
|
31
31
|
|
|
32
|
-
- Prefer the MCP tool when the harness has the `adaptable` MCP server configured. Otherwise run the CLI command as `npx -y @adaptabletools/adaptable-mcp
|
|
32
|
+
- Prefer the MCP tool when the harness has the `adaptable` MCP server configured. Otherwise run the CLI command as `npx -y @adaptabletools/adaptable-mcp@^0 <command> [options]`; add `--json` to read fields instead of Markdown.
|
|
33
33
|
- If neither binding exists for what you need — the capability is not in this table, not in `adaptable --capabilities`, or not in the MCP tool list — say so and fall back to the docs (see `docs-protocol.md`). Never improvise the result a missing capability would have produced.
|
|
34
34
|
- All bindings return the same envelope: `ok`, `data`, `issues`, `warnings`, and on failure `error { code, message, hint }`. CLI exit codes: `0` ok, `1` findings, `2` usage, `3` environment.
|
|
35
35
|
- Skill scripts cannot reach the agent's MCP session: a script only ever runs the CLI. When the CLI is unavailable, the agent performs the fallback itself.
|
|
@@ -7,7 +7,7 @@ or diagnosing anything, establish what is actually installed.
|
|
|
7
7
|
## 1. Detect the project
|
|
8
8
|
|
|
9
9
|
```bash
|
|
10
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
10
|
+
npx -y @adaptabletools/adaptable-mcp@^0 detect --json
|
|
11
11
|
```
|
|
12
12
|
|
|
13
13
|
(or the `detect_environment` MCP tool when the `adaptable` MCP server is
|
|
@@ -45,10 +45,26 @@ AdapTable N, not M". Pass `--docs-host https://<branch>.adaptabletools.com`
|
|
|
45
45
|
(or set `ADAPTABLE_MCP_DOCS_HOST`) on every command from then on so each
|
|
46
46
|
lookup below reads the pre-release docs.
|
|
47
47
|
|
|
48
|
-
## 3. AG Grid
|
|
48
|
+
## 3. AG Grid: AdapTable first
|
|
49
49
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
50
|
+
AdapTable sets its own rules for the AG Grid side of the grid it runs on, so
|
|
51
|
+
that work stays in these skills too. Column definitions follow the ownership
|
|
52
|
+
matrix in adaptable-dev (`cellDataType` and column ids stay in the ColDef;
|
|
53
|
+
layout, styling and derived values move to State); `gridOptions`, AG Grid
|
|
54
|
+
modules and the AG Grid version pairing are covered by `check setup` and
|
|
55
|
+
`compat`; runtime calls go through `adaptableApi` before `gridApi`. Use the
|
|
56
|
+
AdapTable docs, demos and checks for all of it.
|
|
57
|
+
|
|
58
|
+
Fall back to AG Grid only when one of these holds:
|
|
59
|
+
|
|
60
|
+
- the AdapTable docs say nothing about an AG Grid-only property or API the
|
|
61
|
+
task needs;
|
|
62
|
+
- a problem stays inside AG Grid: an AG Grid console error, or an AG Grid
|
|
63
|
+
type error after a version bump.
|
|
64
|
+
|
|
65
|
+
Then use the `ag-dev` / `ag-update` skills when `detect` reports them
|
|
66
|
+
installed, otherwise AG Grid's documentation (or the AG Grid MCP server when
|
|
67
|
+
it is configured). Whatever comes back goes through `check setup` /
|
|
68
|
+
`check state` like any other change, and AdapTable ownership wins over AG
|
|
69
|
+
Grid guidance: a suggested ColDef `hide`, `pinned` or `cellStyle` becomes a
|
|
70
|
+
Layout or a Format Column instead.
|
|
@@ -61,7 +61,7 @@ silently — a stale SCOPE from another target poisons every later phase.
|
|
|
61
61
|
### Phase 3 — Scope → `ADAPTABLE_UPGRADE_SCOPE.md`
|
|
62
62
|
|
|
63
63
|
```bash
|
|
64
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
64
|
+
npx -y @adaptabletools/adaptable-mcp@^0 detect --all-projects --json
|
|
65
65
|
```
|
|
66
66
|
|
|
67
67
|
Record per project: path, framework and wrapper package, AdapTable range and
|
|
@@ -79,8 +79,8 @@ run against such a project.
|
|
|
79
79
|
manifest reports:
|
|
80
80
|
|
|
81
81
|
```bash
|
|
82
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
83
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
82
|
+
npx -y @adaptabletools/adaptable-mcp@^0 compat --adaptable <target>
|
|
83
|
+
npx -y @adaptabletools/adaptable-mcp@^0 compat --adaptable <target> --ag-grid <installed AG Grid major>
|
|
84
84
|
```
|
|
85
85
|
|
|
86
86
|
`compat` returns the target's AG Grid pairing, wrapper packages and
|
|
@@ -134,7 +134,7 @@ index) is the CLI's own chrome: read it, act on the warnings, leave it out
|
|
|
134
134
|
of the plan.
|
|
135
135
|
|
|
136
136
|
```bash
|
|
137
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
137
|
+
npx -y @adaptabletools/adaptable-mcp@^0 changes --from <current> --to <target> \
|
|
138
138
|
--repo <repository root> --projects <project folders from SCOPE> --with-docs
|
|
139
139
|
```
|
|
140
140
|
|
|
@@ -159,7 +159,7 @@ Then, for every file in each project's `initialStateLiterals`:
|
|
|
159
159
|
|
|
160
160
|
```bash
|
|
161
161
|
mkdir -p ADAPTABLE_UPGRADE_STATE
|
|
162
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
162
|
+
npx -y @adaptabletools/adaptable-mcp@^0 migrate state <project>/<file> --from <current> --to <target> \
|
|
163
163
|
--kind initial --columns <project>/<columnDefs file> --out ADAPTABLE_UPGRADE_STATE/<project>--<file>.json \
|
|
164
164
|
> ADAPTABLE_UPGRADE_STATE/<project>--<file>.md
|
|
165
165
|
```
|
|
@@ -1 +1 @@
|
|
|
1
|
-
0.1.0
|
|
1
|
+
0.1.0
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
<!-- BEGIN:adaptable-agent-rules -->
|
|
2
|
-
AdapTable (`@adaptabletools/*`) is used in this project. Its Options, State shapes, API and AdapTableQL change between majors, so do not rely on recalled knowledge. Before writing or changing AdapTable code use the `adaptable-dev` skill; for first-time integration `adaptable-setup`; for a misbehaving running grid `adaptable-debug`; for version upgrades `adaptable-upgrade`. Validate State, expressions and setup with `npx -y @adaptabletools/adaptable-mcp
|
|
2
|
+
AdapTable (`@adaptabletools/*`) is used in this project. Its Options, State shapes, API and AdapTableQL change between majors, so do not rely on recalled knowledge. Before writing or changing AdapTable code use the `adaptable-dev` skill; for first-time integration `adaptable-setup`; for a misbehaving running grid `adaptable-debug`; for version upgrades `adaptable-upgrade`. Validate State, expressions and setup with `npx -y @adaptabletools/adaptable-mcp@^0 check …` (or the `check_*` MCP tools when configured); read the docs for the installed version with `npx -y @adaptabletools/adaptable-mcp@^0 docs search "<topic>"`. The columnDefs, gridOptions and AG Grid modules of an AdapTable grid are covered by these skills too; consult the `ag-dev` / `ag-update` skills or AG Grid's documentation only for what the AdapTable docs and checks do not cover.
|
|
3
3
|
<!-- END:adaptable-agent-rules -->
|
|
@@ -29,7 +29,7 @@ Every capability of `@adaptabletools/adaptable-mcp` (response schema 1) has a CL
|
|
|
29
29
|
|
|
30
30
|
## Choosing a binding
|
|
31
31
|
|
|
32
|
-
- Prefer the MCP tool when the harness has the `adaptable` MCP server configured. Otherwise run the CLI command as `npx -y @adaptabletools/adaptable-mcp
|
|
32
|
+
- Prefer the MCP tool when the harness has the `adaptable` MCP server configured. Otherwise run the CLI command as `npx -y @adaptabletools/adaptable-mcp@^0 <command> [options]`; add `--json` to read fields instead of Markdown.
|
|
33
33
|
- If neither binding exists for what you need — the capability is not in this table, not in `adaptable --capabilities`, or not in the MCP tool list — say so and fall back to the docs (see `docs-protocol.md`). Never improvise the result a missing capability would have produced.
|
|
34
34
|
- All bindings return the same envelope: `ok`, `data`, `issues`, `warnings`, and on failure `error { code, message, hint }`. CLI exit codes: `0` ok, `1` findings, `2` usage, `3` environment.
|
|
35
35
|
- Skill scripts cannot reach the agent's MCP session: a script only ever runs the CLI. When the CLI is unavailable, the agent performs the fallback itself.
|
|
@@ -7,7 +7,7 @@ or diagnosing anything, establish what is actually installed.
|
|
|
7
7
|
## 1. Detect the project
|
|
8
8
|
|
|
9
9
|
```bash
|
|
10
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
10
|
+
npx -y @adaptabletools/adaptable-mcp@^0 detect --json
|
|
11
11
|
```
|
|
12
12
|
|
|
13
13
|
(or the `detect_environment` MCP tool when the `adaptable` MCP server is
|
|
@@ -45,10 +45,26 @@ AdapTable N, not M". Pass `--docs-host https://<branch>.adaptabletools.com`
|
|
|
45
45
|
(or set `ADAPTABLE_MCP_DOCS_HOST`) on every command from then on so each
|
|
46
46
|
lookup below reads the pre-release docs.
|
|
47
47
|
|
|
48
|
-
## 3. AG Grid
|
|
48
|
+
## 3. AG Grid: AdapTable first
|
|
49
49
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
50
|
+
AdapTable sets its own rules for the AG Grid side of the grid it runs on, so
|
|
51
|
+
that work stays in these skills too. Column definitions follow the ownership
|
|
52
|
+
matrix in adaptable-dev (`cellDataType` and column ids stay in the ColDef;
|
|
53
|
+
layout, styling and derived values move to State); `gridOptions`, AG Grid
|
|
54
|
+
modules and the AG Grid version pairing are covered by `check setup` and
|
|
55
|
+
`compat`; runtime calls go through `adaptableApi` before `gridApi`. Use the
|
|
56
|
+
AdapTable docs, demos and checks for all of it.
|
|
57
|
+
|
|
58
|
+
Fall back to AG Grid only when one of these holds:
|
|
59
|
+
|
|
60
|
+
- the AdapTable docs say nothing about an AG Grid-only property or API the
|
|
61
|
+
task needs;
|
|
62
|
+
- a problem stays inside AG Grid: an AG Grid console error, or an AG Grid
|
|
63
|
+
type error after a version bump.
|
|
64
|
+
|
|
65
|
+
Then use the `ag-dev` / `ag-update` skills when `detect` reports them
|
|
66
|
+
installed, otherwise AG Grid's documentation (or the AG Grid MCP server when
|
|
67
|
+
it is configured). Whatever comes back goes through `check setup` /
|
|
68
|
+
`check state` like any other change, and AdapTable ownership wins over AG
|
|
69
|
+
Grid guidance: a suggested ColDef `hide`, `pinned` or `cellStyle` becomes a
|
|
70
|
+
Layout or a Format Column instead.
|
|
@@ -16,12 +16,10 @@ files are not edited in apply mode.
|
|
|
16
16
|
## 1. Packages
|
|
17
17
|
|
|
18
18
|
1. **AG Grid**, per SCOPE's `## AG Grid plan`:
|
|
19
|
-
- *
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
AG Grid's own breaking changes are the user's; name the guide, do not
|
|
24
|
-
run AG Grid's codemod from here.
|
|
19
|
+
- *bump in this plan*: set every `ag-grid-*` package (and `ag-charts-*`
|
|
20
|
+
when present) to the version SCOPE names, same version for all of them.
|
|
21
|
+
Do not run AG Grid's codemod from here; AG Grid's own breaking changes
|
|
22
|
+
are handled in step 4.
|
|
25
23
|
- *already handled*: check `package.json` carries the pairing; if it does
|
|
26
24
|
not, stop and tell the user — nothing below works against a mismatched
|
|
27
25
|
AG Grid.
|
|
@@ -70,7 +68,7 @@ say so in the report.
|
|
|
70
68
|
payload, a test — are not reached by State migration. Rewrite each one:
|
|
71
69
|
|
|
72
70
|
```bash
|
|
73
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
71
|
+
npx -y @adaptabletools/adaptable-mcp@^0 migrate expression "<expression>" --from <n> --to <m> --module <Module> --columns <columnDefs file>
|
|
74
72
|
```
|
|
75
73
|
|
|
76
74
|
The output carries `original`, `migrated`, `changed` and, for targets 24
|
|
@@ -98,9 +96,9 @@ The validation loop applies (three rounds at most, then the remaining
|
|
|
98
96
|
issues verbatim):
|
|
99
97
|
|
|
100
98
|
```bash
|
|
101
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
102
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
103
|
-
npx -y @adaptabletools/adaptable-mcp
|
|
99
|
+
npx -y @adaptabletools/adaptable-mcp@^0 check state <file with the literal> --major <target> --columns <columnDefs file>
|
|
100
|
+
npx -y @adaptabletools/adaptable-mcp@^0 check expression "<rewritten string>" --module <Module> --columns <columnDefs file>
|
|
101
|
+
npx -y @adaptabletools/adaptable-mcp@^0 check setup
|
|
104
102
|
```
|
|
105
103
|
|
|
106
104
|
- `check state` on every rewritten literal — the shape against the target
|
|
@@ -113,7 +111,11 @@ npx -y @adaptabletools/adaptable-mcp@canary check setup
|
|
|
113
111
|
the packages, AG Grid modules, wrapper wiring, ColDef ownership.
|
|
114
112
|
- Then the project's own type-check and build. Type errors at this point are
|
|
115
113
|
usually a record applied to one match and not another: search the plan
|
|
116
|
-
for the identifier before reading the codebase.
|
|
114
|
+
for the identifier before reading the codebase. An error the plan does not
|
|
115
|
+
explain and that names an AG Grid identifier (a ColDef or `gridOptions`
|
|
116
|
+
property, a grid API call, an AG Grid type) is one of AG Grid's own
|
|
117
|
+
breaking changes: resolve it through the AG Grid fallback (grounding) and
|
|
118
|
+
list it in the report.
|
|
117
119
|
|
|
118
120
|
## 5. Run and read the console
|
|
119
121
|
|
|
@@ -11,7 +11,7 @@ import { spawnSync } from 'node:child_process';
|
|
|
11
11
|
|
|
12
12
|
const windows = process.platform === 'win32';
|
|
13
13
|
const override = process.env.ADAPTABLE_CLI?.trim();
|
|
14
|
-
const [command, ...lead] = override ? override.split(/\s+/) : [windows ? 'npx.cmd' : 'npx', '-y', '@adaptabletools/adaptable-mcp
|
|
14
|
+
const [command, ...lead] = override ? override.split(/\s+/) : [windows ? 'npx.cmd' : 'npx', '-y', '@adaptabletools/adaptable-mcp@^0'];
|
|
15
15
|
const result = spawnSync(command, [...lead, ...process.argv.slice(2)], {
|
|
16
16
|
stdio: 'inherit',
|
|
17
17
|
shell: windows,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adaptabletools/adaptable-mcp",
|
|
3
|
-
"version": "0.1.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"description": "AdapTable CLI and MCP server for coding agents: version-matched docs, State and AdapTableQL checks, migration, scaffolding",
|
|
5
5
|
"homepage": "https://www.adaptabletools.com/",
|
|
6
6
|
"license": "contact sales@adaptabletools.com for details",
|