EACI Development Journal · Memory & Context

How Do You Keep Browser Local Memory Under a Size Budget?

Browser persistence needs a measured ceiling and an eviction order. The current message path checks a 50 MB maximum instead of assuming storage is endless.

Memory & Context ~6 min issue-tagged
Issue this fixes

Local history, generated files, media references, and cached state accumulate quietly. Browser quotas vary, private sessions behave differently, and one oversized write can fail the whole save.

The message display path uses a 50 MB ceiling and trims older material before newer conversational state. Size checks happen before serialization is treated as successful.

What was actually going wrong

Local persistence was easy to regard as free because it did not have a visible server bill.

What I tried

What finally worked

Serialized data is measured against a fixed budget, with older low-value content removed first.

Why it worked

A byte budget matches the browser's actual constraint and controlled eviction preserves recent continuity.

What I learned

Every local memory system needs an explicit forgetting policy.

Where EACI uses this today

Main chat protects recent browser state within its local storage budget.

This journal covers real engineering on EACI Companion / The Veil. Companions include Caelum, Chad, Natalia, Atreus, Luna, Roxy, and Cael. Journal articles stay family-safe in content. See Privacy and Ethics.