@@ -55,7 +55,7 @@ def traced_method(wrapped, instance, args, kwargs):
5555 service_provider = SERVICE_PROVIDERS ["OPENAI" ]
5656 span_attributes = {
5757 ** get_langtrace_attributes (version , service_provider , vendor_type = "llm" ),
58- ** get_llm_request_attributes (kwargs ),
58+ ** get_llm_request_attributes (kwargs , operation_name = "images_generate" ),
5959 ** get_llm_url (instance ),
6060 SpanAttributes .LLM_PATH : APIS ["IMAGES_GENERATION" ]["ENDPOINT" ],
6161 ** get_extra_attributes (),
@@ -118,7 +118,7 @@ async def traced_method(wrapped, instance, args, kwargs):
118118
119119 span_attributes = {
120120 ** get_langtrace_attributes (version , service_provider , vendor_type = "llm" ),
121- ** get_llm_request_attributes (kwargs ),
121+ ** get_llm_request_attributes (kwargs , operation_name = "images_generate" ),
122122 ** get_llm_url (instance ),
123123 SpanAttributes .LLM_PATH : APIS ["IMAGES_GENERATION" ]["ENDPOINT" ],
124124 ** get_extra_attributes (),
@@ -181,7 +181,7 @@ def traced_method(wrapped, instance, args, kwargs):
181181
182182 span_attributes = {
183183 ** get_langtrace_attributes (version , service_provider , vendor_type = "llm" ),
184- ** get_llm_request_attributes (kwargs ),
184+ ** get_llm_request_attributes (kwargs , operation_name = "images_edit" ),
185185 ** get_llm_url (instance ),
186186 SpanAttributes .LLM_PATH : APIS ["IMAGES_EDIT" ]["ENDPOINT" ],
187187 SpanAttributes .LLM_RESPONSE_FORMAT : kwargs .get ("response_format" ),
@@ -432,7 +432,7 @@ def traced_method(wrapped, instance, args, kwargs):
432432
433433 span_attributes = {
434434 ** get_langtrace_attributes (version , service_provider , vendor_type = "llm" ),
435- ** get_llm_request_attributes (kwargs ),
435+ ** get_llm_request_attributes (kwargs , operation_name = "embed" ),
436436 ** get_llm_url (instance ),
437437 SpanAttributes .LLM_PATH : APIS ["EMBEDDINGS_CREATE" ]["ENDPOINT" ],
438438 SpanAttributes .LLM_REQUEST_DIMENSIONS : kwargs .get ("dimensions" ),
@@ -490,7 +490,7 @@ async def traced_method(wrapped, instance, args, kwargs):
490490
491491 span_attributes = {
492492 ** get_langtrace_attributes (version , service_provider , vendor_type = "llm" ),
493- ** get_llm_request_attributes (kwargs ),
493+ ** get_llm_request_attributes (kwargs , operation_name = "embed" ),
494494 SpanAttributes .LLM_PATH : APIS ["EMBEDDINGS_CREATE" ]["ENDPOINT" ],
495495 SpanAttributes .LLM_REQUEST_DIMENSIONS : kwargs .get ("dimensions" ),
496496 ** get_extra_attributes (),
0 commit comments