refactor: migrate to genai-lite LLM module#65
Merged
Merged
Conversation
Signed-off-by: Luigi Acerbi <luigi.acerbi@gmail.com>
Replace integrated LLM implementation with genai-lite package: - Add genai-lite ^0.1.0 dependency - Remove old electron/modules/llm directory - Implement custom ApiKeyProvider using genai-key-storage-lite - Centralize IPC channel constants in common/types/llm.ts - Update all imports and type references to use genai-lite - Fix webpack configs to include common directory - Maintain full backward compatibility with existing API 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: lacerbi <luigi.acerbi@gmail.com>
- Add environment variable checking to isKeyAvailable handler - Update ApiKeyProvider to fall back to env vars when storage fails - Support ATHANOR_<PROVIDER>_API_KEY pattern for all providers - Fix documentation: use ATHANOR_GEMINI_API_KEY (not GOOGLE) - Add Mistral to environment variable examples 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: lacerbi <luigi.acerbi@gmail.com>
Update CLAUDE.md and PROJECT.md to reflect the new architecture: - Replace references to old electron/modules/llm/ directory - Document genai-lite as the unified LLM integration - Add common/types/ directory documentation - Note environment variable support pattern - Update dependency lists to remove individual LLM SDKs 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: lacerbi <luigi.acerbi@gmail.com>
Document the migration to genai-lite external package and all related improvements. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: lacerbi <luigi.acerbi@gmail.com>
Both migrations are now complete: - API keys module migration (completed in v0.7.9) - LLM module migration (completed in v0.7.10) These design documents have served their purpose and can be removed. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: lacerbi <luigi.acerbi@gmail.com>
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.
Summary
genai-litepackage (^0.1.0)Changes
Core Refactoring
electron/modules/llm/directory containing internal LLM implementationgenai-liteas external dependency providing unified LLM functionalitycommon/types/llm.tsfor shared IPC channel constantsBuild System Updates
common/directory for TypeScript compilationnpm run packageBug Fixes
ATHANOR_<PROVIDER>_API_KEY) that was temporarily lostATHANOR_GEMINI_API_KEY(was incorrectlyATHANOR_GOOGLE_API_KEY)Documentation
CLAUDE.mdandPROJECT.mdto reflect new architecturecommon/types/pattern for shared typesTest Plan
npx tsc --noEmit)npm run package)Breaking Changes
None - this refactoring maintains full backward compatibility.
🤖 Generated with Claude Code