Generative AI
Generative AI
Ai
Machine learning inside ai
Deep learning inside machine learning
Generative ai inside deep learning
Using a forming database and entering a prompt, then this kind of applications can generate
content (text, audios, images…).
We insert a prompt and we ask the machine to do something with the text. And then base on
that we might get some results.
General ai uses neural networks, and deep learning techniques (a lot of layers of neurons).
The more layers, and the more neurons the better the performance.
Multimodal Large language models (MLLM): they can produce whatever we want besides
text (compositions, videos, photos…). You can not only produce text (chatGPT 4.0).
Generative Adversarial Networks (GAN). How do they work? We have a generator and a
discriminator. Inside we have deep learning neural networks. We put random examples so
the generator can create some data and the discriminator compares the random data with
real data, if they are not the same they are able to update the data they have so that they
are similar.
Initially we have random weights and the faces we generate will be very different to the real
faces. The machine will learn from error to adjust the correct weighs with the algorithm called
backpropagation so that the faces are more similar. Thanks to the discriminator the
generator will be able to create faces that are similar to real faces.
Large language models (LLM) are able to understand the patterns of the text. They use a
transformer: a mathematical function where we use algebra and matrices to calculate
probabilities.
They are able to predict the next word.
When we work with words we need to embed these words into vectors (multidimensional
vectors which are huge). The neural networks only function with numbers. The number
behind the networks take into account the context and the position in a sentence and if a
word is a pronoun, substantive, verb…
LLM use the attention mechanism. Based on the context they are able to give more weight
on one part than the other. They use probability to guess the next word.
To train these language models they needed to take billions of data. Then they realized that
the machine was not able to produce right answers. To avoid that they took humans with
questions and answers to adjust the answers of the large language model.
From this point we have a machine (LLM) which is a generic language model (it can do a lot
of things). To apply it on a company you have three options:
- Use chat gpt or others as they are
- We can also customize these tools using prompt engineering (how we write the text
to have the answers we want)
- We can take a pre-trained gpt and then we introduce information from a company.
Then we are able to change some of the weights of the model. A gpt is based on
neural networks so if we introduce info about our company, then we can customize
these gpts to make specific tasks for the companies. This is what’s called fine tuning.
WE CANNOT DO IT WITH CHAT GPT, but we have open source large language
models. You can download them and retrain them (llama from meta).
- You can build them from scratch
SLM is Small Language Models. They are very specific, specific tasks. Phi is a new one.
They have less parameters. You can now substitute someone with an SLM
Generative AI can change the way we work today. We can use them as machines to have
more expertise. We can use these machines to establish better relations with
customers/suppliers…