curl --request POST \
--url https://api.example.com/v1/preview/models/{model_id}/log \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"split": "<string>",
"trajectory_groups": [
{
"trajectories": [
{
"messages_and_choices": [
{
"content": "<string>",
"role": "<string>",
"name": "<string>"
}
],
"reward": 123,
"tools": [
{
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {},
"strict": true
},
"type": "<string>"
}
],
"additional_histories": [],
"metrics": {},
"metadata": {},
"logs": [],
"start_time": "2023-11-07T05:31:56Z"
}
]
}
]
}
'{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Log trajectories and calculate metrics.
curl --request POST \
--url https://api.example.com/v1/preview/models/{model_id}/log \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"split": "<string>",
"trajectory_groups": [
{
"trajectories": [
{
"messages_and_choices": [
{
"content": "<string>",
"role": "<string>",
"name": "<string>"
}
],
"reward": 123,
"tools": [
{
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {},
"strict": true
},
"type": "<string>"
}
],
"additional_histories": [],
"metrics": {},
"metadata": {},
"logs": [],
"start_time": "2023-11-07T05:31:56Z"
}
]
}
]
}
'{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Schema for logging trajectories.
Show child attributes
Show child attributes
Show child attributes
"function"Show child attributes
Show child attributes
Show child attributes
Show child attributes
"function"Successful Response
Was this page helpful?