Closed FredericoPerimLopes closed 4 months ago
Hi @FredericoPerimLopes, sorry for the late reply. I'm not convinced of the need for this PR as LlamaCpp supports OpenAI-style API.
Is there value in supporting the "native" llamacpp API?
Ok here's why I think this is necessary.
/completion
endpoint (as opposed to /v1/completions
for the OAI models).response.choices
, so you get the first item of the choices array.response.content
.So it seems like the easiest option is to either create a separate llama.cpp backend adapter, or create an additional config option for something like llama.cpp_response = True
so that it uses the OpenAI adapter, but gets the completion from response.content
instead of response.choices
.
The end result of all this is I'm able to make a request to the llama.cpp server but none of the suggestion shows in VSCode.
would be cool imo!
Closing in favor of https://github.com/huggingface/llm-ls/pull/94
@FredericoPerimLopes thank you for your contribution, I added you as co-author on the commit that landed in main
Add Llamacpp support