exploring-llm-clusters
하는 일
이 스킬은 PostHog가 AI 트래픽에서 만든 클러스터를 살펴봅니다. 클러스터는 비슷한 트레이스, 생성 결과, 평가를 묶은 것입니다. AI가 처리하는 요청의 주요 유형을 이해하려는 팀을 위한 것입니다.
사용하는 경우
- ✓AI가 가장 자주 처리하는 요청 종류를 보고 싶을 때.
- ✓두 묶음의 AI 트래픽 동작을 비교하고 싶을 때.
- ✓한 묶음의 대화에 대한 비용이나 속도를 보고 싶을 때.
스킬 링크
https://github.com/PostHog/posthog/blob/master/products/ai_observability/skills/exploring-llm-clusters/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“우리 AI가 처리하는 주요 요청 유형은 무엇이고, 어떤 묶음이 비용이 가장 많이 드나요?”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
저장된 클러스터링 결과를 읽는데, 이는 각 트레이스를 얼마나 비슷한지에 따라 묶은 것입니다. 각 묶음의 비용과 속도를 계산합니다. 그다음 묶음 안의 개별 대화를 열어 예시를 보여 줄 수 있습니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
Exploring LLM clusters
Use this skill when investigating AI observability clusters — understanding what patterns exist in your AI/LLM traffic, comparing cluster behavior, and drilling into individual clusters.
Tools
| Tool | Purpose |
|---|---|
posthog:llma-clustering-job-list |
List clustering job configurations for the team |
posthog:llma-clustering-job-get |
Get a specific clustering job by ID |
posthog:execute-sql |
Query cluster run events and compute metrics |
posthog:query-llm-traces-list |
Find traces belonging to a cluster |
posthog:query-llm-trace |
Inspect a specific trace in detail |
How clustering works
PostHog clusters LLM traces, individual generations, or evaluation events by embedding similarity.
A Temporal workflow runs periodically or on-demand, producing cluster events stored as
$ai_trace_clusters (trace-level), $ai_generation_clusters (generation-level), or
$ai_evaluation_clusters (evaluation-level).
Each cluster event contains:
$ai_clustering_run_id— unique run identifier (format:<team_id>_<level>_<YYYYMMDD>_<HHMMSS>[_<job_id>])$ai_clustering_level—"trace","generation", or"evaluation"$ai_window_start/$ai_window_end— time window of the data that was analyzed$ai_total_items_analyzed— number of traces, generations, or evaluations processed$ai_clusters— JSON array of cluster objects$ai_clustering_params— algorithm parameters used
The analyzed window closes when a run starts, and the cluster event lands once the run finishes.
So the cluster event's own timestamp is always after $ai_window_end, by anything from seconds to hours.
Use the window only to bound the traces, generations, and evaluations that were analyzed.
To find the cluster event itself, filter on $ai_clustering_run_id with a plain recent-time bound.
Cluster object shape (inside $ai_clusters)
{
"cluster_id": 0,
"size": 42,
"title": "User authentication flows",
"description": "Traces involving login, signup, and token refresh operations",
"traces": {
"<trace_or_generation_id>": {
"distance_to_centroid": 0.123,
"rank": 0,
"x": -2.34,
"y": 1.56,
"timestamp": "2026-03-28T10:00:00Z",
"trace_id": "abc-123",
"generation_id": "gen-456"
}
},
"centroid_x": -2.1,
"centroid_y": 1.4
}
cluster_id: -1is the noise/outlier cluster (items that didn't fit any cluster)- Items in
tracesare keyed by trace ID (trace-level), generation event UUID (generation-level), or evaluation event UUID (evaluation-level) rankorders items by proximity to centroid (0 = closest)x,yare 2D coordinates for visualization (UMAP/PCA/t-SNE reduced)
Clustering jobs
Each team can have up to 10 clustering jobs. A job defines:
- name — human-readable label
- analysis_level —
"trace","generation", or"evaluation" - event_filters — property filters scoping which items are included
- enabled — whether the job runs on schedule
Default jobs named "Default - traces", "Default - generations", and "Default - evaluations" are auto-created
and disabled when a custom job is created for the same level.
Workflow: explore clusters
Step 1 — List recent clustering runs
posthog:execute-sql
SELECT
toString(properties.$ai_clustering_run_id) AS run_id,
toString(properties.$ai_clustering_level) AS level,
toString(properties.$ai_clustering_job_id) AS job_id,
toString(properties.$ai_clustering_job_name) AS job_name,
toString(properties.$ai_window_start) AS window_start,
toString(properties.$ai_window_end) AS window_end,
toFloat64OrNull(toString(properties.$ai_total_items_analyzed)) AS total_items,
timestamp
FROM events
WHERE event IN ('$ai_trace_clusters', '$ai_generation_clusters', '$ai_evaluation_clusters')
AND timestamp >= now() - INTERVAL 14 DAY
ORDER BY timestamp DESC
LIMIT 10
Step 2 — Get clusters from a specific run
posthog:execute-sql
SELECT
toString(properties.$ai_clustering_run_id) AS run_id,
toString(properties.$ai_clustering_level) AS level,
toString(properties.$ai_clustering_job_id) AS job_id,
toString(properties.$ai_clustering_job_name) AS job_name,
자주 묻는 질문
PostHog는 트래픽을 어떻게 묶나요?
트레이스나 생성 결과의 내용을 비교해 비슷한 것을 찾고, 일정에 따라 또는 시작할 때 묶음 작업을 실행합니다.
한 묶음 안을 볼 수 있나요?
네. 클러스터에 속한 트레이스를 찾아 그중 하나의 세부 사항을 보여 줄 수 있습니다.
묶음이 무엇을 의미하는지는 누가 정하나요?
묶음은 자동으로 만들어지므로, 스킬은 결론을 내리기 전에 묶음을 읽고 예시를 확인하도록 돕습니다.
상세 정보
작성자의 원본 설명
Investigate AI observability clusters — understand usage patterns in AI/LLM traffic, compare cluster behavior, compute cost/latency metrics, and drill into individual traces within clusters.
repo: PostHog/posthog
인기도
- GitHub 스타
- 41k
- 순위
- #6830
- 라이선스
- —
- 업데이트
- 2026. 11. 2.
댓글
- …
이 저장소의 다른 스킬
depot-ci
41k에이전트가 GitHub Actions 대안인 Depot CI 워크플로를 설정하고 실행하도록 돕습니다. 기존 워크플로 이전과 실행 로그 읽기를 포함합니다.
depot-container-builds
41k에이전트가 Depot 원격 빌더에서 Docker 이미지를 빌드하도록 돕습니다. 다중 플랫폼 이미지, 레지스트리 푸시, 빌드 실패 수정을 포함합니다.
depot-github-runners
41k에이전트가 GitHub Actions 작업을 Depot 관리형 러너로 옮기고, 러너 크기와 라벨을 고르도록 돕습니다.
editing-agents-md
41k에이전트가 규칙을 AGENTS.md나 CLAUDE.md 중 어디에 둘지 정하고, 파일을 키우지 않으면서 잘 지켜지도록 쓰게 돕습니다.
비슷한 스킬
gitcrawl
394k에이전트가 저장된 GitHub 이슈와 풀 리퀘스트 보관본을 검색하고, 중복 항목을 묶고, GitHub에서 현재 상태를 확인하도록 돕습니다.
slacrawl
394k에이전트가 로컬 Slack 보관본에서 메시지를 검색하고 개수를 세며, 보관본이 얼마나 최신인지 확인하고 필요할 때 새로 고치도록 돕습니다.
goplaces
394k에이전트가 Google Places로 장소를 검색하고, 세부 정보와 리뷰를 가져오고, 장소 이름을 확인하며, 스크립트용 JSON을 출력하도록 돕습니다.