mirror of
https://gitlab.com/niansa/libjustlm.git
synced 2025-03-06 20:49:17 +01:00
Fixed exception if pre_tick is nullptr
This commit is contained in:
parent
7cd3899dd0
commit
907cea7f9d
3 changed files with 3 additions and 3 deletions
|
@ -196,7 +196,7 @@ public:
|
|||
state->prompt.append(str);
|
||||
fres.append(str);
|
||||
|
||||
if (on_tick && !pre_tick(str.data())) abort = true;
|
||||
if (pre_tick && !pre_tick(str.data())) abort = true;
|
||||
else {
|
||||
// Evaluate token
|
||||
// TODO: Respect batch size
|
||||
|
|
|
@ -238,7 +238,7 @@ public:
|
|||
fres.append(str);
|
||||
|
||||
// Tick
|
||||
if (on_tick && !pre_tick(str.data())) abort = true;
|
||||
if (pre_tick && !pre_tick(str.data())) abort = true;
|
||||
else {
|
||||
// Evaluate token
|
||||
// TODO: Respect batch size
|
||||
|
|
|
@ -212,7 +212,7 @@ public:
|
|||
state->prompt.append(str);
|
||||
|
||||
// Tick
|
||||
if (on_tick && !pre_tick(str.data())) abort = true;
|
||||
if (pre_tick && !pre_tick(str.data())) abort = true;
|
||||
else {
|
||||
// Evaluate token
|
||||
// TODO: Respect batch size
|
||||
|
|
Loading…
Add table
Reference in a new issue