[Rust Frontend] Require ModelConfig.vocab_size to be present (#45696)

Signed-off-by: Bugen Zhao <i@bugenzhao.com>
This commit is contained in:
Bugen Zhao
2026-06-16 05:30:25 +00:00
committed by GitHub
parent 6607a80dab
commit 259ff891be
8 changed files with 69 additions and 126 deletions
+2 -2
View File
@@ -145,8 +145,8 @@ impl ChatLlm {
self.text.tokenizer_vocab_size()
}
/// Model vocabulary size, else `None`.
pub fn model_vocab_size(&self) -> Option<usize> {
/// Model vocabulary size from the model config.
pub fn model_vocab_size(&self) -> usize {
self.text.model_vocab_size()
}