Main

Introduction to Generative AI

Enroll in this course on Google Cloud Skills Boost → https://goo.gle/3MdGgHs What is Generative AI and how does it work? What are common applications for Generative AI? Watch this video to learn all about Generative AI, including common applications, model types, and the fundamentals for how to use it. Subscribe to Google Cloud Tech → https://goo.gle/GoogleCloudTech

Google Cloud Tech

9 months ago

hello and welcome to introduction to generative AI my name is Dr Gwendolyn Stripling and I am the artificial intelligence technical curriculum developer here at Google Cloud in this course you learn to Define generative AI explain how generative AI Works describe generative AI model types and describe generative AI applications generative AI is a type of artificial intelligence technology that can produce various types of content including text imagery audio and synthetic data but what is artifi
cial intelligence well since we are going to explore generative artificial intelligence let's provide a bit of context so two very common questions asked are what is artificial intelligence and what is the difference between Ai and machine learning one way to think about it is that AI is a discipline like like physics for example AI is a branch of computer science that deals with the creation of intelligent agents which are systems that can reason and learn and act autonomously essentially AI ha
s to do with the theory and methods to build machines that think and act like humans in this discipline we have machine learning which is a subfield of AI it is a program or system that trains a model from input data the trained model can make useful predictions from new or never before seen data drawn from the same one used to train the model machine learning gives the computer the ability to learn without explicit programming two of the most common classes of machine learning models are unsupe
rvised and supervised ml models the key difference between the two is that with supervised models we have labels labeled data is data that comes with a tag like a name a type or a number unlabeled data is data that comes with no tag this graph is an example of the sort of problem that a supervised model might try to solve for example let's say you are the owner of a restaurant you have historical data of the bill amount and how much different people tipped based on order type whether it was pick
ed up or delivered in supervised learning the the model learns from past examples to predict future values in in this case tips so here the model uses the total bill amount to predict the future chip amount based on whether an order was picked up or delivered this is an example of the sort of problem that an unsupervised model might try to solve so here you want to look at tenure and income and then group or cluster employees to see whether someone is on The Fast Track unsupervised problems are
all about discovery about looking at the raw data and seeing if it naturally falls into groups let's get a little deeper and show this graphically as understanding these concepts are the foundation for your understanding of generative AI in supervised learning testing data values or X are input into the model the model outputs a prediction and Compares that prediction to the training data used to train the model if the predicted test data values and actual training data values are far apart that
's called error and the model tries to reduce this error until the predicted and actual values are closer together this is a classic optimization problem now that we've explored a difference between artificial intelligence and machine learning and supervised and unsupervised learning let's briefly explore where deep learning fits as a subset of machine learning methods while machine learning is a broad field that encompasses many different techniques deep learning is a type of machine learning t
hat uses artificial neural networks allowing them to process more complex patterns than machine learning artificial neural networks are inspired by the human brain they are made up of many interconnected nodes or neurons that can learn to perform tasks by processing data and making predictions deep learning models typically have many layers of neurons which allows them to learn more complex patterns than traditional machine learning models and neural networks can use both label and unlabeled dat
a this is called semi-supervised learning and semi-supervised learning a neural network is trained on a small movement of labeled data and a large amount of unlabeled data the label data helps the neural network to learn the basic concepts of the task while the unlabeled data helps the neural network to generalize to new examples now we finally get to where generative AI fits into this AI discipline gin AI is a subset of deep learning which means it uses artificial neural networks can process bo
th labeled and unlabeled data using supervised unsupervised and semi-supervised methods large language models are also a subset of deep learning deep learning models or machine learning models in general can be divided into two types generative and discriminative a discriminative model is a type of model that is used to classify or predict labels for data points discriminative models are typically trained on a data set of labeled data points and they learn the relationship between the features o
f the data points and the labels once a discriminative model is trained it can be used to predict the label for new data points a generative model generates new data instances based on a learned probability distribution of existing data thus generative models generate new content take this example here the discriminative model learns the conditional probability distribution or the probability of Y our output given X our input that this is a dog and classifies it as a dog and not a cat the genera
tive model learns The Joint probability distribution or the probability of X and Y N predicts the conditional probability that this is a dog and can then generate a picture of a dog so to summarize generative models can generate new data instances while discriminative models discriminate between different kinds of data instances the top image shows a traditional machine learning model which attempts to learn the relationship between the data and the label or what you want to predict the bottom i
mage shows a generative AI model which attempts to learn patterns on content so that it can generate new content a good way to distinguish what is Jin Ai and what is not is shown in this illustration it is not gen AI when the output or Y or a label is a number or a class for example spam or not spam or a probability it is Gen AI when the output is natural language like speech or text an image or audio for example visualizing this mathematically would look like this if you haven't seen this for a
while the Y is equal to f of x equation calculates the dependent output of a process given different inputs the y stands for the model output the F embodies the function used in the calculation and the X represents the input or inputs used for the formula so the model output is a function of all the inputs if the Y is a number like predicted sales it is not gen AI if Y is a sentence like Define sales it is generative as the question would elicit a text response the response would be based on al
l the massive large data the model was already trained on to summarize at a high level the traditional classical supervised and unsupervised learning process takes training code and label data to build a model depending on the use case or problem the model can give you a prediction it can classify something or cluster something we use this example to show you how much more robust the gmai process is the Gemini process can take training code label data and unlabel data of all data types and build
a foundation model the foundation model can then generate new content for example text code images audio video Etc we've come a long way from traditional programming to neural networks to generative models in traditional programming we used to have to hard code the rules for distinguishing a cap the type animal legs 4. here's two for yes likes yarn and catnip in the wave of neural networks we could give the network pictures of cats and dogs and ask is this a cat and it would predict a cat in th
e generative wave we as users can generate our own content whether it be text images audio video etc for example models like Palm or Pathways language model or Lambda language model for dialogue applications in just very very large data from the multiple sources across the internet and build foundational language models we can use simply by asking a question whether typing it into a prompt or verbally talking into the prompt itself so when you ask it what's a cat it can give you everything it ha
s learned about a cat now we come to our formal definition what is generative AI jinayi is a type of artificial intelligence that creates new content based on what it has learned from existing content the process of learning from existing content is called training and results in the creation of a statistical model when given a prompt jnai uses the model to predict what an expected response might be and this generates new content essentially it learns the underlying structure of the data and can
then generate new samples that are similar to the data it was trained on has previously mentioned a generative language model can take what it is learned from the examples it's been shown and create something entirely new based on that information large language models are one type of generative AI since they generate novel combinations of text in the form of natural sounding language a generative image model takes an image as input and can output text another image or video for example under t
he output text you can get visual question answering while under output image and image completion is generated and under output video animation is generated a generative language model takes text as input and can output more text and image audio or decisions for example under the output text question answering is generated and under output image a video is generated we've stated that generative language models learn about patterns in language through training data then given some text they pred
ict what comes next thus generative language models are pattern matching systems they learn about patterns based on the data you provide here is an example based on things it's learned from its training data it offers predictions of how to complete this sentence I'm making a sandwich with peanut butter and jelly here is the same example using Bard which is trained on a massive amount of Text data and is able to communicate and generate human-like text in response to a wide range of prompts and q
uestions here is another example the meaning of life is and Bart gives you a contextual answer and then shows the highest probability response the power of generative AI comes from the use of Transformers Transformers produced a 2018 revolution in natural language processing at a high level a Transformer model consists of an encoder and decoder the encoder encodes the input sequence and passes it to the decoder which learns how to decode the representation for a relevant task in Transformers hal
lucinations are words or phrases that are generated by the model that are often nonsensical or grammatically incorrect hallucinations can be caused by a number of factors including the model is not trained on enough data or the model is trained on noisy or dirty data or the model is not given enough context or the model is not given enough constraints hallucinations can be a problem for Transformers because they can make the output text difficult to understand they can also make the model more l
ikely to generate incorrect or misleading information a prompt is a short piece of text that is given to the large language model as input and it can be used to control the output of the model in a variety of ways prompt designing is the process of creating a prompt that will generate the desired output from a lower language model as previously mentioned Jin AI depends a lot on the training data that you have fed into it and analyzes the patterns and structures of the input data and thus learns
but with access to a browser-based prompt you the user can generate your own content we've shown illustrations of the types of input based upon data here are the associated model types text to text well texted text models take a natural language input and produces a text output these models are trained to learn the mapping between a pair of text EG for example translation from one language to another text to image text to image models are trained on a large set of images each captioned with a sh
ort text description diffusion is one method used to achieve this text to video and text to 3D text to video models aim to generate a video representation from text input the input text can be anything from a single sentence to a full script and the output is a video that corresponds to the input text similarly texted 3D models generate three-dimensional objects that correspond to a user's text description for example this can be used in games or other 3D worlds text to task text to task models
are trained to perform a defined task or action based on text input this task can be a wide range of actions such as answering a question performing a search making a prediction or taking some sort of action for example a text to task model could be trained to navigate a web UI or make changes to a doc through the GUI a foundation model is a large AI model pre-trained on a vast quantity of data designed to be adapted or fine-tuned to a wide range of Downstream tasks such as sentiment analysis im
age captioning and object recognition Foundation models have the potential to revolutionize many Industries including Healthcare finance and customer service they can be used to detect fraud and provide personalized customer support vertex AI offers a model Garden that includes Foundation models the language Foundation models include Palm API for chat and text the vision Foundation models include stable diffusion which has been shown to be effective at generating high quality images from text de
scriptions let's say you have a use case where you need to gather sentiments about how your customers are feeling about your product or service you can use the classification task sentiment analysis task model for just that purpose and what if you needed to perform occupancy analytics there is a task model for your use case shown here are gen AI applications let's look at an example of code generation shown in the second block under code at the top in this example I've input a code file conversi
on problem converting from python to Json I use bar and I insert into the prompt box the following I have a pandas data frame with two columns one with the file name and one with the hour in which it is generated I'm trying to convert this into a Json file in the format shown on screen Bart Returns the steps I need to do this and the code snippet and here my output is in a Json format it gets better I happen to be using Google's free browser-based Jupiter notebook known as collab and I simply ex
port the python code to Google's collab to summarize barcode generation can help you debug your lines of source code explain your code to you line by line craft SQL queries for your database translate code from one language to another and generate documentation and tutorials for source code generative AI Studio lets you quickly explore and customize gnai models that you can leverage in your applications on Google Cloud generative AI Studio helps developers create and deploy gen AI models by prov
iding a variety of tools and resources that make it easy to get started for example there's a library of free trained models there is a tool for fine-tuning models there is a tool for deploying models to production and there is a community forum for developers to share ideas and collaborate generative AI app builder lets you create gen AI apps without having to write any code gen AI app builder has a drag and drop interface that makes it easy to design and build apps it has a visual editor that
makes it easy to create and edit app content it has a built-in search engine that allows users to search for information within the app and it has a conversational AI engine that helps users to interact with the app using natural language you can create your own digital assistants custom search engines knowledge bases training applications and much more Palm API lets you test and experiment with Google's large language models and gen AI tools to make prototyping quick and more accessible develop
ers can integrate Palm API with maker suite and use it to access the API using a graphical user interface the suite includes a number of different tools such as a model training tool a model deployment tool and a model monitoring tool the model training tool helps developers train ml models on their data using different algorithms the model deployment tool helps developers deploy ml models to production with a number of different deployment options the model monitoring tool helps developers moni
tor the performance of their ml models in production using a dashboard and a number of different metrics thank you for watching our course introduction to generative AI

Comments

@arunmanglick

This is one of the finest relating dots and completing a full circle.. AI, ML, DL and Generative AI.

@jakobzischka

The fact that this kind of education is available for free on the internet is one of the many advantages of the times we live in 🌱☀

@reshmaramesh222

This is the kind of education we are looking for. Thank you so much for this super simplified explanation.

@hargovindahirwar266

🎯 Key Takeaways for quick navigation: 00:00 📚 Introduction to Generative AI - Definition of generative AI and its applications. - Distinction between AI and machine learning, including supervised and unsupervised learning. - Introduction to deep learning and its connection to generative AI. 05:36 🧠 Deep Learning and Generative AI - Explanation of deep learning and its use of artificial neural networks. - Differentiating generative models from discriminative models. - Overview of how generative AI generates new content. 11:10 🔄 Generative AI Process and Models - The training process of generative AI and how it creates a statistical model. - Examples of generative language models and their capabilities. - The importance of prompt design in controlling model output. 16:23 💼 Gen AI Applications and Foundation Models - An overview of various applications of generative AI, including code generation. - Introduction to foundation models and their role in AI development. - Highlighting specific use cases for different task models. 20:05 🛠️ Tools for Generative AI Development - Introduction to Generative AI Studio and its tools for model development. - Information about Gen AI App Builder and its no-code app creation capabilities. - Overview of PaLM API and its integration with development tools. Made with HARPA AI

@fatemehcheginisalzmann2189

I am impressed with such a clear, informative, and simple explanation !!!

@sreeramch

Simple and Crisp in layman's terms. Thanks for making Data Science available to everyone.

@anantsharma5330

Whole design team has done fantastic work in this video.

@HassanRaza-yg6hl

Thank you for explaining this in a simple and easy way. Had to watch it in parts to process. The visuals really helped!

@koyeogundare1747

Quite fascinating. Great delivery and easy-to-follow concept. You made a complex topic interesting with a clear, unambiguous explanation. Thank you.

@dheer211

The difference between traditional ML and Gen AI is very well explained thank you 🙏

@kimstockfelt

Very good introduction, thank you! Spotted a distracting typo in one of the slides where it says "Speach" instead of "Speech", don't let it seep into the LLM's 😉

@antoniofilho8944

Thank you so much to the Google cloud team for this impressive explanation.

@hongbo-wei

Thank you Google for tech education. I'm a junior software engineer and I'll keep learning and sharping my skills. I'll try my best to land a software enigeering job in the Google! : )

@power_of_prompts

Clear and simple! Many thanks for sharing

@JesseTorres90266

Great tutorial. One of the most complete introductory videos I have come across.

@saskiastripling4885

I am so impressed! Keep up the great work! Such an informative video :)

@newtoro1

Outstanding presentation of the topic. Highly recommended. Makes me with I was more hands-on in development,

@atharvarai163

i was curious about it but didn't knew where to learn, thanks a lot!

@draungminoo6002

Thank you for making AI technology available to everyone. This is the kind of education I am looking for.

@Muuip

Great summary! Much appreciated!👍