Skip to main content
Version: v1.6.0-dev19 🚧

Tutorial 6: Model development and preparation with Enterprise h2oGPTe-agents

Overview​

This tutorial explores model development and preparation with Enterprise h2oGPTe-agents. In this tutorial, we will ask an Enterprise h2oGPTe-agent the following:

Create a regression model to predict housing prices. Use the renowned "Boston Housing Dataset." The target column should be the "MEDV" column. Generate the model and make it accessible in the "Downloadable files" section.

The Boston Housing Dataset is a well-known dataset used primarily for practicing regression techniques in machine learning. It contains information about various features of Boston's housing, which can be used to predict housing prices.

Enterprise h2pGPTe-agents enhance the functionality and versatility of Enterprise h2oGPTe to execute a broader range of tasks autonomously. In other words, this setting allows the LLM to perform actions such as running code, generating plots, searching the web, conducting research, and developing and preparing Machine Learning (ML) models.

Objectives​

  • Model development and preparation: Explore how Enterprise h2oGPTe can help you develop and prepare ML models.
  • Understand the role of agents in Enterprise h2oGPTe: Explore the differences between enabling and disabling agents in Enterprise h2oGPTe and how this affects the system's capabilities during a user query.

Prerequisites​

Step 1: Create a new Chat with an agent enabled​

  1. On Enterprise h2oGPTe, click + New chat.
  2. Click the Configuration tab.
  3. Click the Use Agent toggle to the On position. Use agent

Step 2: Enter query​

  1. In the Ask anything box, enter the following query:

    Create a regression model to predict housing prices. Use the renowned 
    "Boston Housing Dataset." The target column should be the "MEDV" column.
    Generate the model and make it accessible in the "Downloadable files" section.

    You can access the dataset here:
    https://www.kaggle.com/code/prasadperera/the-boston-housing-dataset
    note

    You do not need to specify the dataset, as Enterprise h2oGPTe-agents can search the web for a copy of the dataset.

  2. Click Submit.

Prompt

With the agent enabled, Enterprise h2oGPTe can create a model using Python and generate plots and charts highlighting the model and its important features. Enabling agents in Enterprise h2oGPTe expands the toolkit, allowing you to achieve more practical and interactive results.

When the agent is disabled, Enterprise h2oGPTe provides a text explanation of how to build a model using code while unable to perform the development or generate a model directly.

Step 3: Observe results​

caution

Your downloadable files might differ from those discussed here.

After a few seconds or minutes, Enterprise h2pGPTe generates a query result along with an example demonstration (explanation) on how to use the built model (boston_housing_model.joblib, boston_housing_model.py), which can be found in the Downloadable files section.

Downloadable files

The Downloadable files section also includes the following scatter plot and chart (improved_boston_housing_visualizations.png):

Scatter plot and chart

The scatter plot compares the actual housing prices with predicted prices, while the horizontal bar chart displays the model's feature importance.

Summary​

This tutorial explored the differences between enabling and disabling agents in Enterprise h2oGPTe. Also, we learned that Enterprise h2oGPTe-agents can build or prepare ML models. Lastly, we also learned that Enterprise h2oGPTe can explain the built model with graphs or textual explanations.


Feedback