Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1016,9 +1016,10 @@ It also reduces computational overhead, making operations like similarity search
#### Quantization in RavenDB:

For non-quantized raw 32-bit data or text stored in your documents,
RavenDB allows you to choose the quantization format for the generated embeddings stored in the index.
The selected quantization type determines the similarity search technique that will be applied.
RavenDB allows you to choose the quantization format for the generated embeddings stored in the index.
The quantization format applies to how vectors are stored internally in the index, regardless of the client language used to submit the data.

The selected quantization type determines the similarity search technique that will be applied.
If no target quantization format is specified, the `Single` option will be used as the default.

The available quantization options are:
Expand Down Expand Up @@ -1322,7 +1323,7 @@ where vector.search(TagsEmbeddedAsSingle, $queryVector, 0.85, 10)
* You can perform a vector search and a regular search in the same query.
A single auto-index will be created for both search predicates.

* In the following example, results will include Product documents with content similar to "Italian food" in their _Name_ field and a _PricePerUnit_ above 20.
* In the following example, results will include Product documents with content similar to "italian food" in their _Name_ field and a _PricePerUnit_ above 20.
The following auto-index will be generated:
`Auto/Products/ByPricePerUnitAndVector.search(embedding.text(Name))`.

Expand Down Expand Up @@ -1610,7 +1611,7 @@ or

`VectorSearch`:

<TabItem value="syntax_1" label="syntax_1">
<TabItem>
```csharp
public IRavenQueryable<T> VectorSearch<T>(
Func<IVectorFieldFactory<T>, IVectorEmbeddingTextField> textFieldFactory,
Expand Down Expand Up @@ -1648,14 +1649,14 @@ public IRavenQueryable<T> VectorSearch<T>(
| **isExact** | `bool` | `false` - vector search will be performed in an approximate manner.<br/>`true` - vector search will be performed in an exact manner. |

The default value for `minimumSimilarity` is defined by this configuration key:
[Indexing.Corax.VectorSearch.DefaultMinimumSimilarity ](../../../server/configuration/indexing-configuration.mdx#indexingcoraxvectorsearchdefaultnumberofcandidatesforquerying).
[Indexing.Corax.VectorSearch.DefaultMinimumSimilarity ](../../../server/configuration/indexing-configuration.mdx#indexingcoraxvectorsearchdefaultminimumsimilarity).

The default value for `numberOfCandidates` is defined by this configuration key:
[Indexing.Corax.VectorSearch.DefaultNumberOfCandidatesForQuerying](../../../server/configuration/indexing-configuration.mdx#indexingcoraxvectorsearchdefaultminimumsimilarity).
[Indexing.Corax.VectorSearch.DefaultNumberOfCandidatesForQuerying](../../../server/configuration/indexing-configuration.mdx#indexingcoraxvectorsearchdefaultnumberofcandidatesforquerying).

`IVectorFieldFactory`:

<TabItem value="syntax_2" label="syntax_2">
<TabItem>
```csharp
public interface IVectorFieldFactory<T>
{
Expand Down Expand Up @@ -1694,7 +1695,7 @@ public interface IVectorFieldFactory<T>

`IVectorEmbeddingTextField` & `IVectorEmbeddingField`:

<TabItem value="syntax_3" label="syntax_3">
<TabItem>
```csharp
public interface IVectorEmbeddingTextField
{
Expand All @@ -1718,7 +1719,7 @@ public interface IVectorEmbeddingField
| **targetEmbeddingQuantization** | `VectorEmbeddingType` | The desired target quantization format. |
| **embeddingsGenerationTaskIdentifier** | `string ` | The identifier of an embeddings generation task.<br/>Used to locate the embeddings generated by the task in the [Embedding collections](../../../ai-integration/generating-embeddings/embedding-collections.mdx). |

<TabItem value="syntax_4" label="syntax_4">
<TabItem>
```csharp
public enum VectorEmbeddingType
{
Expand All @@ -1732,7 +1733,7 @@ public enum VectorEmbeddingType

`IVectorEmbeddingTextFieldValueFactory` & `IVectorEmbeddingFieldValueFactory`:

<TabItem value="syntax_5" label="syntax_5">
<TabItem>
```csharp
public interface IVectorEmbeddingTextFieldValueFactory
{
Expand Down Expand Up @@ -1780,7 +1781,7 @@ public interface IVectorEmbeddingFieldValueFactory
RavenVector is RavenDB's dedicated data type for storing and querying numerical embeddings.
Learn more in [RavenVector](../../../ai-integration/vector-search/data-types-for-vector-search.mdx#ravenvector).

<TabItem value="syntax_6" label="syntax_6">
<TabItem>
```csharp
public class RavenVector<T>()
{
Expand All @@ -1795,7 +1796,7 @@ RavenDB provides the following quantizer methods.
Use them to transform your raw data to the desired format.
Other quantizers may not be compatible.

<TabItem value="syntax_7" label="syntax_7">
<TabItem>
```csharp
public static class VectorQuantizer
{
Expand Down
Loading