79e9fd82c5
When parentAgent is undefined, omit the agent field entirely from session.prompt body instead of passing undefined. This prevents the OpenCode SDK from falling back to defaultAgent(), which would change the parent session's agent context. Changes: - manager.ts: Build prompt body conditionally, only include agent/model when defined - background-task/tools.ts: Use ctx.agent as primary source for parentAgent (consistent with sisyphus-task) - registerExternalTask: Add parentAgent parameter support - Added tests for agent context preservation scenarios