Skip to content

feat(session): add agent handoff flow#58

Merged
samzong merged 1 commit into
mainfrom
feat/session-handoff
Jun 29, 2026
Merged

feat(session): add agent handoff flow#58
samzong merged 1 commit into
mainfrom
feat/session-handoff

Conversation

@samzong

@samzong samzong commented Jun 29, 2026

Copy link
Copy Markdown
Owner

What's changed?

  • Add recall session handoff for launching a new target-agent session from an indexed transcript.
  • Add a TUI detail-view handoff picker and confirmation flow.
  • Add prompt, target-command, imported-session, and picker-render coverage.

Why

  • Let Recall hand off indexed sessions to supported target agents without requiring native resume support.

Verification

  • rtk proxy make check
  • git diff --check HEAD~1..HEAD

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 383ef52e3b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/session.rs Outdated
}

let command = handoff::command_for_target(target, prompt);
session_action::run(&command, session.directory.as_deref())

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Fall back when imported session cwd is absent

For imported handoffs from another machine, the stored session.directory commonly points to a path that does not exist locally; passing it here makes session_action::run call Command::current_dir unconditionally, so recall session handoff --id ... --to ... fails before starting the target agent. Since handoff is the new path that is allowed for imported sessions, please skip the stored cwd when it is missing (or at least for is_import) and fall back to the current directory.

Useful? React with 👍 / 👎.

Comment thread src/handoff.rs
Signed-off-by: samzong <samzong.lu@gmail.com>
@samzong samzong force-pushed the feat/session-handoff branch from 383ef52 to 4c52974 Compare June 29, 2026 11:56
@samzong

samzong commented Jun 29, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4c52974b7b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/handoff.rs
"claude-code" => ResumeCommand { program: "claude".to_string(), args: vec![prompt] },
"opencode" => ResumeCommand {
program: "opencode".to_string(),
args: vec!["run".to_string(), "-i".to_string(), prompt],

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Drop the unsupported OpenCode -i flag

For the OpenCode target this constructs opencode run -i <prompt>. I checked the OpenCode CLI reference: TUI startup accepts --prompt, while run is documented as opencode run [message..] and its flag table has no -i flag. Selecting OpenCode will therefore fail during argument parsing instead of starting the handoff; build the command with the documented prompt entrypoint instead.

Useful? React with 👍 / 👎.

@samzong samzong merged commit faeecb1 into main Jun 29, 2026
1 check passed
@samzong samzong deleted the feat/session-handoff branch June 29, 2026 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant