The following provides the the template for building a Jupyter Workbench Runtime images to use with
Open Data Hub ODH or Red Hat OpenShift Data Science RHODS
or podman / Docker Locally.
It loads the Openad lookit and a minimal image of the UBI9 jupyter notebooks with prebuilt note books for using OpenAD.
To install podman see install instructions
To Install Docker Engine see Install Docker Engine
First of all make sure if you are using podman, you have at least 4GB of memory available to podman
e.g.
podman stop
podman machine set --cpus 4 --memory 4096
podman start
To build your image and deploy on podman/docker run
podman/docker build -t openad_workbench https://github.com/acceleratedscience/openad_workbench.git#main
To run your workbench
podman/docker run -d -p 8888:8888 -p 8024-8200:8024-8200 --name my_workbench openad_workbench
To stop your workbench:
podman/docker stop my_workbench
To restart your workbench:
podman/docker stop my_workbench
To delete your workbench container you will need to stop it then run the following:
podman/docker rm my_workbench
Once the Pod is Started use the url in your browser 127.0.0.1:8888
to enter your jupyter lab
The following instruction provides an alternative to allow you to use your desktops existing workspaces as well as use exisint RXN, Deep Search and LLM credentials.
podman/docker run -d -v $HOME/.openad:/opt/app-root/src/.openad:Z -p 8888:8888 -p 8024-8200:8024-8200 --name my_workbench openad_workbench
If you wish to create secrets to pre-load models and other credentials create 2 json files
First called openad_creds.json
{
"bam": {
"auth": {
"api_key": "<api_key>"
}
},
"rxn": {
"auth": {
"api_key": "<api_key>"
}
},
"deepsearch": {
"auth": {
"username": "jon.doe@email",
"api_key": "<api_key>"
}
}
}
The seconds called opend_models.json
like the following example "
"auth_groups": {
"default": "<API_key/Bearer token>"
},
"services": {
"prop": {
"host": "https://<url>:8080/proxy",
"inference-service": "properties",
"auth_group": "default"
},
"gen": {
"host": "https://<url>:8080/proxy",
"inference-service": "generation",
"auth_group": "default"
},
"moler": {
"host":"https://<url>:8080/proxy",
"inference-service": "moler",
"auth_group": "default"
},
"molf": {
"host": "https://<url>>:8080/proxy",
"inference-service": "molformer",
"auth_group": "default"
}
}
}
Then run podman secret create openad_creds openad_creds.json
and
podman secret create openad_models openad_models.json
Then run the following to run the container and access you notebooks
podman run -d --secret openad_creds --secret openad_models -p 8888:8888 -p 8024-8200:8024-8200 --name my_workbench openad_workbench
Before you can interact with the toolkits, you'll need to register with each individual toolkit.
Register with DS4SD (Deep Search)
-
First, you'll need to generate an API key on the Deep Search website.
- Visit the Deep Search website and create an account:
deepsearch-experience.res.ibm.com - Once logged in, click the Toolkit/API icon in the top right hand corner, then open the HTTP section
- Click the "Generate new API key" button
- Visit the Deep Search website and create an account:
-
Once inside the OpenAD client, you'll be prompted to authenticate when activating the Deep Search (DS4SD) toolkit. When running
set context ds4sd
:- Hostname: https://sds.app.accelerate.science
- Email: Your email
- API_key: The DS4SD API key you obtained following the instructions above.
-
You should get a message saying you successfully logged in.
Note: Your DS4SD auth config file is saved as
~/.openad/deepsearch_api.cred
. If you ever want to reset your DS4SD login information you can runset context ds4sd reset
, or you can delete this file.
Register with RXN
-
First, you'll need to generate an API key on the RXN website.
- Sign up for an RXN account at rxn.app.accelerate.science
- Obtain your API key by clicking the user profile icon in the top right hand corner and select "My profile".
-
When setting the context to RXN using
set context rxn
you'll be prompted to create a new auth configuration file:- Hostname: https://rxn.app.accelerate.science
- API_key: The RXN API key you obtained following the instructions above.
- Hostname: https://rxn.app.accelerate.science
-
You should get a message saying you successfully logged in.
Note: Your RXN auth config file is saved as
~/.openad/rxn_api.cred
. If you ever want to reset your RXN login information you can runset context rxn reset
, or you can delete this file.