import SGPClient from 'sgp';
const client = new SGPClient({
apiKey: 'My API Key',
});
const approveAutoGeneratedDraftTestCaseResponse =
await client.evaluationDatasets.autogeneratedDraftTestCases.approve(
'evaluation_dataset_id',
'autogenerated_draft_test_case_id',
);
console.log(approveAutoGeneratedDraftTestCaseResponse.autogenerated_draft_test_case_id);{
"autogenerated_draft_test_case_id": "<string>",
"success": true,
"failed_chunks": [
{
"chunk_text": "<string>",
"artifact_id": "<string>",
"artifact_name": "<string>",
"artifact_content_modification_identifier": "<string>"
}
]
}import SGPClient from 'sgp';
const client = new SGPClient({
apiKey: 'My API Key',
});
const approveAutoGeneratedDraftTestCaseResponse =
await client.evaluationDatasets.autogeneratedDraftTestCases.approve(
'evaluation_dataset_id',
'autogenerated_draft_test_case_id',
);
console.log(approveAutoGeneratedDraftTestCaseResponse.autogenerated_draft_test_case_id);{
"autogenerated_draft_test_case_id": "<string>",
"success": true,
"failed_chunks": [
{
"chunk_text": "<string>",
"artifact_id": "<string>",
"artifact_name": "<string>",
"artifact_content_modification_identifier": "<string>"
}
]
}Force approve a failing test case
Successful Response
Draft test_case_id that has chunk_ids missing
Whether or not the test case was successfully approved
Show child attributes
Text of chunk_id that is missing
Artifact ID of the missing chunk
Artifact Name of the missing chunk
Artifact Content Modification Identifier of the missing chunk