feat(ai): add Gemini as a third AI provider#18
Open
alon710 wants to merge 11 commits into
Open
Conversation
Adds Google Gemini alongside Claude and Ollama for transaction categorization. Uses @google/genai with gemini-2.5-flash and stores the API key encrypted under provider-specific setting keys so it can coexist with a Claude key. Wires the new option through the setup wizard, settings page, factory, and i18n. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Adds a streaming /chat page that uses the same AI provider configured for categorization (Claude or Ollama). The agent answers free-text questions about the user's finances through tool calls that wrap existing read-only DB queries (transactions, monthly summary, top merchants, category breakdown). Page and sidebar entry are disabled when no AI provider is configured. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Next.js 16 renames the Middleware file convention to Proxy. The build emits a deprecation warning until the rename happens. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
refactor: rename middleware.ts to proxy.ts for Next.js 16
- always require a key on save and drop the leave-blank-to-keep-stored UX, removing the hasStoredKey helper, hasClaudeApiKey/hasGeminiApiKey flags, and the i18n hint pair this required - extract shared parseCategorizationResponse used by ClaudeProvider and GeminiProvider - merge ClaudeConfig and GeminiConfig in the setup wizard into a single ApiKeyConfig with a children slot for provider-specific extras - dispatch friendlyAIError on the provider argument instead of cascading regex matches over raw error text - drop redundant Gemini model whitelist checks in the factory and settings writer Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…endering Adds persistent chat sessions backed by SQLite (migration 021), a session history sidebar with rename and delete actions, AI-generated chat titles via a setChatTitle tool, and markdown rendering for assistant responses using react-markdown. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
feat(chat): AI chat agent with persistent sessions and tool-based data access
…ovider-v2 # Conflicts: # package-lock.json
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
src/server/ai/lib/parse-response.tsso Claude and the new Gemini provider share categorization-response handling.Shaya16/Spentrepo inCLAUDE.mdand refreshesREADME.mdaccordingly.Test plan