@nifrajs/agent-app 5.1.0 → 5.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.
Files changed (2) hide show
  1. package/CHANGELOG.md +95 -0
  2. package/package.json +4 -3
package/CHANGELOG.md ADDED
@@ -0,0 +1,95 @@
1
+ # @nifrajs/agent-app
2
+
3
+ ## 5.2.0
4
+
5
+ ### Patch Changes
6
+
7
+ - 9498cf8: The package ships its `CHANGELOG.md`, so the installed package has the notes for every version, as the GitHub release does. Before, the tarball held only the code, `README.md`, `LICENSE` and `package.json`.
8
+ - Updated dependencies [9498cf8]
9
+ - @nifrajs/agent-protocol@5.2.0
10
+
11
+ ## 5.1.0
12
+
13
+ ### Patch Changes
14
+
15
+ - abb4354: The package now ships the MIT `LICENSE` text, as every other @nifrajs package already did.
16
+ - Updated dependencies [abb4354]
17
+ - @nifrajs/agent-protocol@5.1.0
18
+
19
+ ## 5.0.0
20
+
21
+ ### Minor Changes
22
+
23
+ - 7391acd: `AgentAppClient.send` resumes a turn whose stream breaks mid-turn: it calls `turn.attach` with the last seq it received and goes on yielding views without a gap or a repeat. `resumeAttempts` (default 3, counted since the last attach that delivered a new event; 0 turns it off) and `resumeDelayMs` (default 250) bound it. A host that refuses the attach (it keeps no turns, or no longer holds those events) leaves `send` throwing the original break, as before. `AgentTransportError` now carries the response `status` when a host refused a stream.
24
+ - 4417bc9: `AgentAppClient.send()` streams a turn on a session other clients share. A turn's events used to wait behind the seqs that went to another tab's turns, a gap that never fills, so that tab saw no events at all. A turn now starts at its first event, and anything still held behind a gap is released, in order, when the stream ends. `OrderedEventBuffer` gains `flush()` for the same purpose: it releases every held event and counts the missing seqs on `dropped`.
25
+ - a3b3c51: Backends can send their own events. A `type` of `x-<vendor>.<name>` (lowercase, at most 64 characters) with an optional `turnId` and a bounded `data` value is now a valid `AgentEvent` (`AgentExtensionEvent`, `isAgentExtensionEventType`). Before, `isAgentEvent` refused every type the protocol did not define, so a vendor frame such as Codex's plan or a reviewer notice failed the whole turn. `CodingAgentHost` passes extension events through, records only their type and turn as evidence, and takes `extensionEvents: { "x-codex.plan": (event) => boolean }` to check the types it knows; a refused one fails the turn like a malformed event. `@nifrajs/agent-app`'s `toEventView` projects one to `ExtensionEventView` (type, turn, `hasData`, never the data). An exhaustive `switch` over `event.type` now needs a `default` branch for extension events.
26
+
27
+ `agentEventProblem(value)` says why an event is invalid, naming the field and the limit it broke but never its content, and the host's `BACKEND_PROTOCOL` failure now carries it: `backend emitted an invalid agent event: turn.started.prompt is longer than 262144 characters` instead of the bare first half.
28
+
29
+ - b435f13: Three events join the protocol: `reasoning.delta` (`turnId`, optional `itemId`, `text`), `plan.updated` (`turnId`, optional `callId` and `explanation`, and `entries` of `content` up to 4096 characters, `status` `pending` | `in_progress` | `completed`, optional `priority`; each event is the whole plan), and `context.usage` (`usedTokens`, optional `windowTokens`, `inputTokens`, `outputTokens`, `cachedInputTokens`, `reasoningTokens`, `estimated`). The plan entry shape is ACP's. `NifraBackend`'s model port can stream `{ type: "reasoning_delta", text, itemId? }` and `{ type: "usage", usedTokens, ... }` chunks, which become those events; a count that is not a non-negative integer is dropped. `CodingAgentHost` keeps only counts as evidence (a plan's entry and completed counts, never its text), and `toEventView` projects them to `ReasoningDeltaView`, `PlanUpdatedView`, and `ContextUsageView` (with `fill` when the window is known). An exhaustive `switch` over `event.type` needs the three new cases.
30
+
31
+ ### Patch Changes
32
+
33
+ - c8577dd: The coding-agent RPC `approval.list` names each pending approval `approvalId`, the name `approval.resolve` takes, and keeps `id`. `AgentAppClient.listApprovals()` reads either name, so pending approvals from the RPC host are no longer dropped. The workbench refreshes its approval list when a turn reports `approval.required` or `approval.resolved`, while the turn is still streaming.
34
+ - 7775c2b: Detach AG-UI viewers on initial or later output overflow, cancel unlogged work, and preserve logged run results for replay. Parse fragmented agent SSE frames with linear scanning and UTF-8 accounting. Bound each DevTools connection's pending bytes and close stalled readers, replaying only the recent history that fits.
35
+ - Updated dependencies [36bdc71]
36
+ - Updated dependencies [6b0db44]
37
+ - Updated dependencies [a3b3c51]
38
+ - Updated dependencies [343bae0]
39
+ - Updated dependencies [b435f13]
40
+ - @nifrajs/agent-protocol@5.0.0
41
+
42
+ ## 4.0.2
43
+
44
+ ### Patch Changes
45
+
46
+ - @nifrajs/agent-protocol@4.0.2
47
+
48
+ ## 4.0.1
49
+
50
+ ### Patch Changes
51
+
52
+ - @nifrajs/agent-protocol@4.0.1
53
+
54
+ ## 4.0.0
55
+
56
+ ### Patch Changes
57
+
58
+ - 930ed0d: `AgentAppClient.send()` delivers every turn, not only the first. The client advances `session.lastSeq` as it yields each event, and the next turn's ordering buffer starts after it. Previously a second turn's events waited behind a gap that never filled, and the turn yielded nothing.
59
+ - db9d1e1: The view models hold their input to one shape:
60
+
61
+ - `boundaryIsStale` treats an expiry or a clock that is not a number as stale, so `boundaryCommands` offers no command for that boundary.
62
+ - `toRunStudioView` refuses a run graph that lists the same node twice, instead of rendering it twice and counting it twice.
63
+ - `toReviewView` reads the `report` inside a host result as a review report only. A host result nested inside another projects as the `invalid-report` unavailable view. Duplicate finding ids are checked in linear time, so a report at the 4,096-finding cap parses in about 5 ms instead of 22 ms.
64
+
65
+ - ef28ef9: Run views list nodes, checks and findings in code-unit order of their ids, the same in every locale.
66
+ - @nifrajs/agent-protocol@4.0.0
67
+
68
+ ## 3.5.0
69
+
70
+ ### Patch Changes
71
+
72
+ - 6430334: Add the provider-neutral, content-free review report contract and expose `nifra review` through the CLI, authenticated agent RPC, and Workbench-safe view projections.
73
+ - @nifrajs/agent-protocol@3.5.0
74
+
75
+ ## 3.4.0
76
+
77
+ ### Patch Changes
78
+
79
+ - 8d23613: Add the opt-in `@nifrajs/webmcp` package: typed WebMCP registration, core-backed receipts, deterministic predictive-UI reconciliation, and host-independent conformance checks. Also tighten agent execution cancellation cleanup so aborted local work cannot leak into later turns.
80
+ - Updated dependencies [8d23613]
81
+ - @nifrajs/agent-protocol@3.4.0
82
+
83
+ ## 3.3.0
84
+
85
+ ### Patch Changes
86
+
87
+ - @nifrajs/agent-protocol@3.3.0
88
+
89
+ ## 3.2.0
90
+
91
+ ### Patch Changes
92
+
93
+ - 1a041a9: Add provider-neutral gateway and deployment contracts with deterministic reference adapters and evidence-safe policy checks.
94
+ - Updated dependencies [e3e197b]
95
+ - @nifrajs/agent-protocol@3.2.0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nifrajs/agent-app",
3
- "version": "5.1.0",
3
+ "version": "5.2.0",
4
4
  "description": "Presentation-safe browser SDK for Nifra agent hosts: negotiated commands, ordered event streaming, and content-free view models over the agent protocol.",
5
5
  "keywords": [
6
6
  "bun",
@@ -27,14 +27,15 @@
27
27
  },
28
28
  "files": [
29
29
  "dist",
30
- "src"
30
+ "src",
31
+ "CHANGELOG.md"
31
32
  ],
32
33
  "sideEffects": false,
33
34
  "scripts": {
34
35
  "build": "tsc -p tsconfig.build.json && bun run ../../scripts/fix-dts.ts dist"
35
36
  },
36
37
  "dependencies": {
37
- "@nifrajs/agent-protocol": "5.1.0"
38
+ "@nifrajs/agent-protocol": "5.2.0"
38
39
  },
39
40
  "license": "MIT",
40
41
  "publishConfig": {