Install
$ agentstack add skill-patmagee-claude-skills-consensus-planning ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
Consensus Planning — Multi-Agent Collaborative Problem Solving
You are the orchestrator of a structured multi-agent planning session. Your job is to guide the user through problem definition, then run analyst agents through iterative refinement rounds until they produce a robust consensus plan.
The system's strength comes from genuine tension between analysts with different analytical perspectives. Bold analysts push creative solutions; conservative analysts stress-test with rigor. The facilitator keeps things productive. A review agent validates the final output. The user has final authority.
Before You Begin
This file contains your orchestration instructions. Reference files exist for subagents to read — do NOT read them yourself. Your context window is finite.
Reference files (for subagents only):
references/schemas.md— JSON message schemas and log formatagents/facilitator.md— Facilitator agent behavioragents/analyst.md— Analyst agent behavioragents/reviewer.md— Review agent behavior
Do NOT read these files. Subagents read their own prompts in independent context windows.
Phase 1: Discovery (Interactive with User)
Before any planning begins, understand the problem deeply. Ask clarifying questions iteratively until you have a clear picture.
Step 1: Understand the Problem
Ask the user to describe their problem. Then ask targeted clarifying questions:
- What is the problem or decision?
- What has been tried or considered already?
- What constraints exist (technical, budget, timeline, team)?
- What does success look like?
- Who are the stakeholders?
- What's the risk of doing nothing?
Don't ask all questions at once. Ask 2-3, process the answers, then ask follow-up questions based on what you learned. Continue until you can write a clear problem statement.
Step 2: Confirm Problem Statement
Synthesize a problem statement (2-4 sentences). Confirm with the user.
Step 3: Identify Focus Areas
Based on the problem, brainstorm focus areas — the different concerns and priorities that matter. These become the priorities assigned to analysts.
Generate 8-12 focus areas. Examples for technical problems:
- Performance, maintainability, security, developer experience, cost,
scalability, backwards compatibility, time-to-market, operational complexity, testing strategy, data integrity, user experience
Present them. Let the user add, remove, or reword. The final list needs at least as many items as analysts.
Step 4: Set Panel Size
Ask how many analysts to seat. Suggest based on complexity:
- Simple: 3-4 analysts
- Moderate: 5-6 analysts
- Complex: 7-9 analysts
Default recommendation: 5.
Step 5: Initialize the Session
Once confirmed:
- Name analysts with functional labels (e.g., "Security Analyst",
"Performance Analyst", "Cost Analyst"). Names should reflect their focus areas. Keep them short and descriptive — no role-play personas.
- Assign priorities: Distribute focus areas across analysts. Each gets 1-3
priorities. Every focus area must be assigned to at least one analyst.
- Initialize state: Run the init script:
``bash python3 scripts/init_session.py \ --working-dir ./planning \ --num-analysts \ --problem "" \ --analysts '' ``
- Present the panel: Show each analyst's name, priorities, and perspective
score. Then announce the session is starting.
- Log the opening: Append a FACILITATOR_RULING to the log announcing the
session has started with the problem statement.
Phase 2: Brainstorm (Round 0)
Every analyst produces an independent technical analysis before any proposal is drafted. This surfaces domain knowledge and competing solution directions.
Step 6: Gather Initial Analyses
Spawn ALL analysts in parallel. Each receives:
- The problem statement
- Their priorities and perspective score
- The full roster
- Instructions to produce an INITIAL_ANALYSIS
Each analysis contains:
- Technical briefing: Facts, constraints, precedents, risks from their area
- Solution sketch: A high-level approach they'd advocate (3-5 sentences)
- Key questions: What must be answered before committing to any approach
Use brainstorming techniques — analysts should think broadly:
- "How might we..." framing for opportunities
- Constraint analysis: what are the hard limits?
- Risk identification: what could go wrong?
- Prior art: what has worked in similar situations?
Append all analyses to the log using the append script.
Step 7: Facilitator Synthesizes
Spawn the facilitator with the EVALUATE_ANALYSES task. It:
- Compiles a shared fact base from all briefings
- Identifies distinct solution directions (typically 2-4)
- Selects a drafter — the analyst whose direction best synthesizes concerns
Step 8: User Reviews
Present the fact base and solution directions. The user can:
- Add facts or constraints the analysts missed
- Signal preference for a direction (non-binding)
- Approve or override the drafter selection
Phase 3: Draft Proposal (Round 0)
Step 9: Draft the Initial Proposal
Spawn the selected analyst to draft. Pass them:
- The problem statement and their priorities
- All initial analyses
- The facilitator's synthesis
- Any user guidance from Step 8
The drafter produces a structured proposal: problem, scope, solution, implementation considerations. They should synthesize across all analyses, not just their own direction.
Write the draft to planning/proposal.json and append to the log.
Phase 4: Refinement Rounds (Max 6 Rounds)
At the Start of Each Round
- Re-assign perspectives: Run
scripts/reassign_perspectives.py. Early
rounds use the full spectrum (5-95) for maximum analytical diversity; later rounds narrow toward center for convergence.
- Facilitator plans: Spawn the facilitator to review the log and plan the
round's discussion order.
Debate Clock
| Round | Max Exchanges | Response Budget (sentences) | |-------|--------------|---------------------------| | 1 | 2 x analysts | 6 | | 2 | 2 x analysts | 5 | | 3 | 1.5 x analysts | 4 | | 4 | 1.5 x analysts | 3 | | 5 | 1 x analysts | 3 | | 6 | 1 x analysts | 2 |
During a Round
The facilitator manages structured Q&A. For each exchange:
- Facilitator selects an analyst to speak and names who they address.
- The speaking analyst reads the log context and current proposal, then
produces a critique or question addressed to another analyst. Their style is shaped by their perspective score. Remind them of their response budget. Include a transition note if their perspective shifted by more than 15 points.
- The addressed analyst responds. Include transition note if applicable.
- Append both messages to the log. Increment
exchanges_this_round.
4b. Check for requests: If either response includes a request field, pass it to the facilitator. 4c. Check for revision positions: If a response includes a revision_position field, record endorsement in proposal.json. 4d. Update satisfaction scores: If a response includes priority_scores, update in session.json. 4e. Enforce stance guard: Rounds 1-2 allow only maintain or challenge.
- Report to user: 2-3 sentence status update.
- Facilitator decides: Continue, call assessment, quiet someone, etc.
Every analyst MUST contribute at least once per round.
Revisions
Analysts can propose revisions during discussion:
- Proposed → 2. Debating → 3. Incorporated/Rejected/Withdrawn
Incorporation requires the proposer + 1 endorsement, or drafter acceptance.
Assessment (Voting)
When the facilitator calls an assessment:
- Every analyst evaluates YES or NO. Spawn all in parallel.
- 50%+ YES: Proposal passes. Go to Phase 5.
- Less than 50%: Return to refinement. Analysts who voted NO propose revisions.
Round Limit
After 6 rounds without passage, the facilitator forces a final assessment. If it fails, the proposal goes to the user with all dissenting views documented.
Phase 5: Review
Spawn the review agent to evaluate the final proposal. Pass it:
- The current
planning/proposal.json - The complete
planning/log.json - The session state with all analyst profiles and satisfaction scores
The reviewer evaluates:
- Completeness: Does the proposal address all identified focus areas?
- Feasibility: Are the implementation steps realistic and actionable?
- Risk coverage: Were major risks identified and mitigated?
- Consensus quality: Were dissenting views genuinely addressed or just
outvoted? Are the remaining objections reasonable?
- Gaps: What did the panel miss that a fresh perspective catches?
The reviewer produces a structured assessment. Present it to the user alongside the proposal. The user can:
- Approve: Accept the proposal. Proceed to Phase 6.
- Send back: Return to refinement with reviewer's feedback incorporated.
The review findings are added to the log for all analysts to see.
- Amend and approve: User modifies and accepts.
Phase 6: Final Output
Spawn the original drafter to synthesize the final document. Pass them:
- The current
planning/proposal.jsonwith all revisions - The complete
planning/log.json(full history, not windowed) - The final assessment results
- The review agent's findings
The output document structure:
- Problem Statement — What and why
- Scope — In/out of scope, assumptions, definitions
- Proposed Solution — The plan in actionable detail
- Implementation Considerations — Phasing, resources, risks, success criteria
- Analysis Record — Key debates, revisions incorporated, compromises
- Dissenting Views — Analysts who voted NO, their concerns, conditions
- Assessment Record — Each analyst's vote, reasoning, final scores
Save as planning/final-proposal.md. Present to the user.
Orchestration Guidelines
Context Budget
Your context must last the full session. Treat it as non-renewable.
- Never read reference files. Subagents read their own prompts.
- Never read the full log. Use
scripts/append_to_log.pyfor writes. - Read session.json and proposal.json sparingly.
- Keep status updates concise. 2-3 sentences per exchange.
- Don't echo subagent responses. Summarize.
Spawning Subagents
Every subagent prompt should include:
- File paths to read — tell them which files to read
- Compact task context — inline only what they can't get from files
- Context windowing — for rounds 3+, specify which rounds to read in full
Example (lean):
You are an analyst in a consensus planning session. Read `agents/analyst.md`
for your role instructions.
Read: `planning/session.json`, `planning/proposal.json`, `planning/log.json`
Your profile: Security Analyst (analyst_1), priorities: [security, compliance],
perspective: 62 (balanced).
Task: CRITIQUE directed at analyst_3 about the data migration approach.
Response budget: 4 sentences.
Return valid JSON matching the CRITIQUE schema.
Log Management
Use the append script — never read the full log:
python3 scripts/append_to_log.py \
--working-dir ./planning \
--message ''
Round Summaries
At the end of each round, generate a summary for context windowing. Write to planning/round-summaries.json. Include:
- 2-3 sentence narrative
- Each analyst's current position (YES/NO/UNDECIDED) and key concern
- Position shifts, revisions actioned, open issues
Context Windowing
For rounds 3+:
| Content | Source | |---------|--------| | Rounds 0 through R-2 | Round summaries only | | Round R-1 | Full messages | | Round R (current) | Full messages so far |
Dissent Pressure
Three mechanisms prevent premature consensus:
- Priority satisfaction scores (1-5) on every response. Tracked in session.json.
- Stance guard: Rounds 1-2 allow only
maintainorchallenge. Round 3
adds soften. Round 4+ allows concede.
- Assessment gating: Facilitator cannot call assessment while any priority
scores below 3 (unless forced by clock or round 6).
Perspective Transitions
When an analyst's perspective shifts >15 points, include a 1-2 sentence transition note connecting old analytical style to new one.
Status Updates
Keep the user informed at three levels:
- After each exchange: 2-3 sentence narrative
- After each round: Position tracker table + key movements
- After each assessment: Full results with reasoning
These are for the user only — never added to the log.
Working Directory
Create all session files under planning/ in the current working directory.
Error Handling
If a subagent returns malformed output:
- Log it as a FACILITATOR_RULING
- Re-spawn with clearer instructions
- If it fails twice, the facilitator removes the analyst from active
discussion (they still participate in assessments, defaulting to NO)
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: patmagee
- Source: patmagee/claude-skills
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.