{"version":"2.1.232","anchor":"session-state-moved-off-global-variables-onto-the-session-it","canonical_anchor":"session-state-moved-off-global-variables-onto-the-session-it","heading":"Session state moved off global variables onto the session itself","tier":"internal","area":"Session State","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.232\/e\/session-state-moved-off-global-variables-onto-the-session-it","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.232","markdown":"### Session state moved off global variables onto the session itself\n\nCost, cron, budget and presence state now reset with the session instead of lingering.\n\n**What**\n\nCost accounting, prompt assembly, the request journal, scratch space, cron, turn budget, user presence, surface capabilities and host-side slices are now properties of the live session rather than module-level singletons, so they reset with the session instead of persisting across it.\n\n**Details**\n\n- The mutable holder for the main agent id and session project directory became an identity slice with accessors.\n- No behaviour change was identified.\n\n**Evidence**\n\n`return gr.identity.mainAgentId(gr.id);`\n\n- Area: Session State\n- Tier: Under the hood\n- Useful: 2\/5\n- Signal: 2\/5"}