AutoPilot AI Searchbar is a powerful Visual Studio Code extension that integrates OpenAI's GPT models into your coding environment. It provides an intuitive chat interface and context-aware code actions to enhance your development workflow. With features like code explanation, refactoring, and docum
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Autopilot AI Searchbar is a powerful Visual Studio Code extension that integrates OpenAI's GPT models into your coding environment. It provides an intuitive chat interface to enhance your development workflow. With features like code explanation, refactoring, and documentation, it’s designed to streamline your coding experience directly within VSCode.
🚀 Features
💬 Interactive Sidebar Chat:
Ask coding questions or get assistance directly from the sidebar.
Supports multi-turn conversations with chat history.
🖱️ Right-Click Code Actions:
💡 Explain Selection: Get detailed explanations of selected code.
🔧 Refactor Code: Automatically refactor selected code for improved readability and performance.
📃 Document Selection: Generate professional documentation for your code, including summaries, inline comments, and docstrings.
🧠 Powered by OpenAI:
Leverages gpt-4 for intelligent code analysis and generation.
🖼️ Responsive UI:
Clean, modern chat interface with support for code blocks .
Displays typing indicators for a smooth user experience.
🔒 Secure Storage:
Stores sensitive data like session tokens and API keys securely in VSCode’s global state.
🛠️ Installation
Install the extension from the VSCode Marketplace(or sideload the .vsix file for local testing).
Upon activation, the Autopilot AI Searchbar panel will appear in the sidebar.
Complete the setup by providing:
✉️ Email Address: For user identification.
🔑 API Key: Your OpenAI API key.
Click Submit to authenticate and start using the extension.
💡 Usage
🗨️ Sidebar Chat
Open the Autopilot AI Searchbar view from the VSCode sidebar.
Type your coding question or prompt in the input box.
Receive responses with formatted code blocks.
🖱️ Right-Click Code Actions
Select a block of code in any editor.
Right-click and choose one of the following:
💡 Explain Selection: Get a detailed breakdown of what the selected code does.
🔧 Refactor Code: Request AI-driven refactoring suggestions for cleaner, more efficient code.
📃 Document Selection: Generate comprehensive documentation, including high-level summaries, inline comments, and docstrings.
🔑 Logout
Use the autopilot-searchbar.logout command to clear your session and log out securely.
🧩 Settings
Setting
Description
chatgptEmail
Stores the user’s email address.
chatgptApiKey
Stores the OpenAI API key securely.
🛠 Supported Models
gpt-4(default model for all AI interactions)
🧑💻 Contributing
Interested in contributing? Feel free to:
Open an issue to report bugs or suggest features.
Fork the repository and submit a pull request with your improvements.