unflatten_session
Restore a flattened session to its pre-flatten state by reinlining tool results from sidecar files into the session JSONL. Creates a backup snapshot for safety.
Instructions
Reverse a flatten: re-inline every flattened tool result (text and images) back into the session JSONL from its sidecar, restoring the session to its pre-flatten state. Snapshots the flattened file to .preunflatten.bak first.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| session_id | Yes | Session UUID, "last", or "current" (most recent) | |
| project_dir | No | Absolute path to project. Default: the project the CLI runs in (cwd) |