Revert back reset function
This commit is contained in:
parent
9ef8cb5a3e
commit
f853c3eacf
1 changed files with 6 additions and 1 deletions
|
@ -1127,11 +1127,16 @@ static void llama_sampler_k_shift_free(struct llama_sampler * smpl) {
|
||||||
delete (llama_sampler_k_shift *) smpl->ctx;
|
delete (llama_sampler_k_shift *) smpl->ctx;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void llama_sampler_k_shift_reset(struct llama_sampler * smpl) {
|
||||||
|
auto * ctx = (llama_sampler_k_shift *) smpl->ctx;
|
||||||
|
ctx->k_set = false;
|
||||||
|
}
|
||||||
|
|
||||||
static struct llama_sampler_i llama_sampler_k_shift_i = {
|
static struct llama_sampler_i llama_sampler_k_shift_i = {
|
||||||
/* .name = */ llama_sampler_k_shift_name,
|
/* .name = */ llama_sampler_k_shift_name,
|
||||||
/* .accept = */ nullptr,
|
/* .accept = */ nullptr,
|
||||||
/* .apply = */ llama_sampler_k_shift_apply,
|
/* .apply = */ llama_sampler_k_shift_apply,
|
||||||
/* .reset = */ nullptr,
|
/* .reset = */ llama_sampler_k_shift_reset,
|
||||||
/* .clone = */ llama_sampler_k_shift_clone,
|
/* .clone = */ llama_sampler_k_shift_clone,
|
||||||
/* .free = */ llama_sampler_k_shift_free,
|
/* .free = */ llama_sampler_k_shift_free,
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue