Fix increase_usage of total_price in agent_runner (#6688)

pull/6939/head
Pedro Gomes 2 years ago committed by GitHub
parent 79715345ef
commit 20d3e1d297
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -79,6 +79,7 @@ class CotAgentRunner(BaseAgentRunner, ABC):
llm_usage.completion_tokens += usage.completion_tokens
llm_usage.prompt_price += usage.prompt_price
llm_usage.completion_price += usage.completion_price
llm_usage.total_price += usage.total_price
model_instance = self.model_instance

@ -62,6 +62,7 @@ class FunctionCallAgentRunner(BaseAgentRunner):
llm_usage.completion_tokens += usage.completion_tokens
llm_usage.prompt_price += usage.prompt_price
llm_usage.completion_price += usage.completion_price
llm_usage.total_price += usage.total_price
model_instance = self.model_instance

Loading…
Cancel
Save