r/vim • u/MokoshHydro • 4d ago
Need Help Autocompletion plugin (codevium replacement)
Past two years I was happy user of windsurf.vim plugin for autocompletion. Few days ago it stopped working.
What is recommended replacement? I've tried llama.vim, but it is much worse and doesn't support LSP/RAG so suggestions are very limited.
I don't need any advanced AI functionality, just code autocomplete.
P.S. I'm using MacVim, but if some plugin require NVim will consider switching.
P.P.S. It will be nice if guys behind codeium/windsurf/whatever consider open-sourcing their infrastructure for autocompletion if it has no business value for them.
2
u/RewardOwn4479 4d ago
https://github.com/guzmandrade-dev/ollama-fim.vim (I’m the author) started with local Ollama models but also supports OpenAI API endpoints. I have tested with local models but also cloud models using together ai and Mistral Codestral. For Vim (not neovim) You should take a look at the Copilot Vim plugin as well, the free version is very good. For a neovim-only alternative, supermaven is also good
1
u/JetSetIlly 3d ago
Does this work with llama.cpp too?
2
u/RewardOwn4479 3d ago
It should, by using an OpenAI API endpoint. You would need a local model (like codestral, qwen coder, and others) that supports fill in the middle (FIM). I tried to support as many prompt variables as possible (check the README).
1
u/reddotr 4h ago
Thanks for sharing your work! Does your plugin support partial accepts (only one word, only one line) and cycling thru completion variants. Or do you have plans to implement it?
2
u/RewardOwn4479 1h ago
Different suggestions, yes, you can request a new completion. Partial accepts, no, I had some issues when testing with different models, and the best I could do was accept until the end of a statement with some heuristics (looking for new lines, semicolons, etc.), but it could be a good addition. I simply focused on having a functional version.
1
u/TheGratitudeBot 4h ago
Thanks for such a wonderful reply! TheGratitudeBot has been reading millions of comments in the past few weeks, and you’ve just made the list of some of the most grateful redditors this week!
1
u/AutoModerator 4d ago
Please remember to update the post flair to Need Help|Solved when you got the answer you were looking for.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
5
u/Aborres 4d ago
If vim9 is an option for you, I have been pretty happy with https://github.com/yegappan/lsp
I use it professionally with huge c++ codebases, hlsl, python and rust projects and it has been great.