Skip to content
| Marketplace
Sign in
Visual Studio Code>Snippets>Voice Code Snippet SearchNew to Visual Studio Code? Get it now.
Voice Code Snippet Search

Voice Code Snippet Search

yashkhare05

|
4 installs
| (0) | Free
Voice-activated code snippet search with vetted snippets and pros/cons analysis
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Voice Code Snippet Search - VSCode Extension

A powerful VSCode extension that allows developers to search for code snippets using voice commands. Get vetted code snippets with pros/cons analysis instantly.

Features

  • 🎤 Voice-Activated Search: Use voice commands to search for code snippets
  • 🔍 Intelligent Search: Advanced search with keyword matching and relevance ranking
  • 🛡️ Security Analysis: Snippets are annotated with security levels and potential issues
  • ⚖️ Pros & Cons: Each snippet includes detailed analysis of advantages and disadvantages
  • 📝 Multiple Sources: Aggregates snippets from StackOverflow, GitHub Gists, and curated repositories
  • 🚀 Quick Insertion: Insert snippets directly into your code with one click
  • 🎯 Language Filtering: Filter results by programming language
  • 📊 Popularity Ranking: Snippets ranked by community upvotes and usage

Installation

From VSCode Marketplace (Coming Soon)

  1. Open VSCode
  2. Go to Extensions (Ctrl+Shift+X)
  3. Search for "Voice Code Snippet Search"
  4. Click Install

Manual Installation

  1. Clone this repository
  2. Run npm install to install dependencies
  3. Run npm run compile to build the extension
  4. Press F5 to open a new Extension Development Host window

Backend Setup

The extension requires a backend service for snippet search and indexing.

  1. Navigate to the backend directory:

    cd backend
    npm install
    
  2. Copy the environment file and configure:

    cp .env.example .env
    # Edit .env with your configuration
    
  3. Start the backend service:

    npm run dev
    

The backend will run on http://localhost:3001 by default.

Usage

Voice Search

  1. Use the keyboard shortcut Ctrl+Shift+V (or Cmd+Shift+V on Mac)
  2. Speak your search query (e.g., "JWT authentication Node.js")
  3. Browse the results in the sidebar
  4. Click "Insert Code" to add the snippet to your current file

Text Search

  1. Open the Voice Snippets panel from the Activity Bar
  2. Type your search query in the search box
  3. Press Enter or click the search button
  4. Browse and insert snippets as needed

Commands

  • Voice Snippets: Start Voice Search - Begin voice-activated search
  • Voice Snippets: Open Panel - Open the snippets panel
  • Voice Snippets: Insert Snippet - Insert a selected snippet

Configuration

Configure the extension through VSCode settings:

{
  "voiceSnippets.backendUrl": "http://localhost:3001",
  "voiceSnippets.language": "en-US",
  "voiceSnippets.maxResults": 5,
  "voiceSnippets.autoInsert": false
}

Tech Stack

Frontend (VSCode Extension)

  • VSCode Extension API: Core extension functionality
  • TypeScript: Type-safe development
  • Webview API: Rich UI components

Backend Service

  • Node.js + Express: RESTful API server
  • Redis: Caching and session storage
  • Elasticsearch: Advanced search capabilities
  • Winston: Structured logging
  • Rate Limiting: API protection

Data Sources

  • GitHub Gists: Community code snippets
  • StackOverflow API: Q&A code examples
  • Curated Repository: Vetted, high-quality snippets

Development

Extension Development

# Install dependencies
npm install

# Compile TypeScript
npm run compile

# Watch for changes
npm run watch

# Run tests
npm test

# Package extension
npm run package

Backend Development

cd backend

# Install dependencies
npm install

# Start development server
npm run dev

# Run tests
npm test

# Build for production
npm run build

Architecture

┌─────────────────┐    ┌─────────────────┐    ┌─────────────────┐
│   VSCode        │    │   Backend       │    │   Data Sources  │
│   Extension     │◄──►│   Service       │◄──►│                 │
│                 │    │                 │    │ • StackOverflow │
│ • Voice Input   │    │ • Search Engine │    │ • GitHub Gists  │
│ • UI Components │    │ • Snippet Index │    │ • Curated Repo  │
│ • Code Insertion│    │ • Security Scan │    │                 │
└─────────────────┘    └─────────────────┘    └─────────────────┘

Roadmap

  • [x] Week 1: Project setup & voice pipeline
  • [x] Week 2: Query parsing & normalization
  • [x] Week 3: Snippet search backend
  • [x] Week 4: Ranking & filtering
  • [x] Week 5: In-IDE display & snippet insertion
  • [ ] Week 6: Voice-driven refinement & follow-up
  • [ ] Week 7: Security & style annotations
  • [ ] Week 8: Polish & beta launch

Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Support

  • 📧 Email: support@voice-snippets.dev
  • 🐛 Issues: GitHub Issues
  • 💬 Discussions: GitHub Discussions
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft