File tree Expand file tree Collapse file tree 3 files changed +7
-2
lines changed
Expand file tree Collapse file tree 3 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,11 @@ and the project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.
77
88## [ Unreleased]
99
10+ ## [ 1.3.2] - 2025-12-04
11+
12+ ### Fixed
13+ - Further reduced default EMBEDDING_BATCH_SIZE from 10 to 3 (batch_size × chunk_tokens must be < 2048)
14+
1015## [ 1.3.1] - 2025-12-04
1116
1217### Fixed
Original file line number Diff line number Diff line change @@ -94,7 +94,7 @@ docker compose up -d
9494| ` OLLAMA_MODEL ` | ` nomic-embed-text ` | Embedding model |
9595| ` CHUNK_SIZE ` | ` 400 ` | Target chunk size in tokens |
9696| ` CHUNK_MAX_TOKENS ` | ` 1500 ` | Maximum chunk size (safe margin for nomic-embed-text 2048 limit) |
97- | ` EMBEDDING_BATCH_SIZE ` | ` 10 ` | Chunks per embedding API call (reduce if Ollama errors ) |
97+ | ` EMBEDDING_BATCH_SIZE ` | ` 3 ` | Chunks per embedding API call (batch_size × chunk_tokens < 2048 ) |
9898
9999## Features
100100
Original file line number Diff line number Diff line change 1717OLLAMA_URL = os .getenv ('OLLAMA_URL' , 'http://localhost:11434' )
1818EMBEDDING_MODEL = os .getenv ('EMBEDDING_MODEL' , 'nomic-embed-text' )
1919MAX_TOKENS = 2048 # nomic-embed-text context limit (configurable models may differ)
20- EMBEDDING_BATCH_SIZE = int (os .getenv ('EMBEDDING_BATCH_SIZE' , '10 ' )) # Reduced from 32 to avoid Ollama batch decode errors
20+ EMBEDDING_BATCH_SIZE = int (os .getenv ('EMBEDDING_BATCH_SIZE' , '3 ' )) # Low default: batch_size * avg_chunk_tokens must be < 2048
2121
2222
2323def get_embedding (text : str , timeout : int = 60 , max_retries : int = 3 ) -> Optional [list [float ]]:
You can’t perform that action at this time.
0 commit comments