AI Data Modelling Architect

    by Partha Basak

    1

    Analytics engineering requires more than just writing SQL; it demands rigorous dimensional modeling and testable data products.

    Free

    Security scanned

    Works with the AI Agents you already use

    AI Data Modelling Architect

    Example session with this skill installed

    Design a dbt model for subscription payments. Sources are 'raw_payments' and 'raw_plans'. I need to track status changes over time and handle late-arriving refunds.

    • Read your context and instructions
    • Compiled the ai data modelling

    I have designed the subscription payments model using an accumulating snapshot pattern for the fact table and SCD Type 2 logic for status tracking.

    Subscription Payments Architecture

    -- marts/fct_subscription_payments.sql
    {{
      config(
        materialized='incremental',
        unique_key='payment_hk',
        incremental_strategy='merge',
        cluster_by=['created_at_date']
      )
    }}
    
    WITH source_data AS (
        SELECT * FROM {{ ref('stg_payments') }}
        {% if is_incremental() %}
        WHERE updated_at >= (SELECT MAX(updated_at) FROM {{ this }})
        {% endif %}
    ),
    
    final AS (
        SELECT
            -- Surrogate Key: Hash of business key + source system
            {{ dbt_utils.generate_surrogate_key(['payment_id', "'stripe'"]) }} as payment_hk,
            payment_id,
            plan_id,
            amount_cents,
            currency,
            status,
            -- Grain: One row per payment attempt/event
            created_at,
            updated_at,
            COALESCE(refunded_at, '9999-12-31') as refunded_at
        FROM source_data
    )
    
    SELECT * FROM final
    
    ComponentLogic
    GrainOne record per unique payment transaction ID.
    Key LogicMD5 hash of payment_id normalized to string to prevent null collisions.
    SCD LogicUses valid_from and valid_to half-open intervals for plan history.
    IncrementalMerge strategy on payment_hk to handle status updates and late refunds.

    Next steps

    1. Review the stg_payments YAML to ensure payment_id is flagged as a non-null unique key.
    2. Run dbt test --select fct_subscription_payments to verify no grain fan-out occurred during the join to plans.
    3. Deploy the provided SCD2 macro to the macros/ folder to handle interval overlaps.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Analytics engineering requires more than just writing SQL; it demands rigorous dimensional modeling and testable data products. This skill transforms raw requirements into production-ready dbt models, Snowflake architectures, and hardened data pipelines.

    What it does

    • Dimensional modeling designs transaction, periodic snapshot, and accumulating snapshot facts with explicit grain definitions.
    • SCD management implements Type 2 slowly changing dimensions using half-open intervals and robust history rebuild logic.
    • Key engineering generates deterministic surrogate keys using canonicalized hashing and source-system scoping.
    • Incremental processing builds dbt strategies for deduplication, late-arrival handling, and idempotent merges.
    • Data reconciliation creates test suites for financial control totals, relationship integrity, and source-to-target counts.

    How it works

    1. Source analysis maps business processes to source entities, identifying ingestion patterns and CDC behavior.
    2. Design phase defines the grain for facts and classifies measures as additive, semi-additive, or non-additive.
    3. Implementation writes dbt models across staging, intermediate, and marts layers with explicit unique keys.
    4. Validation executes a test matrix covering uniqueness, SCD overlaps, and incremental equivalence.

    Frameworks & tools

    This skill is optimized for dbt Core and Snowflake. It utilizes dimensional modeling principles (Kimball), SQL, and YAML for dbt configurations and tests.

    Why this beats prompting it yourself

    Generic prompts often produce SQL that fails on edge cases like late-arriving facts or overlapping SCD intervals. This skill enforces strict grain isolation and deterministic hashing, preventing the common "fan-out" join errors that break financial reporting.

    Use cases

    • Migrating raw staging tables into a star schema for BI tools like Looker or Tableau.
    • Designing a financial reconciliation model to track authorized vs. settled payments.
    • Refactoring legacy SQL into modular dbt models with proper testing and documentation.
    • Implementing an SCD Type 2 pipeline to track historical changes in customer attributes.

    Known limitations

    Does not perform live warehouse execution or production deployments. It provides code and commands, but requires a local dbt environment or Snowflake instance to run.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free to use

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 11 days ago

    • Free with an Agensi account

    Permissions

    Terminal / Shell
    Read Files
    Listed11 days ago

    What's inside

    Creator

    Partha Basak

    Partha Basak

    Hi, I’m Partha — a Data Analytics Engineer with 5+ years of experience in data analytics and analytics engineering, backed by 18+ years of overall IT experience. I turn raw data into reliable, reusable, business-ready data products that help organizations make faster, better-informed decisions. My focus goes beyond building dashboards — I work on the data models, transformation pipelines, metric definitions, and analytical foundations that make trusted insights possible. At Honeywell, I’ve worked on analytics initiatives that combine SQL, Python, Snowflake, dbt, Airflow, and Power BI to improve data reliability, streamline reporting, and enable self-service analytics. By developing reusable data models, standardizing KPIs, and automating reporting workflows, I’ve helped reduce repetitive reporting effort by 35% across 10+ stakeholder teams and improve decision-making through accessible, consistent business insights. *What I bring to an analytics team:* 🔹 *Analytics Engineering:* Building modular data transformation workflows, reusable models, data quality checks, and trusted analytical datasets. 🔹 *Data Modelling & SQL:* Designing dimensional models, defining business logic, reconciling metrics, and creating consistent reporting foundations. 🔹 *Python & Automation:* Streamlining data processing, validation, and repetitive analytical workflows. 🔹*BI & Self-Service Analytics:* Developing Power BI dashboards, semantic reporting layers, and standardized KPIs that empower stakeholders to explore data independently. 🔹*Business & Product Analytics:* Translating business questions into measurable KPIs, actionable insights, performance analysis, and data-driven recommendations. 🔹 *Collaboration & Delivery:* Working with cross-functional stakeholders, improving analytical processes, and bringing structure to complex data and business problems. I’m also building hands-on, end-to-end analytics engineering solutions involving cloud data storage, Snowflake, dbt, data quality testing, and orchestration — strengthening my ability to design reliable, production-oriented data workflows. I believe great analytics engineering is about creating trusted data foundations that teams can reuse, understand, and confidently act on.

    Frequently Asked Questions

    This skill follows Kimball-style dimensional modeling, producing modular dbt layers (staging, intermediate, marts) with a specific focus on handling complex SCD Type 2 logic and deterministic surrogate keys.

    The skill is specifically optimized for dbt Core and Snowflake; it generates dbt-compliant SQL, YAML configuration files, and testing schemas tailored for Snowflake’s architecture.

    It solves for data 'fan-out' during joins, overlapping intervals in historical tracking, and inconsistent grains that typically cause discrepancies in BI tools like Looker or Tableau.

    You will receive the logic, structural patterns, and dbt code templates required to build your models, though you will need your own active Snowflake instance and dbt environment to execute the code.

    Yes, the skill is designed to handle refactoring by analyzing your existing legacy SQL and re-mapping it into a structured, testable star schema with proper documentation.

    New in Data & Databases

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Data & Databases.

    Free