@dataworks-technology/cli 1.2.0 → 1.4.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/.agents/plugins/marketplace.json +20 -0
- package/.claude-plugin/marketplace.json +16 -0
- package/README.md +85 -2
- package/bin/mcp.js +9 -0
- package/bin/postinstall.js +23 -0
- package/dist/commands/agents/install.d.ts +17 -0
- package/dist/commands/agents/install.d.ts.map +1 -0
- package/dist/commands/agents/install.js +57 -0
- package/dist/commands/agents/install.js.map +1 -0
- package/dist/commands/agents/reminder.d.ts +16 -0
- package/dist/commands/agents/reminder.d.ts.map +1 -0
- package/dist/commands/agents/reminder.js +45 -0
- package/dist/commands/agents/reminder.js.map +1 -0
- package/dist/commands/commands.d.ts.map +1 -1
- package/dist/commands/commands.js +2 -0
- package/dist/commands/commands.js.map +1 -1
- package/dist/generated/metrics.d.ts +15 -0
- package/dist/generated/metrics.d.ts.map +1 -0
- package/dist/generated/metrics.js +131 -0
- package/dist/generated/metrics.js.map +1 -0
- package/dist/lib/agent-install.d.ts +24 -0
- package/dist/lib/agent-install.d.ts.map +1 -0
- package/dist/lib/agent-install.js +196 -0
- package/dist/lib/agent-install.js.map +1 -0
- package/dist/lib/agent-reminder.d.ts +17 -0
- package/dist/lib/agent-reminder.d.ts.map +1 -0
- package/dist/lib/agent-reminder.js +81 -0
- package/dist/lib/agent-reminder.js.map +1 -0
- package/dist/lib/command.d.ts +1 -0
- package/dist/lib/command.d.ts.map +1 -1
- package/dist/lib/command.js +5 -0
- package/dist/lib/command.js.map +1 -1
- package/dist/lib/metric-names.d.ts +29 -0
- package/dist/lib/metric-names.d.ts.map +1 -0
- package/dist/lib/metric-names.js +171 -0
- package/dist/lib/metric-names.js.map +1 -0
- package/dist/lib/query-metrics.d.ts +73 -0
- package/dist/lib/query-metrics.d.ts.map +1 -0
- package/dist/lib/query-metrics.js +374 -0
- package/dist/lib/query-metrics.js.map +1 -0
- package/dist/mcp/main.d.ts +2 -0
- package/dist/mcp/main.d.ts.map +1 -0
- package/dist/mcp/main.js +7 -0
- package/dist/mcp/main.js.map +1 -0
- package/dist/mcp/server.d.ts +85 -0
- package/dist/mcp/server.d.ts.map +1 -0
- package/dist/mcp/server.js +248 -0
- package/dist/mcp/server.js.map +1 -0
- package/oclif.manifest.json +872 -759
- package/package.json +22 -8
- package/plugins/dataworks/.claude-plugin/plugin.json +10 -0
- package/plugins/dataworks/.codex-plugin/plugin.json +27 -0
- package/plugins/dataworks/.mcp.json +8 -0
- package/plugins/dataworks/skills/query-dataworks-metrics/SKILL.md +70 -0
- package/plugins/dataworks/skills/query-dataworks-metrics/agents/openai.yaml +13 -0
- package/skills/dataworks-cli/SKILL.md +18 -2
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "dataworks-cli",
|
|
3
|
+
"interface": {
|
|
4
|
+
"displayName": "Dataworks CLI"
|
|
5
|
+
},
|
|
6
|
+
"plugins": [
|
|
7
|
+
{
|
|
8
|
+
"name": "dataworks",
|
|
9
|
+
"source": {
|
|
10
|
+
"source": "local",
|
|
11
|
+
"path": "./plugins/dataworks"
|
|
12
|
+
},
|
|
13
|
+
"policy": {
|
|
14
|
+
"installation": "AVAILABLE",
|
|
15
|
+
"authentication": "ON_INSTALL"
|
|
16
|
+
},
|
|
17
|
+
"category": "Data"
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "dataworks-cli",
|
|
3
|
+
"owner": {
|
|
4
|
+
"name": "Dataworks Technology"
|
|
5
|
+
},
|
|
6
|
+
"metadata": {
|
|
7
|
+
"description": "Official Dataworks CLI integrations for Claude Code"
|
|
8
|
+
},
|
|
9
|
+
"plugins": [
|
|
10
|
+
{
|
|
11
|
+
"name": "dataworks",
|
|
12
|
+
"source": "./plugins/dataworks",
|
|
13
|
+
"description": "Query Dataworks athlete metrics using the authenticated local CLI session"
|
|
14
|
+
}
|
|
15
|
+
]
|
|
16
|
+
}
|
package/README.md
CHANGED
|
@@ -22,6 +22,7 @@ The `dw` binary turns the public GraphQL contract published by `@dataworks-techn
|
|
|
22
22
|
|
|
23
23
|
| Command | Description |
|
|
24
24
|
| --------------------- | ----------------------------------------------------------- |
|
|
25
|
+
| `dw agents install` | Install the Dataworks skill and MCP tools for AI agents |
|
|
25
26
|
| `dw auth ...` | Log in, log out, and inspect the active UAT or Live session |
|
|
26
27
|
| `dw autocomplete` | Install shell completion for commands and flags |
|
|
27
28
|
| `dw data ...` | Run schema-derived queries, mutations, and subscriptions |
|
|
@@ -39,6 +40,12 @@ The `dw` binary turns the public GraphQL contract published by `@dataworks-techn
|
|
|
39
40
|
- [Node.js](https://nodejs.org/) 22 or newer to run the published CLI
|
|
40
41
|
- A Dataworks account
|
|
41
42
|
- [Bun](https://bun.sh/) for repository development
|
|
43
|
+
- For repository development only: AWS credentials with CodeArtifact read access.
|
|
44
|
+
`bun install` runs a `preinstall` hook that fetches a token for the private
|
|
45
|
+
`@dataworks/sdk` devDependency, which supplies the metric catalogue. Use
|
|
46
|
+
`AWS_PROFILE=your-profile-name bun install` for a non-default profile, and
|
|
47
|
+
`bun run sdk` to refresh an expired token. Installing the published CLI needs
|
|
48
|
+
none of this.
|
|
42
49
|
|
|
43
50
|
---
|
|
44
51
|
|
|
@@ -86,6 +93,23 @@ The `dw` binary turns the public GraphQL contract published by `@dataworks-techn
|
|
|
86
93
|
|
|
87
94
|
Generated command documentation is available in [`docs/commands`](./docs/commands/README.md).
|
|
88
95
|
|
|
96
|
+
5. **Enable Dataworks in Codex or Claude Code:**
|
|
97
|
+
|
|
98
|
+
```sh
|
|
99
|
+
dw agents install
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
This detects supported clients and installs the complete Dataworks plugin:
|
|
103
|
+
the metric-query skill plus its read-only `query_metrics` MCP server. Start a
|
|
104
|
+
new Codex thread after installation. In Claude Code, run `/reload-plugins` or
|
|
105
|
+
start a new session. To configure only one client, use
|
|
106
|
+
`dw agents install codex` or `dw agents install claude-code`.
|
|
107
|
+
|
|
108
|
+
Until setup is completed, interactive CLI use prints this reminder at most
|
|
109
|
+
once every 24 hours. It never appears with `--json`. Permanently hide it with
|
|
110
|
+
`dw agents reminder disable`, restore it with `dw agents reminder enable`, or
|
|
111
|
+
set `DW_NO_AGENT_REMINDER=1` for a single process or automation environment.
|
|
112
|
+
|
|
89
113
|
---
|
|
90
114
|
|
|
91
115
|
## Bash autocomplete
|
|
@@ -96,10 +120,66 @@ Generate the completion cache and print the one-time Bash setup instructions:
|
|
|
96
120
|
dw autocomplete bash
|
|
97
121
|
```
|
|
98
122
|
|
|
123
|
+
Global npm installs and upgrades run this command automatically. It prepares the
|
|
124
|
+
latest completion cache and prints the setup instruction, but does not edit your
|
|
125
|
+
shell startup files. If npm cannot access the shell cache, installation still
|
|
126
|
+
succeeds and you can retry with `dw autocomplete bash`.
|
|
127
|
+
|
|
99
128
|
After following the displayed instruction and reloading Bash, press Tab to
|
|
100
129
|
complete `dw` command names and flags. Run `dw autocomplete --refresh-cache`
|
|
101
130
|
after installing a release that adds commands.
|
|
102
131
|
|
|
132
|
+
## AI agent metric queries
|
|
133
|
+
|
|
134
|
+
The package includes a focused, read-only MCP server with one tool:
|
|
135
|
+
`query_metrics`. It uses the same OS-backed login session and selected tenant as
|
|
136
|
+
`dw`, resolves an athlete by exact ID or unique name, resolves metric names
|
|
137
|
+
against the canonical Dataworks catalogue, polls asynchronous Data Explorer
|
|
138
|
+
queries, and returns normalized structured rows. GPS values include decoded
|
|
139
|
+
latitude and longitude; heart-rate values use numeric BPM when valid.
|
|
140
|
+
|
|
141
|
+
Metric wording is matched case-, space-, hyphen- and underscore-insensitively,
|
|
142
|
+
so “Heart Rate” resolves to `heartrate`, alongside aliases such as `gps`, `hr`,
|
|
143
|
+
and `watts`. An unrecognized name returns the closest canonical candidates
|
|
144
|
+
rather than a bare rejection.
|
|
145
|
+
|
|
146
|
+
The simplest setup for Codex and Claude Code is:
|
|
147
|
+
|
|
148
|
+
```sh
|
|
149
|
+
dw agents install
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
The command is safe to rerun after upgrades. It installs or updates the complete
|
|
153
|
+
Dataworks plugin for each detected client and reports the reload or restart step.
|
|
154
|
+
If an old marketplace registration points to a different CLI installation, rerun
|
|
155
|
+
with `--force`.
|
|
156
|
+
|
|
157
|
+
Successful setup automatically disables the periodic CLI reminder. To opt out
|
|
158
|
+
without installing an agent integration, run `dw agents reminder disable`.
|
|
159
|
+
|
|
160
|
+
Other MCP clients can launch the installed `dw-mcp` binary directly:
|
|
161
|
+
|
|
162
|
+
```json
|
|
163
|
+
{
|
|
164
|
+
"mcpServers": {
|
|
165
|
+
"dataworks": {
|
|
166
|
+
"command": "dw-mcp",
|
|
167
|
+
"args": []
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
The npm package ships a cross-compatible Codex and Claude Code plugin at
|
|
174
|
+
`plugins/dataworks`. Its focused skill turns requests such as “give me the last
|
|
175
|
+
30 GPS values for James Haigh” into a `query_metrics` call. The tool accepts
|
|
176
|
+
exactly one of `athlete_id` or `athlete_name`, plus `metric`; optional inputs are
|
|
177
|
+
`limit`, `order`, `from`, `to`, `event_id`, `dataset_datasource_id`,
|
|
178
|
+
`tenant_id`, `metric_category`, and `timeout_ms`.
|
|
179
|
+
|
|
180
|
+
The server never performs mutations. If name resolution is ambiguous, it
|
|
181
|
+
returns candidates and requires an explicit athlete ID rather than guessing.
|
|
182
|
+
|
|
103
183
|
---
|
|
104
184
|
|
|
105
185
|
## Output and Safety
|
|
@@ -206,6 +286,7 @@ an array; default table output performs that decoding for humans.
|
|
|
206
286
|
| Command | Description |
|
|
207
287
|
| ------------------------------- | ------------------------------------------------------------------- |
|
|
208
288
|
| `bun install --frozen-lockfile` | Install development dependencies |
|
|
289
|
+
| `bun run sdk` | Refresh the CodeArtifact token used to fetch `@dataworks/sdk` |
|
|
209
290
|
| `bun run dev --help` | Run the TypeScript development CLI |
|
|
210
291
|
| `bun run generate` | Regenerate schema-derived commands and Markdown |
|
|
211
292
|
| `bun run generate:check` | Verify generated files are current |
|
|
@@ -223,9 +304,11 @@ The Data Engine SDK publishes a filtered public GraphQL schema and a versioned c
|
|
|
223
304
|
|
|
224
305
|
Files under `src/generated/`, `src/commands/data/`, and `docs/commands/` are generated. Change [`schema/operation-overrides.json`](./schema/operation-overrides.json), [`scripts/generate-commands.ts`](./scripts/generate-commands.ts), or the upstream public schema instead of editing generated files.
|
|
225
306
|
|
|
226
|
-
|
|
307
|
+
Canonical metric names are generated the same way. [`scripts/generate-metrics.ts`](./scripts/generate-metrics.ts) reads `metricConfig` from the private `@dataworks/sdk` devDependency and emits `src/generated/metrics.ts` and the catalogue block in the `query-dataworks-metrics` skill. To add a metric, change the SDK — not the generated files, and not the alias layer in `src/lib/metric-names.ts`.
|
|
308
|
+
|
|
309
|
+
The daily SDK maintenance workflow checks for new `@dataworks-technology/data` and `@dataworks/sdk` versions. Deterministic generation runs first; if compatibility work is required, a constrained LiteLLM maintenance agent prepares a draft pull request for human review.
|
|
227
310
|
|
|
228
|
-
See [architecture](./docs/architecture.md), [automated SDK maintenance](./docs/maintenance.md), [security](./docs/security.md), and [releasing](./docs/releasing.md) for details.
|
|
311
|
+
See [architecture](./docs/architecture.md), [contributing](./docs/contributing.md), [automated SDK maintenance](./docs/maintenance.md), [security](./docs/security.md), and [releasing](./docs/releasing.md) for details.
|
|
229
312
|
|
|
230
313
|
---
|
|
231
314
|
|
package/bin/mcp.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { runDataworksMcpServer } from "../dist/mcp/main.js";
|
|
3
|
+
|
|
4
|
+
runDataworksMcpServer().catch((error) => {
|
|
5
|
+
process.stderr.write(
|
|
6
|
+
`Dataworks MCP server failed: ${error instanceof Error ? error.message : String(error)}\n`,
|
|
7
|
+
);
|
|
8
|
+
process.exitCode = 1;
|
|
9
|
+
});
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { spawnSync } from "node:child_process";
|
|
3
|
+
import { fileURLToPath } from "node:url";
|
|
4
|
+
|
|
5
|
+
// npm runs postinstall for both first-time global installs and global upgrades.
|
|
6
|
+
// Avoid writing shell caches when this package is only a project dependency.
|
|
7
|
+
if (
|
|
8
|
+
process.env.npm_config_global === "true" ||
|
|
9
|
+
process.env.npm_config_location === "global"
|
|
10
|
+
) {
|
|
11
|
+
const runPath = fileURLToPath(new URL("./run.js", import.meta.url));
|
|
12
|
+
const result = spawnSync(process.execPath, [runPath, "autocomplete", "bash"], {
|
|
13
|
+
stdio: "inherit",
|
|
14
|
+
});
|
|
15
|
+
if (result.error || result.status !== 0) {
|
|
16
|
+
process.stderr.write(
|
|
17
|
+
"Dataworks CLI installed, but Bash autocomplete setup could not be prepared. Run `dw autocomplete bash` to retry.\n",
|
|
18
|
+
);
|
|
19
|
+
}
|
|
20
|
+
process.stdout.write(
|
|
21
|
+
"To use Dataworks from Codex or Claude Code, run `dw agents install` once.\n",
|
|
22
|
+
);
|
|
23
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { DataworksCommand } from "../../lib/command.js";
|
|
2
|
+
export default class AgentsInstall extends DataworksCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: {
|
|
5
|
+
description: string;
|
|
6
|
+
command: string;
|
|
7
|
+
}[];
|
|
8
|
+
static args: {
|
|
9
|
+
client: import("@oclif/core/interfaces").Arg<string | undefined, Record<string, unknown>>;
|
|
10
|
+
};
|
|
11
|
+
static flags: {
|
|
12
|
+
force: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
13
|
+
json: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
14
|
+
};
|
|
15
|
+
run(): Promise<void>;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=install.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"install.d.ts","sourceRoot":"","sources":["../../../src/commands/agents/install.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AASxD,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,gBAAgB;IACzD,OAAgB,WAAW,SAC2D;IACtF,OAAgB,QAAQ;;;QAiBtB;IACF,OAAgB,IAAI;;MAMlB;IACF,OAAgB,KAAK;;;MAKnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CA4BlC"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { Args, Flags } from "@oclif/core";
|
|
2
|
+
import { DataworksCommand } from "../../lib/command.js";
|
|
3
|
+
import { installAgentIntegration, supportedAgentClients, } from "../../lib/agent-install.js";
|
|
4
|
+
import { writeResult } from "../../lib/output.js";
|
|
5
|
+
import { configureAgentReminder } from "../../lib/agent-reminder.js";
|
|
6
|
+
export default class AgentsInstall extends DataworksCommand {
|
|
7
|
+
static description = "Install the Dataworks skill and query_metrics MCP server for Codex or Claude Code";
|
|
8
|
+
static examples = [
|
|
9
|
+
{
|
|
10
|
+
description: "Set up every supported agent client found on this machine",
|
|
11
|
+
command: "dw agents install",
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
description: "Set up Codex only",
|
|
15
|
+
command: "dw agents install codex",
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
description: "Set up Claude Code only",
|
|
19
|
+
command: "dw agents install claude-code",
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
description: "Replace a stale Dataworks marketplace registration",
|
|
23
|
+
command: "dw agents install codex --force",
|
|
24
|
+
},
|
|
25
|
+
];
|
|
26
|
+
static args = {
|
|
27
|
+
client: Args.string({
|
|
28
|
+
description: "Agent client to configure; omit to detect and configure both",
|
|
29
|
+
options: ["codex", "claude-code"],
|
|
30
|
+
required: false,
|
|
31
|
+
}),
|
|
32
|
+
};
|
|
33
|
+
static flags = {
|
|
34
|
+
force: Flags.boolean({
|
|
35
|
+
description: "Replace an existing Dataworks marketplace registration",
|
|
36
|
+
}),
|
|
37
|
+
json: Flags.boolean({ description: "Emit stable JSON output" }),
|
|
38
|
+
};
|
|
39
|
+
async run() {
|
|
40
|
+
const { args, flags } = await this.parse(AgentsInstall);
|
|
41
|
+
const clients = args.client ? [args.client] : supportedAgentClients;
|
|
42
|
+
const results = clients.map((client) => installAgentIntegration(client, { force: flags.force }));
|
|
43
|
+
if (results.some(({ status }) => status === "installed" || status === "updated")) {
|
|
44
|
+
await configureAgentReminder("configured");
|
|
45
|
+
}
|
|
46
|
+
writeResult({ integrations: results }, {
|
|
47
|
+
json: flags.json,
|
|
48
|
+
meta: {
|
|
49
|
+
restartRequired: results.some(({ status }) => status === "installed" || status === "updated"),
|
|
50
|
+
},
|
|
51
|
+
});
|
|
52
|
+
if (results.every(({ status }) => status === "unavailable" || status === "failed")) {
|
|
53
|
+
process.exitCode = 1;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=install.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"install.js","sourceRoot":"","sources":["../../../src/commands/agents/install.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AACxD,OAAO,EACL,uBAAuB,EACvB,qBAAqB,GAEtB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAErE,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,gBAAgB;IACzD,MAAM,CAAU,WAAW,GACzB,mFAAmF,CAAC;IACtF,MAAM,CAAU,QAA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sB,CAAC,YAAY,CAAC,CAAC;QAC7C,CAAC;QAED,WAAW,CACT,EAAE,YAAY,EAAE,OAAO,EAAE,EACzB;YACE,IAAI,EAAE,KAAK,CAAC,IAAI;YAChB,IAAI,EAAE;gBACJ,eAAe,EAAE,OAAO,CAAC,IAAI,CAC3B,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,MAAM,KAAK,WAAW,IAAI,MAAM,KAAK,SAAS,CAC/D;aACF;SACF,CACF,CAAC;QAEF,IACE,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,MAAM,KAAK,aAAa,IAAI,MAAM,KAAK,QAAQ,CAAC,EAC9E,CAAC;YACD,OAAO,CAAC,QAAQ,GAAG,CAAC,CAAC;QACvB,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { DataworksCommand } from "../../lib/command.js";
|
|
2
|
+
export default class AgentsReminder extends DataworksCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: {
|
|
5
|
+
description: string;
|
|
6
|
+
command: string;
|
|
7
|
+
}[];
|
|
8
|
+
static args: {
|
|
9
|
+
action: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
10
|
+
};
|
|
11
|
+
static flags: {
|
|
12
|
+
json: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
13
|
+
};
|
|
14
|
+
run(): Promise<void>;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=reminder.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reminder.d.ts","sourceRoot":"","sources":["../../../src/commands/agents/reminder.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AASxD,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,gBAAgB;IAC1D,OAAgB,WAAW,SACwC;IACnE,OAAgB,QAAQ;;;QAatB;IACF,OAAgB,IAAI;;MAMlB;IACF,OAAgB,KAAK;;MAEnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAiBlC"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { Args, Flags } from "@oclif/core";
|
|
2
|
+
import { DataworksCommand } from "../../lib/command.js";
|
|
3
|
+
import { configureAgentReminder, readAgentReminderPreferences, } from "../../lib/agent-reminder.js";
|
|
4
|
+
import { writeResult } from "../../lib/output.js";
|
|
5
|
+
export default class AgentsReminder extends DataworksCommand {
|
|
6
|
+
static description = "Inspect, disable, or enable the Dataworks agent setup reminder";
|
|
7
|
+
static examples = [
|
|
8
|
+
{
|
|
9
|
+
description: "Permanently hide the agent setup reminder",
|
|
10
|
+
command: "dw agents reminder disable",
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
description: "Show the reminder again when setup is incomplete",
|
|
14
|
+
command: "dw agents reminder enable",
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
description: "Inspect the current reminder state",
|
|
18
|
+
command: "dw agents reminder status --json",
|
|
19
|
+
},
|
|
20
|
+
];
|
|
21
|
+
static args = {
|
|
22
|
+
action: Args.string({
|
|
23
|
+
description: "Reminder action",
|
|
24
|
+
options: ["status", "disable", "enable"],
|
|
25
|
+
default: "status",
|
|
26
|
+
}),
|
|
27
|
+
};
|
|
28
|
+
static flags = {
|
|
29
|
+
json: Flags.boolean({ description: "Emit stable JSON output" }),
|
|
30
|
+
};
|
|
31
|
+
async run() {
|
|
32
|
+
const { args, flags } = await this.parse(AgentsReminder);
|
|
33
|
+
const action = args.action;
|
|
34
|
+
const reminder = action === "status"
|
|
35
|
+
? await readAgentReminderPreferences()
|
|
36
|
+
: await configureAgentReminder(action);
|
|
37
|
+
writeResult({
|
|
38
|
+
reminder: {
|
|
39
|
+
...reminder,
|
|
40
|
+
enabled: !reminder.disabled && !reminder.configured,
|
|
41
|
+
},
|
|
42
|
+
}, { json: flags.json });
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
//# sourceMappingURL=reminder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reminder.js","sourceRoot":"","sources":["../../../src/commands/agents/reminder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AACxD,OAAO,EACL,sBAAsB,EACtB,4BAA4B,GAC7B,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAIlD,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,gBAAgB;IAC1D,MAAM,CAAU,WAAW,GACzB,gEAAgE,CAAC;IACnE,MAAM,CAAU,QAAQ,GAAG;QACzB;YACE,WAAW,EAAE,2CAA2C;YACxD,OAAO,EAAE,4BAA4B;SACtC;QACD;YACE,WAAW,EAAE,kDAAkD;YAC/D,OAAO,EAAE,2BAA2B;SACrC;QACD;YACE,WAAW,EAAE,oCAAoC;YACjD,OAAO,EAAE,kCAAkC;SAC5C;KACF,CAAC;IACF,MAAM,CAAU,IAAI,GAAG;QACrB,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC;YAClB,WAAW,EAAE,iBAAiB;YAC9B,OAAO,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,QAAQ,CAAC;YACxC,OAAO,EAAE,QAAQ;SAClB,CAAC;KACH,CAAC;IACF,MAAM,CAAU,KAAK,GAAG;QACtB,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC,EAAE,WAAW,EAAE,yBAAyB,EAAE,CAAC;KAChE,CAAC;IAEK,KAAK,CAAC,GAAG;QACd,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;QACzD,MAAM,MAAM,GAAG,IAAI,CAAC,MAAwB,CAAC;QAC7C,MAAM,QAAQ,GACZ,MAAM,KAAK,QAAQ;YACjB,CAAC,CAAC,MAAM,4BAA4B,EAAE;YACtC,CAAC,CAAC,MAAM,sBAAsB,CAAC,MAAM,CAAC,CAAC;QAC3C,WAAW,CACT;YACE,QAAQ,EAAE;gBACR,GAAG,QAAQ;gBACX,OAAO,EAAE,CAAC,QAAQ,CAAC,QAAQ,IAAI,CAAC,QAAQ,CAAC,UAAU;aACpD;SACF,EACD,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,CACrB,CAAC;IACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../../src/commands/commands.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../../src/commands/commands.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAsBrD,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,gBAAgB;IACpD,OAAgB,WAAW,SACgC;IAC3D,OAAgB,KAAK;;MAEnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAiBlC"}
|
|
@@ -3,6 +3,8 @@ import { DataworksCommand } from "../lib/command.js";
|
|
|
3
3
|
import { operations } from "../generated/operations.js";
|
|
4
4
|
import { writeResult } from "../lib/output.js";
|
|
5
5
|
const builtIns = [
|
|
6
|
+
"agents install",
|
|
7
|
+
"agents reminder",
|
|
6
8
|
"auth login",
|
|
7
9
|
"auth logout",
|
|
8
10
|
"auth status",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"commands.js","sourceRoot":"","sources":["../../src/commands/commands.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACrD,OAAO,EAAE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AAS,EAAE,SAAS,CAAC,SAAS;aAC/B,CAAC,CAAC;SACJ,CAAC;QACF,WAAW,CAAC,IAAI,EAAE;YAChB,IAAI,EAAE,KAAK,CAAC,IAAI;YAChB,IAAI,EAAE,EAAE,cAAc,EAAE,UAAU,CAAC,MAAM,EAAE;SAC5C,CAAC,CAAC;IACL,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/** Metric categories accepted by the Data Explorer API. */
|
|
2
|
+
export type MetricCategory = "METRICS_TYPE_A" | "METRICS_TYPE_B" | "METRICS_TYPE_C";
|
|
3
|
+
/** Canonical metric names, grouped by Data Explorer category. */
|
|
4
|
+
export declare const metricCategories: {
|
|
5
|
+
METRICS_TYPE_A: string[];
|
|
6
|
+
METRICS_TYPE_B: string[];
|
|
7
|
+
METRICS_TYPE_C: string[];
|
|
8
|
+
};
|
|
9
|
+
/** Human-readable label per canonical metric name. */
|
|
10
|
+
export declare const metricLabels: Record<string, string>;
|
|
11
|
+
/** Every canonical metric name, in catalogue order. */
|
|
12
|
+
export declare const allMetricNames: readonly string[];
|
|
13
|
+
/** Category lookup for a canonical metric name. */
|
|
14
|
+
export declare const metricCategoryByName: Record<string, MetricCategory>;
|
|
15
|
+
//# sourceMappingURL=metrics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"metrics.d.ts","sourceRoot":"","sources":["../../src/generated/metrics.ts"],"names":[],"mappings":"AAGA,2DAA2D;AAC3D,MAAM,MAAM,cAAc,GAAG,gBAAgB,GAAG,gBAAgB,GAAG,gBAAgB,CAAC;AAEpF,iEAAiE;AACjE,eAAO,MAAM,gBAAgB;;;;CA4CwB,CAAC;AAEtD,sDAAsD;AACtD,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAsC/C,CAAC;AAEF,uDAAuD;AACvD,eAAO,MAAM,cAAc,EAAE,SAAS,MAAM,EAA2C,CAAC;AAExF,mDAAmD;AACnD,eAAO,MAAM,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,cAAc,CAsC/D,CAAC"}
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
// Generated by scripts/generate-metrics.ts from @dataworks/sdk@3.5.0. Do not edit.
|
|
2
|
+
// Canonical source: Dataworks-SDK/src/shared/metricConfig.ts
|
|
3
|
+
/** Canonical metric names, grouped by Data Explorer category. */
|
|
4
|
+
export const metricCategories = {
|
|
5
|
+
"METRICS_TYPE_A": [
|
|
6
|
+
"latlong",
|
|
7
|
+
"net-time",
|
|
8
|
+
"checkpoint-time",
|
|
9
|
+
"leg-time",
|
|
10
|
+
"sub-time",
|
|
11
|
+
"checkpoint",
|
|
12
|
+
"segment",
|
|
13
|
+
"distance",
|
|
14
|
+
"distance-swim",
|
|
15
|
+
"distance-bike",
|
|
16
|
+
"distance-run",
|
|
17
|
+
"lap",
|
|
18
|
+
"sector",
|
|
19
|
+
"status",
|
|
20
|
+
"is-drafting",
|
|
21
|
+
"total-drafting-seconds",
|
|
22
|
+
"heading-degrees",
|
|
23
|
+
"yoyo-count"
|
|
24
|
+
],
|
|
25
|
+
"METRICS_TYPE_B": [
|
|
26
|
+
"speed",
|
|
27
|
+
"location-speed",
|
|
28
|
+
"altitude",
|
|
29
|
+
"cadence-cycling",
|
|
30
|
+
"cadence",
|
|
31
|
+
"active-energy-burned",
|
|
32
|
+
"horizontal-accuracy",
|
|
33
|
+
"gap-to-leader",
|
|
34
|
+
"gap-to-ahead",
|
|
35
|
+
"time-to-leader",
|
|
36
|
+
"rank",
|
|
37
|
+
"speed-bike",
|
|
38
|
+
"pace",
|
|
39
|
+
"pace-swim",
|
|
40
|
+
"pace-run"
|
|
41
|
+
],
|
|
42
|
+
"METRICS_TYPE_C": [
|
|
43
|
+
"heartrate",
|
|
44
|
+
"power",
|
|
45
|
+
"power-cycling",
|
|
46
|
+
"pwr_instant"
|
|
47
|
+
]
|
|
48
|
+
};
|
|
49
|
+
/** Human-readable label per canonical metric name. */
|
|
50
|
+
export const metricLabels = {
|
|
51
|
+
"latlong": "GPS",
|
|
52
|
+
"net-time": "Net Time (s)",
|
|
53
|
+
"checkpoint-time": "Checkpoint Time (s)",
|
|
54
|
+
"leg-time": "Leg Time (s)",
|
|
55
|
+
"sub-time": "Sub Time (s)",
|
|
56
|
+
"checkpoint": "Checkpoint",
|
|
57
|
+
"segment": "Segment",
|
|
58
|
+
"distance": "Distance (km)",
|
|
59
|
+
"distance-swim": "Swim Distance (km)",
|
|
60
|
+
"distance-bike": "Bike Distance (km)",
|
|
61
|
+
"distance-run": "Run Distance (km)",
|
|
62
|
+
"lap": "Lap",
|
|
63
|
+
"sector": "Sector",
|
|
64
|
+
"status": "Status",
|
|
65
|
+
"is-drafting": "is-drafting",
|
|
66
|
+
"total-drafting-seconds": "total-drafting-seconds",
|
|
67
|
+
"heading-degrees": "heading-degrees",
|
|
68
|
+
"yoyo-count": "yoyo-count",
|
|
69
|
+
"speed": "Speed (km/h)",
|
|
70
|
+
"location-speed": "Location Speed",
|
|
71
|
+
"altitude": "Altitude",
|
|
72
|
+
"cadence-cycling": "Cadence (Cycling)",
|
|
73
|
+
"cadence": "Cadence",
|
|
74
|
+
"active-energy-burned": "Active Energy Burned",
|
|
75
|
+
"horizontal-accuracy": "Horizontal Accuracy",
|
|
76
|
+
"gap-to-leader": "gap-to-leader",
|
|
77
|
+
"gap-to-ahead": "gap-to-ahead",
|
|
78
|
+
"time-to-leader": "Time to Leader (s)",
|
|
79
|
+
"rank": "Rank",
|
|
80
|
+
"speed-bike": "Bike Speed (km/h)",
|
|
81
|
+
"pace": "Pace (sec/km)",
|
|
82
|
+
"pace-swim": "Swim Pace (sec/km)",
|
|
83
|
+
"pace-run": "Run Pace (sec/km)",
|
|
84
|
+
"heartrate": "Heart Rate",
|
|
85
|
+
"power": "Power",
|
|
86
|
+
"power-cycling": "Power (Cycling)",
|
|
87
|
+
"pwr_instant": "Power Instant"
|
|
88
|
+
};
|
|
89
|
+
/** Every canonical metric name, in catalogue order. */
|
|
90
|
+
export const allMetricNames = Object.values(metricCategories).flat();
|
|
91
|
+
/** Category lookup for a canonical metric name. */
|
|
92
|
+
export const metricCategoryByName = {
|
|
93
|
+
"latlong": "METRICS_TYPE_A",
|
|
94
|
+
"net-time": "METRICS_TYPE_A",
|
|
95
|
+
"checkpoint-time": "METRICS_TYPE_A",
|
|
96
|
+
"leg-time": "METRICS_TYPE_A",
|
|
97
|
+
"sub-time": "METRICS_TYPE_A",
|
|
98
|
+
"checkpoint": "METRICS_TYPE_A",
|
|
99
|
+
"segment": "METRICS_TYPE_A",
|
|
100
|
+
"distance": "METRICS_TYPE_A",
|
|
101
|
+
"distance-swim": "METRICS_TYPE_A",
|
|
102
|
+
"distance-bike": "METRICS_TYPE_A",
|
|
103
|
+
"distance-run": "METRICS_TYPE_A",
|
|
104
|
+
"lap": "METRICS_TYPE_A",
|
|
105
|
+
"sector": "METRICS_TYPE_A",
|
|
106
|
+
"status": "METRICS_TYPE_A",
|
|
107
|
+
"is-drafting": "METRICS_TYPE_A",
|
|
108
|
+
"total-drafting-seconds": "METRICS_TYPE_A",
|
|
109
|
+
"heading-degrees": "METRICS_TYPE_A",
|
|
110
|
+
"yoyo-count": "METRICS_TYPE_A",
|
|
111
|
+
"speed": "METRICS_TYPE_B",
|
|
112
|
+
"location-speed": "METRICS_TYPE_B",
|
|
113
|
+
"altitude": "METRICS_TYPE_B",
|
|
114
|
+
"cadence-cycling": "METRICS_TYPE_B",
|
|
115
|
+
"cadence": "METRICS_TYPE_B",
|
|
116
|
+
"active-energy-burned": "METRICS_TYPE_B",
|
|
117
|
+
"horizontal-accuracy": "METRICS_TYPE_B",
|
|
118
|
+
"gap-to-leader": "METRICS_TYPE_B",
|
|
119
|
+
"gap-to-ahead": "METRICS_TYPE_B",
|
|
120
|
+
"time-to-leader": "METRICS_TYPE_B",
|
|
121
|
+
"rank": "METRICS_TYPE_B",
|
|
122
|
+
"speed-bike": "METRICS_TYPE_B",
|
|
123
|
+
"pace": "METRICS_TYPE_B",
|
|
124
|
+
"pace-swim": "METRICS_TYPE_B",
|
|
125
|
+
"pace-run": "METRICS_TYPE_B",
|
|
126
|
+
"heartrate": "METRICS_TYPE_C",
|
|
127
|
+
"power": "METRICS_TYPE_C",
|
|
128
|
+
"power-cycling": "METRICS_TYPE_C",
|
|
129
|
+
"pwr_instant": "METRICS_TYPE_C"
|
|
130
|
+
};
|
|
131
|
+
//# sourceMappingURL=metrics.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"metrics.js","sourceRoot":"","sources":["../../src/generated/metrics.ts"],"names":[],"mappings":"AAAA,mFAAmF;AACnF,6DAA6D;AAK7D,iEAAiE;AACjE,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,gBAAgB,EAAE;QAChB,SAAS;QACT,UAAU;QACV,iBAAiB;QACjB,UAAU;QACV,UAAU;QACV,YAAY;QACZ,SAAS;QACT,UAAU;QACV,eAAe;QACf,eAAe;QACf,cAAc;QACd,KAAK;QACL,QAAQ;QACR,QAAQ;QACR,aAAa;QACb,wBAAwB;QACxB,iBAAiB;QACjB,YAAY;KACb;IACD,gBAAgB,EAAE;QAChB,OAAO;QACP,gBAAgB;QAChB,UAAU;QACV,iBAAiB;QACjB,SAAS;QACT,sBAAsB;QACtB,qBAAqB;QACrB,eAAe;QACf,cAAc;QACd,gBAAgB;QAChB,MAAM;QACN,YAAY;QACZ,MAAM;QACN,WAAW;QACX,UAAU;KACX;IACD,gBAAgB,EAAE;QAChB,WAAW;QACX,OAAO;QACP,eAAe;QACf,aAAa;KACd;CACkD,CAAC;AAEtD,sDAAsD;AACtD,MAAM,CAAC,MAAM,YAAY,GAA2B;IAClD,SAAS,EAAE,KAAK;IAChB,UAAU,EAAE,cAAc;IAC1B,iBAAiB,EAAE,qBAAqB;IACxC,UAAU,EAAE,cAAc;IAC1B,UAAU,EAAE,cAAc;IAC1B,YAAY,EAAE,YAAY;IAC1B,SAAS,EAAE,SAAS;IACpB,UAA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IACjC,cAAc,EAAE,gBAAgB;IAChC,KAAK,EAAE,gBAAgB;IACvB,QAAQ,EAAE,gBAAgB;IAC1B,QAAQ,EAAE,gBAAgB;IAC1B,aAAa,EAAE,gBAAgB;IAC/B,wBAAwB,EAAE,gBAAgB;IAC1C,iBAAiB,EAAE,gBAAgB;IACnC,YAAY,EAAE,gBAAgB;IAC9B,OAAO,EAAE,gBAAgB;IACzB,gBAAgB,EAAE,gBAAgB;IAClC,UAAU,EAAE,gBAAgB;IAC5B,iBAAiB,EAAE,gBAAgB;IACnC,SAAS,EAAE,gBAAgB;IAC3B,sBAAsB,EAAE,gBAAgB;IACxC,qBAAqB,EAAE,gBAAgB;IACvC,eAAe,EAAE,gBAAgB;IACjC,cAAc,EAAE,gBAAgB;IAChC,gBAAgB,EAAE,gBAAgB;IAClC,MAAM,EAAE,gBAAgB;IACxB,YAAY,EAAE,gBAAgB;IAC9B,MAAM,EAAE,gBAAgB;IACxB,WAAW,EAAE,gBAAgB;IAC7B,UAAU,EAAE,gBAAgB;IAC5B,WAAW,EAAE,gBAAgB;IAC7B,OAAO,EAAE,gBAAgB;IACzB,eAAe,EAAE,gBAAgB;IACjC,aAAa,EAAE,gBAAgB;CAChC,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export type AgentClient = "codex" | "claude-code";
|
|
2
|
+
export type AgentInstallStatus = "installed" | "updated" | "unavailable" | "failed";
|
|
3
|
+
export interface AgentInstallResult {
|
|
4
|
+
client: AgentClient;
|
|
5
|
+
status: AgentInstallStatus;
|
|
6
|
+
message: string;
|
|
7
|
+
nextStep: string;
|
|
8
|
+
}
|
|
9
|
+
export interface ProcessResult {
|
|
10
|
+
status: number | null;
|
|
11
|
+
stdout: string;
|
|
12
|
+
stderr: string;
|
|
13
|
+
error?: Error;
|
|
14
|
+
}
|
|
15
|
+
export type ProcessRunner = (command: string, args: readonly string[]) => ProcessResult;
|
|
16
|
+
export interface AgentInstallOptions {
|
|
17
|
+
force?: boolean;
|
|
18
|
+
packageRoot?: string;
|
|
19
|
+
run?: ProcessRunner;
|
|
20
|
+
}
|
|
21
|
+
export declare const supportedAgentClients: readonly AgentClient[];
|
|
22
|
+
export declare function dataworksPackageRoot(): string;
|
|
23
|
+
export declare function installAgentIntegration(client: AgentClient, options?: AgentInstallOptions): AgentInstallResult;
|
|
24
|
+
//# sourceMappingURL=agent-install.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-install.d.ts","sourceRoot":"","sources":["../../src/lib/agent-install.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,aAAa,CAAC;AAClD,MAAM,MAAM,kBAAkB,GAAG,WAAW,GAAG,SAAS,GAAG,aAAa,GAAG,QAAQ,CAAC;AAEpF,MAAM,WAAW,kBAAkB;IACjC,MAAM,EAAE,WAAW,CAAC;IACpB,MAAM,EAAE,kBAAkB,CAAC;IAC3B,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,KAAK,CAAC;CACf;AAED,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,MAAM,EAAE,KAAK,aAAa,CAAC;AAExF,MAAM,WAAW,mBAAmB;IAClC,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,CAAC,EAAE,aAAa,CAAC;CACrB;AAKD,eAAO,MAAM,qBAAqB,EAAE,SAAS,WAAW,EAA6B,CAAC;AAEtF,wBAAgB,oBAAoB,IAAI,MAAM,CAE7C;AA0PD,wBAAgB,uBAAuB,CACrC,MAAM,EAAE,WAAW,EACnB,OAAO,GAAE,mBAAwB,GAChC,kBAAkB,CAUpB"}
|