Pipeline Hygiene Score
Pipeline Hygiene Score: Quality assessment of pipeline data and process adherence across open opportunities.
Formula
Hygiene Score = (Complete opps + Updated opps + Valid dates + Accurate stages) / 4 Computable definition
The canonical formula in the GASP formula grammar. The MCP server compiles it to SQL over the datasets listed below.
(count_distinct(field.opportunity_id where field.required_fields_complete = true) / count_distinct(field.opportunity_id) + count_distinct(field.opportunity_id where field.updated_within_sla = true) / count_distinct(field.opportunity_id) + count_distinct(field.opportunity_id where field.close_date_valid = true) / count_distinct(field.opportunity_id) + count_distinct(field.opportunity_id where field.stage_accurate = true) / count_distinct(field.opportunity_id)) / 4 Unit: percent (the formula yields an unscaled ratio)
Notes: Population is open opportunities.
Data requirements
Grain: Weekly snapshot · Frequency: Weekly · Aggregation: snapshot (week) · Staged: no · Main source: CRM.
| Field | Dataset | Type |
|---|---|---|
close_date_valid | opportunity | boolean |
opportunity_id | opportunity | string |
required_fields_complete | opportunity | boolean |
snapshot_date | opportunity | date |
stage_accurate | opportunity | boolean |
updated_within_sla | opportunity | boolean |
Example SQL (Postgres)
SELECT (CAST(((((CAST((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end AND required_fields_complete = TRUE) AS DOUBLE PRECISION) / NULLIF((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end), 0)) + (CAST((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end AND updated_within_sla = TRUE) AS DOUBLE PRECISION) / NULLIF((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end), 0))) + (CAST((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end AND close_date_valid = TRUE) AS DOUBLE PRECISION) / NULLIF((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end), 0))) + (CAST((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end AND stage_accurate = TRUE) AS DOUBLE PRECISION) / NULLIF((SELECT COUNT(DISTINCT opportunity_id) FROM opportunity WHERE snapshot_date = :period_end), 0))) AS DOUBLE PRECISION) / 4) AS pipeline_hygiene_score From an agent: with the GASP MCP server, call
lookup_metric({ "name": "Pipeline Hygiene Score" }) or generate_query({ "metric": "Pipeline Hygiene Score", "adapter": "<your adapter JSON>" }).
What It Tells You
How far you can trust the pipeline data your forecast is built on.