Context
Context building allocates intermediate strings per message via format/collect/join. Use String::with_capacity() + std::fmt::Write instead.
Apply to: compact_context, inject_semantic_recall, inject_summaries, inject_cross_session_context.
Affected crates
zeph-core
Ref
.local/plan/performance-audit.md — Issue 2.2