Dotscience modes

We explore the different ways in which users can interact with Dotscience using the Dotscience Python Library and the Dotscience client


The Dotscience library can run in 3 modes. The modes can be entered using the appropriate ds commands in the Python library.

  1. Interactive mode
  2. Script mode
  3. Dotscience anywhere / remote mode

Interactive mode

Calling ds.interactive() tells the system that there is no script file that the code is coming from. This is typical when using a Jupyter notebook instead of a .py Python script.

Script mode

When writing the code in a Python script file, e.g., a .py instead of a Jupyter notebook, call ds.script(). This instructs the library to record the script filename (from sys.argv[0]) in the output runs, so they can be tracked back to the originating script. This is not needed in interactive mode because Dotscience knows which Jupyter notebook you are using, and sys.argv[0] points to the Jupyter Python kernel in that case.

Dotscience anywhere mode

Using ds.connect():

NOTE: There is no provenance or data versioning in this mode

This mode offers an easy way to deploy AI models into Kubernetes & monitor them. Using the dotscience-python library, you can now connect to an environment with


By default, this connects to if the last argument is not specified.

All subsequent operations when using the dotscience-python library connect to the Hub specified. This can be used to register metadata, models and perform deployments from external scripts. For a demo of this feature and its usage, follow the Katacoda based tutorial at