langchain/tests/integration_tests
Yoann Poupart c1807d8408
encoding_kwargs for InstructEmbeddings (#5450)
# What does this PR do?

Bring support of `encode_kwargs` for ` HuggingFaceInstructEmbeddings`,
change the docstring example and add a test to illustrate with
`normalize_embeddings`.

Fixes #3605
(Similar to #3914)

Use case:
```python
from langchain.embeddings import HuggingFaceInstructEmbeddings

model_name = "hkunlp/instructor-large"
model_kwargs = {'device': 'cpu'}
encode_kwargs = {'normalize_embeddings': True}
hf = HuggingFaceInstructEmbeddings(
    model_name=model_name,
    model_kwargs=model_kwargs,
    encode_kwargs=encode_kwargs
)
```
2023-05-30 11:57:04 -07:00
..
agent Add Multi-CSV/DF support in CSV and DataFrame Toolkits (#5009) 2023-05-25 14:23:11 -07:00
cache feat: add Momento as a standard cache and chat message history provider (#5221) 2023-05-25 19:13:21 -07:00
callbacks add tracing v2 env var (#4465) 2023-05-10 11:08:29 -07:00
chains Harrison/neo4j (#5078) 2023-05-22 07:31:48 -07:00
chat_models Harrison/vertex (#5049) 2023-05-24 15:51:12 -07:00
client Add Delete Session Method (#5193) 2023-05-24 21:06:03 +00:00
document_loaders Harrison/spark reader (#5405) 2023-05-29 20:23:17 -07:00
embeddings encoding_kwargs for InstructEmbeddings (#5450) 2023-05-30 11:57:04 -07:00
examples fix(document_loaders/telegram): fix pandas calls + add tests (#4806) 2023-05-16 14:35:25 -07:00
llms Harrison/prediction guard update (#5404) 2023-05-29 07:14:59 -07:00
memory feat: add Momento as a standard cache and chat message history provider (#5221) 2023-05-25 19:13:21 -07:00
prompts Cleanup integration test dir (#3308) 2023-04-21 09:44:09 -07:00
retrievers tfidf retriever (#5114) 2023-05-24 10:02:09 -07:00
utilities Tedma4/twilio tool (#5136) 2023-05-25 19:19:22 -07:00
vectorstores adding MongoDBAtlasVectorSearch (#5338) 2023-05-30 07:59:01 -07:00
__init__.py
.env.example adding MongoDBAtlasVectorSearch (#5338) 2023-05-30 07:59:01 -07:00
conftest.py feat: improve pinecone tests (#2806) 2023-04-13 21:49:31 -07:00
test_document_transformers.py Contextual compression retriever (#2915) 2023-04-20 17:01:14 -07:00
test_nlp_text_splitters.py
test_pdf_pagesplitter.py cleanup: unify 3 different pdf loaders, rename PagedPDFSplitter (#1615) 2023-03-13 23:06:50 -07:00
test_schema.py Add 'get_token_ids' method (#4784) 2023-05-22 13:17:26 +00:00
test_text_splitter.py Fix TextSplitter.from_tiktoken(#4361) 2023-05-08 16:36:38 -07:00