getcursor / cursor

The AI Code Editor
https://cursor.com
20.69k stars 1.38k forks source link

'Override OpenAI Base URL' Docs? #1289

Open tonydavis629 opened 4 months ago

tonydavis629 commented 4 months ago

This option seems to make it possible to replace openai with another LLM provider. What are the requirements for this alternative? How can we use this? Are there docs anywhere?

I would ideally like to point cursor at a service like cryptotalks.ai that can access multiple LLM service providers, but I'm unsure how this option works. Does the endpoint need to be exactly '/chat/completions'?

truell20 commented 4 months ago

Yep! Needs to correspond exactly to OpenAI's chat completions API.

jakezz commented 4 months ago

Yep! Needs to correspond exactly to OpenAI's chat completions API.

Seriously? How? Groq.com for example has https://api.groq.com/openai/v1/chat/completions but where do we put the API key in Cursor?

tonydavis629 commented 4 months ago

Having the same API doesn't seem to be the only requirement. I'm getting failures from my service at https://cryptotalks.ai/v1 despite having the same API which works normally in the OpenAI clients.