@ggui-ai/protocol-reference-server 0.25.0 → 0.26.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 CHANGED
@@ -1,17 +1,17 @@
1
1
  # @ggui-ai/protocol-reference-server
2
2
 
3
- Minimal reference implementation of the **ggui protocol** — the narrow WebSocket server
3
+ Minimal reference implementation of the **GGUI protocol** — the narrow WebSocket server
4
4
  that `@ggui-ai/protocol-conformance` runs against to prove the protocol is vendor-neutral.
5
5
 
6
6
  This package is **not a production server**. It implements exactly enough of the
7
- ggui live-channel WebSocket wire to pass the conformance kit. Its deliberate design
7
+ GGUI live-channel WebSocket wire to pass the conformance kit. Its deliberate design
8
8
  constraint — zero runtime dependency on `@ggui-ai/mcp-server*` — is what makes the
9
9
  vendor-neutrality claim real: an independent, from-scratch implementation passing the
10
10
  kit grounds the claim empirically rather than by assertion.
11
11
 
12
12
  ## Scope
13
13
 
14
- - WebSocket transport matching the ggui live-channel wire.
14
+ - WebSocket transport matching the GGUI live-channel wire.
15
15
  - In-memory render store with a consume-buffer event ledger (no persistence).
16
16
  - `schemaVersion` handshake with `UPGRADE_REQUIRED` on mismatch.
17
17
  - Subscribe app scope: the subscribe's `appId` must match the GguiSession's
@@ -49,9 +49,10 @@ Prints `READY ws://127.0.0.1:3100/ws` when bound. Ctrl-C to stop.
49
49
  ## CI proof
50
50
 
51
51
  `src/conformance.test.ts` boots this server and runs `@ggui-ai/protocol-conformance`
52
- against it through a `ConformanceHost` adapter. Every drivable conformance fixture must
52
+ against it through a `ConformanceHost` adapter. Every drivable MUST fixture must
53
53
  pass (bootstrap-success, action-ack-sequence, undeclared-action-rejected,
54
54
  action-payload-schema-violation, version-match, version-mismatch, app-mismatch,
55
55
  absent-appid-defaults, host-context-observed-persists); directives outside this server's scope
56
56
  (renderer-url-override, ui-initialize-response-override, and similar) skip cleanly per
57
- the kit's design.
57
+ the kit's design. The one SHOULD it declines, `fresh-subscribe-replays-reserved-preview` (this server keeps no
58
+ retained stream, so a fresh subscribe replays nothing), is graded a warning and pinned as the exact warned set.
@@ -1 +1 @@
1
- {"version":3,"file":"conformance-host.d.ts","sourceRoot":"","sources":["../src/conformance-host.ts"],"names":[],"mappings":"AAoDA,OAAO,KAAK,EACV,eAAe,EAEhB,MAAM,+BAA+B,CAAC;AAGvC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAEnD,MAAM,WAAW,mCAAmC;IAClD,QAAQ,CAAC,cAAc,EAAE,eAAe,CAAC;CAC1C;AAED;;;;;;;;;GASG;AACH,wBAAgB,8BAA8B,CAAC,EAC7C,cAAc,GACf,EAAE,mCAAmC,GAAG,eAAe,CA+IvD"}
1
+ {"version":3,"file":"conformance-host.d.ts","sourceRoot":"","sources":["../src/conformance-host.ts"],"names":[],"mappings":"AAoDA,OAAO,KAAK,EACV,eAAe,EAEhB,MAAM,+BAA+B,CAAC;AAGvC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAEnD,MAAM,WAAW,mCAAmC;IAClD,QAAQ,CAAC,cAAc,EAAE,eAAe,CAAC;CAC1C;AAED;;;;;;;;;GASG;AACH,wBAAgB,8BAA8B,CAAC,EAC7C,cAAc,GACf,EAAE,mCAAmC,GAAG,eAAe,CAyIvD"}
@@ -112,20 +112,16 @@ export function createReferenceConformanceHost({ serverInstance, }) {
112
112
  schemaVersion: serverInstance.renders.get(sessionId)?.versionOverride ??
113
113
  serverInstance.advertisedVersion,
114
114
  });
115
- const fanned = serverInstance.renders.injectFrame(sessionId, {
115
+ // `injectFrame` reaches no one when no subscriber is attached. The
116
+ // kit dispatches every setup directive before it subscribes, and
117
+ // this server keeps no retained stream, so a later fresh subscribe
118
+ // replays nothing. That is the SHOULD the kit grades as a warning
119
+ // (`fresh-subscribe-replays-reserved-preview`), not a directive
120
+ // failure, so the result is not checked here.
121
+ serverInstance.renders.injectFrame(sessionId, {
116
122
  type: 'data',
117
123
  payload: envelope,
118
124
  });
119
- if (!fanned) {
120
- // No subscribers attached — the directive's emission is
121
- // unobservable. Surface for fixture-authoring debuggability
122
- // (the canonical sequence is create-session → subscribe →
123
- // emit-envelope; fixtures that swap order silently lose the
124
- // injection). Not a throw — the directive itself succeeded;
125
- // the unobservability is a fixture concern.
126
- // eslint-disable-next-line no-console
127
- console.warn(`[@ggui-ai/protocol-reference-server] emit-envelope on render '${sessionId}' channel '${step.channel}' had no subscribers — frame dropped`);
128
- }
129
125
  return;
130
126
  }
131
127
  if (step.kind === 'renderer-url-override') {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ggui-ai/protocol-reference-server",
3
- "version": "0.25.0",
3
+ "version": "0.26.0",
4
4
  "description": "Minimal reference implementation of the ggui protocol. Implements exactly enough of the live-channel WebSocket wire to pass the @ggui-ai/protocol-conformance kit. Not a production server — it exists to prove the protocol is vendor-neutral: an independent, from-scratch implementation passing the kit grounds that claim empirically.",
5
5
  "keywords": [
6
6
  "ggui",
@@ -29,14 +29,14 @@
29
29
  },
30
30
  "dependencies": {
31
31
  "ws": "^8.20.1",
32
- "@ggui-ai/protocol": "0.25.0"
32
+ "@ggui-ai/protocol": "0.26.0"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@types/node": "^22.0.0",
36
36
  "@types/ws": "^8.5.10",
37
37
  "typescript": "^5.0.0",
38
38
  "vitest": "^3.2.6",
39
- "@ggui-ai/protocol-conformance": "0.25.0"
39
+ "@ggui-ai/protocol-conformance": "0.26.0"
40
40
  },
41
41
  "repository": {
42
42
  "type": "git",