azure-sdk-for-net icon indicating copy to clipboard operation
azure-sdk-for-net copied to clipboard

[BUG] Error using vector search with ImageVectorFieldNames

Open druidajes opened this issue 1 year ago • 2 comments

Library name and version

Azure.AI.OpenAI 2.0.0.0

Describe the bug

When I use vector search with ImageVectorFieldNames, an error occurs

Image

ChatCompletionOptions options = new();

options.AddDataSource(new AzureSearchChatDataSource()
{
	Endpoint = _optionsAzureAISearch.Endpoint,
	IndexName = _optionsAzureAISearch.IndexName,
	Authentication = DataSourceAuthentication.FromApiKey(_optionsAzureAISearch.Key),
	QueryType = DataSourceQueryType.VectorSemanticHybrid,
	SemanticConfiguration = _optionsAzureAISearch.IndexName + "-semantic-configuration",
	VectorizationSource =  DataSourceVectorizer.FromDeploymentName(_optionsAzureOpenAIOptions.EmbeddingsModelDeploymentName),
	InScope = true,
	TopNDocuments = 3,
	FieldMappings = new DataSourceFieldMappings()
	{
		ContentFieldNames = { "chunk" },
		FilePathFieldName = "metadata_storage_name",
		TitleFieldName = "title",
		UrlFieldName = "metadata_storage_path",
		VectorFieldNames = { "text_vector" },
		ImageVectorFieldNames = { "image_vector" }
	},

});

Image

However, if I don't use ImageVectorFieldNames, no error occurs.

Expected behavior

That you can search for image vectors

Actual behavior

Cannot search for image vectors

Reproduction Steps

The exception is raised from the code provided above

Environment

No response

druidajes avatar Oct 18 '24 11:10 druidajes

Thank you for your feedback. Tagging and routing to the team member best able to assist.

github-actions[bot] avatar Oct 18 '24 11:10 github-actions[bot]

Hi @druidajes ,

Thank you for raising this issue! Please hang tight while we take a look and feel free to add more details if you have any.

AngelosP avatar Oct 18 '24 21:10 AngelosP