@@ -166,8 +166,58 @@ type Component struct {
166
166
Components * []Component `json:"components,omitempty" xml:"components>component,omitempty"`
167
167
Evidence * Evidence `json:"evidence,omitempty" xml:"evidence,omitempty"`
168
168
ReleaseNotes * ReleaseNotes `json:"releaseNotes,omitempty" xml:"releaseNotes,omitempty"`
169
+ ModelCard * MLModelCard `json:"modelCard,omitempty" xml:"modelCard,omitempty"`
170
+ Data * ComponentData `json:"data,omitempty" xml:"data,omitempty"`
169
171
}
170
172
173
+ type ComponentData struct {
174
+ BOMRef string `json:"bom-ref,omitempty" xml:"bom-ref,attr,omitempty"`
175
+ Type ComponentDataType `json:"type,omitempty" xml:"type,omitempty"`
176
+ Name string `json:"name,omitempty" xml:"name,omitempty"`
177
+ Contents * ComponentDataContents `json:"contents,omitempty" xml:"contents,omitempty"`
178
+ Classification string `json:"classification,omitempty" xml:"classification,omitempty"`
179
+ SensitiveData * []string `json:"sensitiveData,omitempty" xml:"sensitiveData,omitempty"`
180
+ Graphics * ComponentDataGraphics `json:"graphics,omitempty" xml:"graphics,omitempty"`
181
+ Description string `json:"description,omitempty" xml:"description,omitempty"`
182
+ Governance * ComponentDataGovernance `json:"governance,omitempty" xml:"governance,omitempty"`
183
+ }
184
+
185
+ type ComponentDataContents struct {
186
+ Attachment * AttachedText `json:"attachment,omitempty" xml:"attachment,omitempty"`
187
+ URL string `json:"url,omitempty" xml:"url,omitempty"`
188
+ Properties * []Property `json:"properties,omitempty" xml:"properties,omitempty"`
189
+ }
190
+
191
+ type ComponentDataGovernance struct {
192
+ Custodians * []ComponentDataGovernanceResponsibleParty `json:"custodians,omitempty" xml:"custodians>custodian,omitempty"`
193
+ Stewards * []ComponentDataGovernanceResponsibleParty `json:"stewards,omitempty" xml:"stewards>steward,omitempty"`
194
+ Owners * []ComponentDataGovernanceResponsibleParty `json:"owners,omitempty" xml:"owners>owner,omitempty"`
195
+ }
196
+
197
+ type ComponentDataGovernanceResponsibleParty struct {
198
+ Organization * OrganizationalEntity `json:"organization,omitempty" xml:"organization,omitempty"`
199
+ Contact * OrganizationalContact `json:"contact,omitempty" xml:"contact,omitempty"`
200
+ }
201
+
202
+ type ComponentDataGraphic struct {
203
+ Name string `json:"name,omitempty" xml:"name,omitempty"`
204
+ Image * AttachedText `json:"image,omitempty" xml:"image,omitempty"`
205
+ }
206
+
207
+ type ComponentDataGraphics struct {
208
+ Description string `json:"description,omitempty" xml:"description,omitempty"`
209
+ Collection * []ComponentDataGraphic `json:"collection,omitempty" xml:"collection>graphic,omitempty"`
210
+ }
211
+
212
+ type ComponentDataType string
213
+
214
+ const (
215
+ ComponentDataTypeConfiguration ComponentDataType = "configuration"
216
+ ComponentDataTypeDataset ComponentDataType = "dataset"
217
+ ComponentDataTypeOther ComponentDataType = "other"
218
+ ComponentDataTypeSourceCode ComponentDataType = "source-code"
219
+ )
220
+
171
221
type Composition struct {
172
222
BOMRef string `json:"bom-ref,omitempty" xml:"bom-ref,attr,omitempty"`
173
223
Aggregate CompositionAggregate `json:"aggregate" xml:"aggregate"`
@@ -258,6 +308,7 @@ const (
258
308
ERTypeLicense ExternalReferenceType = "license"
259
309
ERTypeMailingList ExternalReferenceType = "mailing-list"
260
310
ERTypeMaturityReport ExternalReferenceType = "maturity-report"
311
+ ERTypeModelCard ExternalReferenceType = "model-card"
261
312
ERTypeOther ExternalReferenceType = "other"
262
313
ERTypePentestReport ExternalReferenceType = "pentest-report"
263
314
ERTypeQualityMetrics ExternalReferenceType = "quality-metrics"
@@ -451,6 +502,84 @@ type Metadata struct {
451
502
Properties * []Property `json:"properties,omitempty" xml:"properties>property,omitempty"`
452
503
}
453
504
505
+ type MLDatasetChoice struct {
506
+ Ref string `json:"-" xml:"-"`
507
+ ComponentData * ComponentData `json:"-" xml:"-"`
508
+ }
509
+
510
+ type MLInputOutputParameters struct {
511
+ Format string `json:"format,omitempty" xml:"format,omitempty"`
512
+ }
513
+
514
+ type MLModelCard struct {
515
+ BOMRef string `json:"bom-ref,omitempty" xml:"bom-ref,attr,omitempty"`
516
+ ModelParameters * MLModelParameters `json:"modelParameters,omitempty" xml:"modelParameters,omitempty"`
517
+ QuantitativeAnalysis * MLQuantitativeAnalysis `json:"quantitativeAnalysis,omitempty" xml:"quantitativeAnalysis,omitempty"`
518
+ Considerations * MLModelCardConsiderations `json:"considerations,omitempty" xml:"considerations,omitempty"`
519
+ }
520
+
521
+ type MLModelCardConsiderations struct {
522
+ Users * []string `json:"users,omitempty" xml:"users>user,omitempty"`
523
+ UseCases * []string `json:"useCases,omitempty" xml:"useCases>useCase,omitempty"`
524
+ TechnicalLimitations * []string `json:"technicalLimitations,omitempty" xml:"technicalLimitations>technicalLimitation,omitempty"`
525
+ PerformanceTradeoffs * []string `json:"performanceTradeoffs,omitempty" xml:"performanceTradeoffs>performanceTradeoff,omitempty"`
526
+ EthicalConsiderations * []MLModelCardEthicalConsideration `json:"ethicalConsiderations,omitempty" xml:"ethicalConsiderations>ethicalConsideration,omitempty"`
527
+ FairnessAssessments * []MLModelCardFairnessAssessment `json:"fairnessAssessments,omitempty" xml:"fairnessAssessments>fairnessAssessment,omitempty"`
528
+ }
529
+
530
+ type MLModelCardEthicalConsideration struct {
531
+ Name string `json:"name,omitempty" xml:"name,omitempty"`
532
+ MitigationStrategy string `json:"mitigationStrategy,omitempty" xml:"mitigationStrategy,omitempty"`
533
+ }
534
+
535
+ type MLModelCardFairnessAssessment struct {
536
+ GroupAtRisk string `json:"groupAtRisk,omitempty" xml:"groupAtRisk,omitempty"`
537
+ Benefits string `json:"benefits,omitempty" xml:"benefits,omitempty"`
538
+ Harms string `json:"harms,omitempty" xml:"harms,omitempty"`
539
+ MitigationStrategy string `json:"mitigationStrategy,omitempty" xml:"mitigationStrategy,omitempty"`
540
+ }
541
+
542
+ type MLModelParameters struct {
543
+ Approach * MLModelParametersApproach `json:"approach,omitempty" xml:"approach,omitempty"`
544
+ Task string `json:"task,omitempty" xml:"task,omitempty"`
545
+ ArchitectureFamily string `json:"architectureFamily,omitempty" xml:"architectureFamily,omitempty"`
546
+ ModelArchitecture string `json:"modelArchitecture,omitempty" xml:"modelArchitecture,omitempty"`
547
+ Datasets * []MLDatasetChoice `json:"datasets,omitempty" xml:"datasets>dataset,omitempty"`
548
+ Inputs * []MLInputOutputParameters `json:"inputs,omitempty" xml:"inputs>input,omitempty"`
549
+ Outputs * []MLInputOutputParameters `json:"outputs,omitempty" xml:"outputs>output,omitempty"`
550
+ }
551
+
552
+ type MLModelParametersApproach struct {
553
+ Type MLModelParametersApproachType `json:"type,omitempty" xml:"type,omitempty"`
554
+ }
555
+
556
+ type MLModelParametersApproachType string
557
+
558
+ const (
559
+ MLModelParametersApproachTypeSupervised MLModelParametersApproachType = "supervised"
560
+ MLModelParametersApproachTypeUnsupervised MLModelParametersApproachType = "unsupervised"
561
+ MLModelParametersApproachTypeReinforcementLearning MLModelParametersApproachType = "reinforcement-learning"
562
+ MLModelParametersApproachTypeSemiSupervised MLModelParametersApproachType = "semi-supervised"
563
+ MLModelParametersApproachTypeSelfSupervised MLModelParametersApproachType = "self-supervised"
564
+ )
565
+
566
+ type MLQuantitativeAnalysis struct {
567
+ PerformanceMetrics * []MLPerformanceMetric `json:"performanceMetrics,omitempty" xml:"performanceMetrics>performanceMetric,omitempty"`
568
+ Graphics * ComponentDataGraphics `json:"graphics,omitempty" xml:"graphics,omitempty"`
569
+ }
570
+
571
+ type MLPerformanceMetric struct {
572
+ Type string `json:"type,omitempty" xml:"type,omitempty"`
573
+ Value string `json:"value,omitempty" xml:"value,omitempty"`
574
+ Slice string `json:"slice,omitempty" xml:"slice,omitempty"`
575
+ ConfidenceInterval * MLPerformanceMetricConfidenceInterval `json:"confidenceInterval,omitempty" xml:"confidenceInterval,omitempty"`
576
+ }
577
+
578
+ type MLPerformanceMetricConfidenceInterval struct {
579
+ LowerBound string `json:"lowerBound,omitempty" xml:"lowerBound,omitempty"`
580
+ UpperBound string `json:"upperBound,omitempty" xml:"upperBound,omitempty"`
581
+ }
582
+
454
583
type Note struct {
455
584
Locale string `json:"locale,omitempty" xml:"locale,omitempty"`
456
585
Text AttachedText `json:"text" xml:"text"`
0 commit comments