Table of Contents

Exploring the World of Generative AI with Google's Vertex AI

Artificial Intelligence (AI) has taken remarkable strides in recent years, and one of the most intriguing facets of this technology is Generative AI. With the advent of Google's Vertex AI, the world of Generative AI has received a powerful new tool. In this blog, we will delve into Generative AI and Discriminative AI, highlighting how Vertex AI can be harnessed to unlock creative and innovative applications.

Understanding Generative AI and Discriminative AI

Generative AI and Discriminative AI represent two distinct paradigms within the realm of artificial intelligence. Generative AI models aim to create new data, often from scratch, that closely resembles the patterns and structures found in the training data. These models can be thought of as creative engines that generate content such as images, text, audio, and more. They are particularly valuable for tasks like image synthesis, text generation, and even art creation. Examples of Generative AI models include Generative Adversarial Networks (GANs), Variational Autoencoders (VAEs), and Transformer-based language models like GPT-3.5/4
On the other hand, Discriminative AI models focus on distinguishing and classifying data into predefined categories or making predictions based on existing patterns in the data. These models are highly suited for tasks like image classification, sentiment analysis, and natural language understanding. Common examples of Discriminative AI models include Convolutional Neural Networks (CNNs) for image classification and Recurrent Neural Networks (RNNs) for sequential data analysis.

The Power of Vertex AI in Generative AI

Google's Vertex AI is a comprehensive machine learning platform that provides a wide range of tools and services to build, deploy, and manage AI models. When it comes to Generative AI, Vertex AI offers several features that make it a game-changer:

Screenshot 2023-10-02 at 3.37.43 PM

 

  • Pre-built Models: Vertex AI comes equipped with pre-trained models for various tasks, including image generation, text generation, and language translation. These models can be fine-tuned for specific applications, saving developers significant time and effort.
  • Scalability: Vertex AI leverages Google Cloud's powerful infrastructure, allowing users to scale their Generative AI models effortlessly. This scalability is crucial for handling large datasets and high-demand applications.
  • Training Pipelines: Vertex AI simplifies the process of training Generative AI models by providing end-to-end training pipelines. Users can efficiently manage data, experiment with hyperparameters, and track model performance through a user-friendly interface.
  • Integration with GANs: Generative Adversarial Networks (GANs) are a popular choice for Generative AI tasks, and Vertex AI supports GANs seamlessly. This integration enables developers to create, train, and deploy GANs with ease.
  • Model Deployment: Once a Generative AI model is trained, Vertex AI offers simple deployment options, allowing developers to serve their models via APIs for real-time inference or batch processing.

Applications of Vertex AI in Generative AI

The combination of Generative AI and Vertex AI opens up a world of possibilities. Here are some exciting applications:

  • Content Generation: Vertex AI can be used to create high-quality images, and realistic text, and even generate entire web pages, making it an invaluable tool for content creators and web developers.
  • Art and Design: Artists can use Vertex AI to generate unique pieces of art or assist in the creative process by providing inspiration and generating design ideas.
  • Language Translation: Vertex AI's language models can be utilized for translating text between languages, making it easier for businesses to engage with a global audience.
  • Data Augmentation: In data science and machine learning, Vertex AI can augment datasets by generating synthetic data, improving model robustness and performance.

Case Study: Generating Medical Summaries with Google Vertex AI's LLM Model – PaLM2

Let's explore this use case to understand how to use the LLM model text-bison@001 for content generation.

Here's how we can achieve it using Vertex AI:
Step 1:  Log in to Vertex AI and select the Language menu under Generate AI Studio

Screenshot 2023-10-02 at 3.41.49 PM

Step 2:   Select +CREATE PROMPT, it opens up the Prompt page where you provide the required prompt and it will provide the response.  

Here is the prompt I have used in the below

Screenshot 2023-10-02 at 3.43.22 PM

Here we have used the PaLM2 model named “text-bison@001” along with other hyperparameters Temperature, Token Limit, Top-K, Top-P, and Max response.

Screenshot 2023-10-02 at 3.44.01 PM

Step 3: Click the SUBMIT button on the right side, which will provide the response.

Response: In accordance with the preceding prompt, the text-bison@001 model has produced a medical summary utilizing the JSON data supplied within the prompt. 

The preceding case study was conducted in Vertex AI Studio without any coding efforts. The following demonstrates how to accomplish the same task using Python code.

Python(Using Colab)

Step 1:  Install the package

Screenshot 2023-10-02 at 3.45.35 PM

Step 2: Authenticate the user

Screenshot 2023-10-02 at 3.46.09 PM

Step 3: Set the Project ID and Location 

Screenshot 2023-10-02 at 3.46.37 PM

Step 4: Initialize with aiplatform 

Screenshot 2023-10-02 at 3.47.13 PM

Step 5: Initialize a text generation model using the "text-bison@001" pre-trained model from Google Vertex AI for text generation tasks

Screenshot 2023-10-02 at 3.47.49 PM

Step 6: Provide your JSON data from your business case (below is not a full JSON, just a sample)

Screenshot 2023-10-02 at 3.48.23 PM

Step 7: Fine-tuning generation settings: lower temperature, maximum output tokens, top-k tokens, and top-p probability

Screenshot 2023-10-02 at 3.48.56 PM

Response:  Here is the response

Screenshot 2023-10-02 at 3.49.34 PM

Key Takeaways

Generative AI and Discriminative AI are two essential paradigms within the field of artificial intelligence, each serving its own unique set of applications. With Google's Vertex AI, developers now have a powerful platform to explore the creative potential of Generative AI. Whether you're interested in content generation, art, translation, or data augmentation, Vertex AI provides the tools and infrastructure to turn your ideas into reality. As we continue to unlock the capabilities of Generative AI, the possibilities are limited only by our imagination.

About Encora

Fast-growing tech companies partner with Encora to outsource product development and drive growth. Contact us to learn more about our software engineering capabilities.

Learn More about Encora

We are the software development company fiercely committed and uniquely equipped to enable companies to do what they can’t do now.

Learn More

Global Delivery

READ MORE

Careers

READ MORE

Industries

READ MORE

Related Insights

Online Travel Agencies: Some Solutions to changes in booking and commission attributions

Discover how we can simplify travel changes for both travelers and OTAs using blockchain and ...

Read More

The AI-Powered Journey: How AI is Changing the Face of Travel

As travel elevates itself into an experience where every journey is as unique as the travelers ...

Read More

Enhancing Operational Excellence with AI: A Game-Changer for the Hospitality Industry

By AI, the hospitality industry can offer the best of both worlds: the efficiency and ...

Read More
Previous Previous
Next

Accelerate Your Path
to Market Leadership 

Encora logo

Santa Clara, CA

+1 669-236-2674

letstalk@encora.com

Innovation Acceleration

Speak With an Expert

Encora logo

Santa Clara, CA

+1 (480) 991 3635

letstalk@encora.com

Innovation Acceleration