deoplete-tabnine
deoplete-tabnine copied to clipboard
Default rank is to high
self.rank = 1000
is listed in the examples:
class Source(Base):
def __init__(self, vim):
super().__init__(vim)
self.name = 'async'
self.mark = '[async]'
self.rank = 1000
self._count = 0
That is what is used for this plugin. However, the default is 100:
*deoplete-source-attribute-rank*
rank (Integer) (Optional)
Source priority. Higher values imply higher priority.
Note: It is high priority than match position.
Default: 100
This puts tabnine above everything else. You can override this with:
call deoplete#custom#source('tabnine', 'rank', 50)
However, it would probably be preferable to use the default sort, as having tabnine above everything else, especially as it creates a lot of suggestions, can get cumbersome.
I set the rank that high because it got annoying to be all the way below the LanguageClient suggestions. I'm open to discussion about what the "right" default rank would be.
That makes sense, and like I mentioned, it's customizable. I found that having 8-10 tabnine suggestions above my ternJS ones was unusable. Maybe all you need is a helpfile that mentions how to customize the sort?
when i use deoplete-jedi
for python deoplete-go
for go, the completion is much better than tabnine
I also stumbled onto this problem here, though I'm actually not sure about the solution.
Especially in combination with the quite good deoplete-jedi
I would want to see both.
Documentation on customization here could definitely help.
What I'll try and feels right is
- a lower rank for
tabnine
(playing around with that one) - tweak
max_candidates
for each source and globally (see https://github.com/Shougo/deoplete.nvim/issues/731)
Perhaps a lower rank
I guess there is still no solution? Which Vim client are you using for Tabnine in 2023? (although deoplete-tabnine really works great!)
You can use ddc.vim instead.
https://github.com/LumaKernel/ddc-tabnine
Cmp-tabnine