sourcegraph / cody

Type less, code more: Cody is an AI code assistant that uses advanced search and codebase context to help you write and fix code.
https://cody.dev
Apache License 2.0
2.59k stars 275 forks source link

Issue using code edit ( alt+k ) feature with ollama. #5484

Open h2210316651 opened 4 weeks ago

h2210316651 commented 4 weeks ago

I have tried using ollama for the code edit feature ( alt + k ). But under the models there's only Claude, openai & google LLMs etc. No option could be visible found to select ollama as a provider for code edits.

abeatrix commented 4 weeks ago

@h2210316651 Are you on the latest version of Cody?

In the latest version the Ollama models are showing up in the Edit models for me:

image

If you are on the latest version, can you try closing VS Code, and make sure Ollama is running, before opening VS Code again and see if that works?

h2210316651 commented 4 weeks ago

Hey @abeatrix, Thanks for your quick reply. I think have actually found a bug. When vs code launches and there is no active internet connection even the local ollama fallback is not working. I suppose the extension is making network calls before initialisation. Could you please check if the behaviour can be replicated?

abeatrix commented 3 weeks ago

@h2210316651 Hmm, I can't reproduce it on my side. The model list are still being pulled for me when i am in offline mode. I wonder if this is a version issue. Which Cody version are you currently on to make sure I am on the right track? It'd also be very helpful if you can provide us with detailed steps to replicate the issue 🙇‍♀️