mirror of
https://git.adityakumar.xyz/llama.cpp.git
synced 2024-11-09 15:29:43 +00:00
Fix token count accounting
This commit is contained in:
parent
c80e2a8f2a
commit
460c482540
1 changed files with 2 additions and 0 deletions
2
main.cpp
2
main.cpp
|
@ -976,6 +976,8 @@ int main(int argc, char ** argv) {
|
|||
std::vector<gpt_vocab::id> line_inp = ::llama_tokenize(vocab, buf, false);
|
||||
embd_inp.insert(embd_inp.end(), line_inp.begin(), line_inp.end());
|
||||
|
||||
remaining_tokens -= line_inp.size();
|
||||
|
||||
input_noecho = true; // do not echo this again
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue