Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Private Code AssistantNew to Visual Studio Code? Get it now.
Private Code Assistant

Private Code Assistant

private-code-assistant

|
34 installs
| (1) | Free
Your private AI code assistant powered by Watsonx and Gemini
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Private Code Assistant

This is a Visual Studio Code extension that acts as a private, context-aware AI programming assistant. It helps you understand, improve, and write code directly within your editor, powered by IBM Watsonx and Google Gemini.

This extension features a lightweight, on-device project indexer to provide relevant, in-project context to its suggestions, ensuring your code remains private and its recommendations are highly specific to your project.


Key Features

  • Context-Aware Inline Completion: As you type, the assistant provides "ghost text" suggestions directly in your editor. This feature is powered by a RAG (Retrieval-Augmented Generation) system that uses your local project index to find relevant code, function definitions, and comments, providing highly accurate and contextual completions.
  • Chat-Based Programming: Use the chat interface to ask programming questions, debug issues, and iterate on code. The AI has access to your conversation history (for follow-up questions) and can incorporate code snippets you provide.
  • Figma-to-Code: Automatically generate front-end components from a Figma design URL. This feature parses the Figma design and uses a multimodal AI (Gemini) to generate component and style files for React/Vue, using UI libraries like Ant Design or Vuetify.
  • Command-Based Code Generation: Select a comment, instruction, or a stub function in your editor, right-click, and choose "Auto complete" to have the AI generate the full implementation for you.
  • Configurable AI Behavior:
    • Deep Thinking: Toggle the "Deep Thinking" switch in the chat panel to use a more powerful (but slower) AI model for complex questions.
    • Completion Frequency: Choose between "High Frequency" (more aggressive, beginner-friendly) and "Low Frequency" (more selective, expert-friendly) modes for inline code suggestions.
  • Code Analysis & Reports:
    • Code Explanation: Select any piece of code and choose "Explain This Code" from the right-click menu.
    • Robustness Report: Select a function and choose "Generate Test Report" to get a Markdown report identifying edge cases and potential bugs.
    • Log Analysis: Right-click a .log file in the explorer and select "Analyze Log" to get a root cause analysis and recommended actions.

Quick Start

  1. Install the Extension: Install from the VS Code Marketplace.
  2. Configure API Keys:
    • Click the extension icon in the activity bar.
    • In the chat view, click the gear icon (⚙️) in the top-right corner to open settings.
    • For Gemini features: Enter your Google AI Studio API Key in the "Gemini API Key" field.
    • For Figma-to-Code: Enter your Figma Personal Access Token.
    • For Watsonx features: Enter your IBM Cloud API Key and Watsonx Project ID.
    • Click "Save".
  3. Build Project Index:
    • The first time you open a project, the extension will automatically begin indexing your code in the background (you can see progress in the status bar).
    • Optional: Open the VS Code Command Palette (Ctrl+Shift+P) and run "Build Project Index for AI" to manually trigger a full re-index.

How to Use

  • Inline Completion: Simply start typing in a supported file (.js, .py, .vue, etc.). The AI will automatically provide suggestions as "ghost text". Press Tab to accept.
  • Chat Panel: Open the "Private AI Assistant" icon in the activity bar. Type a question, toggle "Deep Thinking" for complex tasks, and use the "Apply to File" button on code blocks to send code to your active editor.
  • Context Menu: Right-click on selected code in your editor to access commands like "Explain This Code", "Generate Test Report", and "Auto complete".

Project Indexing

This extension's powerful inline completion comes from its on-device project indexer.

  • Automatic: The indexer runs automatically when you open a project and updates (silently) in the background when you save, create, or delete files.
  • Manual Control: You can use the Command Palette (Ctrl+Shift+P) for manual control:
    • Build Project Index for AI: Forces a complete rebuild of the project index.
    • Show AI Index Statistics: Displays a simple message with the number of files and code chunks currently in the index.
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft