← All updates

0.3.11

Token streaming for the Claude facet

The headline: @silverprotocol/claude-agent-sdk now streams. Run the Claude Agent SDK with includePartialMessages: true and the facet emits token-granular text.delta / reasoning.delta / tool.args.delta events as stream_event partials arrive — instead of one burst at turn end.

const response = query({ prompt, options: { includePartialMessages: true } });

No other change needed:

  • The complete assistant message the SDK still emits after partials is deduplicated automatically — reducer state after partials + suppressed-complete is provably identical to the complete-only fold (pinned by test).
  • Streams without partials produce byte-identical output to previous releases.
  • Time-to-first-token rides message.metadata as ttft_ms.
  • Census-caught bonus: the SDK’s system/status frames ("requesting", …) are now carried via ext.anthropic.frame — wire-level input for agent-status UI.

Verified live, not just synthetically: a new corpus seed (partials-sonnet5) captured the real interleaving — complete frames landing mid-stream, tool results binding before message_stop — and the mapping handles all of it.