-
Notifications
You must be signed in to change notification settings - Fork 99
feat(ai): Add support for AI token span data #3250
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, please, add tests for expected behaviour.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a side note, could you reword the PR description to align with Sentry's commit message guidelines? Thanks beforehand!
@colin-sentry are there any plans to follow up on this ? |
2bcb443
to
5be051d
Compare
@olksdr I'm having a bit of trouble writing a test for this - the test included in this PR still passes if you revert the regex change. |
Do we need all the new fields on span data? |
Discussed, by adding them to span data we can avoid them being removed as PII |
Upstream in SDKs (getsentry/sentry-python#2791) we added strings like "ai.prompt_tokens.used"
This adds them as known data fields, otherwise they are removed as PII since most configurations consider any superstring of "token" to be a password.