omnibus-instrument-llm-analytics

Official

Instrument LLM analytics for PostHog.

AuthorPostHog
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Add PostHog LLM analytics to trace AI model usage. Use after implementing LLM features or reviewing PRs to ensure all generations are captured with token counts, latency, and costs. Also handles initial PostHog SDK setup if not yet installed.

Core Features & Use Cases

  • Instrument LLM calls to produce $ai_generation events and traces, capturing model, input, tokens, latency, and costs.
  • Supports multiple providers and frameworks; integrates with existing LLM stacks for observability in dashboards.
  • Use cases include PR reviews, feature development, and monitoring of AI-assisted workflows.

Quick Start

Install the PostHog SDK and wrap your LLM client with the provided analytics wrapper to start capturing LLM generations.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: omnibus-instrument-llm-analytics
Download link: https://github.com/PostHog/skills/archive/main.zip#omnibus-instrument-llm-analytics

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.