@expressivecss/mcp-server 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.
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "expressivecss-mcp",
3
+ "displayName": "ExpressiveCSS MCP",
4
+ "version": "0.2.0",
5
+ "description": "ExpressiveCSS workflow server with Setup Expert, Rules Enforcer, Creative Director, Page Arcjitect, Component Syntax Expert, and Quality Inspector.",
6
+ "author": {
7
+ "name": "BaezFJ",
8
+ "url": "https://github.com/BaezFJ"
9
+ },
10
+ "homepage": "https://www.expressivecss.com",
11
+ "repository": "https://github.com/BaezFJ/ExpressiveCSS",
12
+ "license": "MIT",
13
+ "mcpServers": "./mcp.json"
14
+ }
@@ -0,0 +1,25 @@
1
+ {
2
+ "name": "expressivecss-mcp",
3
+ "displayName": "ExpressiveCSS MCP",
4
+ "version": "0.2.0",
5
+ "description": "ExpressiveCSS workflow server with Setup Expert, Rules Enforcer, Creative Director, Page Arcjitect, Component Syntax Expert, and Quality Inspector.",
6
+ "author": {
7
+ "name": "BaezFJ",
8
+ "url": "https://github.com/BaezFJ"
9
+ },
10
+ "homepage": "https://www.expressivecss.com",
11
+ "repository": "https://github.com/BaezFJ/ExpressiveCSS",
12
+ "license": "MIT",
13
+ "keywords": [
14
+ "expressivecss",
15
+ "ui",
16
+ "design",
17
+ "material-design",
18
+ "mcp",
19
+ "workflow"
20
+ ],
21
+ "categories": [
22
+ "dev",
23
+ "productivity"
24
+ ]
25
+ }
package/CHANGELOG.md ADDED
@@ -0,0 +1,19 @@
1
+ # Changelog
2
+
3
+ ## 0.2.0 - 2026-09-29
4
+
5
+ - Add the `expressivecss-lint` bin: the `rules_enforcer` static checks as a command with a `--hook` mode for Claude Code `PostToolUse`, so agent edits are checked without a tool call. `server.js` now starts the server only when run as the entry point.
6
+ - Add opt-in consumer scenario command execution through the existing quality inspector and operator allowlist. Browser reports remain separately inspected evidence.
7
+
8
+ - Breaking: update jsdom to 30.0.1 and require Node `^22.22.2 || ^24.15.0 || >=26.0.0`.
9
+ Upgrade the Node executable used by your MCP client before reinstalling the
10
+ server. Node 20 is no longer supported. Ship this change in the next MCP minor
11
+ release, not a patch release. Framework runtime requirements are unchanged.
12
+ - Coordinate independently versioned MCP releases through protected `mcp-v*` tags.
13
+ - Include this changelog in the published package.
14
+ - Bundled framework guidance: ExpressiveCSS 0.10.1.
15
+
16
+ ## 0.1.0
17
+
18
+ Initial MCP package. Exposes the design-to-QA tools with bundled component guides,
19
+ semantics, component decisions, contract metadata, and a standalone smoke check.
package/LICENSE ADDED
@@ -0,0 +1,101 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2026 BaezFJ
4
+ Copyright (c) 2014-2026 Materialize
5
+
6
+ Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ of this software and associated documentation files (the "Software"), to deal
8
+ in the Software without restriction, including without limitation the rights
9
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ copies of the Software, and to permit persons to whom the Software is
11
+ furnished to do so, subject to the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be included in all
14
+ copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ SOFTWARE.
23
+
24
+
25
+ ================================================================================
26
+ THIRD-PARTY NOTICES
27
+ ================================================================================
28
+
29
+ ExpressiveCSS is derived from MaterializeCSS v2.2.2
30
+ (https://github.com/materializecss/materialize), which is distributed under the
31
+ MIT license reproduced above. Portions of `src/ts` and `src/sass` remain
32
+ substantially that work.
33
+
34
+ The following components carry their own licenses, reproduced in full below.
35
+
36
+ --------------------------------------------------------------------------------
37
+ normalize.css v8.0.1 - MIT License
38
+ https://github.com/necolas/normalize.css
39
+
40
+ Used in: src/sass/base/_normalize.scss (trimmed to this project's browser
41
+ support baseline; see that file's header for the list of removed rules).
42
+
43
+ Copyright © Nicolas Gallagher and Jonathan Neal
44
+
45
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
46
+ this software and associated documentation files (the "Software"), to deal in
47
+ the Software without restriction, including without limitation the rights to
48
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
49
+ of the Software, and to permit persons to whom the Software is furnished to do
50
+ so, subject to the following conditions:
51
+
52
+ The above copyright notice and this permission notice shall be included in all
53
+ copies or substantial portions of the Software.
54
+
55
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
56
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
57
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
58
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
59
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
60
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
61
+ SOFTWARE.
62
+
63
+ --------------------------------------------------------------------------------
64
+ The Polymer Project - BSD 3-Clause License
65
+ https://polymer.github.io/LICENSE.txt
66
+
67
+ Used in: src/sass/components/_preloader.scss (spinner animation).
68
+
69
+ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
70
+ The complete set of contributors may be found at
71
+ http://polymer.github.io/CONTRIBUTORS.txt
72
+ Code distributed by Google as part of the polymer project is also subject to an
73
+ additional IP rights grant found at http://polymer.github.io/PATENTS.txt
74
+
75
+ Copyright (c) 2014 The Polymer Authors. All rights reserved.
76
+
77
+ Redistribution and use in source and binary forms, with or without
78
+ modification, are permitted provided that the following conditions are
79
+ met:
80
+
81
+ * Redistributions of source code must retain the above copyright
82
+ notice, this list of conditions and the following disclaimer.
83
+ * Redistributions in binary form must reproduce the above
84
+ copyright notice, this list of conditions and the following disclaimer
85
+ in the documentation and/or other materials provided with the
86
+ distribution.
87
+ * Neither the name of Google Inc. nor the names of its
88
+ contributors may be used to endorse or promote products derived from
89
+ this software without specific prior written permission.
90
+
91
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
92
+ "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
93
+ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
94
+ A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
95
+ OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
96
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
97
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
98
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
99
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
100
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
101
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
package/README.md ADDED
@@ -0,0 +1,240 @@
1
+ # ExpressiveCSS MCP Server
2
+
3
+ This folder contains a self-hosted MCP server for the ExpressiveCSS design-to-QA workflow:
4
+
5
+ - **Setup Expert**
6
+ - **Rules Enforcer**
7
+ - **Creative Director**
8
+ - **Page Arcjitect** (`page_arcjitect`, with conventional `page_architect` compatibility)
9
+ - **Component Syntax Expert**
10
+ - **Quality Inspector**
11
+
12
+ The server bundles generated component guides, selection data, contract metadata, and the normative semantics data. All component guidance comes from this synchronized package data. A framework source checkout contributes only target-version and contract-provenance evidence, so local prose cannot replace the packaged guidance.
13
+
14
+ A resolved version matching the bundled contract reports `documentationMode: "bundled"` and `bundledContractSafe: true`. `documentationSources.bundled` identifies the contract version and source hash. This resolver does not verify the public website, so `currentDocsSafe` and `documentationSources.current.available` remain false even on a match. Use matching bundled guidance, installed sources, or a proven release tag for version-specific claims.
15
+
16
+ ## Material capability evidence
17
+
18
+ `component_syntax_expert` adds a scoped `capability` record to each found component.
19
+ For foundations, pass `foundations: ["typography", "shape", "motion"]`; component
20
+ names are optional for this request. Results distinguish documented scope,
21
+ pinned source review, feature/integration gaps, mapped checks and recorded results.
22
+ Version or contract-provenance failures block capability results.
23
+
24
+ `capabilityEvidence` identifies the bundled review snapshot and browser run.
25
+ This evidence concerns the reviewed checkout. It does not verify the installed
26
+ package's implementation, the consumer's browser, or full Google specification
27
+ parity. Changed inputs invalidate evidence during generation; serving the package
28
+ does not rerun tests or re-review sources. The optional Markdown
29
+ [roadmap](https://github.com/BaezFJ/ExpressiveCSS/blob/master/skills/expressivecss/references/capability-roadmap.md) and packaged
30
+ `capability-roadmap.json` come from the same catalogue.
31
+
32
+ ## Run it locally
33
+
34
+ The server supports Node `^22.22.2 || ^24.15.0 || >=26.0.0`, matching its `jsdom` runtime dependency.
35
+ When upgrading, update the Node executable used by your MCP client before
36
+ reinstalling the server. Node 20 and earlier Node 22/24 patch releases are no
37
+ longer supported. For a contributor checkout, use the latest Node 24 release.
38
+
39
+ ```bash
40
+ cd mcp/expressivecss
41
+ npm ci
42
+ node server.js
43
+ ```
44
+
45
+ The MCP server uses stdio. Normally the MCP client launches it; running the command directly is useful only as a startup check.
46
+
47
+ Run the complete live protocol smoke test with:
48
+
49
+ ```bash
50
+ npm test
51
+ ```
52
+
53
+ ## Tools
54
+
55
+ | Tool | Purpose |
56
+ | --- | --- |
57
+ | `setup_expert` | Resolves the installed ExpressiveCSS version, contract compatibility, setup, and repository artifacts |
58
+ | `rules_enforcer` | Checks authored semantics and legacy/forbidden patterns, and looks up component guidance without claiming component-rule validation |
59
+ | `creative_director` | Suggests components from the generated decision catalogue, with uncertain fuzzy matches labelled as fallback |
60
+ | `page_arcjitect` | Workflow stage returning page sections, landmarks, and a semantic skeleton |
61
+ | `page_architect` | Conventional spelling for the same page architecture tool; component names must resolve exactly |
62
+ | `component_syntax_expert` | Returns authoritative syntax/contract/rules for components |
63
+ | `quality_inspector` | Runs scoped static checks and optional commands (`npm run typecheck`, `npm run test`), then names every uninspected review area |
64
+
65
+ Static findings are heuristic and require source or runtime confirmation before remediation. A clean static check is reported as `staticStatus: "heuristic_pass"`; any overall MCP `pass` applies only to `checksPerformed`. Neither proves visual hierarchy, responsive rendering, focus behavior, motion, contrast, screen-reader announcements, or component-rule conformance unless separate evidence covers those areas. Read `uncheckedAreas`, `blockedChecks`, `coverageStatus`, `contractCompatibility`, and `contractProvenance` before using a result in a finish review.
66
+
67
+ `creative_director` and both page architect spellings resolve the target ExpressiveCSS version before reading current contract guidance. They return no recommendations or architecture when the version is mismatched or unresolved, when local contract provenance is missing, stale, invalid, or divergent from the bundled package contract, or when an architecture request contains an inexact component name. Fuzzy creative matches remain labelled `confidence: "fallback"`; page architecture never accepts them silently.
68
+
69
+ For a framework source checkout, the server accepts only the generated contract's canonical source list. It resolves the real project and source paths, rejects symbolic links and non-regular files, and caps each source at 2 MiB and the set at 8 MiB. It recomputes provenance for every tool call in manifest order with the generator's SHA-256 input format, `source path + NUL + file content + NUL`. The verified local manifest must also match the bundled package's framework version and source hash because the MCP serves bundled guidance. Contract-dependent output is blocked when the source set is invalid, missing, oversized, stale, or divergent. Invalid source paths never produce a computed hash. Generated data shipped in this package reports `contractProvenance: "bundled-verified"` because package consumers do not receive the framework source files.
70
+
71
+ Static inspection uses descriptor-level, no-follow bounded reads and rechecks file identity after each read. It caps files at 2 MiB each and 16 MiB per request by default, stops after 200 issues per file or 1,000 per request, and applies a five-second scan budget. Any unread, changed, over-budget, or partially scanned file appears under `filesUninspected`, which prevents a pass.
72
+
73
+ ## Command-line lint and agent hook
74
+
75
+ `expressivecss-lint` runs the same static checks as `rules_enforcer` (bundled
76
+ semantics rules, retired Materialize patterns, initialization checks) without
77
+ an MCP client. It exits 1 when it finds anything, so it fits `pre-commit` and CI:
78
+
79
+ ```bash
80
+ npx --package @expressivecss/mcp-server expressivecss-lint src/pages/*.astro src/components/*.jsx
81
+ ```
82
+
83
+ `--hook` reads a Claude Code `PostToolUse` payload on stdin, lints
84
+ `tool_input.file_path` when it is a markup file (`.html`, `.astro`, `.jsx`,
85
+ `.tsx`, `.vue`, `.svelte`), and exits 2 with the findings on
86
+ stderr. Claude Code feeds that output back to the agent, so every edit is
87
+ checked without the agent choosing to call a tool. Add to the consuming
88
+ project's `.claude/settings.json`:
89
+
90
+ ```json
91
+ {
92
+ "hooks": {
93
+ "PostToolUse": [
94
+ {
95
+ "matcher": "Edit|Write",
96
+ "hooks": [
97
+ { "type": "command", "command": "npx --package @expressivecss/mcp-server expressivecss-lint --hook" }
98
+ ]
99
+ }
100
+ ]
101
+ }
102
+ }
103
+ ```
104
+
105
+ Files must be regular files inside the working directory and at most 2 MiB;
106
+ symbolic links, anything else, and an inspection that stops early (over
107
+ 4,000 tags, or the five-second budget) are reported as findings rather than
108
+ passed. Agents without hook support get the same enforcement from the
109
+ `pre-commit` or CI invocation above. The checks are heuristic: JSX, Astro, Vue, and Svelte
110
+ files are parsed as HTML after `className` is rewritten to `class`, so
111
+ markup built from expressions can escape a selector rule, and markup kept in
112
+ a string prop (this repository's docs pages pass examples through
113
+ `<Code code={...}>`) is parsed as if it were inline, which produces false
114
+ findings. Semantics findings report line 1 because the parser keeps no
115
+ source positions; the snippet identifies the element.
116
+
117
+ ## Consumer browser scenarios
118
+
119
+ `quality_inspector` accepts `runType: "consumer"` with `runCommands: true` to run
120
+ only the consuming project's `verify:expressivecss` package script. Bind that
121
+ script to the skill's portable `scripts/verify-consumer.mjs`, a reviewed scenario,
122
+ and an already-running local development server. The consumer supplies its
123
+ existing `@playwright/test` and Chromium. MCP adds no browser dependency.
124
+
125
+ The existing operator root allowlist, environment filtering, output redaction,
126
+ and command timeout apply. No arbitrary command text or script name is accepted.
127
+ A disabled `runCommands` flag never launches the script. A missing or failed
128
+ script cannot pass command verification. Project scripts and their printed claims
129
+ are untrusted evidence; inspect the independently collected report and captures.
130
+ `reviewComplete` remains false, and uninspected review areas remain explicit.
131
+ See the skill's `references/consumer-verification.md` for the scenario format,
132
+ network limits, evidence handling, and bounded repair workflow.
133
+
134
+ ## Environment variables
135
+
136
+ - `EXPRESSIVECSS_MCP_MAX_COMPONENT_RESPONSE_CHARS`
137
+ - `EXPRESSIVECSS_MCP_MAX_COMPONENT_SKIPS`
138
+ - `EXPRESSIVECSS_MCP_QA_MAX_FILES`
139
+ - `EXPRESSIVECSS_MCP_QA_MAX_MB`
140
+ - `EXPRESSIVECSS_MCP_QA_MAX_TOTAL_MB`
141
+ - `EXPRESSIVECSS_MCP_COMMAND_TIMEOUT_MS`
142
+ - `EXPRESSIVECSS_MCP_ALLOWED_COMMAND_ROOTS`
143
+ - `SKIP_SETUP_EXPERT`
144
+ - `SKIP_RULES_ENFORCER`
145
+ - `SKIP_CREATIVE_DIRECTOR`
146
+ - `SKIP_PAGE_ARCHITECT`
147
+ - `SKIP_COMPONENT_SYNTAX_EXPERT`
148
+ - `SKIP_QUALITY_INSPECTOR`
149
+
150
+ Set any skip flag to `true` to disable that stage from doing work.
151
+
152
+ Command execution is denied by default. To let `quality_inspector` honor `runCommands: true`, the MCP operator must set `EXPRESSIVECSS_MCP_ALLOWED_COMMAND_ROOTS` when launching the server. Use platform path separators for multiple roots, or a JSON array of absolute roots:
153
+
154
+ ```text
155
+ EXPRESSIVECSS_MCP_ALLOWED_COMMAND_ROOTS=/srv/projects/site-a:/srv/projects/site-b
156
+ EXPRESSIVECSS_MCP_ALLOWED_COMMAND_ROOTS=["/srv/projects/site-a","/srv/projects/site-b"]
157
+ ```
158
+
159
+ The real `projectRoot` must equal or be contained by one of those roots. A tool caller cannot expand this policy. Allowed commands receive only the executable path, system/temp/locale variables, `CI=1`, `NO_COLOR=1`, and `HOME`/`USERPROFILE` reset to the project root. API keys, tokens, passwords, cloud credentials, SSH agent variables, and other MCP-process environment values are not forwarded.
160
+
161
+ ## Sample client configuration
162
+
163
+ ### `mcp/expressivecss/mcp.json`
164
+
165
+ ```json
166
+ {
167
+ "mcpServers": {
168
+ "expressivecss-mcp": {
169
+ "command": "npx",
170
+ "args": ["-y", "@expressivecss/mcp-server@latest"],
171
+ "env": {
172
+ "EXPRESSIVECSS_MCP_MAX_COMPONENT_RESPONSE_CHARS": "24000",
173
+ "EXPRESSIVECSS_MCP_MAX_COMPONENT_SKIPS": "7",
174
+ "EXPRESSIVECSS_MCP_QA_MAX_FILES": "300",
175
+ "EXPRESSIVECSS_MCP_QA_MAX_MB": "2",
176
+ "EXPRESSIVECSS_MCP_ALLOWED_COMMAND_ROOTS": "/absolute/path/to/allowed/project"
177
+ }
178
+ }
179
+ }
180
+ }
181
+ ```
182
+
183
+ The packaged config targets the npm release, following the same `npx ...@latest` shape as daisyUI Blueprint. Before the first publish, configure local development with `node` and an absolute path to this folder's `server.js` instead.
184
+
185
+ ### Hermes
186
+
187
+ Hermes uses the top-level `mcp_servers` setting shown in `sample-hermes-config.yaml`. Apply it with `hermes config set` rather than editing `~/.hermes/config.yaml` by hand, then restart Hermes so it discovers the seven tools. A local-path setup should point `args` at the absolute path to `server.js`.
188
+
189
+ ## Notes
190
+
191
+ - Published package scripts are self-contained: `npm test` runs the live MCP protocol smoke test, and `npm pack --dry-run` runs that test through `prepack`.
192
+ - Repository maintainers can verify generated sources with `node ../../scripts/gen-expressivecss-skill.mjs --check` and `node scripts/sync-guides.mjs --check`, then run `npm test`. To refresh them, run those two generator commands without `--check` before packing.
193
+ - `setup_expert` resolves framework source, an installed package, or supported lockfiles in that order. A manifest range alone is reported as unresolved rather than treated as the installed version. An installed version outside the direct manifest range also blocks contract-dependent guidance.
194
+ - Pass `projectRoot` in tool calls when the target project differs from the MCP process working directory.
195
+
196
+
197
+ ### Task scope and recovery
198
+
199
+ All seven tools publish an output schema for their shared evidence fields. The
200
+ six lookup/review tools declare local read-only behavior. `quality_inspector`
201
+ declares possible destructive, non-idempotent, open-world behavior because
202
+ project-authored scripts can write files and contact services. These
203
+ [MCP annotations](https://modelcontextprotocol.io/specification/2025-11-25/server/tools)
204
+ describe behavior; they do not grant permissions or sandbox a command.
205
+
206
+ The server operator can narrow the existing script list at launch:
207
+
208
+ ```sh
209
+ EXPRESSIVECSS_MCP_ALLOWED_SCRIPTS='["typecheck","verify:expressivecss"]'
210
+ ```
211
+
212
+ Omitting this setting preserves the built-in `typecheck`, `test`, and
213
+ `verify:expressivecss` list. An empty array, malformed JSON, or an unknown entry
214
+ denies all scripts. Call arguments cannot widen it. The project root must still
215
+ be allowlisted and the call must request `runCommands: true`. A request needing
216
+ a disallowed script runs none of its commands. A sequence stops after the first
217
+ failure, timeout, unavailable command, or changed inspected input, and lists
218
+ remaining scripts in `commandExecutionPolicy.commandsNotRun`. There are no
219
+ implicit retries. Existing process-group cleanup also applies on normal exit.
220
+
221
+ `quality_inspector.inspectionEvidence` records SHA-256 hashes and byte counts
222
+ from the exact files read. `inputsUnchanged` compares these inputs after
223
+ verification; command runs also pin `package.json`. A changed or unreadable
224
+ input prevents a pass and stops subsequent commands. For a later check of the
225
+ same candidate, optionally supply `expectedSourceHashes`, mapping the exact
226
+ requested file names to hashes from an operator-owned previous result. Missing
227
+ or mismatched pins block command execution. Only requested files are read for
228
+ this comparison; the map grants no extra filesystem access.
229
+
230
+ Hashes describe observed endpoints, not an atomic snapshot of the application.
231
+ Undeclared files, script dependencies and transient changes are not covered.
232
+ The root allowlist controls the command's working directory; scripts and npm
233
+ hooks still execute project code. Use host filesystem/network isolation and
234
+ inspect scripts before authorizing them. For browser requests use the consumer
235
+ runner's explicit loopback origin and mutation policy.
236
+
237
+ Keep failed evidence and the candidate diff before cleanup. Repair in a disposable
238
+ checkout when practical. Never reset a shared tree to clear a failed check. The
239
+ MCP does not restore files or discard user edits; recovery belongs to the task's
240
+ owner and must preserve concurrent work.