You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: Fix Python code and add multi-language support to Anthropic message-per-token guide
- Add multi-language support (Python, Java, Swift) to message-per-token
guide, matching the structure of message-per-response
- Fix Python code in both guides: use AsyncAnthropic with async/await,
use Message objects for publish with extras and append_message,
use transport_params for echo suppression
- Scope "without await" asides to JavaScript only
- Filters for `content_block_delta` events with `text_delta` type from text content blocks
530
535
- Appends each token to the original message
531
536
537
+
<Ifagent_lang="javascript">
532
538
<Asidedata-type="note">
533
539
Append operations are published without `await` to maximize throughput. Ably maintains message ordering even without awaiting each append. For more information, see [Publishing tokens](/docs/ai-transport/token-streaming/message-per-response#publishing).
534
540
</Aside>
541
+
</If>
535
542
536
543
<Asidedata-type="important">
537
544
Standard Ably message [size limits](/docs/platform/pricing/limits#message) apply to the complete concatenated message. If appending a token would exceed the maximum message size, the append is rejected.
0 commit comments