@qodalis/mcp-cli 0.1.0 → 0.2.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/CHANGELOG.md +26 -0
- package/README.md +137 -26
- package/dist/src/cli.js +21 -11
- package/dist/src/cli.js.map +1 -1
- package/dist/src/config.d.ts +10 -6
- package/dist/src/config.d.ts.map +1 -1
- package/dist/src/config.js +25 -6
- package/dist/src/config.js.map +1 -1
- package/dist/src/dev/api.d.ts +94 -0
- package/dist/src/dev/api.d.ts.map +1 -0
- package/dist/src/dev/api.js +425 -0
- package/dist/src/dev/api.js.map +1 -0
- package/dist/src/dev/docs.d.ts +93 -0
- package/dist/src/dev/docs.d.ts.map +1 -0
- package/dist/src/dev/docs.js +275 -0
- package/dist/src/dev/docs.js.map +1 -0
- package/dist/src/dev/prompts.d.ts +11 -0
- package/dist/src/dev/prompts.d.ts.map +1 -0
- package/dist/src/dev/prompts.js +141 -0
- package/dist/src/dev/prompts.js.map +1 -0
- package/dist/src/dev/scaffold.d.ts +55 -0
- package/dist/src/dev/scaffold.d.ts.map +1 -0
- package/dist/src/dev/scaffold.js +213 -0
- package/dist/src/dev/scaffold.js.map +1 -0
- package/dist/src/dev/tools.d.ts +170 -0
- package/dist/src/dev/tools.d.ts.map +1 -0
- package/dist/src/dev/tools.js +258 -0
- package/dist/src/dev/tools.js.map +1 -0
- package/dist/src/index.d.ts +7 -2
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +6 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/remote.d.ts +3 -1
- package/dist/src/remote.d.ts.map +1 -1
- package/dist/src/remote.js +17 -10
- package/dist/src/remote.js.map +1 -1
- package/dist/src/server.d.ts +11 -2
- package/dist/src/server.d.ts.map +1 -1
- package/dist/src/server.js +85 -15
- package/dist/src/server.js.map +1 -1
- package/docs/llms-full.txt +1740 -0
- package/package.json +7 -4
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,32 @@ All notable changes to this project are documented here. The format follows
|
|
|
4
4
|
[Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the project uses
|
|
5
5
|
[Semantic Versioning](https://semver.org/).
|
|
6
6
|
|
|
7
|
+
## [0.2.0] - 2026-10-27
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
|
|
11
|
+
- Plugin-development tools, served locally: `qcli_docs_search` and
|
|
12
|
+
`qcli_docs_read` over the plugin guide (`llms-full.txt` from
|
|
13
|
+
`QCLI_DOCS_URL`, default https://cli.qodalis.com/llms-full.txt, cached for an
|
|
14
|
+
hour, with a snapshot bundled in the package for offline use), `qcli_api`
|
|
15
|
+
(TypeScript declarations of the `@qodalis/*` packages from the project's
|
|
16
|
+
node_modules or the latest npm version) and `qcli_scaffold_plugin`
|
|
17
|
+
(`@qodalis/create-cli-plugin`).
|
|
18
|
+
- MCP prompts `create-web-plugin` and `create-server-command`, and the docs
|
|
19
|
+
topics as resources (`qcli-docs://<section>/<topic>`).
|
|
20
|
+
- `QCLI_DEV_TOOLS` (default `true`) and `QCLI_DOCS_URL`; `npm run sync-docs`
|
|
21
|
+
refreshes the bundled docs snapshot.
|
|
22
|
+
|
|
23
|
+
### Changed
|
|
24
|
+
|
|
25
|
+
- `QCLI_URL` is optional: without it the server runs in developer mode with only
|
|
26
|
+
the plugin-development tools. With it, the dev tools are listed before the
|
|
27
|
+
server's tools, and still listed when the server is unreachable.
|
|
28
|
+
- `QCLI_READ_ONLY`, `QCLI_TOOLS` and `QCLI_EXCLUDE` apply to the dev tools too
|
|
29
|
+
(read-only mode hides `qcli_scaffold_plugin`).
|
|
30
|
+
- `createProxyServer(remote, config, { dev })` accepts the dev tools and an
|
|
31
|
+
`undefined` remote.
|
|
32
|
+
|
|
7
33
|
## [0.1.0] - 2026-10-15
|
|
8
34
|
|
|
9
35
|
### Added
|
package/README.md
CHANGED
|
@@ -1,17 +1,36 @@
|
|
|
1
1
|
# @qodalis/mcp-cli
|
|
2
2
|
|
|
3
|
-
A
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
A [Model Context Protocol](https://modelcontextprotocol.io) server that helps
|
|
4
|
+
[Claude Code](https://code.claude.com) **build [Qodalis CLI](https://cli.qodalis.com) plugins** (docs search, exact API
|
|
5
|
+
declarations, scaffolding) and gives it the commands, files, data explorer, jobs and plugin tools of a running
|
|
6
|
+
Qodalis CLI server through a resilient proxy.
|
|
6
7
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
[](https://www.npmjs.com/package/@qodalis/mcp-cli)
|
|
9
|
+
[](https://github.com/qodalis-solutions/mcp-cli/actions/workflows/build.yml)
|
|
10
|
+
[](LICENSE)
|
|
11
|
+
|
|
12
|
+
`mcp-cli` runs on your machine as a stdio MCP server in one of two modes:
|
|
13
|
+
|
|
14
|
+
- **Developer mode** (no `QCLI_URL`): the [plugin-development tools](#plugin-development) only. No server needed.
|
|
15
|
+
- **Server mode** (`QCLI_URL` set): the same tools plus a proxy to the server's MCP endpoint
|
|
16
|
+
(`<server>/api/qcli/mcp`): Claude Code sees exactly the server's tools, with the permissions of the account you
|
|
17
|
+
configure. It handles sign-in, reconnects after network drops and lets you narrow what the assistant may use.
|
|
18
|
+
|
|
19
|
+
## Where it fits
|
|
20
|
+
|
|
21
|
+
| Repository | Role |
|
|
22
|
+
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
|
|
23
|
+
| [web-cli](https://github.com/qodalis-solutions/web-cli) | The browser terminal (Angular, React, Vue) and its plugins, including `token create` for API tokens |
|
|
24
|
+
| [cli-server-node](https://github.com/qodalis-solutions/cli-server-node), [cli-server-dotnet](https://github.com/qodalis-solutions/cli-server-dotnet), [cli-server-python](https://github.com/qodalis-solutions/cli-server-python) | The servers that host the MCP endpoint |
|
|
25
|
+
| [cli-server-dashboard](https://github.com/qodalis-solutions/cli-server-dashboard) | Admin dashboard served by the servers |
|
|
26
|
+
| [pwa-cli](https://github.com/qodalis-solutions/pwa-cli) | The CLI as a PWA and Android app |
|
|
27
|
+
| **mcp-cli** | This repository: the bridge from Claude Code to a server |
|
|
12
28
|
|
|
13
29
|
## Highlights
|
|
14
30
|
|
|
31
|
+
- **Plugin development built in.** Search the plugin guide, read the exact
|
|
32
|
+
TypeScript declarations of `@qodalis/cli-core` and scaffold a plugin, with
|
|
33
|
+
prompts that walk the assistant through a web plugin or a server command.
|
|
15
34
|
- **No tool-specific code.** Tools come from the server's `tools/list` and are
|
|
16
35
|
passed through unchanged (names, schemas, annotations); calls are forwarded.
|
|
17
36
|
New commands on the server show up without updating the proxy.
|
|
@@ -30,13 +49,31 @@ after network drops and lets you narrow what the assistant may use.
|
|
|
30
49
|
|
|
31
50
|
## Quick start
|
|
32
51
|
|
|
52
|
+
For plugin development, nothing else is needed:
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
claude mcp add qcli -- npx -y @qodalis/mcp-cli
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Then ask, for example, _"Create a Qodalis CLI plugin that converts temperatures"_ or run the
|
|
59
|
+
`/mcp__qcli__create-web-plugin` prompt. See [Plugin development](#plugin-development).
|
|
60
|
+
|
|
61
|
+
To also reach a running server, add `QCLI_URL` and credentials as described below.
|
|
62
|
+
|
|
33
63
|
```bash
|
|
34
64
|
npx -y @qodalis/mcp-cli --help
|
|
35
65
|
```
|
|
36
66
|
|
|
37
|
-
The server must have MCP enabled (`
|
|
38
|
-
|
|
39
|
-
|
|
67
|
+
The server must have MCP enabled (default ports: .NET `8046`, Node `8047`, Python `8048`):
|
|
68
|
+
|
|
69
|
+
| Server | Enable MCP |
|
|
70
|
+
| ------ | ---------------------------------------------- |
|
|
71
|
+
| Node | `createCliServer({ mcp: true })` |
|
|
72
|
+
| Python | `CliServerOptions(mcp=True)` |
|
|
73
|
+
| .NET | `builder.Services.AddCli(cli => cli.AddMcp())` |
|
|
74
|
+
|
|
75
|
+
Each also takes options (tool allow/deny lists, a static token, instructions); see
|
|
76
|
+
[MCP endpoint](https://cli.qodalis.com/docs/server-integration#mcp-endpoint).
|
|
40
77
|
|
|
41
78
|
### Claude Code
|
|
42
79
|
|
|
@@ -87,7 +124,7 @@ file works too:
|
|
|
87
124
|
{ "command": "npx", "args": ["-y", "@qodalis/mcp-cli", "--env-file", "/path/to/.env"] }
|
|
88
125
|
```
|
|
89
126
|
|
|
90
|
-
Pin a version in shared configs (`@qodalis/mcp-cli@0.
|
|
127
|
+
Pin a version in shared configs (`@qodalis/mcp-cli@0.2.0`) so an upgrade is a
|
|
91
128
|
deliberate change.
|
|
92
129
|
|
|
93
130
|
### Getting a token
|
|
@@ -115,24 +152,87 @@ A server **without** the users plugin protects its endpoint with a static token
|
|
|
115
152
|
(its `mcp.token` option): put that value in `QCLI_TOKEN`. If it sets none, the
|
|
116
153
|
endpoint is open and no auth variable is needed.
|
|
117
154
|
|
|
155
|
+
## Plugin development
|
|
156
|
+
|
|
157
|
+
These tools are served locally and work without a server (developer mode) or next to
|
|
158
|
+
a server's tools. Turn them off with `QCLI_DEV_TOOLS=false`.
|
|
159
|
+
|
|
160
|
+
```bash
|
|
161
|
+
claude mcp add qcli -- npx -y @qodalis/mcp-cli # developer mode
|
|
162
|
+
claude mcp add qcli --scope user -- npx -y @qodalis/mcp-cli # in every project
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
### Tools
|
|
166
|
+
|
|
167
|
+
| Tool | Arguments | What it does |
|
|
168
|
+
| ---------------------- | ------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
169
|
+
| `qcli_docs_search` | `query`, `limit?` (default 5, max 20) | Ranked topics of the plugin guide as `Section › Topic`, with their summary and an excerpt. |
|
|
170
|
+
| `qcli_docs_read` | `topic` | A topic in full (heading match, case-insensitive; `Section › Topic` when a heading is in several sections), or a whole section (`Web plugins`). Lists the topics when nothing matches. |
|
|
171
|
+
| `qcli_api` | `symbol`, `package?` (default `@qodalis/cli-core`) | The TypeScript declaration of an interface, type, class, function, enum or constant, with its JSDoc and the related declarations to look up next. `package` takes any `@qodalis/*` package (`cli` is short for `@qodalis/cli`). |
|
|
172
|
+
| `qcli_scaffold_plugin` | `name`, `description?`, `processorName?`, `directory?` | Runs `npx -y @qodalis/create-cli-plugin@latest` and returns the created files and next steps. Inside a web-cli checkout it creates `packages/plugins/<name>`; elsewhere a standalone `qodalis-cli-<name>` project. |
|
|
173
|
+
|
|
174
|
+
Where the data comes from:
|
|
175
|
+
|
|
176
|
+
- **Docs**: [`https://cli.qodalis.com/llms-full.txt`](https://cli.qodalis.com/llms-full.txt)
|
|
177
|
+
(`QCLI_DOCS_URL`), cached for an hour. When it cannot be fetched, the last
|
|
178
|
+
download is reused, else the snapshot bundled in the package
|
|
179
|
+
(`docs/llms-full.txt`), so the tools work offline.
|
|
180
|
+
- **API declarations**: the project's `node_modules` (the MCP server's working
|
|
181
|
+
directory and its parents) when the package is installed there, so the answer
|
|
182
|
+
matches the version you build against. Otherwise the `latest` version on npm,
|
|
183
|
+
downloaded from jsDelivr (unpkg as fallback) and cached in memory and in
|
|
184
|
+
`<tmp>/qodalis-mcp-cli`; offline, the newest cached version is used.
|
|
185
|
+
- **Scaffolding**: validates the name (lowercase letters, digits and hyphens, no
|
|
186
|
+
`cli-` prefix), refuses an existing target directory, runs without a TTY and
|
|
187
|
+
stops after 5 minutes. The standalone project installs its dependencies.
|
|
188
|
+
|
|
189
|
+
### Prompts
|
|
190
|
+
|
|
191
|
+
| Prompt | Arguments | Walks the assistant through |
|
|
192
|
+
| ----------------------- | -------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
|
|
193
|
+
| `create-web-plugin` | `name`, `description` | Reading the guide, looking up the contracts with `qcli_api`, scaffolding, implementing the processor and module, tests, registering it. |
|
|
194
|
+
| `create-server-command` | `language` (`node`, `dotnet`, `python`), `command` | Adding a command processor to a Node, .NET or Python server, registering it and testing it. |
|
|
195
|
+
|
|
196
|
+
In Claude Code they appear as `/mcp__qcli__create-web-plugin` and
|
|
197
|
+
`/mcp__qcli__create-server-command`. The docs topics are also MCP resources
|
|
198
|
+
(`qcli-docs://<section>/<topic>`), which Claude Code can attach with `@`.
|
|
199
|
+
|
|
200
|
+
### Example requests
|
|
201
|
+
|
|
202
|
+
- _"Search the Qodalis plugin docs for reading user input."_ → `qcli_docs_search`
|
|
203
|
+
- _"Show me ICliExecutionContext."_ → `qcli_api { "symbol": "ICliExecutionContext" }`
|
|
204
|
+
- _"Which options does CliEngine take?"_ → `qcli_api { "symbol": "CliEngine", "package": "cli" }`
|
|
205
|
+
- _"Scaffold a plugin called json-tools."_ → `qcli_scaffold_plugin { "name": "json-tools" }`
|
|
206
|
+
|
|
207
|
+
### Filters and read-only mode
|
|
208
|
+
|
|
209
|
+
The dev tools are tools like any other: `QCLI_TOOLS` and `QCLI_EXCLUDE` apply to
|
|
210
|
+
them (`QCLI_EXCLUDE=qcli_scaffold_plugin`, or `QCLI_TOOLS=qcli_*` for the dev
|
|
211
|
+
tools alone), and `QCLI_READ_ONLY=true` hides and refuses `qcli_scaffold_plugin`
|
|
212
|
+
(the docs and API tools are read-only). A server tool with the same name as a dev
|
|
213
|
+
tool is hidden. When the server is unreachable, `tools/list` still returns the
|
|
214
|
+
dev tools.
|
|
215
|
+
|
|
118
216
|
## Configuration
|
|
119
217
|
|
|
120
218
|
Every setting is an environment variable. `QODALIS_CLI_*` names are accepted as
|
|
121
219
|
aliases for every key.
|
|
122
220
|
|
|
123
|
-
| Variable | Default
|
|
124
|
-
| ------------------------- |
|
|
125
|
-
| `QCLI_URL` |
|
|
126
|
-
| `QCLI_TOKEN` | none
|
|
127
|
-
| `QCLI_USER` | none
|
|
128
|
-
| `QCLI_PASSWORD` | none
|
|
129
|
-
| `QCLI_READ_ONLY` | `false`
|
|
130
|
-
| `QCLI_TOOLS` | all
|
|
131
|
-
| `QCLI_EXCLUDE` | none
|
|
132
|
-
| `QCLI_CONNECTION_TIMEOUT` | `8000`
|
|
133
|
-
| `QCLI_REQUEST_TIMEOUT` | `60000`
|
|
134
|
-
| `QCLI_TRUST_CERT` | `false`
|
|
135
|
-
| `QCLI_ENV_FILE` | none
|
|
221
|
+
| Variable | Default | Description |
|
|
222
|
+
| ------------------------- | --------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
|
|
223
|
+
| `QCLI_URL` | none | Server base URL, e.g. `https://cli.example.com` (a pasted `…/api/qcli/mcp` URL is accepted). Without it: developer mode. |
|
|
224
|
+
| `QCLI_TOKEN` | none | API token (`token create` in the web CLI) or the server's static `mcp.token`. |
|
|
225
|
+
| `QCLI_USER` | none | Sign in with this user name instead of a token (needs `QCLI_PASSWORD`). |
|
|
226
|
+
| `QCLI_PASSWORD` | none | Password for `QCLI_USER`. Never logged. |
|
|
227
|
+
| `QCLI_READ_ONLY` | `false` | Expose and allow only tools annotated `readOnlyHint: true`. See [read-only mode](#read-only-mode). |
|
|
228
|
+
| `QCLI_TOOLS` | all | Comma-separated allow-list of tool names; a trailing `*` matches a prefix (`fs_*`). |
|
|
229
|
+
| `QCLI_EXCLUDE` | none | Comma-separated deny-list, same syntax, applied after `QCLI_TOOLS`. |
|
|
230
|
+
| `QCLI_CONNECTION_TIMEOUT` | `8000` | Milliseconds to wait for the TCP/TLS connection before reporting the server unreachable. |
|
|
231
|
+
| `QCLI_REQUEST_TIMEOUT` | `60000` | Milliseconds a single request (`tools/list`, `tools/call`) may take. |
|
|
232
|
+
| `QCLI_TRUST_CERT` | `false` | Accept a self-signed TLS certificate. |
|
|
233
|
+
| `QCLI_ENV_FILE` | none | Path to a `.env` file (same as `--env-file`). Variables already set in the environment win. |
|
|
234
|
+
| `QCLI_DEV_TOOLS` | `true` | The `qcli_*` plugin-development tools, prompts and docs resources. `false` requires `QCLI_URL`. |
|
|
235
|
+
| `QCLI_DOCS_URL` | `https://cli.qodalis.com/llms-full.txt` | Where the plugin guide is fetched from (falls back to the bundled snapshot). |
|
|
136
236
|
|
|
137
237
|
Set either `QCLI_TOKEN` or `QCLI_USER` + `QCLI_PASSWORD`, not both.
|
|
138
238
|
|
|
@@ -216,7 +316,8 @@ shows its status and tools and lets you reconnect. The proxy logs to stderr
|
|
|
216
316
|
| `Cannot reach … Check QCLI_URL / VPN.` | The server is down, the URL or port is wrong, or the VPN is disconnected. Retry the call once it is back: the proxy reconnects by itself. |
|
|
217
317
|
| `… did not answer within 60000 ms` | A slow command; raise `QCLI_REQUEST_TIMEOUT`. |
|
|
218
318
|
| A tool is missing | The account (or token scope) lacks its permission, the feature is not enabled on the server, or `QCLI_READ_ONLY` / `QCLI_TOOLS` / `QCLI_EXCLUDE` hide it. |
|
|
219
|
-
| `
|
|
319
|
+
| `Nothing to serve: set QCLI_URL …` at startup | `QCLI_DEV_TOOLS=false` without `QCLI_URL`: set the URL (check the variable name; `npx -y @qodalis/mcp-cli --help` lists every variable). |
|
|
320
|
+
| Only the `qcli_*` tools are listed | No `QCLI_URL` (developer mode), or the server is unreachable: the log says which. |
|
|
220
321
|
|
|
221
322
|
## How reconnection works
|
|
222
323
|
|
|
@@ -256,6 +357,15 @@ const remote = new RemoteServer(config, { clientInfo: { name: 'my-app', version:
|
|
|
256
357
|
const server = createProxyServer(remote, config); // a low-level MCP Server: connect any transport
|
|
257
358
|
```
|
|
258
359
|
|
|
360
|
+
With the plugin-development tools (`remote` may be `undefined` for developer mode):
|
|
361
|
+
|
|
362
|
+
```ts
|
|
363
|
+
import { createProxyServer, DevTools, loadConfig } from '@qodalis/mcp-cli';
|
|
364
|
+
|
|
365
|
+
const config = loadConfig(process.env);
|
|
366
|
+
const server = createProxyServer(undefined, config, { dev: new DevTools(config) });
|
|
367
|
+
```
|
|
368
|
+
|
|
259
369
|
## Development
|
|
260
370
|
|
|
261
371
|
```bash
|
|
@@ -265,6 +375,7 @@ npm test # unit tests and stdio end-to-end tests against a fake serv
|
|
|
265
375
|
npm run typecheck
|
|
266
376
|
npm run check-format
|
|
267
377
|
npm run dev -- --env-file .env # run from source
|
|
378
|
+
npm run sync-docs # refresh docs/llms-full.txt: a path/URL argument, else generated by ../web-cli/tools/build-llms.js, else the site
|
|
268
379
|
```
|
|
269
380
|
|
|
270
381
|
See [CONTRIBUTING.md](CONTRIBUTING.md).
|
package/dist/src/cli.js
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { serveStdio } from '@modelcontextprotocol/server/stdio';
|
|
3
3
|
import { ConfigError, describeConfig, ENV_FILE_VARIABLES, loadConfig } from './config.js';
|
|
4
|
+
import { DevTools } from './dev/tools.js';
|
|
4
5
|
import { applyEnvFile } from './env-file.js';
|
|
5
6
|
import { RemoteServer } from './remote.js';
|
|
6
7
|
import { createProxyServer, SERVER_NAME, SERVER_VERSION } from './server.js';
|
|
7
8
|
const SHUTDOWN_GRACE_MS = 5000;
|
|
8
|
-
const usage = `
|
|
9
|
-
(<QCLI_URL>/api/qcli/mcp).
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
const usage = `Plugin-development tools for Qodalis CLI (docs search, API declarations, plugin
|
|
10
|
+
scaffolding) and a proxy to a Qodalis CLI server's MCP endpoint (<QCLI_URL>/api/qcli/mcp).
|
|
11
|
+
Without QCLI_URL it runs in developer mode: only the plugin-development tools.
|
|
12
|
+
Configuration is read from the environment (QCLI_* or QODALIS_CLI_* names):
|
|
13
|
+
QCLI_URL server base URL, e.g. http://localhost:8047 (optional)
|
|
12
14
|
QCLI_TOKEN API token (token create in the web CLI) or the server's mcp token
|
|
13
15
|
QCLI_USER, QCLI_PASSWORD sign in with a password instead (signs in again on 401)
|
|
14
16
|
QCLI_READ_ONLY (false) only tools the server marks read-only
|
|
@@ -17,6 +19,8 @@ QODALIS_CLI_* names):
|
|
|
17
19
|
QCLI_CONNECTION_TIMEOUT (8000 ms) QCLI_REQUEST_TIMEOUT (60000 ms)
|
|
18
20
|
QCLI_TRUST_CERT (false) accept a self-signed TLS certificate
|
|
19
21
|
QCLI_ENV_FILE path to a .env file (same as --env-file)
|
|
22
|
+
QCLI_DEV_TOOLS (true) the qcli_* plugin-development tools, prompts and docs resources
|
|
23
|
+
QCLI_DOCS_URL plugin docs (default https://cli.qodalis.com/llms-full.txt)
|
|
20
24
|
`;
|
|
21
25
|
const log = (message) => {
|
|
22
26
|
// Anything written to stdout corrupts the JSON-RPC stream: all logging goes to stderr.
|
|
@@ -58,14 +62,20 @@ const main = () => {
|
|
|
58
62
|
if (config.trustCert) {
|
|
59
63
|
log('QCLI_TRUST_CERT=true: TLS certificates are not verified');
|
|
60
64
|
}
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
65
|
+
if (!config.url && config.auth.kind !== 'none') {
|
|
66
|
+
log('QCLI_TOKEN / QCLI_USER are set but QCLI_URL is not: no server is used');
|
|
67
|
+
}
|
|
68
|
+
const remote = config.url
|
|
69
|
+
? new RemoteServer(config, {
|
|
70
|
+
clientInfo: { name: SERVER_NAME, version: SERVER_VERSION },
|
|
71
|
+
log,
|
|
72
|
+
})
|
|
73
|
+
: undefined;
|
|
74
|
+
const dev = config.devTools ? new DevTools(config, { log }) : undefined;
|
|
75
|
+
const handle = serveStdio(() => createProxyServer(remote, config, { dev, log }), {
|
|
66
76
|
onerror: (error) => log(`transport error: ${error.message}`),
|
|
67
77
|
});
|
|
68
|
-
log(`v${SERVER_VERSION} ready for ${describeConfig(config)}; connects on first use`);
|
|
78
|
+
log(`v${SERVER_VERSION} ready for ${describeConfig(config)}${remote ? '; connects on first use' : ''}`);
|
|
69
79
|
let shuttingDown = false;
|
|
70
80
|
const shutdown = async (reason) => {
|
|
71
81
|
if (shuttingDown) {
|
|
@@ -75,7 +85,7 @@ const main = () => {
|
|
|
75
85
|
log(`shutting down (${reason})`);
|
|
76
86
|
setTimeout(() => process.exit(0), SHUTDOWN_GRACE_MS).unref();
|
|
77
87
|
await handle.close().catch(() => undefined);
|
|
78
|
-
await remote
|
|
88
|
+
await remote?.close();
|
|
79
89
|
process.exit(0);
|
|
80
90
|
};
|
|
81
91
|
process.once('SIGINT', () => void shutdown('SIGINT'));
|
package/dist/src/cli.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAC1F,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7E,MAAM,iBAAiB,GAAG,IAAI,CAAC;AAE/B,MAAM,KAAK,GAAG
|
|
1
|
+
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAC1F,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7E,MAAM,iBAAiB,GAAG,IAAI,CAAC;AAE/B,MAAM,KAAK,GAAG;;;;;;;;;;;;;;;CAeb,CAAC;AAEF,MAAM,GAAG,GAAG,CAAC,OAAe,EAAQ,EAAE;IAClC,uFAAuF;IACvF,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,WAAW,KAAK,OAAO,I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AC,CAAC,CAAC;IACpB,CAAC;AACL,CAAC,CAAC;AAEF,IAAI,EAAE,CAAC"}
|
package/dist/src/config.d.ts
CHANGED
|
@@ -20,6 +20,10 @@ export type AuthConfig = {
|
|
|
20
20
|
export type Config = {
|
|
21
21
|
auth: AuthConfig;
|
|
22
22
|
connectionTimeoutMs: number;
|
|
23
|
+
/** Expose the local plugin-development tools and prompts (`qcli_*`) */
|
|
24
|
+
devTools: boolean;
|
|
25
|
+
/** Where the plugin-development docs (`llms-full.txt`) are fetched from */
|
|
26
|
+
docsUrl: string;
|
|
23
27
|
/** Client-side deny-list (trailing `*` allowed), applied after `tools` */
|
|
24
28
|
exclude: string[];
|
|
25
29
|
/** Expose and allow only tools annotated `readOnlyHint: true` */
|
|
@@ -29,9 +33,13 @@ export type Config = {
|
|
|
29
33
|
tools: string[];
|
|
30
34
|
/** Accept self-signed TLS certificates */
|
|
31
35
|
trustCert: boolean;
|
|
32
|
-
/**
|
|
33
|
-
|
|
36
|
+
/**
|
|
37
|
+
* Server base URL, e.g. `https://cli.example.com` (no trailing slash). Without it
|
|
38
|
+
* the process runs in developer mode: only the local plugin-development tools.
|
|
39
|
+
*/
|
|
40
|
+
url: string | undefined;
|
|
34
41
|
};
|
|
42
|
+
export declare const DEFAULT_DOCS_URL = "https://cli.qodalis.com/llms-full.txt";
|
|
35
43
|
export declare const PREFIXES: string[];
|
|
36
44
|
/** `QCLI_<suffix>` plus the `QODALIS_CLI_<suffix>` alias. */
|
|
37
45
|
export declare const names: (suffix: string) => string[];
|
|
@@ -45,10 +53,6 @@ export type EnvReader = {
|
|
|
45
53
|
};
|
|
46
54
|
/** Typed readers over an environment map; the first non-empty name wins. */
|
|
47
55
|
export declare const createEnvReader: (env: Env) => EnvReader;
|
|
48
|
-
/**
|
|
49
|
-
* Canonical server URL: scheme and host, optional base path, no trailing slash.
|
|
50
|
-
* A pasted endpoint URL (`…/api/qcli/mcp`) is accepted and reduced to the base.
|
|
51
|
-
*/
|
|
52
56
|
export declare const normalizeUrl: (input: string) => string;
|
|
53
57
|
export declare const loadConfig: (env?: Env) => Config;
|
|
54
58
|
/** One-line summary for the startup log (never contains secrets). */
|
package/dist/src/config.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,MAAM,GAAG,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC;AAErD,qBAAa,WAAY,SAAQ,KAAK;gBACtB,OAAO,EAAE,MAAM;CAI9B;AAED,6DAA6D;AAC7D,MAAM,MAAM,UAAU,GAChB;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,GAChB;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,GAChC;IAAE,IAAI,EAAE,UAAU,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAE3D,MAAM,MAAM,MAAM,GAAG;IACjB,IAAI,EAAE,UAAU,CAAC;IACjB,mBAAmB,EAAE,MAAM,CAAC;IAC5B,0EAA0E;IAC1E,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,iEAAiE;IACjE,QAAQ,EAAE,OAAO,CAAC;IAClB,gBAAgB,EAAE,MAAM,CAAC;IACzB,wEAAwE;IACxE,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,0CAA0C;IAC1C,SAAS,EAAE,OAAO,CAAC;IACnB
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,MAAM,GAAG,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC;AAErD,qBAAa,WAAY,SAAQ,KAAK;gBACtB,OAAO,EAAE,MAAM;CAI9B;AAED,6DAA6D;AAC7D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K,EAAE,MAAM,EAAE,EAAE,QAAQ,EAAE,MAAM,KAAK,MAAM,CAAC;IAC/D,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,MAAM,CAAC;CACzC,CAAC;AAEF,4EAA4E;AAC5E,eAAO,MAAM,eAAe,GAAI,KAAK,GAAG,KAAG,SAoD1C,CAAC;AAmBF,eAAO,MAAM,YAAY,GAAI,OAAO,MAAM,KAAG,MAI5C,CAAC;AAqBF,eAAO,MAAM,UAAU,GAAI,MAAK,GAAiB,KAAG,MAwBnD,CAAC;AAEF,qEAAqE;AACrE,eAAO,MAAM,cAAc,GAAI,QAAQ,MAAM,KAAG,MAmB/C,CAAC"}
|
package/dist/src/config.js
CHANGED
|
@@ -4,6 +4,7 @@ export class ConfigError extends Error {
|
|
|
4
4
|
this.name = 'ConfigError';
|
|
5
5
|
}
|
|
6
6
|
}
|
|
7
|
+
export const DEFAULT_DOCS_URL = 'https://cli.qodalis.com/llms-full.txt';
|
|
7
8
|
export const PREFIXES = ['QCLI', 'QODALIS_CLI'];
|
|
8
9
|
/** `QCLI_<suffix>` plus the `QODALIS_CLI_<suffix>` alias. */
|
|
9
10
|
export const names = (suffix) => PREFIXES.map((prefix) => `${prefix}_${suffix}`);
|
|
@@ -66,17 +67,21 @@ export const createEnvReader = (env) => {
|
|
|
66
67
|
* Canonical server URL: scheme and host, optional base path, no trailing slash.
|
|
67
68
|
* A pasted endpoint URL (`…/api/qcli/mcp`) is accepted and reduced to the base.
|
|
68
69
|
*/
|
|
69
|
-
|
|
70
|
+
const parseHttpUrl = (input, variable) => {
|
|
70
71
|
let url;
|
|
71
72
|
try {
|
|
72
73
|
url = new URL(input);
|
|
73
74
|
}
|
|
74
75
|
catch {
|
|
75
|
-
throw new ConfigError(
|
|
76
|
+
throw new ConfigError(`${variable} must be an http(s) URL, got "${input}".`);
|
|
76
77
|
}
|
|
77
78
|
if (url.protocol !== 'http:' && url.protocol !== 'https:') {
|
|
78
|
-
throw new ConfigError(
|
|
79
|
+
throw new ConfigError(`${variable} must be an http(s) URL, got "${input}".`);
|
|
79
80
|
}
|
|
81
|
+
return url;
|
|
82
|
+
};
|
|
83
|
+
export const normalizeUrl = (input) => {
|
|
84
|
+
const url = parseHttpUrl(input, 'QCLI_URL');
|
|
80
85
|
const path = url.pathname.replace(/\/+$/, '').replace(/\/api\/qcli\/mcp$/i, '');
|
|
81
86
|
return `${url.protocol}//${url.host}${path}`;
|
|
82
87
|
};
|
|
@@ -100,15 +105,25 @@ const loadAuth = (read) => {
|
|
|
100
105
|
};
|
|
101
106
|
export const loadConfig = (env = process.env) => {
|
|
102
107
|
const read = createEnvReader(env);
|
|
108
|
+
const url = read.optional(names('URL'));
|
|
109
|
+
const devTools = read.boolean(names('DEV_TOOLS'), true);
|
|
110
|
+
if (!url && !devTools) {
|
|
111
|
+
throw new ConfigError('Nothing to serve: set QCLI_URL to proxy a Qodalis CLI server, or leave QCLI_DEV_TOOLS on for the plugin-development tools.');
|
|
112
|
+
}
|
|
113
|
+
const auth = loadAuth(read);
|
|
114
|
+
const docsUrl = read.optional(names('DOCS_URL')) ?? DEFAULT_DOCS_URL;
|
|
115
|
+
parseHttpUrl(docsUrl, 'QCLI_DOCS_URL');
|
|
103
116
|
return {
|
|
104
|
-
auth
|
|
117
|
+
auth,
|
|
105
118
|
connectionTimeoutMs: read.positiveInteger(names('CONNECTION_TIMEOUT'), 8000),
|
|
119
|
+
devTools,
|
|
120
|
+
docsUrl,
|
|
106
121
|
exclude: read.list(names('EXCLUDE')),
|
|
107
122
|
readOnly: read.boolean(names('READ_ONLY'), false),
|
|
108
123
|
requestTimeoutMs: read.positiveInteger(names('REQUEST_TIMEOUT'), 60000),
|
|
109
124
|
tools: read.list(names('TOOLS')),
|
|
110
125
|
trustCert: read.boolean(names('TRUST_CERT'), false),
|
|
111
|
-
url: normalizeUrl(
|
|
126
|
+
url: url ? normalizeUrl(url) : undefined,
|
|
112
127
|
};
|
|
113
128
|
};
|
|
114
129
|
/** One-line summary for the startup log (never contains secrets). */
|
|
@@ -125,6 +140,10 @@ export const describeConfig = (config) => {
|
|
|
125
140
|
]
|
|
126
141
|
.filter(Boolean)
|
|
127
142
|
.join(', ');
|
|
128
|
-
|
|
143
|
+
const dev = config.devTools ? ' + plugin-development tools' : '';
|
|
144
|
+
if (!config.url) {
|
|
145
|
+
return `developer mode (plugin-development tools only; ${filters})`;
|
|
146
|
+
}
|
|
147
|
+
return `${config.url} (${auth}; ${filters})${dev}`;
|
|
129
148
|
};
|
|
130
149
|
//# sourceMappingURL=config.js.map
|
package/dist/src/config.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AAMA,MAAM,OAAO,WAAY,SAAQ,KAAK;IAClC,YAAY,OAAe;QACvB,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,aAAa,CAAC;IAC9B,CAAC;CACJ;
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AAMA,MAAM,OAAO,WAAY,SAAQ,KAAK;IAClC,YAAY,OAAe;QACvB,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,aAAa,CAAC;IAC9B,CAAC;CACJ;AA+BD,MAAM,CAAC,MAAM,gBAAgB,GAAG,uCAAuC,CAAC;AAExE,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;AAEhD,6DAA6D;AAC7D,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,MAAc,EAAY,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,GAAG,MAAM,IAAI,MAAM,EAAE,CAAC,CAAC;AAEnG,MAAM,CAAC,MAAM,kBAAkB,GAAG,KAAK,CAAC,UAAU,CAAC,CAAC;AAEpD,MAAM,WA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D,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,WAAW,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE;KACrE;SACI,MAAM,CAAC,OAAO,CAAC;SACf,IAAI,CAAC,IAAI,CAAC,CAAC;IAChB,MAAM,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,6BAA6B,CAAC,CAAC,CAAC,EAAE,CAAC;IACjE,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,CAAC;QACd,OAAO,kDAAkD,OAAO,GAAG,CAAC;IACxE,CAAC;IACD,OAAO,GAAG,MAAM,CAAC,GAAG,KAAK,IAAI,KAAK,OAAO,IAAI,GAAG,EAAE,CAAC;AACvD,CAAC,CAAC"}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `qcli_api`: TypeScript declarations of the published `@qodalis/*` packages, read from
|
|
3
|
+
* the project's node_modules when installed there, otherwise from the npm registry
|
|
4
|
+
* (`latest`) through a CDN, cached in memory and in a temp directory.
|
|
5
|
+
*/
|
|
6
|
+
export declare const DEFAULT_API_PACKAGE = "@qodalis/cli-core";
|
|
7
|
+
/** `cli-core`, `@qodalis/cli-core` → `@qodalis/cli-core`; anything outside @qodalis is refused. */
|
|
8
|
+
export declare const normalizePackageName: (input: string | undefined) => string;
|
|
9
|
+
export type Declaration = {
|
|
10
|
+
/** The declaration with its JSDoc, as written in the .d.ts */
|
|
11
|
+
text: string;
|
|
12
|
+
/** File it came from, relative to the package root */
|
|
13
|
+
file: string;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* `source` with comments, strings and template literals replaced by spaces (newlines
|
|
17
|
+
* kept), so offsets match the original and braces in JSDoc or string types do not count.
|
|
18
|
+
*/
|
|
19
|
+
export declare const blankNonCode: (source: string) => string;
|
|
20
|
+
/** Every top-level declaration of `symbol` in `source` (overloads and merged interfaces included). */
|
|
21
|
+
export declare const extractDeclarations: (source: string, symbol: string) => string[];
|
|
22
|
+
/** Names of every top-level declaration in the files. */
|
|
23
|
+
export declare const declaredNames: (sources: string[]) => Set<string>;
|
|
24
|
+
/** `export { Local as Symbol }` aliases: the local name a public symbol is declared under. */
|
|
25
|
+
export declare const aliasOf: (sources: string[], symbol: string) => string | undefined;
|
|
26
|
+
export type TypeFiles = {
|
|
27
|
+
/** Relative path → content */
|
|
28
|
+
files: Map<string, string>;
|
|
29
|
+
package: string;
|
|
30
|
+
/** `node_modules (<path>)`, `cache`, `https://…` */
|
|
31
|
+
source: string;
|
|
32
|
+
version: string;
|
|
33
|
+
};
|
|
34
|
+
export type ApiLookup = {
|
|
35
|
+
declarations: Declaration[];
|
|
36
|
+
/** Declared names referenced by the declarations, to look up next */
|
|
37
|
+
related: string[];
|
|
38
|
+
/** Close names when nothing matched */
|
|
39
|
+
suggestions: string[];
|
|
40
|
+
types: TypeFiles;
|
|
41
|
+
};
|
|
42
|
+
/** Finds `symbol` in the package's declaration files. */
|
|
43
|
+
export declare const lookupSymbol: (types: TypeFiles, symbol: string) => ApiLookup;
|
|
44
|
+
type PackageJson = {
|
|
45
|
+
exports?: unknown;
|
|
46
|
+
name?: string;
|
|
47
|
+
types?: string;
|
|
48
|
+
typings?: string;
|
|
49
|
+
version?: string;
|
|
50
|
+
};
|
|
51
|
+
/** The declaration entry of a package.json: `types`, `typings`, `exports["."].types`. */
|
|
52
|
+
export declare const typesEntry: (pkg: PackageJson) => string;
|
|
53
|
+
/**
|
|
54
|
+
* Loads the entry file and every .d.ts reachable through relative imports/re-exports
|
|
55
|
+
* with `read` (returns undefined for a missing file).
|
|
56
|
+
*/
|
|
57
|
+
export declare const collectTypeFiles: (entry: string, read: (relativePath: string) => Promise<string | undefined>) => Promise<Map<string, string>>;
|
|
58
|
+
/** `<dir>/node_modules/<pkg>` for `dir` and each of its parents. */
|
|
59
|
+
export declare const findInstalledPackage: (cwd: string, name: string) => string | undefined;
|
|
60
|
+
export type ApiSourceOptions = {
|
|
61
|
+
/** Project directory searched for node_modules (default: process.cwd()) */
|
|
62
|
+
cwd?: string;
|
|
63
|
+
/** Overrides the HTTP client (tests) */
|
|
64
|
+
fetch?: typeof fetch;
|
|
65
|
+
log?: (message: string) => void;
|
|
66
|
+
/** Directory for downloaded declarations (default: `<os tmp>/qodalis-mcp-cli`); null disables it */
|
|
67
|
+
cacheDir?: string | null;
|
|
68
|
+
registryUrl?: string;
|
|
69
|
+
/** CDN base URLs tried in order; `<base>/<name>@<version>/<file>` */
|
|
70
|
+
cdns?: string[];
|
|
71
|
+
};
|
|
72
|
+
/**
|
|
73
|
+
* Resolves a package's declaration files: (1) the project's node_modules, (2) an
|
|
74
|
+
* in-memory copy, (3) the registry's `latest` version from the temp-dir cache or a CDN,
|
|
75
|
+
* (4) without network, the newest version in the temp-dir cache.
|
|
76
|
+
*/
|
|
77
|
+
export declare class ApiSource {
|
|
78
|
+
private readonly options;
|
|
79
|
+
private readonly memory;
|
|
80
|
+
constructor(options?: ApiSourceOptions);
|
|
81
|
+
get(name: string): Promise<TypeFiles>;
|
|
82
|
+
private fromDirectory;
|
|
83
|
+
private get cacheDir();
|
|
84
|
+
private fetchText;
|
|
85
|
+
private download;
|
|
86
|
+
private cacheFile;
|
|
87
|
+
private readCache;
|
|
88
|
+
private writeCache;
|
|
89
|
+
private newestCached;
|
|
90
|
+
}
|
|
91
|
+
/** Markdown answer for `qcli_api`. */
|
|
92
|
+
export declare const formatLookup: (symbol: string, lookup: ApiLookup) => string;
|
|
93
|
+
export {};
|
|
94
|
+
//# sourceMappingURL=api.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../../src/dev/api.ts"],"names":[],"mappings":"AAIA;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,sBAAsB,CAAC;AAKvD,mGAAmG;AACnG,eAAO,MAAM,oBAAoB,GAAI,OAAO,MAAM,GAAG,SAAS,KAAG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