C3 AI offers a fantastic exercise package which is used for most of the C3.ai Academy Cornerstone and Data Science courses. This package contains numerous Types and timeseries data, along with UI elements, showing how to build a fully functional application. For learning certain aspects of the C3 AI Suite, we recommend that DTI members download this package and look inside. Some DTI examples also use this package so you may wind up provisioning it as well.

Downloading the Package

To get the source code follow these directions:

  1. Navigate to the C3.ai Data Science course.
  2. Select the 'Additional Resources':
  3. Download the 'C3DS_Course_Files.zip' file:


  4. Unzip the 'C3DS_Course_Files.zip' file to your local file system.
  5. Copy the lightbulbAD package out of the unzipped set of files. This is located in the 'StarterRepository' directory and is named 'c3training'.

Once provisioned, you will need the 'SmartBulbMeasurement.csv' file to fill your package with missing data. You can find this data in the 'General Resources' folder of the zip file.

Provisioning

Follow the DTI Guide: Provisioning for instructions on how to provision a package.

Data Integration

Finally, we need to send the 'SmartBulbMeasurement.csv' file to the cluster. There are a couple of ways to do this: we can use postman, curl, or the DTI send-file.py helper script. Essentially it's just an HTTP POST request.

We'll describe here how to use send-file.py:

  1. Download the DTI github repository for helper scripts.
  2. Generate an authentication token by executing `Authenticator.generateC3AuthToken()`.

Then, execute the following command:

python send-file.py --vanity-url <vanity_url> --tenant <tenant> --tag <tag> --api-endpoint CanoniocalSmartMeasurement/CanonicalSmartMeasurement.csv --file <path_to_SmartBulbMeasurement.csv>
  • No labels