root-cause-analysis
Installation
SKILL.md
Root Cause Analysis with Kopai
Debug production issues from telemetry (traces, logs, metrics). Kopai's analytical power — error rate, throughput, latency, group-by, time-series bucketing — lives in the SDK query API, which the CLI does not expose. So lead every investigation by writing a short TypeScript script; the CLI stays as a quick-lookup fallback.
Prerequisites
- Services are sending OpenTelemetry data to Kopai (see the
otel-instrumentationskill). @kopai/sdkis installed in the project:npm i @kopai/sdk(it ships the query API and the.kopaircreader).
Code mode (recommended)
Connect — clientFromConfig() reads .kopairc exactly like the CLI: