-
Notifications
You must be signed in to change notification settings - Fork 2
Model ephemeral interactive tool sessions without declaring durable agent services #150
Copy link
Copy link
Open
Labels
area:agent-specAgent Spec format, parsing, and the agent-spec crate · Set: manualAgent Spec format, parsing, and the agent-spec crate · Set: manualarea:ptyPTY sessions and terminal integration · Set: manualPTY sessions and terminal integration · Set: manualorigin:agentFiled or primarily produced by an AI agent · Set: manualFiled or primarily produced by an AI agent · Set: manualstate:open-design-questionUnresolved design choice requiring explicit alignment before implementation · Set: manualUnresolved design choice requiring explicit alignment before implementation · Set: manual
Description
Activity
Metadata
Metadata
Assignees
Labels
area:agent-specAgent Spec format, parsing, and the agent-spec crate · Set: manualAgent Spec format, parsing, and the agent-spec crate · Set: manualarea:ptyPTY sessions and terminal integration · Set: manualPTY sessions and terminal integration · Set: manualorigin:agentFiled or primarily produced by an AI agent · Set: manualFiled or primarily produced by an AI agent · Set: manualstate:open-design-questionUnresolved design choice requiring explicit alignment before implementation · Set: manualUnresolved design choice requiring explicit alignment before implementation · Set: manual
Problem
An agent workspace can need a short-lived interactive terminal for tools such as
lazygit,git add -p, a shell, ortail -f. Fractal should be able to open that terminal beside the agent session.These tools need a pseudo-terminal. They do not need a durable Agent Spec identity, permanent PTY registry entry, supervisor restart, adoption, or reconciliation after they exit.
The current st2 model has declared
ptyservice tasks and terminal-freeexectasks. A declared missing service is reconciled back into existence. That is the wrong lifecycle for an on-demand tool owned by one UI or agent session.Boundary to decide
Decide how Agent Spec and st2 describe or authorize an ephemeral interactive tool without making its runtime instance durable.
The likely split is:
Do not add
lifecycle "once"to declared tasks without resolving the ownership problem. A reconciler cannot infer whether an absent one-shot task has never run or has already completed without adding durable run state.Questions
st2 tasksdistinguish declared service tasks from ephemeral tool instances?Required semantics
spawn_ptyandattach_ptyAPI.lazygit, a long-running log tail, normal exit, owner close, resize, and client crash.Related