Function getEmbeddingModel

  • Initialize HuggingFace Transformers pipeline for embedding text.

    Parameters

    • Optionaloptions: {
          pipelineName: string;
          modelName: string;
      } = {}
      • pipelineName: string

        default "feature-extraction",

      • modelName: string

        default="Xenova/all-MiniLM-L6-v2" - The name of the model to use

    Returns Promise<AutoTokenizer>

    The pipeline. *