symfonic.observability.otel.attributes¶
attributes ¶
Centralized OTEL attribute key constants.
GenAI semconv keys: https://opentelemetry.io/docs/specs/semconv/gen-ai/
Symfonic-specific keys: symfonic.<domain>.<sub>
This module is intentionally free of opentelemetry imports so other
internal tooling can reference the key strings without pulling OTEL.
truncate_for_attribute ¶
Truncate value to ATTRIBUTE_VALUE_MAX_BYTES UTF-8 bytes.
Returns the value verbatim if it already fits; otherwise truncates at
a UTF-8 boundary and appends TRUNCATION_MARKER so consumers can
tell at a glance that the field is incomplete.