gergap/vim-ollama
Vim plugin for integrating Ollama based LLM (large language models)
What it solves
It provides Copilot-like AI code completion and editing capabilities for the original Vim editor, allowing users to leverage local LLMs via Ollama to maintain privacy and avoid reliance on commercial cloud services.
How it works
The plugin uses Python scripts to communicate with the Ollama REST API (or OpenAI-compatible endpoints like LMStudio and Mistral AI) via I/O redirection. It integrates AI-generated suggestions as "ghost text" in the editor and provides a dedicated conversation buffer for chat and editing tasks. For advanced editing, it includes "OllamaEdit," which can inspect project workspaces, apply changes, and use web search/fetch tools to assist in coding.
Who it’s for
Vim users who want AI-powered coding assistance but prefer to stay within the original Vim (not NeoVim) and prioritize local model execution for privacy.
Highlights
- Local-first AI: Uses Ollama as the primary backend for private, local code completion.
- OllamaEdit: A tool-based workflow for AI-assisted code editing, including project workspace inspection and automatic compiler diagnostic fixes via
:OllamaQuickFix. - Flexible Backends: Supports Ollama, OpenAI-compatible endpoints, and Mistral AI.
- Privacy-focused: Integrates with the UNIX password manager (
pass) to securely handle API keys. - Thinking Model Support: Displays reasoning output from thinking models in foldable sections.
Related
- Project
- Project
- Project
- Project
- Project