ModelCard
Models & Types · AiDotNet.AdversarialRobustness.Documentation
Represents a Model Card for documenting AI model characteristics and performance.
For Beginners
A Model Card is like a nutrition label for AI models. Just as food labels tell you what’s in your food and its nutritional value, Model Cards tell you what the AI model is for, how well it works, what its limitations are, and any ethical considerations you should know about.
How It Works
Model Cards provide transparent documentation about machine learning models, including their intended use, limitations, performance metrics, and ethical considerations.
Based on “Model Cards for Model Reporting” by Mitchell et al. (2019)
Constructors
| Constructor | Summary |
|---|---|
ModelCard() |
Properties
| Property | Summary |
|---|---|
DateTime Date { get; set; } |
Gets or sets the date the model was created or last updated. |
Dictionary<string, Dictionary<string, double>> FairnessMetrics { get; set; } |
Gets or sets fairness metrics across different demographic groups. |
Dictionary<string, Dictionary<string, double>> PerformanceMetrics { get; set; } |
Gets or sets performance metrics on different datasets. |
Dictionary<string, double> RobustnessMetrics { get; set; } |
Gets or sets robustness evaluation results. |
List<string> Caveats { get; set; } |
Gets or sets caveats and additional warnings. |
List<string> EthicalConsiderations { get; set; } |
Gets or sets ethical considerations and potential biases. |
List<string> IntendedUses { get; set; } |
Gets or sets the intended use cases for the model. |
List<string> Limitations { get; set; } |
Gets or sets known limitations of the model. |
List<string> OutOfScopeUses { get; set; } |
Gets or sets the out-of-scope use cases (what the model should NOT be used for). |
List<string> Recommendations { get; set; } |
Gets or sets recommendations for responsible use. |
string Developers { get; set; } |
Gets or sets the model developers or organization. |
string ModelName { get; set; } |
Gets or sets the model name and version. |
string ModelType { get; set; } |
Gets or sets the model type (e.g., “Classification”, “Regression”, “LLM”). |
string TrainingData { get; set; } |
Gets or sets the training data description. |
string Version { get; set; } |
Gets or sets the model version identifier. |
Methods
| Method | Summary |
|---|---|
ModelCard CreateFromEvaluation(string modelName, string modelType, Dictionary<string, double> performanceMetrics, Dictionary<string, double> robustnessMetrics) |
Creates a Model Card from evaluation results. |
string Generate() |
Generates a formatted Model Card document. |
void SaveToFile(string filePath) |
Saves the Model Card to a markdown file. |