Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Cs Metric Audit

ASecurity

Audit the metrics published on a CS-health dashboard against the mart layer to identify inconsistencies, stale definitions, missing signals, and metrics that bypass the mart. Reach for this skill before a CS analytics rebuild, during a QBR preparation review, or when a CS leader reports that the numbers don't match what they expect.

7 stars
0 votes
0 copies
0 views
Added 9/23/2026
ai-agentsrustsqlexpressapi

Works with

api

Security Analysis

A100/100

Scanned 9/23/2026

$npx -y skills add mcorbett51090/RavenClaude --skill cs-metric-audit --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Cs Metric Audit?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Cs Metric Audit
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/mcorbett51090-cs-metric-audit/badge)](https://www.skillsdirectory.com/skills/mcorbett51090-cs-metric-audit)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: cs-metric-audit
description: "Audit the metrics published on a CS-health dashboard against the mart layer to identify inconsistencies, stale definitions, missing signals, and metrics that bypass the mart. Reach for this skill before a CS analytics rebuild, during a QBR preparation review, or when a CS leader reports that the numbers don't match what they expect."
---

# Skill: CS Metric Audit

A CS dashboard accumulates drift: metrics are added directly in the BI tool, signal definitions diverge from what was agreed, NULLs are silently converted to zeros, and trend columns get recomputed at query time instead of materialized. This skill surfaces the drift before it undermines CS team trust or produces a wrong renewal decision.

## When to reach for this skill

- A CS leader reports that numbers on the dashboard "don't look right."
- A rebuild or refresh of the CS health mart is planned.
- A QBR is upcoming and the team wants to verify the numbers are reliable before presenting to accounts.
- A new data source was added and the team needs to confirm it integrated cleanly.

## Step 1 — Inventory every metric on the CS dashboard

List every metric visible on the CS surface (the sort columns, the tier labels, the sub-indicators in the explainability panel). For each metric, record:

| Metric | Where computed | Source signal | Window | NULL handling | Last verified |
|---|---|---|---|---|---|
| [metric name] | [mart / BI-tool SQL / live API] | [source table] | [window] | [NULL → 0? or explicit NULL?] | [date] |

**Red flags to flag immediately:**
- Computed in the BI tool (not the mart) — violates the mart-is-the-single-source rule
- "Live API at query time" — violates the mart-as-single-source rule and adds query latency
- NULL → 0 anywhere — violates the explicit-NULL rule

## Step 2 — Trace each metric to the mart definition

For every metric computed in the mart, find the dbt model (or equivalent) and confirm:
1. The model name and the mart column name match what is displayed on the dashboard
2. The window definition matches what the CS team was told (e.g., "30-day usage trend" is actually 30 days, not 28 or 35)
3. The grain is correct (account-level, not user-level accidentally aggregated)
4. The trend column is materialized, not a `CASE WHEN ... OVER (...)` computed at query time

## Step 3 — Validate the append-only health snapshot

Confirm `fct_account_health_snapshot`:
- Is append-only (no deletes, no upsert-in-place rows)
- Has one row per account per day for the complete history window
- The trend columns (`health_score_delta_7d`, `usage_slope_30d`) are materialized in the model, not derived at query time
- NULL signals are NULL, not zero

```sql
-- Quick check: does the table have rows for every day in the window?
SELECT snapshot_date, COUNT(*) AS account_count
FROM fct_account_health_snapshot
WHERE snapshot_date >= CURRENT_DATE - 90
GROUP BY 1
ORDER BY 1
-- Expected: a row for every date in the window with a stable account count
-- Red flag: missing dates (gap) or count drops that aren't explained by churn
```

## Step 4 — Audit tier rule expression

Find the tier rule expression (in the mart model, a dbt macro, or the tier-definition doc) and verify:
- The rule uses the threshold values documented in the tier-design decision record
- The NULL handling is explicit: a missing signal is treated as NULL (not zero or "OK")
- The drivers columns (`tier_driver_1`, `tier_driver_2`) are populated for every Red account
- The explainability contract is met: every Red has at least one named driver

## Step 5 — Identify identity-resolution anomalies

Check whether any metric is published off a name-match join rather than the resolved `bridge_account_xref` cross-reference. Name-only joins produce artificially inflated or deflated metrics when two accounts share a company name variation.

```sql
-- Check for unresolved accounts in key metrics
SELECT COUNT(*) AS unresolved
FROM fct_account_health_snapshot h
LEFT JOIN dim_account a ON h.account_id = a.account_id
WHERE a.account_id IS NULL
-- Expected: 0. Any non-zero value means metric rows that can't be attributed to a resolved account.
```

## Step 6 — Produce the audit report

```
Audit date: [YYYY-MM-DD]
Dashboard version / last refresh: [date]

Metric count: [total]
Passed: [N]
Flagged: [N]

Flags:
  [metric name]: [flag type] — [brief description] — recommended fix: [action]

Identity-resolution anomalies: [N unresolved]
NULL handling violations: [N fields where NULL → 0]
Mart-bypass violations: [N metrics computed in BI tool or via live API]
Append-only snapshot: [PASS / FAIL — detail if fail]

Handoff to data-platform: [any mart fixes required]
Recommended re-audit date: [YYYY-MM-DD — after fixes are deployed]
```

## Pitfalls

- Auditing only the dashboard layer without tracing to the mart model — a clean dashboard that sits on wrong mart logic passes the surface check and fails in production.
- Treating a BI-tool computed metric as "fine" because it returns the same number as the mart — it will diverge eventually, and the divergence will be invisible.
- Skipping the identity-resolution check when the source systems use different account name formats — name-match joins are almost always subtly wrong.

## See also

- [`../../knowledge/cs-health-metrics-and-churn-indicators.md`](../../knowledge/cs-health-metrics-and-churn-indicators.md) — canonical signal definitions to audit against
- [`../../agents/cs-analytics-architect.md`](../../agents/cs-analytics-architect.md) — the agent that designs and owns the mart layer
- [`../../templates/cs-health-data-model.md`](../../templates/cs-health-data-model.md) — the reference schema to cross-reference

Attribution

mcorbett51090mcorbett51090
View sourceSee grades on GitHubMore from mcorbett51090 →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Caveman

Terse caveman voice: answer first, fluff gone, every technical fact kept. Use for /caveman, "caveman mode", "talk like caveman", "be brief", "less tokens". Stays on until "stop caveman" or "normal mode".

1100021 votes

Hyperplan

Adversarial multi-agent planning skill. Self-orchestrates 5 hostile category members (unspecified-low, unspecified-high, deep, ultrabrain, artistry) via team-mode for ruthless cross-critique debate, distills only the defensible insights, then MANDATORILY hands the distilled insight bundle to the `plan` agent for executable plan formalization. Use when planning needs maximum rigor and surfacing of weak assumptions, blind spots, and over-engineering. Triggers: 'hyperplan', 'hpp', '/hyperplan', ...

698461 votes

Writing Skills

Create and manage Claude Code skills in HASH repository following Anthropic best practices. Use when creating new skills, modifying skill-rules.json, understanding trigger patterns, working with hooks, debugging skill activation, or implementing progressive disclosure. Covers skill structure, YAML frontmatter, trigger types (keywords, intent patterns), UserPromptSubmit hook, and the 500-line rule. Includes validation and debugging with SKILL_DEBUG. Examples include rust-error-stack, cargo-dep...

3931 votes

Mcp Code Execution

Routes multi-tool workflows through MCP servers for large datasets and pipelines. Use when Bash tool overhead is limiting throughput on data-heavy tasks.

3421 votes

catchup

Recovers the conversation and failed tool calls of a previous Codex, Amp, Claude Code, Antigravity, Cline, Copilot CLI, Cursor, DeepSeek Harness, Grok Build, Kimi, OpenCode, Pi Agent, or ZCode session. Use when the user says "catch up", "what did the last session do", "get me up to speed", "I switched agents", asks to recover/summarize a previous session before continuing, or asks to diagnose or report a catchup failure. Do NOT use for the current conversation, git history, or any non-agent log.

741 votes
View all in ai-agents →