mirror of
https://github.com/hwchase17/langchain.git
synced 2025-06-02 04:58:46 +00:00
# Parameterize Redis vectorstore index Redis vectorstore allows for three different distance metrics: `L2` (flat L2), `COSINE`, and `IP` (inner product). Currently, the `Redis._create_index` method hard codes the distance metric to COSINE. I've parameterized this as an argument in the `Redis.from_texts` method -- pretty simple. Fixes #4368 ## Before submitting I've added an integration test showing indexes can be instantiated with all three values in the `REDIS_DISTANCE_METRICS` literal. An example notebook seemed overkill here. Normal API documentation would be more appropriate, but no standards are in place for that yet. ## Who can review? Not sure who's responsible for the vectorstore module... Maybe @eyurtsev / @hwchase17 / @agola11 ? |
||
---|---|---|
.. | ||
agent | ||
cache | ||
callbacks | ||
chains | ||
chat_models | ||
document_loaders | ||
embeddings | ||
examples | ||
llms | ||
memory | ||
prompts | ||
retrievers | ||
utilities | ||
vectorstores | ||
__init__.py | ||
.env.example | ||
conftest.py | ||
test_document_transformers.py | ||
test_nlp_text_splitters.py | ||
test_pdf_pagesplitter.py | ||
test_schema.py | ||
test_text_splitter.py |