This research models LLM agent context files as a capacitated assortment optimization problem rather than simple append-only logs. It highlights that loaded tokens incur recurring costs per session and that adding instructions does not improve the compliance of existing ones. The authors prove an upper bound on optimal file size and demonstrate that appending every positive instruction degrades performance due to attention capacity limits.
- Context files should be curated, not just appended, to avoid attention degradation.
- Each loaded token incurs a recurring computational cost in every session round.
- Adding new instructions provides no benefit to the compliance of retained ones.
- There is a proven upper bound on optimal context file size regardless of candidates.