Create task
    • PDF

    Create task

    • PDF

    Article summary

    Available in Classic and VPC

    Create a task model.

    When a user requests the creation of task, the NCLUE system registers the request job and returns the task ID. The creation process is as follows.

    Creation process

    OrderCreation statusDescription
    Step 1Registered registeredStatus where the creation job is registered in the system. It is the status before starting the job. You can cancel the job by deleting it at this point
    Step 2Pending pendingStatus where the creation job is queued in the system
    Step 3Creating in_progressStatus where the job is being executed on the server. Creation time varies depending on the service's available resources
    Step 4Creation complete
    • Available completed
    • Failed failed
    Once creation is complete, it will be available for use when successful with the "Available" status. If an error occurs during the operation, it will be in the "Failed" status, and the error message can be used to troubleshoot the problem

    The creation of task varies in time depending on the service's available resources. To check the progress of the creation, call the Get task API and check the "status" field in the response body.

    Request

    This section describes the request format. The method and URI are as follows:

    MethodURI
    POST/api/v1/tasks

    Request headers

    For information about the headers common to all NCLUE APIs, see Common NCLUE headers.

    Request body

    You can include the following data in the body of your request:

    FieldTypeRequiredDescription
    nameStringRequiredTask name (40-character limit)
    train_feature_idStringRequiredID of the feature applied to the task model
    train_bucketStringRequiredBucket name of Object Storage where the correct answer dataset file for training the task model is stored
    train_file_pathStringRequiredCorrect answer dataset file path in the train_bucket bucket
    • File paths containing the following special characters can't be entered
      • &$@=;:+,?*\{}^%`[]<>~#\|"'
      • Characters with ASCII codes 0 to 31 and 128 to 255
    test_feature_idStringOptionalFeature ID for the test set set separately for evaluating the performance of the task model
    test_bucketStringOptionalBucket name of Object Storage where the correct answer dataset file for test set is stored
    test_file_pathStringOptionalCorrect answer dataset for test set file path in the test_bucket bucket
    • File paths containing the following special characters can't be entered
      • &$@=;:+,?*\{}^%`[]<>~#\|"'
      • Characters with ASCII codes 0 to 31 and 128 to 255

    Request example

    The request example is as follows:

    curl --location --request POST 'https://nclue.apigw.ntruss.com/api/v1/tasks' \
    --header 'X-NCP-APIGW-TIMESTAMP: {Timestamp}' \
    --header 'X-NCP-IAM-ACCESS-KEY: {Access Key}' \
    --header 'X-NCP-APIGW-SIGNATURE-V2: {API Gateway Signature}' 
    --data '{
      "name": "Prediction model for pet food purchase interest",
      "train_file_path": "task_dataset/pet_food.tsv"
      "train_feature_id":"79eb85b5-8ec5-4e1a-8617-64a1977c8062",
      "train_bucket":"your.bucket.name",
      "train_file_path":"task_dataset/pet_food.tsv"
    }'
    

    Response

    This section describes the response format.

    Response body

    The response body includes the following data:

    FieldTypeRequiredDescription
    task_idString-Task ID
    task_nameString-Name of task entered by the user
    created_atString-Task creation request date (ISO 8601 format)
    train_feature_idString-Feature ID for training set
    train_feature_nameString-Feature name for training set
    train_bucketString-Bucket name of Object Storage where the correct answer dataset file for training the task model is stored
    train_file_pathString-File path of the correct answer dataset in the train_bucket bucket
    test_feature_idString-Feature ID for the test set set separately for evaluating the performance of the trained model
    test_feature_nameString-Feature name for test set
    test_bucketString-Bucket name of Object Storage where the correct answer dataset file for test set is stored
    test_file_pathString-File path of the correct answer dataset for test set in the train_bucket bucket

    Response example

    The response example is as follows:

    Succeeded

    The following is a sample response upon a successful call.

    {
        "task_id":"b5e742f1-0558-465a-8485-3b7808b0e125",
        "task_name":"Prediction model for pet food purchase interest",
        "created_at":"2024-11-03T16:20:52+09:00",
        "train_feature_id":"79eb85b5-8ec5-4e1a-8617-64a1977c8062",
        "train_feature_name":"Shopping behavior sequence - 2024",
        "train_bucket":"your.bucket.name",
        "train_file_path":"task_dataset/pet_food.tsv",
        "test_feature_id":null,
        "test_feature_name":null,
        "test_bucket":null,
        "test_file_path":null
    }
    

    Failure

    For examples of responses in the event of a failed call, see Response status codes.


    Was this article helpful?

    What's Next
    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.