Replace kfp-notebook
/elyra-server
with a KFP component to run notebooks
#305
Labels
API
Swagger API
dependencies
Pull requests that update a dependency file
question
Further information is requested
Current State:
We currently depend on the
elyra-server
package with theExecuteFileOp
to run notebooks in a Kubeflow Pipeline. While that works fairly well and provides much flexibility, there are some drawbacks.The Problem:
One of the biggest drawbacks are the Python packages that are required by
elyra
, most of which are not essential to generate the pipeline code to run the notebook. Note, that thepapermill
package with its dependencies onipython
etc are only required on the Pod running the notebook, not on the MLX API server pod that generates the pipeline to run the notebook. Many of the remaining packages required byelyra
overlap with the packages required bykfp
/kfp-tekton
, sometimes requiring conflicting and occasionally irreconcilable versions.Proposed Solution:
Instead of using Elyra to generate the pipelines to run notebooks, we could use a straight-forward KFP component, as we have done in the past. An example of a notebook runner component with sample pipeline exists in KFP:
The Elyra team had considered switching to a KFP component, but they have not done any further investigation. Publishing a component -- that is married to a base Docker image -- would probably not meet the needs of most Elyra users (@ptitzler)
Having the flexibility to specify the Docker image to be used to run the notebook is one important consideration. Since MLX uses code templates to generate sample pipelines to launch notebooks, we could utilize
kfp.components.create_component_from_func()
which takes abase_image
argument:Or we could use
kfp.components.create_component_from_file
and replace the image attribute in theComponentSpec
> .. >ContainerSpec
. Or, even more crudely, we could usekfp.components.create_component_from_text
and replace an${image}
placeholder in acomponent.yaml.template
.Related Issues:
Interested Parties:
The text was updated successfully, but these errors were encountered: