Commit 14fbee6
committed
refactor(indexer): consolidate embedding initialization to use config
Architectural fix: Symbol resolution now uses the same configuration path
as main indexing instead of creating a separate EmbeddingGenerator with
environment variables.
Before: ai_resolve_symbol() called with_auto_from_env() - different init path
After: ai_resolve_symbol() calls with_config(&self.global_config) - same as main indexing
This ensures:
1. Single source of truth for embedding configuration
2. Consistent provider selection across all code paths
3. No duplicate initialization logic
4. Easier maintenance and testing
The indexer already has access to global_config in the ProjectIndexer struct,
so this is a simple one-line change that eliminates architectural inconsistency.1 parent d5b8f13 commit 14fbee6
1 file changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1674 | 1674 | | |
1675 | 1675 | | |
1676 | 1676 | | |
1677 | | - | |
1678 | | - | |
| 1677 | + | |
| 1678 | + | |
1679 | 1679 | | |
1680 | 1680 | | |
1681 | 1681 | | |
| |||
0 commit comments