A sophisticated AI coding agent that leverages Emacs' native programmability through direct Elisp evaluation.
Efrit is a conversational AI assistant that integrates seamlessly with Emacs, providing multiple interfaces for different types of tasks:
- efrit-chat - Multi-turn conversational interface for complex discussions and code development
- efrit-do - Natural language command execution for quick tasks
- efrit - Command interface for structured interactions
- efrit-agent-run - Advanced agent loop for multi-step automation
- Direct Elisp Evaluation: Leverages Emacs' native programmability without complex abstractions
- Multi-turn Conversations: Maintains context across multiple exchanges with configurable turn limits
- Tool Integration: Can execute Emacs functions, manipulate buffers, and interact with the environment
- Safety-First Design: Confirmation systems and comprehensive error handling
- Dark Theme Friendly: Adaptive colors that work with any Emacs theme
- Emacs: Version 28.1 or later
- Anthropic API Key: Get yours from Anthropic Console
- Internet Connection: Required for Claude API access
-
Clone the repository:
git clone https://github.com/steveyegge/efrit.git cd efrit -
Add to your Emacs configuration (~/.emacs.d/init.el):
(add-to-list 'load-path "/path/to/efrit") (require 'efrit) -
Configure your API key in ~/.authinfo:
machine api.anthropic.com login personal password YOUR_API_KEY_HERE -
Restart Emacs and test with M-x efrit-chat
Emergency Emacs Setup (for quick testing):
Using straight.el:
- M-x efrit-chat - Multi-turn conversational interface
- M-x efrit-do - Natural language command execution
- M-x efrit - Command interface
- M-x efrit-agent-run - Advanced agent loop
- C-c C-e e - efrit-chat
- C-c C-e d - efrit-do
- C-c C-e c - efrit command interface
- C-c C-e a - efrit-agent-run
Multi-Buffer Creation with efrit-do
Starting with a simple request:
Conversational Context - Making Modifications
efrit-do maintains context, so you can refine previous work:
This demonstrates efrit-do's key feature: conversational continuity. It remembers what it just created and can modify, improve, or completely rewrite previous work based on your feedback.
Conversational Development:
Quick Commands:
Multi-step Tasks:
Efrit follows the principle of Elisp-centricity: rather than building complex tool abstractions, it provides the AI with direct access to Emacs' powerful Elisp evaluation capabilities. This approach offers unlimited flexibility while staying within Emacs' natural paradigm.
- efrit.el - Main entry point and package coordination
- efrit-chat.el - Multi-turn conversational interface with Claude API
- efrit-do.el - Natural language command interface
- efrit-multi-turn.el - Multi-turn conversation state management
- efrit-tools.el - Core functionality engine with Elisp evaluation
- efrit-debug.el - Optional debugging and logging system
- efrit-agent.el - Advanced agent loop for complex automation
"Cannot open load file: efrit"
- Verify the path in your load-path is correct
- Ensure efrit.el exists in that directory
"API key not found"
- Check ~/.authinfo file exists and has correct format
- Test with: M-x auth-source-search RET machine api.anthropic.com RET
Connection timeout
- Check internet connection and API key validity
- Try increasing efrit-api-timeout
Enable debug logging for troubleshooting:
Then check: M-x efrit-debug-show
See CONTRIBUTING.md for detailed guidelines on:
- Development setup
- Code standards and conventions
- Testing procedures
- Submitting changes
v0.2.0 (2025-01-07) - Major Stability Release
- ✅ Fixed API integration issues and HTTP 400 errors
- ✅ Enhanced token limits (1024 → 8192 tokens)
- ✅ Improved message ordering and dark theme compatibility
- ✅ Added multi-turn conversation system with configurable limits
- ✅ Consolidated documentation and cleaned up codebase
- ✅ Production-ready with comprehensive error handling
Licensed under the Apache License, Version 2.0. See LICENSE for details.
Efrit: Where AI meets the power of Emacs.