Feat/tool card#72
Merged
Merged
Conversation
rusty4444
approved these changes
Jul 7, 2026
rusty4444
left a comment
Owner
There was a problem hiding this comment.
Hermes Agent Automated Review — PR #72
Verdict: APPROVE ✅
Summary
Groups tool execution messages into compact progress cards with emoji indicators. Separates tool messages from the main message list and renders them as card widgets between user/assistant bubbles.
✅ Looks Good
- Clear emoji mapping for common tool types (browser, file, search, shell, reasoning)
- Proper display list construction that interleaves tool cards with messages
- Handles unmatched SSE tool events gracefully (shown at end as separate card)
- Clean
_ToolProgressCardwidget with dark/light theme support - Active tools show spinner; completed tools show checkmark
💡 Suggestions (non-blocking)
_extractToolMessagesuses regexsource="([^"]+)"for tool name discovery — this is fragile and depends on server message format. Consider a more structured approach or a fallback that's clearer when the regex doesn't match.- The
_toolMessageslist is kept in parallel with_messages— ensure indices stay synchronized if the message list is ever filtered/reordered elsewhere.
Reviewed by Hermes Agent — July 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Groups consecutive tool calls into compact emoji cards instead of
rendering individual tool-bubbles. Tool cards appear during streaming
(via SSE
hermes.tool.progressevents) and persist after the responsecompletes. Also filters out empty ghost bubbles left behind during
token-by-token streaming.
Changes
_toolMessages— a separate state list populated during streamingvia SSE tool-progress events. On stream completion (
onDone), servermessages with
role: 'tool'are parsed to extract tool names via_extractToolMessages()._extractToolMessages()— scans the server message list forrole: 'tool'entries. Extracts the tool name from thenamefield,or parses
source="..."from the content (e.g.<untrusted_tool_result source="browser_navigate">)._toolEmoji()— maps tool names to emojis: 🌐 browser, 📄read_file, ✏️ write_file, 🔍 search, 💻 execute, 🧠 think, 🔧 default.
_ToolProgressCard— a compact inline widget showing✅ 🌐 🔍 📄(completed) or
⏳ 🌐 🔍with a spinner (active). Consecutive toolcalls are grouped into separate cards (e.g.
user → 🌐 📄 → assistant → user → 🔍 → assistant).Empty bubble filter — assistant messages with empty content are
excluded from the display list, eliminating phantom bubbles during
streaming.
Real-time streaming — tools from SSE events that arrive during
streaming are shown immediately, before the server response is
complete. Previously they only appeared after
onDoneor on re-entry.