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

com.pulumi.gcp.vertex.kotlin.inputs.AiIndexMetadataConfigArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 8.10.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.vertex.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.vertex.inputs.AiIndexMetadataConfigArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 *
 * @property algorithmConfig The configuration with regard to the algorithms used for efficient search.
 * Structure is documented below.
 * @property approximateNeighborsCount The default number of neighbors to find via approximate search before exact reordering is
 * performed. Exact reordering is a procedure where results returned by an
 * approximate search algorithm are reordered via a more expensive distance computation.
 * Required if tree-AH algorithm is used.
 * @property dimensions The number of dimensions of the input vectors.
 * @property distanceMeasureType The distance measure used in nearest neighbor search. The value must be one of the followings:
 * * SQUARED_L2_DISTANCE: Euclidean (L_2) Distance
 * * L1_DISTANCE: Manhattan (L_1) Distance
 * * COSINE_DISTANCE: Cosine Distance. Defined as 1 - cosine similarity.
 * * DOT_PRODUCT_DISTANCE: Dot Product Distance. Defined as a negative of the dot product
 * @property featureNormType Type of normalization to be carried out on each vector. The value must be one of the followings:
 * * UNIT_L2_NORM: Unit L2 normalization type
 * * NONE: No normalization type is specified.
 * @property shardSize Index data is split into equal parts to be processed. These are called "shards".
 * The shard size must be specified when creating an index. The value must be one of the followings:
 * * SHARD_SIZE_SMALL: Small (2GB)
 * * SHARD_SIZE_MEDIUM: Medium (20GB)
 * * SHARD_SIZE_LARGE: Large (50GB)
 */
public data class AiIndexMetadataConfigArgs(
    public val algorithmConfig: Output? = null,
    public val approximateNeighborsCount: Output? = null,
    public val dimensions: Output,
    public val distanceMeasureType: Output? = null,
    public val featureNormType: Output? = null,
    public val shardSize: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.vertex.inputs.AiIndexMetadataConfigArgs =
        com.pulumi.gcp.vertex.inputs.AiIndexMetadataConfigArgs.builder()
            .algorithmConfig(algorithmConfig?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .approximateNeighborsCount(approximateNeighborsCount?.applyValue({ args0 -> args0 }))
            .dimensions(dimensions.applyValue({ args0 -> args0 }))
            .distanceMeasureType(distanceMeasureType?.applyValue({ args0 -> args0 }))
            .featureNormType(featureNormType?.applyValue({ args0 -> args0 }))
            .shardSize(shardSize?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [AiIndexMetadataConfigArgs].
 */
@PulumiTagMarker
public class AiIndexMetadataConfigArgsBuilder internal constructor() {
    private var algorithmConfig: Output? = null

    private var approximateNeighborsCount: Output? = null

    private var dimensions: Output? = null

    private var distanceMeasureType: Output? = null

    private var featureNormType: Output? = null

    private var shardSize: Output? = null

    /**
     * @param value The configuration with regard to the algorithms used for efficient search.
     * Structure is documented below.
     */
    @JvmName("hahetuehchcjwlrm")
    public suspend fun algorithmConfig(`value`: Output) {
        this.algorithmConfig = value
    }

    /**
     * @param value The default number of neighbors to find via approximate search before exact reordering is
     * performed. Exact reordering is a procedure where results returned by an
     * approximate search algorithm are reordered via a more expensive distance computation.
     * Required if tree-AH algorithm is used.
     */
    @JvmName("kjgwxacnkoofkqyj")
    public suspend fun approximateNeighborsCount(`value`: Output) {
        this.approximateNeighborsCount = value
    }

    /**
     * @param value The number of dimensions of the input vectors.
     */
    @JvmName("mfxpkwipbncanxkm")
    public suspend fun dimensions(`value`: Output) {
        this.dimensions = value
    }

    /**
     * @param value The distance measure used in nearest neighbor search. The value must be one of the followings:
     * * SQUARED_L2_DISTANCE: Euclidean (L_2) Distance
     * * L1_DISTANCE: Manhattan (L_1) Distance
     * * COSINE_DISTANCE: Cosine Distance. Defined as 1 - cosine similarity.
     * * DOT_PRODUCT_DISTANCE: Dot Product Distance. Defined as a negative of the dot product
     */
    @JvmName("atfffuoyitjlcles")
    public suspend fun distanceMeasureType(`value`: Output) {
        this.distanceMeasureType = value
    }

    /**
     * @param value Type of normalization to be carried out on each vector. The value must be one of the followings:
     * * UNIT_L2_NORM: Unit L2 normalization type
     * * NONE: No normalization type is specified.
     */
    @JvmName("nmcoapbqkxvffptx")
    public suspend fun featureNormType(`value`: Output) {
        this.featureNormType = value
    }

    /**
     * @param value Index data is split into equal parts to be processed. These are called "shards".
     * The shard size must be specified when creating an index. The value must be one of the followings:
     * * SHARD_SIZE_SMALL: Small (2GB)
     * * SHARD_SIZE_MEDIUM: Medium (20GB)
     * * SHARD_SIZE_LARGE: Large (50GB)
     */
    @JvmName("xdfplvvtrdstsdob")
    public suspend fun shardSize(`value`: Output) {
        this.shardSize = value
    }

    /**
     * @param value The configuration with regard to the algorithms used for efficient search.
     * Structure is documented below.
     */
    @JvmName("ykapvpkvjkuhinmi")
    public suspend fun algorithmConfig(`value`: AiIndexMetadataConfigAlgorithmConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.algorithmConfig = mapped
    }

    /**
     * @param argument The configuration with regard to the algorithms used for efficient search.
     * Structure is documented below.
     */
    @JvmName("dsxcrnpuoisaliuf")
    public suspend fun algorithmConfig(argument: suspend AiIndexMetadataConfigAlgorithmConfigArgsBuilder.() -> Unit) {
        val toBeMapped = AiIndexMetadataConfigAlgorithmConfigArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.algorithmConfig = mapped
    }

    /**
     * @param value The default number of neighbors to find via approximate search before exact reordering is
     * performed. Exact reordering is a procedure where results returned by an
     * approximate search algorithm are reordered via a more expensive distance computation.
     * Required if tree-AH algorithm is used.
     */
    @JvmName("irslymhelojjqyrg")
    public suspend fun approximateNeighborsCount(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.approximateNeighborsCount = mapped
    }

    /**
     * @param value The number of dimensions of the input vectors.
     */
    @JvmName("iwylguxaknbabbrh")
    public suspend fun dimensions(`value`: Int) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.dimensions = mapped
    }

    /**
     * @param value The distance measure used in nearest neighbor search. The value must be one of the followings:
     * * SQUARED_L2_DISTANCE: Euclidean (L_2) Distance
     * * L1_DISTANCE: Manhattan (L_1) Distance
     * * COSINE_DISTANCE: Cosine Distance. Defined as 1 - cosine similarity.
     * * DOT_PRODUCT_DISTANCE: Dot Product Distance. Defined as a negative of the dot product
     */
    @JvmName("bjocodywggrqtfmg")
    public suspend fun distanceMeasureType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.distanceMeasureType = mapped
    }

    /**
     * @param value Type of normalization to be carried out on each vector. The value must be one of the followings:
     * * UNIT_L2_NORM: Unit L2 normalization type
     * * NONE: No normalization type is specified.
     */
    @JvmName("eipallswbmavkqxn")
    public suspend fun featureNormType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.featureNormType = mapped
    }

    /**
     * @param value Index data is split into equal parts to be processed. These are called "shards".
     * The shard size must be specified when creating an index. The value must be one of the followings:
     * * SHARD_SIZE_SMALL: Small (2GB)
     * * SHARD_SIZE_MEDIUM: Medium (20GB)
     * * SHARD_SIZE_LARGE: Large (50GB)
     */
    @JvmName("qocvotaewjyqvhod")
    public suspend fun shardSize(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.shardSize = mapped
    }

    internal fun build(): AiIndexMetadataConfigArgs = AiIndexMetadataConfigArgs(
        algorithmConfig = algorithmConfig,
        approximateNeighborsCount = approximateNeighborsCount,
        dimensions = dimensions ?: throw PulumiNullFieldException("dimensions"),
        distanceMeasureType = distanceMeasureType,
        featureNormType = featureNormType,
        shardSize = shardSize,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy