Skip to main content

Jupyter Notebook extension GUI node editor

Project description

ailab-lite

AI Lab is a cloud-based enterprise software application built by Fathom Solutions that enables building data workflows, managing experiments and deploying models. The ailab-lite library enables us to harness the power of the AI Lab product in a simple Jupyter Notebook setting. By adding this extension, the user can exploit the GUI node editor to create and test complicated data pipelines. Below is a link to a visualisation of how to generate an example workflow in Jupyter Notebook using the ailab-lite extension:

https://github.com/fathom-io/ailab-lite/blob/master/graphics/workflow.gif

The main idea of this product resolves around using the UI to construct a graph, which is later used to generate a data processing pipeline. The following image shows an example visualisation of a particular graph in the AI Lab product.

Next , there is the same graph generated in the Jupyter Notebook extension.

Each node represents a certain data transformation, model or validation process. Thinking of all these elements as one large graph lets us encapsulate our whole data processing and prediction pipeline into one object. Communication between each node is assured thanks to using a similar API to the ones used in libraries:

Buttons

Buttons in the editor are revealed after a dataset and at least one component are added to the graph. Before running an experiment, validation must be performed. After clicking the validation button and reveiving positive feedback, the run option appears. When running an experiment the results are printed below the GUI and additional files are saved in the same folder as the opened notebook.

Installation

To install use pip:

$ pip install ailab_lite

Instructions

Jupyter Notebook/Lab

Import node editor widget:

from ailab_lite import NodeEditorWidget

Import pandas:

import pandas as pd

Decalare dataset:

example = pd.read_csv("example.csv")

Run widget:

NodeEditorWidget(env=globals())

We initialize it with globals() so all previously defined datasets are available in node editor.

We can pass workflow definition directly when initializing widget:

NodeEditorWidget(env=globals(), workflow_definition="definition")

Running example

The examples directory contain example of widget usage. It contain predefined workflow. To run it, simply cd to the directory and run jupyter notebook or jupyter lab command.

(In order to run widget in the example first time it is required to run all cells. Other way the widget won't render)


Development

For a development installation (requires Node.js and Yarn version 1),

$ git clone https://github.com/fathoms-io/ailab-lite.git
$ cd ailab-lite
$ pip install -e .
$ jupyter nbextension install --py --symlink --overwrite --sys-prefix ailab_lite
$ jupyter nbextension enable --py --sys-prefix ailab_lite

When actively developing your extension for JupyterLab, run the command:

$ jupyter labextension develop --overwrite ailab_lite

Then you need to rebuild the JS when you make a code change:

$ cd js
$ yarn run build

You then need to refresh the JupyterLab page when your javascript changes.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ailab_lite-0.1.10.tar.gz (2.0 MB view details)

Uploaded Source

Built Distribution

ailab_lite-0.1.10-py2.py3-none-any.whl (5.0 MB view details)

Uploaded Python 2 Python 3

File details

Details for the file ailab_lite-0.1.10.tar.gz.

File metadata

  • Download URL: ailab_lite-0.1.10.tar.gz
  • Upload date:
  • Size: 2.0 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.7

File hashes

Hashes for ailab_lite-0.1.10.tar.gz
Algorithm Hash digest
SHA256 a51dfa2fb5d9593fd8af89e074957ac936a5e8e0db63bcf1a4283444f531f596
MD5 4f2cf7bb6641f3902314fb8988be8596
BLAKE2b-256 e2d043a596b799ed4efe30a5dd1acfbe5e4ec3a5b545e6eaf48213f489617e71

See more details on using hashes here.

File details

Details for the file ailab_lite-0.1.10-py2.py3-none-any.whl.

File metadata

  • Download URL: ailab_lite-0.1.10-py2.py3-none-any.whl
  • Upload date:
  • Size: 5.0 MB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.7

File hashes

Hashes for ailab_lite-0.1.10-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 f53cd93bc6e48fa60dcbd5a4fc742848c75e4802358220026406586745dafe24
MD5 fb64dc207dd208648bc9e2468703e215
BLAKE2b-256 a03738c05b0e9e803ee07ec3a7a940c388a6338c07a01794cca4bb77c9009798

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page