Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Code2PR: PR Description GeneratorNew to Visual Studio Code? Get it now.
Code2PR: PR Description Generator

Code2PR: PR Description Generator

kr

|
4 installs
| (0) | Free
AI-powered PR description generator for local Git changes.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Code2PR: AI-Powered Pull Request Description Generator

🚀 Overview

Code2PR is a VS Code extension that automatically generates comprehensive Pull Request descriptions by analyzing your Git changes using AI. Save time and improve code review quality with intelligent, detailed PR descriptions that help reviewers understand your changes instantly.

✨ Key Features

  • 🤖 AI-Powered Analysis: Automatically analyzes your code changes and generates detailed descriptions
  • 📊 Comprehensive Summaries: Creates organized, professional PR descriptions with proper categorization
  • ⚡ Fast Processing: Supports GPU acceleration for faster analysis (optional)
  • 📝 Markdown Format: Outputs clean, formatted descriptions ready for GitHub, GitLab, or Bitbucket
  • 🎯 Smart Categorization: Automatically groups and organizes changes by file type and purpose
  • 🔍 Change Detection: Identifies new features, bug fixes, refactoring, and breaking changes
  • ✅ Review Checklist: Includes helpful review checklists for thorough code reviews

🎯 Benefits

  • Save Time: Generate PR descriptions in seconds instead of writing them manually
  • Improve Quality: Ensure consistent, detailed documentation for every PR
  • Better Reviews: Help reviewers understand changes quickly and thoroughly
  • Track Impact: Automatically identify breaking changes and migration requirements
  • Professional Output: Create well-structured descriptions that follow best practices

📋 Requirements

  • VS Code: Version 1.102.0 or higher
  • Python: 3.8 or higher (must be installed on your system)
  • Git: Must be installed and repository initialized
  • Internet Connection: Required for initial setup and AI model download

Optional

  • NVIDIA GPU: For faster processing (automatically detected)

🛠️ Installation

From VS Code Marketplace (Recommended)

  1. Open VS Code
  2. Go to Extensions (Ctrl+Shift+X or Cmd+Shift+X on Mac)
  3. Search for "Code2PR"
  4. Click Install
  5. Reload VS Code when prompted

First-Time Setup

When you first use the extension, it will automatically:

  1. Create a Python virtual environment
  2. Download required AI models and dependencies
  3. Configure your system for optimal performance

This one-time setup may take 5-10 minutes depending on your internet speed.

🎮 How to Use

Generate a PR Description

  1. Make Your Changes: Edit your code and save the files
  2. Stage/Commit (Optional): You can stage or commit your changes, or just save them
  3. Generate Description:
    • Open Command Palette (Ctrl+Shift+P or Cmd+Shift+P on Mac)
    • Type "Generate PR Description"
    • Select Code2PR: Generate PR Description
  4. Wait for Analysis: A progress notification will show while analyzing
  5. Review Output: A new Markdown document will open with your PR description
  6. Copy to PR: Copy the generated description to your Pull Request

What Gets Analyzed?

  • All modified, added, and deleted files in your Git repository
  • Code structure and architectural changes
  • Potential impacts and breaking changes
  • File categorization and grouping
  • Change statistics and summaries

⚙️ Configuration

Access settings: File → Preferences → Settings → Search for "Code2PR"

Available Settings

  • Force GPU Usage: Enable this if you have a GPU but it's not automatically detected
    • Default: false
    • Set to true to force GPU acceleration

📖 Understanding the Output

The generated PR description includes:

1. Executive Summary

  • Total files modified
  • Lines added/removed
  • High-level overview of changes

2. File Categories

Your changes are organized into:

  • 📦 Package & Configuration
  • 🐍 Python Code
  • 🌐 JavaScript/TypeScript
  • 📚 Documentation
  • 🧪 Tests
  • ⚙️ Configuration Files
  • 🔨 Build & Deploy Scripts

3. Detailed Analysis

For each file:

  • Change type (New, Modified, Deleted)
  • Impact level (Low, Medium, High)
  • Summary of changes
  • Technical context
  • Potential impacts

4. Review Checklist

A comprehensive checklist covering:

  • Code quality
  • Functionality
  • Performance
  • Security
  • Testing
  • Documentation

🔧 Troubleshooting

Extension Not Working?

  1. Check Python Installation

    • Open terminal and run: python --version (Windows) or python3 --version (Mac/Linux)
    • Should show Python 3.8 or higher
  2. Verify Git Repository

    • Ensure you're in a Git repository
    • Check for .git folder in your workspace
  3. View Logs

    • Go to View → Output
    • Select "Code2PR" from dropdown
    • Check for error messages

Common Issues

"No workspace folder found"

  • Open a folder in VS Code (File → Open Folder)

"Python not found"

  • Install Python from python.org
  • Restart VS Code after installation

"No changes found"

  • Make sure you have saved your file changes
  • Verify you have uncommitted changes: git status

Slow Performance

  • First run downloads AI models (one-time)
  • Consider enabling GPU support if available
  • Close other heavy applications

Reset Extension

If you encounter persistent issues:

  1. Delete the virtual environment folder: .venv in your workspace
  2. Reload VS Code
  3. Run the command again (will recreate environment)

💡 Tips for Best Results

  1. Save All Files: Ensure all your changes are saved before generating
  2. Clear Commits: Works best with focused, related changes
  3. GPU Acceleration: If you have an NVIDIA GPU, the extension will use it automatically
  4. Review Output: Always review and customize the generated description
  5. Add Context: Supplement the generated description with business context when needed

🔒 Privacy & Security

  • Local Processing: All analysis happens locally on your machine
  • No Code Upload: Your code is never sent to external servers
  • Offline Capable: After initial setup, works without internet
  • Secure: Uses official Microsoft AI models

🗺️ What's Next?

Current Version (0.0.1)

  • ✅ Basic PR description generation
  • ✅ AI-powered analysis
  • ✅ File categorization
  • ✅ GPU support

Coming Soon

  • Support for custom templates
  • Multiple language support
  • Integration with GitHub/GitLab APIs
  • Team collaboration features
  • Custom AI models

🏆 Credits

Created by Karthick Raja M
AI/ML Engineer & Full Stack Developer


Enjoy using Code2PR! 🎉

Making code reviews smarter, one PR at a time

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft