<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Carolina Moura on Medium]]></title>
        <description><![CDATA[Stories by Carolina Moura on Medium]]></description>
        <link>https://medium.com/@carolinamns?source=rss-0e4a65f2a64f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*gb4NiDP-lSQUSf6y0QkyaQ.jpeg</url>
            <title>Stories by Carolina Moura on Medium</title>
            <link>https://medium.com/@carolinamns?source=rss-0e4a65f2a64f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 10:06:01 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@carolinamns/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How Analytics Engineers Can Use AI In Their Everyday Workflow]]></title>
            <link>https://medium.com/indiciumtech/how-analytics-engineers-can-use-ai-in-their-everyday-workflow-00e0713d726a?source=rss-0e4a65f2a64f------2</link>
            <guid isPermaLink="false">https://medium.com/p/00e0713d726a</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[analytics-engineering]]></category>
            <category><![CDATA[analytics-engineer]]></category>
            <dc:creator><![CDATA[Carolina Moura]]></dc:creator>
            <pubDate>Fri, 25 Apr 2025 20:20:52 GMT</pubDate>
            <atom:updated>2025-04-29T18:15:08.717Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YNH74Y1eMSD3VtjVV9RHbA.png" /></figure><p>If you work as an <strong>Analytics Engineer</strong>, you’ve probably spent hours documenting dbt models, debugging cryptic errors, or hunting for a bug that, in the end, was just a misplaced apostrophe. On top of that, building complex SQL calculations or translating queries between different languages can take up precious time. But what if <strong>artificial intelligence (AI)</strong> could help with those tasks?</p><p><strong>AI</strong> tools don’t replace human knowledge, but they can serve as support to speed up development and minimize operational errors when used appropriately. In this article, we’ll explore five practical ways to incorporate <a href="https://indicium.ai/knowledge-hub/blog/ai-data-services-new-era/"><strong>AI</strong></a> into your daily workflow, bringing more efficiency without compromising the quality of your work.</p><h3><strong>1. Generate dbt documentation</strong></h3><p>Documenting dbt models is essential for maintaining data governance, but writing descriptions manually can be time-consuming and prone to inconsistencies (who hasn’t missed the indentation in a Jinja block?). With AI, this process becomes faster and more standardized. Generative <strong>AI</strong> models can analyze SQL code to generate descriptions for tables and columns, and even suggest data quality tests.</p><p>As an example, let’s consider the <em>stg_orders.sql</em> model from the Northwind database:</p><figure><img alt="Code snippet showing the stg_orders.sql dbt model from the Northwind database, used in an analytics engineering context" src="https://cdn-images-1.medium.com/max/414/1*iTslmTQbHCfM9nZzux5Jpg.png" /><figcaption>Example of a dbt model used in analytics engineering</figcaption></figure><p>We can use <strong>AI</strong> to automatically generate documentation for the model by prompting something like:</p><blockquote><em>Based on the dbt model code stg_orders.sql, generate the corresponding stg_orders.yml documentation file. Include descriptions for the table and columns. Also, suggest relevant generic tests to ensure data quality, such as null value validation, uniqueness checks, and date range validation.</em></blockquote><p>Here’s how <strong>AI</strong> might structure the YAML, with descriptions and tests inferred from the schema:</p><figure><img alt="YAML file with table and column descriptions generated by AI for the stg_orders model" src="https://cdn-images-1.medium.com/max/895/1*CNNnJW6GnBZGqTJ0u46qIw.png" /><figcaption>stg_orders.yml dbt documentation generated by AI</figcaption></figure><p>That said, when it comes to columns with business-specific logic, <strong>AI</strong> might not understand all the nuances. Keep an eye out for some common pitfalls, which we’ll cover at the end of the article.</p><h3><strong>2. Interpret error logs</strong></h3><p>Who hasn’t encountered an indecipherable error and spent far too long trying to understand the root cause? Logs can be lengthy and hard to interpret, especially when they involve references between models, custom macros, or dbt_project.yml configurations. Instead of analyzing each detail manually, <strong>AI</strong> can help interpret the error and quickly suggest fixes.</p><p>When running a dbt model, you might encounter this error:</p><figure><img alt="Error message displayed during the execution of a dbt model, typical in analytics engineering workflows" src="https://cdn-images-1.medium.com/max/948/1*Xh6Pme8bc40AYwbX4rufuw.png" /><figcaption>Example of a dbt error in analytics engineering</figcaption></figure><p>After submitting the error to <strong>AI</strong> with the prompt <em>“Explain this dbt error and suggest a fix”</em>, you might receive a response like this:</p><figure><img alt="Text generated by AI providing a diagnosis and suggested fix for a dbt model error" src="https://cdn-images-1.medium.com/max/1024/1*HZZWn4ddsUC4UbPjEAk61w.png" /><figcaption>AI-generated error explanation</figcaption></figure><p>This interpretation saves you time troubleshooting and gets you straight to potential solutions.</p><h3><strong>3. Convert functions between data warehouses</strong></h3><p>In data migration projects, adapting functions from one data warehouse to another (<a href="https://aws.amazon.com/redshift/">Redshift</a> to <a href="https://www.snowflake.com/">Snowflake</a>, <a href="https://cloud.google.com/bigquery">BigQuery</a> to <a href="http://databricks.com/">Databricks</a>, etc.) can be a time-consuming process. Each platform has its own syntax rules, operators, and native functions, which often require manual adjustments to ensure the code works properly in the new environment. With <strong>AI</strong>, much of this conversion can be automated.</p><p>Suppose you’re migrating this model from Redshift to Snowflake:</p><figure><img alt="SQL code example of a dbt model written for Redshift, used in analytics engineering" src="https://cdn-images-1.medium.com/max/541/1*kwOaRwNJSgkkswSPl6UCFg.png" /><figcaption>dbt model using Redshift syntax in analytics engineering</figcaption></figure><p>You could use a prompt like this to generate a version compatible with Snowflake: <em>“Convert the following dbt model from Redshift to Snowflake, keeping the logic intact.”</em></p><figure><img alt="SQL code originally written in Redshift syntax, converted to Snowflake using AI" src="https://cdn-images-1.medium.com/max/574/1*g8dU8kb9NvBNzuhN6AESYQ.png" /><figcaption>Snowflake version of dbt model converted by AI</figcaption></figure><p><strong>AI</strong> adapts the syntax to Snowflake while maintaining the original logic, reducing manual work and potential human error during migrations. This not only speeds up migrations but also helps maintain consistency across projects.</p><h3><strong>4. Optimize dbt models</strong></h3><p>Beyond syntax conversion, <strong>AI</strong> can also suggest performance and readability improvements, such as replacing subqueries with Common Table Expressions (CTEs), reducing duplicated logic, and simplifying join structures. These optimizations can reduce execution time, improve maintainability, and make your models easier to understand, all without changing the underlying logic.</p><p>Here’s an example of a dbt model that could benefit from refactoring:</p><figure><img alt="SQL code of a dbt model with potential for performance and readability improvements before AI optimization" src="https://cdn-images-1.medium.com/max/979/1*ELQRXr3d1MHEE-vcAf3nMA.png" /><figcaption>dbt model before AI optimization</figcaption></figure><p>You can use a prompt like this: <em>“Optimize the following dbt model for performance and readability without changing the logic. Follow SQL code style best practices.”</em></p><p>The AI-generated version might look like this:</p><figure><img alt="dbt model refactored by AI with improved performance and readability" src="https://cdn-images-1.medium.com/max/659/1*4pg9Enk2gTQJ1IFN04j1lA.png" /><figcaption>dbt model optimized by AI</figcaption></figure><p>In larger projects with complex transformations, small optimizations like these can scale into meaningful gains, not just in performance, but also in clarity and team collaboration.</p><h3><strong>5. Automate dimensional modeling</strong></h3><p>Choosing the best approach to data modeling can be a challenge, especially when working with multiple tables. <strong>AI</strong> can help by suggesting optimized structures for fact and dimension tables, making data organization more efficient and easier to scale.</p><p>Using the Northwind database diagram as a reference, you could prompt AI with: <em>“Based on the diagram provided, design a dimensional model.”</em></p><figure><img alt="Entity-relationship diagram of the Northwind database, commonly used as a reference in analytics engineering" src="https://cdn-images-1.medium.com/max/974/1*VXgmntrOdy1TAalmQA6aww.png" /><figcaption>Northwind database diagram used in analytics engineering</figcaption></figure><p>You might receive an output like this:</p><figure><img alt="Dimensional model generated by AI based on the Northwind database structure, including suggested fact and dimension tables" src="https://cdn-images-1.medium.com/max/1024/1*c2kMbPcVg63nsGbh_jC9WA.png" /><figcaption>Dimensional model suggested by AI</figcaption></figure><p>Once the structure is defined, you could also ask the <strong>AI</strong> to:</p><ul><li>Create a mapping table between the transactional and dimensional models.</li><li>Generate the corresponding dbt models using the transactional tables as sources.</li><li>Suggest naming conventions and folder structures to organize your dbt project.</li></ul><h3><strong>Best practices when working with AI</strong></h3><p><strong>AI</strong> can be a powerful ally, but only when used thoughtfully. Here are some key practices for safe, effective usage:</p><ol><li><strong>Always validate AI output:</strong> Review any AI-generated code or documentation carefully. It may include incorrect syntax or misinterpret business context.</li><li><strong>Test before deploying:</strong> Run tests on any generated or modified code before pushing to production.</li><li><strong>Keep sensitive data private:</strong> Never input confidential data, credentials, or proprietary business logic into AI tools.</li><li><strong>Learn from AI, don’t just copy:</strong> Use the output as a learning opportunity to understand new techniques and patterns.</li><li><strong>Iterate your prompts:</strong> The quality of AI output often depends on how clearly and specifically you ask. Don’t be afraid to refine and experiment.</li></ol><p>The <strong>AI</strong> landscape is evolving rapidly, with tools becoming increasingly customizable and integrated into data platforms. If you haven’t started using <strong>AI</strong> in your daily workflow yet, now is a great time to begin. Start small: documentation and error debugging are low-risk areas where mistakes are easy to catch. As you explore more use cases, consider building a prompt library tailored to your common tasks and gradually refining it as you go. And don’t keep it all to yourself: sharing prompts and insights with your team helps foster a culture of learning and experimentation. Over time, you’ll develop an intuition for where <strong>AI</strong> is most helpful in your workflow and how to get the most out of it in your specific context.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=00e0713d726a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/indiciumtech/how-analytics-engineers-can-use-ai-in-their-everyday-workflow-00e0713d726a">How Analytics Engineers Can Use AI In Their Everyday Workflow</a> was originally published in <a href="https://medium.com/indiciumtech">Indicium AI Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>