class_docstr: Wrapper around ChromaDB embeddings platform.
  
  To use, you should have the ``chromamigdb`` python package installed.
  
  Example:
      .. code-block:: python
  
              from langchain.vectorstores import Chroma
              from langchain.embeddings.openai import OpenAIEmbeddings
  
              embeddings = OpenAIEmbeddings()
              vectorstore = Chroma("langchain_store", embeddings)
docstr: The 'correct' relevance function
  may differ depending on a few things, including:
  - the distance / similarity metric used by the VectorStore
  - the scale of your embeddings (OpenAI's are unit normed. Many others are not!)
  - embedding dimensionality
  - etc.
docstr_tok: ["The","'correct","'","relevance","function","may","differ","depending","on","a","few","things",",","including",":","-","the","distance","\/","similarity","metric","used","by","the","VectorStore","-","the","scale","of","your","embeddings","(","OpenAI","'s","are","unit","normed",".","Many","others","are","not","!",")","-","embedding","dimensionality","-","etc","."]
code: def _select_relevance_score_fn(self) -> Callable[[float], float]:
      """
      The 'correct' relevance function
      may differ depending on a few things, including:
      - the distance / similarity metric used by the VectorStore
      - the scale of your embeddings (OpenAI's are unit normed. Many others are not!)
      - embedding dimensionality
      - etc.
      """
      if self.override_relevance_score_fn:
          return self.override_relevance_score_fn
  
      distance = "l2"
      distance_key = "hnsw:space"
      metadata = self._collection.metadata
  
      if metadata and distance_key in metadata:
          distance = metadata[distance_key]
  
      if distance == "cosine":
          return self._cosine_relevance_score_fn
      elif distance == "l2":
          return self._euclidean_relevance_score_fn
      elif distance == "ip":
          return self._max_inner_product_relevance_score_fn
      else:
          raise ValueError(
              "No supported normalization function"
              f" for distance metric of type: {distance}."
              "Consider providing relevance_score_fn to Chroma constructor."
          )
  
imports: from __future__ import annotations
  import logging
  import uuid
  from typing import TYPE_CHECKING, Any, Callable, Dict, Iterable, List, Optional, Tuple, Type
  import numpy
  from langchain.docstore.document import Document
  from langchain.embeddings.base import Embeddings
  from langchain.utils import xor_args
  from langchain.vectorstores.base import VectorStore
  from langchain.vectorstores.utils import maximal_marginal_relevance
label_desc: Use image node_id 9 for calling the ChromaMig obj's underlying member method code with example usage: obj._select_relevance_score_fn() and returns: self, self, self, self