From cc4b2158dde0923d012eb1531616ec55c2e4a761 Mon Sep 17 00:00:00 2001 From: Andrei Borza Date: Tue, 12 May 2026 15:32:47 +0900 Subject: [PATCH 1/2] docs(js): Add `streamGenAiSpans` option --- .../common/ai-agent-monitoring/index.mdx | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx b/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx index cda0d4dbea740..735245260e1ff 100644 --- a/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx +++ b/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx @@ -113,6 +113,31 @@ Sentry.init({ + + + + +### Streaming Gen AI Spans + +AI spans with large inputs and outputs can hit transaction payload size limits. Set `streamGenAiSpans` to `true` to send `gen_ai` spans as standalone envelope items instead of bundling them in the transaction. + + + + +```javascript +import * as Sentry from "___SDK_PACKAGE___"; + +Sentry.init({ + dsn: "___PUBLIC_DSN___", + tracesSampleRate: 1.0, + streamGenAiSpans: true, +}); +``` + + + + + ## Tracking Conversations From e4f68c2383c453807f2f3db07f4308df0808928b Mon Sep 17 00:00:00 2001 From: Andrei Borza Date: Tue, 12 May 2026 16:51:17 +0900 Subject: [PATCH 2/2] Add call to action --- docs/platforms/javascript/common/ai-agent-monitoring/index.mdx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx b/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx index 735245260e1ff..15fcf5893763b 100644 --- a/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx +++ b/docs/platforms/javascript/common/ai-agent-monitoring/index.mdx @@ -121,6 +121,8 @@ Sentry.init({ AI spans with large inputs and outputs can hit transaction payload size limits. Set `streamGenAiSpans` to `true` to send `gen_ai` spans as standalone envelope items instead of bundling them in the transaction. +Enable this option if `gen_ai` spans are being dropped because the transaction payload exceeds size limits. +