Cargo Features

langchain-rust has no features set by default.

[dependencies]
langchain-rust = { version = "4.6.0", features = ["fastembed", "git", "mistralai", "lopdf", "pdf-extract", "ollama", "opensearch", "postgres", "qdrant", "sqlite", "surrealdb", "tree-sitter"] }
fastembed

Enables fastembed

git = flume, gix
mistralai = mistralai-client

Affects embedding::mistralai

lopdf

Enables lopdf

Affects pdf_loader::lo_loader

pdf-extract

Enables lopdf and pdf-extract ^0.7.8

Affects pdf_loader::pdf_extract_loader

ollama = ollama-rs

Affects embedding::ollama, ollama::client

opensearch = aws-config

Enables opensearch

Affects vectorstore::opensearch

postgres = pgvector, sqlx, uuid

Affects sql::postgres, vectorstore::pgvector

qdrant = qdrant-client, uuid

Affects vectorstore::qdrant

sqlite = sqlx

Affects vectorstore::sqlite_vss

surrealdb

Enables surrealdb

Affects vectorstore::surrealdb

tree-sitter = cc

Enables tree-sitter, tree-sitter-c, tree-sitter-cpp, tree-sitter-go, tree-sitter-javascript, tree-sitter-python, tree-sitter-rust, and tree-sitter-typescript

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

sqlx postgres? sqlite?
uuid postgres? qdrant?
pgvector postgres?
flume git?
gix git?

Enables gix ^0.66.0

aws-config opensearch?
qdrant-client qdrant?
ollama-rs ollama?
mistralai-client mistralai?
cc build tree-sitter?