feat: fork thread multi agent (#12499)

This commit is contained in:
jif-oai
2026-02-26 18:01:53 +00:00
committed by GitHub
parent c53c08f8f9
commit d3603ae5d3
5 changed files with 494 additions and 4 deletions

View File

@@ -495,6 +495,27 @@ impl ThreadManagerState {
.await
}
pub(crate) async fn fork_thread_with_source(
&self,
config: Config,
initial_history: InitialHistory,
agent_control: AgentControl,
session_source: SessionSource,
persist_extended_history: bool,
) -> CodexResult<NewThread> {
self.spawn_thread_with_source(
config,
initial_history,
Arc::clone(&self.auth_manager),
agent_control,
session_source,
Vec::new(),
persist_extended_history,
None,
)
.await
}
/// Spawn a new thread with optional history and register it with the manager.
#[allow(clippy::too_many_arguments)]
pub(crate) async fn spawn_thread(