Train your own model for Search and AI Models
curl --request POST \
--url https://api.worqhat.com/api/ai/datasets/train-datasets \
--header 'Authorization: <authorization>' \
--header 'Content-Type: multi-part/form-data' \
--data '{
"datasetId": "1234567890",
"dataset_name": "Sample Dataset",
"dataset_type": "self",
"json_data": "{'\''data'\'': '\''This is a sample data'\''}",
"training_file": "sample.csv"
}'
{
"data": {
"dataset_description": "",
"dataset_id": "0109c3db-5968-4704-b99e-84d1b8201319",
"dataset_name": "sampled ataset",
"dataset_timestamp": {
"_clock_hash": 762483,
"_seconds": 1697742460
},
"status": "Training",
"training_for": "Self"
},
"processing_count": 132,
"processing_id": "9cb58eda-8ff3-417c-a5d0-1b427471a3d4",
"processing_time": 5359,
"status": "success"
}
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
The ID of the Dataset that you want to train. This is optional. If you don't pass a Dataset ID, we will generate a random ID for you. Make sure this is unique. You can pass in a old id if you want to add in more data to your existing Trained Dataset.
The Name of the Dataset that you want to train.
The Type of the Training Dataset after Saving. It can be either self
or org
.
self
, org
The JSON Data that you want to train. You can pass in the JSON Data in the form of a stringified JSON.
The Training File that you want to train. You can pass in the Training File in the form of a CSV or a PDF file.
Response
The information about the created dataset.
The number of times the request has been processed. This is what is considered in the Billing Process. This is either the number of times the image is processed or the number of words that the server processes.
A universally unique identifier for the request. This can be used to track the request in the logs.
The time taken to process the request, in milliseconds.
Status indicating the success of the Dataset Creation Process.
Was this page helpful?
curl --request POST \
--url https://api.worqhat.com/api/ai/datasets/train-datasets \
--header 'Authorization: <authorization>' \
--header 'Content-Type: multi-part/form-data' \
--data '{
"datasetId": "1234567890",
"dataset_name": "Sample Dataset",
"dataset_type": "self",
"json_data": "{'\''data'\'': '\''This is a sample data'\''}",
"training_file": "sample.csv"
}'
{
"data": {
"dataset_description": "",
"dataset_id": "0109c3db-5968-4704-b99e-84d1b8201319",
"dataset_name": "sampled ataset",
"dataset_timestamp": {
"_clock_hash": 762483,
"_seconds": 1697742460
},
"status": "Training",
"training_for": "Self"
},
"processing_count": 132,
"processing_id": "9cb58eda-8ff3-417c-a5d0-1b427471a3d4",
"processing_time": 5359,
"status": "success"
}