Skip to content

Commit

Permalink
fix: only print 'cache saved' in verbose mode (abetlen#1668)
Browse files Browse the repository at this point in the history
Co-authored-by: Andrei <[email protected]>
  • Loading branch information
lsorber and abetlen authored Aug 12, 2024
1 parent 95a1533 commit 9bab46f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion llama_cpp/llama.py
Original file line number Diff line number Diff line change
Expand Up @@ -1523,7 +1523,8 @@ def logit_bias_processor(
if self.verbose:
print("Llama._create_completion: cache save", file=sys.stderr)
self.cache[prompt_tokens + completion_tokens] = self.save_state()
print("Llama._create_completion: cache saved", file=sys.stderr)
if self.verbose:
print("Llama._create_completion: cache saved", file=sys.stderr)
return

if self.cache:
Expand Down

0 comments on commit 9bab46f

Please sign in to comment.