✨ feat: add batch processing, auto-sort, custom prompt, and debug mode#7
Open
rfiacne wants to merge 82 commits into
Open
✨ feat: add batch processing, auto-sort, custom prompt, and debug mode#7rfiacne wants to merge 82 commits into
rfiacne wants to merge 82 commits into
Conversation
- Fix manual label menu to properly handle selected messages - Use await with browser.tabs.sendMessage to get response - Get full message objects from mailTabs.getSelectedMessages - Process all selected messages instead of just getting response
- Fixed manual label menu to process all selected emails (not just 2) - Added example email folder categories with collapsible spoiler - Improved error handling for batch operations - Better message routing for manual label application
- When a category folder is not found (null), skip to the next category - Prevents early exit if a matching category prefix exists but folder not found - Better fallback handling for direct folder match
- Multi-provider AI support (Gemini, OpenAI, Anthropic, Groq, Mistral) - Fixed batch email processing (all selected emails now processed) - Added example email folder categories with spoiler - Skip null categories and try next one - IMAP folder discovery with recursive traversal - Professional UI with provider info cards - Move history tracking (last 100 entries) - All syntax errors fixed
- Create folder on the fly if a configured custom label folder is missing - Skip auto-creation for imported/structured labels (contain / or \) - Uses first account folder as parent; logs failures but continues
- Added prominent warning box in settings UI - Updated README with detailed rate limit estimates per provider - Updated release notes with API quota guidance - Free tiers: 5-20 emails before hitting limits - Groq and Gemini recommended for best free tier limits - Paid plans recommended for daily email processing
- Free tier: 5 requests per minute (12 second delay between requests) - Free tier: 20 requests per day limit - Added 'Gemini paid plan' checkbox in settings to bypass limits - Shows countdown timer during rate limiting - Displays hours until daily reset when limit reached - Tracks requests in browser storage - Only applies to Gemini provider - Paid plan users can disable rate limiting
- Shows current daily usage (X/20 requests) - Displays last request time - Shows time until daily limit resets - Status indicator (Ready/Nearly Full/Limit Reached) - Warning when approaching or at limit - Alerts when to switch to new API key - Reset counter button for new API keys - Refresh usage button - Auto-updates when switching providers
…hanced organization - Added Privacy & Security section with feature table - Converted Troubleshooting to collapsible details sections - Added System Requirements table - Enhanced Changelog with collapsible feature categories - Created Roadmap & TODO priority table - Added professional Support & Community section - Expanded Contributing guidelines - Included full MIT License text - Enhanced Credits & Acknowledgments - Added Star History chart - Professional footer with navigation and badges
…eature showcase index.md: - Added centered header with badges and navigation - Multi-provider comparison table - Complete v1.2.0 feature showcase with gradient styling - AI provider comparison with free tier details - Quick start guide with step-by-step instructions - Gemini rate limit management guides - Privacy & security table - Advanced configuration section - System architecture diagram - Enhanced troubleshooting with solutions - Support & community section with table - Contributing guidelines with dev setup - Full credits and acknowledgments - Star history chart integration _config.yml: - Enhanced SEO with jekyll-seo-tag - Added sitemap plugin - Improved metadata (title, description, author) - Repository and URL configuration - Social media integration ready - Kramdown with syntax highlighting - Collections setup for future expansion - Better build settings and excludes
OpenAI-compatible provider: - Custom endpoint support with base URL + model selection - Model dropdown with Fetch Models button - API key optional for local endpoints (no auth required) - max_tokens: 8192 for reasoning models (Qwen3 etc) Debug mode: - Toggle in General Settings (Ctrl+Shift+I to view logs) - Colored console tags: [AutoSort+], [Gemini], [Ollama], [Custom] - apiRequest/apiResponse collapsible groups - Cross-context sync via browser.storage.local Bug fixes: - Provider switch: hide/show correct subsections - Save button state updates on all input changes - Input validation for Ollama and OpenAI-compatible configs
- Extract subject, author, attachments for better AI categorization - Build folder Map to avoid N+1 recursion in batch processing - Cache accounts to avoid N+1 fetching - Parallel auto-sort with provider-based concurrency limit - Gemini rate limit mutex for atomic operations - Add shared tab fetch utility module Bug fixes: - pct undefined crash in batch progress - error message lost in catch block - missing return true for async message handler - message.folder null pointer risk - ollamaNumCtx setting ignored - context menu stale after label changes
81385ab to
b8820b8
Compare
Add Thunderbird _locales/ based internationalization with en and zh_CN translations. All UI text, provider info, badges, and dynamic status messages are now localized.
Owner
|
Wow, thanks for the major updates! |
Author
|
Thank you so much for the kind words! No worries at all about the response time — I really appreciate you taking a look. Please let me know if there’s anything you’d like me to adjust or improve. Looking forward to your feedback!
|
31b84b4 to
b6b5252
Compare
- Add full English and Simplified Chinese translations (1260+ message keys) - Fix: autoSortEnabled defaults to true for backward compatibility with users upgrading from older versions (storage migration, guard fix, checkbox default). Auto-sort was silently disabled after update because the new setting key was undefined and treated as disabled. - Add autoSortEnabled unit test suite (13 cases)
1bca749 to
1bef445
Compare
browser.i18n.getMessage() only supports $1/$2 positional syntax, but
messages.json uses {key} format. Add manual {key}→value substitution
in i18n.get() with a placeholder mapping table for all 50 keys.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.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
This PR adds several features to AutoSort+ Thunderbird extension for improved email sorting workflow (and it is all ai generated, if you didn't notice):
🚀 New Features
1. Batch Processing with Controls
2. Batch Chunk Processing
3. Auto-Sort New Emails
4. Custom Prompt Feature
{labels}for folder list,{email}for email content5. OpenAI-Compatible Provider
/v1/modelsendpoint6. Debug Mode
🐛 Bug Fixes
convertToPlainTextnot being awaited, causing[object Promise]in AI prompts📁 Files Changed