88
99from ..._models import BaseModel
1010
11- __all__ = ["TestListResponse", "_Meta", "Item", "ItemThreshold", "ItemThresholdInsightParameter"]
12-
13-
14- class _Meta(BaseModel):
15- page: int
16- """The current page."""
17-
18- per_page: int = FieldInfo(alias="perPage")
19- """The number of items per page."""
20-
21- total_items: int = FieldInfo(alias="totalItems")
22- """The total number of items."""
23-
24- total_pages: int = FieldInfo(alias="totalPages")
25- """The total number of pages."""
11+ __all__ = ["TestListResponse", "Item", "ItemThreshold", "ItemThresholdInsightParameter"]
2612
2713
2814class ItemThresholdInsightParameter(BaseModel):
@@ -33,13 +19,55 @@ class ItemThresholdInsightParameter(BaseModel):
3319
3420
3521class ItemThreshold(BaseModel):
36- insight_name: Optional[str] = FieldInfo(alias="insightName", default=None)
22+ insight_name: Optional[
23+ Literal[
24+ "characterLength",
25+ "classImbalance",
26+ "expectColumnAToBeInColumnB",
27+ "columnAverage",
28+ "columnDrift",
29+ "columnValuesMatch",
30+ "confidenceDistribution",
31+ "conflictingLabelRowCount",
32+ "containsPii",
33+ "containsValidUrl",
34+ "correlatedFeatures",
35+ "customMetric",
36+ "duplicateRowCount",
37+ "emptyFeatures",
38+ "featureDrift",
39+ "featureProfile",
40+ "greatExpectations",
41+ "groupByColumnStatsCheck",
42+ "illFormedRowCount",
43+ "isCode",
44+ "isJson",
45+ "llmRubricV2",
46+ "labelDrift",
47+ "metrics",
48+ "newCategories",
49+ "newLabels",
50+ "nullRowCount",
51+ "ppScore",
52+ "quasiConstantFeatures",
53+ "sentenceLength",
54+ "sizeRatio",
55+ "specialCharacters",
56+ "stringValidation",
57+ "trainValLeakageRowCount",
58+ ]
59+ ] = FieldInfo(alias="insightName", default=None)
3760 """The insight name to be evaluated."""
3861
3962 insight_parameters: Optional[List[ItemThresholdInsightParameter]] = FieldInfo(
4063 alias="insightParameters", default=None
4164 )
42- """The insight parameters. Required only for some test subtypes."""
65+ """The insight parameters.
66+
67+ Required only for some test subtypes. For example, for tests that require a
68+ column name, the insight parameters will be [{'name': 'column_name', 'value':
69+ 'Age'}]
70+ """
4371
4472 measurement: Optional[str] = None
4573 """The measurement to be evaluated."""
@@ -168,6 +196,4 @@ class Item(BaseModel):
168196
169197class TestListResponse(BaseModel):
170198 __test__ = False
171- api_meta: _Meta = FieldInfo(alias="_meta")
172-
173199 items: List[Item]
0 commit comments