Skip to content

知识库文档解析报错:code=105000004 ,dense_text_content vector dim 1024 not match collection definition, which has dim of 2048 #2608

@DoubleEspresso-7

Description

@DoubleEspresso-7

Describe the bug

A clear and concise description of what the bug is.
知识库中添加文件向量化失败,看起来.env的配置没有生效,在模型管理后台也配置了openai的bge-m3,但都没用

报错:
code=105000004 message=SearchStore operation failed: store search store failed, err: [Store] upsert failed, params column dense_text_content vector dim 1024 not match collection definition, which has dim of 2048

.env embedding配置:
export EMBEDDING_TYPE="openai"
export EMBEDDING_MAX_BATCH_SIZE=100

export ARK_EMBEDDING_BASE_URL="" # (string, required) Ark embedding base_url
export ARK_EMBEDDING_MODEL="" # (string, required) Ark embedding model
export ARK_EMBEDDING_API_KEY="" # (string, required) Ark embedding api_key
export ARK_EMBEDDING_DIMS="2048" # (int, required) Ark embedding dimensions
export ARK_EMBEDDING_API_TYPE="" # (string, optional) Ark embedding api type, should be "text_api" / "multi_modal_api". Default "text_api".

export OPENAI_EMBEDDING_BASE_URL="http://xxxx:8090/v1" # (string, required) OpenAI embedding base_url
export OPENAI_EMBEDDING_MODEL="bge-m3" # (string, required) OpenAI embedding model
export OPENAI_EMBEDDING_API_KEY="" # (string, required) OpenAI embedding api_key
export OPENAI_EMBEDDING_BY_AZURE=false # (bool, optional) OpenAI embedding by_azure
export OPENAI_EMBEDDING_API_VERSION="" # (string, optional) OpenAI embedding azure api version
export OPENAI_EMBEDDING_DIMS=1024 # (int, required) OpenAI embedding dimensions
export OPENAI_EMBEDDING_REQUEST_DIMS=1024 # (int, optional) OpenAI embedding dimensions in requests, need to be empty if api doesn't support specifying dimensions.

To Reproduce

Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior

A clear and concise description of what you expected to happen.

Screenshots

If applicable, add screenshots to help explain your problem.

Version:

Please provide the version of {project_name} you are using.

Environment:

The output of go env.

Additional context

Add any other context about the problem here.

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