actrone-memory
    Preparing search index...

    Class RedisL1Store

    Redis-backed hot session store (L1). Turns are stored as a per-session list with a sliding TTL and a capped length, mirroring the Python actrone_memory RedisStore.

    Implements

    Index
    • Claim the right to summarise this session, fleet-wide, via SET key NX EX ttl.

      One atomic command, so the check and the claim cannot interleave across processes. The TTL is never released early, which makes it double as a re-summarisation cooldown. Throws if the injected client exposes no set, rather than pretending to hold a lock.

      Parameters

      • agentId: string
      • sessionId: string
      • ttlSeconds: number

      Returns Promise<boolean>

    • Recent turns, oldest → newest, capped at n (defaults to all retained).

      Parameters

      • agentId: string
      • sessionId: string
      • Optionaln: number

      Returns Promise<Turn[]>

    • Parameters

      • agentId: string
      • sessionId: string

      Returns Promise<number>