Skip to content

Qwen_reranker#162

Merged
sonam-pankaj95 merged 3 commits into
mainfrom
qwen_reranker
Jul 27, 2025
Merged

Qwen_reranker#162
sonam-pankaj95 merged 3 commits into
mainfrom
qwen_reranker

Conversation

@akshayballal95
Copy link
Copy Markdown
Collaborator

  • Added an optional path_in_repo parameter to the __init__ and from_pretrained methods of the Reranker class for enhanced model loading flexibility.
  • Refactored the model type check in model.rs to use is_some_and for improved clarity and performance.

…d signature

- Introduced a new `compute_scores` method in the `Reranker` class to calculate scores for given queries and documents.
- Updated the `from_pretrained` method signature to include an optional `path_in_repo` parameter for model loading.
- Added a new `qwen3` module for handling specific model computations.
- Enhanced the `reranker` module to support dynamic model type handling during score computation.
- Updated example usage in `reranker.rs` to demonstrate the new functionality.
- Changed the model in `reranker.rs` to "zhiqing/Qwen3-Reranker-0.6B-ONNX" for improved performance.
- Refactored score computation in `model.rs` to simplify handling of Qwen3 model type.
- Introduced a check for model type at the beginning of the score computation process to enhance clarity and maintainability.
- Updated logic to conditionally format query and document pairs based on the model type, improving code readability.
…improve model type check

- Added an optional `path_in_repo` parameter to the `__init__` and `from_pretrained` methods of the `Reranker` class for enhanced model loading flexibility.
- Refactored the model type check in `model.rs` to use `is_some_and` for improved clarity and performance.
@sonam-pankaj95 sonam-pankaj95 merged commit dcaec53 into main Jul 27, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants