intitni / intitni/CustomSuggestionServiceForCopilotForXcode

Using Qwen2.5-Coder with LM Studio

Aberta
#18 6 comentários 0 reações 0 responsáveis Ver no GitHub
Linguagem predominante
Swift
Estrelas
88
Forks
12
Métricas de merge de PRs
Nenhum PR com merge em 30d

Descrição

I am trying to setup code completion with the Qwen2.5-Coder models. I have tested different model versions and different settings for "Request Strategy" but it is not working well. Either the configuration is not compatible with LM Studio or otherwise the model responds with `` or `` most times. So the model tries to use format tags.

The best configuration for Qwen would be the "Naive" setting as the models are trained for this situation.
source: https://github.com/QwenLM/Qwen2.5-Coder?tab=readme-ov-file#1-basic-usage
However it is not working because LM Studio doesn't accept an empty system prompt like this:
```
{
"role": "system",
"content": ""
},
```
Maybe there could be a new option added to set a custom system prompt or to remove this empty message.

The Qwen2.5-Coder models are also trained for fill in the middle. This is the prompt format:
```
prompt = '<|fim_prefix|>' + prefix_code + '<|fim_suffix|>' + suffix_code + '<|fim_middle|>'
```
source: https://github.com/QwenLM/Qwen2.5-Coder?tab=readme-ov-file#3-file-level-code-completion-fill-in-the-middle
I did put the following in the 'FIM Template' text field but I am still getting responses like ``.
```
<|fim_prefix|> {prefix} <|fim_suffix|> {suffix} <|fim_middle|>
```
Maybe there is a conflict with the given system prompt which instructs to use other strings. The fill in the middle setting without system prompt is not working for the same reason as the "Naive" setting.

Guia de contribuição

Nenhum guia de contribuição indexado para este repositório

Direção de pesquisa

Comece rastreando como o app Swift lida com Request Strategy, o FIM Template e system messages; o payload não nomeia nenhum arquivo ou teste. Compare os caminhos de requisição Naive e FIM com a restrição do LM Studio sobre empty system messages e considere concluído o comportamento solicitado de configuração do prompt quando as requisições do Qwen2.5-Coder não produzirem mais format tags.

Escrita pelo modelo de indexação a partir do texto da issue.

Avaliação

Stack de tecnologia
swift
Domínio
ai, developer-experience
Tipo de issue
Funcionalidade
Dificuldade
4/5
Tempo estimado
3-5 dias
Status de atividade
Estagnada
Clareza
Razoavelmente clara
Facilidade para iniciantes
35/100

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.