mcp-better 0.6.0 → 0.8.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/README.md +26 -16
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
# mcp-better — built for 7/28
|
|
2
2
|
|
|
3
|
-
[](https://wolfe-jam.github.io/agent-business-card/?repo=Wolfe-Jam/mcp-better)
|
|
4
|
-
|
|
5
3
|
**NONE | GOOD | [BETTER] | BEST**
|
|
6
4
|
|
|
7
5
|
Textbook for **AGENTS.md** on that scale — honest modern MCP at the **BETTER** step.
|
|
@@ -11,7 +9,7 @@ Textbook for **AGENTS.md** on that scale — honest modern MCP at the **BETTER**
|
|
|
11
9
|
the book is the app is the book
|
|
12
10
|
```
|
|
13
11
|
|
|
14
|
-
Modern MCP textbook **that runs**, reviewed and approved as an AAIF Ambassador contribution. Rust · `rmcp` **3.10** · Discover · stamped cache hints · the official MCP conformance suite in CI: [100% for the conformance build](#conformance), every scored check that
|
|
12
|
+
Modern MCP textbook **that runs**, reviewed and approved as an AAIF Ambassador contribution. Rust · `rmcp` **3.10** · Discover · stamped cache hints · the official MCP conformance suite in CI: [100% for the conformance build](#conformance), and for the textbook binary every scored check except those that need a suite fixture or an undeclared method.
|
|
15
13
|
**Book:** [`textbook/`](./textbook/) — what · why · how · [doctrine](./textbook/DOCTRINE-book-is-app.md).
|
|
16
14
|
**App:** this binary + smokes. Lesson after lesson, version after version — knowledge compounds.
|
|
17
15
|
|
|
@@ -28,7 +26,7 @@ Modern MCP textbook **that runs**, reviewed and approved as an AAIF Ambassador c
|
|
|
28
26
|
|
|
29
27
|
One Agent Skill (`mcp-better-lab`) on the same process as tools:
|
|
30
28
|
|
|
31
|
-
→ [
|
|
29
|
+
→ **Tutorial: [Ship a skill with your MCP server](./docs/SKILLS-OVER-MCP.md)** — each step linked to the code, and the four checks that prove a host loads the skill (verified in Claude Code 2.1.332: `mcp-better:mcp-better-lab` listed and loaded).
|
|
32
30
|
|
|
33
31
|
## What is 7/28?
|
|
34
32
|
|
|
@@ -56,14 +54,17 @@ Humans say **7/28**. Machines negotiate **`2026-07-28`**.
|
|
|
56
54
|
| **v0.4.4** | Same era + **book matches 0.4.3 wire** — no new tool · catalogs named `health` → `echo` → `confirm_echo` |
|
|
57
55
|
| **v0.5** | Same era + **matching client completes MRTR** — `mrtr-client` finishes `confirm_echo` |
|
|
58
56
|
| **v0.6** | Same era + **the spec's own tests** — the official MCP conformance suite in CI ([Conformance](#conformance)) · cache hints on every list and read · declare what you answer · `rmcp` 3.10 |
|
|
57
|
+
| **v0.7** | Same era + **tools say what they do** — every tool carries all four annotation hints (read-only, not destructive, idempotent, closed world) · `confirm_echo` asks only clients that declare elicitation (else `-32021`) · `server/discover` stamped like the lists · a strict command line (`--version`, unknown arguments exit 2) |
|
|
58
|
+
| **v0.8** | Same era + **confirmations that hold** — `confirm_echo`'s `requestState` expires after 5 minutes · a changed `message` in round 2 is refused (`-32602`) · strict SKILL.md frontmatter (refuses what YAML reads differently) · single-file skills by design |
|
|
59
59
|
|
|
60
60
|
## What BETTER means
|
|
61
61
|
|
|
62
62
|
1. **Protocol honesty** — claim 7/28 / `2026-07-28` only for surfaces you implement and test.
|
|
63
63
|
2. **Discover-compatible** — clients should use `ClientLifecycleMode::Discover` (or Auto → 7/28), not only legacy initialize.
|
|
64
|
-
3. **Cache hints by choice** — `tools/list`, `resources/list`, `resources/templates/list`, `resources/read`, `skills/list` and `skills/get` return a positive `ttlMs` and `cacheScope` (static catalog → `public`). The SDK default is `ttlMs: 0` + `private`: valid, but it tells every client not to cache.
|
|
64
|
+
3. **Cache hints by choice** — `server/discover`, `tools/list`, `resources/list`, `resources/templates/list`, `resources/read`, `skills/list` and `skills/get` return a positive `ttlMs` and `cacheScope` (static catalog → `public`). The SDK default is `ttlMs: 0` + `private`: valid, but it tells every client not to cache.
|
|
65
65
|
4. **Stable tool order** — same process, same order across N list calls.
|
|
66
|
-
5. **
|
|
66
|
+
5. **Annotated tools** — every tool sets `readOnlyHint`, `destructiveHint`, `idempotentHint` and `openWorldHint`. A tool with no hints gets the spec's defaults: it may write, may destroy, and reaches the outside world.
|
|
67
|
+
6. **Transports** — **stdio** (default) and **Streamable HTTP** (`--http`) in the **same 7/28 era**.
|
|
67
68
|
|
|
68
69
|
## Quickstart (≤10 min)
|
|
69
70
|
|
|
@@ -106,10 +107,11 @@ MCP_BETTER_BIN="$(pwd)/target/debug/mcp-better" cargo run --example mrtr-client
|
|
|
106
107
|
```bash
|
|
107
108
|
cargo run --release
|
|
108
109
|
# install from crates.io — first hit compiles deps once (see above):
|
|
109
|
-
cargo install mcp-better --version 0.
|
|
110
|
+
cargo install mcp-better --version 0.8.0 --locked
|
|
111
|
+
mcp-better --version # mcp-better 0.8.0
|
|
110
112
|
mcp-better --help
|
|
111
113
|
# optional lying companion (teaching only — not for hosts):
|
|
112
|
-
# cargo install mcp-better --version 0.
|
|
114
|
+
# cargo install mcp-better --version 0.8.0 --locked --bin mcp-worse
|
|
113
115
|
```
|
|
114
116
|
|
|
115
117
|
**Streamable HTTP** (local demo only — see [SECURITY.md](./SECURITY.md)):
|
|
@@ -124,9 +126,10 @@ cargo run --release -- --http
|
|
|
124
126
|
|
|
125
127
|
| How | Value |
|
|
126
128
|
|-----|--------|
|
|
127
|
-
| CLI | `mcp-better` (stdio) · `mcp-better --http` · `mcp-better --stdio` |
|
|
129
|
+
| CLI | `mcp-better` (stdio) · `mcp-better --http` · `mcp-better --stdio` · `--version` / `--help` win wherever they appear |
|
|
128
130
|
| Bare args | `http` / `stdio` (same meaning as flags) |
|
|
129
131
|
| Env | `MCP_TRANSPORT` or `MCP_BETTER_TRANSPORT` → `stdio` \| `http` (**`MCP_TRANSPORT` first** if both set) |
|
|
132
|
+
| Anything else | An unknown argument or transport value prints the error and exits **2**; nothing falls back to stdio silently |
|
|
130
133
|
| HTTP bind | `MCP_BETTER_HTTP_ADDR` — default **`127.0.0.1:8787`**. Do **not** use `0.0.0.0` unless you accept an unauthenticated open endpoint. |
|
|
131
134
|
|
|
132
135
|
## Tools
|
|
@@ -137,7 +140,9 @@ cargo run --release -- --http
|
|
|
137
140
|
| `echo` | Pure demo — returns `message` unchanged. |
|
|
138
141
|
| `confirm_echo` | Textbook **MRTR** (SEP-2322) — echo after mid-call confirm · sealed `requestState`. |
|
|
139
142
|
|
|
140
|
-
|
|
143
|
+
All three are annotated `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`: they read only, change nothing and stay in the process.
|
|
144
|
+
|
|
145
|
+
## Protocol claims (v0.8.0 — same 7/28 era · the official conformance suite in CI)
|
|
141
146
|
|
|
142
147
|
| Surface | Status |
|
|
143
148
|
|---------|--------|
|
|
@@ -146,10 +151,11 @@ cargo run --release -- --http
|
|
|
146
151
|
| HTTP mode | Stateless for 7/28 · `json_response` · local **Host** guards |
|
|
147
152
|
| Routing headers | Streamable HTTP POSTs use **`Mcp-Method`** and **`Mcp-Name`** when naming a tool (SEP-2243); `http-smoke` asserts this happy path |
|
|
148
153
|
| Capabilities | **tools** · **resources** (skill docs) · **skills** extension (SEP-2640, rmcp native) · prompts and completions **not declared** (`prompts/*`, `completion/complete` → method not found) |
|
|
149
|
-
| Cache hints | tools, resources and skills: **`ttlMs=60000`**, **`cacheScope=public`** · tool order **`health`→`echo`→`confirm_echo`** (restart-stable) |
|
|
150
|
-
|
|
|
151
|
-
|
|
|
152
|
-
|
|
|
154
|
+
| Cache hints | discover, tools, resources and skills: **`ttlMs=60000`**, **`cacheScope=public`** · tool order **`health`→`echo`→`confirm_echo`** (restart-stable) |
|
|
155
|
+
| Tool annotations | all four hints on every tool: read-only · not destructive · idempotent · closed world (`tests/handlers.rs`) |
|
|
156
|
+
| MRTR (optional) | **`confirm_echo`** — mid-call confirm · sealed `requestState` (expires after 5 min; round 2 must resend the same `message`) · asked only of clients that declare elicitation (else `-32021`) · matching client **`mrtr-client`** · [`docs/MRTR-CONFIRM-ECHO.md`](./docs/MRTR-CONFIRM-ECHO.md)
|
|
157
|
+
| Skills (optional) | **`mcp-better-lab`** · `skills/list` · digests · strict frontmatter · one file per skill by design · [`docs/SKILLS-OVER-MCP.md`](./docs/SKILLS-OVER-MCP.md) |
|
|
158
|
+
| Lying companion | **`mcp-worse`** — reversed tool order (the lie) + the SDK defaults left in place: no cache hints of its own (the wire shows `ttlMs: 0` + `private`, valid but uninformative), no tool annotations, and `prompts/list` / `completion/complete` answered without being declared · stdio only · same `--version` · contrast-smoke only |
|
|
153
159
|
| OAuth / tasks | out of hero |
|
|
154
160
|
|
|
155
161
|
## Conformance
|
|
@@ -158,12 +164,12 @@ CI runs the official MCP conformance suite ([`@modelcontextprotocol/conformance`
|
|
|
158
164
|
|
|
159
165
|
| Run | Binary | 2026-07-28 requirements | Skills |
|
|
160
166
|
|-----|--------|-------------------------|--------|
|
|
161
|
-
| Conformance build | [`conformance/`](./conformance/): `mcp-better-conformance` | **100%, no baseline:**
|
|
167
|
+
| Conformance build | [`conformance/`](./conformance/): `mcp-better-conformance` | **100%, no baseline:** 196 checks pass across the 50 scenarios, none fail or warn; the suite itself skips one scenario (`tasks-status-notifications`, 0 checks) | 38 of 38 |
|
|
162
168
|
| Textbook | `mcp-better`, what you install | the 37 scored scenarios: 74 checks pass; 33 fail or warn, each listed in [`conformance-baseline.yml`](./conformance-baseline.yml) as `fixture` or `not declared` | 38 of 38 |
|
|
163
169
|
|
|
164
170
|
**What each run measures.** Most scenarios call tools, prompts and resources that exist only in the suite's reference server (`test_*`, `test://…`), and the 13 unscored ones are the Tasks extension and three pending scenarios. The official SDKs pass those with a separate server that carries the fixtures; `mcp-better-conformance` is that server for mcp-better. Its fixtures, capabilities and Tasks are adapted from the Rust MCP SDK's conformance server (Apache-2.0, [`conformance/NOTICE`](./conformance/NOTICE)); `BetterServer` serves mcp-better's three tools, the skill resource and Skills. So the 100% mostly measures the fixtures and the shared transport (`mcp_better::http_config`). The textbook run and the Skills scenarios measure mcp-better's own code.
|
|
165
171
|
|
|
166
|
-
**Reading the textbook run.** `caching` is 7 of 8: the eighth check calls `prompts/list`, and mcp-better doesn't declare prompts, so it answers method-not-found (`not declared` in the baseline). `prompts-list` and `completion-complete` fail for the same reason. Every other failure is a missing suite fixture. The suite's MRTR scenarios use its own fixture tools, so `confirm_echo` is checked by the matching client (`examples/mrtr-client`)
|
|
172
|
+
**Reading the textbook run.** `caching` is 7 of 8: the eighth check calls `prompts/list`, and mcp-better doesn't declare prompts, so it answers method-not-found (`not declared` in the baseline). `prompts-list` and `completion-complete` fail for the same reason. Every other failure is a missing suite fixture. The suite's MRTR scenarios use its own fixture tools, so `confirm_echo` is checked by the matching client (`examples/mrtr-client`), which declares elicitation, and by a handler test that a client without it gets `-32021` (missing required client capability).
|
|
167
173
|
|
|
168
174
|
```bash
|
|
169
175
|
bash scripts/conformance.sh # textbook + baseline
|
|
@@ -229,3 +235,7 @@ For persistent, versionable AI project context beyond a protocol textbook:
|
|
|
229
235
|
## License
|
|
230
236
|
|
|
231
237
|
MIT — see [LICENSE](./LICENSE). Except [`conformance/`](./conformance/) (the unpublished conformance build), which is Apache-2.0: see [`conformance/NOTICE`](./conformance/NOTICE).
|
|
238
|
+
|
|
239
|
+
---
|
|
240
|
+
|
|
241
|
+
[](https://wolfe-jam.github.io/agent-business-card/?repo=Wolfe-Jam/mcp-better)
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mcp-better",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0",
|
|
4
4
|
"mcpName": "io.github.Wolfe-Jam/mcp-better",
|
|
5
|
-
"description": "
|
|
5
|
+
"description": "Rust MCP textbook for 2026-07-28: annotated tools, MCP conformance suite in CI. AAIF contribution. npm shim downloads the native binary from GitHub Releases.",
|
|
6
6
|
"license": "MIT",
|
|
7
|
-
"author": "Wolfe-Jam <
|
|
7
|
+
"author": "Wolfe-Jam <team@faf.one>",
|
|
8
8
|
"homepage": "https://github.com/Wolfe-Jam/mcp-better",
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|