Multi-agent consensus protocol — weave votes into fleet decisions with quorum and veto
Project description
consensus-weave
Multi-agent consensus protocol. Weave separate agent votes into a single fleet decision with quorum thresholds, weighted voting, and veto power.
Usage
from consensus_weave import ConsensusWeave, Vote, VoteType
cw = ConsensusWeave()
cw.propose("deploy-v1", "Deploy to production", quorum=3, threshold=0.6, veto_power={"captain"})
cw.vote("deploy-v1", Vote(agent_id="oracle1", vote=VoteType.AGREE, weight=1.5))
cw.vote("deploy-v1", Vote(agent_id="fm", vote=VoteType.AGREE))
cw.vote("deploy-v1", Vote(agent_id="jc1", vote=VoteType.DISAGREE))
result = cw.resolve("deploy-v1")
# passed=True (2 agree vs 1 disagree, weighted score 2.5/3.5 = 0.71 >= 0.6)
Zero deps. pip install consensus-weave
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
consensus_weave-0.1.0.tar.gz
(3.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file consensus_weave-0.1.0.tar.gz.
File metadata
- Download URL: consensus_weave-0.1.0.tar.gz
- Upload date:
- Size: 3.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9d2362a1943fc385be64e205d15874941e876f08a4fa6d27b1d5de4b0608ed38
|
|
| MD5 |
f67ccca6e96aa619faf8c4e6662c9e8f
|
|
| BLAKE2b-256 |
3e0645a2ade87bf7efa98cbe9bd636d252d17f322854358ed0261182d1b86b69
|
File details
Details for the file consensus_weave-0.1.0-py3-none-any.whl.
File metadata
- Download URL: consensus_weave-0.1.0-py3-none-any.whl
- Upload date:
- Size: 3.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7ebecf809f11573141aebfe964ec55f288e425d45c9e84e41e0836f7b4728485
|
|
| MD5 |
d4ba518404d62fa8414b04fc4178a3dd
|
|
| BLAKE2b-256 |
0342ade4a6409440e26c7f5d5f1b9a160623f1fc64aea82250abab286ee1b983
|