Generative AI use case: Generate content for personalized marketing campaigns

Last reviewed 2026-09-04 UTC

This document provides a high-level architecture for an application that uses AI to generate content for personalized marketing campaigns.

The intended audience for this document includes architects, developers, and administrators who build and manage generative AI applications in the cloud for the media and marketing industries. The document assumes that you have a foundational understanding of generative AI.

The Deployment section of this document provides links to code samples to help you experiment with deploying generative AI applications for marketing use cases.

Architecture

The following diagram shows an architecture for an application in Google Cloud that processes user data to generate media assets for personalized marketing campaigns.

Architecture for a generative AI application that generates personalized marketing campaigns. Architecture for an application that uses AI to generate personalized marketing campaigns.

The architecture shows the following flows:

  • Ingest and process user data:

    1. User data from sources within Google Cloud and from external sources is uploaded to BigQuery.
    2. A Dataflow pipeline processes the uploaded data and derives marketing insights, such as demographic profiles, interests, and purchasing patterns.
    3. Eventarc triggers a Cloud Run service.
    4. The Cloud Run service sends the marketing insights to Gemini Enterprise Agent Platform, with a prompt to generate personalized media assets for marketing campaigns.
    5. For each user, the Gemini model on Agent Platform generates audio, video, and text content for online marketing campaigns.
    6. The Cloud Run service uploads the generated content to a content-server bucket in Cloud Storage.
  • Serve marketing content:

    When users visit the company web portal (hosted on Cloud Run), the portal service does the following:

    1. Retrieves user-specific marketing content from the Cloud Storage content server.
    2. Displays the marketing content on the web pages that users visit.

To improve the quality of the content that's generated, consider the following adjustments to the architecture:

  • Build a feedback loop that enables the model to learn from the impact of the marketing campaigns.
  • Include a human review step before generated content is uploaded to Cloud Storage to verify that the content aligns with safety guidelines and brand standards.

Products used

This example architecture uses the following Google Cloud products:

  • Cloud Run: A serverless compute platform that lets you run containers directly on top of Google's scalable infrastructure.
  • Gemini Enterprise Agent Platform: A comprehensive platform that lets you build, scale, govern, and optimize enterprise‑grade AI agents.
  • BigQuery: An enterprise data warehouse that helps you manage and analyze your data with built-in features like machine learning, geospatial analysis, and business intelligence.
  • Dataflow: A service that provides unified stream and batch data processing at scale.
  • Eventarc: A serverless solution to asynchronously route messages triggered by events.
  • Cloud Storage: A low-cost, no-limit object store for diverse data types. Data can be accessed from within and outside Google Cloud, and it's replicated across locations for redundancy.

Deployment

The Generative AI for Marketing repository in GitHub includes code samples that you can use to experiment with deploying generative AI applications for marketing use cases.

What's next

Contributors

Author: Kumar Dhanagopal | Cross-Product Solution Developer

Other contributors: