From 8874b4d7fe6e48454330a9af91cf9e5d1274ac32 Mon Sep 17 00:00:00 2001 From: richardmilles Date: Mon, 7 Sep 2026 12:04:05 +0200 Subject: [PATCH] docs(agents): use current New session and Edit from here labels --- AGENTS.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index f9183f3ca..4c65edb71 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -133,8 +133,8 @@ hooks/ **Fix**: `send("fork")` captures `newSessionId`, then calls `this.destroy()` before returning. The next request for the original session reloads a clean AgentSession from the original file. ### Two kinds of branching — don't confuse them -- **Fork** (Fork button on user message): creates a new independent `.jsonl` file. Shown as a child in the sidebar tree via `parentSession` header field. -- **In-session branch** (Continue button / BranchNavigator): calls `navigate_tree` within the same file. Multiple entries share the same `parentId`. Switching between them calls `/api/sessions/[id]/context?leafId=`. +- **Fork** ("New session" on user message): creates a new independent `.jsonl` file. Shown as a child in the sidebar tree via `parentSession` header field. +- **In-session branch** ("Edit from here" / BranchNavigator): calls `navigate_tree` within the same file. Multiple entries share the same `parentId`. Switching between them calls `/api/sessions/[id]/context?leafId=`. ### Session files can be fully rewritten `parentSession` in the header is **display metadata only** — has zero effect on chat content. Safe to `writeFileSync` the entire file (pi does this itself during migrations). Used when cascade-reparenting children on delete.