\documentclass{article}
\usepackage[margin=2cm]{geometry}
\usepackage[style=web]{chatui}

\begin{document}

\section*{chatui: tool-call kinds, JSON results, reasoning modes}

\begin{chatconversation}[chat.example.com]

\begin{chatuser}
Find the repo's largest file and check the weather API.
\end{chatuser}

\begin{chatthinking}[Reasoning][paragraph]
This reasoning trace uses paragraph mode instead of stepped bullets: it
reads as ordinary upright prose, which is easier to skim for a longer
chain of thought than italic arrow-prefixed steps. The user can choose
whichever mode fits the length and style of a given trace.
\end{chatthinking}

\begin{chattool}[ok][cli]{find . -type f -printf '\%s \%p\textbackslash n' | sort -rn | head -1}
\toolresult{48213004 ./data/snapshot.tar}
\end{chattool}

\begin{chatthinking}
\tstep{Now call the weather API and check the JSON payload.}
\end{chatthinking}

\begin{chattool}[ok][code]{get\_weather(city="Austin")}
\toolargs{city="Austin", units="metric"}
\tooljson{\{\\
\quad "city": "Austin",\\
\quad "temp\_c": 34.2,\\
\quad "conditions": "clear"\\
\}}
\end{chattool}

\begin{chattool}[ok]{web\_search}
\toolargs{query="latex chatui package"}
\toolresult{3 results found.}
\end{chattool}

\begin{chatassistant}
The largest file is \texttt{snapshot.tar} (46 MB), and it's currently
34.2\textdegree{}C and clear in Austin.
\end{chatassistant}

\end{chatconversation}

\end{document}
