/uptrain

Your open-source ML monitoring and refinement toolkit.

Primary LanguagePythonApache License 2.0Apache-2.0

An open-source framework to observe ML applications, built for engineers

Docs - Try it out - Discord Community - Bug Report - Feature Request

uptrain_demo.mp4

Read this in other languages: English language German language Chinese language Hindi language Spanish language French language Japanese language Russian language

UpTrain is an open-source, data-secure tool for ML practitioners to observe and refine their ML models by monitoring their performance, checking for (data) distribution shifts, and collecting edge cases to retrain them upon. It integrates seamlessly with your existing production pipelines and takes minutes to get started ⚡.

  • Data Drift Checks - Identify distribution shifts in your model inputs.
  • Performance Monitoring - Track the performance of your models in realtime and get degradation alerts.
  • Embeddings Support - Specialized dashboards to understand model-inferred embeddings.
  • Edge Case Signals - User-defined signals and statistical techniques to detect out-of-distribution data-points.
  • Data Integrity Checks - Checks for missing or inconsistent data, duplicate records, data quality, etc.
  • Customizable metrics - Define custom metrics that make sense for your use case.
  • Automated Retraining - Automate model retraining by attaching your training and inference pipelines.
  • Model Bias - Track bias in your ML model's predictions.
  • AI Explainability - Understand relative importance of multiple features on predictions.
  • Data Security - Your data never goes out of your machine.
  • Slack Integration - Get alerts on Slack.
  • Realtime Dashboards - To visualize your model's health live.

🚨Coming soon🚨

  • Label Shift - Identify drifts in your predictions. Specially useful in cases when ground truth is unavailable.
  • Model confidence interval - Confidence intervals for model predictions
  • Advanced drift detection techniques - Outlier-based drift detection methods
  • Advanced feature slicing - Ability to slice statistical properties
  • Kolmogorov-Smirnov Test - For detecting distribution shifts
  • Prediction Stability - Filter cases where model prediction is not stable.
  • Adversarial Checks - Combat adversarial attacks

And more.

Get started 🙌

You can quickly get started with Google Colab here.

To run it in your machine, follow the steps below:

Install the package through pip:

pip install uptrain

Run your first example:

git clone git@github.com:uptrain-ai/uptrain.git
cd uptrain/examples
pip install jupyterlab
jupyter lab

For a quick walkthrough of how UpTrain works, check out our quickstart tutorial.

UpTrain in action 🎬

One of the most common use cases of ML today is language models, be it text summarization, NER, chatbots, language translation, etc. UpTrain provides ways to visualize differences in the training and real-world data via UMAP clustering of text embeddings (inferred from BERT). Following are some replays from the UpTrain dashboard.

AI Explainability out-of-the-box

umap_gif

Live Model Performance Monitoring and Data Integrity Checks

perf_gif perf_gif

UMAP Dimensionality Reduction and Visualization

umap_gif

Edge-case Collection for Finetuning the Model later

perf_gif

Why UpTrain 🤔?

Machine learning (ML) models are widely used to make critical business decisions. Still, no ML model is 100% accurate, and, further, their accuracy deteriorates over time 😣. For example, Sales prediction becomes inaccurate over time due to a shift in consumer buying habits. Additionally, due to the black box nature of ML models, it's challenging to identify and fix their problems.

UpTrain solves this. We make it easy for data scientists and ML engineers to understand where their models are going wrong and help them fix them before others complain 🗣️.

UpTrain can be used for a wide variety of Machine learning models such as LLMs, recommendation models, prediction models, Computer vision models, etc.

We are constantly working to make UpTrain better. Want a new feature or need any integrations? Feel free to create an issue or contribute directly to the repository.

Meme

License 💻

This repo is published under Apache 2.0 license, with the exception of the ee directory which will contain premium features requiring an enterprise license in the future. We're currently focused on developing non-enterprise offerings that should cover most use cases by adding more features and extending to more models. We also working towards adding a hosted offering - contact us if you are interested.

Stay Updated ☎️

We are continuously adding tons of features and use cases. Please support us by giving the project a star ⭐!

Provide feedback (Harsher the better 😉)

We are building UpTrain in public. Help us improve by giving your feedback here.

Contributors 🖥️

We welcome contributions to UpTrain. Please see our contribution guide for details.