interlens.context.sliding_window_policy¶
interlens.context.sliding_window_policy
¶
SlidingWindowPolicy
¶
Bases: ContextPolicy
Keep the preserved framing plus the most recent keep_last turns; drop older turns.
keep_system=True (the default) preserves the system/moderator/private_context framing regardless of the
window; set it False to also let framing fall outside the window (rarely wanted). Unlike DropOldestPolicy
this is a fixed-size window rather than a fit-to-budget trim, so it's predictable turn-to-turn.