Learn how to use the is code test
tests.json
[ { "name": "Outputs have valid Python code", "description": "Asserts that the output column contains valid Python code", "type": "integrity", "subtype": "isCode", "thresholds": [ { "insightName": "isCode", "insightParameters": [ { "name": "column_name", "value": "output" }, // Selects the column `output` { "name": "language", "value": "python" } // Checks for valid Python code ], "measurement": "isCodeRowPercentage", "operator": ">=", "value": 1.0 } ], "subpopulationFilters": null, "mode": "development", "usesValidationDataset": true, // Apply test to the validation set "usesTrainingDataset": false, "usesMlModel": false, "syncId": "b4dee7dc-4f15-48ca-a282-63e2c04e0689" // Some unique id } ]
Was this page helpful?