Skip to content

[Bug] show_members_responses in team.print_response doesn't work #4064

@patsnap-liujin

Description

@patsnap-liujin

Description

using the script in Agno:team session state, the result in console is :

┌─ Message ───────────────────────────────────────────────────────────────────────────────────────────────┐ 
│                                                                                                         │
│ Add milk, eggs, and bread to the shopping list                                                          │
│                                                                                                         │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────┘
┌─ Shopping Management Team Response ─────────────────────────────────────────────────────────────────────┐
│                                                                                                         │
│ The task has been successfully completed: Milk added to the shopping list. If you need any more         │
│ assistance, feel free to ask!                                                                           │
│                                                                                                         │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────┘
┌─ Shopping Management Team Response ─────────────────────────────────────────────────────────────────────┐
│                                                                                                         │
│ The task has been successfully completed.                                                               │
│                                                                                                         │
│ Expected Output: Eggs added to the shopping list.                                                       │
│                                                                                                         │
│ If you need anything else, feel free to ask!                                                            │
│                                                                                                         │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────┘
┌─ Shopping Management Team Response ─────────────────────────────────────────────────────────────────────┐
│                                                                                                         │
│ The task has been successfully completed.                                                               │
│                                                                                                         │
│ Bread has been added to the shopping list.                                                              │
│                                                                                                         │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────┘
┌─ Team Tool Calls ───────────────────────────────────────────────────────────────────────────────────────┐
│                                                                                                         │
│ • transfer_task_to_member(expected_output=Milk added to the shopping list.,                             │
│ member_id=shopping-list-manager,                                                                        │
│   task_description=Add milk to the shopping list.)                                                      │
│                                                                                                         │
│ • transfer_task_to_member(member_id=shopping-list-manager, task_description=Add milk to the shopping    │
│ list.,                                                                                                  │
│   expected_output=Milk added to the shopping list.)                                                     │
│                                                                                                         │
│ • transfer_task_to_member(expected_output=Eggs added to the shopping list.,                             │
│ member_id=shopping-list-manager,                                                                        │
│   task_description=Add eggs to the shopping list.)                                                      │
│                                                                                                         │
│ • transfer_task_to_member(member_id=shopping-list-manager, task_description=Add eggs to the shopping    │
│ list.,                                                                                                  │
│   expected_output=Eggs added to the shopping list.)                                                     │
│                                                                                                         │
│ • transfer_task_to_member(member_id=shopping-list-manager, task_description=Add bread to the shopping   │
│ list.,                                                                                                  │
│   expected_output=Bread added to the shopping list.)                                                    │
│   expected_output=Bread added to the shopping list.)                                                    │ 
│                                                                                                         │ 
│ • add_chore(chore=Added milk, eggs, and bread to the shopping list., priority=high)                     │ 
│                                                                                                         │ 
└─────────────────────────────────────────────────────────────────────────────────────────────────────────┘ 
┌─ Response (32.6s) ──────────────────────────────────────────────────────────────────────────────────────┐ 
│                                                                                                         │ 
│ The task has been successfully completed: Milk added to the shopping list. If you need any more         │ 
│ assistance, feel free to ask!The task has been successfully completed.                                  │ 
│                                                                                                         │ 
│ Expected Output: Eggs added to the shopping list.                                                       │ 
│                                                                                                         │ 
│ If you need anything else, feel free to ask!The task has been successfully completed.                   │ 
│                                                                                                         │ 
│ **Bread has been added to the shopping list.**I have successfully added the following items to the      │ 
│ shopping list:                                                                                          │ 
│                                                                                                         │ 
│  • Milk                                                                                                 │ 
│  • Eggs                                                                                                 │ 
│  • Bread                                                                                                │ 
│                                                                                                         │ 
│ If you need anything else, feel free to ask!                                                            │ 
│                                                                                                         │ 
└─────────────────────────────────────────────────────────────────────────────────────────────────────────┘ 

notice the Response contains every team's response. And it's SAME in Playground .
and I set show_members_responses=False, in shopping_team's defination, nothing change.

Steps to Reproduce

  1. COPY CODE IN https://docs.agno.com/examples/teams/shared_state/team_session_state
  2. RUN IT IN TERMINAL

Agent Configuration (if applicable)

No response

Expected Behavior

the Response is good when stream=False:

┌─ Response (31.2s) ───────────────────────────────────────────────┐ 
│                                                                  │ 
│ The following items have been successfully added to the shopping │ 
│ list:                                                            │ 
│                                                                  │ 
│  • Milk                                                          │ 
│  • Eggs                                                          │ 
│  • Bread                                                         │ 
│                                                                  │ 
│ If you need anything else, feel free to ask!                     │ 
│                                                                  │ 
└──────────────────────────────────────────────────────────────────┘ 

I think it should behavior the same result when stream=True

Actual Behavior

  1. member response occurs:
┌─ Shopping Management Team Response ──────────────────────────────┐ 
│                                                                  │ 
│ Eggs have been added to the shopping list. If you need anything  │ 
│ else, feel free to ask!                                          │ 
│                                                                  │ 
└──────────────────────────────────────────────────────────────────┘
  1. Response contains members':
┌─ Response (32.6s) ──────────────────────────────────────────────────────────────────────────────────────┐ 
│                                                                                                         │ 
│ The task has been successfully completed: Milk added to the shopping list. If you need any more         │ 
│ assistance, feel free to ask!The task has been successfully completed.                                  │ 
│                                                                                                         │ 
│ Expected Output: Eggs added to the shopping list.                                                       │ 
│                                                                                                         │ 
│ If you need anything else, feel free to ask!The task has been successfully completed.                   │ 
│                                                                                                         │ 
│ **Bread has been added to the shopping list.**I have successfully added the following items to the      │ 
│ shopping list:                                                                                          │ 
│                                                                                                         │ 
│  • Milk                                                                                                 │ 
│  • Eggs                                                                                                 │ 
│  • Bread                                                                                                │ 
│                                                                                                         │ 
│ If you need anything else, feel free to ask!                                                            │ 
│                                                                                                         │ 
└─────────────────────────────────────────────────────────────────────────────────────────────────────────┘

Screenshots or Logs (if applicable)

No response

Environment

win 10 | python 3.10.16 |Agno 1.7.7

Possible Solutions (optional)

No response

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions