All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.machinelearningservices.kotlin.inputs.TextClassificationArgs.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azurenative.machinelearningservices.kotlin.inputs

import com.pulumi.azurenative.machinelearningservices.inputs.TextClassificationArgs.builder
import com.pulumi.azurenative.machinelearningservices.kotlin.enums.ClassificationPrimaryMetrics
import com.pulumi.azurenative.machinelearningservices.kotlin.enums.LogVerbosity
import com.pulumi.core.Either
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 * Text Classification task in AutoML NLP vertical.
 * NLP - Natural Language Processing.
 * @property featurizationSettings Featurization inputs needed for AutoML job.
 * @property limitSettings Execution constraints for AutoMLJob.
 * @property logVerbosity Log verbosity for the job.
 * @property primaryMetric Primary metric for Text-Classification task.
 * @property targetColumnName Target column name: This is prediction values column.
 * Also known as label column name in context of classification tasks.
 * @property taskType AutoMLJob Task type.
 * Expected value is 'TextClassification'.
 * @property trainingData [Required] Training data input.
 * @property validationData Validation data inputs.
 */
public data class TextClassificationArgs(
    public val featurizationSettings: Output? = null,
    public val limitSettings: Output? = null,
    public val logVerbosity: Output>? = null,
    public val primaryMetric: Output>? = null,
    public val targetColumnName: Output? = null,
    public val taskType: Output,
    public val trainingData: Output,
    public val validationData: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.machinelearningservices.inputs.TextClassificationArgs =
        com.pulumi.azurenative.machinelearningservices.inputs.TextClassificationArgs.builder()
            .featurizationSettings(
                featurizationSettings?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .limitSettings(limitSettings?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .logVerbosity(
                logVerbosity?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .primaryMetric(
                primaryMetric?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .targetColumnName(targetColumnName?.applyValue({ args0 -> args0 }))
            .taskType(taskType.applyValue({ args0 -> args0 }))
            .trainingData(trainingData.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .validationData(
                validationData?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            ).build()
}

/**
 * Builder for [TextClassificationArgs].
 */
@PulumiTagMarker
public class TextClassificationArgsBuilder internal constructor() {
    private var featurizationSettings: Output? = null

    private var limitSettings: Output? = null

    private var logVerbosity: Output>? = null

    private var primaryMetric: Output>? = null

    private var targetColumnName: Output? = null

    private var taskType: Output? = null

    private var trainingData: Output? = null

    private var validationData: Output? = null

    /**
     * @param value Featurization inputs needed for AutoML job.
     */
    @JvmName("ipqvbcatwdqjkjob")
    public suspend fun featurizationSettings(`value`: Output) {
        this.featurizationSettings = value
    }

    /**
     * @param value Execution constraints for AutoMLJob.
     */
    @JvmName("qxvpgsqifiqatdxr")
    public suspend fun limitSettings(`value`: Output) {
        this.limitSettings = value
    }

    /**
     * @param value Log verbosity for the job.
     */
    @JvmName("vymkbuisafhicdat")
    public suspend fun logVerbosity(`value`: Output>) {
        this.logVerbosity = value
    }

    /**
     * @param value Primary metric for Text-Classification task.
     */
    @JvmName("inaksexqkrrqaqyo")
    public suspend fun primaryMetric(`value`: Output>) {
        this.primaryMetric = value
    }

    /**
     * @param value Target column name: This is prediction values column.
     * Also known as label column name in context of classification tasks.
     */
    @JvmName("cfawrsxlkjvikjhm")
    public suspend fun targetColumnName(`value`: Output) {
        this.targetColumnName = value
    }

    /**
     * @param value AutoMLJob Task type.
     * Expected value is 'TextClassification'.
     */
    @JvmName("dyjyahrckuddflhp")
    public suspend fun taskType(`value`: Output) {
        this.taskType = value
    }

    /**
     * @param value [Required] Training data input.
     */
    @JvmName("gawqqadspnnptopa")
    public suspend fun trainingData(`value`: Output) {
        this.trainingData = value
    }

    /**
     * @param value Validation data inputs.
     */
    @JvmName("eulhlrkjxggbsnvd")
    public suspend fun validationData(`value`: Output) {
        this.validationData = value
    }

    /**
     * @param value Featurization inputs needed for AutoML job.
     */
    @JvmName("vyajfkmbskcncguo")
    public suspend fun featurizationSettings(`value`: NlpVerticalFeaturizationSettingsArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.featurizationSettings = mapped
    }

    /**
     * @param argument Featurization inputs needed for AutoML job.
     */
    @JvmName("evtxtkjfjfkoxera")
    public suspend fun featurizationSettings(argument: suspend NlpVerticalFeaturizationSettingsArgsBuilder.() -> Unit) {
        val toBeMapped = NlpVerticalFeaturizationSettingsArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.featurizationSettings = mapped
    }

    /**
     * @param value Execution constraints for AutoMLJob.
     */
    @JvmName("ifunwnhrdkrcdctl")
    public suspend fun limitSettings(`value`: NlpVerticalLimitSettingsArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.limitSettings = mapped
    }

    /**
     * @param argument Execution constraints for AutoMLJob.
     */
    @JvmName("scqlgoxqujfylyen")
    public suspend fun limitSettings(argument: suspend NlpVerticalLimitSettingsArgsBuilder.() -> Unit) {
        val toBeMapped = NlpVerticalLimitSettingsArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.limitSettings = mapped
    }

    /**
     * @param value Log verbosity for the job.
     */
    @JvmName("uegppaaqaoblogqq")
    public suspend fun logVerbosity(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.logVerbosity = mapped
    }

    /**
     * @param value Log verbosity for the job.
     */
    @JvmName("dmgnbxccboyqcqki")
    public fun logVerbosity(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.logVerbosity = mapped
    }

    /**
     * @param value Log verbosity for the job.
     */
    @JvmName("naprbhexywsunbdp")
    public fun logVerbosity(`value`: LogVerbosity) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.logVerbosity = mapped
    }

    /**
     * @param value Primary metric for Text-Classification task.
     */
    @JvmName("nbardgrdmthtcxwe")
    public suspend fun primaryMetric(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.primaryMetric = mapped
    }

    /**
     * @param value Primary metric for Text-Classification task.
     */
    @JvmName("oqrdkxpvdiysuqxf")
    public fun primaryMetric(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.primaryMetric = mapped
    }

    /**
     * @param value Primary metric for Text-Classification task.
     */
    @JvmName("jesfanbxkmvayqub")
    public fun primaryMetric(`value`: ClassificationPrimaryMetrics) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.primaryMetric = mapped
    }

    /**
     * @param value Target column name: This is prediction values column.
     * Also known as label column name in context of classification tasks.
     */
    @JvmName("pyrvnaxxlgqwmkns")
    public suspend fun targetColumnName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.targetColumnName = mapped
    }

    /**
     * @param value AutoMLJob Task type.
     * Expected value is 'TextClassification'.
     */
    @JvmName("cmkuvnsvfmljcrnl")
    public suspend fun taskType(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.taskType = mapped
    }

    /**
     * @param value [Required] Training data input.
     */
    @JvmName("cgdtdlxmeoqdlbym")
    public suspend fun trainingData(`value`: MLTableJobInputArgs) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.trainingData = mapped
    }

    /**
     * @param argument [Required] Training data input.
     */
    @JvmName("gldunsmgstnwrddb")
    public suspend fun trainingData(argument: suspend MLTableJobInputArgsBuilder.() -> Unit) {
        val toBeMapped = MLTableJobInputArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.trainingData = mapped
    }

    /**
     * @param value Validation data inputs.
     */
    @JvmName("lfdbnqykyahwgdum")
    public suspend fun validationData(`value`: MLTableJobInputArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.validationData = mapped
    }

    /**
     * @param argument Validation data inputs.
     */
    @JvmName("qxqpmuqugotqepbb")
    public suspend fun validationData(argument: suspend MLTableJobInputArgsBuilder.() -> Unit) {
        val toBeMapped = MLTableJobInputArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.validationData = mapped
    }

    internal fun build(): TextClassificationArgs = TextClassificationArgs(
        featurizationSettings = featurizationSettings,
        limitSettings = limitSettings,
        logVerbosity = logVerbosity,
        primaryMetric = primaryMetric,
        targetColumnName = targetColumnName,
        taskType = taskType ?: throw PulumiNullFieldException("taskType"),
        trainingData = trainingData ?: throw PulumiNullFieldException("trainingData"),
        validationData = validationData,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy