Skip to content

Commit b85e4dc

Browse files
committed
[feat][turn-based-groupchat][single speaker bidding per
turn][feat][recency-penalty][discourage same agent monologuing][improvement][extract-decide-prompt][move prompt to prompts folder][improvement][verbose-printing][gate panel output on verbose][docs][groupchat-example][replace example with simpler version]
1 parent dda124e commit b85e4dc

3 files changed

Lines changed: 182 additions & 181 deletions

File tree

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
model_name="gpt-5.5",
99
max_loops=1,
1010
persistent_memory=False,
11-
print_on=True,
1211
output_type="final",
1312
)
1413

@@ -17,7 +16,6 @@
1716
system_prompt="You push back on weak claims and ask sharp questions.",
1817
model_name="claude-haiku-4-5",
1918
max_loops=1,
20-
print_on=True,
2119
persistent_memory=False,
2220
output_type="final",
2321
)
@@ -28,7 +26,6 @@
2826
model_name="gpt-5.5",
2927
max_loops=1,
3028
persistent_memory=False,
31-
print_on=True,
3229
output_type="final",
3330
)
3431

@@ -38,6 +35,7 @@
3835
threshold=0.6,
3936
output_type="dict",
4037
auto_equip=True,
38+
verbose=True,
4139
)
4240

4341
result = chat.run(

swarms/prompts/groupchat_prompt.py

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
GROUPCHAT_DECIDE_PROMPT = """You are {agent_name} in a groupchat with: {other_agents}.
2+
3+
Conversation so far:
4+
{history}
5+
6+
Latest message from {sender}:
7+
{message}
8+
9+
Decide whether to speak. Silence is the default — most messages do NOT warrant
10+
a reply from you. Only respond when you genuinely add value.
11+
12+
Score high (>= 0.7) ONLY if:
13+
- The message is directly in your area of expertise AND you have something
14+
substantive to contribute that nobody else has said.
15+
- You're directly addressed or @-mentioned.
16+
- There's a factual error or weak claim you can sharpen or correct.
17+
- You can move the conversation forward with a concrete next step or question.
18+
19+
Score low (< 0.5) — stay silent — if:
20+
- The topic is outside your expertise.
21+
- Your point would echo or paraphrase something already said.
22+
- You'd only be adding agreement, encouragement, or filler ("great point",
23+
"I agree", "well said").
24+
- The conversation is already converging and you'd just pile on.
25+
- You spoke very recently and have nothing new to add.
26+
27+
Call the `respond` function. If score < 0.5, return an empty message.
28+
Otherwise, give a tight, specific reply — no preamble, no restating others.
29+
"""

0 commit comments

Comments
 (0)