Skip to content

Commit 3294036

Browse files
committed
fix gemma3-cli
1 parent 5e6a6d4 commit 3294036

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/llava/gemma3-cli.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ static int eval_text(gemma3_context & ctx, std::string input, bool logits_last =
9393
llama_batch_ext_clear(ctx.batch.get());
9494
for (llama_token & t : tokens) {
9595
llama_seq_id seq_id = 0;
96-
llama_batch_ext_add_text(ctx.batch.get(), t, 0, &seq_id, 1, false);
96+
llama_batch_ext_add_text(ctx.batch.get(), t, ctx.n_past++, &seq_id, 1, false);
9797
}
9898
if (logits_last) {
9999
llama_batch_ext_set_output_last(ctx.batch.get());

0 commit comments

Comments
 (0)