1. Packages
  2. DataRobot
  3. API Docs
  4. VectorDatabase
DataRobot v0.9.0 published on Tuesday, Apr 8, 2025 by DataRobot, Inc.

datarobot.VectorDatabase

Explore with Pulumi AI

Vector database

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as datarobot from "@datarobot/pulumi-datarobot";

const exampleUseCase = new datarobot.UseCase("exampleUseCase", {description: "Description for the example use case"});
const exampleDatasetFromFile = new datarobot.DatasetFromFile("exampleDatasetFromFile", {
    filePath: "[Path to file to upload]",
    useCaseIds: [exampleUseCase.id],
});
const exampleVectorDatabase = new datarobot.VectorDatabase("exampleVectorDatabase", {
    useCaseId: exampleUseCase.id,
    datasetId: exampleDatasetFromFile.id,
});
// Optional
// chunking_parameters = {
//   chunk_overlap_percentage = 0
//   chunk_size               = 512
//   chunking_method          = "recursive"
//   embedding_model          = "jinaai/jina-embedding-t-en-v1"
//   separators               = ["\n", " "]
// }
export const exampleId = exampleVectorDatabase.id;
Copy
import pulumi
import pulumi_datarobot as datarobot

example_use_case = datarobot.UseCase("exampleUseCase", description="Description for the example use case")
example_dataset_from_file = datarobot.DatasetFromFile("exampleDatasetFromFile",
    file_path="[Path to file to upload]",
    use_case_ids=[example_use_case.id])
example_vector_database = datarobot.VectorDatabase("exampleVectorDatabase",
    use_case_id=example_use_case.id,
    dataset_id=example_dataset_from_file.id)
# Optional
# chunking_parameters = {
#   chunk_overlap_percentage = 0
#   chunk_size               = 512
#   chunking_method          = "recursive"
#   embedding_model          = "jinaai/jina-embedding-t-en-v1"
#   separators               = ["\n", " "]
# }
pulumi.export("exampleId", example_vector_database.id)
Copy
package main

import (
	"github.com/datarobot-community/pulumi-datarobot/sdk/go/datarobot"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleUseCase, err := datarobot.NewUseCase(ctx, "exampleUseCase", &datarobot.UseCaseArgs{
			Description: pulumi.String("Description for the example use case"),
		})
		if err != nil {
			return err
		}
		exampleDatasetFromFile, err := datarobot.NewDatasetFromFile(ctx, "exampleDatasetFromFile", &datarobot.DatasetFromFileArgs{
			FilePath: pulumi.String("[Path to file to upload]"),
			UseCaseIds: pulumi.StringArray{
				exampleUseCase.ID(),
			},
		})
		if err != nil {
			return err
		}
		exampleVectorDatabase, err := datarobot.NewVectorDatabase(ctx, "exampleVectorDatabase", &datarobot.VectorDatabaseArgs{
			UseCaseId: exampleUseCase.ID(),
			DatasetId: exampleDatasetFromFile.ID(),
		})
		if err != nil {
			return err
		}
		ctx.Export("exampleId", exampleVectorDatabase.ID())
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Datarobot = DataRobotPulumi.Datarobot;

return await Deployment.RunAsync(() => 
{
    var exampleUseCase = new Datarobot.UseCase("exampleUseCase", new()
    {
        Description = "Description for the example use case",
    });

    var exampleDatasetFromFile = new Datarobot.DatasetFromFile("exampleDatasetFromFile", new()
    {
        FilePath = "[Path to file to upload]",
        UseCaseIds = new[]
        {
            exampleUseCase.Id,
        },
    });

    var exampleVectorDatabase = new Datarobot.VectorDatabase("exampleVectorDatabase", new()
    {
        UseCaseId = exampleUseCase.Id,
        DatasetId = exampleDatasetFromFile.Id,
    });

    // Optional
    // chunking_parameters = {
    //   chunk_overlap_percentage = 0
    //   chunk_size               = 512
    //   chunking_method          = "recursive"
    //   embedding_model          = "jinaai/jina-embedding-t-en-v1"
    //   separators               = ["\n", " "]
    // }
    return new Dictionary<string, object?>
    {
        ["exampleId"] = exampleVectorDatabase.Id,
    };
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.datarobot.UseCase;
import com.pulumi.datarobot.UseCaseArgs;
import com.pulumi.datarobot.DatasetFromFile;
import com.pulumi.datarobot.DatasetFromFileArgs;
import com.pulumi.datarobot.VectorDatabase;
import com.pulumi.datarobot.VectorDatabaseArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var exampleUseCase = new UseCase("exampleUseCase", UseCaseArgs.builder()
            .description("Description for the example use case")
            .build());

        var exampleDatasetFromFile = new DatasetFromFile("exampleDatasetFromFile", DatasetFromFileArgs.builder()
            .filePath("[Path to file to upload]")
            .useCaseIds(exampleUseCase.id())
            .build());

        var exampleVectorDatabase = new VectorDatabase("exampleVectorDatabase", VectorDatabaseArgs.builder()
            .useCaseId(exampleUseCase.id())
            .datasetId(exampleDatasetFromFile.id())
            .build());

        // Optional
        // chunking_parameters = {
        //   chunk_overlap_percentage = 0
        //   chunk_size               = 512
        //   chunking_method          = "recursive"
        //   embedding_model          = "jinaai/jina-embedding-t-en-v1"
        //   separators               = ["\n", " "]
        // }
        ctx.export("exampleId", exampleVectorDatabase.id());
    }
}
Copy
resources:
  exampleUseCase:
    type: datarobot:UseCase
    properties:
      description: Description for the example use case
  exampleDatasetFromFile:
    type: datarobot:DatasetFromFile
    properties:
      filePath: '[Path to file to upload]'
      useCaseIds:
        - ${exampleUseCase.id}
  exampleVectorDatabase:
    type: datarobot:VectorDatabase
    properties:
      useCaseId: ${exampleUseCase.id}
      datasetId: ${exampleDatasetFromFile.id}
outputs:
  exampleId: ${exampleVectorDatabase.id}
Copy

Create VectorDatabase Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new VectorDatabase(name: string, args: VectorDatabaseArgs, opts?: CustomResourceOptions);
@overload
def VectorDatabase(resource_name: str,
                   args: VectorDatabaseArgs,
                   opts: Optional[ResourceOptions] = None)

@overload
def VectorDatabase(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   dataset_id: Optional[str] = None,
                   use_case_id: Optional[str] = None,
                   chunking_parameters: Optional[VectorDatabaseChunkingParametersArgs] = None,
                   name: Optional[str] = None)
func NewVectorDatabase(ctx *Context, name string, args VectorDatabaseArgs, opts ...ResourceOption) (*VectorDatabase, error)
public VectorDatabase(string name, VectorDatabaseArgs args, CustomResourceOptions? opts = null)
public VectorDatabase(String name, VectorDatabaseArgs args)
public VectorDatabase(String name, VectorDatabaseArgs args, CustomResourceOptions options)
type: datarobot:VectorDatabase
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. VectorDatabaseArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. VectorDatabaseArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. VectorDatabaseArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. VectorDatabaseArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. VectorDatabaseArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var vectorDatabaseResource = new Datarobot.VectorDatabase("vectorDatabaseResource", new()
{
    DatasetId = "string",
    UseCaseId = "string",
    ChunkingParameters = new Datarobot.Inputs.VectorDatabaseChunkingParametersArgs
    {
        ChunkOverlapPercentage = 0,
        ChunkSize = 0,
        ChunkingMethod = "string",
        EmbeddingModel = "string",
        IsSeparatorRegex = false,
        Separators = new[]
        {
            "string",
        },
    },
    Name = "string",
});
Copy
example, err := datarobot.NewVectorDatabase(ctx, "vectorDatabaseResource", &datarobot.VectorDatabaseArgs{
	DatasetId: pulumi.String("string"),
	UseCaseId: pulumi.String("string"),
	ChunkingParameters: &datarobot.VectorDatabaseChunkingParametersArgs{
		ChunkOverlapPercentage: pulumi.Int(0),
		ChunkSize:              pulumi.Int(0),
		ChunkingMethod:         pulumi.String("string"),
		EmbeddingModel:         pulumi.String("string"),
		IsSeparatorRegex:       pulumi.Bool(false),
		Separators: pulumi.StringArray{
			pulumi.String("string"),
		},
	},
	Name: pulumi.String("string"),
})
Copy
var vectorDatabaseResource = new VectorDatabase("vectorDatabaseResource", VectorDatabaseArgs.builder()
    .datasetId("string")
    .useCaseId("string")
    .chunkingParameters(VectorDatabaseChunkingParametersArgs.builder()
        .chunkOverlapPercentage(0)
        .chunkSize(0)
        .chunkingMethod("string")
        .embeddingModel("string")
        .isSeparatorRegex(false)
        .separators("string")
        .build())
    .name("string")
    .build());
Copy
vector_database_resource = datarobot.VectorDatabase("vectorDatabaseResource",
    dataset_id="string",
    use_case_id="string",
    chunking_parameters={
        "chunk_overlap_percentage": 0,
        "chunk_size": 0,
        "chunking_method": "string",
        "embedding_model": "string",
        "is_separator_regex": False,
        "separators": ["string"],
    },
    name="string")
Copy
const vectorDatabaseResource = new datarobot.VectorDatabase("vectorDatabaseResource", {
    datasetId: "string",
    useCaseId: "string",
    chunkingParameters: {
        chunkOverlapPercentage: 0,
        chunkSize: 0,
        chunkingMethod: "string",
        embeddingModel: "string",
        isSeparatorRegex: false,
        separators: ["string"],
    },
    name: "string",
});
Copy
type: datarobot:VectorDatabase
properties:
    chunkingParameters:
        chunkOverlapPercentage: 0
        chunkSize: 0
        chunkingMethod: string
        embeddingModel: string
        isSeparatorRegex: false
        separators:
            - string
    datasetId: string
    name: string
    useCaseId: string
Copy

VectorDatabase Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The VectorDatabase resource accepts the following input properties:

DatasetId This property is required. string
The id of the Vector Database.
UseCaseId This property is required. string
The id of the Use Case.
ChunkingParameters DataRobotVectorDatabaseChunkingParameters
The chunking parameters for the Model.
Name string
The name of the VectorDatabase.
DatasetId This property is required. string
The id of the Vector Database.
UseCaseId This property is required. string
The id of the Use Case.
ChunkingParameters VectorDatabaseChunkingParametersArgs
The chunking parameters for the Model.
Name string
The name of the VectorDatabase.
datasetId This property is required. String
The id of the Vector Database.
useCaseId This property is required. String
The id of the Use Case.
chunkingParameters VectorDatabaseChunkingParameters
The chunking parameters for the Model.
name String
The name of the VectorDatabase.
datasetId This property is required. string
The id of the Vector Database.
useCaseId This property is required. string
The id of the Use Case.
chunkingParameters VectorDatabaseChunkingParameters
The chunking parameters for the Model.
name string
The name of the VectorDatabase.
dataset_id This property is required. str
The id of the Vector Database.
use_case_id This property is required. str
The id of the Use Case.
chunking_parameters VectorDatabaseChunkingParametersArgs
The chunking parameters for the Model.
name str
The name of the VectorDatabase.
datasetId This property is required. String
The id of the Vector Database.
useCaseId This property is required. String
The id of the Use Case.
chunkingParameters Property Map
The chunking parameters for the Model.
name String
The name of the VectorDatabase.

Outputs

All input properties are implicitly available as output properties. Additionally, the VectorDatabase resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Version int
The version of the VectorDatabase.
Id string
The provider-assigned unique ID for this managed resource.
Version int
The version of the VectorDatabase.
id String
The provider-assigned unique ID for this managed resource.
version Integer
The version of the VectorDatabase.
id string
The provider-assigned unique ID for this managed resource.
version number
The version of the VectorDatabase.
id str
The provider-assigned unique ID for this managed resource.
version int
The version of the VectorDatabase.
id String
The provider-assigned unique ID for this managed resource.
version Number
The version of the VectorDatabase.

Look up Existing VectorDatabase Resource

Get an existing VectorDatabase resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: VectorDatabaseState, opts?: CustomResourceOptions): VectorDatabase
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        chunking_parameters: Optional[VectorDatabaseChunkingParametersArgs] = None,
        dataset_id: Optional[str] = None,
        name: Optional[str] = None,
        use_case_id: Optional[str] = None,
        version: Optional[int] = None) -> VectorDatabase
func GetVectorDatabase(ctx *Context, name string, id IDInput, state *VectorDatabaseState, opts ...ResourceOption) (*VectorDatabase, error)
public static VectorDatabase Get(string name, Input<string> id, VectorDatabaseState? state, CustomResourceOptions? opts = null)
public static VectorDatabase get(String name, Output<String> id, VectorDatabaseState state, CustomResourceOptions options)
resources:  _:    type: datarobot:VectorDatabase    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
ChunkingParameters DataRobotVectorDatabaseChunkingParameters
The chunking parameters for the Model.
DatasetId string
The id of the Vector Database.
Name string
The name of the VectorDatabase.
UseCaseId string
The id of the Use Case.
Version int
The version of the VectorDatabase.
ChunkingParameters VectorDatabaseChunkingParametersArgs
The chunking parameters for the Model.
DatasetId string
The id of the Vector Database.
Name string
The name of the VectorDatabase.
UseCaseId string
The id of the Use Case.
Version int
The version of the VectorDatabase.
chunkingParameters VectorDatabaseChunkingParameters
The chunking parameters for the Model.
datasetId String
The id of the Vector Database.
name String
The name of the VectorDatabase.
useCaseId String
The id of the Use Case.
version Integer
The version of the VectorDatabase.
chunkingParameters VectorDatabaseChunkingParameters
The chunking parameters for the Model.
datasetId string
The id of the Vector Database.
name string
The name of the VectorDatabase.
useCaseId string
The id of the Use Case.
version number
The version of the VectorDatabase.
chunking_parameters VectorDatabaseChunkingParametersArgs
The chunking parameters for the Model.
dataset_id str
The id of the Vector Database.
name str
The name of the VectorDatabase.
use_case_id str
The id of the Use Case.
version int
The version of the VectorDatabase.
chunkingParameters Property Map
The chunking parameters for the Model.
datasetId String
The id of the Vector Database.
name String
The name of the VectorDatabase.
useCaseId String
The id of the Use Case.
version Number
The version of the VectorDatabase.

Supporting Types

VectorDatabaseChunkingParameters
, VectorDatabaseChunkingParametersArgs

ChunkOverlapPercentage int
The percentage of overlap between chunks.
ChunkSize int
The size of the chunks.
ChunkingMethod string
The method used to chunk the data.
EmbeddingModel string
The id of the Embedding Model.
IsSeparatorRegex bool
Whether the separator is a regex.
Separators List<string>
The separators used to split the data.
ChunkOverlapPercentage int
The percentage of overlap between chunks.
ChunkSize int
The size of the chunks.
ChunkingMethod string
The method used to chunk the data.
EmbeddingModel string
The id of the Embedding Model.
IsSeparatorRegex bool
Whether the separator is a regex.
Separators []string
The separators used to split the data.
chunkOverlapPercentage Integer
The percentage of overlap between chunks.
chunkSize Integer
The size of the chunks.
chunkingMethod String
The method used to chunk the data.
embeddingModel String
The id of the Embedding Model.
isSeparatorRegex Boolean
Whether the separator is a regex.
separators List<String>
The separators used to split the data.
chunkOverlapPercentage number
The percentage of overlap between chunks.
chunkSize number
The size of the chunks.
chunkingMethod string
The method used to chunk the data.
embeddingModel string
The id of the Embedding Model.
isSeparatorRegex boolean
Whether the separator is a regex.
separators string[]
The separators used to split the data.
chunk_overlap_percentage int
The percentage of overlap between chunks.
chunk_size int
The size of the chunks.
chunking_method str
The method used to chunk the data.
embedding_model str
The id of the Embedding Model.
is_separator_regex bool
Whether the separator is a regex.
separators Sequence[str]
The separators used to split the data.
chunkOverlapPercentage Number
The percentage of overlap between chunks.
chunkSize Number
The size of the chunks.
chunkingMethod String
The method used to chunk the data.
embeddingModel String
The id of the Embedding Model.
isSeparatorRegex Boolean
Whether the separator is a regex.
separators List<String>
The separators used to split the data.

Package Details

Repository
datarobot datarobot-community/pulumi-datarobot
License
Apache-2.0
Notes
This Pulumi package is based on the datarobot Terraform Provider.