@@ -79,16 +79,6 @@ export interface FineTune {
7979
8080 learning_rate ?: number ;
8181
82- lora ?: boolean ;
83-
84- lora_alpha ?: number ;
85-
86- lora_dropout ?: number ;
87-
88- lora_r ?: number ;
89-
90- lora_trainable_modules ?: string ;
91-
9282 model ?: string ;
9383
9484 model_output_name ?: string ;
@@ -111,6 +101,8 @@ export interface FineTune {
111101
112102 training_file ?: string ;
113103
104+ training_type ?: FineTune . FullTrainingType | FineTune . LoRaTrainingType ;
105+
114106 trainingfile_numlines ?: number ;
115107
116108 trainingfile_size ?: number ;
@@ -169,6 +161,22 @@ export namespace FineTune {
169161
170162 wandb_url ?: string ;
171163 }
164+
165+ export interface FullTrainingType {
166+ type : 'Full' ;
167+ }
168+
169+ export interface LoRaTrainingType {
170+ lora_alpha : number ;
171+
172+ lora_r : number ;
173+
174+ type : 'Lora' ;
175+
176+ lora_dropout ?: number ;
177+
178+ lora_trainable_modules ?: string ;
179+ }
172180}
173181
174182export interface FineTuneEvent {
@@ -269,32 +277,6 @@ export interface FineTuneCreateParams {
269277 */
270278 learning_rate ?: number ;
271279
272- /**
273- * Whether to enable LoRA training. If not provided, full fine-tuning will be
274- * applied.
275- */
276- lora ?: boolean ;
277-
278- /**
279- * The alpha value for LoRA adapter training.
280- */
281- lora_alpha ?: number ;
282-
283- /**
284- * The dropout probability for Lora layers.
285- */
286- lora_dropout ?: number ;
287-
288- /**
289- * Rank for LoRA adapter weights
290- */
291- lora_r ?: number ;
292-
293- /**
294- * A list of LoRA trainable modules, separated by a comma
295- */
296- lora_trainable_modules ?: string ;
297-
298280 /**
299281 * Number of checkpoints to save during fine-tuning
300282 */
@@ -315,6 +297,8 @@ export interface FineTuneCreateParams {
315297 */
316298 suffix ?: string ;
317299
300+ training_type ?: FineTuneCreateParams . FullTrainingType | FineTuneCreateParams . LoRaTrainingType ;
301+
318302 /**
319303 * File-ID of a validation file uploaded to the Together API
320304 */
@@ -326,6 +310,24 @@ export interface FineTuneCreateParams {
326310 wandb_api_key ?: string ;
327311}
328312
313+ export namespace FineTuneCreateParams {
314+ export interface FullTrainingType {
315+ type : 'Full' ;
316+ }
317+
318+ export interface LoRaTrainingType {
319+ lora_alpha : number ;
320+
321+ lora_r : number ;
322+
323+ type : 'Lora' ;
324+
325+ lora_dropout ?: number ;
326+
327+ lora_trainable_modules ?: string ;
328+ }
329+ }
330+
329331export interface FineTuneDownloadParams {
330332 /**
331333 * Fine-tune ID to download. A string that starts with `ft-`.
0 commit comments