pando-ai 0.2.4 → 0.2.6
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 +38 -19
- package/bin/pando-ai.js +22 -2
- package/dist/cli.js +174 -153
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -26,8 +26,11 @@ npx -y pando-ai
|
|
|
26
26
|
|
|
27
27
|
On a terminal this opens the **firewall console**: it detects whether `codex`
|
|
28
28
|
and `claude` are protected, offers to install supervised launchers for any that
|
|
29
|
-
aren't, and shows current status and policy.
|
|
30
|
-
`
|
|
29
|
+
aren't, and shows current status and policy. It also installs a persistent
|
|
30
|
+
`~/.pando/bin/pando-ai` command shim, so future commands such as
|
|
31
|
+
`pando-ai uninstall` work even when the first run came from `npx`. After
|
|
32
|
+
installation you keep running `codex` and `claude` normally — Pando supervises
|
|
33
|
+
each launch.
|
|
31
34
|
|
|
32
35
|
## How it works
|
|
33
36
|
|
|
@@ -35,8 +38,10 @@ Two choke points, one ruleset:
|
|
|
35
38
|
|
|
36
39
|
- **Launch shim** (`~/.pando/bin` ahead of the real tools on PATH) — supervises
|
|
37
40
|
every `codex`/`claude` invocation. It disables the agent's native tools where
|
|
38
|
-
supported,
|
|
39
|
-
applies the MCP allow/deny policy via the agent's own launch
|
|
41
|
+
supported, dynamically injects the Pando MCP server (root-scoped to your
|
|
42
|
+
project), and applies the MCP allow/deny policy via the agent's own launch
|
|
43
|
+
flags. Pando does not permanently add itself to the user's MCP config files by
|
|
44
|
+
default; supervised launches pass generated config on each run.
|
|
40
45
|
- **Wire gateway** (a local reverse proxy speaking the OpenAI Responses API and
|
|
41
46
|
Anthropic Messages API) — sits inline on every supported request and forwards
|
|
42
47
|
it to the upstream you control, so traffic stays local. It blocks off-policy
|
|
@@ -71,7 +76,7 @@ Legacy completion APIs, including OpenAI chat/completions and Anthropic
|
|
|
71
76
|
| Capability | Claude Code | Codex |
|
|
72
77
|
| --- | --- | --- |
|
|
73
78
|
| Disable native tools | ✅ `--tools ""` (MCP stays available) + gateway/hook block | ⚠️ read-only sandbox + web search disabled + request/response gateway block |
|
|
74
|
-
| Install Pando MCP, root-scoped | ✅ `--mcp-config` | ✅ required `-c mcp_servers.pando.*` |
|
|
79
|
+
| Install Pando MCP, root-scoped | ✅ dynamic `--mcp-config` + `--strict-mcp-config` | ✅ dynamic required `-c mcp_servers.pando.*` |
|
|
75
80
|
| `other_mcp: deny_all` | ✅ `--strict-mcp-config` (Pando only) + gateway/hook block | ✅ request/response gateway block |
|
|
76
81
|
| `other_mcp: allow_list` | ✅ strict config with Pando + named servers + gateway/hook block | ✅ request/response gateway block |
|
|
77
82
|
| `other_mcp: deny_list` | ✅ `--disallowedTools` removes denied names + gateway/hook block | ✅ request/response gateway block |
|
|
@@ -179,11 +184,11 @@ provider-bound gateway enforcement is disabled.
|
|
|
179
184
|
## Surfaces
|
|
180
185
|
|
|
181
186
|
```bash
|
|
182
|
-
pando-ai # firewall console
|
|
187
|
+
pando-ai # firewall console: status, install, uninstall
|
|
183
188
|
pando-ai install # force a (re)install pass
|
|
184
|
-
pando-ai uninstall # remove Pando shims, managed PATH block, and install
|
|
189
|
+
pando-ai uninstall # remove Pando shims, managed PATH block, install state, and global npm install when detected
|
|
185
190
|
pando-ai serve [path] # stdio MCP server for MCP clients
|
|
186
|
-
pando-ai serve-http # HTTP MCP server
|
|
191
|
+
pando-ai serve-http # explicit HTTP MCP server for debugging/integrations
|
|
187
192
|
pando-ai gateway # run the firewall gateway in the foreground (debug)
|
|
188
193
|
pando-ai proxy status|enable|disable [codex|claude]
|
|
189
194
|
pando-ai login|logout|whoami
|
|
@@ -202,26 +207,40 @@ pando-ai uninstall
|
|
|
202
207
|
```
|
|
203
208
|
|
|
204
209
|
This removes Pando-owned `codex`/`claude` shims from `~/.pando/bin`, removes
|
|
205
|
-
the
|
|
206
|
-
`~/.pando/state.json` so
|
|
207
|
-
|
|
210
|
+
the Pando-owned `pando-ai` command shim, removes the managed PATH block from
|
|
211
|
+
your shell startup file when present, and deletes `~/.pando/state.json` so
|
|
212
|
+
declined/install state does not suppress future setup prompts. It does not
|
|
213
|
+
delete policy files, logs, or other user data. If the command is running from a
|
|
214
|
+
global npm install, it also removes that global `pando-ai` package
|
|
215
|
+
automatically. `npx` runs are temporary, so there is no persistent npm package
|
|
216
|
+
to remove in that case.
|
|
208
217
|
|
|
209
|
-
|
|
218
|
+
## MCP serve mode
|
|
219
|
+
|
|
220
|
+
MCP mode is explicit. Bare `pando-ai` always opens the firewall console; it does
|
|
221
|
+
not become an MCP server just because stdin/stdout are non-interactive.
|
|
222
|
+
|
|
223
|
+
Use stdio MCP for agents:
|
|
210
224
|
|
|
211
225
|
```bash
|
|
212
|
-
|
|
226
|
+
pando-ai serve /path/to/project
|
|
213
227
|
```
|
|
214
228
|
|
|
215
|
-
|
|
229
|
+
`serve-http` remains available as an explicit command for debugging or
|
|
230
|
+
integrations that need HTTP:
|
|
231
|
+
|
|
232
|
+
```bash
|
|
233
|
+
pando-ai serve-http /path/to/project --host 127.0.0.1 --port 5888
|
|
234
|
+
```
|
|
216
235
|
|
|
217
|
-
|
|
218
|
-
engine over stdio for the given path, or the current working directory, exactly
|
|
219
|
-
as before. `pando-ai config set telemetry false` disables usage telemetry.
|
|
236
|
+
`pando-ai config set telemetry false` disables usage telemetry.
|
|
220
237
|
|
|
221
238
|
## Transport behavior
|
|
222
239
|
|
|
223
|
-
- MCP
|
|
224
|
-
-
|
|
240
|
+
- MCP does not run by default. Agents should use `pando-ai serve`.
|
|
241
|
+
- HTTP MCP does not run by default. It only starts through explicit
|
|
242
|
+
`pando-ai serve-http`.
|
|
243
|
+
- The CLI redirects incidental runtime logs to stderr so stdout stays valid JSON-RPC/MCP traffic in stdio mode.
|
|
225
244
|
|
|
226
245
|
## Agent setup
|
|
227
246
|
|
package/bin/pando-ai.js
CHANGED
|
@@ -29,10 +29,30 @@ const current = parseNodeVersion(process.version);
|
|
|
29
29
|
if (!isSupportedNode(current)) {
|
|
30
30
|
const detected = current ? `${current.major}.${current.minor}.${current.patch}` : process.version;
|
|
31
31
|
console.error(
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
"\n" +
|
|
33
|
+
`[pando] pando-ai requires Node.js 22.5.0 or newer. Detected ${detected}.\n` +
|
|
34
|
+
"[pando] Please update Node.js, then re-run: npx -y pando-ai\n",
|
|
34
35
|
);
|
|
35
36
|
process.exit(1);
|
|
36
37
|
}
|
|
37
38
|
|
|
39
|
+
const originalEmitWarning = process.emitWarning;
|
|
40
|
+
process.emitWarning = function pandoEmitWarning(warning, ...args) {
|
|
41
|
+
const text =
|
|
42
|
+
typeof warning === "string"
|
|
43
|
+
? warning
|
|
44
|
+
: warning && typeof warning === "object" && "message" in warning
|
|
45
|
+
? String(warning.message)
|
|
46
|
+
: "";
|
|
47
|
+
const type = typeof args[0] === "string" ? args[0] : undefined;
|
|
48
|
+
if (
|
|
49
|
+
type === "ExperimentalWarning" ||
|
|
50
|
+
text.includes("SQLite is an experimental feature") ||
|
|
51
|
+
text.includes("localStorage is not available")
|
|
52
|
+
) {
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
return originalEmitWarning.call(process, warning, ...args);
|
|
56
|
+
};
|
|
57
|
+
|
|
38
58
|
require("../dist/cli.js");
|