Repository navigation
refactor(embedding): 删除无调用的 Token 估算函数 - #6134
Merged
qin-ctx merged 1 commit intoOct 15, 2026
Merged
Conversation
Remove the estimator left without production callers after the truncation rewrite, along with its test-only assertions. Keep truncation coverage. Co-authored-by: qin-ctx <qinhaojie.exe@bytedance.com>
qin-ctx
approved these changes
Oct 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
删除截断重构后已无生产调用的
estimate_embedding_input_tokens,以及测试中对它的引用和断言。保留入队前截断的行为验证,无运行时行为变化。Human Involvement
Related Issue
Related #6129。本 PR 仅清理死代码,不修复真实 Token 超限问题。
Type of Change
Changes Made
expected_tokens参数和估算断言,保留截断结果断言。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:
pytest -q --no-cov tests/unit/test_vectorize_file_strategy.py -k bounds_content_before_enqueue:3 passed。修改文件的
ruff check、ruff format --check和git diff --check通过。Checklist
Screenshots (if applicable)
不涉及。
Additional Notes
无。