fix: completion prompt template for Deepseek Coder (#387)

* fix: completion prompt template for Deepseek Coder

* Add stop token
This commit is contained in:
squall 2024-02-29 22:23:29 +08:00 committed by GitHub
parent b972078395
commit 20c31de21d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -25,10 +25,10 @@ public enum InfillPromptTemplate {
return format("<fim_prefix>%s<fim_suffix>%s<fim_middle>", prefix, suffix);
}
},
DEEPSEEK_CODER("DeepSeek Coder") {
DEEPSEEK_CODER("DeepSeek Coder", List.of("<|EOT|>")) {
@Override
public String buildPrompt(String prefix, String suffix) {
return format("<|fim_begin|>%s<|fim_hole|>%s<|fim_end|>", prefix, suffix);
return format("<fim▁begin>%s<fim▁hole>%s<fim▁end>", prefix, suffix);
}
};