Skip to content

babegeman/ai-tab-grouper

Repository files navigation

AI Tab Grouper Chrome Extension (v0.1.0 Alpha)

A Chrome extension that automatically groups your open tabs into logical categories using Claude AI with a streamlined two-step process: content analysis and intelligent grouping.

Alpha Release: This is an early version with core functionality. Features include parallel batch processing, robust content extraction, and real-time progress tracking.

✨ Key Features

  • 🤖 Claude Sonnet 4 AI - Advanced intelligent tab categorization
  • 📊 Two-Step Process - Parallel batch summarization followed by single grouping decision
  • 🛠️ Tool-Based Priority - Smart recognition of popular platforms (GitHub, Jira, Claude, AWS, etc.)
  • 📄 Universal Content Analysis - Every tab gets scraped and analyzed uniformly
  • 🔍 Live Diagnostics - Real-time progress tracking with detailed analysis results
  • 📱 State Persistence - Progress remains visible when popup is closed and reopened
  • ⏹️ Stop Processing - Cancel long-running operations anytime with stop button
  • 🎨 Smart Grouping Modes - Incremental grouping vs full reorganization
  • 🔒 Secure API Storage - Encrypted storage with fallback options
  • 🎯 One-Click Operation - Simple interface with dynamic progress feedback

Installation & Setup

1. Install Extension

  1. Open Chrome and navigate to chrome://extensions/
  2. Enable "Developer mode" in the top right corner
  3. Click "Load unpacked" button
  4. Select the extension folder containing these files
  5. The extension should now appear in your extensions list

2. Configure API Key

  1. Click the extension icon in your toolbar
  2. Click "Settings" to open the options page
  3. Enter your Claude API key from Anthropic Console
  4. Click "Save" and optionally test the connection

🚀 Usage

Smart Grouping (Recommended)

  1. Open multiple tabs in Chrome
  2. Click the AI Tab Grouper extension icon
  3. Click "Smart Group" - only processes new tabs, preserves existing groups
  4. Watch live diagnostics as tabs are analyzed and organized
  5. Use ⏹️ Stop button if you need to cancel processing

Full Regrouping

  1. Click "Regroup All" for complete reorganization of all tabs
  2. Existing groups will be dissolved and recreated
  3. Monitor progress with real-time updates

🧠 How It Works

Simplified Two-Step Process

Step 1: Content Analysis

For every tab in parallel batches of 10:

  • Extract comprehensive context: tab title, URL, meta descriptions, article content, and page headings
  • Multiple extraction strategies: meta tags → article content → headings → URL analysis
  • Send enriched tab information to Claude 3.5 Haiku for accurate content summarization
  • Build enriched tab data with AI-generated summaries

Step 2: Intelligent Grouping

Single Claude call with all tab data (titles, URLs, summaries):

  • Apply tool-based grouping priority for recognized platforms
  • Group articles/tutorials by topic using full context and summaries
  • Create logical categories with descriptive names

Supported Tool Categories

Claude recognizes and prioritizes grouping for:

  • Development: GitHub, GitLab, Jira, Confluence
  • Cloud Platforms: AWS, Azure, Salesforce, Snowflake
  • AI/ML: OpenAI, Claude, Google Gemini
  • Productivity: Slack, Teams, Zoom, Notion, Figma
  • Google Workspace: Docs, Sheets, Slides, Drive
  • Project Management: Linear, Asana, Trello, Monday.com

Live Progress Tracking

Watch the analysis happen in real-time:

  • See each tab being analyzed with progress counter
  • View AI-generated summaries for each tab
  • Track grouping decisions and final results
  • State Persistence: Close and reopen the popup anytime - your progress is saved
  • Stop Processing: Use the red ⏹️ button to cancel operations at any time
  • Real-time diagnostics show exactly what's happening during long operations

🔧 Technical Details

Supported Tools & Platforms

  • Development: GitHub, GitLab, Jira, Confluence
  • Cloud Platforms: AWS, Azure, Salesforce, Snowflake
  • AI/ML: OpenAI, Claude, Google Gemini
  • Productivity: Slack, Teams, Zoom, Notion, Figma
  • Google Workspace: Docs, Sheets, Slides, Drive
  • Project Management: Linear, Asana, Trello, Monday.com

File Structure

  • manifest.json - Extension configuration and permissions
  • background.js - Enhanced service worker with tool detection and context extraction
  • popup.html/js - Smart popup interface with dynamic tab counts
  • options.html/js - Secure API key management with connection testing
  • CLAUDE.md - Developer documentation for Claude Code

Build & Package

npm run build    # Creates distributable ZIP
npm run zip      # Same as build
npm test         # Shows manual testing instructions

🛡️ Privacy & Security

Data Handling

  • Two-Phase API Usage: Individual summaries + single grouping call
  • Tab Analysis: Every tab's title, URL, and page content analyzed uniformly
  • API Key Storage: Secure Chrome storage with encrypted fallback
  • Content Extraction: Tab titles, URLs, meta descriptions, article content, and page headings
  • State Persistence: Progress data temporarily stored locally, cleared on completion
  • No Hardcoded Secrets: All credentials require user configuration
  • No Tracking: Extension doesn't collect or store user data

Permissions Required

  • tabs - Read tab information (title, URL)
  • tabGroups - Create and manage tab groups
  • activeTab - Access to current tab
  • storage - Secure API key storage
  • scripting - Content extraction for enhanced categorization
  • https://*/* - API calls to Anthropic and web scraping

🚨 Troubleshooting

Common Issues

  • API Key Errors: Verify key format starts with sk-ant-
  • Grouping Fails: Check browser console and internet connection
  • Large Tab Sets: 50+ tabs may take longer to process
  • Content Script Errors: Some sites block scraping (graceful fallback enabled)

Performance Tips

  • Use "Smart Group" for better performance on large tab sets
  • Parallel Processing: 10 tabs analyzed simultaneously for faster processing
  • Watch the live diagnostics to see batch analysis progress
  • All tabs get analyzed uniformly - no artificial limits
  • Close unnecessary tabs before grouping for faster processing

📋 Development

See CLAUDE.md for detailed developer documentation and architecture overview.

Testing API Connection

# Set environment variable and test API connection
CLAUDE_API_KEY=sk-ant-... node test-api.js

Security Notes

  • No hardcoded API keys in source code
  • Test files require environment variables
  • All credentials managed through secure Chrome storage

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published