#Context lost the next day

1 messages · Page 1 of 1 (latest)

jolly smelt
#

openclaw used to remember conversations in the same telegram topic for many days. Now it seems that there is some message session timeout and if you ask about something in a day or two, it will say that it does not understand what is it about.

how to fix this?

warped forgeBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

abstract vigilBOT
#

This is usually the session reset policy, not Telegram topic routing itself.

Current OpenClaw defaults reset sessions daily around 4am local time unless you override it. For Telegram topics that feels exactly like “it forgot what we talked about yesterday”.

Try setting a longer Telegram session reset window in ~/.openclaw/openclaw.json / JSON5:

{
  session: {
    resetByChannel: {
      telegram: {
        mode: "idle",
        idleMinutes: 10080, // 7 days; use 43200 for 30 days
      },
    },
  },
#
}

Then restart the gateway:

openclaw gateway restart

If you want this only for group/forum topics and not Telegram DMs, use type-specific policy instead:

{
  session: {
    resetByType: {
jolly smelt
#

how do I set this globally?

abstract vigilBOT
#

Set the top-level session.reset policy. That becomes the default for all channels/session types unless session.resetByChannel or session.resetByType overrides it.

In ~/.openclaw/openclaw.json:

{
  session: {
    reset: {
      mode: "idle",
      idleMinutes: 10080, // 7 days
      // 43200 = 30 days
    },
  },
}

Then restart:

#
openclaw gateway restart

If you already have session.resetByChannel or session.resetByType, those can still override the global default, so remove/update them too.

For long retention, I’d also keep maintenance at least as long as your desired memory window:

{
  session: {
    reset: { mode: "idle", idleMinutes: 43200 },
    maintenance: {
      pruneAfter: "60d",
    },
  },