BAAI/bge-base-en-v1.5 model by default. You can pass a different model name to the constructor to use a different model.
Setup
You’ll first need to install the@langchain/community package and the required peer dependency:
npm
Usage
Note: If you do not provide amodel, a warning will be logged and the default modelBAAI/bge-base-en-v1.5will be used. If you do not provide aprovider, Hugging Face will default toautoselection, which will select the first provider available for the model based on your settings at https://hf.co/settings/inference-providers.
Hint:
hf-inference is the provider name for models that are hosted directly by Hugging Face.
Related
- Embedding model conceptual guide
- Embedding model how-to guides
Connect these docs programmatically to Claude, VSCode, and more via MCP for real-time answers.