Skip to content

Conversation

@PGijsbers
Copy link
Collaborator

Work converting the Python docs to mkdocs. Left to do before it's "functional":

  • Make sure notebooks run
  • Add the test server warning back, preferably in a reusable way as was before.

Otherwise, most of the files have been converted.

That said, the documentation really needs a rewrite. I refrained from changing any content as much as I could, with rare exceptions. But the main problems, to me, are:

  • Information is all over the place. A few cohesive examples with a proper ToC would be better (I think).
  • The formatting is bad.
  • There is a mix of styles. Some examples even talk about "exercises" (e.g., here).
  • Some of the content is outdated.

How should we move forward with this PR? I don't mind rewriting (some of) this documentation, but I think it would be better to merge this at one point so it's easier to collaborate. WDYT? @eddiebergman @LennartPurucker

@LennartPurucker
Copy link
Contributor

IMO: merge first and focus on user stories/use cases afterward to refactor the documentation. That is, likely move all the old documentation to an "extended example" list and only keep a set of user stories / use cases in the new main documentation.

Copy link
Contributor

@SubhadityaMukherjee SubhadityaMukherjee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merged all the changes, they seem correct and run correctly. Next I will test the notebooks/scripts to verify if everything runs.

…e if everything still runs and is up to date
@codecov-commenter
Copy link

codecov-commenter commented Mar 25, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 53.71%. Comparing base (c66d22a) to head (2a16c03).
Report is 1 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #1379   +/-   ##
========================================
  Coverage    53.71%   53.71%           
========================================
  Files           38       38           
  Lines         5229     5229           
========================================
  Hits          2809     2809           
  Misses        2420     2420           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@SubhadityaMukherjee
Copy link
Contributor

SubhadityaMukherjee commented Apr 29, 2025

Seems I forgot to update this. These examples dont work. Im not entirely sure how to fix them. All the other examples seem to run. I modified some slightly to make some of them work. They are from examples/

20_basic/
simple_flows_and_runs_tutorial : the flow seems to be wrong. expected flow parameters: [] model parameters: ['bootstrap', 'ccp_alpha', 'class_weight', 'criterion', 'max_depth', 'max_features', 'max_leaf_nodes', 'max_samples', 'min_impurity_decrease', 'min_samples_leaf', 'min_samples_split', 'min_weight_fraction_leaf', 'monotonic_cst', 'n_estimators', 'n_jobs', 'oob_score', 'random_state', 'verbose', 'warm_start’]

30_extended/
run_setup_tutorial : IndexError: positional indexers are out-of-bounds

flows_and_runs_tutorial : No reg-eye-state, or dataset 68 seems to be something else.

study_tutorial: the flow seems to be wrong. ValueError: Parameters of the model do not match the parameters expected by the flow: expected flow parameters: [] model parameters: ['bootstrap', 'ccp_alpha', 'class_weight', 'criterion', 'max_depth', 'max_features', 'max_leaf_nodes', 'max_samples', 'min_impurity_decrease', 'min_samples_leaf', 'min_samples_split', 'min_weight_fraction_leaf', 'monotonic_cst', 'n_estimators', 'n_jobs', 'oob_score', 'random_state', 'verbose', 'warm_start’]

40_paper/
2018_kdd_rijn_example.py: This example is deprecated, remove the if False in this code to use it manually.

@PGijsbers
Copy link
Collaborator Author

Thanks! I can have another look once AIoD calms down a little (i.e., after May 22nd).

@PGijsbers PGijsbers self-assigned this May 5, 2025
@SubhadityaMukherjee
Copy link
Contributor

Removed linkcheck for now since the one I picked apparently is not maintained.
Also an option for versioning using "mike" which requires some extra work. - https://squidfunk.github.io/mkdocs-material/setup/setting-up-versioning/

@SubhadityaMukherjee
Copy link
Contributor

Ah @PGijsbers I think we will also need to point the gh-pages option in settings to a different page. I dont have access to it so I cant check if its the same as sphinx.
It should be Pages -> Deploy from branch : gh-pages -> root

@SubhadityaMukherjee SubhadityaMukherjee marked this pull request as ready for review June 16, 2025 14:01
@PGijsbers
Copy link
Collaborator Author

PGijsbers commented Jun 18, 2025

Ah @PGijsbers I think we will also need to point the gh-pages option in settings to a different page. I dont have access to it so I cant check if its the same as sphinx. It should be Pages -> Deploy from branch : gh-pages -> root

That's already set. Sorry for the slow reply. Next time just ask me directly if I don't respond :)

Comment on lines 37 to 40
if: (contains(github.ref, 'develop') || contains(github.ref, 'main')) && github.event_name == 'push'
run: |
mkdocs gh-deploy --force
env:
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this take into account the branch? For example, if we publish version 0.16 and its documentation, to me it reads like our develop documentation will overwrite it as soon as we push to develop.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know I initially said we didn't need it but.. maybe it might be a good idea to look into mike? https://squidfunk.github.io/mkdocs-material/setup/setting-up-versioning/

it seems to handle the thing we'd want later and it would also solve this problem.
Then we can simply build docs when:

  • push to develop (as dev)
  • a release is made, i.e., a tag of format v*

Copy link
Collaborator

@eddiebergman eddiebergman Jun 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some reference for what you might need from mike if you want versioned docs.
https://github.com/automl/amltk/blob/5221d80fb4fec92f2d6f2fc73fce4eb16139c09f/.github/workflows/release.yml#L90-L110

It's also good to be aware that all mike does for you is work on the gh-pages branch and so you can always go nuke it or manually edit it if testing goes wrong. Took me a while before realising that, but it means you can really test out the workflow locally before doing the annoying dance with GH actions to get it to work.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The root of this branch is pretty instructive for what it's doing, i.e. with the symlink, the index.html pointig to latest and the versions.json it's using to store metadata
https://github.com/automl/amltk/tree/gh-pages

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A wild Eddie appears!

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can just use regular pokeball, no need for an ultra

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

throws a master ball

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

struggle, struggle, pokémon Eddie breaks free

@SubhadityaMukherjee
Copy link
Contributor

all the tests pass in reality but the added files check fails, maybe mike adds them. Im looking into it

Copy link
Contributor

@LennartPurucker LennartPurucker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comments

Comment on lines 5 to 26
<<<<<<< docs/mkdoc -- Incoming Change
# %%
import openml
=======
>>>>>>> develop -- Current Change
import pandas as pd

import openml
from openml.datasets import edit_dataset, fork_dataset, get_dataset

############################################################################
# Exercise 0
# **********
# %% [markdown]
# ## Exercise 0
#
<<<<<<< docs/mkdoc -- Incoming Change
# * List datasets

# %%
datalist = openml.datasets.list_datasets(output_format="dataframe")
=======
# * List datasets and return a dataframe
datalist = openml.datasets.list_datasets()
>>>>>>> develop -- Current Change
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merge bug?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this file?

Copy link
Contributor

@LennartPurucker LennartPurucker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

uv.lock Outdated
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this file is not needed

@LennartPurucker LennartPurucker merged commit d0f31b9 into develop Jun 19, 2025
12 of 13 checks passed
@LennartPurucker LennartPurucker deleted the docs/mkdoc branch June 19, 2025 10:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants