feat(telemetry): use zero-width space to avoid clutter

# What does this PR do?


## Test Plan
This commit is contained in:
Eric Huang 2025-03-21 11:18:53 -07:00
parent a316166e63
commit 73c52a751e
32 changed files with 34 additions and 33 deletions

View file

@ -29,7 +29,8 @@ class TelemetryConfig(BaseModel):
description="The OpenTelemetry collector endpoint URL for metrics",
)
service_name: str = Field(
default="llama-stack",
# service name is always the same, use zero-width space to avoid clutter
default="",
description="The service name to use for telemetry",
)
sinks: List[TelemetrySink] = Field(
@ -51,7 +52,7 @@ class TelemetryConfig(BaseModel):
@classmethod
def sample_run_config(cls, __distro_dir__: str, db_name: str = "trace_store.db") -> Dict[str, Any]:
return {
"service_name": "${env.OTEL_SERVICE_NAME:llama-stack}",
"service_name": "${env.OTEL_SERVICE_NAME:}",
"sinks": "${env.TELEMETRY_SINKS:console,sqlite}",
"sqlite_db_path": "${env.SQLITE_DB_PATH:" + __distro_dir__ + "/" + db_name + "}",
}