22 instantiations of VectorSearchOptions
Microsoft.Extensions.VectorData.ConformanceTests (22)
DistanceFunctionTests.cs (2)
132
new
() { ScoreThreshold = 0.9 })
150
new
() { ScoreThreshold = threshold })
EmbeddingGenerationTests.cs (1)
312
var exception = await Assert.ThrowsAsync<NotSupportedException>(() => collection.SearchAsync("[1, 0, 0]", top: 1,
new
() { IncludeVectors = true }).ToListAsync().AsTask());
FilterTests.cs (3)
53
new
() { Filter = r => r["String = \"not\"; DROP TABLE FilterTests;"] == "" }).ToListAsync());
515
new
() { Filter = filter })
535
new
() { Filter = dynamicFilter })
ModelTests\BasicModelTests.cs (3)
427
new
() { IncludeVectors = includeVectors })
440
new
() { Skip = 1 })
453
new
() { Filter = r => r.Number == 2 })
ModelTests\DynamicModelTests.cs (3)
320
new
() { IncludeVectors = includeVectors })
333
new
() { Skip = 1 })
346
new
() { Filter = r => (int)r[IntegerPropertyName]! == 2 })
ModelTests\MultiVectorModelTests.cs (2)
59
.SearchAsync(new ReadOnlyMemory<float>([1, 2, 3]), top: 1,
new
() { VectorProperty = r => r.Vector1, IncludeVectors = true })
64
.SearchAsync(new ReadOnlyMemory<float>([10, 2, 6]), top: 1,
new
() { VectorProperty = r => r.Vector2, IncludeVectors = true })
Support\TestStore.cs (1)
147
new
()
TypeTests\DataTypeTests.cs (4)
361
var result = (await collection.SearchAsync(fixture.Vector, top: 100,
new
() { Filter = filter }).SingleAsync()).Record;
376
result = (await collection.SearchAsync(fixture.Vector, top: 100,
new
() { Filter = filter }).SingleAsync()).Record;
402
var result = (await dynamicCollection.SearchAsync(fixture.Vector, top: 100,
new
() { Filter = filter }).SingleAsync()).Record;
419
result = (await dynamicCollection.SearchAsync(fixture.Vector, top: 100,
new
() { Filter = filter }).SingleAsync()).Record;
TypeTests\EmbeddingTypeTests.cs (3)
77
var result2 = await collection.SearchAsync(value, top: 1,
new
() { IncludeVectors = true, Filter = r => r.Int == 42 }).SingleAsync();
124
var dynamicResult2 = await dynamicCollection.SearchAsync(value, top: 1,
new
() { IncludeVectors = true, Filter = r => (int)r["Int"]! == 43 }).SingleAsync();
171
var result4 = await collection2.SearchAsync("does not matter", top: 1,
new
() { Filter = r => r.Int == 44 }).SingleAsync();
4 references to VectorSearchOptions
Microsoft.Extensions.VectorData.Abstractions (3)
IVectorSearchable.cs (1)
59
VectorSearchOptions
<TRecord>? options = default,
ProviderServices\CollectionModel.cs (1)
121
public VectorPropertyModel GetVectorPropertyOrSingle<TRecord>(
VectorSearchOptions
<TRecord> searchOptions)
VectorStoreCollection.cs (1)
185
public abstract IAsyncEnumerable<VectorSearchResult<TRecord>> SearchAsync<TInput>(TInput searchValue, int top,
VectorSearchOptions
<TRecord>? options = null, CancellationToken cancellationToken = default)
Microsoft.Extensions.VectorData.ConformanceTests (1)
DependencyInjectionTests.cs (1)
306
VectorSearchOptions
<TRecord>? options = null,