@yawlabs/mcp 0.72.0 → 0.73.1

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.
Files changed (3) hide show
  1. package/README.md +147 -413
  2. package/dist/index.js +357 -137
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -1,520 +1,254 @@
1
1
  # @yawlabs/mcp
2
2
 
3
- One install. All your MCP servers. Managed from the cloud.
3
+ **One install. Every MCP server. Managed from one place.**
4
4
 
5
- Yaw MCP (the `yaw-mcp` CLI, package `@yawlabs/mcp`) is an MCP server that fronts every other MCP server you use. Install it once per AI client (Claude Code, Claude Desktop, Cursor, VS Code) and your servers come from your [yaw.sh/mcp](https://yaw.sh/mcp) account instead of a hand-edited `mcpServers` block. It earns its keep when you hit any of these:
5
+ Yaw MCP (the `yaw-mcp` CLI) is an MCP server that fronts every other MCP server you use. Point each AI client (Claude Code, Claude Desktop, Cursor, VS Code) at it once, and your servers load lazily from a single connection instead of a hand-edited `mcpServers` block per client.
6
6
 
7
- - **More than one client or more than one machine.** Add a server once on the dashboard; every client/device picks it up on the next poll. No copy-paste of the same JSON into four config files, no per-machine drift.
8
- - **Tool-context bloat.** The `dispatch` meta-tool ranks your installed servers against the task at hand and loads only the top match(es). A 30-server account stays at a handful of tools in context at any moment instead of surfacing hundreds by default.
9
- - **API tokens you'd rather not sit in disk configs.** Credentials live encrypted on yaw.sh/mcp and inject at spawn time. Rotate once -- every client picks up the new value. Revoke the yaw.sh/mcp token and every install stops working.
10
- - **A trust signal before you activate.** Every scored server renders with its A-F compliance grade in `discover`. Set `YAW_MCP_MIN_COMPLIANCE=B` to refuse anything below.
7
+ Run it free with no account (servers live in a local `bundles.json`), or sign in with a token to manage servers from the [yaw.sh/mcp](https://yaw.sh/mcp) dashboard and sync them across machines.
11
8
 
12
- If you use one client on one machine with a handful of servers, `claude mcp add` or hand-editing `mcp.json` is fine -- yaw-mcp's value shows up when that setup stops scaling.
9
+ It earns its keep when you hit any of these:
10
+
11
+ - **More than one client or machine.** Add a server once; every client/device picks it up on the next poll. No copy-pasting the same JSON into four config files.
12
+ - **Tool-context bloat.** The `dispatch` meta-tool ranks your servers against the task and loads only the top match. A 30-server account keeps a handful of tools in context at a time instead of hundreds.
13
+ - **Tokens you'd rather not leave in disk configs.** Credentials live encrypted (on the dashboard, or in a local vault) and inject at spawn time. Rotate once; every client picks up the new value.
14
+ - **A trust signal before you activate.** Every scored server shows an A-F compliance grade. Set `YAW_MCP_MIN_COMPLIANCE=B` to refuse anything below.
15
+
16
+ One client, one machine, a few servers? `claude mcp add` is fine -- yaw-mcp's value shows up when that setup stops scaling.
13
17
 
14
18
  ## How it works
15
19
 
16
20
  ```
17
- Your MCP client (Claude Code, Cursor, etc.)
21
+ Your MCP client (Claude Code, Cursor, ...)
18
22
  |
19
23
  | single stdio connection
20
24
  v
21
- @yawlabs/mcp
22
- | | |
23
- v v v
24
- GitHub Slack Stripe <- your MCP servers (local or remote)
25
+ @yawlabs/mcp --lazy load--> GitHub | Slack | Stripe | ... (your servers)
25
26
  ```
26
27
 
27
- 1. You add servers on [yaw.sh/mcp](https://yaw.sh/mcp) (name, command, args, env vars)
28
- 2. yaw-mcp pulls your config on startup
29
- 3. You use a handful of meta-tools to control which servers' tools are loaded in the current session:
30
- - **`mcp_connect_dispatch`** -- describe a task in plain English; yaw-mcp picks the right server, loads its tools, and exposes them. The fast path when you know what you want.
31
- - **`mcp_connect_discover`** -- list all installed servers, optionally ranked by relevance to a context string. Auto-loads the top match when one server clearly wins.
32
- - **`mcp_connect_activate`** -- load specific servers' tools by namespace.
33
- - **`mcp_connect_deactivate`** -- unload a server and remove its tools from context.
34
- - **`mcp_connect_install`** -- install a new MCP server on your yaw.sh/mcp account.
35
- - **`mcp_connect_import`** -- bulk-import servers from an existing client config (`claude_desktop_config.json`, `mcp.json`, etc.).
36
- - **`mcp_connect_health`** -- show call counts, error rates, and latency per loaded server.
37
- - **`mcp_connect_suggest`** -- surface recurring multi-server workflows yaw-mcp has learned from persisted pack history. When you repeatedly use `gh` -> `linear` -> `slack` for the same kind of task, `suggest` lists the pattern with a ready-to-run `activate` call so you can load the whole pack at once.
38
- - **`mcp_connect_read_tool`** -- return a single tool's schema + docs without activating its server. Reads 1-2 schemas instead of loading a whole catalog when the model only needs a couple of tools from a big server.
39
- - **`mcp_connect_exec`** -- run a short declarative pipeline of tool calls in one round-trip. Steps name namespaced tools + args; `{"$ref": "<stepId>[.path]"}` markers splice prior outputs into later inputs. No eval -- only dot/bracket path resolution. Capped at 16 steps.
40
- - **`mcp_connect_bundles`** -- list curated multi-server presets (DevOps incident, PR review, growth stack, data ops, etc.) and/or match them against your current config. Pair it with `mcp_connect_activate` to load a whole bundle at once.
28
+ 1. Add servers on the dashboard (or `yaw-mcp add <slug>` locally).
29
+ 2. yaw-mcp pulls your config on startup and polls for changes.
30
+ 3. The model uses a handful of **meta-tools** to control which servers' tools are in context. Installing a server puts it on your list; loading it brings its tools into the session.
41
31
 
42
- Installing a server puts it on your account; loading it brings its tools into the current session's context. yaw-mcp loads servers lazily so your context window stays clean.
32
+ | Meta-tool | What it does |
33
+ |-----------|--------------|
34
+ | `mcp_connect_dispatch` | Describe a task in plain English; picks the best server, loads its tools, exposes them in one call. The fast path. |
35
+ | `mcp_connect_discover` | List installed servers, optionally ranked by a context string. Auto-loads the top match when one clearly wins. |
36
+ | `mcp_connect_activate` / `deactivate` | Load / unload specific servers by namespace. |
37
+ | `mcp_connect_install` | Install a new server on your account. |
38
+ | `mcp_connect_import` | Bulk-import servers from an existing client config. |
39
+ | `mcp_connect_read_tool` | Return one tool's schema without loading its server. |
40
+ | `mcp_connect_exec` | Run a short declarative pipeline of tool calls in one round-trip (`{"$ref": "<step>[.path]"}` splices prior outputs; no eval, max 16 steps). |
41
+ | `mcp_connect_bundles` | List curated multi-server presets (PR review, DevOps incident, ...) and match them against your config. |
42
+ | `mcp_connect_suggest` | Surface recurring multi-server workflows learned from usage, with a ready-to-run `activate` call. |
43
+ | `mcp_connect_secrets` | Show which local-vault secrets each server's `${secret:NAME}` refs resolve to -- by name only, never a value. |
44
+ | `mcp_connect_health` | Call counts, error rates, and latency per loaded server. |
43
45
 
44
- Ranking is two-stage when the backend has a Voyage embeddings key configured: a local BM25 pass narrows to a shortlist, then a `/api/connect/rerank` call semantically reorders. With no key on the backend it gracefully degrades to BM25-only -- `dispatch` and `discover(context)` keep working, just with slightly weaker ranking on ambiguous queries.
46
+ **Ranking.** dispatch/discover rank with BM25. When the backend has a Voyage embeddings key, a `/api/connect/rerank` call semantically reorders the shortlist; with no key it degrades to BM25-only. On top of the ranker, three client-side signals adjust scores:
45
47
 
46
- On top of the ranker, yaw-mcp applies three client-side signals to dispatch scores:
48
+ - **Health-aware** -- servers that recently failed or error often get down-ranked (never boosted above raw).
49
+ - **Learning** -- servers that succeeded before get a small nudge (+10% max), persisted across restarts.
50
+ - **Sampling tiebreak** -- when the top two are within 10% and your client supports [MCP sampling](https://modelcontextprotocol.io/specification/server/sampling), yaw-mcp asks your own model to pick (no extra provider key or cost).
47
51
 
48
- - **Health-aware**: servers that have recently failed to load or have high error rates get down-ranked. Never boosts above raw -- "all else equal, prefer the one that works".
49
- - **Learning**: servers that have succeeded before get a small (+10% max) nudge, so the router remembers what's been useful. Success counts persist across restarts via `~/.yaw-mcp/state.json` (opt out with `YAW_MCP_DISABLE_PERSISTENCE=1`).
50
- - **Sampling tiebreak**: when the top two candidates are within 10% of each other and your client supports [MCP sampling](https://modelcontextprotocol.io/specification/server/sampling), yaw-mcp asks your client's LLM to pick. Uses the model you're already running -- no extra provider key, no extra cost to yaw-mcp.
52
+ Servers auto-unload after ~10 tool calls to other servers, so context stays clean even if you forget. The threshold is adaptive per namespace (`[5, 50]`): bursty servers get more patience, long-idle ones unload at the baseline.
51
53
 
52
54
  ## Install
53
55
 
54
56
  ### One command (recommended)
55
57
 
56
58
  ```bash
57
- npx -y @yawlabs/mcp@latest install <claude-code|claude-desktop|cursor|vscode> --token mcp_pat_your_token_here
59
+ npx -y @yawlabs/mcp@latest install <claude-code|claude-desktop|cursor|vscode> --token mcp_pat_your_token
58
60
  ```
59
61
 
60
- This:
61
-
62
- 1. Edits the chosen client's config file (correct path for your OS, correct JSON shape) to launch yaw-mcp.
63
- 2. Writes your token to `~/.yaw-mcp/config.json` so every other client you install picks it up automatically -- no need to copy the token into each client's `env` block.
64
- 3. On Windows, wraps `npx` in `cmd /c` (without this, MCP clients hit `ENOENT` on the `npx.cmd` shim).
65
-
66
- Run it once per client. To rotate the token later, run `install` again with `--token` -- both files get rewritten.
62
+ This edits the chosen client's config (correct path + JSON shape for your OS) to launch yaw-mcp, and writes your token to `~/.yaw-mcp/config.json` so every other client picks it up automatically. On Windows it wraps `npx` in `cmd /c` (without which MCP clients hit `ENOENT` on the `npx.cmd` shim). Run it once per client; re-run with `--token` to rotate.
67
63
 
68
- Helpful flags:
64
+ Useful flags:
69
65
 
70
66
  - `--scope user|project|local` -- which file to write (Claude Code + Cursor support project/local; VS Code is workspace-only; Claude Desktop is user-only).
71
67
  - `--dry-run` -- print the diff and exit without writing.
72
- - `--force` / `--skip` -- overwrite or leave an existing `mcp` entry. Without either, yaw-mcp prompts (TTY) or refuses (non-TTY).
73
- - `--no-yaw-mcp-config` -- write only the client config; leave `~/.yaw-mcp/config.json` untouched.
74
-
75
- Or install into every detected client at once:
76
-
77
- ```bash
78
- yaw-mcp install --list # read-only: detect clients + show install state per scope
79
- yaw-mcp install --all --token mcp_pat_... # one-shot: install into every user-scope client on this machine
80
- ```
81
-
82
- `--list` never writes (no token needed). `--all` installs into every client whose user-scope target is resolvable on this OS -- Claude Desktop is skipped on Linux, VS Code is skipped unless `--project-dir` is given (it's workspace-only). Aggregate exit code is non-zero if any sub-install fails.
83
-
84
- Or [edit the JSON by hand](#manual-install) if you'd rather.
85
-
86
- > The launch entry is keyed as `"mcp"` in the client config, so its tools surface under the `mcp__mcp__` namespace. Installs created before the rename used `"mcp.hosting"` / `"yaw-mcp"`; `yaw-mcp install` (and Yaw Terminal) detect and migrate those to `"mcp"`.
87
-
88
- ### Diagnose problems -- `yaw-mcp doctor`
89
-
90
- ```bash
91
- npx -y @yawlabs/mcp@latest doctor # human-readable report
92
- npx -y @yawlabs/mcp@latest doctor --json # machine-readable snapshot for pipelines
93
- ```
94
-
95
- Prints the loaded config files, your token's source + fingerprint (last 4 chars), the API base URL, installed clients, env overrides, persisted learning state, flaky-namespace reliability rollup, shell-history "shadow" hits (CLIs you run that an MCP server could replace), and an upgrade check against the npm registry. Exits `0` healthy / `1` no token / `2` warnings (e.g. world-readable token file). Paste the text output into a support ticket; the `--json` blob is the same data as a structured snapshot, so dashboards and CI scripts can `jq` instead of parsing the text layout.
96
-
97
- ### Add servers locally (no account) -- `add` / `remove` / `list`
98
-
99
- In Free (no-account) mode, yaw-mcp loads servers from `~/.yaw-mcp/bundles.json`.
100
- Manage that set from the catalog at [yaw.sh/mcp/catalog](https://yaw.sh/mcp/catalog/):
101
-
102
- ```bash
103
- yaw-mcp add <slug> # resolve a catalog server and write it into bundles.json
104
- yaw-mcp add github --env GITHUB_PERSONAL_ACCESS_TOKEN=ghp_... # supply a required env value
105
- yaw-mcp add <slug> --dry-run [--json] # preview the entry without writing
106
- yaw-mcp remove <slug-or-namespace> # drop a server from bundles.json
107
- yaw-mcp list [--json] # list the servers yaw-mcp loads locally
108
- ```
109
-
110
- `add` is NOT `install`: `install <client>` connects an AI client to yaw-mcp;
111
- `add <slug>` adds an MCP server to yaw-mcp itself. Required env keys are seeded
112
- empty and only a value passed via `--env` is written to disk (yaw-mcp inherits
113
- your shell env when it spawns the server, so an ambient secret reaches it at
114
- runtime without being persisted). The same one-click lives on the website as
115
- the "Add to Yaw MCP" button.
116
-
117
- ### Try a server for an hour -- `try`
118
-
119
- ```bash
120
- yaw-mcp try <slug> [--client <name>] [--ttl 1h] [--env KEY=value] # wire a one-off trial directly into your AI client
121
- yaw-mcp try-cleanup <slug> # remove a wired trial early (doctor GCs expired ones)
122
- ```
123
-
124
- `try` points the AI client straight at the upstream server (bypassing yaw-mcp)
125
- so you can evaluate it without an account; the entry expires after `--ttl`.
126
-
127
- ### Other CLI subcommands
128
-
129
- ```bash
130
- yaw-mcp servers [<namespace-filter>] [--json] # list servers; optional substring filter on namespace
131
- yaw-mcp bundles [list|match] [--json] # browse curated multi-server bundles (PR review, DevOps incident, etc.)
132
- yaw-mcp reset-learning # clear cross-session learning history (~/.yaw-mcp/state.json)
133
- yaw-mcp completion <bash|zsh|fish|powershell> # print shell completion script
134
- yaw-mcp upgrade [--run] [--json] # show (or execute) the command that bumps @yawlabs/mcp
135
- yaw-mcp compliance <target> [--publish] # run the compliance suite against an MCP server
136
- yaw-mcp --version # print version
137
- ```
68
+ - `--force` / `--skip` -- overwrite or leave an existing `mcp` entry (otherwise prompts on a TTY, refuses off-TTY).
69
+ - `--no-yaw-mcp-config` -- write only the client config; leave `~/.yaw-mcp/config.json` alone.
138
70
 
139
- Account / sync (Yaw Team -- a license key unlocks cross-machine bundle sync):
71
+ Or do every detected client at once:
140
72
 
141
73
  ```bash
142
- yaw-mcp login [--key <license>] # authenticate this machine with a Yaw MCP account
143
- yaw-mcp logout # sign this machine out
144
- yaw-mcp sync <push|pull|status> [--json] # replicate bundles.json to/from the account store (env values stripped on push)
145
- yaw-mcp secrets <set|get|list|remove|lock|push|pull> # manage synced secret VALUES
146
- yaw-mcp stats [--limit N] [--days N] [--json] # account usage statistics
74
+ yaw-mcp install --list # detect clients + show install state (read-only, no token)
75
+ yaw-mcp install --all --token mcp_pat_... # install into every user-scope client on this machine
147
76
  ```
148
77
 
149
- Every CLI that reads state has a `--json` mode for pipeline use. `yaw-mcp servers` hits the backend; `yaw-mcp bundles list` and `yaw-mcp completion` are fully static (no network, no token). `yaw-mcp bundles match` partitions the curated set against your enabled servers so you see the same ready-to-activate vs. partially-installed view the LLM-facing `mcp_connect_bundles` meta-tool produces.
150
-
151
- To wire up shell completion:
152
-
153
- ```bash
154
- # bash
155
- yaw-mcp completion bash > ~/.local/share/bash-completion/completions/yaw-mcp
156
-
157
- # zsh (must be on $fpath, then rebuild compinit)
158
- yaw-mcp completion zsh > "${fpath[1]}/_yaw-mcp"
159
-
160
- # fish
161
- yaw-mcp completion fish > ~/.config/fish/completions/yaw-mcp.fish
162
-
163
- # powershell
164
- yaw-mcp completion powershell >> $PROFILE
165
- ```
78
+ > The launch entry is keyed `"mcp"`, so its tools surface under the `mcp__mcp__` namespace. Installs made before the rename used `"mcp.hosting"` / `"yaw-mcp"`; `yaw-mcp install` detects and migrates those.
166
79
 
167
80
  ### Getting your token
168
81
 
169
- 1. Sign up at [yaw.sh/mcp](https://yaw.sh/mcp)
170
- 2. Go to **Settings > Tokens**
171
- 3. Create a token -- it starts with `mcp_pat_`
172
- 4. Pass it to `yaw-mcp install` as shown above
82
+ 1. Sign up at [yaw.sh/mcp](https://yaw.sh/mcp).
83
+ 2. **Settings > Tokens** -> create a token (starts with `mcp_pat_`).
84
+ 3. Pass it to `yaw-mcp install` as above.
173
85
 
174
86
  ### Manual install
175
87
 
176
- If you'd rather edit the config files yourself, the JSON shapes are:
177
-
178
- **Claude Code, Cursor, Claude Desktop** -- top-level key `mcpServers`:
88
+ The JSON shape (top-level `mcpServers`, except VS Code uses `servers` in `.vscode/mcp.json`):
179
89
 
180
90
  ```json
181
91
  {
182
92
  "mcpServers": {
183
- "mcp": {
184
- "command": "npx",
185
- "args": ["-y", "@yawlabs/mcp@latest"]
186
- }
93
+ "mcp": { "command": "npx", "args": ["-y", "@yawlabs/mcp@latest"] }
187
94
  }
188
95
  }
189
96
  ```
190
97
 
191
- **VS Code** -- top-level key `servers` (NOT `mcpServers`) in `.vscode/mcp.json`:
98
+ On **Windows**, use `"command": "cmd", "args": ["/c", "npx", "-y", "@yawlabs/mcp@latest"]`. Put your token in `~/.yaw-mcp/config.json` (`{ "version": 1, "token": "mcp_pat_..." }`) or set `YAW_MCP_TOKEN` in the client's `env` block.
192
99
 
193
- ```json
194
- {
195
- "servers": {
196
- "mcp": {
197
- "command": "npx",
198
- "args": ["-y", "@yawlabs/mcp@latest"]
199
- }
200
- }
201
- }
202
- ```
100
+ ## CLI
203
101
 
204
- **Windows** -- `command: "cmd", args: ["/c", "npx", "-y", "@yawlabs/mcp@latest"]` (the `cmd /c` wrapper is required because `npx.cmd` is a shim).
102
+ `yaw-mcp` with no subcommand runs as the MCP server. No token needed: without one it serves your local `~/.yaw-mcp/bundles.json`; with a token it also pulls your account's servers. Most read-only subcommands accept `--json`. Run `yaw-mcp <cmd> --help` for per-command flags.
205
103
 
206
- Then put your token in `~/.yaw-mcp/config.json` so yaw-mcp picks it up at startup:
207
-
208
- ```json
209
- {
210
- "version": 1,
211
- "token": "mcp_pat_your_token_here"
212
- }
213
- ```
214
-
215
- Or set `YAW_MCP_TOKEN` in the client's `env` block -- both work.
216
-
217
- ## Adding servers
218
-
219
- On [yaw.sh/mcp](https://yaw.sh/mcp), add each MCP server you want to orchestrate:
220
-
221
- | Field | Description |
222
- |-------|-------------|
223
- | **Name** | Display name (e.g., "GitHub") |
224
- | **Namespace** | Short prefix for tool names (e.g., "gh") |
225
- | **Type** | `local` (stdio) or `remote` (HTTP) |
226
- | **Command** | For local: the command to run (e.g., "npx") |
227
- | **Args** | For local: command arguments (e.g., ["-y", "@modelcontextprotocol/server-github"]) |
228
- | **Env** | Environment variables (API keys, tokens) |
229
- | **URL** | For remote: the server URL |
230
-
231
- ## Usage
232
-
233
- ### Fast path -- `dispatch`
234
-
235
- When you know what you want to do, skip the discover/load dance:
236
-
237
- ```
238
- > Create a GitHub issue for the login bug
104
+ **Setup**
239
105
 
240
- [mcp_connect_dispatch is called with intent="create a GitHub issue for the login bug"]
241
-
242
- Dispatched "create a GitHub issue for the login bug" -- loaded top 1 of 1 matching server.
243
- gh (score 4.32): Loaded "gh" -- 24 tools: gh_create_issue, gh_list_prs, ...
244
-
245
- [gh_create_issue is then called, returns the new issue]
106
+ ```bash
107
+ yaw-mcp install <client> # connect a client to yaw-mcp (see above)
108
+ yaw-mcp doctor [--json] # diagnose config, token, clients, learning, reliability, upgrade
246
109
  ```
247
110
 
248
- `dispatch` ranks every installed server, loads the top match's tools, and immediately exposes them so the LLM can call them. Default budget is 1 (one server). For tasks that need multiple servers, pass `budget: 3` etc.
249
-
250
- ### Manual control
111
+ **Local servers (no account)** -- managed in `~/.yaw-mcp/bundles.json`, browse the catalog at [yaw.sh/mcp/explore](https://yaw.sh/mcp/explore):
251
112
 
113
+ ```bash
114
+ yaw-mcp add <slug> [--env KEY=value] [--dry-run] # add a catalog server to bundles.json
115
+ yaw-mcp remove <slug-or-namespace> # drop a server
116
+ yaw-mcp list [--json] # list locally loaded servers
117
+ yaw-mcp try <slug> [--client <name>] [--ttl 1h] # wire a one-off trial straight into your client (expires)
118
+ yaw-mcp try-cleanup <slug> # remove a trial early (doctor GCs expired ones)
252
119
  ```
253
- > What MCP servers do I have?
254
-
255
- Installed MCP servers:
256
120
 
257
- gh -- GitHub [ready] (local)
258
- slack -- Slack [ready] (local)
259
- stripe -- Stripe [ready] (local)
121
+ `add` is not `install`: `install <client>` connects an AI client to yaw-mcp; `add <slug>` adds an MCP server to yaw-mcp itself. `try` points the client directly at the upstream server, bypassing yaw-mcp, so you can evaluate it without an account.
260
122
 
261
- 0 loaded in this session, 0 tools in context.
262
- ```
123
+ **Inspection & maintenance**
263
124
 
264
- ```
265
- > Load my GitHub server
266
-
267
- Loaded "gh" -- 24 tools: gh_create_issue, gh_list_prs, ...
125
+ ```bash
126
+ yaw-mcp servers [<filter>] [--json] # list dashboard servers (optional namespace substring filter)
127
+ yaw-mcp bundles [list|match] [--json] # browse curated bundles; match partitions against your enabled servers
128
+ yaw-mcp upgrade [--run] [--json] # show (or run) the command that bumps @yawlabs/mcp
129
+ yaw-mcp reset-learning # clear cross-session learning (~/.yaw-mcp/state.json)
130
+ yaw-mcp completion <bash|zsh|fish|powershell> # print a shell-completion script
268
131
  ```
269
132
 
270
- You can load multiple at once: `> Load GitHub and Slack`. Tools are namespaced as `{namespace}_{original_tool_name}` to prevent collisions. The tool list updates automatically via `tools/list_changed`.
133
+ **Compliance**
271
134
 
135
+ ```bash
136
+ yaw-mcp compliance <target> [--publish] # run the 88-test compliance suite; --publish posts the report + prints a URL
137
+ yaw-mcp audit <namespace> # audit a stdio server from bundles.json, cache its A-F grade in grades.json
272
138
  ```
273
- > Unload GitHub when you're done
274
139
 
275
- Unloaded "gh". Tools removed from context.
276
- ```
140
+ To install completion, redirect to your shell's completions dir, e.g. `yaw-mcp completion zsh > "${fpath[1]}/_yaw-mcp"`, or `yaw-mcp completion powershell >> $PROFILE`.
277
141
 
278
- Servers also auto-unload after ~10 tool calls to other servers, so context stays clean even if you forget. The threshold is adaptive per-namespace: a server that's been called in bursts recently gets more patience (up to +20) before it's unloaded, so heavily-used servers don't get torn down mid-task. Long-idle servers still unload at the baseline.
142
+ ## Adding servers on the dashboard
279
143
 
280
- ## `.yaw-mcp/` config directory
144
+ On [yaw.sh/mcp](https://yaw.sh/mcp), each server has a **name**, **namespace** (tool prefix, e.g. `gh` -> `gh_create_issue`), **type** (`local` stdio or `remote` HTTP), **command + args** (local) or **URL** (remote), and an **env** block for API keys. Credentials are encrypted at rest and injected at spawn time -- they never sit in a client config.
281
145
 
282
- yaw-mcp stores its config under a `.yaw-mcp/` directory -- mirroring the `.git/`, `.vscode/`, `.claude/` convention so everything related to yaw-mcp (config, project guide, future additions) lives under one predictable folder you can grep, gitignore, or blow away atomically. yaw-mcp reads `config.json` from three optional locations (highest precedence first):
146
+ ## Configuration -- `.yaw-mcp/`
283
147
 
284
- | Scope | Path | Holds |
285
- |-------|------|-------|
286
- | **local** | `<project>/.yaw-mcp/config.local.json` | Machine-local override; `gitignore` it. Token allowed. |
287
- | **project** | `<project>/.yaw-mcp/config.json` | Shared with the team via git. Token NOT allowed (warned). |
288
- | **global** | `~/.yaw-mcp/config.json` | Personal default for every project. Token allowed. |
148
+ yaw-mcp keeps its config under a `.yaw-mcp/` directory (mirroring `.git/`, `.vscode/`, `.claude/`). It reads `config.json` from three optional scopes, highest precedence first:
289
149
 
290
- The project `.yaw-mcp/` is found by walking UP from the current directory until a `.yaw-mcp/` is found, stopping just before `$HOME` (exclusive) so a `.yaw-mcp/` sitting at `$HOME` is treated as user-global only and never double-loaded as project.
150
+ | Scope | Path | Token allowed? |
151
+ |-------|------|----------------|
152
+ | **local** | `<project>/.yaw-mcp/config.local.json` | Yes -- machine-local, gitignore it. |
153
+ | **project** | `<project>/.yaw-mcp/config.json` | No -- shared via git (warned; it would be committed). |
154
+ | **global** | `~/.yaw-mcp/config.json` | Yes -- personal default for every project. |
291
155
 
292
- Full schema:
156
+ The project `.yaw-mcp/` is found by walking up from the cwd, stopping just before `$HOME` so a `.yaw-mcp/` at `$HOME` is treated as global only. Files may contain `//` and `/* */` comments. Full schema:
293
157
 
294
158
  ```jsonc
295
159
  {
296
- // Schema version. yaw-mcp emits version 1; older fields stay
297
- // readable. Newer versions log a warning so an old yaw-mcp can't
298
- // silently miss new fields.
299
- "version": 1,
300
-
301
- // Personal access token from yaw.sh/mcp -> Settings -> Tokens.
302
- // env YAW_MCP_TOKEN still wins over the file value.
303
- "token": "mcp_pat_your_token_here",
304
-
305
- // API base override -- point yaw-mcp at a self-hosted backend or staging.
306
- // Defaults to https://yaw.sh/mcp. env YAW_MCP_URL still wins.
307
- "apiBase": "https://yaw.sh/mcp",
308
-
309
- // Project profile: which namespaces are allowed.
310
- "servers": ["gh", "pg", "linear"],
311
-
312
- // Project profile: namespaces denied even if in `servers`.
313
- "blocked": ["prod-db"]
160
+ "version": 1, // schema version; newer versions log a warning
161
+ "token": "mcp_pat_...", // yaw.sh/mcp token; env YAW_MCP_TOKEN wins
162
+ "apiBase": "https://yaw.sh/mcp", // backend override; env YAW_MCP_URL wins
163
+ "servers": ["gh", "pg", "linear"], // allow-list of namespaces (most-specific scope wins)
164
+ "blocked": ["prod-db"] // deny-list (UNION across all scopes -- fail-safe on deny)
314
165
  }
315
166
  ```
316
167
 
317
- **Comments are allowed** (line `//` and block `/* ... */`) -- handy for documenting a shared `config.json` checked into git.
318
-
319
- **Resolution:**
320
-
321
- - **Token** -- `YAW_MCP_TOKEN` env > local > global. (`token` in the project file is ignored and warned: it'd get committed to git.)
322
- - **apiBase** -- `YAW_MCP_URL` env > local > project > global > `https://yaw.sh/mcp`.
323
- - **servers** allow-list -- local wins if set, else project, else global (most-specific scope overrides).
324
- - **blocked** deny-list -- UNION across every scope that sets it (fail-safe on deny).
325
- - Malformed files log a warning and fall through -- fail-open so a typo doesn't brick the session.
326
- - On POSIX, yaw-mcp warns if the file contains a token and is readable by group/other; run `chmod 600 ~/.yaw-mcp/config.json` to silence it.
327
-
328
- **Token rotation**: yaw-mcp reads its config at startup. After editing `~/.yaw-mcp/config.json`, restart the MCP client (or kill yaw-mcp; the client respawns it).
329
-
330
- `mcp_connect_health` shows which file(s) are currently applied.
331
-
332
- ## Project guide -- `YAW-MCP.md`
333
-
334
- Drop a `YAW-MCP.md` next to `config.json` inside either `.yaw-mcp/` and yaw-mcp surfaces its contents to your client via a `yaw-mcp://guide` MCP resource. The meta-tool descriptions (`discover`, `dispatch`) tell the model to read this resource first, so project-specific routing conventions ("use the `gh` server for GitHub, not bash") and credential guidance ("keys go in the dashboard, not `.mcp.json`") stick without the user restating them every session.
168
+ Resolution: **token** = `YAW_MCP_TOKEN` env > local > global (project token ignored + warned). **apiBase** = `YAW_MCP_URL` env > local > project > global. Malformed files log a warning and fall through (fail-open). On POSIX, yaw-mcp warns if a token file is group/other-readable (`chmod 600` to silence). yaw-mcp reads config at startup, so restart the client after editing; `mcp_connect_health` shows which files are applied.
335
169
 
336
- | Scope | Path | Purpose |
337
- |-------|------|---------|
338
- | **user** | `~/.yaw-mcp/YAW-MCP.md` | Personal defaults that apply everywhere (your preferred tools, credential conventions). |
339
- | **project** | `<project>/.yaw-mcp/YAW-MCP.md` | Project-specific guidance shared via git (which servers are load-bearing, project idioms). |
340
-
341
- When both exist, the project guide is appended after the user guide with a `---` separator so project-specific rules get the final word in the reader's attention. A missing or empty file is silently skipped -- if neither file exists, the `yaw-mcp://guide` resource isn't listed at all.
342
-
343
- ## Elicitation for missing credentials
344
-
345
- When a server fails to start with stderr like `GITHUB_TOKEN is required` and your client advertises the MCP [elicitation](https://modelcontextprotocol.io/specification/server/elicitation) capability, yaw-mcp prompts you for the missing value inline and retries the load. Values stay in-memory for the current yaw-mcp session only -- persist them in the yaw.sh/mcp dashboard if you want them across restarts.
346
-
347
- ### Errors come with deep-links
348
-
349
- When a load fails (missing token, runtime not on PATH, server crashes on init), yaw-mcp emits a message ending with `-> Edit at https://yaw.sh/mcp/dashboard/connect#server-<id>`. Most LLMs render that as a clickable link, and the dashboard scrolls to and highlights the matching card so you find the right server in one click.
350
-
351
- ## Config sync
170
+ ### Project guide -- `YAW-MCP.md`
352
171
 
353
- yaw-mcp polls [yaw.sh/mcp](https://yaw.sh/mcp) every 60 seconds for config changes. When you add, remove, or modify a server on the dashboard, yaw-mcp picks it up automatically -- no restart needed.
172
+ Drop a `YAW-MCP.md` next to `config.json` in either `.yaw-mcp/` and yaw-mcp surfaces it via a `yaw-mcp://guide` MCP resource. The `discover`/`dispatch` descriptions tell the model to read it first, so project routing conventions ("use the `gh` server, not bash") and credential guidance stick without restating them each session. A user guide (`~/.yaw-mcp/YAW-MCP.md`) and a project guide are concatenated with the project one last; a missing file is skipped silently.
354
173
 
355
- ### Multi-device sync
174
+ ## Local secret vault (no account)
356
175
 
357
- Because every yaw-mcp install reads the same account's server list, the same token gives you the same servers across every machine. Install yaw-mcp on a second laptop with the same `mcp_pat_...`, and within 60 seconds it sees the same GitHub/Slack/Stripe/etc. servers you configured from the first. Tokens, environment variables, and credentials stay in the dashboard -- you don't have to sync a JSON file across machines, copy secrets into a dotfile repo, or re-paste an API key per device.
358
-
359
- Rotate a credential in one place (the dashboard), every machine picks up the new value on the next poll. Revoke a token in Settings -> Tokens, every install stops working immediately (the token is the only thing authenticating the config pull). This is why `~/.yaw-mcp/config.json` holds a token, not a server list -- the server list is the cloud's concern.
360
-
361
- ## Environment variables
362
-
363
- | Variable | Required | Description |
364
- |----------|----------|-------------|
365
- | `YAW_MCP_TOKEN` | Yes (or in `~/.yaw-mcp/config.json`) | Personal access token from yaw.sh/mcp. Env wins over `~/.yaw-mcp/config.json`. |
366
- | `YAW_MCP_URL` | No | API URL (default: `https://yaw.sh/mcp`). Env wins over `apiBase` in `config.json`. |
367
- | `LOG_LEVEL` | No | Log verbosity: `debug`, `info`, `warn`, `error` (default: `info`) |
368
- | `YAW_MCP_POLL_INTERVAL` | No | Config-poll interval in seconds. `0` disables polling (config fetched once at startup). Default: `60` |
369
- | `YAW_MCP_AUTO_ACTIVATE` | No | When `discover` is called with a context string and one server clearly wins, auto-load it. Set to `0` to disable. Default: enabled |
370
- | `YAW_MCP_AUTO_UPGRADE` | No | When yaw-mcp starts as a server, runs a non-blocking background check for a newer npm/pnpm/bun global install and upgrades quietly with the owning tool. Set to `0` to disable. Default: enabled. |
371
- | `YAW_MCP_SERVER_CAP` | No | Hard cap on concurrently activated servers. Default: `6`. Set to `0` to disable. |
372
- | `YAW_MCP_PRUNE_RESPONSES` | No | Conservative response pruning (redact large file blobs etc. before returning to the client). Set to `0` or `false` to disable. Default: enabled. |
373
- | `YAW_MCP_DISABLE_PERSISTENCE` | No | Set to `1` or `true` to keep learning + pack-history scoped to the current process -- nothing loaded at start, nothing written on shutdown. Intended for ephemeral / shared environments (CI, containers). Default: cross-session persistence enabled at `~/.yaw-mcp/state.json`. |
374
- | `YAW_MCP_AUTO_LOAD` | No | Set to `1` or `true` to pre-activate the top recurring pack (from persisted pack-history) on startup -- no LLM round-trip required. Skips silently when history is empty or no pack's namespaces are all installed. Default: off. Requires persistence to be enabled. |
375
- | `YAW_MCP_MIN_COMPLIANCE` | No | Minimum compliance grade (`A`, `B`, `C`, `D`, or `F`, case-insensitive) an installed server must report before `mcp_connect_activate` will load it. Ungraded servers always pass (don't punish unknown). `discover()` annotates below-grade servers in place and shows a "Compliance filter active" header when set. Invalid values log a warning and disable the filter. Default: unset (no filter). |
376
- | `YAW_MCP_VAULT_PASSPHRASE` | No | Passphrase for the local secret vault (`~/.yaw-mcp/secrets.json`). Required for spawn-time `${secret:NAME}` substitution and to avoid the interactive prompt on `yaw-mcp secrets`. Stripped from every spawned upstream server's env. |
377
- | `YAW_MCP_VAULT_PASSPHRASE_NEW` | No | The NEW passphrase for `yaw-mcp secrets rotate`. When unset, rotate prompts (confirm-twice) on a TTY instead. |
378
- | `MCP_CONNECT_TIMEOUT` | No | Connection timeout in ms for upstream servers (default: `15000`) |
379
- | `MCP_CONNECT_IDLE_THRESHOLD` | No | Baseline for idle auto-unload (default: `10`). The per-namespace adaptive cap is `[5, 50]` -- bursty namespaces extend past the baseline, long-idle ones unload at it. |
380
-
381
- ## Runtime detection
382
-
383
- On startup, yaw-mcp probes your machine for `node`, `npx`, `python`, `uvx`, and `docker` and reports the snapshot to yaw.sh/mcp. The dashboard uses this to warn before you add a catalog server whose runtime isn't installed (e.g., adding the Sentry server when Python isn't on your PATH). No prompt, no LLM round-trip -- just a yellow banner on the Add Server form.
384
-
385
- The detection is best-effort: each probe has a 3-second timeout and missing runtimes are recorded as absent rather than blocking startup. yaw-mcp itself only requires Node.js -- every other runtime is optional and only matters for servers that need it.
386
-
387
- ### Automatic `uv` bootstrap
388
-
389
- The popular Python-based MCP servers (`sqlite`, `time`, `sentry`, and other uvx-launched entries) all launch via Astral's `uv`/`uvx`. yaw-mcp ships its own bootstrap for these: on first encounter with a `uv`/`uvx` command, if the binary isn't on your PATH, yaw-mcp lazily downloads Astral's standalone `uv` release, verifies the sha256, and caches it under the platform-appropriate cache dir. Subsequent loads reuse the cached binary. If you already have `uv` installed, yaw-mcp uses your version and never downloads.
390
-
391
- `uvx ARGS` is always rewritten to `uv tool run ARGS` at spawn time -- so only `uv` needs to be reachable, not `uvx` separately. Fixes Windows setups where one was on PATH and the other wasn't.
392
-
393
- ## Local secret vault (no account required)
394
-
395
- There are two ways a secret reaches a server yaw-mcp spawns, and they have
396
- different threat models:
397
-
398
- 1. **Backend-credential path (account required).** Paste a token into a
399
- server's `env` block in the yaw.sh/mcp dashboard. The value is encrypted
400
- at rest on the backend and injected at spawn time. It syncs across every
401
- machine signed in to the same account, and revoking the account token cuts
402
- off access everywhere on the next poll. This is the path the
403
- "Cross-machine config sync" and "Trust & security" sections describe.
404
-
405
- 2. **Local secret vault (no account required).** Keep the value in an
406
- encrypted file on your own machine at `~/.yaw-mcp/secrets.json` and
407
- reference it from any server's `env` with a `${secret:NAME}` placeholder.
408
- yaw-mcp substitutes the decrypted value into the child env at spawn time.
409
- The value never leaves your machine, never goes to the backend, and works
410
- with no login. This is the right path when you want a credential that is
411
- strictly local to one machine, or you don't have an account at all.
412
-
413
- ### How `${secret:NAME}` references work
414
-
415
- Put a placeholder in a server's `env` value -- it can stand alone or be
416
- composed inline:
176
+ Besides pasting credentials into the dashboard, you can keep a value in an encrypted file on your own machine and reference it from any server's `env` with a `${secret:NAME}` placeholder:
417
177
 
418
178
  ```jsonc
419
- {
420
- "namespace": "gh",
421
- "command": "npx",
422
- "args": ["-y", "@modelcontextprotocol/server-github"],
423
- "env": {
424
- "GITHUB_PERSONAL_ACCESS_TOKEN": "${secret:gh}",
425
- "AUTH_HEADER": "Bearer ${secret:gh}"
426
- }
179
+ "env": {
180
+ "GITHUB_PERSONAL_ACCESS_TOKEN": "${secret:gh}",
181
+ "AUTH_HEADER": "Bearer ${secret:gh}" // placeholders compose inline
427
182
  }
428
183
  ```
429
184
 
430
- At spawn time, if `YAW_MCP_VAULT_PASSPHRASE` is set in yaw-mcp's own
431
- environment, yaw-mcp loads the vault, decrypts the referenced names, and
432
- substitutes the values into the child's env. If the passphrase is absent, the
433
- vault is missing, or a referenced name isn't stored, the literal
434
- `${secret:NAME}` is passed through unchanged -- the child then surfaces its
435
- own "missing/invalid credential" error, which is louder than silently passing
436
- an empty string.
437
-
438
- ### Managing the vault -- `yaw-mcp secrets`
185
+ At spawn time, if `YAW_MCP_VAULT_PASSPHRASE` is set in yaw-mcp's own env, it decrypts the referenced names and substitutes them into the child's env. If the passphrase is absent or a name isn't stored, the literal `${secret:NAME}` passes through unchanged, so the child surfaces its own "missing credential" error rather than an empty string. The value never leaves your machine.
439
186
 
440
187
  ```bash
441
- yaw-mcp secrets set <name> # store a value (stdin prompt, no echo; or --value/--stdin)
188
+ yaw-mcp secrets set <name> # store a value (no-echo prompt, or --value/--stdin)
442
189
  yaw-mcp secrets get <name> # decrypt and print one value
443
- yaw-mcp secrets list # show entry NAMES (values stay encrypted)
190
+ yaw-mcp secrets list # show entry NAMES only (values stay encrypted)
444
191
  yaw-mcp secrets remove <name> # delete an entry
445
192
  yaw-mcp secrets lock # clear the in-process passphrase cache
446
- yaw-mcp secrets rotate [--push] # re-encrypt the whole vault under a NEW passphrase
193
+ yaw-mcp secrets rotate # re-encrypt the whole vault under a NEW passphrase
447
194
  yaw-mcp secrets audit [--secret NAME] [--server NS] [--json] # who consumed which secret, when
448
- yaw-mcp secrets push # upload the encrypted blob to your account (login required)
449
- yaw-mcp secrets pull # download it back (login required)
450
195
  ```
451
196
 
452
- The passphrase derives the encryption key via scrypt and is cached in memory
453
- for the lifetime of one yaw-mcp process; the on-disk file only ever holds
454
- ciphertext (AES-256-GCM, per-entry IV + auth tag, one vault-level salt). Set
455
- `YAW_MCP_VAULT_PASSPHRASE` in the env to avoid the prompt -- this is required
456
- for spawn-time substitution, since a spawned MCP server runs non-interactively
457
- and can't prompt on a TTY.
458
-
459
- `rotate` re-encrypts every entry under a fresh salt + key derived from a NEW
460
- passphrase (read from `YAW_MCP_VAULT_PASSPHRASE_NEW` or a confirm-twice
461
- prompt). It decrypts every entry under the current passphrase FIRST and aborts
462
- the whole operation -- leaving the on-disk vault untouched -- if any entry
463
- fails to decrypt. **Rotate re-wraps the ENCRYPTION, not the underlying token
464
- values:** a token that has leaked is still leaked after a rotate; rotate it at
465
- its source. Rotate does NOT push to your account unless you pass `--push`.
466
-
467
- `audit` reads an append-only NDJSON log at `~/.yaw-mcp/secrets-audit.log`
468
- (mode `0600`, tail-capped) recording that a secret NAME was `injected` into
469
- (or was `missing` for) a given server namespace, with a timestamp. **The log
470
- never records a value** -- only names, namespaces, and times. Writes to it are
471
- fail-open: a broken or unwritable log never blocks a server spawn.
472
-
473
- The `mcp_connect_secrets` meta-tool gives the same picture to the model
474
- without any decryption: per server it lists `injectedSecrets` (names the vault
475
- has and the server references) and `missing` (referenced names the vault
476
- lacks). It reads only the vault's key list and the servers' reference names --
477
- it never decrypts or returns a value, and needs no passphrase.
478
-
479
- ### Offline threat model
480
-
481
- The vault protects the on-disk file against **offline brute-force after
482
- exfiltration** -- a stolen laptop, a leaked backup, a synced dotfile repo. The
483
- file is useless without the passphrase: scrypt key derivation makes guessing
484
- expensive, and AES-256-GCM means a tampered ciphertext fails to decrypt rather
485
- than yielding garbage plaintext. What the vault does **not** defend against: a
486
- process running as you while the passphrase is cached in memory (it can ask
487
- yaw-mcp to decrypt), a keylogger capturing the passphrase, or a value already
488
- leaked at its source. For those, rotate the underlying token, not the vault
489
- encryption.
197
+ The passphrase derives the key via scrypt and is cached in memory for one process; the on-disk file holds only ciphertext (AES-256-GCM, per-entry IV + tag, one vault salt). `rotate` decrypts every entry first and aborts untouched if any fails -- and it re-wraps the **encryption**, not the underlying tokens (a leaked token is still leaked; rotate it at its source). `audit` reads an append-only `0600` NDJSON log of secret NAME + namespace + timestamp -- never a value -- and writes fail-open so a broken log never blocks a spawn.
198
+
199
+ **Threat model.** The vault protects the on-disk file against offline brute-force after exfiltration (stolen laptop, leaked backup): useless without the passphrase, tamper-evident via GCM. It does **not** defend against a process running as you while the passphrase is cached, a keylogger, or a value already leaked at its source.
200
+
201
+ ## Runtime detection & `uv` bootstrap
202
+
203
+ On startup yaw-mcp probes for `node`, `npx`, `python`, `uvx`, and `docker` (best-effort, 3s per probe) and reports the snapshot to the dashboard, which warns before you add a server whose runtime is missing. yaw-mcp itself needs only Node.js.
204
+
205
+ Python servers (`sqlite`, `time`, `sentry`, ...) launch via Astral's `uv`/`uvx`. On first encounter, if `uv` isn't on your PATH, yaw-mcp downloads Astral's standalone release, verifies the sha256, and caches it -- reusing your own `uv` if you have one. `uvx ARGS` is always rewritten to `uv tool run ARGS`, so only `uv` needs to be reachable.
490
206
 
491
207
  ## Trust & security
492
208
 
493
- MCP servers are third-party code that you choose to run, and yaw-mcp launches them on your machine or calls them over the network. We don't sandbox arbitrary code and we're not an antivirus -- that's your OS and network. What yaw-mcp gives you is **visibility and a gate**:
209
+ MCP servers are third-party code you choose to run. yaw-mcp doesn't sandbox them -- that's your OS and network. What it gives you is **visibility and a gate**:
494
210
 
495
- - **Compliance grades (A-F)** -- the `@yawlabs/mcp-compliance` suite runs 88 behavioral tests against an MCP server and reports a grade. yaw.sh/mcp publishes grades for catalog servers; `yaw-mcp servers` shows them, and `mcp_connect_discover` surfaces them inline on every listing (e.g., `github -- GitHub [ready] [A]`). Set `YAW_MCP_MIN_COMPLIANCE=B` (or any grade) and `mcp_connect_activate` will refuse to load anything below the floor -- the refusal message spells out the grade and the env var to unset. Ungraded servers always pass (don't punish unknown), so audit unknowns yourself with `yaw-mcp compliance <target>` before you rely on them.
496
- - **Source transparency** -- `yaw-mcp servers` and the yaw.sh/mcp dashboard show the exact `command`, `args`, and `url` each server launches with. Nothing is hidden or wrapped -- if a server is `npx -y @example/foo` you see that, and you can trace it back to npm / GitHub / the remote endpoint before installing.
497
- - **Credentials stay encrypted at rest on yaw.sh/mcp** -- API tokens and other secrets you paste into a server's `env` block are encrypted on the backend and injected at spawn time. They don't sit in a committed `.env` file or a client config JSON, and they are never logged. Revoke the yaw.sh/mcp token (Settings -> Tokens) and every install loses access on the next poll.
498
- - **Response pruning** -- `YAW_MCP_PRUNE_RESPONSES` (on by default) redacts large file-blob-shaped content before it reaches your LLM. This cuts the easiest form of cross-server prompt injection (stuffing a giant payload into a tool reply to swamp the model's context) and reduces accidental token burn. Set to `0` to disable.
499
- - **Namespace isolation** -- tools are namespace-prefixed (`gh_create_issue`, never bare `create_issue`), so a server can't impersonate tools from another server it has no business touching. `mcp_connect_read_tool` lets you inspect a tool's schema without loading its server, so you can decide before any code runs.
211
+ - **Compliance grades (A-F)** -- the `@yawlabs/mcp-compliance` suite (88 tests) grades a server; `servers` and `discover` show it inline (`github [ready] [A]`). `YAW_MCP_MIN_COMPLIANCE=B` makes `activate` refuse anything below the floor. Ungraded servers pass (don't punish unknown); audit them yourself with `yaw-mcp compliance <target>`.
212
+ - **Source transparency** -- `servers` and the dashboard show the exact `command`, `args`, and `url` each server launches with. Nothing is wrapped.
213
+ - **Encrypted credentials** -- dashboard `env` values are encrypted at rest and injected at spawn; never logged. Revoke the token and every install loses access on the next poll.
214
+ - **Response pruning** (`YAW_MCP_PRUNE_RESPONSES`, on by default) -- redacts large file-blob content before it reaches the model, cutting the easiest cross-server prompt-injection vector.
215
+ - **Namespace isolation** -- tools are namespace-prefixed (`gh_create_issue`, never bare `create_issue`), so a server can't impersonate another's tools. `mcp_connect_read_tool` inspects a schema before any code runs.
500
216
 
501
- **What yaw-mcp does not try to solve.** yaw-mcp does not prevent a server you deliberately installed from doing harmful things inside its own process. It doesn't block outbound network traffic, firewall DNS, analyze source, or pin package hashes. A malicious server you chose to run can call any URL your machine can reach; cross-server prompt injection through tool output is a fundamentally model-layer problem that no orchestrator fully fixes. The defenses that matter for those threats live at the layer below yaw-mcp:
217
+ yaw-mcp does **not** block outbound traffic, firewall DNS, analyze source, or pin hashes -- a malicious server you chose to run can reach any URL your machine can. Review the command before adding a server, run untrusted ones under a restricted user or container, and prefer graded servers when alternatives are equivalent. Report a security issue in yaw-mcp itself via [GitHub private advisories](https://github.com/YawLabs/mcp/security/advisories/new) (see [`SECURITY.md`](./SECURITY.md)).
218
+
219
+ ## Config sync
502
220
 
503
- - Review the command (`npx -y @scope/pkg`, a remote URL, ...) before adding a server. If you don't recognize it, run `yaw-mcp compliance <target>` against it first.
504
- - Run yaw-mcp and its spawned servers under a restricted OS user or inside a container if you're handling sensitive data. yaw-mcp stays out of your sandbox's way -- a restricted user will block egress just like it would for anything else.
505
- - Keep the yaw.sh/mcp token scoped to the devices that need it. Rotate with `yaw-mcp install <client> --token ...`; every client picks up the new value.
506
- - Prefer graded servers when the alternatives are otherwise equivalent. A server that can't pass the compliance suite on basic spec conformance is a worse choice than one that does.
221
+ yaw-mcp polls the dashboard every 60s (configurable), so adding, removing, or editing a server there takes effect with no restart. Because every install with the same token reads the same account, all your machines see the same servers, env vars, and credentials -- rotate in one place, every device picks it up on the next poll; revoke the token and every install stops immediately. That's why `~/.yaw-mcp/config.json` holds a token, not a server list.
222
+
223
+ Missing credentials are handled inline where supported: if a server exits with something like `GITHUB_TOKEN is required` and your client advertises MCP [elicitation](https://modelcontextprotocol.io/specification/server/elicitation), yaw-mcp prompts for the value and retries. Load failures end with a `-> Edit at https://yaw.sh/mcp/...#server-<id>` deep link that most clients render as a click-through to the right dashboard card.
224
+
225
+ ## Environment variables
507
226
 
508
- If you find a security issue in yaw-mcp itself, report it via [GitHub's private vulnerability reporting](https://github.com/YawLabs/mcp/security/advisories/new) -- details in [`SECURITY.md`](./SECURITY.md).
227
+ Common ones (run `yaw-mcp --help` for the full list):
228
+
229
+ | Variable | Description |
230
+ |----------|-------------|
231
+ | `YAW_MCP_TOKEN` | API token (overrides every config file). |
232
+ | `YAW_MCP_URL` | API base URL (default `https://yaw.sh/mcp`). |
233
+ | `YAW_MCP_POLL_INTERVAL` | Dashboard poll interval, seconds. `0` fetches once at startup. Default `60`. |
234
+ | `YAW_MCP_SERVER_CAP` | Max concurrently active servers. Default `6`; `0` disables the cap. |
235
+ | `YAW_MCP_MIN_COMPLIANCE` | Minimum grade (`A`-`F`) an installed server must report before `activate` loads it. |
236
+ | `YAW_MCP_VAULT_PASSPHRASE` | Passphrase for the local secret vault. Required for spawn-time `${secret:NAME}` substitution. |
237
+ | `YAW_MCP_AUTO_ACTIVATE` | `0` disables discover auto-loading a clearly-winning server. Default on. |
238
+ | `YAW_MCP_AUTO_UPGRADE` | `0` disables the background self-upgrade check at startup. Default on. |
239
+ | `YAW_MCP_AUTO_LOAD` | `1` pre-activates the top recurring pack at startup (needs persistence). Default off. |
240
+ | `YAW_MCP_PRUNE_RESPONSES` | `0` disables response pruning. Default on. |
241
+ | `YAW_MCP_DISABLE_PERSISTENCE` | `1` keeps learning + pack history process-scoped (CI, containers). Default off. |
242
+ | `LOG_LEVEL` | `debug` \| `info` \| `warn` \| `error`. Default `info`. |
509
243
 
510
244
  ## Requirements
511
245
 
512
- - Node.js 18+
513
- - No account required for core features. A Yaw Team license key is needed only for sync and shared bundles (yaw.sh/mcp).
246
+ - Node.js 18.17+.
247
+ - No account required for core features. A token from [yaw.sh/mcp](https://yaw.sh/mcp) unlocks dashboard-managed servers and cross-machine sync.
514
248
 
515
249
  ## Links
516
250
 
517
- - [yaw.sh/mcp](https://yaw.sh/mcp) -- Dashboard and server management
518
- - [@yawlabs/mcp-compliance](https://www.npmjs.com/package/@yawlabs/mcp-compliance) -- Test your MCP servers for spec compliance
519
- - [CHANGELOG](./CHANGELOG.md) -- Release notes
520
- - [GitHub](https://github.com/YawLabs/mcp) -- Source code and issues
251
+ - [yaw.sh/mcp](https://yaw.sh/mcp) -- dashboard and server management
252
+ - [@yawlabs/mcp-compliance](https://www.npmjs.com/package/@yawlabs/mcp-compliance) -- test your MCP servers for spec compliance
253
+ - [CHANGELOG](./CHANGELOG.md) -- release notes
254
+ - [GitHub](https://github.com/YawLabs/mcp) -- source and issues