2a940de76a93bbbb7d4dd4cb76e5b0ff6bf99a2e
msg.cwd only rides the first message, but OpenCode's system prompt is rebuilt every turn — so turn 2+ reverted to general_chat_sessions and the model fell back to the server's real cwd. Fix: the cwd is bound at creation (metadata.officer.cwd), so for an existing/resumed session read it back (new client.getSession) and reuse it for the system prompt every turn. Also make the prompt explicit that it overrides any other working directory the environment reports. Verified: a session created with a cwd reads the same cwd back on a later turn. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Description
No description provided
42 MiB
Languages
TypeScript
90.9%
Shell
4.7%
JavaScript
4.1%
CSS
0.2%
HTML
0.1%