Skip to content

Develop#18

Merged
AperturePlus merged 5 commits intomasterfrom
develop
Mar 4, 2026
Merged

Develop#18
AperturePlus merged 5 commits intomasterfrom
develop

Conversation

@AperturePlus
Copy link
Owner

fix #3

Why:
Indexing aborted entirely when one text exceeded model token limits at min batch size.

What:
Changed fallback logic to skip permanently oversized items by inserting a zero-vector placeholder and continuing processing.
Updated embedding client docs/messages to reflect the new behavior.
Added property test coverage to verify oversized-item isolation and output ordering preservation.

Test:
uv run ruff check src tests (pass)
uv run pytest tests/property/test_embedding_client_properties.py -q (pass)
uv run mypy src --ignore-missing-imports --no-error-summary (fails: existing repo-wide type issues unrelated to this change)
uv run pytest tests/ -v --tb=short -q --durations=10 (did not complete cleanly in this run; emitted multiple failures early)
…or-oversized-items

fix(embedding): skip oversized single item during fallback
Why:
The oversized-item token-limit fix needs an explicit, fast regression test
that validates behavior without running the full property suite.

What:
- Added unit tests for OpenAIEmbeddingClient fallback behavior.
- Verified oversized single items are replaced with zero vectors and indexing can continue.
- Verified fallback-disabled mode still raises NonRetryableError.

Test:
- uv run ruff check src tests (pass)
- uv run pytest tests/unit/test_embedding_client_fallback.py -q (pass)
- uv run pytest tests/ -v --tb=short -q --durations=10 (fails in existing suite; interrupted after multiple pre-existing failures)
- uv run mypy src --ignore-missing-imports --no-error-summary (fails with pre-existing type errors)
…-oversized-items

test(embedding): add regression tests for oversized-item token-limit fallback
@AperturePlus AperturePlus merged commit bbb8f00 into master Mar 4, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Indexing aborts when single chunk/summary exceeds embedding model token limit

1 participant