Skip to main content
Back

ONNXMLTools 1.16.0 Finally Lets LightGBM Ranking Models Skip Python in Production

The ONNX ecosystem's model converter library ships 1.16.0 with LGBMRanker export, custom objective support, and better XGBoost categorical handling.

Pro

Repo, Full Access
  • ONNXMLTools 1.16.0 adds LGBMRanker converter, closing a gap for learning-to-rank pipelines.
  • XGBoost categorical feature support is improved in PR 743, building on 1.15.0's initial support.
  • Partial support for custom objectives lands in PR 753 (scalar output shapes).
  • Install with pip install --upgrade onnxmltools; Apache 2.0 licensed.
  • Covers LightGBM, XGBoost, CatBoost, H2O, scikit-learn, Core ML, Spark ML, TensorFlow, libsvm.
  • Exports classical ML models to a portable .onnx file for ONNX Runtime serving.

The maintainers of ONNXMLTools have tagged version 1.16.0, extending the library's coverage of gradient boosting exports to include LightGBM's ranking model and closing several long-standing gaps in XGBoost conversion. The release is small in line count but touches a corner of the ecosystem that many production ML teams quietly depend on: getting classical tree models out of Python and into ONNX Runtime for low-latency serving.

What actually shipped

ONNXMLTools is the umbrella converter that turns models from various classical ML toolkits into the ONNX graph format. The library currently supports TensorFlow (via a tf2onnx wrapper), scikit-learn (via skl2onnx), Apple Core ML, Spark ML (experimental), LightGBM, libsvm, XGBoost, H2O, and CatBoost. PyTorch is intentionally out of scope because it has its own built-in exporter.

The 1.16.0 changelog is short and targeted:

  • LGBMRanker support, added in an initial PR and finalized in PR 755
  • Partial support for a custom objective (PR 753)
  • Improved XGBoost categorical feature support (PR 743)

You can grab it the usual way:

pip install --upgrade onnxmltools

Why LGBMRanker matters

LightGBM's LGBMRanker is the learning-to-rank cousin of its classifier and regressor. It shows up heavily in search relevance, recommendation re-ranking, and ad ranking pipelines, typically trained with LambdaRank or a similar pairwise objective. Until now, teams wanting to serve a LightGBM ranker through ONNX Runtime had to either write a custom converter, keep Python in the serving path, or fall back on the LightGBM C API.