opencode
opencode copied to clipboard
fix: rejoin system prompt after plugin hook to preserve caching
Summary
- Fixes system prompt caching when plugins modify
output.system
The caching logic in transform.ts expects exactly 2 system parts. If a plugin pushes additional parts, they won't be cached. This rejoins the array after the plugin hook to maintain the 2-part structure.