Skip to content

Make all tutorials multi-language #11413

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
david-cortes opened this issue Apr 17, 2025 · 3 comments
Open

Make all tutorials multi-language #11413

david-cortes opened this issue Apr 17, 2025 · 3 comments

Comments

@david-cortes
Copy link
Contributor

ref #11410

After the PR above gets merged, we'll have a mechanism to show language tabs throughout the online docs, but it would only be used in 2 out of 25 tutorials. This could be a nice way to make all the current tutorials multi-language, by having a tab for 'R' next to the tab for 'Python' - example:

Image

I think most of the tutorials would be straightforward to write as R code (save for ones that don't apply, like distributed mode), but it's quite a lot of work. Leaving the idea here in case someone wants to work on porting at least some tutorials (CC @mayer79 @jameslamb @dfsnow).

@jameslamb
Copy link
Contributor

I love this!

I have wanted tab-per-language tutorials like this in LightGBM for a while, never took the time to investigate it. I'd love to adopt something like what you did for #11410 in LightGBM, with at least Python and R.

I'd love to expand https://github.com/microsoft/LightGBM/blob/master/docs/Features.rst with one section for each of like "early stopping", "linear trees", "custom objective function", etc. I'd welcome a PR over there to introduce this plugin and one such example (let's say "linear trees") if you have the time and interest. If not, no worries, I'll adopt what you've put together in #11410.

it's quite a lot of work

This can be a good candidate for a good first issue to attract more outside contributors, I think. If you all go that route, I recommend enumerating all of the examples to be done in a to-do list, like I did here: microsoft/LightGBM#6361

I would also be happy to help with some of these examples 😊

@dfsnow
Copy link

dfsnow commented Apr 21, 2025

Likewise happy to help! But pretty busy these days so would massively appreciate a to-do list ala James' suggestion to make the work more bite-sized.

@trivialfis
Copy link
Member

@dfsnow Thank you for volunteering! Since @david-cortes has already set up the sphinx build, you can focus on the tutorials. Perhaps one tutorial at a time: https://github.com/dmlc/xgboost/tree/master/doc/tutorials ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants