feat(vote): add constrained-choice vote deliberation mode (CAC-09 / #3)#49
Merged
Conversation
…ssue #3) - VoteResult model: choices, votes, tally, winner, split - vote: VoteResult | None field on CouncilResult - VOTE_SYSTEM prompt + vote_user() helper; bump SYNTHESIS_PROMPT_VERSION - run_vote() in modes.py: fan-out with word-boundary letter parsing, tally, summary - Council.vote() / vote_sync() with cache support - CLI: --mode vote + --choices flag + _render_vote() rich tally table - cache.make_key() + _cache_key() accept choices for vote mode keying - 21 new tests in tests/test_vote_mode.py covering majority, split, parse edge cases, CLI
Add strict=False to zip() calls in cli.py and modes.py (B905). Auto-sort import blocks in tests/test_vote_mode.py (I001).
ruff format --check was failing on these three files; running ruff format brings them into compliance with the project formatter config.
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.
Summary
votedeliberation mode where each council member answers with a single letter choice (A, B, C, ...) from a constrained setVoteResultmodel (choices, votes, tally, winner, split),run_vote()mode function,Council.vote()/vote_sync(), CLI--mode vote --choices "A,B,C", and rich tally table renderertests/test_vote_mode.py; 489/489 passingTest plan
Closes #3