resolveReasoning
resolveReasoning(
reasonings,args):SlashCommandResult
Defined in: packages/agent/src/modules/slashCommands.ts:1352
TUI-C18 — resolve a /reasoning invocation against the committed turns’ reasoning (in transcript
order, index 0 = turn 1). Pure, so the whole selection + friendly-notice logic is unit-testable
without React:
- no arg → the most recent turn that actually recorded thinking; if none exists, a friendly info notice (nothing to show).
<n>→ turnn(1-based). A non-positive / non-integer / out-of-rangen→ a warn notice; a valid turn that recorded no thinking → an info notice. Otherwise areprintReasoningrequest.
The App renders a reprintReasoning result as a fresh reasoning block (reusing the TUI-C15
styling) and a notice result via the shared CommandNotice.
GS2-88 — undefined is the surface saying it keeps no thinking record, and is answered as
that. It is not the same claim as an empty array, which is a surface that keeps the record and
has nothing in it yet. Collapsing the two is how this command came to tell a plain-session user
with a long conversation behind them that the session had no committed turns.
Parameters
Section titled “Parameters”reasonings
Section titled “reasonings”string[] | undefined
string[]