bge-reranker-base-fp16-ov

Disclaimer: This model is provided for evaluation purposes only. Performance, accuracy, and stability may vary. Use at your own discretion.

Description

This is bge-reranker-base model converted to the OpenVINO™ IR (Intermediate Representation) format with weights compressed to FP16.

Compatibility

The provided OpenVINO™ IR model is compatible with:

  • OpenVINO version 2025.1.0 and higher
  • Optimum Intel 1.24.0 and higher

Running Model Inference with Optimum Intel

  1. Install packages required for using Optimum Intel integration with the OpenVINO backend:
pip install optimum[openvino]
  1. Run model inference:
from transformers import AutoTokenizer
from optimum.intel import OVModelForSequenceClassification


tokenizer = AutoTokenizer.from_pretrained('OpenVINO/bge-reranker-base-fp16-ov')
model = OVModelForSequenceClassification.from_pretrained('OpenVINO/bge-reranker-base-fp16-ov')

pairs = [['what is panda?', 'hi'], ['what is panda?', 'The giant panda (Ailuropoda melanoleuca), sometimes called a panda bear or simply panda, is a bear species endemic to China.']]

inputs = tokenizer(pairs, padding=True, truncation=True, return_tensors='pt', max_length=512)
scores = model(**inputs, return_dict=True).logits.view(-1, ).float()
print(scores)

For more examples and possible optimizations, refer to the Inference with Optimum Intel.

You can find more detailed usage examples in OpenVINO Notebooks:

Limitations

Check the original model card for limitations.

Legal information

The original model is distributed under MIT license. More details can be found in bge-reranker-base.

Disclaimer

Intel is committed to respecting human rights and avoiding causing or contributing to adverse impacts on human rights. See Intel’s Global Human Rights Principles. Intel’s products and software are intended only to be used in applications that do not cause or contribute to adverse impacts on human rights.

Downloads last month
16
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for OpenVINO/bge-reranker-base-fp16-ov

Finetuned
(6)
this model