
Built In Metrics
This walks you through the four-tier ladder LaunchDarkly recommends for instrumenting AI provider calls with metrics tracking: managed runner, provider package with trackMetricsOf, custom extractor, or raw manual calls. The core insight is to default to the highest tier that fits your call shape, because going straight to manual tracker calls costs you drift and missed metrics. It audits your existing code to determine whether you have a chat loop, one-shot completion, or agent step, checks which provider package exists for your framework and language, then points you to reference implementations. Includes a migration path if you're still on the pre-0.20 SDK surface with aiclient.config instead of completion_config.
- skills.sh installs
- 1.3K
- GitHub stars
- 19
- last updated
- Jul 14, 2026
Install
$ npx -y skills add launchdarkly/agent-skills --skill built-in-metrics --agent claude-codeInstalls into .claude/skills of the current project.
Files
Agent Metrics Instrumentation
You're using a skill that wires LaunchDarkly agent metrics around an existing provider call. Your job is to audit what's already there, pick the right tier from the ladder below, and implement it with the least ceremony that still captures the metrics the Monitoring tab needs (duration, input/output tokens, success/error, plus TTFT when streaming).
The single most important thing to get right: default to the highest tier that fits the shape of the call. Going lower ("just write the manual tracker calls") looks flexible but costs you drift, missed metrics, and legacy patterns the SDKs have moved past.
The four-tier ladder
This is the order the official SDK READMEs (Python core, Node core, and every provider package) recommend. Walk from the top and stop at the first tier that fits:
Sponsors
Details
- Repository
- github.com/launchdarkly/agent-skills
- Category
- AI & Agent Building
- First seen
- Jul 14, 2026
More from launchdarkly/agent-skills
All 41- Configs Create1.3K
- Configs Targeting1.3K
- Configs Update1.3K
- Configs Variations1.3K
- Custom Metrics1.3K
- Migrate1.3K
- Online Evals1.3K
- Projects1.3K
- Snippets1.3K
- Tools1.3K
- Launchdarkly Flag Command1K
- Onboarding3.3K
- Launchdarkly Flag Cleanup2.5K
- Launchdarkly Flag Create2.5K
- Launchdarkly Flag Discovery2.5K
- Launchdarkly Flag Targeting2.5K
- Aiconfig Create2.3K
- Aiconfig Projects2.3K
- Aiconfig Tools2.3K
- Aiconfig Update2.3K
- Aiconfig Variations2.3K
- Launchdarkly Metric Choose2.3K
- Launchdarkly Metric Create2.3K
- Launchdarkly Metric Instrument2.3K