github huggingface/sentence-transformers v6.2.0
v6.2.0 - Model merging, faster loading, and distributed evaluation

5 hours ago

This release adds model merging for all four model types, reduces redundant Hub requests when loading models, and distributes evaluator inference across DDP ranks. It also includes lower-memory training losses, more flexible multi-vector compression, and fixes throughout inference, training, and evaluation.

Install this version with

# Inference only, use one of:
pip install sentence-transformers==6.2.0
pip install sentence-transformers[openvino]==6.2.0

# Multimodal dependencies (optional):
pip install sentence-transformers[image]==6.2.0
pip install sentence-transformers[audio]==6.2.0
pip install sentence-transformers[video]==6.2.0

# Training + Inference
pip install sentence-transformers[train]==6.2.0
pip install sentence-transformers[merge]==6.2.0

# Or combine as needed:
pip install sentence-transformers[train,image]==6.2.0

Model merging for all four model types (#3776)

Combine compatible fine-tuned checkpoints without another training run using SentenceTransformer.merge, SparseEncoder.merge, CrossEncoder.merge, or MultiVectorEncoder.merge. The integration uses Arcee AI's mergekit and supports well over a dozen methods such as Linear, SLERP, TIES, and DARE.

Install the merge extra with pip install "sentence-transformers[merge]". For example, take a weighted average of two compatible MiniLM models:

from sentence_transformers import SentenceTransformer

models = [
    "sentence-transformers/all-MiniLM-L6-v2",
    "sentence-transformers/multi-qa-MiniLM-L6-cos-v1",
]

merged = SentenceTransformer.merge(
    models,
    method="linear",
    parameters={"weight": [0.6, 0.4]},
)
merged.save_pretrained("merged-MiniLM-L6")

embeddings = merged.encode(["Combining compatible model weights."])

Or interpolate between the same inputs with SLERP:

merged = SentenceTransformer.merge(
    models,
    method="slerp",
    parameters={"t": 0.5},
)

The method returns a model that can be used, trained, and saved normally. Configuration, prompts, and processors come from the first input. Inputs must have compatible architectures, module configurations, and tokenizers. Merging uses FP32 on CPU by default and holds the inputs and result in memory.

See the merging guides for Sentence Transformers, Cross Encoders, Sparse Encoders (plus an example evaluation!), and Multi-Vector Encoders. Be sure to evaluate the merged model on your own tasks, since combining checkpoints can improve some tasks while regressing others.

Faster Hub model loading (#3890)

Combined with huggingface_hub>=1.26.0, model loading now resolves the requested branch or tag to a commit once and reuses that result across component downloads, reducing repeated Hub requests. Older Hub versions retain the previous loading behavior.

The loading benchmarks in #3890 measured constructor time in fresh processes with a warm cache and online Hub access. Values are medians of seven alternating runs per configuration:

Model Before After HTTP requests before / after
sentence-transformers-testing/stsb-bert-tiny-safetensors 5.78 s 2.26 s 34 / 8
sentence-transformers/all-MiniLM-L6-v2 6.39 s 2.66 s 35 / 9
sparse-encoder-testing/splade-bert-tiny-nq 5.77 s 2.25 s 34 / 8
cross-encoder/ms-marco-MiniLM-L6-v2 4.38 s 2.48 s 23 / 9

Constructor time fell by 43 to 61 percent in these workloads. Loading models from local directories is unchanged and unaffected by this improvement.

Distributed evaluator inference during DDP training (#4004)

During DDP training, evaluators now share their encode() and predict() work across the existing training processes for all four model types, with each rank processing a shard of the inputs. Rank zero combines predictions in their original order, computes metrics over the full dataset, and writes evaluation output once. Metrics are then broadcast to every rank for checkpoint selection and early stopping.

This now happens automatically when using an evaluator through the trainer. It also covers encode_query(), encode_document(), and rank(), which use those inference methods internally.

Explicit device and pool arguments retain their usual behavior, and calls with arguments that cannot be serialized fall back to rank zero. Predictions are gathered through CPU memory, so the speedup depends on inference cost and communication overhead. Evaluator support for FSDP and DeepSpeed is unchanged.

Smaller Features

Experimental FP32 layers for CrossEncoders (#4230)

CrossEncoders can compute selected linear layers in FP32 to reduce BF16 score ties while keeping a reduced-precision backbone:

from sentence_transformers import CrossEncoder

model = CrossEncoder(
    "cross-encoder/ms-marco-MiniLM-L6-v2",
    device="cuda",
    model_kwargs={"dtype": "bfloat16"},
    keep_in_fp32_modules=["0.model.classifier"],
)

This uses the exact model.named_modules() paths. The selection is saved with the model, works under autocast during training and inference, and leaves stored parameter dtypes unchanged. In my experiments, this doesn't improve NDCG@10, but solely helps reduce ties caused by the low BF16/FP16 output precision.

Lower memory training losses (#4026, #4029, #4030)

  • BatchSemiHardTripletLoss uses quadratic intermediate memory instead of constructing cubic distance and mask tensors. It also corrects a gradient issue when selected negative distances tie (#4026).
  • BatchAllTripletLoss removes invalid anchor-positive pairs before constructing triplets. Memory is quadratic for paired labels, though large label groups can still require cubic storage (#4029).
  • CoSENTLoss, AnglELoss, and their sparse counterparts use sorted suffix reductions with linear intermediate storage. MPS execution requires PyTorch 2.9 or newer (#4030).

Multi-vector compression and scoring (#3965, #3941, #4008, #4153)

  • HierarchicalTokenPooling accepts fractional pool_factor values for finer control over compression (#3965) and can use optional fastcluster linkage for faster clustering (#3941).
  • HierarchicalTokenPooling now normalizes output tokens by default, including protected tokens. Older saved configurations retain their previous behavior. Set normalize_embeddings=False on the pooling module to opt out (#4008).
  • MaxSim scoring budgets score blocks using both query and document token counts, reducing memory use for long query batches. A single query-document pair can still exceed chunk_elements (#4153).

Compatibility Notes

  • Python and Hub versions: Added Python 3.14 and huggingface_hub 2.x support, retaining Python 3.10 support and the Hub 1.3.0 minimum (#4162, #4003).
  • Scalar quantization: Inferring int8 or uint8 calibration ranges from a single vector now raises ValueError. Encode floats first, then call quantize_embeddings with representative calibration_embeddings or explicit ranges (#4150).
  • Checkpoint paths: Module paths must be relative and cannot contain .. path components, even with trust_remote_code=True. Keep custom modules inside the checkpoint tree (#4175).

Bug Fixes

Pooling precision and normalization

  • Improved FP16/BF16 mean and weighted-mean pooling arithmetic, corrected weighted positions under left padding, and fixed prompt exclusion in flattened CLS fallback selection (#4106, #4104, #4159).
  • Corrected normalization of single sparse vectors and sparse matrices with non-default dtypes or low-precision values (#4149, #4045).

Multi-process inference

  • Worker exceptions are reported to the caller, and terminated workers are detected while polling for results (#3920, #4146).
  • Worker tensor outputs are moved to CPU before queueing, including tensors nested in lists and dictionaries. Hard-negative mining also stops its pool if mining fails (#3971, #4086).

Model placement and memory

  • Improved device handling for quantized models and models using Accelerate device maps or offloading, and reduced repeated placement work. Call clear_placement_cache() after changing dispatch hooks or adding modules following the first inference call (#3986, #4035).
  • Disabled Transformer KV caching by default when supported, reducing unnecessary inference memory use. Explicit use_cache overrides in config_kwargs remain honored (#3992).

Cached and compiled training

  • Avoided redundant DDP synchronization during cached-loss replay (#4039).
  • Corrected image slicing for cached training batches containing zero or multiple images per sample, including custom training loops (#4157).
  • Fixed checkpoint restoration for compiled models, including best-checkpoint loading, and forwarded gradient-checkpointing options from newer Transformers versions (#4130, #4241).

CSR training

  • Preserved the 4k reconstruction path, corrected raw-space targets and auxiliary residual scaling for normalized autoencoders, and prevented inference from changing dead-feature statistics (#4111, #4117, #3910).
  • Supported k_aux=0 and used ordinary MSE for zero-variance reconstruction batches (#4017, #4016).

Quantization, search, and mining

  • Reused scalar calibration ranges across ragged multi-vector embeddings, accepted BF16 inputs, and corrected FP16 range arithmetic (#4025, #4089, #4113).
  • Corrected scalar-quantized candidate rescoring. Use the same corpus calibration ranges when searching reused indexes (#4058).
  • Fixed binary USearch rescoring, padding when the corpus is smaller than top_k, and the metric used for approximate FAISS inner-product search (#3948, #3956, #4022).
  • Sped up CPU cosine semantic_search by normalizing each corpus chunk once (#4197).
  • Corrected paraphrase candidate capacity, deduplicated pairs before the max_pairs cap, and excluded self-matches before enforcing each sentence's top_k (#3930, #3979, #4189).
  • Used the supplied CrossEncoder for hard-negative filtering when only min_score is set (#4073).

Ranking losses and evaluators

  • Stabilized ListMLE/PListMLE normalization and long-list weights, and corrected one-based PListMLE positions (#4012, #4166, #4051).
  • Preserved gradients for strongly misordered pairs through weighted log-sigmoid, returned differentiable zero when no label pairs are ordered, and retained LambdaLoss pairs crossing the top-k cutoff (#4116, #4032, #4172).
  • Resolved model-derived IR scorers on each call and honored separate corpus models and cached embeddings in sparse IR evaluation (#3976, #4147).
  • Corrected binary thresholds for tied scores and treated string positives and negatives as whole documents in reranking evaluation (#4023, #4164).

Other fixes

  • Preserved SparseEncoder.max_active_dims and Router module sharing across saving and loading (#4046, #4180).
  • Fixed sampler epoch propagation, label grouping, and seed handling, and added bounded no-duplicate resampling. Extra passes can repeat samples or still fall short of the estimated batch count (#4002, #4013, #4109, #3946).
  • Preserved external ONNX weight files during export and upload, and accepted dictionary configurations for static OpenVINO quantization (#3913, #4219).

All Changes

  • Fix README dependency versions & increase ST dev version by @tomaarsen in #3952
  • Bump astral-sh/setup-uv from 9.0.0 to 10.0.0 in the actions group by @dependabot[bot] in #3958
  • Bump astral-sh/setup-uv from 10.0.0 to 10.0.1 in the actions group by @dependabot[bot] in #3970
  • [fix] Return the add_transitive_closure flag from ParaphraseMiningEvaluator.get_config_dict by @Kropiunig in #3919
  • [fix] Prevent CSR inference from updating dead-feature statistics by @eSVeeF in #3910
  • Return zero rather than nan from GlobalOrthogonalRegularizationLoss for a batch of one by @vineethsaivs in #3921
  • [fix] Retain max_pairs candidates in paraphrase mining by @FU-max-boop in #3930
  • [fix] Save the external data of an ONNX model over 2GB when exporting by @LK-maker-007 in #3913
  • Respect min_community_size for small inputs by @uczltw6 in #3954
  • Fix shared default tokenizer in WordEmbeddings.from_text_file by @Nikhi00718 in #3925
  • [v6.1] Resolve Hub revisions before model loading by @Wauplin in #3890
  • [feat] Support fractional pool_factor in HierarchicalTokenPooling by @tomaarsen in #3965
  • [fix] Resolve IR evaluator scoring per call instead of latching onto the first model by @tomaarsen in #3976
  • Remove the dead PeftModel branches from the Transformer module by @tomaarsen in #3975
  • Fix binary rescoring in Usearch by @tandede in #3948
  • [fix] Resolve the base model's config when loading a PEFT adapter checkpoint by @tomaarsen in #3978
  • [fix] Report worker crashes instead of hanging in multi-process encode by @codechrl in #3920
  • Move every result shape to CPU in the multi-process workers by @vineethsaivs in #3971
  • Fix duplicated/NaN results from semantic_search_usearch when corpus is smaller than top_k by @mayuriphad in #3956
  • Resample NoDuplicatesBatchSampler when a pass is shorter than len by @alireza-aminzadeh in #3946
  • Use fastcluster for faster hierarchical token pooling linkage by @tonywu71 in #3941
  • [fix] Deduplicate pairs before the max_pairs cap in paraphrase mining by @ebarkhordar in #3979
  • [fix] Write the sparsity CSV columns once in three sparse evaluators by @MaxFreedomPollard in #3985
  • [fix] Preserve CNN strides when saving and loading checkpoints by @mottopanikeiku in #3997
  • Fix binary classification evaluation with NumPy arrays and pandas Series by @Con-Benksl in #3995
  • Compare vocabularies with get_vocab() in CachedGISTEmbedLoss by @vineethsaivs in #3993
  • [fix] Keep composed batch samplers synchronized across epochs by @eSVeeF in #4002
  • Disable KV caching by default in Transformer by @tomaarsen in #3992
  • Migrate httpx imports through huggingface_hub by @Wauplin in #4003
  • [fix] Honor explicit CrossEncoder activation overrides when loading by @mottopanikeiku in #4006
  • Fix inference device placement for quantized and dispatched models by @tomaarsen in #3986
  • [tests] Use a new cached tiny MVE model by @tomaarsen in #4024
  • Distribute evaluator inference across DDP ranks by @tomaarsen in #4004
  • Keep label-grouped batches valid across shuffled rounds by @vineethsaivs in #4013
  • Stabilize ListMLE loss for large finite scores by @vineethsaivs in #4012
  • Fix compiled models with losses that require media counts in the trainer by @RizgarOzan in #4015
  • [fix] Prevent non-finite CSR reconstruction losses by @eSVeeF in #4016
  • [fix] Support disabling CSR auxiliary latents with k_aux=0 by @eSVeeF in #4017
  • Avoid overflow in batch-hard soft-margin triplet loss by @vineethsaivs in #4019
  • Keep single hard pairs in OnlineContrastiveLoss by @vineethsaivs in #4020
  • [fix] Use inner product for approximate FAISS search by @xblwh in #4022
  • Match contrastive-tension loader length to its batches by @vineethsaivs in #4021
  • Reduce repeated inference placement overhead by @tomaarsen in #4035
  • Fix attainable binary classification thresholds for tied scores by @HaokaiDing in #4023
  • Reuse calibration ranges across multi-vector embeddings by @ayoubchikri in #4025
  • Use quadratic-memory semi-hard triplet mining by @ayoubchikri in #4026
  • Prune invalid positive pairs before forming batch-all triplets by @ayoubchikri in #4029
  • Group tied scores when evaluating paraphrase mining by @vineethsaivs in #4028
  • Bump astral-sh/setup-uv from 10.0.1 to 10.1.0 in the actions group by @dependabot[bot] in #4043
  • [chore] Increment the dev version by @tomaarsen in #4049
  • Pin UTF-8 encoding when reading tokenizer/IDF JSON files by @dltsum in #4057
  • [docs] add the .md extension to the NLI/STS README links by @simpleqt in #4040
  • Stop discovering tiny models from trl-internal-testing by @albertvillanova in #4062
  • [docs] Fix legacy hf CLI references (sentence-transformers) by @Wauplin in #4063
  • Fix low precision overflow and accumulation errors in pooling by @AHMETHAKANBEZIR1 in #4106
  • Bump astral-sh/setup-uv from 10.1.0 to 10.2.0 in the actions group by @dependabot[bot] in #4112
  • [feat] Allow logits_to_keep through processing_kwargs by @tomaarsen in #4047
  • Add contribution guidelines and documentation setup by @tomaarsen in #4135
  • [feat] Save and load max_active_dims in SparseEncoder by @tomaarsen in #4046
  • Fix redundant DDP synchronization in cached losses by @tomaarsen in #4039
  • Delegate static distillation device selection to model2vec by @Anu27n in #4056
  • [fix] Keep each sentence's top_k across corpus chunks in paraphrase mining by @ewraj in #4131
  • [Bug] Keep FP64 in the GradCache replay surrogate by @gss10282025 in #4082
  • [fix] Keep leading dims when binary-quantizing a single embedding by @RizgarOzan in #4061
  • [docs] fix the duplicated word and missing verb in the MSEEEvaluatorFromDataFrame docstring by @simpleqt in #4041
  • [docs] align CrossEncoderCorrelationEvaluator's docstring with its signature by @simpleqt in #4042
  • [examples] Add PEP 723 script headers to the STS training examples by @davanstrien in #4072
  • [docs] Fix dead MTEB 'adding a model' link by @pratikgx in #4092
  • Drop two docstring entries for parameters that do not exist by @VenishPaneliya in #4118
  • Pass args.seed to the per-dataset batch samplers by @vineethsaivs in #4109
  • Fix CachedGISTEmbedLoss retokenization for flattened inputs by @palanigsharma182-ctrl in #4079
  • Handle optional Transformer kwargs when forwarding cache_dir by @LaoChouPro in #4050
  • Fix WordEmbeddings crash with HF tokenizers on transformers v5 by @simpleqt in #4085
  • Keep Euclidean similarity gradients finite at zero distance by @vineethsaivs in #4033
  • Skip softmax over single-label CrossEncoder scores by @jayzuccarelli in #4123
  • Apply model2vec token mapping and weights when loading StaticEmbedding by @JoeyTan21 in #4108
  • Document Perplexity v2 late-interaction models by @tomaarsen in #4141
  • Activate undocumented param rule (D417) by @Samoed in #4139
  • Fix normalize_embeddings crash on a single 1D embedding by @MohammadHijjawi97 in #4076
  • Fix encode(precision=...) and quantize_embeddings crashing on bfloat16 embeddings by @LindseyZ1205 in #4089
  • Fix similarity scoring of dense tensor lists by @LimbC-C in #4098
  • Fix NumPy and list inputs in pairwise_angle_sim by @eSVeeF in #4101
  • Fix scalar quantization arithmetic for float16 embeddings by @Afloat16 in #4113
  • Fix semantic_search crashing on a list of numpy embeddings by @MohammadHijjawi97 in #4064
  • Deprecate apply_softmax on CrossEncoder.rank by @tomaarsen in #4138
  • Fix uint64 precision loss in resolve_ids by @AHMETHAKANBEZIR1 in #4096
  • [fix] Warn about every include_positives option that discards the positives by @RizgarOzan in #4053
  • Rescore with the CrossEncoder when only min_score is set in mine_hard_negatives by @gauravch-code in #4073
  • Stop the multi-process pool when hard negative mining fails by @simpleqt in #4086
  • [fix] Respect verbose=False for the average-positives message in mine_hard_negatives by @eSVeeF in #4100
  • [fix] Clear ValueError instead of bare IndexError in mine_hard_negatives column resolution by @cloudydreamland in #4129
  • Count weightedmean positions from the first non-padding token by @AHMETHAKANBEZIR1 in #4104
  • Fix community_detection crashing on a 1D embedding by @MohammadHijjawi97 in #4065
  • [docs] Explain that an empty query prompt blocks the default_prompt_name fallback in encode_query by @Zhuoxi2000 in #4110
  • Fix CI NumPy conflict by excluding pyctcdecode by @tomaarsen in #4158
  • [fix] Restore checkpoints into compiled models by @mottopanikeiku in #4130
  • Compute CoSENT ranking loss with linear-memory suffix reductions by @ayoubchikri in #4030
  • Document Hugging Face login and refresh retrieval examples by @tomaarsen in #4160
  • Return zero ranking loss when no label pairs are ordered by @vineethsaivs in #4032
  • Count PListMLE rank positions from one, not zero by @vineethsaivs in #4051
  • Fix mean pooling precision and flattened CLS prompt exclusion by @tomaarsen in #4159
  • Flatten (n, 1) labels in losses that take one label per row by @johneckberg in #4145
  • Fix mixed-precision distances in batch triplet losses by @tjwjdrok in #4078
  • Add Python 3.14 support by @tomaarsen in #4162
  • Skip BF16 encode precision tests on affected Windows CPUs by @tomaarsen in #4163
  • Support probability targets in SoftmaxLoss by @amishaguptaberk in #4124
  • Preserve ranking-loss gradients with weighted log-sigmoid by @Afloat16 in #4116
  • Fail fast when a multi-process pool worker dies by @Samoed in #4146
  • Fix CoSENT score scaling precision under mixed precision by @AaravMehta-07 in #4167
  • Keep the CSR 4k latents off the dead-latent mask by @vineethsaivs in #4111
  • Compare CSR reconstructions with the raw input when normalize=True by @vineethsaivs in #4117
  • Fix calibration when rescoring scalar-quantized embeddings by @wcsnbilil in #4058
  • [fix] Raise a clear error when int8/uint8 ranges come from a single embedding by @emrehangorgec in #4150
  • Fix MaxSim memory use for long query batches by @Arthur031221 in #4153
  • Fix community_detection to drop communities whose centre was already claimed by @linhongyu510 in #4143
  • Warn when models implicitly load in low precision on CPU by @tomaarsen in #4169
  • [fix] Slice per-image VLM inputs by image count in cached losses by @arcusbuilds in #4157
  • Stabilize PListMLE position weights for long ranking lists by @kocean9-freedom in #4166
  • [fix] Keep string features whole in encode(output_value=None) by @mottopanikeiku in #4170
  • Fix semantic_search with an empty list corpus by @laulauraluo in #4171
  • Validate model paths and Dense activation classes before loading by @tomaarsen in #4175
  • [fix] Only truncate sentence embeddings in MatryoshkaLoss by @mottopanikeiku in #4173
  • Fix minimum dependency tests and run them on every PR by @tomaarsen in #4176
  • [fix] Keep LambdaLoss pairs that cross the top-k cutoff by @mottopanikeiku in #4172
  • Fix tensor teacher scores in multi-vector distillation evaluation by @aswanth-07 in #4133
  • Fix encoder-mask reuse in uncached multi-vector losses by @Afloat16 in #4127
  • Reuse shared model fixture in multi-vector encoder tests by @tomaarsen in #4177
  • [fix] Pad WordEmbeddings batches that have no known tokens by @mottopanikeiku in #4179
  • Fix repeated evaluation with iterator-backed SequentialEvaluator by @laulauraluo in #4183
  • fix: honor WordEmbeddings sequence length limit by @ch-z-hc in #4182
  • Truncate per-column Matryoshka teacher labels by @vineethsaivs in #4094
  • Average filtered loss components over the logged calls by @vineethsaivs in #4181
  • Schedule the regularizer weights of every SpladeLoss by @vineethsaivs in #4102
  • [fix] Normalize a single sparse embedding as one vector in normalize_embeddings by @emrehangorgec in #4149
  • Fix sparse embedding normalization for non-default dtypes by @HaokaiDing in #4045
  • [fix] Optimize the loss weights in SentenceTransformer.fit() by @Kropiunig in #4066
  • Size SparseStaticEmbedding.from_json weights by the vocabulary size by @LindseyZ1205 in #4142
  • Fix sparse IR evaluation ignoring corpus model and embeddings by @YueshenZ in #4147
  • [fix] Keep modules shared between Router routes shared after loading by @mottopanikeiku in #4180
  • Accept duplicate expected translation text in TranslationEvaluator by @LK-maker-007 in #4031
  • Fix loading Normalize modules at the model root by @tomaarsen in #4190
  • Validate paired sentence counts in MSEEvaluator by @leeshengis in #4187
  • Fix nested config tests for read-only Transformers sub_configs by @tomaarsen in #4192
  • [fix] Exclude self-matches before taking paraphrase mining's top_k by @mottopanikeiku in #4189
  • [fix] Match SoftmaxLoss inputs to the classifier dtype by @mottopanikeiku in #4193
  • [fix] Use router_mapping for model card dataset statistics by @mottopanikeiku in #4191
  • 🚨 Normalize hierarchical token pooling outputs by default by @tomaarsen in #4008
  • Reduce unnecessary model downloads in tests by @tomaarsen in #4198
  • Rewrite pairwise_angle_sim as clearer cos+sin form by @Eryx-Z in #4194
  • Fix fit() crash with a DataLoader batch_sampler and warn that it is not used by @zikrulihsan in #4228
  • [fix] Share quantization ranges in similarity evaluation by @mottopanikeiku in #4226
  • Span every objective's steps in the fit() learning rate schedule by @vineethsaivs in #4225
  • Shuffle complete label groups before trimming odd rows by @Bembaby in #4208
  • [docs] Correct custom PListMLE discount callback documentation and examples by @nancy6547 in #4204
  • Keep new sparse search corpora from sharing an index name by @Bembaby in #4217
  • Write numeric MSE values in sparse evaluator CSV files by @Bembaby in #4221
  • Honor the correlation evaluator progress-bar option by @Bembaby in #4222
  • Fix cache-folder forwarding in sparse IDF JSON checkpoint loading by @Bembaby in #4214
  • Forward advertised module kwargs during MultiVectorEncoder encoding by @Bembaby in #4215
  • Accept dictionary configurations in static OpenVINO quantization by @Bembaby in #4219
  • Apply per-dataset prompts and losses to a reused DatasetDict by @LindseyZ1205 in #4202
  • Speed up semantic_search up to 1.46x on CPU by normalizing each corpus chunk once by @deadstrobe5 in #4197
  • Simplify optional dependency checks with pytest.importorskip by @tomaarsen in #4229
  • Skip rows with an empty text when building widget examples by @zikrulihsan in #4233
  • Add SlideOn and mSlideOn to Sparse Encoder pretrained models by @tomaarsen in #4234
  • [feat] Support opt-in fp32 computation for selected linear layers by @tomaarsen in #4230
  • [feat] Add model merging via mergekit for all archetypes by @yjoonjang in #3776
  • Stack tensor-formatted labels in the data collator by @Bembaby in #4231
  • Accept a string main_score_function in NanoBEIREvaluator by @RizgarOzan in #4034
  • Evaluate the main similarity function in TripletEvaluator by @vineethsaivs in #4088
  • Keep the RRF fusion order the same from run to run by @vineethsaivs in #4067
  • Follow only duplicate pairs in the paraphrase mining transitive closure by @vineethsaivs in #4120
  • Treat a string positive or negative as one document in RerankingEvaluator by @LindseyZ1205 in #4164
  • Fix blank rows in CrossEncoder and RRF evaluator CSVs on Windows by @abo3losh1 in #4077
  • Skip bfloat16 transformer head tests on affected Windows runners by @tomaarsen in #4242
  • Forward gradient checkpointing options to Transformers by @tomaarsen in #4241

New Contributors

Full Changelog: v6.1.0...v6.2.0

Don't miss a new sentence-transformers release

NewReleases is sending notifications on new releases.