Skip to content

Commit ea31422

Browse files
minthigpengaugup
andauthored
Create README.md for responsibleai and add RAI notebooks. (Azure#1742)
* Create README.md * Create README.md * Update README.md * Create apartments-train.csv * Create apartments-train.csv * Add RAI notebooks Signed-off-by: Gaurav Gupta <[email protected]> * Fix black linting Signed-off-by: Gaurav Gupta <[email protected]> Signed-off-by: Gaurav Gupta <[email protected]> Co-authored-by: Gaurav Gupta <[email protected]>
1 parent 2b9189a commit ea31422

File tree

29 files changed

+8872
-0
lines changed

29 files changed

+8872
-0
lines changed

cli/responsible-ai/README.md

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Azure Machine Learning Responsible AI Dashboard and Scorecard
2+
3+
Read more about how to generate the Responsible AI (RAI) dashboard [here](https://learn.microsoft.com/en-us/azure/machine-learning/how-to-responsible-ai-dashboard-sdk-cli?tabs=yaml) and Responsible AI scorecard [here](https://learn.microsoft.com/en-us/azure/machine-learning/how-to-responsible-ai-scorecard).
4+
5+
The Responsible AI components are supported for MLflow models with `scikit-learn` flavor that are trained on `pandas.DataFrame`.
6+
The components accept both models and SciKit-Learn pipelines as input as long as the model or pipeline implements `predict` and `predict_proba` functions that conforms to the `scikit-learn` convention.
7+
If not compatible, you can wrap your model's prediction function into a wrapper class that transforms the output into the format that is supported (`predict` and `predict_proba` of `scikit-learn`), and pass that wrapper class to modules in this repo.
8+
9+
## Sample directory 📖
10+
11+
| Scenario | Dataset | Data type | RAI component included | Link to sample |
12+
| --- | --- | --- | --- | --- |
13+
| Regression | [sklearn Diabetes](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_diabetes.html) | Tabular | Explanation, Error Analysis, Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
14+
| Regression | ADD LINK AFTER MOVING PROGRAMMERS DATA FOLDER | Tabular | Explanation, Error Analysis, Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
15+
| Classification | [Kaggle Housing](https://www.kaggle.com/alphaepsilon/housing-prices-dataset) | Tabular | Explanation, Error Analysis, Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
16+
| Decision making | [Kaggle Housing](https://www.kaggle.com/alphaepsilon/housing-prices-dataset) | Tabular | Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
17+
| Decision making | [sklearn Diabetes](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_diabetes.html) | Tabular | Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
18+
19+
20+
## Supportability 🧰
21+
Currently, we support datasets having numerical and categorical features. The following table provides the scenarios supported for each of the four responsible AI components:
22+
> **Note**: Model overview (performance metrics and fairness disparity metrics) and Data explorer are generated for every Responsible AI dashboard by default and do not require a component to be configured.
23+
24+
| RAI component | Binary classification | Multi-class classification | Multilabel classification | Regression | Timeseries forecasting | Categorical features | Text features | Image Features | Recommender Systems | Reinforcement Learning |
25+
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | -- |
26+
| Explainability | Yes | Yes | No | Yes | No | Yes | No | No | No | No |
27+
| Error Analysis | Yes | Yes | No | Yes | No | Yes | No | No | No | No |
28+
| Causal Analysis | Yes | No | No | Yes | No | Yes (max 5 features due to computational cost) | No | No | No | No |
29+
| Counterfactual | Yes | Yes | No | Yes | No | Yes | No | No | No | No |
30+
31+
Read more about how to use the Responsible AI dashboard [here](https://learn.microsoft.com/en-us/azure/machine-learning/how-to-responsible-ai-dashboard).

cli/responsible-ai/datasets/apartments-train.csv

+1,461
Large diffs are not rendered by default.

sdk/python/responsible-ai/README.md

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Azure Machine Learning Responsible AI Dashboard and Scorecard
2+
3+
Read more about how to generate the Responsible AI (RAI) dashboard [here](https://learn.microsoft.com/en-us/azure/machine-learning/how-to-responsible-ai-dashboard-sdk-cli?tabs=yaml) and Responsible AI scorecard [here](https://learn.microsoft.com/en-us/azure/machine-learning/how-to-responsible-ai-scorecard).
4+
5+
The Responsible AI components are supported for MLflow models with `scikit-learn` flavor that are trained on `pandas.DataFrame`.
6+
The components accept both models and SciKit-Learn pipelines as input as long as the model or pipeline implements `predict` and `predict_proba` functions that conforms to the `scikit-learn` convention.
7+
If not compatible, you can wrap your model's prediction function into a wrapper class that transforms the output into the format that is supported (`predict` and `predict_proba` of `scikit-learn`), and pass that wrapper class to modules in this repo.
8+
9+
## Sample directory 📖
10+
11+
| Scenario | Dataset | Data type | RAI component included | Link to sample |
12+
| --- | --- | --- | --- | --- |
13+
| Regression | [sklearn Diabetes](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_diabetes.html) | Tabular | Explanation, Error Analysis, Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
14+
| Regression | ADD LINK AFTER MOVING PROGRAMMERS DATA FOLDER | Tabular | Explanation, Error Analysis, Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
15+
| Classification | [Kaggle Housing](https://www.kaggle.com/alphaepsilon/housing-prices-dataset) | Tabular | Explanation, Error Analysis, Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
16+
| Decision making | [Kaggle Housing](https://www.kaggle.com/alphaepsilon/housing-prices-dataset) | Tabular | Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
17+
| Decision making | [sklearn Diabetes](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_diabetes.html) | Tabular | Causal analysis, Counterfactuals | ADD LINK AFTER MOVING SAMPLES! |
18+
19+
## Supportability 🧰
20+
Currently, we support datasets having numerical and categorical features. The following table provides the scenarios supported for each of the four responsible AI components:
21+
> **Note**: Model overview (performance metrics and fairness disparity metrics) and Data explorer are generated for every Responsible AI dashboard by default and do not require a component to be configured.
22+
23+
| RAI component | Binary classification | Multi-class classification | Multilabel classification | Regression | Timeseries forecasting | Categorical features | Text features | Image Features | Recommender Systems | Reinforcement Learning |
24+
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | -- |
25+
| Explainability | Yes | Yes | No | Yes | No | Yes | No | No | No | No |
26+
| Error Analysis | Yes | Yes | No | Yes | No | Yes | No | No | No | No |
27+
| Causal Analysis | Yes | No | No | Yes | No | Yes (max 5 features due to computational cost) | No | No | No | No |
28+
| Counterfactual | Yes | Yes | No | Yes | No | Yes | No | No | No | No |
29+
30+
Read more about how to use the Responsible AI dashboard [here](https://learn.microsoft.com/en-us/azure/machine-learning/how-to-responsible-ai-dashboard).

0 commit comments

Comments
 (0)