Skip to content

fix(memory): pass agent generation settings to consolidation#1825

Closed
IsamAlBalushi wants to merge 3 commits intoHKUDS:mainfrom
IsamAlBalushi:fix/memory-consolidation-config
Closed

fix(memory): pass agent generation settings to consolidation#1825
IsamAlBalushi wants to merge 3 commits intoHKUDS:mainfrom
IsamAlBalushi:fix/memory-consolidation-config

Conversation

@IsamAlBalushi
Copy link
Copy Markdown

@IsamAlBalushi IsamAlBalushi commented Mar 10, 2026

Summary

This passes the active agent generation settings through the memory consolidation path so consolidation uses the same temperature, max_tokens, and reasoning_effort as the main agent loop.

Problem

AgentLoop._consolidate_memory() calls MemoryStore.consolidate() without forwarding these settings. As a result, the provider falls back to default values during consolidation.

Fix

  • add temperature, max_tokens, and reasoning_effort params to MemoryStore.consolidate()
  • forward them from AgentLoop._consolidate_memory()
  • pass them into provider.chat_with_retry(...)

Fixes #1823

Notes

This is a minimal change and keeps existing behavior unchanged outside the memory consolidation path.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 976be443f2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread nanobot/agent/memory.py Outdated
@IsamAlBalushi
Copy link
Copy Markdown
Author

Looks like this was resolved by commit b957dbc which moved generation settings
ownership to the provider layer.

I confirmed locally that memory consolidation now sends the correct
generation parameters. Closing this PR.

@IsamAlBalushi IsamAlBalushi deleted the fix/memory-consolidation-config branch March 11, 2026 10:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Memory consolidation does not inherit agent temperature and maxTokens configuration

1 participant