Run

“Run” in a pipeline signifies the execution of a predefined sequence of tasks that collectively achieve a specific goal, whether it’s building and deploying software, processing data, or automating a set of operations. The concept emphasizes the automation and repeatability of workflows to ensure consistency and efficiency in various domains.

List of Versions

To get the list of Versions, send a GET request to the Pipeline Run Endpoint

https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/{{pipeline_id}}/versions/?apikey={{tapi_key}}
import requests

url = "https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/{{pipeline_id}}/versions/?apikey={{tapi_key}}"

payload={}
headers = {
'Authorization': 'Bearer {{Token}}',
'Content-Type': 'application/json',
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAi...

List of SKU

To get the list of SKU, send a GET request to the Pipeline Run Endpoint

https://api.e2enetworks.com/myaccount/api/v1/gpu/gpu_service/sku/?apikey={{tapi_key}}&image_id=&service=pipeline
import requests

url = "https://api.e2enetworks.com/myaccount/api/v1/gpu/gpu_service/sku/?apikey={{tapi_key}}&image_id=&service=pipeline"

payload={}
headers = {
'Authorization': 'Bearer {{Token}}',
'Content-Type': 'application/json',
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAi...

List of Experiments

To get the list of Experiments, send a GET request to the Pipeline Run Endpoint

https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/experiments?apikey={{tapi_key}}
import requests

url = "https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/experiments?apikey={{tapi_key}}"

payload={}
headers = {
'Authorization': 'Bearer {{Token}}',
'Content-Type': 'application/json',
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAi...

List of Run

To get the list of Runs, send a GET request to the Pipeline Run Endpoint

https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/runs/?page_no=1&page_size=5&apikey={{tapi_key}}
import requests

url = "https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/runs/?page_no=1&page_size=5&apikey={{tapi_key}}"

payload={}
headers = {
'Authorization': 'Bearer {{Token}}',
'Content-Type': 'application/json',
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAi...

Create Run

To create the Run, send a POST request to the Pipeline Run Endpoint

https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/runs/?apikey={{tapi_key}}
import requests
import json

url = "https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/runs/?apikey={{tapi_key}}"

payload = json.dumps({
"sku_id": 81,
"sku_item_price_id": 207,
"next_sku_item_price_id": None,
"committed_instance_policy": "",
"name": "tir-run-070819042323",
"description": "",
"experiment_id": "{{experiment_id}}",
"pipeline_type": "existing",
"pipeline_version_id": "{{version_id}}",
"run_parameter": [
    {
    "name": "workspace_pvc_class",
    "value": "csi-rbd-sc"
    },
    {
    "name": "hf_api_token",
    "value": ""
    },
    {
    "name": "e2e_tir_access_token",
    "value": ""
    },
    {
    "name": "e2e_tir_api_key",
    "value": ""
    },
    {
    "name": "e2e_tir_project_id",
    "value": ""
    },
    {
    "name": "e2e_tir_team_id",
    "value": ""
    },
    {
    "name": "e2e_tir_finetune_job_id",
    "value": ""
    },
    {
    "name": "e2e_tir_api_host",
    "value": ""
    },
    {
    "name": "run_name",
    "value": ""
    },
    {
    "name": "source_model_repo_id",
    "value": "0"
    },
    {
    "name": "source_model_path",
    "value": ""
    },
    {
    "name": "model",
    "value": "google/gemma-7b-it"
    },
    {
    "name": "dataset_name",
    "value": "luisroque/instruct-python-llama2-20k"
    },
    {
    "name": "dataset_text_field",
    "value": "text"
    },
    {
    "name": "dataset_type",
    "value": "huggingface"
    },
    {
    "name": "dataset_bucket",
    "value": ""
    },
    {
    "name": "dataset_path",
    "value": ""
    },
    {
    "name": "dataset_accesskey",
    "value": ""
    },
    {
    "name": "dataset_secretkey",
    "value": ""
    },
    {
    "name": "dataset_split",
    "value": "1"
    },
    {
    "name": "batch_size",
    "value": "1"
    },
    {
    "name": "gradient_accumulation_steps",
    "value": "1"
    },
    {
    "name": "seq_length",
    "value": "512"
    },
    {
    "name": "num_train_epochs",
    "value": "3"
    },
    {
    "name": "max_steps",
    "value": "-1"
    },
    {
    "name": "save_steps",
    "value": "100"
    },
    {
    "name": "save_total_limit",
    "value": "10"
    },
    {
    "name": "use_peft",
    "value": "true"
    },
    {
    "name": "peft_lora_r",
    "value": "64"
    },
    {
    "name": "peft_lora_alpha",
    "value": "16"
    },
    {
    "name": "lora_dropout",
    "value": "0.05"
    },
    {
    "name": "lora_bias",
    "value": "none"
    },
    {
    "name": "load_in_4bit",
    "value": "false"
    },
    {
    "name": "bnb_4bit_compute_dtype",
    "value": "bfloat16"
    },
    {
    "name": "bnb_4bit_quant_type",
    "value": "fp4"
    },
    {
    "name": "bnb_4bit_use_double_quant",
    "value": "false"
    },
    {
    "name": "trust_remote_code",
    "value": "false"
    },
    {
    "name": "use_auth_token",
    "value": "true"
    },
    {
    "name": "trainer_ram",
    "value": "100"
    },
    {
    "name": "trainer_gpus",
    "value": "1"
    },
    {
    "name": "trainer_cores",
    "value": "8"
    },
    {
    "name": "ephemeral_storage",
    "value": "99"
    },
    {
    "name": "finetuner_image",
    "value": "aimle2e/fine-tuner"
    },
    {
    "name": "finetuner_tag",
    "value": "gemma_7b_inst_v5"
    },
    {
    "name": "finetuner_image_policy",
    "value": "Always"
    },
    {
    "name": "sku_type",
    "value": ""
    },
    {
    "name": "wandb_key",
    "value": ""
    },
    {
    "name": "wandb_project",
    "value": ""
    },
    {
    "name": "wandb_run_name",
    "value": ""
    },
    {
    "name": "learning_rate",
    "value": "0.00002"
    },
    {
    "name": "max_train_samples",
    "value": "10"
    },
    {
    "name": "max_eval_samples",
    "value": "10"
    },
    {
    "name": "workspace",
    "value": "/mnt/workspace"
    },
    {
    "name": "torch_cache",
    "value": "/mnt/workspace/torch"
    },
    {
    "name": "transformers_cache",
    "value": "/mnt/workspace/hf"
    },
    {
    "name": "output_dir",
    "value": "/mnt/workspace/finetunes/"
    },
    {
    "name": "prompt_template_base64",
    "value": ""
    },
    {
    "name": "resume",
    "value": "true"
    }
],
"run_type": "run"
})
headers = {
'Authorization': 'Bearer {{Token}}',
'Content-Type': 'application/json',
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAi...
{
"sku_id": 81,
"sku_item_price_id": 207,
"next_sku_item_price_id": null,
"committed_instance_policy": "",
"name": "tir-run-070819042323",
"description": "",
"experiment_id": "{{experiment_id}}",
"pipeline_type": "existing",
"pipeline_version_id": "{{version_id}}",
"run_parameter": [
    {
        "name": "workspace_pvc_class",
        "value": "csi-rbd-sc"
    },
    {
        "name": "hf_api_token",
        "value": ""
    },
    {
        "name": "e2e_tir_access_token",
        "value": ""
    },
    {
        "name": "e2e_tir_api_key",
        "value": ""
    },
    {
        "name": "e2e_tir_project_id",
        "value": ""
    },
    {
        "name": "e2e_tir_team_id",
        "value": ""
    },
    {
        "name": "e2e_tir_finetune_job_id",
        "value": ""
    },
    {
        "name": "e2e_tir_api_host",
        "value": ""
    },
    {
        "name": "run_name",
        "value": ""
    },
    {
        "name": "source_model_repo_id",
        "value": "0"
    },
    {
        "name": "source_model_path",
        "value": ""
    },
    {
        "name": "model",
        "value": "google/gemma-7b-it"
    },
    {
        "name": "dataset_name",
        "value": "luisroque/instruct-python-llama2-20k"
    },
    {
        "name": "dataset_text_field",
        "value": "text"
    },
    {
        "name": "dataset_type",
        "value": "huggingface"
    },
    {
        "name": "dataset_bucket",
        "value": ""
    },
    {
        "name": "dataset_path",
        "value": ""
    },
    {
        "name": "dataset_accesskey",
        "value": ""
    },
    {
        "name": "dataset_secretkey",
        "value": ""
    },
    {
        "name": "dataset_split",
        "value": "1"
    },
    {
        "name": "batch_size",
        "value": "1"
    },
    {
        "name": "gradient_accumulation_steps",
        "value": "1"
    },
    {
        "name": "seq_length",
        "value": "512"
    },
    {
        "name": "num_train_epochs",
        "value": "3"
    },
    {
        "name": "max_steps",
        "value": "-1"
    },
    {
        "name": "save_steps",
        "value": "100"
    },
    {
        "name": "save_total_limit",
        "value": "10"
    },
    {
        "name": "use_peft",
        "value": "true"
    },
    {
        "name": "peft_lora_r",
        "value": "64"
    },
    {
        "name": "peft_lora_alpha",
        "value": "16"
    },
    {
        "name": "lora_dropout",
        "value": "0.05"
    },
    {
        "name": "lora_bias",
        "value": "none"
    },
    {
        "name": "load_in_4bit",
        "value": "false"
    },
    {
        "name": "bnb_4bit_compute_dtype",
        "value": "bfloat16"
    },
    {
        "name": "bnb_4bit_quant_type",
        "value": "fp4"
    },
    {
        "name": "bnb_4bit_use_double_quant",
        "value": "false"
    },
    {
        "name": "trust_remote_code",
        "value": "false"
    },
    {
        "name": "use_auth_token",
        "value": "true"
    },
    {
        "name": "trainer_ram",
        "value": "100"
    },
    {
        "name": "trainer_gpus",
        "value": "1"
    },
    {
        "name": "trainer_cores",
        "value": "8"
    },
    {
        "name": "ephemeral_storage",
        "value": "99"
    },
    {
        "name": "finetuner_image",
        "value": "aimle2e/fine-tuner"
    },
    {
        "name": "finetuner_tag",
        "value": "gemma_7b_inst_v5"
    },
    {
        "name": "finetuner_image_policy",
        "value": "Always"
    },
    {
        "name": "sku_type",
        "value": ""
    },
    {
        "name": "wandb_key",
        "value": ""
    },
    {
        "name": "wandb_project",
        "value": ""
    },
    {
        "name": "wandb_run_name",
        "value": ""
    },
    {
        "name": "learning_rate",
        "value": "0.00002"
    },
    {
        "name": "max_train_samples",
        "value": "10"
    },
    {
        "name": "max_eval_samples",
        "value": "10"
    },
    {
        "name": "workspace",
        "value": "/mnt/workspace"
    },
    {
        "name": "torch_cache",
        "value": "/mnt/workspace/torch"
    },
    {
        "name": "transformers_cache",
        "value": "/mnt/workspace/hf"
    },
    {
        "name": "output_dir",
        "value": "/mnt/workspace/finetunes/"
    },
    {
        "name": "prompt_template_base64",
        "value": ""
    },
    {
        "name": "resume",
        "value": "true"
    }
],
"run_type": "run"
}

Delete Run

To Delete the Run, send a DELETE request to the Pipeline Run Endpoint

https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/runs/?apikey={{tapi_key}}
import requests
import json

url = "https://api.e2enetworks.com/myaccount/api/v1/gpu/projects/{{project_id}}/pipelines/runs/?apikey={{tapi_key}}"

payload = json.dumps({
"sku_id": 81,
"sku_item_price_id": 207,
"next_sku_item_price_id": None,
"committed_instance_policy": "",
"name": "tir-run-070819042323",
"description": "",
"experiment_id": "{{experiment_id}}",
"pipeline_type": "existing",
"pipeline_version_id": "{{version_id}}",
"run_parameter": [
    {
    "name": "workspace_pvc_class",
    "value": "csi-rbd-sc"
    },
    {
    "name": "hf_api_token",
    "value": ""
    },
    {
    "name": "e2e_tir_access_token",
    "value": ""
    },
    {
    "name": "e2e_tir_api_key",
    "value": ""
    },
    {
    "name": "e2e_tir_project_id",
    "value": ""
    },
    {
    "name": "e2e_tir_team_id",
    "value": ""
    },
    {
    "name": "e2e_tir_finetune_job_id",
    "value": ""
    },
    {
    "name": "e2e_tir_api_host",
    "value": ""
    },
    {
    "name": "run_name",
    "value": ""
    },
    {
    "name": "source_model_repo_id",
    "value": "0"
    },
    {
    "name": "source_model_path",
    "value": ""
    },
    {
    "name": "model",
    "value": "google/gemma-7b-it"
    },
    {
    "name": "dataset_name",
    "value": "luisroque/instruct-python-llama2-20k"
    },
    {
    "name": "dataset_text_field",
    "value": "text"
    },
    {
    "name": "dataset_type",
    "value": "huggingface"
    },
    {
    "name": "dataset_bucket",
    "value": ""
    },
    {
    "name": "dataset_path",
    "value": ""
    },
    {
    "name": "dataset_accesskey",
    "value": ""
    },
    {
    "name": "dataset_secretkey",
    "value": ""
    },
    {
    "name": "dataset_split",
    "value": "1"
    },
    {
    "name": "batch_size",
    "value": "1"
    },
    {
    "name": "gradient_accumulation_steps",
    "value": "1"
    },
    {
    "name": "seq_length",
    "value": "512"
    },
    {
    "name": "num_train_epochs",
    "value": "3"
    },
    {
    "name": "max_steps",
    "value": "-1"
    },
    {
    "name": "save_steps",
    "value": "100"
    },
    {
    "name": "save_total_limit",
    "value": "10"
    },
    {
    "name": "use_peft",
    "value": "true"
    },
    {
    "name": "peft_lora_r",
    "value": "64"
    },
    {
    "name": "peft_lora_alpha",
    "value": "16"
    },
    {
    "name": "lora_dropout",
    "value": "0.05"
    },
    {
    "name": "lora_bias",
    "value": "none"
    },
    {
    "name": "load_in_4bit",
    "value": "false"
    },
    {
    "name": "bnb_4bit_compute_dtype",
    "value": "bfloat16"
    },
    {
    "name": "bnb_4bit_quant_type",
    "value": "fp4"
    },
    {
    "name": "bnb_4bit_use_double_quant",
    "value": "false"
    },
    {
    "name": "trust_remote_code",
    "value": "false"
    },
    {
    "name": "use_auth_token",
    "value": "true"
    },
    {
    "name": "trainer_ram",
    "value": "100"
    },
    {
    "name": "trainer_gpus",
    "value": "1"
    },
    {
    "name": "trainer_cores",
    "value": "8"
    },
    {
    "name": "ephemeral_storage",
    "value": "99"
    },
    {
    "name": "finetuner_image",
    "value": "aimle2e/fine-tuner"
    },
    {
    "name": "finetuner_tag",
    "value": "gemma_7b_inst_v5"
    },
    {
    "name": "finetuner_image_policy",
    "value": "Always"
    },
    {
    "name": "sku_type",
    "value": ""
    },
    {
    "name": "wandb_key",
    "value": ""
    },
    {
    "name": "wandb_project",
    "value": ""
    },
    {
    "name": "wandb_run_name",
    "value": ""
    },
    {
    "name": "learning_rate",
    "value": "0.00002"
    },
    {
    "name": "max_train_samples",
    "value": "10"
    },
    {
    "name": "max_eval_samples",
    "value": "10"
    },
    {
    "name": "workspace",
    "value": "/mnt/workspace"
    },
    {
    "name": "torch_cache",
    "value": "/mnt/workspace/torch"
    },
    {
    "name": "transformers_cache",
    "value": "/mnt/workspace/hf"
    },
    {
    "name": "output_dir",
    "value": "/mnt/workspace/finetunes/"
    },
    {
    "name": "prompt_template_base64",
    "value": ""
    },
    {
    "name": "resume",
    "value": "true"
    }
],
"run_type": "run"
})
headers = {
'Authorization': 'Bearer {{Token}}',
'Content-Type': 'application/json',
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAi...