Tracing

Creates a new trace on Confident AI.

post/v1/traces

Request

Request body

uuidstring required

This is the unique identifier of the trace.

namestring

This is the name of the trace.

inputstring

This is the input to the trace.

outputstring

This is the output of the trace.

startTimestring date-time required

This is the time the trace started.

endTimestring date-time required

This is the time the trace ended.

environment'production' | 'development' | 'staging' | 'testing'

This is the environment where your trace was posted, which helps with separating and debugging traces from different environments on the Confident AI platform.

metadataobject

This is any additional metadata associated with the trace.

tagsstring[]

This is any tags associated with the trace, which helps with grouping traces and filtering them on the Confident AI platform.

threadIdstring

This is the unique identifier of the thread associated with the trace.

userIdstring

This is the unique identifier for your end user for the trace.

metricCollectionstring

This is the metric collection you wish to use to evaluate the trace.

testRunIdstring

This is the unique identifier of the test run to associate the trace with. When set, the trace becomes one test case in that test run, and metricCollection is required. Create a test run with the POST /v1/test-runs endpoint to get this id.

retrievalContextstring[]

This is the retrieval context of your trace, which is to be used for evaluation.

contextstring[]

This is the ideal retrieval context of your trace, which is to be used for evaluation.

expectedOutputstring

This is the expected output of your trace, which is the ideal actual output and to be used for evaluation.

attachmentsobject

Map of attachment ids to payloads for all [DEEPEVAL:IMAGE:…] and [DEEPEVAL:PDF:…] markers in this trace. Define attachments at the trace level with same ids for same instances.

Response

successboolean required

A boolean indicating the success or failure of the API call

linkstring required

This is the URL to the trace on the Confident AI platform.

deprecatedboolean required

This is true if this endpoint is deprecated.

Changes