Skip to content

Support the capture of complex attributes in span. #7879

@Cirilla-zmh

Description

@Cirilla-zmh

Background

According to semantic-conventions v1.38.0, generative AI instrumentations should emit chat messages as complex attributes both in span and in log, which depends on the option. However, when we try to migrate the semconv of OpenAI from v1.36.0 to v1.38.0 (see this PR), it turns out that we just support the capture of complex attributes in log now, and the feature for span is still on the way.

I believe this is a great user case which promotes the popularity of complex attributes and it's a great timing to do that. @trask and I have discussed this topic on the APAC Java SIG and then we have this issue.

Issues depend on this feature:

cc @anuraaga @lmolkova

Suggested Solution

We should add some test cases for extended span like this. Relevant infrastructures like marshalers should also be ready.

P.S. I guess we're able to set an object in Value<?> type as a span attribute yet but perhaps I'm wrong. I will add more information after studying it.

Tip: React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.

Metadata

Metadata

Assignees

Labels

Feature RequestSuggest an idea for this project

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions