Tuesday, January 07, 2025

Generative AI @ AWS

 What is Generative AI? - Gen AI Explained - AWS

Generative AI - Digital and Classroom Training | AWS

Diffusion models

...create new data by iteratively making controlled random changes to an initial data sample.
They start with the original data and add subtle changes (noise),
progressively making it less similar to the original.
This noise is carefully controlled to ensure the generated data remains coherent and realistic.

After adding noise over several iterations, the diffusion model reverses the process.
Reverse denoising gradually removes the noise
to produce a new data sample that resembles the original.
...work by training two neural networks in a competitive manner.
The first network, known as the generator, generates fake data samples by adding random noise.
The second network called the discriminator, tries to distinguish between real data and the fake data produced by the generator.

During training, the generator continually improves its ability to create realistic data while the discriminator becomes better at telling real from fake.
This adversarial process continues until the generator produces data that is so convincing that the discriminator can't differentiate it from real data.

GANs are widely used in generating realistic images, style transfer, and data augmentation tasks.

Variational autoencoders (VAEs)

...learn a compact representation of data called latent space.
The latent space is a mathematical representation of the data.
You can think of it as a unique code representing the data based on all its attributes. 
For example, if studying faces, the latent space contains numbers representing eye shape, nose shape, cheekbones, and ears.

VAEs use two neural networks—the encoder and the decoder. 

The encoder neural network maps the input data to a mean and variance for each dimension of the latent space. It generates a random sample from a Gaussian (normal) distribution. This sample is a point in the latent space and represents a compressed, simplified version of the input data.

The decoder neural network takes this sampled point from the latent space and reconstructs it back into data that resembles the original input. Mathematical functions are used to measure how well the reconstructed data matches the original data.


Transformer-based models

...builds upon the encoder and decoder concepts of VAEs. Transformer-based models add more layers to the encoder to improve performance on text-based tasks like comprehension, translation, and creative writing.

Transformer-based models use a self-attention mechanism.
They weigh the importance of different parts of an input sequence when processing each element in the sequence.

Another key feature is that these AI models implement contextual embeddings. The encoding of a sequence element depends not only on the element itself but also on its context within the sequence.






Amazon Bedrock is a fully-managed service that offers a choice of high-performing foundation models (FMs) from leading AI companies, along with a broad set of features to build generative artificial intelligence (generative AI) applications. Amazon Bedrock Titan foundation models are a family of FMs pre-trained by AWS on large datasets. They are powerful, general-purpose models built to support a variety of use cases. Use them as is or customize them with your own data.

No comments: