Repository navigation
[Feature] Add a lightweight Russian-language CLIP model for Smart Search (ruCLIP) #33465
Abikutin
started this conversation in
Feature Request
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I have searched the existing feature requests, both open and closed, to make sure this is not a duplicate request.
The feature
I'd like to suggest adding support for a lightweight Russian-language CLIP model, such as Sber AI's ruCLIP, to Immich Smart Search.
A promising candidate is ai-forever/ruclip-vit-base-patch32-224.
Motivation
The default ViT-B-32__openai model works reasonably well for English queries, but its performance with Russian-language searches is noticeably worse.
Immich already supports more capable multilingual models, such as ViT-B-16-SigLIP2__webli. However, these models have significantly higher memory requirements, making them less suitable for home NAS devices with limited RAM.
For example, I'm running Immich on a TerraMaster NAS with an Intel N95 processor and 8 GB of RAM. I'd like to search my photos using natural Russian queries without allocating several gigabytes of memory to the machine learning service.
Why ruCLIP?
ruCLIP was specifically developed for Russian-language image-text similarity tasks.
The proposed model contains approximately 150 million parameters and uses a ViT-B/32 architecture.
Its architecture suggests that it may have lower memory requirements than larger multilingual models, although actual RAM consumption in Immich would need to be measured.
Ideally, it could operate within approximately 1–2 GB of RAM.
The official ruCLIP repository links to an existing ONNX export example:
https://github.com/Lednik7/CLIP-ONNX/blob/main/examples/RuCLIP_onnx_example.ipynb
This could simplify integration with Immich's ONNX Runtime pipeline, although compatibility with Immich's model format, preprocessing and tokenizer would still need to be verified.
The ruCLIP source code is available under the Apache-2.0 license. The redistribution terms for the specific model weights would need to be confirmed separately.
Suggested evaluation
It would be useful to compare ruCLIP with existing Smart Search models in terms of:
Russian-language search quality.
Memory consumption during indexing and search.
CPU inference performance on low-power NAS hardware.
Compatibility with the existing Immich machine learning pipeline.
English-language search quality, to understand potential trade-offs.
Willingness to test
I'm happy to help test an experimental version on my TerraMaster NAS (Intel N95, 8 GB RAM) and provide feedback on memory consumption, performance and search quality.
I don't have experience integrating custom machine learning models into Immich, but I would be willing to test a prepared model or experimental build if the maintainers provide instructions.
References
Model: https://huggingface.co/ai-forever/ruclip-vit-base-patch32-224
Source code: https://github.com/ai-forever/ru-clip
ONNX export example: https://github.com/Lednik7/CLIP-ONNX/blob/main/examples/RuCLIP_onnx_example.ipynb
Immich model repository: https://huggingface.co/immich-app/models
Question
Would the maintainers consider evaluating ruCLIP as a lightweight option for Russian-language Smart Search?
Alternatively, would supporting user-provided compatible ONNX CLIP models be a preferred approach?
Platform
All reactions