-
Notifications
You must be signed in to change notification settings - Fork 580
feat(integration): add gen_ai.conversation.id if available
#5307
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
e5ad308
8884375
c446c35
ca2b9ba
e5d0ffa
5e0d558
5f73e4f
b09e718
635606f
fcd77a7
c67deeb
621766c
852402e
0f8c7ec
bc43364
2359f29
da4d104
0c90615
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -51,3 +51,8 @@ def update_execute_tool_span( | |
|
|
||
| if should_send_default_pii(): | ||
| span.set_data(SPANDATA.GEN_AI_TOOL_OUTPUT, result) | ||
|
|
||
| # Add conversation ID from agent | ||
| conv_id = getattr(agent, "_sentry_conversation_id", None) | ||
| if conv_id: | ||
| span.set_data(SPANDATA.GEN_AI_CONVERSATION_ID, conv_id) | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Duplicated pattern for setting conversation ID on spansLow Severity The same 3-line pattern for extracting and setting |
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,3 +18,8 @@ def handoff_span( | |
| origin=SPAN_ORIGIN, | ||
| ) as span: | ||
| span.set_data(SPANDATA.GEN_AI_OPERATION_NAME, "handoff") | ||
|
|
||
| # Add conversation ID from agent | ||
| conv_id = getattr(from_agent, "_sentry_conversation_id", None) | ||
| if conv_id: | ||
| span.set_data(SPANDATA.GEN_AI_CONVERSATION_ID, conv_id) | ||
|
Comment on lines
18
to
+25
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug: The Suggested FixModify the handoff patching logic to access the secondary agent object, not just its name. Once the secondary agent instance is available, copy the Prompt for AI Agent |
||


Uh oh!
There was an error while loading. Please reload this page.