Skip to content

Conversation

@elyasafko
Copy link

This PR adds two new manipulation algorithms for negotiating-team scenarios, based on “Strategic Voting in the Context of Negotiating Teams” (Schmerler & Hazon, 2021):

C-MaNego (algorithm1_single_voter): Single-voter constructive manipulation under any positional scoring rule.
CC-MaNego (algorithm2_coalitional): Coalitional manipulation for x-approval rules.

added:
New module - strategic_voting_algorithms.py
algorithm1_single_voter(F, team_profile, opponent_order, preferred)
algorithm2_coalitional(F, team_profile, opponent_order, preferred, k)
Helpers: _explode_profile, borda, make_x_approval, _rc_result, _compute_Hi, check_validation, etc.

Tests test_algorithms.py
Coverage for both algorithms, including paper’s examples, edge cases (empty input, threshold guards), randomized guards, output-shape invariants, and Profile-based inputs.

References

Paper:
"Strategic Voting in the Context of Negotiating Teams",
Leora Schmerler & Noam Hazon (2021) – https://arxiv.org/abs/2107.14097

elyasafko added 24 commits May 19, 2025 13:51
Implemented algorithms for strategic voting decision-making, including single-voter and coalitional manipulation. Added unit tests to validate functionality. Initialized project settings and Git integration with configuration files.
This commit introduces a new `.idea/misc.xml` file to the repository. It specifies project settings, including the use of Python 3.12 as the SDK. This helps ensure consistent development environment configurations.
Replaced print statements with logging for better traceability and debugging. Adjusted log levels for message clarity and transitioned to outputting warnings for critical checks. Removed outdated comments and redundant documentation for improved code readability."
Enhanced existing docstrings with examples to clarify usage and behavior of functions like `_pos`, `_top_i`, `_compute_Hi`, and `check_validation`. This improvement aids in understanding and testing the code more effectively.
Added a detailed module docstring describing strategic voting algorithms based on recent research. Updated project configuration to use Python 3.12 SDK, ensuring compatibility and standardization.
git merge upstream/main
update git
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.

1 participant