Skip to content

Data API with lexical/analyzer off does not accept explicit "enabled: false" setting for collections #2423

@sl-at-ibm

Description

@sl-at-ibm

(Originally reported by @clun )

Summary:

It should be possible to indicate re-ranking is disabled regardless of whether it'd be possible to enable, but currently the server errors on doing that.

(Tatu: I am guessing option validation done in wrong place [...]).

Description

When the Data API is started without lexical/analyzer support, as is currently the case e.g. for Mission Control, attempts to create a collection with these settings explicitly set to 'disabled' result in an error:

{
  "createCollection": {
    "name": "collection_vector",
    "options": {
      "vector": {
        "dimension": 14,
        "metric": "cosine"
      },
      "lexical": {
        "enabled": false
      },
      "rerank": {
        "enabled": false
      }
    }
  }
}

A payload like the above results in:

{
  "errors": [
    {
      "message": "Reranking feature is not enabled",
      "errorCode": "RERANKING_FEATURE_NOT_ENABLED",
      "family": "REQUEST",
      "scope": "RERANKING",
      "title": "Reranking feature is not enabled",
      "id": "4ff098df-ac53-4c8f-9566-f69ea6bfef18"
    }
  ]
}

Expected behaviour

Since the payload specifies enabled: false (which matches the available support), the expectation is that this collection is created correctly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions