Skip to content

Commit 57c111f

Browse files
committed
speculative : print draft token pieces
1 parent 062cc26 commit 57c111f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/speculative/speculative.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ int main(int argc, char ** argv) {
241241
llama_sample_softmax(ctx_dft, &cur_p);
242242

243243
for (int i = 0; i < 3; ++i) {
244-
LOG(" - draft candidate %d: %d (%.3f)\n", i, cur_p.data[i].id, cur_p.data[i].p);
244+
LOG(" - draft candidate %3d: %6d (%8.3f) '%s'\n", i, cur_p.data[i].id, cur_p.data[i].p, llama_token_to_piece(ctx_dft, cur_p.data[i].id).c_str());
245245
}
246246

247247
// too low probability, stop drafting

0 commit comments

Comments
 (0)