langchain/libs/community/langchain_community/document_compressors
X-HAN 62f13f95e4
community[minor]: add DashScope Rerank (#22403)
**Description:** this PR adds DashScope Rerank capability to Langchain,
you can find DashScope Rerank API from
[here](https://help.aliyun.com/document_detail/2780058.html?spm=a2c4g.2780059.0.0.6d995024FlrJ12)
&
[here](https://help.aliyun.com/document_detail/2780059.html?spm=a2c4g.2780058.0.0.63f75024cr11N9).
[DashScope](https://dashscope.aliyun.com/) is the generative AI service
from Alibaba Cloud (Aliyun). You can create DashScope API key from
[here](https://bailian.console.aliyun.com/?apiKey=1#/api-key).

**Dependencies:** DashScopeRerank depends on `dashscope` python package.

**Twitter handle:** my twitter/x account is https://x.com/LastMonopoly
and I'd like a mention, thanks you!


**Tests and docs**
  1. integration test: `test_dashscope_rerank.py`
  2. example notebook: `dashscope_rerank.ipynb`

**Lint and test**: I have run `make format`, `make lint` and `make test`
from the root of the package I've modified.

---------

Co-authored-by: Bagatur <baskaryan@gmail.com>
Co-authored-by: Bagatur <22008038+baskaryan@users.noreply.github.com>
2024-06-05 15:40:21 -07:00
..
__init__.py community[minor]: add DashScope Rerank (#22403) 2024-06-05 15:40:21 -07:00
dashscope_rerank.py community[minor]: add DashScope Rerank (#22403) 2024-06-05 15:40:21 -07:00
flashrank_rerank.py Harrison/move flashrank rerank (#21448) 2024-05-15 13:08:52 -07:00
jina_rerank.py community[mionr]: add Jina Reranker in retrievers module (#19406) 2024-04-25 10:27:10 -07:00
llmlingua_filter.py community[feat]: Adds LLMLingua as a document compressor (#17711) 2024-02-27 19:23:56 -08:00
openvino_rerank.py community[patch]: Update OpenVINO embedding and reranker to support static input shape (#22171) 2024-06-03 13:27:17 -07:00
rankllm_rerank.py langchain: add RankLLM Reranker (#21171) 2024-05-22 20:12:55 +00:00