[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-posthog-authoring-data-quality-checks":3,"mdc--qr7tqw-key":49,"related-repo-posthog-authoring-data-quality-checks":787,"related-org-posthog-authoring-data-quality-checks":880},{"slug":4,"name":4,"fn":5,"description":6,"org":7,"tags":11,"stars":24,"repoUrl":25,"updatedAt":26,"license":27,"forks":28,"topics":29,"repo":44,"sourceUrl":47,"mdContent":48},"authoring-data-quality-checks","author data quality checks for warehouse tables","Adds and runs data quality checks (dbt-test style assertions) on a project's warehouse tables and saved-query views: not-null, uniqueness, accepted values, referential integrity, row-count bounds, freshness, and custom HogQL. Use when asked to test a model, validate a view, check for nulls or duplicates, add data quality checks, find out why a number looks wrong, or judge whether a warehouse table is trustworthy before using it in an analysis. To describe what data *means* (metrics, certifications, joins), see setting-up-data-catalog instead. Trigger terms: data quality, data test, dbt test, not null check, uniqueness check, freshness check, referential integrity, row count check, validate model, is this table trustworthy.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},"posthog","PostHog","https:\u002F\u002Fpexgzepcugksgbtrxkhf.supabase.co\u002Fstorage\u002Fv1\u002Fobject\u002Fpublic\u002Forg-logos\u002Fposthog.png",[12,16,19,21],{"name":13,"slug":14,"type":15},"Data Quality","data-quality","tag",{"name":17,"slug":18,"type":15},"Data Engineering","data-engineering",{"name":20,"slug":20,"type":15},"dbt",{"name":22,"slug":23,"type":15},"Analytics","analytics",35568,"https:\u002F\u002Fgithub.com\u002FPostHog\u002Fposthog","2026-08-19T03:59:25.329274",null,2977,[30,31,23,32,33,34,35,36,37,38,39,40,41,42,43],"ab-testing","ai-analytics","cdp","data-warehouse","experiments","feature-flags","javascript","product-analytics","python","react","session-replay","surveys","typescript","web-analytics",{"repoUrl":25,"stars":24,"forks":28,"topics":45,"description":46},[30,31,23,32,33,34,35,36,37,38,39,40,41,42,43],"🦔 PostHog is an all-in-one developer platform for building successful products. We offer product analytics, web analytics, session replay, error tracking, feature flags, experimentation, surveys, data warehouse, a CDP, and an AI product assistant to help debug your code, ship features faster, and keep all your usage and customer data in one stack.","https:\u002F\u002Fgithub.com\u002FPostHog\u002Fposthog\u002Ftree\u002FHEAD\u002Fproducts\u002Fdata_quality\u002Fskills\u002Fauthoring-data-quality-checks","---\nname: authoring-data-quality-checks\ndescription: >\n  Adds and runs data quality checks (dbt-test style assertions) on a project's warehouse tables and\n  saved-query views: not-null, uniqueness, accepted values, referential integrity, row-count bounds,\n  freshness, and custom HogQL. Use when asked to test a model, validate a view, check for nulls or\n  duplicates, add data quality checks, find out why a number looks wrong, or judge whether a warehouse\n  table is trustworthy before using it in an analysis. To describe what data *means* (metrics,\n  certifications, joins), see setting-up-data-catalog instead. Trigger terms: data quality, data test,\n  dbt test, not null check, uniqueness check, freshness check, referential integrity, row count check,\n  validate model, is this table trustworthy.\n---\n\n# Authoring data quality checks\n\nA check is one assertion about one warehouse table or view. It compiles to a count-only HogQL query\nand **passes when it finds zero failing rows** — the same semantics as `dbt test`. Failing rows are\nnever stored; only counts and the compiled query are, so to see the offending rows you re-run the\nstored query yourself.\n\n`row_count` is the exception. It passes when the observed count is within its configured min\u002Fmax\nbounds, so its `failed_row_count` comes back null and its stored query returns that single count,\nnot offending rows. Read the observed count to judge it rather than looking for matched rows.\n\nReads go through SQL (`system.information_schema.data_quality_*`); writes and runs go through the\ndata-quality MCP tools.\n\n## Before you write anything: look\n\nTwo queries save you from the two most common mistakes — duplicating a check, and checking a column\nthat doesn't exist.\n\n```sql\n-- What is already covered?\nSELECT name, subject_name, column_name, check_type, config, severity, last_status\nFROM system.information_schema.data_quality_checks\nWHERE subject_name = 'orders'\n\n-- What columns are there, and what do they mean?\nSELECT column_name, data_type, description\nFROM system.information_schema.columns\nWHERE table_name = 'orders'\n```\n\nRe-creating a byte-identical check is a harmless no-op — checks are keyed by a fingerprint of the\nsubject, type, column, and config, so an identical create upserts. A _near_-duplicate is not\nharmless: it doubles the noise for whoever reads the results. If an existing check's assertion is\nclose but wrong, create the corrected check and delete the old one — the assertion (type, column,\nconfig) is immutable and the subject is fixed by the URL, so an update that tries to change them is\nrejected. Update is only for metadata, severity, and ownership.\n\n## Choosing checks\n\nAim for a handful that would actually catch a real regression, not blanket coverage. A model with\ntwenty checks nobody reads is worse than three that fail meaningfully.\n\nReach for these first, in roughly this order:\n\n- **`not_null` on the columns downstream joins and filters depend on.** The single highest-value\n  check. A null join key silently drops rows.\n- **`unique` on whatever the model claims is its grain.** If `orders` is one row per order, say so.\n- **`relationships` on foreign keys.** Catches the join that quietly stopped matching after an\n  upstream change.\n- **`accepted_values` on status and category columns** whose downstream logic branches on them.\n- **`freshness` on the timestamp column of anything that syncs.** Catches a dead pipeline, which no\n  row-level check will.\n- **`row_count` bounds** when you know the plausible range. Good for catching a truncated sync.\n- **`custom_sql`** only when nothing above expresses the invariant — e.g. cross-column arithmetic\n  (`select 1 from orders where total != subtotal + tax`). Every row it returns counts as a failure.\n\nCall `posthog:data-quality-check-types` for each type's exact config schema rather than guessing.\n\nChecks live on the subject they audit: create them with `data-quality-check-create-on-view`\n(`saved_query_id` path parameter) or `data-quality-check-create-on-table` (`table_id`).\n\n## Severity and triggers\n\n**Severity** is a decision about consequences, not about confidence. Use `error` when the failure\nmeans downstream numbers should not be trusted — those failures mark the subject `failing` and\nnotify. Use `warn` for things worth surfacing that nobody would act on today. When unsure, `warn` is\nthe safer default: an `error` check that cries wolf gets everything ignored.\n\n**Triggers** — there is nothing to schedule. A check runs when its subject's data changes: a\nmaterialized view's checks run as part of its refresh (and, when the team turns the gate on, a\nrefresh whose error-severity checks fail is not published), a source table's checks run after each\ncompleted sync, and a plain view's checks run when its DAG runs. Checks on a view outside any DAG\nonly run on demand.\n\n## Verify what you wrote\n\nAuthor, run once, read the result. A check nobody has run is a guess.\n\n1. `posthog:data-quality-check-create-on-view` (or `-on-table`)\n2. `posthog:data-quality-check-run-on-view` (or `-on-table`) — returns a suite run\n3. Poll `system.information_schema.data_quality_check_runs` (or\n   `posthog:data-quality-check-results-on-view`\u002F`-on-table`) for the outcome\n\nA `failed` result on the first run is the interesting case: either you found real bad data, or the\nassertion is wrong. Take the `compiled_query` off the run, execute it with `posthog:execute-sql`, and\nlook at what it actually matched before reporting anything. That `compiled_query` comes from\n`posthog:data-quality-check-results-on-view`\u002F`-on-table`; the information_schema poll in step 3 does\nnot return it. An `errored` result is never a data\nproblem — the query could not run at all, usually a column name typo or a subject that no longer\nexists.\n\n## Judging a source before you use it\n\nWhen an analysis depends on a warehouse table or view, check its verdict first:\n\n```sql\nSELECT subject_name, health, checks_total, checks_failing, last_run_at\nFROM system.information_schema.data_quality_health\n```\n\n- `failing` — an error-severity check found bad data. Say so in your answer; don't quietly use it.\n- `erroring` — a check couldn't run. The data may be fine, but nobody is watching it.\n- `warn` — only warn-severity failures. Usable, worth a mention.\n- `healthy` — checks ran and passed.\n- `unknown` \u002F absent — no checks, or none have run. Absence of failures is not evidence of health.\n\nFor the history behind a verdict, `system.information_schema.data_quality_check_runs` carries recent\nexecutions with `observed_value` recorded on passes too, so you can see when a number started\ndrifting rather than just that it is wrong now.\n\n## Related\n\n- `setting-up-data-catalog` — what the data _means_: metrics, trust marks, relationships.\n- `querying-posthog-data` — the schema-discovery and HogQL rules these queries follow.\n",{"data":50,"body":51},{"name":4,"description":6},{"type":52,"children":53},"root",[54,62,85,104,117,124,129,224,237,243,248,253,383,396,433,439,487,497,503,508,576,633,639,644,667,723,743,749,781],{"type":55,"tag":56,"props":57,"children":58},"element","h1",{"id":4},[59],{"type":60,"value":61},"text","Authoring data quality checks",{"type":55,"tag":63,"props":64,"children":65},"p",{},[66,68,74,76,83],{"type":60,"value":67},"A check is one assertion about one warehouse table or view. It compiles to a count-only HogQL query\nand ",{"type":55,"tag":69,"props":70,"children":71},"strong",{},[72],{"type":60,"value":73},"passes when it finds zero failing rows",{"type":60,"value":75}," — the same semantics as ",{"type":55,"tag":77,"props":78,"children":80},"code",{"className":79},[],[81],{"type":60,"value":82},"dbt test",{"type":60,"value":84},". Failing rows are\nnever stored; only counts and the compiled query are, so to see the offending rows you re-run the\nstored query yourself.",{"type":55,"tag":63,"props":86,"children":87},{},[88,94,96,102],{"type":55,"tag":77,"props":89,"children":91},{"className":90},[],[92],{"type":60,"value":93},"row_count",{"type":60,"value":95}," is the exception. It passes when the observed count is within its configured min\u002Fmax\nbounds, so its ",{"type":55,"tag":77,"props":97,"children":99},{"className":98},[],[100],{"type":60,"value":101},"failed_row_count",{"type":60,"value":103}," comes back null and its stored query returns that single count,\nnot offending rows. Read the observed count to judge it rather than looking for matched rows.",{"type":55,"tag":63,"props":105,"children":106},{},[107,109,115],{"type":60,"value":108},"Reads go through SQL (",{"type":55,"tag":77,"props":110,"children":112},{"className":111},[],[113],{"type":60,"value":114},"system.information_schema.data_quality_*",{"type":60,"value":116},"); writes and runs go through the\ndata-quality MCP tools.",{"type":55,"tag":118,"props":119,"children":121},"h2",{"id":120},"before-you-write-anything-look",[122],{"type":60,"value":123},"Before you write anything: look",{"type":55,"tag":63,"props":125,"children":126},{},[127],{"type":60,"value":128},"Two queries save you from the two most common mistakes — duplicating a check, and checking a column\nthat doesn't exist.",{"type":55,"tag":130,"props":131,"children":136},"pre",{"className":132,"code":133,"language":134,"meta":135,"style":135},"language-sql shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","-- What is already covered?\nSELECT name, subject_name, column_name, check_type, config, severity, last_status\nFROM system.information_schema.data_quality_checks\nWHERE subject_name = 'orders'\n\n-- What columns are there, and what do they mean?\nSELECT column_name, data_type, description\nFROM system.information_schema.columns\nWHERE table_name = 'orders'\n","sql","",[137],{"type":55,"tag":77,"props":138,"children":139},{"__ignoreMap":135},[140,151,160,169,178,188,197,206,215],{"type":55,"tag":141,"props":142,"children":145},"span",{"class":143,"line":144},"line",1,[146],{"type":55,"tag":141,"props":147,"children":148},{},[149],{"type":60,"value":150},"-- What is already covered?\n",{"type":55,"tag":141,"props":152,"children":154},{"class":143,"line":153},2,[155],{"type":55,"tag":141,"props":156,"children":157},{},[158],{"type":60,"value":159},"SELECT name, subject_name, column_name, check_type, config, severity, last_status\n",{"type":55,"tag":141,"props":161,"children":163},{"class":143,"line":162},3,[164],{"type":55,"tag":141,"props":165,"children":166},{},[167],{"type":60,"value":168},"FROM system.information_schema.data_quality_checks\n",{"type":55,"tag":141,"props":170,"children":172},{"class":143,"line":171},4,[173],{"type":55,"tag":141,"props":174,"children":175},{},[176],{"type":60,"value":177},"WHERE subject_name = 'orders'\n",{"type":55,"tag":141,"props":179,"children":181},{"class":143,"line":180},5,[182],{"type":55,"tag":141,"props":183,"children":185},{"emptyLinePlaceholder":184},true,[186],{"type":60,"value":187},"\n",{"type":55,"tag":141,"props":189,"children":191},{"class":143,"line":190},6,[192],{"type":55,"tag":141,"props":193,"children":194},{},[195],{"type":60,"value":196},"-- What columns are there, and what do they mean?\n",{"type":55,"tag":141,"props":198,"children":200},{"class":143,"line":199},7,[201],{"type":55,"tag":141,"props":202,"children":203},{},[204],{"type":60,"value":205},"SELECT column_name, data_type, description\n",{"type":55,"tag":141,"props":207,"children":209},{"class":143,"line":208},8,[210],{"type":55,"tag":141,"props":211,"children":212},{},[213],{"type":60,"value":214},"FROM system.information_schema.columns\n",{"type":55,"tag":141,"props":216,"children":218},{"class":143,"line":217},9,[219],{"type":55,"tag":141,"props":220,"children":221},{},[222],{"type":60,"value":223},"WHERE table_name = 'orders'\n",{"type":55,"tag":63,"props":225,"children":226},{},[227,229,235],{"type":60,"value":228},"Re-creating a byte-identical check is a harmless no-op — checks are keyed by a fingerprint of the\nsubject, type, column, and config, so an identical create upserts. A ",{"type":55,"tag":230,"props":231,"children":232},"em",{},[233],{"type":60,"value":234},"near",{"type":60,"value":236},"-duplicate is not\nharmless: it doubles the noise for whoever reads the results. If an existing check's assertion is\nclose but wrong, create the corrected check and delete the old one — the assertion (type, column,\nconfig) is immutable and the subject is fixed by the URL, so an update that tries to change them is\nrejected. Update is only for metadata, severity, and ownership.",{"type":55,"tag":118,"props":238,"children":240},{"id":239},"choosing-checks",[241],{"type":60,"value":242},"Choosing checks",{"type":55,"tag":63,"props":244,"children":245},{},[246],{"type":60,"value":247},"Aim for a handful that would actually catch a real regression, not blanket coverage. A model with\ntwenty checks nobody reads is worse than three that fail meaningfully.",{"type":55,"tag":63,"props":249,"children":250},{},[251],{"type":60,"value":252},"Reach for these first, in roughly this order:",{"type":55,"tag":254,"props":255,"children":256},"ul",{},[257,274,298,314,330,346,361],{"type":55,"tag":258,"props":259,"children":260},"li",{},[261,272],{"type":55,"tag":69,"props":262,"children":263},{},[264,270],{"type":55,"tag":77,"props":265,"children":267},{"className":266},[],[268],{"type":60,"value":269},"not_null",{"type":60,"value":271}," on the columns downstream joins and filters depend on.",{"type":60,"value":273}," The single highest-value\ncheck. A null join key silently drops rows.",{"type":55,"tag":258,"props":275,"children":276},{},[277,288,290,296],{"type":55,"tag":69,"props":278,"children":279},{},[280,286],{"type":55,"tag":77,"props":281,"children":283},{"className":282},[],[284],{"type":60,"value":285},"unique",{"type":60,"value":287}," on whatever the model claims is its grain.",{"type":60,"value":289}," If ",{"type":55,"tag":77,"props":291,"children":293},{"className":292},[],[294],{"type":60,"value":295},"orders",{"type":60,"value":297}," is one row per order, say so.",{"type":55,"tag":258,"props":299,"children":300},{},[301,312],{"type":55,"tag":69,"props":302,"children":303},{},[304,310],{"type":55,"tag":77,"props":305,"children":307},{"className":306},[],[308],{"type":60,"value":309},"relationships",{"type":60,"value":311}," on foreign keys.",{"type":60,"value":313}," Catches the join that quietly stopped matching after an\nupstream change.",{"type":55,"tag":258,"props":315,"children":316},{},[317,328],{"type":55,"tag":69,"props":318,"children":319},{},[320,326],{"type":55,"tag":77,"props":321,"children":323},{"className":322},[],[324],{"type":60,"value":325},"accepted_values",{"type":60,"value":327}," on status and category columns",{"type":60,"value":329}," whose downstream logic branches on them.",{"type":55,"tag":258,"props":331,"children":332},{},[333,344],{"type":55,"tag":69,"props":334,"children":335},{},[336,342],{"type":55,"tag":77,"props":337,"children":339},{"className":338},[],[340],{"type":60,"value":341},"freshness",{"type":60,"value":343}," on the timestamp column of anything that syncs.",{"type":60,"value":345}," Catches a dead pipeline, which no\nrow-level check will.",{"type":55,"tag":258,"props":347,"children":348},{},[349,359],{"type":55,"tag":69,"props":350,"children":351},{},[352,357],{"type":55,"tag":77,"props":353,"children":355},{"className":354},[],[356],{"type":60,"value":93},{"type":60,"value":358}," bounds",{"type":60,"value":360}," when you know the plausible range. Good for catching a truncated sync.",{"type":55,"tag":258,"props":362,"children":363},{},[364,373,375,381],{"type":55,"tag":69,"props":365,"children":366},{},[367],{"type":55,"tag":77,"props":368,"children":370},{"className":369},[],[371],{"type":60,"value":372},"custom_sql",{"type":60,"value":374}," only when nothing above expresses the invariant — e.g. cross-column arithmetic\n(",{"type":55,"tag":77,"props":376,"children":378},{"className":377},[],[379],{"type":60,"value":380},"select 1 from orders where total != subtotal + tax",{"type":60,"value":382},"). Every row it returns counts as a failure.",{"type":55,"tag":63,"props":384,"children":385},{},[386,388,394],{"type":60,"value":387},"Call ",{"type":55,"tag":77,"props":389,"children":391},{"className":390},[],[392],{"type":60,"value":393},"posthog:data-quality-check-types",{"type":60,"value":395}," for each type's exact config schema rather than guessing.",{"type":55,"tag":63,"props":397,"children":398},{},[399,401,407,409,415,417,423,425,431],{"type":60,"value":400},"Checks live on the subject they audit: create them with ",{"type":55,"tag":77,"props":402,"children":404},{"className":403},[],[405],{"type":60,"value":406},"data-quality-check-create-on-view",{"type":60,"value":408},"\n(",{"type":55,"tag":77,"props":410,"children":412},{"className":411},[],[413],{"type":60,"value":414},"saved_query_id",{"type":60,"value":416}," path parameter) or ",{"type":55,"tag":77,"props":418,"children":420},{"className":419},[],[421],{"type":60,"value":422},"data-quality-check-create-on-table",{"type":60,"value":424}," (",{"type":55,"tag":77,"props":426,"children":428},{"className":427},[],[429],{"type":60,"value":430},"table_id",{"type":60,"value":432},").",{"type":55,"tag":118,"props":434,"children":436},{"id":435},"severity-and-triggers",[437],{"type":60,"value":438},"Severity and triggers",{"type":55,"tag":63,"props":440,"children":441},{},[442,447,449,455,457,463,465,471,473,478,480,485],{"type":55,"tag":69,"props":443,"children":444},{},[445],{"type":60,"value":446},"Severity",{"type":60,"value":448}," is a decision about consequences, not about confidence. Use ",{"type":55,"tag":77,"props":450,"children":452},{"className":451},[],[453],{"type":60,"value":454},"error",{"type":60,"value":456}," when the failure\nmeans downstream numbers should not be trusted — those failures mark the subject ",{"type":55,"tag":77,"props":458,"children":460},{"className":459},[],[461],{"type":60,"value":462},"failing",{"type":60,"value":464}," and\nnotify. Use ",{"type":55,"tag":77,"props":466,"children":468},{"className":467},[],[469],{"type":60,"value":470},"warn",{"type":60,"value":472}," for things worth surfacing that nobody would act on today. When unsure, ",{"type":55,"tag":77,"props":474,"children":476},{"className":475},[],[477],{"type":60,"value":470},{"type":60,"value":479}," is\nthe safer default: an ",{"type":55,"tag":77,"props":481,"children":483},{"className":482},[],[484],{"type":60,"value":454},{"type":60,"value":486}," check that cries wolf gets everything ignored.",{"type":55,"tag":63,"props":488,"children":489},{},[490,495],{"type":55,"tag":69,"props":491,"children":492},{},[493],{"type":60,"value":494},"Triggers",{"type":60,"value":496}," — there is nothing to schedule. A check runs when its subject's data changes: a\nmaterialized view's checks run as part of its refresh (and, when the team turns the gate on, a\nrefresh whose error-severity checks fail is not published), a source table's checks run after each\ncompleted sync, and a plain view's checks run when its DAG runs. Checks on a view outside any DAG\nonly run on demand.",{"type":55,"tag":118,"props":498,"children":500},{"id":499},"verify-what-you-wrote",[501],{"type":60,"value":502},"Verify what you wrote",{"type":55,"tag":63,"props":504,"children":505},{},[506],{"type":60,"value":507},"Author, run once, read the result. A check nobody has run is a guess.",{"type":55,"tag":509,"props":510,"children":511},"ol",{},[512,531,548],{"type":55,"tag":258,"props":513,"children":514},{},[515,521,523,529],{"type":55,"tag":77,"props":516,"children":518},{"className":517},[],[519],{"type":60,"value":520},"posthog:data-quality-check-create-on-view",{"type":60,"value":522}," (or ",{"type":55,"tag":77,"props":524,"children":526},{"className":525},[],[527],{"type":60,"value":528},"-on-table",{"type":60,"value":530},")",{"type":55,"tag":258,"props":532,"children":533},{},[534,540,541,546],{"type":55,"tag":77,"props":535,"children":537},{"className":536},[],[538],{"type":60,"value":539},"posthog:data-quality-check-run-on-view",{"type":60,"value":522},{"type":55,"tag":77,"props":542,"children":544},{"className":543},[],[545],{"type":60,"value":528},{"type":60,"value":547},") — returns a suite run",{"type":55,"tag":258,"props":549,"children":550},{},[551,553,559,561,567,569,574],{"type":60,"value":552},"Poll ",{"type":55,"tag":77,"props":554,"children":556},{"className":555},[],[557],{"type":60,"value":558},"system.information_schema.data_quality_check_runs",{"type":60,"value":560}," (or\n",{"type":55,"tag":77,"props":562,"children":564},{"className":563},[],[565],{"type":60,"value":566},"posthog:data-quality-check-results-on-view",{"type":60,"value":568},"\u002F",{"type":55,"tag":77,"props":570,"children":572},{"className":571},[],[573],{"type":60,"value":528},{"type":60,"value":575},") for the outcome",{"type":55,"tag":63,"props":577,"children":578},{},[579,581,587,589,595,597,603,605,610,612,617,618,623,625,631],{"type":60,"value":580},"A ",{"type":55,"tag":77,"props":582,"children":584},{"className":583},[],[585],{"type":60,"value":586},"failed",{"type":60,"value":588}," result on the first run is the interesting case: either you found real bad data, or the\nassertion is wrong. Take the ",{"type":55,"tag":77,"props":590,"children":592},{"className":591},[],[593],{"type":60,"value":594},"compiled_query",{"type":60,"value":596}," off the run, execute it with ",{"type":55,"tag":77,"props":598,"children":600},{"className":599},[],[601],{"type":60,"value":602},"posthog:execute-sql",{"type":60,"value":604},", and\nlook at what it actually matched before reporting anything. That ",{"type":55,"tag":77,"props":606,"children":608},{"className":607},[],[609],{"type":60,"value":594},{"type":60,"value":611}," comes from\n",{"type":55,"tag":77,"props":613,"children":615},{"className":614},[],[616],{"type":60,"value":566},{"type":60,"value":568},{"type":55,"tag":77,"props":619,"children":621},{"className":620},[],[622],{"type":60,"value":528},{"type":60,"value":624},"; the information_schema poll in step 3 does\nnot return it. An ",{"type":55,"tag":77,"props":626,"children":628},{"className":627},[],[629],{"type":60,"value":630},"errored",{"type":60,"value":632}," result is never a data\nproblem — the query could not run at all, usually a column name typo or a subject that no longer\nexists.",{"type":55,"tag":118,"props":634,"children":636},{"id":635},"judging-a-source-before-you-use-it",[637],{"type":60,"value":638},"Judging a source before you use it",{"type":55,"tag":63,"props":640,"children":641},{},[642],{"type":60,"value":643},"When an analysis depends on a warehouse table or view, check its verdict first:",{"type":55,"tag":130,"props":645,"children":647},{"className":132,"code":646,"language":134,"meta":135,"style":135},"SELECT subject_name, health, checks_total, checks_failing, last_run_at\nFROM system.information_schema.data_quality_health\n",[648],{"type":55,"tag":77,"props":649,"children":650},{"__ignoreMap":135},[651,659],{"type":55,"tag":141,"props":652,"children":653},{"class":143,"line":144},[654],{"type":55,"tag":141,"props":655,"children":656},{},[657],{"type":60,"value":658},"SELECT subject_name, health, checks_total, checks_failing, last_run_at\n",{"type":55,"tag":141,"props":660,"children":661},{"class":143,"line":153},[662],{"type":55,"tag":141,"props":663,"children":664},{},[665],{"type":60,"value":666},"FROM system.information_schema.data_quality_health\n",{"type":55,"tag":254,"props":668,"children":669},{},[670,680,691,701,712],{"type":55,"tag":258,"props":671,"children":672},{},[673,678],{"type":55,"tag":77,"props":674,"children":676},{"className":675},[],[677],{"type":60,"value":462},{"type":60,"value":679}," — an error-severity check found bad data. Say so in your answer; don't quietly use it.",{"type":55,"tag":258,"props":681,"children":682},{},[683,689],{"type":55,"tag":77,"props":684,"children":686},{"className":685},[],[687],{"type":60,"value":688},"erroring",{"type":60,"value":690}," — a check couldn't run. The data may be fine, but nobody is watching it.",{"type":55,"tag":258,"props":692,"children":693},{},[694,699],{"type":55,"tag":77,"props":695,"children":697},{"className":696},[],[698],{"type":60,"value":470},{"type":60,"value":700}," — only warn-severity failures. Usable, worth a mention.",{"type":55,"tag":258,"props":702,"children":703},{},[704,710],{"type":55,"tag":77,"props":705,"children":707},{"className":706},[],[708],{"type":60,"value":709},"healthy",{"type":60,"value":711}," — checks ran and passed.",{"type":55,"tag":258,"props":713,"children":714},{},[715,721],{"type":55,"tag":77,"props":716,"children":718},{"className":717},[],[719],{"type":60,"value":720},"unknown",{"type":60,"value":722}," \u002F absent — no checks, or none have run. Absence of failures is not evidence of health.",{"type":55,"tag":63,"props":724,"children":725},{},[726,728,733,735,741],{"type":60,"value":727},"For the history behind a verdict, ",{"type":55,"tag":77,"props":729,"children":731},{"className":730},[],[732],{"type":60,"value":558},{"type":60,"value":734}," carries recent\nexecutions with ",{"type":55,"tag":77,"props":736,"children":738},{"className":737},[],[739],{"type":60,"value":740},"observed_value",{"type":60,"value":742}," recorded on passes too, so you can see when a number started\ndrifting rather than just that it is wrong now.",{"type":55,"tag":118,"props":744,"children":746},{"id":745},"related",[747],{"type":60,"value":748},"Related",{"type":55,"tag":254,"props":750,"children":751},{},[752,770],{"type":55,"tag":258,"props":753,"children":754},{},[755,761,763,768],{"type":55,"tag":77,"props":756,"children":758},{"className":757},[],[759],{"type":60,"value":760},"setting-up-data-catalog",{"type":60,"value":762}," — what the data ",{"type":55,"tag":230,"props":764,"children":765},{},[766],{"type":60,"value":767},"means",{"type":60,"value":769},": metrics, trust marks, relationships.",{"type":55,"tag":258,"props":771,"children":772},{},[773,779],{"type":55,"tag":77,"props":774,"children":776},{"className":775},[],[777],{"type":60,"value":778},"querying-posthog-data",{"type":60,"value":780}," — the schema-discovery and HogQL rules these queries follow.",{"type":55,"tag":782,"props":783,"children":784},"style",{},[785],{"type":60,"value":786},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"items":788,"total":879},[789,804,816,828,841,848,863],{"slug":790,"name":790,"fn":791,"description":792,"org":793,"tags":794,"stars":24,"repoUrl":25,"updatedAt":803},"analyzing-expensive-users","analyze expensive users in AI observability","Analyze the most expensive users in AI observability and explain why they cost so much. Use when the user asks about top spenders, expensive users, per-user LLM cost, user-level cost drivers, or patterns behind high AI observability spend.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[795,796,799,802],{"name":22,"slug":23,"type":15},{"name":797,"slug":798,"type":15},"Cost Optimization","cost-optimization",{"name":800,"slug":801,"type":15},"Observability","observability",{"name":9,"slug":8,"type":15},"2026-08-13T04:28:38.012786",{"slug":805,"name":805,"fn":806,"description":807,"org":808,"tags":809,"stars":24,"repoUrl":25,"updatedAt":815},"auditing-endpoints","audit PostHog project endpoints","Audit every endpoint in a PostHog project for staleness, failed materialisations, and unused materialised versions. Use when the user asks \"what endpoints can I clean up?\", \"are any of my endpoints broken?\", \"which materialised versions are still being called?\", or wants a one-shot cleanup pass over the Endpoints product. Produces a prioritised report grouped by issue type, with recommended actions but does not modify anything without explicit confirmation.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[810,811,814],{"name":22,"slug":23,"type":15},{"name":812,"slug":813,"type":15},"Audit","audit",{"name":9,"slug":8,"type":15},"2026-06-08T08:08:33.693989",{"slug":817,"name":817,"fn":818,"description":819,"org":820,"tags":821,"stars":24,"repoUrl":25,"updatedAt":827},"auditing-warehouse-source-health","audit PostHog data warehouse source health","Audit the health of a PostHog project's data warehouse sources and syncs — find every broken or degraded source connection, sync schema, and webhook channel. Use when the user asks \"why are my imports failing?\", \"what's broken with my sources?\", \"why is my warehouse data stale?\", or wants a one-shot triage of source\u002Fsync health before deciding where to dig in. Produces a prioritized report grouped by severity, with recommended next steps. For materialized-view health use `auditing-warehouse-view-health`; for a single failing sync use `diagnosing-failed-warehouse-syncs`.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[822,823,825,826],{"name":812,"slug":813,"type":15},{"name":824,"slug":33,"type":15},"Data Warehouse",{"name":800,"slug":801,"type":15},{"name":9,"slug":8,"type":15},"2026-06-18T08:22:57.67984",{"slug":829,"name":829,"fn":830,"description":831,"org":832,"tags":833,"stars":24,"repoUrl":25,"updatedAt":840},"auditing-warehouse-view-health","audit PostHog materialized view health","Audit the health of a PostHog project's materialized views (saved queries) — find every failed materialization and flag unused or stale materialized views that cost storage and compute. Use when the user asks \"which of my views are broken?\", \"why is this materialized view failing?\", \"are any of my views wasting compute?\", or wants a one-shot triage of view health. For source\u002Fsync health use `auditing-warehouse-source-health`.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[834,835,836,839],{"name":812,"slug":813,"type":15},{"name":824,"slug":33,"type":15},{"name":837,"slug":838,"type":15},"Performance","performance",{"name":9,"slug":8,"type":15},"2026-06-18T08:25:10.936787",{"slug":4,"name":4,"fn":5,"description":6,"org":842,"tags":843,"stars":24,"repoUrl":25,"updatedAt":26},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[844,845,846,847],{"name":22,"slug":23,"type":15},{"name":17,"slug":18,"type":15},{"name":13,"slug":14,"type":15},{"name":20,"slug":20,"type":15},{"slug":849,"name":849,"fn":850,"description":851,"org":852,"tags":853,"stars":24,"repoUrl":25,"updatedAt":862},"authoring-error-tracking-alerts","author PostHog error tracking alerts","Author error tracking alerts that fire when an issue is created, reopened, or starts spiking. Use when the user asks to set up error notifications, route exceptions to Slack\u002Fwebhook\u002FLinear, or evaluate which error events are worth alerting on. Covers trigger-event selection, integration choice, dedup against existing alerts, and shipping with the canonical message body shape.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[854,857,860,861],{"name":855,"slug":856,"type":15},"Alerting","alerting",{"name":858,"slug":859,"type":15},"Debugging","debugging",{"name":800,"slug":801,"type":15},{"name":9,"slug":8,"type":15},"2026-08-13T04:28:36.025103",{"slug":864,"name":864,"fn":865,"description":866,"org":867,"tags":868,"stars":24,"repoUrl":25,"updatedAt":878},"authoring-log-alerts","author log alerts in PostHog","Author useful, low-noise log alerts on services in a PostHog project. Use when the user asks to set up alerts for their logs, suggest alerts they should add, or evaluate whether a service is worth monitoring. Covers service triage, baseline characterisation, threshold drafting, back-testing via simulate, and shipping with a notification destination.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[869,870,873,874,877],{"name":22,"slug":23,"type":15},{"name":871,"slug":872,"type":15},"Monitoring","monitoring",{"name":800,"slug":801,"type":15},{"name":875,"slug":876,"type":15},"Operations","operations",{"name":9,"slug":8,"type":15},"2026-08-13T04:28:20.051489",78,{"items":881,"total":1009},[882,889,895,902,909,916,923,931,948,966,982,997],{"slug":790,"name":790,"fn":791,"description":792,"org":883,"tags":884,"stars":24,"repoUrl":25,"updatedAt":803},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[885,886,887,888],{"name":22,"slug":23,"type":15},{"name":797,"slug":798,"type":15},{"name":800,"slug":801,"type":15},{"name":9,"slug":8,"type":15},{"slug":805,"name":805,"fn":806,"description":807,"org":890,"tags":891,"stars":24,"repoUrl":25,"updatedAt":815},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[892,893,894],{"name":22,"slug":23,"type":15},{"name":812,"slug":813,"type":15},{"name":9,"slug":8,"type":15},{"slug":817,"name":817,"fn":818,"description":819,"org":896,"tags":897,"stars":24,"repoUrl":25,"updatedAt":827},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[898,899,900,901],{"name":812,"slug":813,"type":15},{"name":824,"slug":33,"type":15},{"name":800,"slug":801,"type":15},{"name":9,"slug":8,"type":15},{"slug":829,"name":829,"fn":830,"description":831,"org":903,"tags":904,"stars":24,"repoUrl":25,"updatedAt":840},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[905,906,907,908],{"name":812,"slug":813,"type":15},{"name":824,"slug":33,"type":15},{"name":837,"slug":838,"type":15},{"name":9,"slug":8,"type":15},{"slug":4,"name":4,"fn":5,"description":6,"org":910,"tags":911,"stars":24,"repoUrl":25,"updatedAt":26},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[912,913,914,915],{"name":22,"slug":23,"type":15},{"name":17,"slug":18,"type":15},{"name":13,"slug":14,"type":15},{"name":20,"slug":20,"type":15},{"slug":849,"name":849,"fn":850,"description":851,"org":917,"tags":918,"stars":24,"repoUrl":25,"updatedAt":862},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[919,920,921,922],{"name":855,"slug":856,"type":15},{"name":858,"slug":859,"type":15},{"name":800,"slug":801,"type":15},{"name":9,"slug":8,"type":15},{"slug":864,"name":864,"fn":865,"description":866,"org":924,"tags":925,"stars":24,"repoUrl":25,"updatedAt":878},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[926,927,928,929,930],{"name":22,"slug":23,"type":15},{"name":871,"slug":872,"type":15},{"name":800,"slug":801,"type":15},{"name":875,"slug":876,"type":15},{"name":9,"slug":8,"type":15},{"slug":932,"name":932,"fn":933,"description":934,"org":935,"tags":936,"stars":24,"repoUrl":25,"updatedAt":947},"building-canvases","create and edit PostHog canvases","Create or edit a PostHog freeform canvas — a sandboxed browser application (data board, document, form, small tool, graphics experiment) stored in PostHog and rendered by the desktop\u002Fweb app. Use when a task asks to build, generate, update, or fix a standalone canvas app, or when a freeform canvas id is given as the publish target. For grid\u002Fhome canvases, widget placements, or reusable components, use composing-grid-canvases instead. Covers resolving or creating the target canvas, choosing an implementation approach (React + Quill vs plain HTML\u002Fbrowser APIs), the read → edit → validate → publish → build loop, and which companion canvas skills to load for the details.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[937,940,943,944],{"name":938,"slug":939,"type":15},"Automation","automation",{"name":941,"slug":942,"type":15},"Design","design",{"name":9,"slug":8,"type":15},{"name":945,"slug":946,"type":15},"Prototyping","prototyping","2026-08-19T03:27:38.215922",{"slug":949,"name":949,"fn":950,"description":951,"org":952,"tags":953,"stars":24,"repoUrl":25,"updatedAt":965},"building-html-canvases","author HTML and CSS PostHog canvases","Author a PostHog canvas with semantic HTML, CSS, and direct browser APIs — documents, articles, generative graphics, 2D canvas and WebGL experiences, and focused experiments where React components add no useful structure. Use after building-canvases has routed a canvas request to a plain-HTML\u002Fbrowser-API implementation. Covers the thin component wrapper the current runtime requires, styling and theming without Quill, drawing surfaces, and animation\u002Fcleanup patterns.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[954,957,958,961,964],{"name":955,"slug":956,"type":15},"CSS","css",{"name":941,"slug":942,"type":15},{"name":959,"slug":960,"type":15},"Graphics","graphics",{"name":962,"slug":963,"type":15},"HTML","html",{"name":9,"slug":8,"type":15},"2026-08-06T06:09:30.313848",{"slug":967,"name":967,"fn":968,"description":969,"org":970,"tags":971,"stars":24,"repoUrl":25,"updatedAt":981},"building-react-quill-canvases","build React and Quill canvases","Author the React + Quill implementation of a PostHog canvas: the single-component contract, the allowed imports, Quill (PostHog's design system) component and composition rules, theme-aware design tokens, loading skeletons, and the in-canvas date picker. Use after building-canvases has routed a canvas request to a React implementation — dashboards, data boards, forms, tools, or any canvas that should look native to PostHog.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[972,973,976,978],{"name":941,"slug":942,"type":15},{"name":974,"slug":975,"type":15},"Frontend","frontend",{"name":977,"slug":39,"type":15},"React",{"name":979,"slug":980,"type":15},"UI Components","ui-components","2026-08-19T03:27:37.227731",{"slug":983,"name":983,"fn":984,"description":985,"org":986,"tags":987,"stars":24,"repoUrl":25,"updatedAt":996},"building-workflows","build and edit PostHog workflows","Build, edit, test, enable, and monitor PostHog workflows over MCP. Author the action\u002Fedge graph so it runs and opens cleanly in the visual editor, then change drafts surgically with patch operations. Use when asked to build, set up, automate, change, fix, or debug a workflow, campaign, broadcast, drip sequence, or event-triggered automation in the workflows product.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[988,989,992,993],{"name":938,"slug":939,"type":15},{"name":990,"slug":991,"type":15},"MCP","mcp",{"name":9,"slug":8,"type":15},{"name":994,"slug":995,"type":15},"Workflow Automation","workflow-automation","2026-08-10T04:16:26.294119",{"slug":998,"name":998,"fn":999,"description":1000,"org":1001,"tags":1002,"stars":24,"repoUrl":25,"updatedAt":1008},"check-posthog-loading","inspect PostHog SDK loading across URLs","Inspect how the PostHog JavaScript SDK is loaded across a list of URLs. Use to confirm consistent installation across pages, find pages missing the snippet, detect mismatched API keys or hosts between pages, and verify the load method (head snippet vs deferred vs array.js).\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1003,1004,1005,1006,1007],{"name":22,"slug":23,"type":15},{"name":858,"slug":859,"type":15},{"name":974,"slug":975,"type":15},{"name":800,"slug":801,"type":15},{"name":9,"slug":8,"type":15},"2026-05-07T05:56:19.828048",251]