Detachable Session Lifecycle

Ghost Sessions

Run AI agents in detached sessions that persist after you close your terminal. Attach and detach on demand, inspect session state, and manage lifecycle with familiar commands.

Session states

Every nono session has two orthogonal state dimensions: a lifecycle state (running, paused, or exited) and an attachment state (attached or detached). A session can be running and detached, meaning the agent continues working while no terminal is connected.

Core Commands

nono psList sessions
nono attach <id>Connect terminal
nono detach <id>Drop terminal
nono stop <id>Terminate session
nono inspect <id>Session metadata
nono pruneClean old records

Security Model

  • Local-only and same-user only access
  • Private session registry directory
  • Owner-only socket permissions
  • Kernel peer-credential checks
starting sessions
# Start attached (default)
nono run --profile claude-code --allow-cwd -- claude
# Start detached — runs in background
nono run --detached --profile claude-code --allow-cwd -- claude
# Output: Started detached session [id]. Attach with: nono attach [id]
listing sessions
# List running sessions
nono ps
# Include exited sessions
nono ps --all
# JSON output for scripting
nono ps --json
attach / detach
# Attach to a running session
nono attach a3f7c2
# Detach from CLI
nono detach a3f7c2
# Detach from inside the terminal
# Press: Ctrl-] d (configurable)
inspecting sessions
# View session metadata
nono inspect a3f7c2
# JSON output
nono inspect a3f7c2 --json
stopping sessions
# Graceful stop
nono stop a3f7c2
# Custom timeout (seconds)
nono stop a3f7c2 --timeout 15
# Force stop
nono stop a3f7c2 --force
pruning sessions
# Preview what would be removed
nono prune --dry-run
# Remove sessions older than 7 days
nono prune --older-than 7
# Keep only the 20 most recent
nono prune --keep 20
config.toml
# ~/.config/nono/config.toml
[ui]
detach_sequence = "ctrl-] d"

Detach sequence

The default detach sequence is Ctrl-] d, configurable in ~/.config/nono/config.toml. Supported tokens include single characters, named keys (esc, tab, enter, space), and control chords. A minimum of two key presses is required.

See the session lifecycle docs for full details.

Get started with nono

Runtime safety infrastructure that works on macOS, Linux, Windows, and in CI.