utils/collapse/collapse_utils library
Message collapsing/grouping utilities for read, search, bash, hook, background bash, and teammate shutdown operations.
Ported from:
- neomage/src/utils/collapseReadSearch.ts (1109 LOC)
- neomage/src/utils/collapseBackgroundBashNotifications.ts (84 LOC)
- neomage/src/utils/collapseHookSummaries.ts (59 LOC)
- neomage/src/utils/collapseTeammateShutdowns.ts (55 LOC)
Provides functions to collapse consecutive search/read/bash tool uses into summary groups, collapse hook summaries, background bash notifications, and teammate shutdown messages.
Classes
- AttachmentData
- Simplified attachment data.
- CollapsedReadSearchGroup
- A collapsed group of read/search operations.
- CollapseUtils
- Manages message collapsing and grouping logic.
- DetectedBranch
- A detected git branch operation.
- DetectedCommit
- A detected git commit.
- DetectedPr
- A detected PR operation.
- DetectedPush
- A detected git push.
- MessageData
- Simplified message data.
- RenderableMessage
- A simplified renderable message for collapse processing.
- SearchOrReadResult
- Result of checking if a tool use is a search or read operation.
- StopHookInfo
- Information about a hook that was stopped.
Enums
- BranchAction
- Git branch action detected.
- CommitKind
- Kind of git commit detected.
- PrAction
- Git PR action detected.
Constants
- backgroundBashSummaryPrefix → const String
- bashToolName → const String
- fileEditToolName → const String
- fileWriteToolName → const String
- replToolName → const String
- statusTag → const String
- summaryTag → const String
- taskNotificationTag → const String
- toolSearchToolName → const String