Help Center

Updating AI Workbench notebooks for the Q4-2024 Release

AI Workbench enhancements and updates

With the Q4-2024 BlueConic release (Release 94) in October 2024, two key AI Workbench technologies have been upgraded to enhance security and usability:

  • Upgrade to support Jupyter Notebook 7
  • Upgrade from Python 3.9 to Python 3.11

Jupyter Notebook 7 improvements

Upgrading to Jupyter Notebook 7 offers several important benefits for Python developers:

  • Simplified and more intuitive user interface.
  • Improved support for keyboard navigation and screen readers.
  • New menu options for editing, viewing, and running Python code in AI Workbench notebooks. 
  • Additional Markdown rendering options are available in the Markdown menu, including better rendering of tables, code blocks, and LaTeX.

Updating AI Workbench notebooks 

Existing AI Workbench notebooks will run as before but with an improved notebook user interface and enhanced security and usability. Python developers will benefit from better error highlighting and enhanced code navigation features. However, this release of AI Workbench may require changes to your notebook code to upgrade the Python library packages called in your notebooks.

Check for required package versions in your Python notebook code

Whether you need to update your notebook code depends on the Python library packages used in your notebook code. BlueConic users whose user role includes notebook editing access can check the notebook code and update package dependencies if needed.

  1. In order to update package dependencies, first verify that your user role has Notebook editor permissions in AI Workbench. You can check your Account Settings to determine your user role.
    If you do not have the permissions to view or edit notebook code, contact the BlueConic administrator at your site for assistance.
  2. Update the package versions used in your code to meet the version requirements in the table below, and Save your changes. For example, in an existing RFM notebook, you would change
%pip install -q matplotlib==3.5.1 numpy==1.22.1 pyarrow==15.0.0 pytz==2021.3 ipytest==0.13.1 python-dateutil==2.8.2

to

%pip install -q matplotlib==3.5.1 numpy==1.26.4 pyarrow==15.0.0 pytz==2021.3 ipytest==0.13.3

AI Workbench notebook Python updates2.png

Python library packages: Minimum version requirements

For the current platform release, your AI Workbench Python notebooks must be updated for the following minimum package dependencies:

PIP Packages Used in Notebook Code Minimum Required Versions
(updated October 4, 2024)
boto3 1.34.0
ipytest 0.13.3
matplotlib 3.7.1
numpy** 1.23.2
onnx 1.13.0
onnxoptimizer 0.3.13
onnxruntime 1.15.0
pandas** 1.5.1
scikit-learn 1.2.0
scipy 1.10.0
shapely 1.8.5
sklearn Replaced with scikit-learn
skl2onnx 1.17

More information about Python dependencies

**Version note about pandas and numpy dependencies

Updated October 4, 2024: If you have previously used pandas==1.5.1 without pinning a specific version of numpy, please ensure that you install a compatible version of numpy by specifying it explicitly:

%pip install pandas==1.5.1 'numpy<2.0'

Alternatively, you can update to the latest version of pandas that handles numpy dependencies correctly:

%pip install pandas==2.1.2

Remove the ipywidgets library package

To migrate your notebooks for the newest release of AI Workbench, you must remove the ipywidgets library package from the pip install. 

Remove the python-dateutil library package

To migrate your notebooks for the newest release of AI Workbench, you must remove the python-dateutil library package from the pip install in your notebook code. The package will be installed by default.

Update standard, out-of-the-box BlueConic AI notebooks

The easiest way to update an existing BlueConic AI notebook (for example, the CLV or RFM notebook) is to download the newer version and copy over your configuration or customizations to the new version. Contact BlueConic Support if you have questions on how to proceed.

Update your custom AI notebooks

To update your own custom AI notebooks, follow these steps:

  1. Open the notebook editor in AI Workbench to assess whether your notebooks are calling the most up-to-date packages. Use the table above or the Python dependencies page to find the correct versions.
  2. Change sklearn to scikit-learn and upgrade to at least the recommended version (may also involve changing some other code in the notebook, depending on your custom code).
  3. Remove ipywidgets and python-dateutil from the pip install line.
  4. Go through all the packages in the pip install line to ensure the versions are compatible with those in the table above.
  5. Save your changes and run the notebook.
  6. Check for errors in the notebook's run history to see if there are additional updates or fixes required  based on your custom implementation.

FAQ: Updating pip packages in AI Workbench notebooks

Q: Why are these changes necessary?

A: Newer versions of these packages include performance improvements, security patches, and bug fixes that are important for the stability of your notebooks.

Q: Are these changes required?

A: Yes, in order to run your AI Workbench notebook code as of October 2024, the packages called in your notebook code must meet the version requirements outlined above.

Q: When will my BlueConic server be updated?

A: Visit status.blueconic.com for current status updates for the BlueConic platform. This page is updated continually and announces major updates to the BlueConic platform.

Q: What will happen to notebooks still calling older, unsupported package versions?

A: Any notebook calling older, unsupported packages will not run successful and will throw an error. Check the AI Workbench run history for your notebook for errors.
For example, if your notebook code calls unsupported libraries in this way:

!pip install -q lifetimes==0.11.3 scikit-learn==1.3.0 matplotlib==3.8.3 pandas==2.0.2 ipytest==0.13.3 scipy==1.10.1 numpy==1.24.4

The notebook run history will show an error: 

ERROR: Cannot install numpy==1.24.4 because these package versions have conflicting dependencies.
ERROR: ResolutionImpossible: for help visit
https://pip.pypa.io/en/latest/topics/dependency-resolution/#dealing-with-dependency-conflicts

Q: How can I check if a notebook needs to be updated?

A: There are two ways check:

  1. You can examine the Run history for an AI Workbench notebook to check for errors, as shown above.
  2. Or, if your user role has notebook editor privileges (BlueConic Administrators or Data Scientists, for example), you can inspect the notebook code in the Notebook editor window in AI Workbench.
    Tip: Use CMD +f or CTRL + f to search for pip install to locate lines of code that call Python library packages.

Q: Is there a list of all AI Workbench Python dependencies?

A: Yes, see the list of Python library package dependencies: https://supportdocs.blueconic.com/python/changelog/100-dependencies-changelog.html

Q: Are there best practices for how to specify package versions in notebook code?

A: Yes, see the FAQ: AI Workbench Python package dependencies.

Q: Who can I contact for questions or help resolving library/package updates?

Contact BlueConic Support if you have questions. Note that BlueConic Support cannot edit your AI notebooks but can help you understand if there are errors and how they should be resolved.

 

Was this article helpful?
0 out of 0 found this helpful