]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
tests : refactor test-save-load-state to accept token input (#24073)
authorGeorgi Gerganov <redacted>
Thu, 4 Jun 2026 05:06:36 +0000 (08:06 +0300)
committerGitHub <redacted>
Thu, 4 Jun 2026 05:06:36 +0000 (08:06 +0300)
commit65ef50a0a4bb240211a41d43c957ae6313af6841
tree598c1b453a116239fa969da7c8837e6c1f85ba12
parent3d1998634e62b3a9920ea549c920bfc356ac599e
tests : refactor test-save-load-state to accept token input (#24073)

* tests : refactor test-save-load-state to accept token input

- Default prompt is now empty; when not provided, generate n_batch
  random tokens (useful for models without a tokenizer)
- Tokenization happens once upfront; pass token vector to test functions
- generate_tokens prints token IDs instead of decoded pieces
- Use llama_model_get_vocab / llama_vocab_n_tokens API
- Upgrade log level from LOG_TRC to LOG_INF for visibility

Assisted-by: llama.cpp:local pi
* cont : use llama_tokens alias
tests/test-save-load-state.cpp