Skip to main content
skill CX Codex

modeling-warehouse-foundations — Claude Code skill: setup guide

modeling-warehouse-foundations sets core guidelines for building PostHog data models via native HogQL views or an external dbt setup.

no license 172 installs ★ 101 updated 2026-10-24

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add PostHog/ai-plugin --skill modeling-warehouse-foundations -a claude-code
Open on GitHub

What modeling-warehouse-foundations does

This skill guides the design of reusable analytical models in PostHog. It structures the choice between two paths: native PostHog views managed through HogQL tools (view-create and view-materialize) or an external dbt repository organized into staging and marts layers with schema tests.

Inside the native stack, unaliased fields or SELECT * trigger immediate failures on posthog:view-create. The skill enforces explicit column aliasing, sets rules for choosing between person-level and group-level aggregation, and routes currency calculations through the built-in convertCurrency() function.

PostHog provides no internal dbt runner, so all dbt transformations must execute in an external CI pipeline or orchestrator.

What it helps with

  • choose between native HogQL views and an external dbt repository
  • author valid posthog:view-create definitions with strict column aliases
  • set up physical materialization and sync_frequency for heavy queries
  • handle monetary metrics using the native convertCurrency() syntax

Example prompts for the agent

  • Help me author a materialized view in PostHog for monthly active accounts
  • Show me how to organize an external dbt repository targeting PostHog data
  • Write a HogQL view query with explicit column aliases and currency conversion

How to install modeling-warehouse-foundations

1Skills CLI (Vercel)

npx skills add PostHog/ai-plugin --skill modeling-warehouse-foundations -a claude-code

2Manually: put the files in place

~/.claude/skills/modeling-warehouse-foundations/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/modeling-warehouse-foundations/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about modeling-warehouse-foundations

How to install modeling-warehouse-foundations in Claude Code?

Run npx skills add PostHog/ai-plugin --skill modeling-warehouse-foundations -a claude-code in your terminal.

What does modeling-warehouse-foundations do?

It provides foundational modeling standards for PostHog, covering HogQL view materialization, column aliasing rules, and dbt project skeletons.

Can dbt run natively inside PostHog?

No. PostHog has no built-in dbt runtime, meaning models must run in your own CI or scheduler against the warehouse.

Similar skills

All skills for Data and databases →

From the same set82

The whole set →
writing-streamlit-apps The writing-streamlit-apps skill guides Python code for Streamlit apps that read PostHog data inside a sandbox. Use it when building or debugging dashboards with tables and charts. CX Codex +1 177installs modeling-revenue-metrics modeling-revenue-metrics builds reusable revenue models for MRR, ARR, churn, ARPU and LTV from PostHog views or dbt. Use it for revenue analysis by customer, product or period. CX Codex +1 175installs modeling-product-usage-metrics modeling-product-usage-metrics builds retention, frequency, and lifecycle models using PostHog HogQL views or dbt data marts with built-in tests. CX Codex +1 175installs modeling-dimension-tables modeling-dimension-tables builds star-schema dimension tables in PostHog HogQL views or dbt projects so you avoid repetitive joins across your metrics. CX Codex +1 174installs instrument-metrics The instrument-metrics Claude Code skill adds PostHog metric capture to a codebase. It runs after feature work or PR review, and when a request calls for counters or other metrics. CX Codex +1 154installs debugging-experiments debugging-experiments — a Claude Code skill for investigating PostHog experiment results. It checks uneven or missing exposures against the experiment’s data and known causes. CX Codex +1 150installs context-layer-health-check The context-layer-health-check Claude Code skill checks a context wiki after changes are consolidated. It triages missed entries, conflicting claims, and outdated priorities. CX Codex +1 150installs understanding-billing-usage understanding-billing-usage is a Claude Code skill that investigates PostHog usage and spend through Billing MCP tools. It handles questions about spikes, changes, and the products or projects behind usage. CX Codex +1 150installs

Project sponsors

Companies that keep this analytics open