-
Notifications
You must be signed in to change notification settings - Fork 180
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sublime-LSP Local Code-Assistant Support #2520
Comments
Is your request is to have a LSP-tabby package? Not so related, but have you maybe seen https://github.com/yaroslavyaroslav/OpenAI-sublime-text ? I guess OpenAi package doesn't have ghost text completion items. But it does support having a local model. |
Yes, tabby could be a good target. It looks like they have LSP support https://github.com/TabbyML/tabby/tree/main/clients/example-vscode-lsp
Yes, I have looked at this repository and I think it is neat. But as you said it doesn't offer the ghost text completion, which imho is a huge value-add. |
It seems like the LSP server is implemented via tabby-agent (https://www.npmjs.com/package/tabby-agent) and it is a server (the first one?) with support for This client currently doesn't have support for inline completions ("ghost text completion"), but it would be interesting to see how it could be implemented and how the UI for that could work (but regular So I tried to set up the server on a Windows PC for testing
Maybe I will try again when there is a downloadable server / local model which doesn't require you to sign up for an account. Perhaps at the current time these AI models (still?) require a lot of performance, and therefore it might be expected to setup the server on a separate machine or so (just guessing). If anyone else already has or want to set up this server, feel free to share your experiences and whether it works. As said before, inline completions are not yet supported by this client, but apparently it should/might work with regular completions too. |
Thanks! This is a very useful investigation. |
Update: it seems that running tabby without an authorization token is already supported. The trick is to start tabby with a
After testing this, unfortunately I got a timeout after 30 seconds and a response with no results for the So now I downloaded |
Thanks, I actually was able to get this to run using your setup! But I had to remove
and the generated code is not well formatted yet, there is something off with the output still. I am guessing this is the only completion currently supported? Is ghost text completion the same kind of completion the Codeium plugin uses? |
I intentionally added the "disabled_capabilities" to the config above because the AI/LLM completions are relatively expensive to compute, and the completion popup only appears when the responses from all active language servers are ready. So I think it would be annoying to have a significant delay everytime for the completion popup. For inline completions this could be handled independently and it would not affect the regular completion popup. My initial idea though would be to request inline completions only on demand when you explicitly trigger auto-complete via Ctrl + Space. But we probably need to experiment with that to see what kind of behavior works best for them. Or maybe provide a user setting for that. The wrong formatting for regular completions is a bug in tabby-agent, I believe. I reported an issue for that at TabbyML/tabby#3330
I haven't used that plugin, but I would guess that it is. I also like how an implementation in IntelliJ works by only presenting a single line instead of multi-line ghost text. They call it "full line completion" and I found this GIF in the docs: This has the advantage that the code doesn't temporarily shift to the bottom when a block phantom is added under the current line. But I'm not sure if this would be possible or easy to do with what is provided in the LSP response. |
There is currently no first-class code local assistant plugin for Sublime-LSP. Github Copilot and Codeium plugins exist but they require a consistent internet connection and use proprietary models.
It would be nice to have good support for a local model. There seems to be some interest in integrating tabby with Sublime-LSP: TabbyML/tabby#219
Unfortunately, I do not know how to build such a plugin. How easy is it to add support or integrate SublimeLSP with a code assistant?
The text was updated successfully, but these errors were encountered: