Generative AI presentation for beginners (45 minutes)
This column did not post an article last week for the first time since 15 November last year. I would have loved a no-week-missed year and was working towards that. I was glad to watch kid’s videos with my son that teach how it is quite possible for things to go against the plan. I love the 2019 Bollywood movie Chhichhore, in which Anni tries to throw the ball into the basketball goal, but it bounces back from the hoop. They lose the match. H3 Hostel won the game. But they cheered H4 Hostel for their team spirit and perseverance. A less than perfect ending. Quite frequent and relatable. On lines like the above, I might not be able to give you the best (or the only) outline for a 45-minute presentation on Generative AI. You decide.
First, The Generative AI Revolution. If the Generative AI hype is based on truth, is it still hype? Talk about my convoluted thoughts. Generative AI generates content in the form of text, audio, music, images, and videos. It has applications in every function and every industry. The impact is in how we work, write our job descriptions and the expectations from a role in an organisation. There is a myriad of use cases to explore. The list of use cases is limited only by our imagination.
Second, Insights into the Creation of the Training Dataset. The training dataset for building an LLM is created by taking each word of a part of the sentence as an input variable and the subsequent word as the output variable. The model generates by predicting the next word. In a standard multiclass classification ML problem, the word with the highest probability of occurrence should be picked. However, selecting the topmost word every time would cause the loss of creativity of LLMs. Hence, quite often, we go further down.
Third, Is Gen AI Supervised Learning? Taking the online content as input and generating the LLM’s output makes it an unsupervised model. However, as we look deeper, we see that the actual LLM is created as a supervised model, as explained in the above section.
Fourth, Three Ways of Using an LLM. We can use a foundational LLM as it is, fine-tune it to create our domain-specific LLM or use RAG with a foundational LLM to contextualise the response. The second and third approaches can also be used in combination.
Fifth, LLM-based Application. The application we build using LLMs generally leverages the natural language understanding and generation capabilities of the LLMs. There are configuration files storing details of the LLM and its parameters. It would also require creating the most effective prompt (prompt engineering) and parsing the response into a consumable format. The application would often use agents and third-party tools to carry out specialised tasks requested by the user.
Sixth, Challenges with LLMs. Working with LLMs is not a bed of roses. Challenges include hallucinations, a lack of computation capability, inaccurate answers to fact-based questions, a cut-off date of knowledge, token limits, inaccurate code generation, a threat to data privacy and intellectual property ownership, a threat to ethics, job losses, and a lack of talent available to work with LLMs, to name a few.
Seventh, Best Practices for Developing with LLMs. The developer must incorporate effective prompting techniques that will help get the most contextual response in the most consumable format with an optimised number of tokens. One must optimise the number of calls made to the LLM during experimentation by using stubs and drivers. The design of the application should not enforce unnecessary usage of the LLM. The trade-off between getting an LLM to do a task and writing a piece of code to do the task should be respected.
Eighth, A Learning Pathway. The fundamentals of supervised and unsupervised learning in ML hold good for LLMs. The fundamentals of statistics matter as well. One cannot be on the tenth step by starting on the tenth. The journey must cover deep learning through artificial neural networks. Fluency with data, vector databases, and data exploration go a long way in making the trip exciting and possible.
Now, let’s move on to the Q&A. We have 15 minutes left. Who goes first?
Disclaimer
Views expressed above are the author’s own.
END OF ARTICLE