Skip to content

Mark-Phillipson/TalonCommandSearchExtension

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

55 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ” Search Talon Commands - VS Code Extension

๐ŸŽฏ Search and browse 27,000+ Talon Voice commands and lists with lightning-fast performance, advanced filtering, and dedicated list search capabilities.

โš ๏ธ AI Disclosure: This extension was developed with assistance from AI tools (GitHub Copilot and Claude AI). While thoroughly tested and functional, users should be aware that AI-generated code was used in its creation. Please report any issues or concerns through the project's issue tracker.

๐Ÿ”’ File Access Policy: This extension only reads your Talon files (.talon, .talon-list, .py). It never writes to, modifies, or deletes any of your Talon Voice files or Python scripts. All file access is read-only for indexing and search purposes only.

Talon Command Search Screenshot

โœจ Features

  • โšก Lightning Fast JSON Storage: Handles massive datasets (27k+ commands) with optimized in-memory search
  • ๐Ÿ”Ž Intelligent Search: Instant search across commands, scripts, applications, and metadata
  • ๐Ÿ“‘ Dedicated List Search: Brand new tabbed interface with dedicated Talon list (.talon-list) search
    • ๐ŸŽฏ Separate "Commands" and "Lists" tabs for focused searching
    • ๐Ÿ“Š Search across list names, spoken forms, values, and source files
    • ๐ŸŽช Grouped results by list name for better organization
    • ๐Ÿ“ Table format showing spoken form โ†’ list value mappings
    • ๐Ÿ” Collapsible available lists section with click-to-filter functionality
  • ๐ŸŽ›๏ธ Advanced Filtering: Filter by application, mode, repository with real-time results
  • ๐Ÿ“Š Repository Breakdown: See command distribution across your repositories (community, personal, etc.)
  • ๐ŸŽฏ Multiple Search Scopes:
    • ๐ŸŽช Command Names Only (spoken phrase matches only)
    • ๐Ÿ“ Scripts Only (code content search)
    • ๐ŸŒ All (comprehensive search across everything + list matching)
  • ๐Ÿง  Intelligent List Matching: Search by list values to find commands that use them
    • ๐Ÿ” Search "left" โ†’ finds game <user.arrow_key> (because "left" is in the arrow_key list)
    • ๐ŸŽญ Search "happy" โ†’ finds insert <user.emoji> (because "happy" is in the emoji list)
    • ๐Ÿ”— Automatically maps command placeholders to actual Talon lists
    • โœจ Works with complex list naming structures and repository paths
  • ๐Ÿค– Auto-Detection: Automatically finds your Talon user folder on Windows/Mac/Linux
  • ๐Ÿ“‚ File Integration: Click any result to open source .talon or .talon-list files instantly
  • โŒจ๏ธ Keyboard Shortcuts: Ctrl+Shift+T (Windows/Linux) or Cmd+Shift+T (Mac)
  • ๐Ÿ“ˆ Real-time Stats: Live command count, list count, and repository statistics
  • ๐Ÿ”ง Folder Management: Set custom Talon user folder paths and import from any directory
  • ๐Ÿ› ๏ธ Database Tools: Built-in database management with clear/check functionality

๐Ÿ—๏ธ Architecture & Performance

๐Ÿ’พ Database: Optimized JSON storage with in-memory processing

  • ๐Ÿš€ Lightning-fast search through 27k+ commands
  • ๐Ÿ’ผ Stored in extension global storage (workspace-independent)
  • ๐Ÿ” Intelligent filtering without database complexity
  • ๐Ÿ“Š Real-time repository breakdown and statistics
  • โœ… Proven to handle massive Talon command datasets

๐Ÿ”„ Migration Journey:

  • โŒ SQLite Issues: Native module compilation problems on Windows
  • โŒ IndexedDB: Too slow for large datasets (cursor-based iteration)
  • โœ… JSON + In-Memory: Perfect balance of speed, simplicity, and reliability

๐Ÿง  How List Matching Works

The Intelligent List Matching feature revolutionizes command discovery by letting you search for the values that commands accept, not just their names.

โœจ Examples

Search Term Finds Commands Why?
"left" game <user.arrow_key> "left" exists in the arrow_key list
"chrome" focus <user.running_applications> "chrome" is in the applications list
"happy" insert <user.emoji> "happy" is an emoji in the emoji list
"enter" press <user.keys> "enter" is in the keys list

๐Ÿ”ง Technical Details

  1. ๐Ÿ” Placeholder Detection: Finds placeholders like <user.arrow_key> and {user.emoji} in commands
  2. ๐Ÿ—บ๏ธ Smart Mapping: Maps simplified names (user.arrow_key) to full database paths (user.community/core/keys/arrow_key)
  3. ๐Ÿ“Š List Lookup: Searches through actual Talon list files (.talon-list) for matching values
  4. โœ… Match Return: Returns the command as a match if your search term exists in any referenced list

๐ŸŽฏ Search Scopes That Support List Matching

  • Command Names Only: โŒ List matching disabled (spoken phrases only)
  • Scripts Only: โŒ No list matching (searches code content only)
  • All: โœ… Includes list matching + everything else

This feature makes it incredibly easy to discover commands when you know what you want to do but don't know the exact command name!

๏ฟฝ Dedicated List Search

The extension now includes a complete List Search interface for browsing and searching through your Talon list files (.talon-list).

โœจ Key Features

  • ๐Ÿ“‘ Separate Tab: Dedicated "Lists" tab alongside "Commands" for focused searching
  • ๐Ÿ” Multi-field Search: Search across list names, spoken forms, values, and source files
  • ๐ŸŽช Organized Results: Results grouped by list name (e.g., user.emoji, user.keys) for better navigation
  • ๐Ÿ“ Clean Display: Table format showing "spoken form โ†’ list value" mappings
  • ๐ŸŽฏ Click-to-Filter: Click any available list name to filter results to that specific list
  • ๐Ÿ“‹ Collapsible Interface: Space-saving design with expandable available lists section
  • ๐Ÿ“‚ File Integration: Click source file names to open .talon-list files directly

๐ŸŽฏ How to Use List Search

  1. Open Search: Use Ctrl+Shift+T or "Talon: Search Commands"
  2. Switch to Lists: Click the "Lists" tab in the interface
  3. Search Lists: Type in the search box to find specific list items
  4. Filter by List: Click any list name in the "Available Lists" section to filter
  5. Open Files: Click source file names to edit your .talon-list files

๐Ÿ“Š Example Use Cases

  • Find Emoji: Search "happy" to see all happy-related emojis in your emoji lists
  • Browse Keys: Click "user.keys" to see all available key mappings
  • Check Snippets: Search "print" to find all print-related code snippets
  • Verify Lists: Quickly verify what values are available in specific lists

๏ฟฝ๐Ÿš€ Quick Start

  1. ๐Ÿ“ฆ Install the extension
  2. ๐ŸŽฏ Open Command Palette (Ctrl+Shift+P / Cmd+Shift+P)
  3. ๐Ÿ”„ Run: Talon: Refresh Index (first time only - imports your commands and lists)
  4. ๐Ÿ” Search: Talon: Search Commands or use Ctrl+Shift+T
  5. ๐Ÿ“Š Enjoy: See your command breakdown and start searching instantly!
  6. ๐Ÿ“‘ Try List Search: Click the "Lists" tab to search through your Talon list files
  7. ๐Ÿง  Try List Matching: Search for values like "left", "chrome", or "happy" to see the magic!

โš™๏ธ Configuration

{
  "talonSearch.userFolderPath": "",           // ๐Ÿ“ Leave empty for auto-detection
  "talonSearch.enableAutoIndexing": true,     // ๐Ÿ”„ Auto-import on startup  
  "talonSearch.maxSearchResults": 500,        // ๐Ÿ“Š Max results per search
  "talonSearch.searchDebounceMs": 3000        // โฑ๏ธ Search delay in milliseconds (0-30000)
}

๐Ÿ”ง Configuration Details

  • User Folder Path: Auto-detects standard Talon locations:
    • Windows: %APPDATA%\talon\user
    • Mac: ~/.talon/user
    • Linux: ~/.talon/user
  • Auto Indexing: Automatically imports commands on VS Code startup
  • Max Results: Prevents UI slowdown with large result sets (default: 500)
  • Search Debounce: Configurable delay before performing search (default: 3000ms)
    • โฑ๏ธ Prevents searches on every keystroke for better performance
    • ๐ŸŽฏ Adjustable from 0ms (instant) to 30 seconds via VS Code settings
    • ๐ŸŽจ Visual feedback with orange pending indicator and countdown
    • ๐Ÿ’ก Recommended: 1000-3000ms for optimal user experience
    • ๐Ÿš€ Includes race condition prevention for smooth search experience

๐Ÿ‘จโ€๐Ÿ’ป Development

# ๐Ÿ“ฆ Install dependencies
npm install

# ๐Ÿ”จ Compile TypeScript
npm run compile

# ๐Ÿ‘€ Watch mode for development
npm run watch

# ๐Ÿš€ Run extension (press F5 in VS Code)

๐Ÿ›๏ธ Technical Architecture

  • ๐ŸŽฏ Extension Host (src/extension.ts): VS Code integration, command registration, file scanning
  • ๐Ÿ’พ Database Manager (src/database/dataManager.ts): JSON storage, in-memory search, repository breakdown
  • ๐Ÿ“ Parser (src/parser/talonFileParser.ts): Advanced Talon file parsing (headers, commands, scripts)
  • ๐Ÿ–ฅ๏ธ Webview UI (webview/): Modern search interface with real-time filtering and stats
  • ๐Ÿ“Š Data Models (src/types.ts): TypeScript interfaces ensuring type safety
  • ๐ŸŽจ Modern UI (webview/styles.css): CSS Grid responsive layout with VS Code theming

๐Ÿ”„ Evolution: Started with SQLite โ†’ Tried IndexedDB โ†’ Perfected with JSON + In-Memory for optimal performance!

๐Ÿ—๏ธ Key Technical Improvements

  • Smart Focus Management: Automatic focus handling for optimal voice user experience
  • Configurable Search Debounce: Performance-tuned search delays with visual feedback system
  • Advanced Filtering Architecture: Multi-dimensional filtering (tags, OS, repos) with persistent state
  • Responsive Design: CSS Grid automatically adapts to screen size (3/2/1 columns)
  • In-Memory Search: All filtering and search operations run in memory for instant results
  • Repository Intelligence: Smart path parsing extracts repository info from file paths
  • Additive Imports: Support both full refresh and incremental folder imports
  • Database Isolation: Commands stored in extension global storage, workspace-independent

๐Ÿ†• Recent Updates (Latest)

๐ŸŽฏ Enhanced User Experience (NEW!)

  • โŒจ๏ธ Smart Focus Management: Automatic focus on search inputs when switching between Commands and Lists tabs
  • ๐ŸŽจ Improved Tab Navigation: Seamless switching with immediate focus for voice users
  • ๐Ÿš€ Enhanced Search Performance: Intelligent search triggers only when tab switching with available data
  • ๐Ÿ“ฑ Touch-Friendly Interface: Better click targets and responsive design elements
  • ๐ŸŽญ Voice-Optimized UX: Minimal navigation required for efficient voice command usage

๐Ÿ›’ Marketplace Discoverability (NEW!)

  • ๐ŸŽฏ Targeted Categories: Published under Programming Languages, Snippets, and Other to help the right users find the extension faster
  • ๐Ÿงน Clean Console Output: Removed development-only console.log statements to keep logs focused on actionable information during troubleshooting

โฑ๏ธ Configurable Search Debounce (NEW!)

  • ๐ŸŽฏ Smart Search Timing: Configurable delay prevents searches on every keystroke
  • โš™๏ธ Fully Customizable: Adjust delay from 0ms (instant) to 30 seconds via VS Code settings
  • ๐ŸŽจ Visual Feedback: Orange pending indicator shows search will start with countdown
  • ๐Ÿš€ Performance Optimized: Reduces server load while maintaining responsive feel
  • ๐Ÿ’ก Smart Defaults: 3-second default delay balances performance and usability

๐Ÿ” Advanced Filtering System (NEW!)

  • ๐Ÿท๏ธ Tags Filter: Filter commands by tags for better organization
  • ๐Ÿ’ป Operating System Filter: Filter commands by OS (Windows, Mac, Linux)
  • ๐Ÿ“Š Enhanced Repository Stats: More detailed breakdown with visual indicators
  • ๐ŸŽฏ Smart Filter Combinations: Multiple filters work together for precise results
  • ๐Ÿ”„ Persistent Filter State: Filters maintain state across searches

๐Ÿ“‘ Revolutionary Talon List Search (NEW!)

  • ๐ŸŽฏ Dedicated List Search Tab: Complete separate interface for searching Talon lists (.talon-list files)
  • ๐Ÿ“Š Comprehensive List Parsing: Full support for parsing .talon-list files with spoken_form: list_value format
  • ๐ŸŽช Grouped Results Display: Search results organized by list name for better navigation
  • ๐Ÿ“ Table Format: Clean display showing spoken form โ†’ list value mappings
  • ๐Ÿ” Multi-field Search: Search across list names, spoken forms, values, and source files
  • ๐ŸŽฏ Click-to-Filter: Click any list name to instantly filter results to that specific list
  • ๐Ÿ“‹ Collapsible Lists Section: Space-saving UI with expandable available lists section
  • ๐Ÿง  Voice-Friendly Design: Optimized for voice users with minimal scrolling required

๐Ÿง  Enhanced List Matching Intelligence

  • ๐ŸŽฏ Intelligent List Value Search: Find commands by searching for the values they accept
  • ๐Ÿ” Smart Placeholder Mapping: Automatically maps <user.arrow_key> to actual lists like user.community/core/keys/arrow_key
  • โœจ Enhanced Command Discovery: Search "left" to find all commands that use arrow keys
  • ๐Ÿšซ No False Positives: Only matches actual Talon lists, not code captures
  • ๐Ÿƒโ€โ™‚๏ธ Performance Optimized: Debounced search with race condition prevention
  • ๐Ÿ“Š Scope Awareness: List matching available in the All search scope

๐ŸŽจ Enhanced UI & User Experience

  • ๐Ÿ“‘ Tabbed Interface: Separate "Commands" and "Lists" tabs for focused searching
  • CSS Grid Layout: Modern responsive design with automatic 3-column layout
  • Improved Results Display: Cards now use optimal grid spacing for better readability
  • Interactive Repository Stats: Click on any repository in the breakdown to instantly filter results
  • Visual Filter Feedback: Selected repositories are visually highlighted in the stats
  • ๐Ÿ”„ Stable Results: Fixed issue where search results would sometimes disappear
  • โœ–๏ธ Clear Search Button: Quick search reset functionality for both tabs

๐Ÿ› ๏ธ Database Management Tools

  • Check Database: New toolbar button to inspect database status and location
  • Clear Database: Safe database clearing with confirmation dialogs
  • Better Error Handling: Improved feedback when database isn't initialized
  • ๐Ÿ“Š Enhanced Import Process: Now imports both .talon and .talon-list files in single operation

๐Ÿ“ Flexible Folder Management

  • Set User Folder: New command to configure your Talon user folder path
  • Import from Folder: Import commands from any directory (additive to existing commands)
  • Refresh vs Import: Clear distinction between refreshing (replace all) and importing (add to existing)

๐Ÿ“ฆ Publishing & Distribution

  • Complete Publishing Guide: Step-by-step marketplace publishing documentation
  • VSCE Integration: Ready-to-publish package with proper configuration
  • Professional Documentation: Comprehensive setup and usage instructions

๐Ÿš€ Quick Start

๐ŸŽฎ Available Commands

  • ๐Ÿ” Talon: Search Commands - Open the powerful search panel with Commands and Lists tabs
  • ๐Ÿ”„ Talon: Refresh Index - Re-import all .talon and .talon-list files (with progress indicator)
  • ๐Ÿ“ Talon: Import from Folder - Import commands and lists from a custom folder (additive)
  • โš™๏ธ Talon: Set User Folder Path - Configure your Talon user folder location

๐Ÿ—บ๏ธ Roadmap & Future Features

  • โœ… Repository Breakdown - See command distribution across repositories
  • โœ… Horizontal Stats Layout - Space-efficient command statistics
  • โœ… JSON Storage Migration - Solved native module compilation issues
  • โœ… Real-time Search - Lightning-fast search with 27k+ commands
  • โœ… CSS Grid Layout - Responsive 3-column results layout
  • โœ… Database Management - Built-in tools for clearing and checking database
  • โœ… Folder Management - Custom folder selection and import workflows
  • โœ… Enhanced Filtering - Clickable repository stats and dynamic filtering
  • โœ… Publishing Ready - Complete publishing guide and marketplace preparation
  • โœ… List Parsing & Matching - Full support for Talon list files (.talon-list) with intelligent command matching
  • โœ… Dedicated List Search - Complete tabbed interface with separate list search functionality
  • โœ… Collapsible UI - Space-saving interface optimized for voice users
  • โœ… Click-to-Filter Lists - Interactive list name filtering for focused searching
  • ๐ŸŒณ TreeView - Hierarchical browsing of results
  • ๐Ÿง  Semantic Search - AI-powered command discovery
  • ๐Ÿ‘€ File Watcher - Auto-refresh when .talon files change
  • ๐Ÿ“ˆ Usage Analytics - Track most-used commands
  • ๐Ÿ”— Cross-Reference Search - Show which commands use specific lists
  • โœ๏ธ Inline List Editing - Edit list items directly in the interface

๐ŸŽ‰ What's New in This Version

๐Ÿ†• Random Command Discovery

When you open the search panel, you'll now see a random selection of commands from your database (instead of filtering by a default application). This makes it easier to discover new commands and remember useful ones, even if you don't know what to search for!

The defaultApplications setting has been removed.

If you want to filter by application, simply use the filter dropdown in the search panel.

  • UI Improvement: The repository breakdown ("Commands by Repository") is now displayed above the search box in the Commands tab. This makes it clear that the figures shown are totals for each repository, not filtered results. When you filter or search, the breakdown remains visible for reference.

  • ๐Ÿ—ฃ๏ธ New Default Search Scope: Spoken Forms (Commands + Lists)

    • The search panel now defaults to the "Spoken Forms (Commands + Lists)" filter, making it easier to find both command names and list values instantly.
    • This scope includes intelligent matching for spoken phrases and list values, so searching for terms like "left" or "happy" will find commands that use those list items.
    • You can still switch to other scopes (All, Command Names Only, Scripts Only) using the dropdown next to the search box.
  • ๐ŸŽฏ Enhanced User Experience: Smart focus management with automatic search input focus when switching tabs

  • โฑ๏ธ Configurable Search Debounce: Customizable search delay (0-30s) with visual feedback and performance optimization

  • ๐Ÿ” Advanced Filtering System: New tags and operating system filters with enhanced repository breakdown

  • ๐Ÿ“‘ Revolutionary List Search: Complete tabbed interface with dedicated Talon list search functionality

  • ๐ŸŽฏ Intelligent List Parsing: Full support for .talon-list files with comprehensive search capabilities

  • ๐Ÿ—‚๏ธ Organized Results: Grouped list results by list name with clean table formatting

  • ๐Ÿ” Enhanced Filtering: Click-to-filter list names with collapsible interface design

  • ๐Ÿš€ Performance Revolution: Migrated from SQLite to optimized JSON storage

  • ๐Ÿ“Š Repository Insights: See exactly where your commands come from with clickable stats

  • ๐ŸŽจ Modern UI: CSS Grid layout with responsive 3-column design and tabbed navigation

  • ๐Ÿ› ๏ธ Database Tools: Built-in database management (check/clear with confirmation dialogs)

  • ๐Ÿ“ Flexible Imports: New commands for setting user folder and importing from any directory

  • โšก Zero Dependencies: No more native module compilation issues

  • ๏ฟฝ๏ธ Windows Compatible: Solved all the pesky Node.js version conflicts

  • ๐Ÿ“ˆ Scalable: Tested with 27,000+ commands and thousands of list items!

  • ๐Ÿ—ฃ๏ธ Voice-Optimized: UI designed specifically for voice users with minimal scrolling required

  • ๐Ÿ“ฆ Publishing Ready: Complete marketplace publishing guide included

๏ฟฝ Publishing & Distribution

This extension is ready for VS Code Marketplace publication! A comprehensive publishing guide is included:

  • ๐Ÿ“‹ Complete Setup: Step-by-step Azure DevOps and Personal Access Token configuration
  • ๐Ÿ”ง VSCE Integration: All package.json settings configured for publishing
  • ๐Ÿ“ Documentation: Professional README and marketplace-ready descriptions
  • ๐Ÿš€ One-Command Publishing: vsce publish patch for streamlined releases
  • ๐Ÿ”’ Security Best Practices: Token management and security guidelines included

See PUBLISHING.md for the complete publishing guide.

๐Ÿค Contributing

We welcome contributions! Here's how to get started:

  1. ๐Ÿด Fork the repository
  2. ๐Ÿ”ง Setup: Run npm install and npm run compile
  3. ๐Ÿงช Test: Press F5 to launch extension development host
  4. โœจ Develop: Make your changes and test thoroughly
  5. ๐Ÿ“ค Submit: Create a pull request with your improvements

๏ฟฝ๐Ÿ“ License

MIT - Feel free to contribute and make Talon Voice even better! ๐ŸŽฏ

๐Ÿง‘โ€๐Ÿ’ป Application Header Normalization (NEW)

  • The parser now normalizes any application header containing terminal or windows_terminal to windows_terminal for consistency in filtering and search.
  • Any header containing powershell is normalized to powershell.
  • If you want terminal and windows_terminal to be listed separately, you must adjust the normalization logic in src/parser/talonFileParser.ts.
  • To ensure commands are indexed under the correct application, add explicit app: powershell or app: terminal headers to your Talon files.

About

VS Code extension for searching and browsing Talon voice commands with advanced filtering and JSON file storage

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published