Skip to content

model

mlte/report/model.py

Model implementation for MLTE report.

CommentDescriptor

Bases: BaseModel

The model implementation for a generic comment.

Source code in mlte/report/model.py
14
15
16
17
18
class CommentDescriptor(BaseModel):
    """The model implementation for a generic comment."""

    content: str
    """The comment content."""

content instance-attribute

The comment content.

QuantitiveAnalysisDescriptor

Bases: BaseModel

The model implementation for report quantitative analysis.

Source code in mlte/report/model.py
21
22
23
24
25
26
class QuantitiveAnalysisDescriptor(BaseModel):
    """The model implementation for report quantitative analysis."""

    # TODO(Kyle): This is not implemented.
    content: Optional[str] = None
    """The field content."""

content = None class-attribute instance-attribute

The field content.

ReportModel

Bases: BaseModel

The model implementation for the MLTE report artifact.

Source code in mlte/report/model.py
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
class ReportModel(BaseModel):
    """The model implementation for the MLTE report artifact."""

    artifact_type: Literal[ArtifactType.REPORT] = ArtifactType.REPORT
    """Union discriminator."""

    nc_data: NegotiationCardDataModel = NegotiationCardDataModel()
    """The specific data from a negotiation card."""

    validated_spec_id: Optional[str] = None
    """The findings from MLTE evaluation."""

    comments: List[CommentDescriptor] = []
    """Comments included in the report."""

    quantitative_analysis: QuantitiveAnalysisDescriptor = (
        QuantitiveAnalysisDescriptor()
    )
    """Quantitative analysis included in the report."""

artifact_type = ArtifactType.REPORT class-attribute instance-attribute

Union discriminator.

comments = [] class-attribute instance-attribute

Comments included in the report.

nc_data = NegotiationCardDataModel() class-attribute instance-attribute

The specific data from a negotiation card.

quantitative_analysis = QuantitiveAnalysisDescriptor() class-attribute instance-attribute

Quantitative analysis included in the report.

validated_spec_id = None class-attribute instance-attribute

The findings from MLTE evaluation.