Skip to content

Commit b22dac6

Browse files
xrmxhectorhdzg
andauthored
Update instrumentation-genai/opentelemetry-instrumentation-openai-v2/src/opentelemetry/instrumentation/openai_v2/utils.py
Co-authored-by: Hector Hernandez <39923391+hectorhdzg@users.noreply.github.com>
1 parent d3fb79f commit b22dac6

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

  • instrumentation-genai/opentelemetry-instrumentation-openai-v2/src/opentelemetry/instrumentation/openai_v2

instrumentation-genai/opentelemetry-instrumentation-openai-v2/src/opentelemetry/instrumentation/openai_v2/utils.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ def get_llm_request_attributes(
225225
)
226226

227227
if (choice_count := kwargs.get("n")) is not None:
228+
# Only add non default, meaningful values
228229
if isinstance(choice_count, int) and choice_count != 1:
229230
attributes[GenAIAttributes.GEN_AI_REQUEST_CHOICE_COUNT] = (
230231
choice_count

0 commit comments

Comments
 (0)