copilot-chat.el  by chep

Emacs plugin for interacting with GitHub Copilot

Created 1 year ago
345 stars

Top 80.2% on SourcePulse

GitHubView on GitHub
Project Summary

This Emacs package provides an interface to interact with GitHub Copilot's chat functionality directly within the Emacs editor. It's designed for Emacs users who want to leverage AI-powered code assistance, explanation, and generation without leaving their development environment. The primary benefit is seamless integration with Emacs workflows, allowing for context-aware AI interactions.

How It Works

The package acts as a frontend for the Copilot Chat API, supporting multiple backend implementations (curl for token-by-token streaming or request for full response buffering) and various output formats (org, markdown, shell-maker). It allows users to send code snippets, entire buffers, or selected text as context to Copilot, receiving AI-generated responses directly within Emacs. Features like copilot-chat-add-workspace and copilot-chat-add-buffers enable rich context management for more relevant AI outputs.

Quick Start & Requirements

  • Install: M-x package-install RET copilot-chat RET
  • Prerequisites: GitHub account with Copilot access, Emacs.
  • Configuration: Requires setting up GitHub authentication on first use. Backend and frontend can be configured via copilot-chat-backend and copilot-chat-frontend variables.
  • Docs: MELPA

Highlighted Details

  • Supports gpt-4o model with Copilot-Vision for image input.
  • Integrates with magit for AI-generated commit messages.
  • Offers extensive keybindings and transient menus for all functionalities.
  • Allows adding multiple buffers, workspace files, or specific files as context.
  • Provides dedicated functions for code explanation, review, documentation, fixing, optimization, and test generation.

Maintenance & Community

  • Active development with contributions from multiple users.
  • Open to bug reports and feature suggestions.

Licensing & Compatibility

  • License: MIT.
  • Compatible with commercial and closed-source Emacs configurations.

Limitations & Caveats

The request backend writes the full response only after completion, which can be slow. Proxy support for HTTPS connections is noted as not thoroughly tested and may be missing features.

Health Check
Last Commit

1 week ago

Responsiveness

1 day

Pull Requests (30d)
4
Issues (30d)
3
Star History
9 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.