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_URLenvironment 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 |
|---|---|---|
|
No |
Name for this customization job. Auto-generated if not provided |
|
Yes |
Workspace where the job runs. Determines what datasets and models are authorized to be used in the job. |
|
Yes |
Reference to the Model Entity ( |
|
Yes |
Dataset URI ( |
|
Yes |
Training method and hyperparameters (see Training Configuration) |
|
Yes |
Training method: |
|
No |
PEFT adapter configuration (e.g., |
|
No |
Output artifact configuration ( |
|
No |
Deployment configuration. Pass a string to reference an existing config by name, or an object with inline NIM deployment parameters (e.g., |
Training Output#
When training completes, the system automatically:
Uploads artifacts to a new FileSet (
output.fileset)Creates the output based on PEFT configuration:
PEFT Configuration |
Output Created |
|---|---|
|
Adapter attached to the parent Model Entity |
|
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:
Properties
typeobject - Supervised Fine-Tuning.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.object - Direct Preference Optimization.Properties
Properties
^[a-z0-9_-]+(/[a-z0-9_-]+)?$Properties
string - A reference to DeploymentParams.object - Inline deployment parameters for creating a new ModelDeploymentConfig.{'name': 'my-finetuned-llama'}Properties
my-finetuned-llamallama-3-8b-lora-v2^[\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 |
|---|---|
|
W&B project name. Defaults to |
|
W&B entity (team or username) |
|
List of tags for filtering runs |
|
Reference to a secret containing |
|
W&B run name. Defaults to the job ID if not provided |
|
Notes or description for the run |
|
Base URL for self-hosted W&B servers (e.g., |
To view your training metrics in W&B after the job starts, see Using Weights & Biases.
Field |
Description |
|---|---|
|
W&B project name. Defaults to |
|
W&B entity (team or username) |
|
List of tags for filtering runs |
|
Reference to a secret containing |
|
W&B run name. Defaults to the job ID if not provided |
|
Notes or description for the run |
|
Base URL for self-hosted W&B servers (e.g., |
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 |
|---|---|
|
MLflow experiment name. Defaults to |
|
MLflow tracking server URI. Can also be set via |
|
MLflow run name. Defaults to the job ID if not provided |
|
Key-value pairs for filtering runs (e.g., |
|
Description for the MLflow run |