Skip to content

feat: Always enable embeddings, remove config toggle#74

Merged
colbymchenry merged 1 commit into
mainfrom
feat/always-enable-embeddings
Apr 3, 2026
Merged

feat: Always enable embeddings, remove config toggle#74
colbymchenry merged 1 commit into
mainfrom
feat/always-enable-embeddings

Conversation

@colbymchenry
Copy link
Copy Markdown
Owner

Summary

  • Removes the enableEmbeddings config option entirely — embeddings are now always enabled
  • Vector manager is created eagerly in the CodeGraph constructor (model download + embedding generation still happen lazily)
  • Updates visualizer server to remove the config toggle step from the embeddings generate endpoint

Why

Testing with 13 queries ranging from exact symbol lookups to natural language showed that semantic search consistently outperforms FTS-only search for the kinds of queries Claude writes:

  • "ExtractionOrchestrator" — FTS returned rootDir (a property) as How do you use this across multiple projects #1; semantic correctly returned the class
  • "how does file parsing work" — FTS returned readJsonFile (config I/O); semantic returned getParser
  • "database connection management" — FTS returned optimize; semantic found DatabaseConnection
  • "resolves references between modules" — FTS found framework-specific helpers; semantic found the main resolveOne orchestrator

FTS has a ranking problem where properties/methods that match tokens often outrank the conceptually relevant class or function. Semantic search understands intent.

Test plan

  • All 21 vector tests pass (updated the one test that expected null stats)
  • Build succeeds
  • Backward compatible — old config files with enableEmbeddings field are harmlessly ignored during config merge

🤖 Generated with Claude Code

Testing showed semantic search produces significantly better results for
natural language queries that Claude writes. FTS alone often ranks
properties above their parent classes and misses conceptual matches.
Embeddings are now always on — the vector manager is created eagerly,
with model download and embedding generation still happening lazily.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.

1 participant