feat: v0.5.2 — embeddings + reranker (MLXEmbedders)#53
Merged
Conversation
- EmbeddingEngine (MLXEmbedders): batch embedding with mean/last-token pooling, mask-aware (pooling excludes padding), L2-normalized output - POST /v1/embeddings (OpenAI-compatible) + POST /v1/rerank (bi-encoder MVP: cosine over embeddings; true cross-encoder deferred) - HuggingFaceTokenizerLoader extracted from MLXSwiftEngine (shared by chat + embedding paths) - LocalModel.embedder kind + ModelLibraryManager detection (config architectures / model_type heuristics) + Models tab badge - MLXEmbedders dependency in MacMLXCore Package.swift Tests: EmbeddingPoolingTests (incl. the padding-mask regression that was the review blocker), RerankScoringTests, embedder detection, HummingbirdServerEmbeddingsTests.
…n lock acquireGenerationLock became throwing (cancellation-aware waiters) in v0.5.3; the embeddings/rerank handlers now try-acquire with the exactly-once discipline: a throw means the lock is NOT held, so those paths return an error without releasing.
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
This was referenced Jul 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Lands the v0.5.2 embeddings/rerank feature (implemented + code-reviewed earlier; the review's one BLOCKER — pooling ignoring the attention mask — was fixed with a regression test before this PR).
What lands
LocalModel.embedderkind + detection heuristics + Models-tab badge; MLXEmbedders dependency.Verification
Unified state (this branch = v0.5.2 + v0.5.3 + DeepSeek V3.2):
** TEST SUCCEEDED **, 76 XCTest + 203 swift-testing in 27 suites, 0 failures — embeddings/rerank/detection suites, all 7 v0.5.3 regression tests, and all 11 DeepSeek parity tests coexist green.Known follow-ups (tracked): true cross-encoder reranker, gate /v1/embeddings on .embedder kind, decoder-family embedder detection.