opencode icon indicating copy to clipboard operation
opencode copied to clipboard

[FEATURE]: /continue command

Open JosXa opened this issue 1 month ago • 8 comments

Feature hasn't been suggested before.

  • [x] I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

It happens frequently that I need to interrupt the agent when I need to check that it isn't about to do something dangerous (giving myself a moment to read up), or opencode crashes and I need to restart. In these situations, I find myself typing "continue" in chat a lot to kick the task off again.

This is kinda annoying, produces unnecessary context, and isn't integrated as nicely as I'd like (e.g. it keeps the "command was interrupted" error in).

A /continue command for this purpose would be great. It could even delete the most recent incomplete message and have the AI start that last command or message from scratch again.

JosXa avatar Dec 06 '25 00:12 JosXa

This issue might be a duplicate or closely related to existing issues. Please check:

  • #2404: headless mode --resume - Requests a --resume flag similar to Claude Code
  • #4801: Print some info when exiting: title, command to resume, usage stats - Requests better session resumption features
  • #4186: "revert message" should place reverted message in the prompt input - Related feature about recovering/continuing from previous actions

These issues all touch on resuming or continuing from where you left off. Feel free to ignore if your /continue command proposal addresses these in a different way.

github-actions[bot] avatar Dec 06 '25 00:12 github-actions[bot]

You can just type "Continue." or even make yourself a custom slash command for /continue. Doesn't seem like it really needs any changes in the code to do this... personally I just have a key on my keyboard that types "Continue.".

ariane-emory avatar Dec 06 '25 01:12 ariane-emory

You can just type "Continue." or even make yourself a custom slash command for /continue. Doesn't seem like it really needs any changes in the code to do this... personally I just have a key on my keyboard that types "Continue.".

Sure, I get it. It does mess with the dialog though. When the agent was just going to send one more message and stop, now it will "continue" the original plan further.

JosXa avatar Dec 06 '25 10:12 JosXa

u said it crashes? Never had that happen and very worrying unless you are a windows user because thatd be a bun bug out of our control

rekram1-node avatar Dec 06 '25 17:12 rekram1-node

you want a built in slash command that just says “continue”?

rekram1-node avatar Dec 06 '25 17:12 rekram1-node

Windows. No, it shouldn't send the word "continue", it should prompt the LLM with that conversation again. Thinking about it now, that's possible, right? Like have the last message in the sent conversation be an assistant message and it will keep talking?

JosXa avatar Dec 06 '25 23:12 JosXa

OH I see what you mean, is that the same as doing /undo and then reprompting? It seems somewhat similar..

rekram1-node avatar Dec 07 '25 06:12 rekram1-node

@JosXa Okay, I get what you mean now, there might be advantages to the approach you're describing.

ariane-emory avatar Dec 07 '25 07:12 ariane-emory

/undo and reprompting - sorta, but not quite. That will start with a user message. In Roo Code, you can arbitrarily stop and then continue the autonomous agent. No idea how they implement it.

Basically I'm asking for pause and resume

JosXa avatar Dec 08 '25 02:12 JosXa

Thanks for the work @ariane-emory!!

JosXa avatar Dec 08 '25 02:12 JosXa

@JosXa Thanks! Haven't had the chance to properly test my experiment out yet, hopefully I'll get a chance to do so pretty soon.

ariane-emory avatar Dec 08 '25 02:12 ariane-emory