@ggui-ai/protocol-conformance 0.7.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.
Files changed (44) hide show
  1. package/README.md +15 -12
  2. package/dist/binding-conformance/cases/bind-blueprint-no-contract-none.json +6 -0
  3. package/dist/binding-conformance/cases/bind-contract-without-tool-names-none.json +18 -0
  4. package/dist/binding-conformance/cases/bind-declared-gadget.json +13 -0
  5. package/dist/binding-conformance/cases/bind-declared-wins-over-contract.json +23 -0
  6. package/dist/binding-conformance/cases/bind-derived-caps-at-sixteen.json +54 -0
  7. package/dist/binding-conformance/cases/bind-derived-props-and-stream.json +36 -0
  8. package/dist/binding-conformance/cases/bind-derived-skips-invalid-names.json +40 -0
  9. package/dist/binding-conformance/cases/bind-derived-union-dedupes.json +38 -0
  10. package/dist/binding-conformance/cases/bind-gadget-undeclared-none.json +6 -0
  11. package/dist/binding-conformance/cases/bind-reject-charset.json +9 -0
  12. package/dist/binding-conformance/cases/bind-reject-duplicate-pair.json +12 -0
  13. package/dist/binding-conformance/cases/bind-reject-empty-list.json +9 -0
  14. package/dist/binding-conformance/cases/bind-reject-overlong-name.json +13 -0
  15. package/dist/binding-conformance/cases/bind-reject-server-charset.json +9 -0
  16. package/dist/binding-conformance/cases/bind-reject-too-many-entries.json +27 -0
  17. package/dist/binding-conformance/cases/filter-case-sensitive-server.json +7 -0
  18. package/dist/binding-conformance/cases/filter-case-sensitive-tool.json +7 -0
  19. package/dist/binding-conformance/cases/filter-none-passes-bound.json +7 -0
  20. package/dist/binding-conformance/cases/filter-none-passes-unbound.json +6 -0
  21. package/dist/binding-conformance/cases/filter-pair-bare-never-matches.json +7 -0
  22. package/dist/binding-conformance/cases/filter-pair-exact.json +10 -0
  23. package/dist/binding-conformance/cases/filter-pair-not-cross-entry.json +10 -0
  24. package/dist/binding-conformance/cases/filter-server-excludes-bare.json +7 -0
  25. package/dist/binding-conformance/cases/filter-server-match.json +7 -0
  26. package/dist/binding-conformance/cases/filter-tool-cross-server.json +7 -0
  27. package/dist/binding-conformance/cases/filter-tool-excludes-unbound.json +6 -0
  28. package/dist/binding-conformance/cases/filter-tool-matches-bare-entry.json +7 -0
  29. package/dist/binding-conformance/cases/filter-tool-no-match.json +7 -0
  30. package/dist/binding-conformance/index.d.ts +214 -0
  31. package/dist/binding-conformance/index.d.ts.map +1 -0
  32. package/dist/binding-conformance/index.js +153 -0
  33. package/dist/index.d.ts +2 -0
  34. package/dist/index.d.ts.map +1 -1
  35. package/dist/index.js +5 -0
  36. package/dist/resolution-conformance/cases/resolve-bundle-host-computed.json +3 -3
  37. package/dist/resolution-conformance/cases/resolve-default-host.json +2 -2
  38. package/dist/resolution-conformance/cases/resolve-loopback-host-http-scheme.json +2 -2
  39. package/dist/resource-read-conformance/cases/channel-less-read-mounts-inline.json +24 -0
  40. package/dist/resource-read-conformance/cases/read-without-a-delivery-channel-answers-not-mountable.json +15 -4
  41. package/dist/resource-read-conformance/index.d.ts +16 -4
  42. package/dist/resource-read-conformance/index.d.ts.map +1 -1
  43. package/dist/resource-read-conformance/index.js +16 -5
  44. package/package.json +8 -3
@@ -110,13 +110,14 @@ import registryFusion from './cases/registry-match-fuses-on-not-mountable.json'
110
110
  import malformedLocator from './cases/malformed-locator-stays-outside-the-typed-set.json' with { type: 'json' };
111
111
  import liveRowMount from './cases/live-row-read-returns-mount-material.json' with { type: 'json' };
112
112
  import remintMount from './cases/evicted-row-remints-from-the-durable-record.json' with { type: 'json' };
113
+ import inlineMount from './cases/channel-less-read-mounts-inline.json' with { type: 'json' };
113
114
  // =============================================================================
114
115
  // Catalog
115
116
  // =============================================================================
116
117
  /**
117
118
  * Every resource-read case the kit ships, in deterministic order: the
118
119
  * four typed classes, then the disclosure fusions, then the boundary of
119
- * the classification, then the two mount cases.
120
+ * the classification, then the three mount cases.
120
121
  */
121
122
  export const resourceReadCases = [
122
123
  notFoundOnAMiss,
@@ -132,6 +133,7 @@ export const resourceReadCases = [
132
133
  malformedLocator,
133
134
  liveRowMount,
134
135
  remintMount,
136
+ inlineMount,
135
137
  ];
136
138
  // =============================================================================
137
139
  // Locator grammar + the mount predicate
@@ -160,8 +162,9 @@ export function renderLocatorUri(locator, registeredKeys = {}) {
160
162
  }
161
163
  /**
162
164
  * Does this render meta carry enough to paint something? One of the
163
- * three delivery channels a runtime knows: a static component URL, a
164
- * live channel, or a server-emitted system card.
165
+ * four delivery channels a runtime knows: a fetchable static component
166
+ * URL, inline base64 component source, a live channel, or a
167
+ * server-emitted system card.
165
168
  *
166
169
  * The live channel needs BOTH halves — an endpoint with no token cannot
167
170
  * be opened, and a token with no endpoint has nowhere to go — so a
@@ -170,6 +173,8 @@ export function renderLocatorUri(locator, registeredKeys = {}) {
170
173
  export function declaresDeliveryChannel(meta) {
171
174
  if (typeof meta.codeUrl === 'string' && meta.codeUrl.length > 0)
172
175
  return true;
176
+ if (typeof meta.codeB64 === 'string' && meta.codeB64.length > 0)
177
+ return true;
173
178
  if (typeof meta.kind === 'string' && meta.kind.length > 0)
174
179
  return true;
175
180
  return (typeof meta.wsUrl === 'string' &&
@@ -600,7 +605,7 @@ const PROBE_KEYS = ['as', 'locator', 'expect'];
600
605
  const SEED_KEYS = {
601
606
  'identity-record': ['kind', 'session', 'key', 'blueprint'],
602
607
  'durable-blueprint': ['kind', 'componentRef', 'body'],
603
- 'committed-render': ['kind', 'session'],
608
+ 'committed-render': ['kind', 'session', 'size'],
604
609
  'uncommitted-render': ['kind', 'session'],
605
610
  'registered-blueprint': ['kind', 'as'],
606
611
  };
@@ -665,11 +670,17 @@ function parseSeed(bad, seed) {
665
670
  }
666
671
  return { kind: 'durable-blueprint', componentRef, body };
667
672
  }
668
- case 'committed-render':
673
+ case 'committed-render': {
674
+ const size = seed['size'] ?? 'under-inline-cap';
675
+ if (size !== 'under-inline-cap' && size !== 'over-inline-cap') {
676
+ throw bad("a committed-render seed's 'size' must be 'under-inline-cap' or 'over-inline-cap' (or omitted for the default)");
677
+ }
669
678
  return {
670
679
  kind: 'committed-render',
671
680
  session: requireText(bad, seed['session'], "a committed-render seed's 'session'"),
681
+ size,
672
682
  };
683
+ }
673
684
  case 'uncommitted-render':
674
685
  return {
675
686
  kind: 'uncommitted-render',
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@ggui-ai/protocol-conformance",
3
- "version": "0.7.0",
4
- "description": "Conformance test kit for the ggui protocol. Drives a behavioral fixture catalog against a live implementation over WebSocket, a resources/read catalog against a live MCP server, and three pure-function catalogs (schema, registration, resolution) for the gadget obligations, reporting a scorecard-style pass / fail / skip. MCP builders adopt this kit to prove their implementation is protocol-conformant.",
3
+ "version": "0.8.0",
4
+ "description": "Conformance test kit for the ggui protocol. Drives a behavioral fixture catalog against a live implementation over WebSocket, a resources/read catalog against a live MCP server, and four pure-function catalogs (schema, registration, resolution, binding) for the gadget and tool-binding obligations, reporting a scorecard-style pass / fail / skip. MCP builders adopt this kit to prove their implementation is protocol-conformant.",
5
5
  "license": "Apache-2.0",
6
6
  "keywords": [
7
7
  "ggui",
@@ -50,11 +50,16 @@
50
50
  "types": "./dist/resource-read-conformance/index.d.ts",
51
51
  "import": "./dist/resource-read-conformance/index.js",
52
52
  "default": "./dist/resource-read-conformance/index.js"
53
+ },
54
+ "./binding-conformance": {
55
+ "types": "./dist/binding-conformance/index.d.ts",
56
+ "import": "./dist/binding-conformance/index.js",
57
+ "default": "./dist/binding-conformance/index.js"
53
58
  }
54
59
  },
55
60
  "dependencies": {
56
61
  "ws": "^8.20.1",
57
- "@ggui-ai/protocol": "0.7.0"
62
+ "@ggui-ai/protocol": "0.8.0"
58
63
  },
59
64
  "devDependencies": {
60
65
  "@types/node": "^22.0.0",