Build consensus

From pjt222/agent-almanac · View interactive version

Build consensus is an AI agent skill from the GitHub repository pjt222/agent-almanac. Achieve distributed agreement without central authority using bee democracy, threshold voting, and quorum sensing. Covers proposal generation, advocacy dynamics, commitment thresholds, deadlock resolution, and consensus quality assessment. Use when a group must decide between options without a desig

How to use this skill

Skill file

Build Consensus

Collective agreement across distributed agents w/o central authority — scout advocacy, threshold quorum sensing, commit dynamics from honeybee swarm decisions.

Use When

In

Do

Step 1: Generate Proposals — Independent Scouting

Decision space explored before advocacy begins.

  1. Assign scouts to independently explore:
  1. Scouts produce structured assessments:
  1. Aggregate reports w/o filter — all above min quality enter advocacy

→ Independently evaluated proposals w/ scores + assessments. No option eliminated by single evaluator; perspective diversity preserved.

If err: Scouts converge on same option w/o independent eval → scouting not truly independent. Rerun w/ explicit info barriers. Too many survive → raise min threshold. Too few → lower or add scouts.

Step 2: Advocacy Dynamics (Waggle Dance)

Scouts advocate preferred options, intensity proportional to quality.

  1. Each scout advocates top-rated:
  1. Uncommitted observe + evaluate:
  1. Cross-inspection dynamics:
Advocacy Dynamics:
┌─────────────────────────────────────────────────────────┐
│ Scout A advocates Option 1 (quality 85) ──→ ◉◉◉◉◉     │
│ Scout B advocates Option 2 (quality 70) ──→ ◉◉◉        │
│ Scout C advocates Option 3 (quality 45) ──→ ◉           │
│                                                         │
│ Uncommitted agents inspect:                             │
│   Agent D inspects Option 1 → confirms → joins ◉◉◉◉◉◉  │
│   Agent E inspects Option 2 → confirms → joins ◉◉◉◉    │
│   Agent F inspects Option 3 → disagrees → inspects Opt 1│
│                               → confirms → joins ◉◉◉◉◉◉◉│
│                                                         │
│ Over time: Option 1 advocacy grows, Option 3 fades      │
└─────────────────────────────────────────────────────────┘

→ Advocacy for best option(s) grows as agents verify. Weaker fades. Group converges naturally w/o any agent dictating.

If err: No convergence (2 options neck-and-neck) → genuinely equivalent, proceed to quorum w/ either or tiebreaker. Converges too fast on mediocre → increase eval independence (more scouts, stricter barriers) + mandatory cross-inspection.

Step 3: Quorum Threshold + Commit

Commit threshold → collective action.

  1. Set quorum:
  1. Monitor commit accumulation:
  1. Quorum reached:

→ Clear quorum moment, enough agents independently committed. Legitimate because emerged from independent eval, not authority.

If err: Quorum never reached in time → escalate Step 4. Reached but agents unhappy → advocacy too short, committed w/o adequate eval. Wrong consensus (discovered after) → independent scouting insufficient, increase scout diversity + eval thoroughness next cycle.

Step 4: Deadlock Resolution

Break gridlock when natural process stalls.

  1. Diagnose type:
  1. Apply resolution:
  1. After res, reset quorum clock, re-run Step 3

→ Deadlock resolved via intervention. Visible + accepted as fair process even if indiv preferred diff outcome.

If err: Deadlocks recur on same decision → framing wrong. Step back: decomposable into smaller independent decisions? Scope reduction? "Try both and see"? Sometimes best consensus = "time-boxed experiment".

Step 5: Consensus Quality

Eval whether process produced good decision, not just decision.

  1. Post-decision:
  1. Health metrics:
  1. Feed learnings back:

→ Feedback loop improves quality over time. Group learns to scout better, advocate honestly, commit confidently.

If err: Poor metrics (high regret, slow) → audit for structural fails: insufficient scout diversity, advocacy w/o verification, thresholds too low. Rebuild failing stage vs overhauling whole.

Check

Traps

→

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.