Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

11.7 KB
Raw Blame
{
  "resourceSpans": [
    {
      "resource": {
        "attributes": [
          {
            "key": "host.name",
            "value": {
              "stringValue": "fixture-host"
            }
          },
          {
            "key": "host.arch",
            "value": {
              "stringValue": "arm64"
            }
          },
          {
            "key": "host.id",
            "value": {
              "stringValue": "00000000-0000-0000-0000-000000000000"
            }
          },
          {
            "key": "process.pid",
            "value": {
              "intValue": "83283"
            }
          },
          {
            "key": "process.executable.name",
            "value": {
              "stringValue": "node"
            }
          },
          {
            "key": "process.executable.path",
            "value": {
              "stringValue": "/home/user/.local/share/fnm/node-versions/v25.8.1/installation/bin/node"
            }
          },
          {
            "key": "process.command_args",
            "value": {
              "arrayValue": {
                "values": [
                  {
                    "stringValue": "/home/user/.local/share/fnm/node-versions/v25.8.1/installation/bin/node"
                  },
                  {
                    "stringValue": "--env-file=.env"
                  },
                  {
                    "stringValue": "/home/user/dev/litellm-lens-example/vercel-ai-sdk-js/simple/main.ts"
                  }
                ]
              }
            }
          },
          {
            "key": "process.runtime.version",
            "value": {
              "stringValue": "25.8.1"
            }
          },
          {
            "key": "process.runtime.name",
            "value": {
              "stringValue": "nodejs"
            }
          },
          {
            "key": "process.runtime.description",
            "value": {
              "stringValue": "Node.js"
            }
          },
          {
            "key": "process.command",
            "value": {
              "stringValue": "/home/user/dev/litellm-lens-example/vercel-ai-sdk-js/simple/main.ts"
            }
          },
          {
            "key": "process.owner",
            "value": {
              "stringValue": "user"
            }
          },
          {
            "key": "service.name",
            "value": {
              "stringValue": "unknown_service:node"
            }
          },
          {
            "key": "telemetry.sdk.language",
            "value": {
              "stringValue": "nodejs"
            }
          },
          {
            "key": "telemetry.sdk.name",
            "value": {
              "stringValue": "opentelemetry"
            }
          },
          {
            "key": "telemetry.sdk.version",
            "value": {
              "stringValue": "2.11.0"
            }
          }
        ]
      },
      "scopeSpans": [
        {
          "scope": {
            "name": "litellm.gateway.client"
          },
          "spans": [
            {
              "traceId": "bc7b9b77021187d591ec4c5fe546c0ed",
              "spanId": "d342ee8a0654b9e0",
              "parentSpanId": "b3135c73252b1cfa",
              "name": "gateway.request",
              "kind": 3,
              "startTimeUnixNano": "1791061319869000000",
              "endTimeUnixNano": "1791061322796203541",
              "attributes": [
                {
                  "key": "litellm.gateway.attempt",
                  "value": {
                    "boolValue": true
                  }
                },
                {
                  "key": "http.request.method",
                  "value": {
                    "stringValue": "POST"
                  }
                },
                {
                  "key": "url.full",
                  "value": {
                    "stringValue": "http://localhost:4002/v1/chat/completions"
                  }
                },
                {
                  "key": "server.address",
                  "value": {
                    "stringValue": "localhost"
                  }
                },
                {
                  "key": "http.response.status_code",
                  "value": {
                    "intValue": "200"
                  }
                },
                {
                  "key": "litellm.call_id",
                  "value": {
                    "stringValue": "ef052c46-6645-4f8c-80c8-33aecd9150fa"
                  }
                }
              ],
              "status": {},
              "flags": 257
            }
          ]
        },
        {
          "scope": {
            "name": "gen_ai"
          },
          "spans": [
            {
              "traceId": "bc7b9b77021187d591ec4c5fe546c0ed",
              "spanId": "b3135c73252b1cfa",
              "parentSpanId": "61dd542aeb30b8df",
              "name": "chat openai/gpt-6-luna",
              "kind": 3,
              "startTimeUnixNano": "1791061319867000000",
              "endTimeUnixNano": "1791061322798078875",
              "attributes": [
                {
                  "key": "gen_ai.operation.name",
                  "value": {
                    "stringValue": "chat"
                  }
                },
                {
                  "key": "gen_ai.provider.name",
                  "value": {
                    "stringValue": "litellm.chat"
                  }
                },
                {
                  "key": "gen_ai.request.model",
                  "value": {
                    "stringValue": "openai/gpt-6-luna"
                  }
                },
                {
                  "key": "gen_ai.input.messages",
                  "value": {
                    "stringValue": "[{\"role\":\"user\",\"parts\":[{\"type\":\"text\",\"content\":\"What is an agent trace?\"}]}]"
                  }
                },
                {
                  "key": "gen_ai.client.operation.duration",
                  "value": {
                    "doubleValue": 2.9307650409999995
                  }
                },
                {
                  "key": "gen_ai.response.finish_reasons",
                  "value": {
                    "arrayValue": {
                      "values": [
                        {
                          "stringValue": "stop"
                        }
                      ]
                    }
                  }
                },
                {
                  "key": "gen_ai.response.id",
                  "value": {
                    "stringValue": "chatcmpl-EV19k5k5Q9nTw1BToyv1fxqm72Leg"
                  }
                },
                {
                  "key": "gen_ai.response.model",
                  "value": {
                    "stringValue": "openai/gpt-6-luna"
                  }
                },
                {
                  "key": "gen_ai.usage.input_tokens",
                  "value": {
                    "intValue": "12"
                  }
                },
                {
                  "key": "gen_ai.usage.output_tokens",
                  "value": {
                    "intValue": "186"
                  }
                },
                {
                  "key": "gen_ai.usage.cache_read.input_tokens",
                  "value": {
                    "intValue": "0"
                  }
                },
                {
                  "key": "gen_ai.output.messages",
                  "value": {
                    "stringValue": "[{\"role\":\"assistant\",\"parts\":[{\"type\":\"text\",\"content\":\"An **agent trace** is a record of an AI agent\u2019s steps while completing a task. It may include the inputs it received, actions it took (such as tool calls), results returned by tools, and its final response.\\n\\nTraces help developers debug, evaluate, or audit an agent\u2019s behavior. The exact contents vary, and a trace doesn\u2019t necessarily include the agent\u2019s private internal reasoning.\"}],\"finish_reason\":\"stop\"}]"
                  }
                }
              ],
              "status": {},
              "flags": 257
            },
            {
              "traceId": "bc7b9b77021187d591ec4c5fe546c0ed",
              "spanId": "61dd542aeb30b8df",
              "parentSpanId": "53366a8154e97816",
              "name": "step 1",
              "kind": 1,
              "startTimeUnixNano": "1791061319867000000",
              "endTimeUnixNano": "1791061322798540375",
              "attributes": [
                {
                  "key": "gen_ai.operation.name",
                  "value": {
                    "stringValue": "agent_step"
                  }
                }
              ],
              "status": {},
              "flags": 257
            },
            {
              "traceId": "bc7b9b77021187d591ec4c5fe546c0ed",
              "spanId": "53366a8154e97816",
              "name": "invoke_agent research_agent",
              "kind": 1,
              "startTimeUnixNano": "1791061319864000000",
              "endTimeUnixNano": "1791061322798418250",
              "attributes": [
                {
                  "key": "gen_ai.operation.name",
                  "value": {
                    "stringValue": "invoke_agent"
                  }
                },
                {
                  "key": "gen_ai.provider.name",
                  "value": {
                    "stringValue": "litellm.chat"
                  }
                },
                {
                  "key": "gen_ai.request.model",
                  "value": {
                    "stringValue": "openai/gpt-6-luna"
                  }
                },
                {
                  "key": "gen_ai.agent.name",
                  "value": {
                    "stringValue": "research_agent"
                  }
                },
                {
                  "key": "gen_ai.input.messages",
                  "value": {
                    "stringValue": "[{\"role\":\"user\",\"parts\":[{\"type\":\"text\",\"content\":\"What is an agent trace?\"}]}]"
                  }
                },
                {
                  "key": "gen_ai.response.finish_reasons",
                  "value": {
                    "arrayValue": {
                      "values": [
                        {
                          "stringValue": "stop"
                        }
                      ]
                    }
                  }
                },
                {
                  "key": "gen_ai.usage.input_tokens",
                  "value": {
                    "intValue": "12"
                  }
                },
                {
                  "key": "gen_ai.usage.output_tokens",
                  "value": {
                    "intValue": "186"
                  }
                },
                {
                  "key": "gen_ai.usage.cache_read.input_tokens",
                  "value": {
                    "intValue": "0"
                  }
                },
                {
                  "key": "gen_ai.output.messages",
                  "value": {
                    "stringValue": "[{\"role\":\"assistant\",\"parts\":[{\"type\":\"text\",\"content\":\"An **agent trace** is a record of an AI agent\u2019s steps while completing a task. It may include the inputs it received, actions it took (such as tool calls), results returned by tools, and its final response.\\n\\nTraces help developers debug, evaluate, or audit an agent\u2019s behavior. The exact contents vary, and a trace doesn\u2019t necessarily include the agent\u2019s private internal reasoning.\"}],\"finish_reason\":\"stop\"}]"
                  }
                }
              ],
              "status": {},
              "flags": 257
            }
          ]
        }
      ]
    }
  ]
}