feat: forward skills, agent roles, MCP notes and OpenCode-only instructions
Since the catalog fix in 1.3.3 Claude only received the Code Mode catalog from OpenCode's system prompt. That dropped the skills list, which the skill tool needs for its ids, custom agent prompts such as a writer subagent's rules, MCP server notes, and OpenCode-only instruction files. Forward each of those as its own block, found by its own markers rather than by section order: the skills list, the custom agent's prompt (text before OpenCode's model identity, skipped for OpenCode's stock prompts) labelled as the session's role, the <mcp_instructions> block, and instruction files OpenCode loaded that Claude Code doesn't read itself. A project's AGENTS.md is left to Claude Code, which loads it where there is no CLAUDE.md, and files Claude Code already reads as CLAUDE.md are skipped. The runtime note drops the model and effort, which Claude Code's own prompt already names, and the tool note names the host app. Tested with unit cases for each block and live through opencode run: a writer agent's rules, the skills list without tools, no role for build, and an AGENTS.md-only project read once, by Claude Code.
B
Bohdan Triapitsyn committed
3700f7f3ed9dbf717af1bdcb625a6dfd1b2072a7
Parent: f2c173e