diff --git a/examples/getting_started/plot_tracking_items.py b/examples/getting_started/plot_tracking_items.py index 11bfe30aa..ec8e1a5fb 100644 --- a/examples/getting_started/plot_tracking_items.py +++ b/examples/getting_started/plot_tracking_items.py @@ -73,7 +73,7 @@ # We retrieve the history of the ``my_int`` item: # %% -item_histories = my_project.get_item_versions("my_int") +item_histories = my_project.get_item_versions("my_int") # TO CHANGE /!\ # %% # We can print the first history (first iteration) of this item: diff --git a/examples/getting_started/plot_working_with_projects.py b/examples/getting_started/plot_working_with_projects.py index 0b16b2074..3d672df1d 100644 --- a/examples/getting_started/plot_working_with_projects.py +++ b/examples/getting_started/plot_working_with_projects.py @@ -119,25 +119,19 @@ def my_func(x): ) # %% -# Moreover, we can also explicitly tell skore the media type of an object, for example -# in HTML: +# Moreover, we can also explicitly tell skore the way we want to display an object, for +# example in HTML: # %% -from skore.item import MediaItem -my_project.put_item( +my_project.put( "my_string_3", - MediaItem.factory( - "

Title

bold, italic, etc.

", media_type="text/html" - ), + "

Title

bold, italic, etc.

", + display_as="html", ) # %% -# .. note:: -# We used :func:`~skore.Project.put_item` instead of :func:`~skore.Project.put`. - -# %% -# Note that the media type is only used for the UI, and not in this notebook at hand: +# Note that the `display_as` is only used for the UI, and not in this notebook at hand: # %% my_project.get("my_string_3") diff --git a/examples/model_evaluation/plot_cross_validate.py b/examples/model_evaluation/plot_cross_validate.py index 9422e37b0..a47b6b74f 100644 --- a/examples/model_evaluation/plot_cross_validate.py +++ b/examples/model_evaluation/plot_cross_validate.py @@ -157,7 +157,7 @@ # %% # We can also access the plot after we have stored the ``CrossValidationReporter``: my_project.put("cross_validation_regression", reporter) -cv_item = my_project.get_item("cross_validation_regression") +cv_item = my_project.get_item("cross_validation_regression") # TO CHANGE /!\ cv_item.plots["Scores"] # %%