--- title: Training | Scenario Docs description: API reference for enhanced model training methods. --- ## `client.models.train.trigger(modelID, params)` Trigger model training. Returns enhanced response with `response.job.wait()`. See [Jobs](/sdk-helpers/jobs/index.md) for the full `.wait()` reference. **Signature** ``` client.models.train.trigger( modelID: string, params: TrainTriggerParams, options?: RequestOptions, ): APIPromise> ``` **Parameters** | Name | Type | Description | | ----------------------------- | --------- | ------------------------------------ | | `modelID` | `string` | The model ID to train. | | `params.maxSteps?` | `number` | Maximum training steps. | | `params.dryRun?` | `unknown` | If set, validates without executing. | | `params.originalAssets?` | `unknown` | Original asset configuration. | | `params.trainingImagesCount?` | `unknown` | Number of training images to use. | **Returns** `APIPromise>` — The response contains: | Property | Type | Description | | -------- | -------- | ---------------------------------------- | | `job` | `Job` | The training job, with `.wait()` method. | | `model` | `object` | The model data. | **Example** ``` import Scenario from '@scenario-labs/sdk'; const client = new Scenario({ apiKey: '...' }); const response = await client.models.train.trigger('model_my-custom-model', { maxSteps: 1000, }); console.log(response.job.jobId); // 'job_...' console.log(response.job.status); // 'in-progress' const completed = await response.job.wait({ intervalMs: 15_000, // poll every 15 seconds timeoutMs: 900_000, // wait up to 15 minutes }); console.log(completed.status); // 'success' ``` Caution Training jobs can take several minutes to hours. Set `timeoutMs` accordingly.