Fixed context usage calculation
This commit is contained in:
@@ -60,13 +60,15 @@ class WebAgentTest(unittest.TestCase):
|
||||
yield "<reasoning>test reasoning</reasoning>"
|
||||
|
||||
self.mock_llm.infer.side_effect = mock_infer
|
||||
self.mock_llm.token_count.return_value = 100
|
||||
self.mock_llm.token_limit.return_value = 1000
|
||||
|
||||
# Create agent with all components
|
||||
self.agent = WebAgent(
|
||||
system_prompt="test prompt",
|
||||
action_schema="test schema",
|
||||
working_memory=self.working_memory,
|
||||
system_metrics=self.mock_metrics,
|
||||
metrics=self.mock_metrics,
|
||||
llm=self.mock_llm,
|
||||
validator=self.mock_validator,
|
||||
parser=self.parser
|
||||
|
||||
Reference in New Issue
Block a user