Skip to content

Conversation

as-suvorov
Copy link
Collaborator

@as-suvorov as-suvorov commented Jul 15, 2025

Add TextRerankPipeline which reranks a list of candidate documents based on their relevance to a query using a cross-encoder or reranker model.

@github-actions github-actions bot added category: GHA CI based on Github actions category: cmake / build Cmake scripts category: tokenizers Tokenizer class or submodule update category: Python API Python API for GenAI category: CPP API Changes in GenAI C++ public headers no-match-files category: RAG RAG pipeline components category: RAG samples RAG samples category: speech generation labels Jul 15, 2025
@github-actions github-actions bot added the category: llm_bench Label for tool/llm_bench folder label Jul 16, 2025
Comment on lines +576 to +577
infer_request_guard.get().set_input_tensor(0, ov::Tensor{ov::element::string, {prompts_1.size()}, const_cast<std::string*>(prompts_1.data())});
infer_request_guard.get().set_input_tensor(1, ov::Tensor{ov::element::string, {prompts_2.size()}, const_cast<std::string*>(prompts_2.data())});
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines +214 to +215
if MODELS[model_id].get("convert_2_input_tokenizer", False):
convert_2_input_tokenizer(Path(model_path))
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Temporary until 2 inputs tokenizer transformation is implemented

@as-suvorov as-suvorov marked this pull request as ready for review July 17, 2025 08:32
@as-suvorov as-suvorov enabled auto-merge July 18, 2025 14:28
@as-suvorov as-suvorov added this pull request to the merge queue Jul 21, 2025
github-merge-queue bot pushed a commit that referenced this pull request Jul 21, 2025
Add TextRerankPipeline which reranks a list of candidate documents based
on their relevance to a query using a cross-encoder or reranker model.
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jul 21, 2025
@apaniukov apaniukov added this pull request to the merge queue Jul 21, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jul 21, 2025
@as-suvorov as-suvorov added this pull request to the merge queue Jul 22, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jul 22, 2025
@as-suvorov as-suvorov added this pull request to the merge queue Jul 22, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jul 22, 2025
@Wovchena Wovchena added this pull request to the merge queue Jul 23, 2025
@as-suvorov as-suvorov removed this pull request from the merge queue due to a manual request Jul 23, 2025
@as-suvorov as-suvorov enabled auto-merge July 23, 2025 16:29
@Wovchena
Copy link
Collaborator

.pyi is incorrect

@as-suvorov as-suvorov added this pull request to the merge queue Jul 29, 2025
Merged via the queue into openvinotoolkit:master with commit a6631f5 Jul 29, 2025
103 of 105 checks passed
github-merge-queue bot pushed a commit that referenced this pull request Aug 1, 2025
**Details**: 
After #2436
merged, there are two test_rag.py as follow:
-
[pytests/samples/test_rag.py](https://github.com/openvinotoolkit/openvino.genai/blob/master/tests/python_tests/samples/test_rag.py)
-
[pytests/test_rag.py](https://github.com/openvinotoolkit/openvino.genai/blob/master/tests/python_tests/test_rag.py)
 
Which introduced following issue in CI precommit test locally: 
```
__________________________ERROR collecting test_rag.py__________________________
import file mismatch:
imported module 'test_rag' has this __file__ attribute:
  C:\xsun\openvino.genai\tests\python_tests\samples\test_rag.py
which is not the same as the test file we want to collect:
  C:\xsun\openvino.genai\tests\python_tests\test_rag.py
HINT: remove __pycache__ / .pyc files and/or use a unique basename for your test file modules
```
This PR aim to rename `pytests/samples/test_rag.py` to
`pytests/samples/test_rag_sample.py` to avoid ambiguous name conflict
with
[pytests/test_rag.py](https://github.com/openvinotoolkit/openvino.genai/blob/master/tests/python_tests/test_rag.py),
therefore fix the pytest import issue in CI precommit test.

---------

Co-authored-by: Vladimir Zlobin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: cmake / build Cmake scripts category: CPP API Changes in GenAI C++ public headers category: GHA CI based on Github actions category: llm_bench Label for tool/llm_bench folder category: Python API Python API for GenAI category: RAG samples RAG samples category: RAG RAG pipeline components category: speech generation category: tokenizers Tokenizer class or submodule update no-match-files
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants