consensus
Installation
SKILL.md
consensus
Apply self-consistency to a structured prompt: run it N times, parse each output as JSON, fuzzy-match findings across passes, keep only what converges.
The vote is deterministic — a Python script consolidates the JSON outputs without any LLM judge. The schema and vote key are agreed upfront and cached, so repeat invocations on the same prompt skip the schema-design step.
Arguments
<prompt>(positional, required): the structured prompt. Must describe a task whose output can be a JSON list/object (findings, extractions, classifications). Free-form text generation is not supported — the vote needs structure.--passes N(optional, default3): how many times to run the prompt. Must be ≥2.--threshold M(optional, defaultceil(N/2)): minimum votes for a finding to be retained. Must satisfy1 ≤ M ≤ N.--force-fresh(optional flag): bypass the schema cache and re-derive the schema from scratch.
Step 0: Validate inputs
PASSES=${PASSES:-3}
THRESHOLD=${THRESHOLD:-$(( (PASSES + 1) / 2 ))}