gpt analytics

AI in the Daily Work of a Web Analyst

Back to article list

AI assistants (commonly referred to as chatbots or AI chats) have significantly impacted various aspects of our both the personal and professional lives. From planning shopping trips and asking health-related questions to managing time, analyzing data, visualizing metrics, writing scripts, and creating regex patterns. Personally, I use chatbots every day. Using content grouping in Google Analytics 4 as an example, I’ll share my best practices and insights on leveraging AI in web analytics.

Chatbot and the Concept of Content Grouping

In GPT Chat, I uploaded a report containing the pages from my company’s website. These were intended as a starting point for creating content groupings in Google Analytics 4. By merging multiple URLs into cohesive categories, we aimed to gain a deeper understanding of user behavior on the site and streamline the content optimization process.

The chatbot’s task was to identify patterns within the page URLs and classify them into categories. The report included not only the URLs themselves but also the associated data.

Prompt:

“Divide the pages of my website into content categories in Google Analytics 4 based on their structure and purpose. I have data that includes the URL paths of the pages, session counts, key events, and the average engagement time of users on each page. Based on this, I’d like you to create categories.”

As a result of this query, I received categories that fit my website while also reflecting user visits and transitions between different sections.

Tips:

  • Use client data exclusively in chatbot versions intended for business use (e.g., ChatGPT Teams) to ensure a higher level of privacy and data security.
  • CSV is the best and most widely accepted format for such tasks.
  • Prepare files to include only relevant data. For instance, an exported CSV report from GA4 may contain rows like: # Exported report in CSV format, # Account: xxx, # Property: xxx. These are unnecessary and can even hinder chatbot performance.

An example of a proper file:

url,pageviews,avg_time 

/job-offers/data-analyst,450,120

/job-offers/specialist-seo,320,95

/blog/analysis-internet,780,180

Chatbot knows the regular expressions

In the next step, I asked the chatbot to prepare regular expressions that would enable content grouping in GA4 via Google Tag Manager. I quickly obtained the foundation for creating a table of regular expressions.

Prompt

“Create regular expressions (regex) that will allow assigning pages of my website to specific content categories in Google Tag Manager. The categorization has already been conducted and includes the following groups:”

Careers: Sites with job information, employment opportunities and recruitment.

Homepage: Home page of the website.

Offer: Pages detailing the company’s services and offerings.

Portfolio: Pages showcasing completed projects or products.

About Us: Pages with information about the company, team, mission, etc.

Blog: sites with blog articles.

Other: All sites that do not fit into the above categories.

In the first version of the response, the chatbot created regular expressions that, instead of grouping all addresses containing a common element, e.g., job offers in the analytics, SEO, etc. sections, were limited only to the main address of a given section. Learning from this experience, I modified the query by adding a verification criterion:”

Prompt 2.0 

“Create regular expressions (regex) that will allow assigning pages of my website to specific content categories in Google Tag Manager. The categorization has already been completed and includes the following groups:”

Careers: Sites with job information, employment opportunities and recruitment.

Homepage: Home page of the website.

Offer: Pages detailing the company’s services and offerings.

Portfolio: Pages showcasing completed projects or products.

About Us: Pages with information about the company, team, mission, etc.

Blog: sites with blog articles.

Other: All sites that do not fit into the above categories.

The generated regular expressions should be tailored to URL paths that match these categories. Make sure that the regexes take into account the various possible path variants and are flexible enough to capture all pages that fit the category.

As a result, I would like to receive a list of regexes, ready to be used in GTM, with a brief description of how each regex works and for which category it is intended.”

Tips:

  • Expectations should be well defined.
  • Test, test, test. It’s a good idea to ask the chatbot to verify that the addresses we provided earlier match the patterns. It will also be a good move to ask it to assign hypothetical future addresses to categories based on accepted rules.
  • Chatbot – the clairvoyant

    I also tried out GPT chat’s capabilities for practical data analysis. The first sentence consisted of the estimation of metrics relevant to our company website.

    Prompt

    “Based on page view data from the last 6 months, analyze trends for each content group. Use a simple predictive model (you can use Prophet) and show predicted values for the next 3 months.”

    I asked the chatbot for estimates for a period from which I already had statistics, so I was able to assess the extent to which the calculated metrics deviated from reality. This historical validation showed that the model used deviated by about 12% from the account data.

    Tips:

    • If you care about a specific model/estimation approach you need to specify it
    • Do not immediately provide all the metrics you want to estimate. Excessive data combined with the use of several forecasting methods can, in extreme cases, lead to suspension of the chat

    Chatbot in front of the board

    The chatbot’s final task was to create charts with time-varying metrics by category.

    Prompt

    “Prepare a set of bar charts for average user engagement time data in each category (Career, Offer, Blog, Portfolio, About Us) based on a report containing monthly data (May, June, July, August 2024).

    Each chart should meet the following criteria:

    One category per chart: Each chart shows data for only one category.

    Indicator: The Y-axis shows the average user engagement time in seconds.

    Period: The X axis should represent consecutive months (May, June, July, August).

    Order: Posts are arranged chronologically (May -> August).

    Look: charts should be aesthetically pleasing, easy to read and distinguished by described axes and titles. Each chart should include a legend with the name of the indicator.

    Data: use the average values of the indicator for each category in a given month.

    Additionally:

    Use a consistent chart style

    If possible, add a trend line for each category to show the dynamics of change.

    Once the generation of charts is complete, present them in separate graphics or as a visual report.”

    It took me and chat some time to arrive at a version of the chart that would be readable to the “common man.” Initially, it created visualizations that resembled spider webs and were consequently useless. The traversed prompt is a version that takes into account the entire path leading to a good chart.

    Tips:

    • Specify exactly: metrics, scope of the chart, method of visualization, criteria.

    Conclusion

    Chatbots can greatly improve work in the area of web analytics, including with Google Analytics 4, by automating repetitive tasks and providing quick analysis.

    All of the tasks that the GPT chatbot performed were, of course, possible without its support. However, they would have required more time and in some cases knowledge (e.g., forecasting models).

    The usefulness of chatbots depends on proper preparation of data, precision of queries and validation of results. These are tools that support specialists, but do not replace their knowledge and experience.

    To learn more tips and tricks in your daily marketer tasks, visit Bluerank website.

    Try this next article:
    Harnessing the power of server-side conversions in Google Ads
    All articles

    More from Bluerank:
    mentoring
    Company-wide mentoring program supported by Mentiway
    How Bluerank client “Rainbow Tours” achieved high-value outcomes with Microsoft Advertising?
    cooperation with performance agency
    Cooperation with a performance agency in 2024: Key trends and billing models