Skip to content

Conversation

@swapniel99
Copy link

Related Issues

None

Proposed Changes:

Added a revision parameter to all Sentence Transformers embedder components to allow users to specify a specific model revision/version from the Hugging Face Hub. This parameter is passed through to the underlying Sentence Transformers backend.

How did you test it?

  • Added unit tests for all four embedder components to verify the revision parameter is correctly:
    • Initialized with default value (None)
    • Set when provided explicitly (e.g., "v1.0")
    • Serialized and deserialized in to_dict() and from_dict() methods
  • Updated existing backend initialization tests to include the revision parameter
  • All pre-commit hooks passed successfully

Notes for the reviewer

The revision parameter follows the same pattern as other optional parameters like trust_remote_code and local_files_only. It's passed directly to the Sentence Transformers model initialization, allowing users to pin to specific model versions for reproducibility.

Checklist

  • I have read the contributors guidelines and the code of conduct
  • I have updated the related issue with new insights and changes
  • I added unit tests and updated the docstrings
  • I've used one of the conventional commit types for my PR title: fix:, feat:, build:, chore:, ci:, docs:, style:, refactor:, perf:, test: and added ! in case the PR includes breaking changes.
  • I documented my code
  • I ran pre-commit hooks and fixed any issue

@swapniel99 swapniel99 requested a review from a team as a code owner November 1, 2025 08:58
@swapniel99 swapniel99 requested review from sjrl and removed request for a team November 1, 2025 08:58
@vercel
Copy link

vercel bot commented Nov 1, 2025

@swapniel99 is attempting to deploy a commit to the deepset Team on Vercel.

A member of the Team first needs to authorize it.

@CLAassistant
Copy link

CLAassistant commented Nov 1, 2025

CLA assistant check
All committers have signed the CLA.

@github-actions github-actions bot added topic:tests type:documentation Improvements on the docs labels Nov 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic:tests type:documentation Improvements on the docs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants