diff --git a/src/crewai/utilities/token_counter_callback.py b/src/crewai/utilities/token_counter_callback.py index c5f632d5f5..dc0cef71df 100644 --- a/src/crewai/utilities/token_counter_callback.py +++ b/src/crewai/utilities/token_counter_callback.py @@ -17,7 +17,7 @@ def __init__(self, model_name, token_cost_process): self.token_cost_process = token_cost_process try: self.encoding = tiktoken.encoding_for_model(self.model_name) - except KeyError as e: + except KeyError: self.encoding = tiktoken.get_encoding("cl100k_base") def on_llm_start(