Skip to content

Add option to hide tool call progress messages in chat #243

Description

@juev

Problem

When the agent calls tools (read_file, web_search, exec, etc.), nanobot sends intermediate progress messages to the chat channel (e.g. Telegram). This is hardcoded in agent/loop.py line 201:

if on_progress:
    await on_progress(clean or self._tool_hint(response.tool_calls))

There is no configuration option to disable this behavior. Users who want a clean chat experience (only final responses) cannot suppress these messages.

Proposed Solution

Add a config option, e.g. show_tool_progress: false in config.yaml (or per-channel), that controls whether on_progress is called.

Example:

# config.yaml
assistant:
  show_tool_progress: false  # default: true (current behavior)

In agent/loop.py:

if on_progress and self.config.assistant.show_tool_progress:
    await on_progress(clean or self._tool_hint(response.tool_calls))

Current Workaround

Monkey-patch on_progress callback in a startup hook:

import nanobot.agent.loop as loop
loop.BusAgent._bus_progress = lambda content: None

This works but breaks on package updates.

Environment

  • nanobot-ai 0.1.4
  • Python 3.12
  • Channel: Telegram

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions