End to End Machine Learning with AI First Colab
Key Takeaways
Demonstrates end-to-end machine learning with AI-First Colab using natural language prompts
Full Transcript
When you're building a predictive model, do you enjoy coming up with specific syntax for all these different data manipulation and machine learning libraries? Yeah, me neither. I'm Alok, a developer advocate here at Google Cloud. And today we're going to talk about how to simplify and accelerate your end-to-end machine learning journeys with AI first Colab. AI first Colab is your Jupyter notebook hosted in Google's cloud environment with an agentic collaborator that's designed to help you tackle your most challenging problems faster than ever. Colab runs in the browser with minimal setup and notebooks can be shared with others via Google Drive. You can also use strong computing resources like GPUs and TPUs for free. Powered by Gemini, Colab's AI companion is a coding agent that operates across your entire notebook, understanding your code and the state of your data at each step. Using Colab in this way is an iterative and collaborative experience. You are truly working with the agent. A typical machine learning journey in Colab consists of various steps like those you see here. Data ingestion and preparation, exploratory analysis and feature engineering, training a model or multiple models, evaluating those models, and finally making predictions. The good news is that this entire workflow can be performed autonomously with natural language in AI first Colab. To show this with a real-life example, let's move to a fun demo. Using some data on past Olympics games results from Kaggle, our goal is to predict the total medal count, gold plus silver plus bronze, for each country in the 2026 Winter Olympics. Domain knowledge and high-level ideas will come from us, but we'll let AI first Colab do the heavy lifting of writing and executing all the code. I'll start in an empty Colab notebook and go down to the toolbar at the bottom asking what can I help you build to start working with Gemini. The first thing I'm going to do is upload these two data files with Olympic results and hosts that I got from Kaggle. While those are being uploaded, I'm going to paste in my detailed prompt for the modeling task I'm looking for. It says, "Create a model to predict total medal counts for each country in the 2026 Winter Olympics. Use only data from Winter Olympics since 1992. Use each country's medal counts from the previous couple medal Winter Olympics to make predictions. Make sure to account for host country effects. Evaluate on a holdout test set of the most recent Winter Olympics. Make 2026 predictions for all countries that participated in 2022. And finally, there are 116 medal events in 2026, so make sure the country medal predictions add up to three times that number." That's a lot, but what I've given to Gemini is a type of instruction that I might give as a domain expert to a data scientist building such model. I'll send the prompt and let the agent get to work. Gemini eventually comes back with a plan, which I move over to the side panel for easier reading. It talks about loading the data, filtering and preparation, creating features including accounting for the host country effect, training the model, evaluating the model, making predictions for 2026 including adjustment I asked for, and finishing. This looks pretty good to me, so I click accept and auto run to let it do the whole thing. It now shows a checklist of the tasks from the plan, so they can follow along as they execute it within the notebook over here on the left. It takes a few moments to load the two CSV files into memory. Then it gets going with data preparation, filtering the data to only Winter Olympics since 1992, identifying host countries, and aggregating up total medals by country at each games. This is all without me having to worry about pandas merging, filtering, or aggregation syntax that I always seem to misremember. Next is feature engineering. Gemini puts in the logic to get each country's medal counts from the previous two games, which get added as previous medal count and previous previous medal count, which are expected to be key predictors in this model. >> We also see how Gemini adds an is host field to account for the host country effect as I had asked. It appears to identify the right countries based on the few examples we can see here. We move right into modeling where scikit-learn is used to perform linear regression. This is appropriate in this scenario with a continuous outcome variable like metal count and just a couple of predictors. Gemini is careful to hold out the 2022 Olympics in training for eval. Which happens almost immediately after on that holdout test set. We see that the mean absolute error on the test set is about 1.6 medals per country. Not bad for such a simple model that doesn't explicitly consider the individual sports, teams, or athletes. Gemini is now ready to generate predictions for 2026. It sets up the country-level data with previous medal counts and makes addiction initial medal predictions directly from the model as shown here. It then goes on to adjust those metal predictions based on the info that I provided at the beginning ensuring that the total predicted medal count adds up to 348. Gemini and Colab are finished executing that whole plan providing a summary that shows key findings, insights, and next steps. But we never got to see the main result, the projected 2026 Olympics medal table from top to bottom. No worries though, I had another quick prompt to Gemini asking it to produce that as an interactive plot. After working for a few seconds, we see the code to generate the plot using a library called Altair. I go ahead and run that and boom! We have an interactive plot with a projected medal table. We can hover over the bars to see Norway has the highest projection at 31 medals, followed by Germany, Canada, the US, and Italy, the host country in 2026. So, to recap, I started with just a data set and a high-level idea, and ended up with a full predicted medal table for the 2026 Winter Olympics a few minutes later, without having to write any code myself. That said, it's important to note that you also have access to the full code and output, so you can and should check, modify, and build on what AI first Colab provides. The best work will be done with you and the agent working together. To get started building your own models, open any new or existing notebook in Colab. Look for the Gemini Spark icon in the bottom toolbar. Start asking questions and giving commands, or click on one of the suggested prompts. I can't wait to see how AI first Colab transforms your machine learning workflow. Happy modeling.
Original Description
Ready to build machine learning models faster than ever? This video dives into end-to-end machine learning with AI-First Colab, your agentic coding partner powered by Gemini. You'll see a demo of how to execute the ML lifecycle using only natural language prompts, starting from raw data and ending with full prediction of 2026 Winter Olympics medal counts. Learn how to transform your development process by letting AI handle the heavy lifting for data preparation, model training, evaluation, and prediction, allowing you to focus on high-level strategy and direction. Start your next machine learning project with unprecedented speed and ease.
Resources:
Learn more → https://goo.gle/47Yq4DK
Subscribe to Google for Developers → https://goo.gle/developers
Products Mentioned: Google AI, Colab
Watch on YouTube ↗
(saves to browser)
Sign in to unlock AI tutor explanation · ⚡30
Playlist
Uploads from Google for Developers · Google for Developers · 0 of 60
← Previous
Next →
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
Developer Journey - Sunnyvale DSC Summit ‘19
Google for Developers
How Google is working with students - Sunnyvale DSC Summit ‘19
Google for Developers
Starting your career in the Cloud - Sunnyvale DSC Summit ‘19
Google for Developers
The Solution Challenge - Sunnyvale DSC Summit ‘19
Google for Developers
Firebase - Sunnyvale DSC Summit ‘19
Google for Developers
Cloud Hero - Sunnyvale DSC Summit ‘19
Google for Developers
Panel discussion - Sunnyvale DSC Summit ‘19
Google for Developers
The art of negotiation - Sunnyvale DSC Summit ‘19
Google for Developers
Courage to care, solve and share - Sunnyvale DSC Summit ‘19
Google for Developers
Version 9 of Angular, Glass Enterprise Edition 2, path to DX deprecation, & more!
Google for Developers
[DEPRECATING] Introducing a new series (Assistant for Developers Pro Tips)
Google for Developers
Detecting memory bugs with HWASan, Bazel 2.1, Next ‘20 session guide, & more!
Google for Developers
Why Podcast.app chose a .app domain name
Google for Developers
Machine Learning Bootcamp Jakarta 2019
Google for Developers
Android Studio 3.6, Android 11 Developer Preview, Kubeflow 1.0, & more!
Google for Developers
[DEPRECATING] Importance of community (Assistant on Air)
Google for Developers
Why the Flutter team switched from .io to a .dev domain name
Google for Developers
3 website-building tips from .dev creators
Google for Developers
Why NimbleDroid chose a .app domain name
Google for Developers
Android Platform Codelab, Bazel 2.2, Maps Android Utility Library v1.0, & more!
Google for Developers
Google for Games Developer Summit: A free, digital experience for game developers
Google for Developers
Inspecting Home Graph (Assistant for Developers Pro Tips)
Google for Developers
Google for Games Developer Summit Keynote
Google for Developers
Stadia Games & Entertainment presents: Keys to a great game pitch (Google Games Dev Summit)
Google for Developers
Empowering game developers with Stadia R&D (Google Games Dev Summit)
Google for Developers
Supercharging discoverability with Stadia (Google Games Dev Summit)
Google for Developers
Stadia Games & Entertainment presents: Creating for content creators (Google Games Dev Summit)
Google for Developers
Bringing Destiny to Stadia: A postmortem (Google Games Dev Summit)
Google for Developers
Live Captioning in Google Slides
Google for Developers
[DEPRECATING] User engagement for the Google Assistant
Google for Developers
TensorFlow Dev Summit ‘20, Google for Games Dev Summit, Cloud AI Platform Pipelines, & much more!
Google for Developers
Top 5 from the TensorFlow Dev Summit 2020
Google for Developers
Developer Student Clubs 2019 Turkey Leads Summit
Google for Developers
Building simpler payment experiences | Google Pay Plugin for Magento 2
Google for Developers
Become A Developer Student Club Lead
Google for Developers
Firebase Kotlin Extensions, ARM apps on the Android Emulator, Angular v9.1, & more!
Google for Developers
Test suite for Smart Home (Assistant for Developers Pro Tips)
Google for Developers
Google Play updates, Bazel 3.0, Business Console for Google Pay, & more!
Google for Developers
How to use error logs (Assistant for Developers Pro Tips)
Google for Developers
Contact Center AI, Android Studio 4.1 Canary 5, TensorFlow QAT API, & more!
Google for Developers
WebView DevTools, Kotlin meets gRPC, Flutter CodePen support, & more! (Episode 200)
Google for Developers
Offline handling for Smart Home (Assistant for Developers Pro Tips)
Google for Developers
Android 11 Dev Preview 3, Google Fonts for Flutter, Shielded VM, & more!
Google for Developers
Machine Learning Foundations: Ep #1 - What is ML?
Google for Developers
Flutter web support updates, BigQuery materialized views, Cloud Spanner emulator, & more!
Google for Developers
Computer vision by building a neural network with TensorFlow | Machine Learning Foundations
Google for Developers
Machine Learning Foundations: Ep #3 - Convolutions and pooling
Google for Developers
Android 11 Beta plans, Flutter 1.17, Dart 2.8, & much more!
Google for Developers
Machine Learning Foundations: Ep #4 - Coding with Convolutional Neural Networks
Google for Developers
Google Developers ML Summit
Google for Developers
Real-world image classification using convolutional neural networks | Machine Learning Foundations
Google for Developers
Adobe XD support for Flutter, Architecture Framework, temporary closures with Places API, & more!
Google for Developers
Machine Learning Foundations: Ep #6 - Convolutional cats and dogs
Google for Developers
Machine Learning Foundations: Ep #7 - Image augmentation and overfitting
Google for Developers
Announcing Firebase Live, Flutter Day, Java 11 on Google Cloud Functions, & more!
Google for Developers
Machine Learning Foundations: Ep #8 - Tokenization for Natural Language Processing
Google for Developers
Android 11 Beta, Google Play Asset Delivery, Firebase Crashlytics SDK, & much more!
Google for Developers
Natural Language Processing: Using sequencing APIs in TensorFlow | Machine Learning Foundations
Google for Developers
Build a sarcasm classifier using NLP and TensorFlow | Machine Learning Foundations
Google for Developers
AR Realism with the ARCore Depth API
Google for Developers
More on: AI Pair Programming
View skill →Related Reads
📰
📰
📰
📰
CLI Ownership Management: master, owner, and session Commands for Self-Hosted Wallets
Dev.to AI
Our drift-warning hook was silently dead for 23 days. Zero warnings looked exactly like good behavior.
Dev.to AI
Automate AI Workflows with Qualcomm AI Runtime
Dev.to · Gate of AI
Add a rate-limit backstop to your agent's email sending
Dev.to · Qasim
🎓
Tutor Explanation
DeepCamp AI