Skip to content

Add bidding-based discussion turn-taking - #20

Merged
JuneQQQ merged 1 commit into
mainfrom
feature/bidding-discussion
May 18, 2026
Merged

Add bidding-based discussion turn-taking#20
JuneQQQ merged 1 commit into
mainfrom
feature/bidding-discussion

Conversation

@JuneQQQ

@JuneQQQ JuneQQQ commented May 18, 2026

Copy link
Copy Markdown
Owner

Summary

Implements #19 — bidding-based discussion turn-taking, the highest-value item
from this cycle's competitive research.

Research that motivated it

Google's Werewolf Arena (arXiv:2407.13943) introduced a dynamic turn order
where agents bid to speak instead of following a fixed seating order — it
better mirrors real discussion. deepwolf used fixed seating order; every serious
comparable project has moved past that.

What this adds

  • GameConfig.discussion_mode — validated, "ordered" (default) or "bidding";
    a --bidding flag on simulate and play.
  • engine._speaking_order() collects a bid from each living agent, emits each
    as a public SPEAK_BID event, and seats speakers highest-bid-first (ties by
    seat).
  • Agent.bid() — new concrete method; RandomAgent, LLMAgent and the CLI
    HumanAgent override it. Bilingual prompts; the offline mock handles the new
    bid decision kind.

deepwolf's innovation over the original

Werewolf Arena's bids are an internal mechanism. Here bids are public — a
priority and a reason, emitted as events. An eager bid backed by a thin reason
is itself a tell that other agents and the copilot can read. That fits
deepwolf's "everything is explainable" principle.

Checklist

  • ruff / mypy / pytest (67 tests, 7 new) all pass
  • Default is "ordered" — existing games and English output unchanged
  • CHANGELOG.md and README.md updated

Closes #19

Competitive research turned up Google's Werewolf Arena, whose key idea is a
dynamic turn order where agents bid to speak rather than following fixed
seating. deepwolf now supports the same — with a twist.

- GameConfig gains a validated `discussion_mode` ("ordered" default, or
  "bidding"); a --bidding CLI flag on simulate and play.
- engine.py: _speaking_order collects a bid from every living agent, emits each
  bid as a public SPEAK_BID event, and seats speakers highest-bid-first.
- deepwolf's innovation over Werewolf Arena: bids are public (priority + a
  reason), so an eager bid with a thin reason is a signal other agents and the
  copilot can read — consistent with the project's "everything explainable".
- agents: new concrete Agent.bid; RandomAgent, LLMAgent and HumanAgent override
  it. Bilingual strings; the mock handles the new decision kind.
- 7 new tests. English/ordered output is unchanged.

Closes #19

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@JuneQQQ

JuneQQQ commented May 18, 2026

Copy link
Copy Markdown
Owner Author

Code review (post-merge record).

  • Research-driven and properly attributed: the PR cites Werewolf Arena and adds a genuine deepwolf-specific twist (public bids) rather than copying — exactly the brief. ✅
  • discussion_mode defaults to "ordered"; verified the ordered path emits zero SPEAK_BID events and English output is unchanged, so no existing game shifts. ✅
  • _speaking_order clamps priority to 0-10 and truncates the reason to 200 chars — a rogue/hallucinating bidder can't distort or flood the round. A test covers it. ✅
  • Agent.bid is concrete, so third-party agents need no change; the mock handles the new bid kind so offline games still run. ✅
  • Bids carry both priority and reason in event.data, so the copilot can consume them later (good seam for the follow-up). ✅
  • CI green on 3.10–3.12, 67 tests.

Clean increment. Merged via squash.

@JuneQQQ
JuneQQQ merged commit 37503e3 into main May 18, 2026
4 checks passed
@JuneQQQ
JuneQQQ deleted the feature/bidding-discussion branch May 18, 2026 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bidding-based discussion turn-taking (competitive-research-driven)

1 participant