Skip to content

feat(subagents): run /btw asides in memory and drop aborted cards (#529) - #530

Open
rhine9473 wants to merge 2 commits into
openpi-dev:mainfrom
rhine9473:feat/btw-ephemeral-session
Open

feat(subagents): run /btw asides in memory and drop aborted cards (#529)#530
rhine9473 wants to merge 2 commits into
openpi-dev:mainfrom
rhine9473:feat/btw-ephemeral-session

Conversation

@rhine9473

Copy link
Copy Markdown

Summary

Fixes #529.

This PR optimizes /btw aside lifecycle and session visibility:

  1. In-Memory Ephemeral Sessions: Spawns /btw child sessions with SessionManager.inMemory(task.cwd) instead of SessionManager.create(task.cwd). /btw asides no
    longer create persistent .jsonl files on disk, preventing the project's /sessions picker from being flooded with temporary asides.
  2. Cleaner Parent Transcript: Aborted or empty /btw runs no longer append failed entries ((no output)) into the parent session transcript.
  3. Legacy Session Filtering: Filters out legacy btw: prefixed sessions from the /sessions picker list.
  4. Unit Tests: Adds unit test asserting that /btw spawns use in-memory sessions without persisting to disk.

Testing

  • node --test --experimental-strip-types tests/extensions/subagents/*.test.ts (180 passed, 0 failed)
  • node --test --experimental-strip-types tests/extensions/sessions/*.test.ts (35 passed, 0 failed)
  • Verified locally in interactive TUI mode: aborted /btw runs no longer leave failure cards, and /sessions list remains clean without transient btw: entries.
  • Biome check verified clean.

@github-actions github-actions Bot added the area:subagents Subagent delegation, skills, or tests label Sep 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:subagents Subagent delegation, skills, or tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(subagents): /btw 临时问答不应在 sessions 历史列表显示,没有进行记录销毁,建议改为“用完即丢”的临时会话

1 participant