Child Field Options

  • reference
    You can configure a child field from the Couchbase Server Web Console to control how its data is added to your Search index.

    For more information about how to create a child field, see Create a Child Field.

    You can configure the following options for a child field, based on its type:

    Option Description

    Dimension (Vector Fields Only)

    For a vector child field, enter the total number of elements in the vector embedding array.

    Vector Search indexes can support arrays with up to 2048 elements. Arrays can be an array of arrays.

    Similarity Metric (Vector Fields Only)

    For a vector child field, choose the method to calculate the similarity between the vector embedding in a Vector Search index and the vector embedding in a Vector Search query.

    It’s recommended to choose the same similarity metric for your Search index as the one used in your embedding model.
    • dot_product: Calculated by adding the result of multiplying a vector’s components, or the product of the magnitudes of the vectors and the cosine of the angle between them. The dot product of 2 vectors is affected by the length and direction of each of the vectors, rather than just taking a straight-line distance.

      Dot product similarity is commonly used by Large Language Models (LLMs). Use dot_product to get the best results with an embedding model that uses dot product similarity.

    • l2_norm: Also known as Euclidean distance. Uses the straight-line distance between 2 vectors to calculate similarity. Smaller euclidean distances mean that the values of each coordinate in the vectors are closer together.

      It’s best to use l2_norm similarity when your embeddings contain information about the count or measure of specific things, and your embedding model uses the same similarity metric.

    Optimized For (Vector Fields Only)

    For a vector child field, choose whether the Search Service should prioritize recall or latency when returning similar vectors in search results:

    • recall: The Search Service prioritizes returning the most accurate result. This may increase resource usage for Search queries.

      The Search Service uses an nprobe value to calculate the number of centroids to search when using recall priority. This value is calculated by taking the square root of the number of centroids in the index.

    • latency: The Search Service prioritizes returning results with lower latency. This may reduce the accuracy of results.

      The Search Service uses half the nprobe value calculated for recall priority.

    Searchable As

    Set a different name that you can use to search the field’s contents in a query.

    The default value is the value set in the Field field when you create a child field.


    Choose an analyzer for the content in the child field.

    You can choose a default analyzer or a custom analyzer.

    For more information about the available default analyzers, see Default Analyzers.

    For more information about how to create a custom analyzer, see Create a Custom Analyzer.


    To include the child field in the index, select Index.

    To remove the child field from the index, clear Index.

    If you remove the child field from the index, it cannot appear in search results.


    To store the values from the field in the index and return them in search results, select Store. This increases your index’s size and indexing time.

    You can return the values from this field when you include the fields array in a Search query.

    To remove the field’s values from the index, clear Store.

    Include in _all field

    The _all field is a composite field that has the content from multiple fields in an index. It allows searches to query the content of a field without specifying the field’s name. This option increases your index’s size.

    To include this field in the _all field, select Include in _all field.

    To exclude this field from the _all field, clear Include in _all field.

    To change the name of the _all field, see Default Field.

    Include Term Vectors

    Term vectors store the location of terms in a field for an index. You can use term vectors to highlight matching search terms in search results, and perform phrase searches. Term vectors increase your index’s size and indexing time.

    To enable term vectors for this field, select Include Term Vectors.

    To turn off term vectors, clear Include Term Vectors.

    To enable term vectors, you must also enable Store.

    Doc Values

    Use doc values for a field for Search Facets and sorting your search results.

    To store doc values and enable faceting and sorting for this field, select Doc Values.

    To exclude doc values from the index for this field, clear Doc Values.