Enables OpenAI models to interact with Emacs through the MCP server, as indicated by the OPENAI_API_KEY requirement in the configuration.
Emacs MCP Server
Model Context Protocol (MCP) server for Emacs. Enables generating and running elisp code in a running Emacs process.
Tools
The server exposes two tools:
generate_emacs_lisp_code: generates elisp for a given taskexecute_emacs_lisp_code: passes elisp to a running Emacs (viaemacsclient) to eval and execute it.
Related MCP server: MCP Toolkit
Invocation
The project is managed with uv. First, run uv sync to install all dependencies. Then source .venv/bin/activate to activate the resulting venv.
To run the MCP server in the inspector:
To install the MCP server so that Claude Desktop can use it:
But you will have to edit the resulting JSON config in claude_desktop_config.json to include API keys and the full path to emacsclient. It should look something like this: