Clusters

Clusters group similar traces, generations, or evaluation results so you can find recurring topics and problems.

Why use clusters?

  • Discover usage patterns – See what users are actually asking your LLM to do.
  • Find problem areas – Identify clusters with high error rates, costs, or latency.
  • Monitor trends – Daily runs show how usage patterns evolve over time.
  • Surface outliers – Items that don't fit any cluster are flagged as unusual behavior.

Enable clustering

Before you start, capture LLM events and enable AI data processing for your organization, as required for trace summarization.

Go to AI Observability > Clusters and enable clustering for your project. PostHog creates default clustering jobs. Each job defines which data to group, such as traces from a specific model or results from one evaluator. Open Manage jobs to customize them.

Jobs run daily, so results don't appear immediately. Keep sending events after enabling clustering. PostHog doesn't automatically process your older traces when you enable it.

How clusters work

  1. Each enabled job selects recent data that matches its analysis level and filters.
  2. Similar items are grouped together based on their content.
  3. AI generates a title and description for each cluster.
  4. Metrics like average cost, latency, token usage, and error rate are computed per cluster.

Minimum data per job

Analysis levelMinimumAnalysis window
Traces10 tracesLast 7 days
Generations10 generations from different tracesLast 7 days
Evaluations10 evaluation resultsLast 3 days

These minimums apply after filtering. Evaluation jobs exclude numeric and categorical scores. Enough data alone doesn't guarantee a cluster: the items must also be similar enough to form groups.

Before clusters appear

If no clusters appear, open Manage jobs and check that a job is enabled and its filters match enough data to meet the minimum above.

You can turn clustering off from the No clusters yet page or the Jobs panel. This stops future runs and keeps existing results available.

Viewing clusters

Navigate to AI Observability > Clusters to see the overview.

Managing clustering jobs

Click Jobs in the Clusters view, or Manage jobs before your first clusters appear.

Each job has the following settings:

  • Name – A label to identify the job (e.g. "Production GPT-4o")
  • Analysis level – Whether to cluster traces (entire conversations), generations (individual LLM calls), or evaluation results
  • Event filters – Property filters that select the data to include (leave empty to include all eligible data)
  • Enabled – Toggle a job on or off without deleting it

You can create up to 10 clustering jobs per project. The run selector includes the job name so you can identify which job produced each run.

Analysis levels

Choose one analysis level for each job:

  • Traces – Cluster entire conversations, giving you a high-level view of what users are doing.
  • Generations – Cluster individual LLM calls, useful for analyzing specific model interactions.
  • Evaluations – Group related evaluation results to find recurring patterns in the verdicts and reasoning.

The analysis level is configured per job in the jobs panel. You can also use the level toggle at the top of the Clusters page to filter which runs are displayed.

Scatter plot

Click Map to show the interactive scatter plot beside the cluster table. Hover over a cluster row to highlight its dots.

Nearby dots represent items with similar content. The axes don't represent metrics such as cost or latency.

FeatureDescription
DotsEach dot represents one trace, generation, or evaluation result, color-coded by cluster
CentroidsLarger dots marking the center of each cluster
Click dotOpen the item in a drawer without leaving the cluster view
Click centroidNavigate to the cluster detail page
Drag to zoomZoom into a region of the plot
Double-clickReset zoom

Cluster table

The table shows each cluster with:

  • AI-generated title and description summarizing the cluster's content
  • Size – Item count and percentage of total
  • Metrics – Average cost, average latency, and error rate (pass rate for evaluation clusters)

Expand a row to preview its items. Click an item to inspect it in a drawer, or click the cluster title for the detail page.

Items that don't fit any cluster appear under Outliers.

Cluster detail page

Click a cluster title or centroid to open the detail page. Here you'll find:

  • Cluster title, description, and item count with the date range
  • Focused scatter plot showing only items in this cluster
  • Paginated item list with summaries

Click an item to inspect it in a drawer and move between items in the same cluster.

Clusters in trace view

When viewing an individual trace, the Clusters tab shows which cluster(s) that trace belongs to. This is useful for understanding what category a specific conversation falls into.

Still have questions?

Was this page useful?