Not really because you're not building a database or GUI app where using native elements & data structures help a lot with memory pressure.
TUI renderer is the one using the memory heavily so your terminal takes the heavy lifing. If you're managing the buffers and out-of-screen context good enough, Typescript can be pretty efficient.
I love opencode but it chews through memory on my 64gb MacBook Pro. Can’t have too many long running sessions because the memory use just slowly creeps up.
It’s not about the terminal at all which as you noted accounts for minimal isage. It’s all the internal chat and history and everything else the agent tracks - all of which are smallish (and largish) strings allocated on the heap.
I don’t have the same issues with rust based tuis.
TUI renderer is the one using the memory heavily so your terminal takes the heavy lifing. If you're managing the buffers and out-of-screen context good enough, Typescript can be pretty efficient.