use candle_core::DType;
use crate::models::RerankHead;
use crate::models::jina_bert::AlibiSlopeVariant;
use crate::registry::DtypeSupport;
use crate::registry::Family;
use crate::registry::Support;
use crate::registry::WeightsFormat;
use crate::registry::rerank::RerankInput;
use crate::registry::rerank::entry::RerankEntry;
use crate::registry::t4::T4_BF16_UNTESTED;
use crate::rerank::ScoreActivation;
use crate::tokenizer::PairTruncationPolicy;
pub(super) const JINA_RERANKER_V1_TINY_EN: RerankEntry = RerankEntry {
id: "jinaai/jina-reranker-v1-tiny-en",
family: Family::JinaBert,
head: RerankHead::BertPooler,
default_max_length: 512,
score_activation: ScoreActivation::Sigmoid,
input: RerankInput::Pair {
truncation: PairTruncationPolicy::LongestFirst,
},
alibi_variant: Some(AlibiSlopeVariant::HalvedInterpolatedTail),
position_scheme: None,
default_dtype: DType::F32,
cpu: Support::Verified,
metal: Support::Verified,
cuda: Support::Verified,
dtypes: DtypeSupport {
f32: Support::Verified,
f16: Support::Verified,
bf16: Support::Verified,
},
license: "Apache-2.0",
size_gb: 0.07,
phase: 5,
weights: WeightsFormat::Safetensors,
gated: false,
accel_only_dtypes: &[DType::F16],
cell_exceptions: T4_BF16_UNTESTED,
};