feat(webui): persist fork boundary metadata

This commit is contained in:
Xubin Ren
2026-06-10 04:26:06 +08:00
parent 03bca4c0a9
commit 73d4b1cb2f
6 changed files with 182 additions and 8 deletions
+2 -2
View File
@@ -648,8 +648,8 @@ class SessionManager:
``before_user_index`` is zero-based over user messages in the full session:
``0`` means "before the first user message", ``1`` means "before the
second user message", and so on. A value equal to the total user-message
count copies the full session prefix. The target user message itself is
not copied; the WebUI pre-fills it in the composer for editing and resend.
count copies the full session prefix. WebUI assistant-reply forks pass
the next user index so the selected completed assistant turn is included.
"""
if before_user_index < 0:
return None