@silverprotocol/google-adk 1.0.0-rc.3 → 1.0.0-rc.5
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 +5 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -33,6 +33,7 @@ facet's per-field dispositions, including its disclosed `silently-dropped` gaps)
|
|
|
33
33
|
|
|
34
34
|
| `@google/adk` | verified | with | evidence |
|
|
35
35
|
| --- | --- | --- | --- |
|
|
36
|
+
| `2.3.0` | 2026-10-26 | 1.0.0-rc.4 | @google/genai 2.30.0 -> 2.31.0 under @google/adk 2.3.0 (ADK declares genai ^2.29.1); dependencies and file set unchanged. No Event or Part member the facet reads changes: FinishReason, BlockedReason / promptFeedback, usageMetadata, Part, Content, FunctionCall / FunctionResponse, the Candidate members and every LiveServerMessage type are identical, and on the Interactions route Interaction still declares errors and the status update still has no error member. The remaining type changes are request side. The one runtime change: genai now checks every SSE data event for an error payload, so a mid-stream {"error":{"code":...}} event throws an ApiError where 2.30.0 passed it through as an empty chunk. ADK 2.3.0 reports that throw as an in-band error (errorCode UNKNOWN_ERROR, the HTTP code inside errorMessage), which the facet closes as error + turn.error. On 2.30.0 the same stream lost the error: a text-then-error stream closed turn.abort stream-truncated (or a success turn.done under a host completion marker), and an error-only stream opened no turn. Shown on engine-built streams with a stubbed fetch, both versions. Live: echo-gemini38 (gemini-3.8-flash) captured green at adk 2.3.0 with genai 2.31.0, with no drops and no new fields and the same event shape as the committed capture. |
|
|
36
37
|
| `2.3.0` | 2026-10-15 | 1.0.0-rc.3 | @google/adk 2.2.1 -> 2.3.0 with @google/genai 2.28.0 -> 2.30.0 (2.3.0 declares @google/genai ^2.29.1). Event and Part surfaces unchanged: the drift gate finds no new member. NEW RUNTIME PATH: when the host's abortSignal fires during runAsync, the Runner yields a closing event with errorCode "INVOCATION_ABORTED" (and a functionResponse {error} for each call left unanswered) before it returns (runner.js, events/abort_events.js). Its 24 engine-built natives (a text reply, one and two dangling calls, a pending confirmation ask, an ask after a pause, and an unaborted control; both streaming modes, two runs each) are fixtures/adk-abort; the facet's close for that event ships in this cohort. ENGINE FIXTURES regenerated at 2.3.0 (adk-error, adk-pause; 81 files) show two engine changes. In SSE, the partial chunks and the final aggregate of one model response now share one event id (2.2.1 gave each its own); this does not reach the wire. The engine-built adk_request_credential ask's auth URI no longer carries an empty redirect_uri=; this does reach the wire, since the facet carries that URL verbatim in tool.args, the hitl.ask and the paused close. 160 of 162 runs (with and without host completion) are identical once run ids and timestamps are masked; the two plain-credential runs differ by that URL only. genai 2.28.0 -> 2.30.0: Part is byte-identical (verifiedAt 2.30.0); usageMetadata gains initialPromptTokenCount and Transcription gains startOffset/endOffset, none of which the recorded streams carry. LIVE at 2.3.0 / 2.30.0 on gemini-3.8-flash: echo-gemini38 and app-spec-gemini38 re-captured green, each with its one tool call (echo, render_card) and the same event sequence as at 2.1.0; census zero drops and zero new fields. |
|
|
37
38
|
| `2.2.1` | 2026-10-07 | 0.12.4 | @google/adk 2.1.0 -> 2.2.1 with @google/genai 2.24.0 -> 2.27.0. Dependency shape unchanged except adm-zip, which adk now declares at ^0.6.1, so the adm-zip security override is retired. 2.2.1 widens its Gemini 3.x Live path to every gemini-3.*-live model: on gemini-3.8-live a toolCall's function calls are yielded at once, input transcriptions arrive per fragment as finished, and text input goes through sendRealtimeInput. the CONTINUATION finish reason (new in genai 2.26.0) and the per-fragment transcriptions are covered by facet tests. Live: the three gemini-3.8-live seeds re-captured green (live-bargein, live-bargein2, live-tool): the same interruptions and the same turn outcomes; in live-tool the function call now opens the message. The text-input capture cannot exercise the per-fragment input transcription (capture backlog: an audio-input Live capture). |
|
|
38
39
|
| `2.1.0` | 2026-09-23 | 0.6.3 | @google/adk 2.0.0 -> 2.1.0, the first minor since the 2.0 major, with @google/genai 2.22.0 -> 2.24.0. WIRE CONTRACT UNCHANGED: Event, LlmResponse, CompactedEvent, InMemoryRunner, MCPToolset and the MCP runtime are byte-identical and the EventActions interface is unchanged; the capture agent compiles against 2.1.0. genai 2.24.0 adds one Part member, speechMetadata (16 -> 17), CARRIED through the existing unmapped-part-fields provider-raw carry. Hardened three pre-existing assumptions the genai types never promised: ExecutableCode.code, Blob.mimeType/data and FileData.fileUri are optional, and a part missing one now rides verbatim as provider-raw instead of throwing or emitting a schema-invalid block. DEPENDENCY SHAPE is where 2.1.0 bites: it adds dockerode as an optionalDependency, which brings back ssh2 and cpu-features, both with install scripts, so both workspace files now declare them false under allowBuilds (without that, every strict-builds install fails ERR_PNPM_IGNORED_BUILDS). @types/dockerode is a REGULAR dependency and puts a second @types/node (18.x) into the program of every `import from "@google/adk"`; consumers compiling with skipLibCheck:false may notice. genai stays a regular dependency at ^2.9.0 and resolves to a single 2.24.0 copy (plus the expected legacy 1.52.0 under @google-cloud/vertexai). adk 2.1.0 moved its OpenTelemetry exporters 0.205.0 -> 0.222.0, which exact-pin @opentelemetry/core 2.11.0, so the ^2.8.0 core override is RETIRED (confirmed after a fresh resolution: one core copy, 2.11.0). adm-zip is STILL ^0.5.17 in 2.1.0, so the ^0.6.1 override stays; upstream fix is google/adk-js#923. NEW RUNTIME PATH: an unregistered or hallucinated tool name now yields functionResponse {error: "Function X is not found in the toolsDict."} instead of throwing, and this facet classifies that envelope tool.done outcome "ok" - a pre-existing gap (ADK's {error} tool-failure envelope has always read as ok) that 2.1.0 makes reachable from ordinary model hallucination; pinned by a synthetic test at the current behaviour until decided. LIVE at 2.1.0 / 2.24.0 on gemini-3.8-flash: echo-, app-spec- and thinking-gemini38 refreshed (thinking-gemini38: 2 thought parts, 2 signatures); NEW tool-error-gemini38, which steers the bare tool name because ADK registers MCP tools without the mcp__<server>__ prefix, recording the clean MCP isError path rather than the hallucinated-tool envelope; and the grammar seeds multi-turn, single-tool-call and text-only MIGRATED from gemini-2.5-flash at adk 1.3.0, where they had sat since July proving nothing about the current peer. Census ZERO drops / ZERO new fields on every adk seed. The 2026-09-21 nightly typechecked adk 2.1.0 but did not exercise genai 2.24.0. Facet tests now 105. |
|
|
@@ -64,7 +65,7 @@ facet's per-field dispositions, including its disclosed `silently-dropped` gaps)
|
|
|
64
65
|
|
|
65
66
|
> **Search grounding (spec §13.3).** When Gemini grounds a reply with Google Search, the facet emits `display.required` carrying the Search Suggestions HTML (`groundingMetadata.searchEntryPoint.renderedContent`), which the reducer records on the turn. Rendering, storing and re-displaying it are governed by Google's grounding terms (SPEC §13.3). `toPersistable` from `@silverprotocol/core` gives a fold without it, for a host that stores the result.
|
|
66
67
|
|
|
67
|
-
> **Prompt blocks.** In `StreamingMode.NONE`, `@google/adk` 2.1.0 turns a blocked prompt into an event whose `errorCode` is the block reason, with no `finishReason` and no content. The facet records one `prompt.blocked` for each such event while its turn is open, before the turn's terminal: `SAFETY` → `"safety"`, `BLOCKLIST` → `"blocklist"`, `PROHIBITED_CONTENT` → `"prohibited"`, and any other treated value → `"other"` with `reasonRaw` verbatim, with no `safety`, since the event carries no ratings. The treated values are genai's `BlockedReason` values (`BLOCKED_REASON_UNSPECIFIED`, `SAFETY`, `OTHER`, `BLOCKLIST`, `PROHIBITED_CONTENT`, `IMAGE_SAFETY`, `MODEL_ARMOR`, `JAILBREAK` at genai 2.24.0) and the Gemini API's `BLOCK_REASON_UNSPECIFIED`. The record changes no terminal: the turn ends as it would without it. Detect a block from `prompt.blocked` (or the fold's `promptBlocked`), not from the terminal. An event with a `finishReason` beside its `errorCode` is a response-level block and records nothing. The facet checks each event on its own. An event that carries an `a2a:response` entry in `customMetadata`, whoever wrote it (ADK's `RemoteA2AAgent` writes one on every event it relays), is never read as a prompt block: at 2.1.0 the relay drops the `finishReason` that tells a prompt block from a response-level one; in a relay that streams, the relayed event carries the block's code in `errorCode` when the remote agent sends one, and then ends the turn as an error. A session service that reloads an event without its raw form (for Vertex, an event stored without `rawEvent`) can drop its `finishReason`, so a response-level block that reaches the facet through such a reload is recorded as a prompt block. So is a Workflow node's error event when the node throws an error whose `code` is a treated value.
|
|
68
|
+
> **Prompt blocks.** In `StreamingMode.NONE`, `@google/adk` 2.1.0 through 2.3.0 turns a blocked prompt into an event whose `errorCode` is the block reason, with no `finishReason` and no content. The facet records one `prompt.blocked` for each such event while its turn is open, before the turn's terminal: `SAFETY` → `"safety"`, `BLOCKLIST` → `"blocklist"`, `PROHIBITED_CONTENT` → `"prohibited"`, and any other treated value → `"other"` with `reasonRaw` verbatim, with no `safety`, since the event carries no ratings. The treated values are genai's `BlockedReason` values (`BLOCKED_REASON_UNSPECIFIED`, `SAFETY`, `OTHER`, `BLOCKLIST`, `PROHIBITED_CONTENT`, `IMAGE_SAFETY`, `MODEL_ARMOR`, `JAILBREAK` at genai 2.24.0) and the Gemini API's `BLOCK_REASON_UNSPECIFIED`. The record changes no terminal: the turn ends as it would without it. Detect a block from `prompt.blocked` (or the fold's `promptBlocked`), not from the terminal. An event with a `finishReason` beside its `errorCode` is a response-level block and records nothing. The facet checks each event on its own. An event that carries an `a2a:response` entry in `customMetadata`, whoever wrote it (ADK's `RemoteA2AAgent` writes one on every event it relays), is never read as a prompt block: at 2.1.0 the relay drops the `finishReason` that tells a prompt block from a response-level one; in a relay that streams, the relayed event carries the block's code in `errorCode` when the remote agent sends one, and then ends the turn as an error. A session service that reloads an event without its raw form (for Vertex, an event stored without `rawEvent`) can drop its `finishReason`, so a response-level block that reaches the facet through such a reload is recorded as a prompt block. So is a Workflow node's error event when the node throws an error whose `code` is a treated value. In SSE mode ADK's aggregator absorbs a prompt-block chunk (observed at 2.1.0 and 2.3.0), so a prompt block records no `prompt.blocked`: with a usage report it arrives as a usage-only event with no `errorCode` and no `finishReason`, which closes the turn as `success` (`stop`) on the host-completion event and as `turn.abort` (`stream-truncated`) at `flush()` without it; with no usage report ADK yields no event and no turn opens. Only `StreamingMode.NONE` yields the shape the facet records. The Live and Interactions routes never produce it.
|
|
68
69
|
|
|
69
70
|
> **Streamed text (SSE and Live).** In `StreamingMode.SSE` on the generateContent route, and on the Live API, ADK streams a model call's text as `partial:true` chunks, then repeats the streamed text in one `partial:false` event: when the call closes, in SSE before a non-text part in the same stream, and on the Live API before a tool call, on a switch between thought and text, and on a barge-in. The facet renders the chunks and drops the repeat (spec §8.0 item 3). It matches a repeat only to the text streamed by the same source (the event's author, branch and node path, and for an event `@google/adk`'s `RemoteA2AAgent` relays, the relayed task and, within it, the relayed artifact or the relayed status messages, read from its `customMetadata`), so interleaved streams stay apart, and a new relayed task never reads an earlier one's text. An event serialized from ADK-Python's relay (`custom_metadata`) is matched by author, branch and node path alone: that relay records the whole task for every event it relays, so its relayed streams cannot be told apart. A text event is the repeat when one text starts with the other (an equal or shorter one renders nothing, a longer one renders only its added text: the repeat before a function call also holds that chunk's own text, and an after-model callback may extend the final), or when the streamed text ends with it (a later call's repeat after a call whose close never arrived, or ADK's structured-output rewrite). Any other text renders in full. Every other event of the source ends the match, except the ones ADK yields between the chunks and the repeat: a block's finish, a Live usage report or grounding record on its own, a transcription, a function response, and a `partial:false` event whose parts are all non-text. The source's next chunks then start a new match. An event without a branch that finds no match of its own (ADK's A2A relay rebuilds its repeat without one, and a failed call's in-band error carries none) reads the matches of the same author and node path: a repeat takes one only when exactly one is open, and an event that ends the match ends them all, so two open matches of one author and node path that differ only by branch would both end. A relayed artifact with no match of its own reads its task's status messages; a relayed Task or Message restates its task, so it is matched, in the order ADK renders a Task, against that task's artifacts and then its status messages (else the artifacts alone, else the status messages alone), and it ends them; and the relay's own failure event ends every relayed match of its author and node path. It assumes no agent or response processor of yours yields a text event of the same source between a call's chunks and its repeat (ADK registers none by default): such a text that starts with, is a start of, or ends the streamed text is read as the repeat.
|
|
70
71
|
|
|
@@ -109,7 +110,9 @@ agEvents.push(...n.flush()); // seal anything still open
|
|
|
109
110
|
|
|
110
111
|
> **Errors the runtime throws (spec §8.0 host obligation 1).** When ADK throws instead of ending the stream (for example its LLM-call limit), catch it and push `{ type: "__host_error__", code, message, usage? }` (exported as `ADK_HOST_ERROR_TYPE`) before `flush()`: the open turn closes `turn.error` with that code and message and the turn's usage plus the sentinel's `usage`: the sentinel's usage covers only work the stream did not report, and is added to what the stream reported, so pass the usage of unreported work only, never a total, and with no turn open a fresh terminal turn, `turn_<invokeId>_host_error_<n>`, carries it. A turn whose pause was signalled closes `paused` first, with its asks and its usage, and the error then closes on a new top-level turn, `<turn id>_error`, with one message and no content, carrying only the sentinel's usage. The sentinel may be the caught Error itself with `type` and `code` assigned; its message is kept.
|
|
111
112
|
|
|
112
|
-
> **
|
|
113
|
+
> **Chrome built-in model.** When `@google/adk` 2.3.0's Chrome built-in model backend gets a reply it cannot parse that looks like a cut-off JSON envelope, and it can recover no text from it, ADK answers with the fixed text "The model started an answer and did not finish it. Ask again." and `turnComplete: true` instead of the raw output. The facet maps that event as any final answer: the text lands in the turn, which closes as `success` (`stop`) when no ask is pending. Nothing in the event marks the text as ADK's, so a host that must tell it from the model's own answer matches the text.
|
|
114
|
+
|
|
115
|
+
> **In-band errors (spec §8.0 item 35).** ADK yields an error it meets as an event carrying both `errorCode` and `errorMessage` (a rate-limit error, a response-level block with a finish message, a failed Interactions call), and keeps running: a SequentialAgent runs its next sub-agent, a Workflow node retries, a callback or a further model round follows. So the facet never closes a turn on one. The `push()` that receives it emits the non-terminal `error` event, with `code` from `errorCode` and `message` from `errorMessage`, and every later event of the invocation lands in the same turn. At the invocation's end, on the host-completion event, on a host-terminal event, or at `flush()`, the turn closes with one `turn.error`, never as `success`, even when a later sub-agent or a retried node answered. Its `code` and `message` are the host-terminal event's when you fed one, otherwise the invocation's first in-band error's, and it carries the turn's accumulated usage. When the turn's pause was signalled, it closes `paused` first, and the error then closes on a new top-level turn, `<turn id>_error`, with one message and no content. In SSE mode ADK repeats an error as a model call's stream closes, in a `partial: false` event with the code and message of the previous event of the same author, branch and node path; that repeat yields no further `error`, and the call's usage counts once, from the later report. From `@google/genai` 2.31.0, an error the service sends as an event of an SSE stream (a rate limit or an overloaded model after the stream began) reaches ADK as a thrown error, and ADK 2.3.0 reports it as an in-band error whose `errorCode` is `"UNKNOWN_ERROR"` and whose `errorMessage` is `got status: <status>.` followed by the error's JSON, the only place its HTTP code appears; the turn closes as `turn.error`. With `@google/genai` 2.30.0 such an event reached ADK as an empty chunk and no error was reported: the text already streamed closed the turn as `success` on the host-completion event and as `turn.abort` (`stream-truncated`) at `flush()`, and a stream with no text before the error opened no turn. ADK's `RemoteA2AAgent` can report one remote failure twice, the second time in the event with which it closes the remote run (it carries an `a2a:request` entry in `customMetadata`); that event yields no further `error` and adds no usage when it carries the same code, message and usage report as the earlier one and the same `a2a:task_id` entry, present on both. Every other such event is a further error. An event with `errorMessage` and no `errorCode` is not an in-band error: it yields no `error` event and closes as it otherwise would, and its message rides the event-level `provider-raw` carry verbatim (ADK's A2A relay reports its own failure that way). The relay's message is the text of the error it caught, which can include data the remote agent returned and the agent-card URL; treat it as remote content before forwarding it to a client. At `@google/adk` 2.1.0 through 2.3.0 the Live path yields none: a Live failure reaches the facet as the host-terminal event. A failed Interactions call can lose its code: `@google/adk` 2.3.0 reads a failed interaction's code and message from a singular `error` member, while `@google/genai` 2.30.0 and 2.31.0 declare an interaction's failures as an `errors` array and give the stream's status update no error member, so a failure the service reports that way reaches the facet as `errorCode` `"UNKNOWN_ERROR"` with `errorMessage` `"Unknown error"`, and the `error` event and `turn.error` carry those. The code of the Interactions stream's own `error` event reaches them unchanged.
|
|
113
116
|
|
|
114
117
|
> **Client aborts (spec §8.0 items 35 and 26).** From `@google/adk` 2.3.0, when the host's `abortSignal` ends a `runAsync()` run and the host keeps reading, ADK yields one more event and stores it as the session's last: its seal, with `errorCode` `"INVOCATION_ABORTED"` and `errorMessage` `"Invocation was aborted by client."`, which answers each call still unanswered with an error result, a pending `adk_request_*` call included. The facet recognises the seal by that `errorCode` value alone, and it is not an in-band error. The `push()` that receives it closes each call it answers with `tool.done` (`outcome: "error"`), then closes the turn as `turn.abort` (`cancelled`), with the turn's usage, when any, on the `message.end`, and emits no `error` or `turn.error`. An ask whose call the seal answers is no longer pending, so the turn does not close `paused`; the same holds when any other non-partial event of the invocation answers an ask's call. The seal's code and message ride the event-level `provider-raw` carry verbatim. A host that stops reading when it aborts never sees the seal, so `flush()` closes its turn as it closes any stream cut at that point: as `turn.abort` (`stream-truncated`), or as `paused` while an ask was pending, once ADK had signalled the pause. A run aborted before ADK yielded any event opens no turn. `runLive()` yields no seal.
|
|
115
118
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@silverprotocol/google-adk",
|
|
3
|
-
"version": "1.0.0-rc.
|
|
3
|
+
"version": "1.0.0-rc.5",
|
|
4
4
|
"description": "AgJSON normalizer for the official Google Agent Development Kit — @google/adk (ADK Event / Gemini Content.parts[] → AgEvent[]).",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"!dist/**/*.test.*"
|
|
35
35
|
],
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@silverprotocol/core": "1.0.0-rc.
|
|
37
|
+
"@silverprotocol/core": "1.0.0-rc.5"
|
|
38
38
|
},
|
|
39
39
|
"peerDependencies": {
|
|
40
40
|
"@google/adk": ">=1.0.0 <3"
|