Create Job#

Prerequisites#

Before you can create a customization job, make sure that you have:

  • Obtained the base URL of your NeMo Platform.

  • Created a FileSet and Model Entity for your base model.

  • Uploaded a dataset as a FileSet.

  • Determined the training configuration you want to use for the customization job.

  • Verified that the platform has sufficient storage for the job. Full SFT jobs require approximately 3× the base model size in free disk space; LoRA jobs require approximately 1.5×. See Understanding NeMo Customizer: Models, Training, and Resources for details. If you are also deploying the model from a base checkpoint fileset, plan for ~2.5× model size overall for LoRA.

  • Set the NMP_BASE_URL environment variable to your NeMo Platform endpoint.

export NMP_BASE_URL="https://your-nemo-platform-url"

To Create a Customization Job#

Use the SDK to create a customization job:

import os
from nemo_platform import NeMoPlatform

# Initialize the client
client = NeMoPlatform(
    base_url=os.environ.get("NMP_BASE_URL", "http://localhost:8080"),
    workspace="default",
)

# Create a customization job
job = client.customization.jobs.create(
    name="my-lora-job",
    workspace="default",
    spec={
        "model": "default/llama-3-2-1b",  # Model Entity (workspace/name format)
        "dataset": "fileset://default/my-training-dataset",
        "training": {
            "type": "sft",
            "peft": {
                "type": "lora",
                "rank": 8,
                "alpha": 32,
                "dropout": 0.0
            },
            "batch_size": 32,
            "epochs": 3,
            "learning_rate": 1e-4,
            "max_seq_length": 2048
        },
        "output": {"name": "my-custom-model"},  # Optional: auto-generated if not provided
        "deployment_config": {
            "lora_enabled": True  # Optional: deploy base model with LoRA support
        }
    }
)

print(f"Created job: {job.name}")
print(f"Job status: {job.status}")
Example Response
{
  "name": "my-lora-job",
  "workspace": "default",
  "id": "job-abc123def456",
  "status": "created",
  "spec": {
    "model": "default/llama-3-2-1b",
    "dataset": "fileset://default/my-training-dataset",
    "training": {
      "type": "sft",
      "peft": {
        "type": "lora",
        "rank": 8,
        "alpha": 32,
        "dropout": 0.0
      },
      "batch_size": 32,
      "epochs": 3,
      "learning_rate": 0.0001,
      "max_seq_length": 2048
    },
    "output": {"name": "my-custom-model", "type": "adapter", "fileset": "my-custom-model-a1b2c3d4e5f6"}
  },
  "created_at": "2026-02-09T10:30:00.000Z",
  "updated_at": "2026-02-09T10:30:00.000Z"
}

Key Fields#

All job configuration (model, dataset, training, and output) is specified in the job spec.

Field

Required

Description

name

No

Name for this customization job. Auto-generated if not provided

workspace

Yes

Workspace where the job runs. Determines what datasets and models are authorized to be used in the job.

spec.model

Yes

Reference to the Model Entity (workspace/name format)

spec.dataset

Yes

Dataset URI (fileset://workspace/name)

spec.training

Yes

Training method and hyperparameters (see Training Configuration)

spec.training.type

Yes

Training method: sft, distillation, or dpo

spec.training.peft

No

PEFT adapter configuration (e.g., {"type": "lora", ...}). Omit for full-weight training

spec.output

No

Output artifact configuration ({"name": "..."}). Auto-generated if not provided

spec.deployment_config

No

Deployment configuration. Pass a string to reference an existing config by name, or an object with inline NIM deployment parameters (e.g., {"lora_enabled": true}). Omit to skip deployment


Training Output#

When training completes, the system automatically:

  1. Uploads artifacts to a new FileSet (output.fileset)

  2. Creates the output based on PEFT configuration:

PEFT Configuration

Output Created

peft: { type: "lora", ... }

Adapter attached to the parent Model Entity

peft omitted

New Model Entity with all model weights (complete fine-tuned model)

LoRA Adapters#

For LoRA jobs, the adapter is added to the parent Model Entity’s adapters list:

# After training completes, retrieve the model to see the adapter
model = client.models.retrieve(workspace="default", name="llama-3-2-1b")

for adapter in model.adapters or []:
    print(f"Adapter: {adapter.name}")
    print(f"  Fileset: {adapter.fileset}")
    print(f"  Enabled: {adapter.enabled}")

Adapters are enabled by default and will automatically be loaded by NIMs serving this model with LoRA support.


Complete API Reference#

For a complete reference of all customization job fields with constraints and types:

CustomizationJobInput object
Input schema for creating customization jobs.
Properties
model * string
Model reference (e.g., 'workspace/model-name').
dataset * string
Dataset URI. Supported protocol: fileset:// (e.g., fileset://workspace/name).
training * object | object | object
Training method and hyperparameters.
Discriminator: property: type
One of:
Option 1: object - Supervised Fine-Tuning.
Option 2: object - Knowledge Distillation with a teacher model. Customizer's differentiator — not available in Unsloth. Trains the student model to match the teacher's output distribution.
Option 3: object - Direct Preference Optimization.
integrations object
Third-party integrations (e.g., Weights & Biases, MLflow).
Properties
wandb object
Weights & Biases integration configuration.
Properties
project string
W&B project name (groups related runs). Defaults to output.name if not set.
name string
W&B run name. Defaults to job_id if not provided.
entity string
W&B entity (team or username).
tags array
W&B tags for filtering runs.
Array items:
item string
notes string
W&B notes/description for the run.
base_url string
Base URL for self-hosted W&B server (e.g., 'https://wandb.mycompany.com'). If not provided, uses the default W&B cloud service.
api_key_secret string
Reference to a secret containing the WANDB_API_KEY. Format: 'secret_name' (uses request workspace) or 'workspace/secret_name' (explicit workspace).
Constraints: pattern: ^[a-z0-9_-]+(/[a-z0-9_-]+)?$
mlflow object
MLflow integration configuration.
Properties
experiment_name string
MLflow experiment name (groups related runs). Defaults to output.name if not set.
run_name string
MLflow run name. Defaults to job_id if not provided.
tags object
MLflow tags as key-value pairs for filtering runs.
Additional properties schema:
[key: string] string
description string
MLflow run description.
tracking_uri string
MLflow tracking server URI (e.g., 'http://mlflow.mycompany.com:5000'). Can also be set via MLFLOW_TRACKING_URI environment variable.
deployment_config string | object
Deployment configuration for auto-deploying the model after training. Pass a string to reference an existing ModelDeploymentConfig by name (e.g., 'my-config' or 'workspace/my-config'). An object provides inline NIM deployment parameters. Omit to skip deployment.
Any of:
Option 1: string - A reference to DeploymentParams.
Option 2: object - Inline deployment parameters for creating a new ModelDeploymentConfig.
custom_fields object
Custom user-defined fields.
Allows additional properties: Yes
output object
Output artifact configuration. If omitted, name is auto-generated as `{model}-{dataset}-`. The output type (model vs adapter) is always inferred from the training configuration.
Examples:{'name': 'my-finetuned-llama'}
Properties
name * string
Name of the output artifact. Used to identify it during deployment and inference.
Examples:my-finetuned-llamallama-3-8b-lora-v2
Constraints: max length: 255, pattern: ^[\w\-.]+$

Weights & Biases Integration#

To enable W&B integration, add the integrations configuration:

job = client.customization.jobs.create(
    name="my-job",
    workspace="default",
    spec={
        "model": "default/llama-3-2-1b",
        "dataset": "fileset://default/my-dataset",
        "training": {
            "type": "sft",
            "peft": {"type": "lora"},
            "epochs": 3
        },
        "integrations": {
            "wandb": {
                "project": "my-finetuning-project",
                "entity": "my-team",
                "tags": ["fine-tuning", "llama"],
                "api_key_secret": "my-wandb-key"
            }
        }
    }
)

The api_key_secret field references a stored secret containing your WANDB_API_KEY. Use the secret name (e.g., "my-wandb-key") to resolve it from the request workspace. To create the secret, see Weights & Biases Keys.

Field

Description

project

W&B project name. Defaults to output.name if not set

entity

W&B entity (team or username)

tags

List of tags for filtering runs

api_key_secret

Reference to a secret containing WANDB_API_KEY

name

W&B run name. Defaults to the job ID if not provided

notes

Notes or description for the run

base_url

Base URL for self-hosted W&B servers (e.g., https://wandb.mycompany.com). Omit to use W&B cloud

To view your training metrics in W&B after the job starts, see Using Weights & Biases.

Field

Description

project

W&B project name. Defaults to output.name if not set

entity

W&B entity (team or username)

tags

List of tags for filtering runs

api_key_secret

Reference to a secret containing WANDB_API_KEY

name

W&B run name. Defaults to the job ID if not provided

notes

Notes or description for the run

base_url

Base URL for self-hosted W&B servers (e.g., https://wandb.mycompany.com). Omit to use W&B cloud

To view your training metrics in W&B after the job starts, see Using Weights & Biases.


MLflow Integration#

To enable MLflow integration:

job = client.customization.jobs.create(
    name="my-job",
    workspace="default",
    spec={
        "model": "default/llama-3-2-1b",
        "dataset": "fileset://default/my-dataset",
        "training": {
            "type": "sft",
            "peft": {"type": "lora"},
            "epochs": 3
        },
        "integrations": {
            "mlflow": {
                "experiment_name": "llama-finetuning",
                "tracking_uri": "http://mlflow.example.com:5000"
            }
        }
    }
)

Field

Description

experiment_name

MLflow experiment name. Defaults to output.name if not set

tracking_uri

MLflow tracking server URI. Can also be set via MLFLOW_TRACKING_URI environment variable

run_name

MLflow run name. Defaults to the job ID if not provided

tags

Key-value pairs for filtering runs (e.g., {"team": "nlp", "task": "sft"})

description

Description for the MLflow run