Model names in Docker has changed

Created on 4 September 2025, about 1 month ago

Problem/Motivation

When you have set everything up with Milvus, Docker Models and this module and are about to configure the Server in Search API you are unable to save. The dimension value that is required is not pre-populated. This is because the names that Docker Models use have changed and no longer match.

Steps to reproduce

After installing the module go to /admin/config/search/search-api/add-server and select AI search, in the Embeddings pulldown select "Docker Model Runner | ai/mxbai-embed-large:latest" and check that the value for Dimensions in the section "Advanced Embeddings Engine Configuration".

https://www.drupal.org/files/issues/2025-09-04/Screenshot%202025-09-04%2...

Proposed resolution

In DockerModuleRunnerProvider.php this is the code:

  public function embeddingsVectorSize(string $model_id): int {
    return match($model_id) {
      'ai/mxbai-embed-large' => 1024,
      default => 0,
    };
  }

but with Docker 4.44.3 for example the mxbai model has been appended with :latest
There is also a (new?) embeddings model called Nomic that is missing.

  public function embeddingsVectorSize(string $model_id): int {
    return match($model_id) {
      'ai/mxbai-embed-large' => 1024,
      'ai/mxbai-embed-large:latest' => 1024,
      'ai/nomic-embed-text-v1.5:latest' => 768,
      default => 0,
    };
  }

To keep backwards capability it is probably good to keep the original name as well.

🐛 Bug report
Status

Active

Version

1.0

Component

Code

Created by

🇫🇮Finland seiplax

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024