feat: /fork slash command — fork session from a point in the timeline #297
Labels
No labels
backend
bug
chore
duplication
effort:complex
effort:medium
effort:trivial
enhancement
frontend
fullstack
priority:high
ready-for-agent
refactor
security
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
dries/ocman#297
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of OpenCode command parity (transparent-layer goal). OpenCode's TUI has
/fork(title "Fork session") which branches the conversation into a new child session, optionally from a chosen message in the timeline (DialogForkFromTimeline).Approach: proxy the OpenCode SDK — do NOT reimplement
OpenCode's SDK exposes
sdk.client.session.fork({ sessionID })and a variant that forks from a specific message. Proxy it through the OpenCode adapter (internal/platforms/opencode) and route the mutation via sessionsvc, same pattern as #293 (/undo /redo).Scope
forktoBUILTIN_COMMANDS(frontend/src/lib/commands/builtinCommands.ts).Notes
Forked sessions are OpenCode child sessions — confirm how they surface in ocman's session list and whether the existing parent-id resolution (db.GetSessionParentIDs) already handles them.