Skip to content

Latest commit

 

History

History
69 lines (45 loc) · 3.03 KB

CONTRIBUTING.md

File metadata and controls

69 lines (45 loc) · 3.03 KB

Contributing guide

bokbokbok aims to integrate custom loss functions to LightGBM, XGBoost and CatBoost. To add a loss function / eval metric / to contibute in general please follow these steps:

  • Discuss the feature you want to add on Github before you write a PR for it. On disagreements, maintainer(s) will have the final word.
  • If you’re going to add a loss function, please contribute the derivations of gradients and Hessians.
  • When issues or pull requests are not going to be resolved or merged, they should be closed as soon as possible. This is kinder than deciding this after a long period. Our issue tracker should reflect work to be done.

That said, there are many ways to contribute to bokbokbok, including:

  • Contribution to code
  • Improving the documentation
  • Reviewing merge requests
  • Investigating bugs
  • Reporting issues

Starting out with open source? See the guide How to Contribute to Open Source and have a look at our issues labelled good first issue.

Setup

Development install:

pip install -e '.[all]'

Run unit tests with

pytest

Standards

  • Python 3.6+
  • Follow PEP8 as closely as possible (except line length)
  • google docstring format
  • Git: Include a short description of what and why was done, how can be seen in the code. Use present tense, imperative mood
  • Git: limit the length of the first line to 72 chars. You can use multiple messages to specify a second (longer) line: git commit -m "Patch load function" -m "This is a much longer explanation of what was done"

Derivations

We use Code cogs to generate equations that are compatible with Git and markdown. To use an equation, choose svg format and HTML embedding and copy the link at the bottom of the page.

Releases and versioning

We use semver for versioning. When we are ready for a release, the maintainer runs:

git tag -a v0.1 -m "bokbokbok v0.1" && git push origin v0.1

When we create a new github release a github action is triggered that:

  • a new version will be deployed to pypi
  • the docs will be re-built and deployed

Documentation

Documentation is a very crucial part of the project, because it ensures usability of the package. We develop the docs in the following way:

  • We use mkdocs with mkdocs-material theme. The docs/ folder contains all the relevant documentation.
  • We use mkdocs serve to view the documentation locally. Use it to test the documentation every time you make any changes.
  • Maintainers can deploy the docs using mkdocs gh-deploy. The documentation is deployed to https://orchardbirds.github.io/.