Skip to content

refactor(vectordb): remove legacy vectorize path - #3024

Merged
qin-ctx merged 1 commit into
mainfrom
refactor/remove-vectordb-vectorize
Jul 6, 2026
Merged

refactor(vectordb): remove legacy vectorize path#3024
qin-ctx merged 1 commit into
mainfrom
refactor/remove-vectordb-vectorize

Conversation

@qin-ctx

@qin-ctx qin-ctx commented Jul 6, 2026

Copy link
Copy Markdown
Collaborator

Description

移除底层 vectordb collection 的遗留 Vectorize 自动向量化路径,避免它和 OpenViking 当前标准 embedding queue 链路混淆。标准链路中的 openviking.core.context.Vectorizeembedding.max_input_tokens 处理不受影响。

Related Issue

无直接关闭 issue。背景来自 #3010 排查,但本 PR 不关闭该 issue。

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Refactoring (no functional changes)
  • Performance improvement
  • Test update

Changes Made

  • 删除 openviking/storage/vectordb/vectorize/ 下的旧自动向量化实现。
  • LocalCollection 不再创建或持有 VectorizerAdapter,写入时只接受调用方传入的 vector / sparse_vector
  • collection create API 和 metadata validation 不再暴露 Vectorize 配置,并在 CollectionMeta 构建时丢弃历史传入的 Vectorize 字段。

Testing

  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have tested this on the following platforms:
    • Linux
    • macOS
    • Windows

本地验证:

  • python3 -m py_compile openviking/storage/vectordb/collection/local_collection.py openviking/storage/vectordb/meta/collection_meta.py openviking/storage/vectordb/service/api_fastapi.py openviking/storage/vectordb/service/app_models.py openviking/storage/vectordb/utils/validation.py
  • git diff --check
  • rg -n "VectorizerAdapter|VectorizerFactory|BaseVectorizer|openviking\\.storage\\.vectordb\\.vectorize|meta\\.vectorize|request\\.Vectorize|\\\"Vectorize\\\"|Vectorize:" openviking tests -S

未运行:当前环境缺少 pytestruff Python 模块。

Checklist

  • My code follows the project's coding style
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • Any dependent changes have been merged and published

Screenshots (if applicable)

不适用。

Additional Notes

这个 PR 只清理底层 vectordb collection meta 的 Vectorize 自动向量化能力;不删除主链路使用的 openviking.core.context.Vectorize 数据结构。

@qin-ctx
qin-ctx merged commit b931f4d into main Jul 6, 2026
3 checks passed
@qin-ctx
qin-ctx deleted the refactor/remove-vectordb-vectorize branch July 6, 2026 04:11
@github-project-automation github-project-automation Bot moved this from Backlog to Done in OpenViking project Jul 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants