Skip to main content
All docs
V25.1
  • SemanticSearchBehavior(Type, String, String, String, ScoreThresholdFilter, Double, Int32, ControlSearchMode, Boolean, SemanticSearchEvents) Constructor

    Initializes a new instance of the SemanticSearchBehavior class with specified settings.

    Namespace: DevExpress.AIIntegration.WinForms

    Assembly: DevExpress.AIIntegration.WinForms.SemanticSearch.v25.1.dll

    NuGet Package: DevExpress.AIIntegration.WinForms.SemanticSearch

    Declaration

    public SemanticSearchBehavior(
        Type behaviorSourceType,
        string vectorCollectionName = "",
        string embeddingGeneratorName = "",
        string dataSourceKeyField = "",
        ScoreThresholdFilter thresholdFilter = ScoreThresholdFilter.None,
        double scoreThreshold = 0,
        int searchResultCount = 10,
        ControlSearchMode searchMode = ControlSearchMode.Standard,
        bool allowChangeSearchMode = true,
        SemanticSearchEvents events = null
    )

    Parameters

    Name Type Description
    behaviorSourceType Type

    The type of the Semantic Search behavior (for example, SemanticSearchBehavior).

    Optional Parameters

    Name Type Default Description
    vectorCollectionName String String.Empty

    the name of the collection with embeddings in the vector store. This value is assigned to the VectorCollectionName property.

    embeddingGeneratorName String String.Empty

    The name of the collection with embeddings in the vector store. This value is assigned to the VectorCollectionName property.

    dataSourceKeyField String String.Empty

    The key field. This value is assigned to the DataSourceKeyField property.

    thresholdFilter DevExpress.AIIntegration.SemanticSearch.ScoreThresholdFilter None

    Controls how the ScoreThreshold is applied during filtering. This value is assigned to the ScoreThresholdFilter property.

    scoreThreshold Double 0

    The similarity score threshold at which search results are considered relevant. This value is assigned to the ScoreThreshold property.

    searchResultCount Int32 10

    The maximum number of search results returned for a query. This value is assigned to the SearchResultCount property.

    searchMode DevExpress.AIIntegration.SemanticSearch.ControlSearchMode Standard

    A value that specifies search mode. This value is assigned to the SearchMode property.

    allowChangeSearchMode Boolean True

    true to allow users to change search mode; otherwise, false. This value is assigned to the AllowChangeSearchMode property.

    events DevExpress.AIIntegration.WinForms.SemanticSearchEvents null

    Search-related events.

    Remarks

    See the following help topic for additional information: Semantic Search.

    See Also