From: aidotengineer

Open Telemetry is an open-source project maintained by the CNCF, standardizing cloud observability by defining how to handle logging, metrics, and tracing [00:28:00]. Beyond being a protocol, Open Telemetry is an ecosystem that includes Software Development Kits (SDKs) and Instrumentations [03:23:59].

SDKs (Software Development Kits)

SDKs provide the means to manually send out logs, metrics, and traces from an application [03:32:00]. This requires developers to explicitly add code to send the desired data [04:00:00]. Open Telemetry currently supports SDKs in 11 different languages, including Python, TypeScript, Go, and C++ [03:37:37].

Instrumentations

Instrumentations offer an automatic way to obtain observability data [03:55:00]. Unlike SDKs, they do not require manual code changes to send data [04:10:00].

How Instrumentations Work

Instrumentations automatically provide visibility into specific parts of an application [04:30:00]. For example, an instrumentation for a database like PostgreSQL can automatically provide logs, metrics, and traces related to its operations [04:40:00].

The mechanism behind instrumentations involves “monkey patching” the client library used within an application [04:54:00]. This allows the instrumentation to emit relevant data to the observability platform [04:59:00]. All of this processing occurs on the application side [05:07:00]. Instrumentations are designed with high engineering standards, resulting in an almost negligible latency impact while providing a comprehensive view of system activities [05:13:00].

Instrumentations in OpenLLMetry

OpenLLMetry extends Open Telemetry by building instrumentations specifically for Gen AI frameworks, foundation models, and vector databases [06:20:00]. The community has contributed to over 40 different providers, including:

  • Foundation Models: OpenAI, Anthropic, Cohere, Gemini, Bedrock [07:16:00]
  • Vector Databases: Pinecone, Chroma [07:23:00]
  • Frameworks: LangChain, LlamaIndex, CrewAI, Haystack [07:28:00]

These instrumentations automatically emit logs, metrics, and traces, which can then be connected to any preferred observability platform, offering out-of-the-box observability [07:36:00].

Example: Pinecone Instrumentation

An instrumentation for Pinecone would provide visibility into:

  • Queries sent to Pinecone [08:01:00]
  • Indexing processes within Pinecone [08:07:00]
  • Details of vectors returned from Pinecone, such as data, distances, scores, and latencies [08:10:00]

All this data is available in the standard Open Telemetry format [08:23:00].

Using Open Telemetry’s standard protocol means users are not tied to a specific observability platform and can switch easily via configuration changes, as all supporting platforms adhere to the same format [08:41:00].