-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Open
Description
- In backend/core/agentpress/context_manager.py
line 1380
I believe
# Recursive call - will handle its own last_usage update
return await self.compress_messages(
result, llm_model, max_tokens,
token_threshold // 2, max_iterations - 1,
compressed_total, system_prompt, thread_id=thread_id
)
must change to
# Recursive call - will handle its own last_usage update
result = await self.compress_messages(
result, llm_model, max_tokens,
token_threshold // 2, max_iterations - 1,
compressed_total, system_prompt, thread_id=thread_id
)
in order to make possible compressed messages to be stored to db in each recursion beacause original_content_by_id is recalculated and loose previous original_content_by_id.
- Also in count_tokens, tool_calls and native tools desctiptions are not calculated.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels