Repository navigation
Commit a6114e8
committed
improvement(chat): restore stable inline tool activity headers and action summaries
Mothership v1.0.0 reintroduced the "Searching -> Searched -> Searching"
flicker that staging had fixed: between two calls of an open main-agent
activity, the header dropped to the past tense, lost its shimmer, and the
turn-level Thinking row appeared until the next call started. It also removed
the header icon and summarized headers as "<latest title> + N".
Stable in-progress header
- An open main-agent activity group (the streaming turn's tail, with nothing
after its last call) stays in the present tense through the gaps between
its calls, so the header no longer flips tense. Succeeded calls arrive
with past-tense titles, so the open header maps them back through the exact
inverse of the completed-verb rewrite; one helper (getToolInProgressTitle)
serves main lanes, subagent lanes, and the landing hero.
One live indicator per lane
- A new pure module (lane-activity) owns the rule and states it in TSDoc.
Each active lane has one live call: the newest running call anywhere in
the lane (across all its runs, including runs split by a search or an
interaction card, and its nested lanes). With none running and the lane
open, the latest call of its trailing run owns the gap, and only if it
succeeded. A finished search shows static results, so the gap after it
belongs to Thinking.
- Only the run holding that call shimmers: its group header, or its one
search row. Tool rows never shimmer by themselves. A parent lane defers
to a visible nested lane holding the live call only while that lane is
still working; an ended nested lane hands its last call back to the
parent's header.
- Tense follows liveness: a header reads in progress only while it is live
or its call still runs, so a group whose latest call failed or stopped
reads as finished instead of keeping a stale present tense.
- The turn computes this once; every lane view receives its share, and the
Thinking row reads the same result. The main lane spans all main-agent
segments. Thinking shows only when no lane is live and no lane waits on
the user. A lane waiting on an approval, terminal handoff, or browser
takeover shows no indicator, while other lanes doing real work keep theirs.
When the stream finishes, nothing shimmers.
- Rendering and liveness share one run split, and failed subagent lanes no
longer count as working. Only the tail group is open, so a later pending
interaction no longer re-opens earlier finished groups.
Header icons
- Group headers and single inline rows render the icon of the call they
describe again, including integration brand icons, and keep it through
completion. Main and subagent headers share one title rule: "Working…"
while a sim_cli or run_code call generates its arguments, a live wait
countdown, and streaming file-edit titles.
Summaries without "+N"
- Running headers show only the active call. Main and subagent lanes share
one completed-label rule: the model's completedTitle only when every call
succeeded, and otherwise a fallback naming up to three distinct successful
actions ("Navigated, read pages, clicked elements"), picked by first
occurrence in transcript order. Failed calls are
left out, and the " · N stopped/skipped" outcome suffix stays.
- A rebuilt action catalog covers the current tool surface: every visible
catalog tool and operation, plus sim_cli commands. Each command's verb comes
from its own display title, and the object comes from its resource path, so
commands on one resource share a word ("Listed, read tables"). `mkdir`
commands read as creating folders and `tables upsert` as writing table rows.
Tools outside the catalog use their own completed title.
Separate finished activity groups
- groupByActivity still splits main-agent calls by activity id, but no longer
merges finished groups into one header, so the completedGroupCount plumbing
is removed, along with the unused getAgentIcon fallback parameter.
Flat expanded layout
- Indentation now only marks nested work. Expanded tool rows in main and
subagent groups line up with their header: the icon in the shared 14px
icon column, the text one gap-2 to its right. Nested subagent lanes,
narration, lane errors, and the permission card's rows sit on that same
text column through one shared primitive instead of pl-6 or pl-[22px].
- One spacing scale: gap-1.5 between rows inside a group (tool rows, search
queries), gap-3 between blocks in the main lane (tool groups, search runs,
lanes, interaction cards, prose).
Inline links in answers
- A link's favicon is centered on the text's own middle with align-middle,
like inline citation chips, instead of a baseline pixel nudge.
- The link tooltip names the page instead of showing its URL. It uses the
turn's retrieved source for that exact URL, then the link preview's title,
then the site name, with the site name muted beneath. One helper dedupes a
turn's sources by URL everywhere they are listed or looked up.
- Prose links show a thin muted underline on hover instead of a filled
background, and keep the keyboard focus outline.
Verb rewrites
- The past-tense and present-tense verb tables are Maps, because titles
include model-written text, and a description starting with "constructor"
must never resolve to an inherited object property.1 parent 2d0353a commit a6114e8
36 files changed
Lines changed: 3109 additions & 885 deletions
File tree
- apps/sim
- app
- (landing)/components/hero/components/hero-chat-loop
- workspace/[workspaceId]/home/components/message-content
- components
- agent-group
- chat-content
- source-chip
- components/ui
- lib/mothership/tools
Lines changed: 10 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
5 | 8 | | |
6 | 9 | | |
7 | 10 | | |
8 | 11 | | |
9 | 12 | | |
10 | 13 | | |
11 | | - | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
12 | 18 | | |
13 | 19 | | |
14 | 20 | | |
| |||
25 | 31 | | |
26 | 32 | | |
27 | 33 | | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
| 34 | + | |
| 35 | + | |
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
| |||
Lines changed: 146 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
0 commit comments