mirror of
https://github.com/ikawrakow/ik_llama.cpp.git
synced 2026-04-27 09:53:40 +00:00
Make string ban more robust and add regex ban (#1243)
* Test new ctx_sampling->n_rewind system * CRLF quickfix * Adaptive p check * merge banned_n * Fix attempt 1 * Fix attempt 2
This commit is contained in:
@@ -81,7 +81,7 @@ struct server_slot {
|
||||
bool stopped_eos = false;
|
||||
bool stopped_word = false;
|
||||
bool stopped_limit = false;
|
||||
|
||||
bool saturate_predict = false;
|
||||
bool oaicompat = false;
|
||||
|
||||
std::string oaicompat_model;
|
||||
@@ -91,12 +91,16 @@ struct server_slot {
|
||||
// For context rewind/ token buffer
|
||||
size_t n_buffer = 0;
|
||||
int32_t rewind_count = 0;
|
||||
int32_t rewind_count_max = -1;
|
||||
bool rewind_status = false;
|
||||
std::unordered_map<llama_token, float> logit_bias;
|
||||
std::vector<std::string>ban_phrases;
|
||||
std::vector<std::string> ban_phrases;
|
||||
std::vector<std::string> ban_regex;
|
||||
std::vector<std::string> ban_regex_ci;
|
||||
completion_token_outputs token_buffer;
|
||||
float ban_phrases_bias = 0;
|
||||
int32_t banned_n = 1;
|
||||
std::map<int32_t, std::set<llama_token>> positional_bans;
|
||||
|
||||
server_prompt server_cached_prompt;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user