Skip to content
SDK Module

HiveCouncil

The primary interface for multi-model orchestration. HiveCouncil manages the deliberation cycle across different LLM providers to reach verified consensus.

Constructor Options

PropertyTypeDescription
apiKeystringYour AGI-HIVE API key.
modelsstring[]Default models for deliberation.
evidenceChainbooleanWhether to enable cryptographic chaining. Defaults to true.
requireConsensusbooleanIf true, deliberate() throws if consensus fails.

Method: deliberate()

Initiates a council session across multiple models.

typescript
1const result = await hive.deliberate({
2 question: "Evaluate the security implications of autonomous agents using blake3 for hashing.",
3 models: ['claude-3-opus', 'gpt-4-turbo'],
4 requireConsensus: true,
5 consensusThreshold: 0.7
6});

Return Object

typescript
1interface CouncilResult {
2 consensus: string; // The agreed-upon analysis
3 confidence: number; // Consensus score (0.0 to 1.0)
4 evidenceHash: string; // BLAKE3 hash of the deliberation
5 modelResponses: {
6 model: string;
7 response: string;
8 score: number;
9 }[];
10}

Code Example

typescript
1import { HiveCouncil } from '@murkworks/hive-sdk';
2
3const hive = new HiveCouncil({
4 apiKey: process.env.HIVE_API_KEY,
5 models: ['claude-3-sonnet']
6});
7
8async function runSecurityAudit() {
9 try {
10 const audit = await hive.deliberate({
11 question: "Is the current blake3 implementation in src/lib/ RSI-compliant?",
12 models: ['claude-3-opus', 'gpt-4o']
13 });
14
15 console.log(`Audit completed with ${audit.confidence * 100}% confidence.`);
16 console.log(`Evidence: ${audit.evidenceHash}`);
17 } catch (error) {
18 console.error("Deliberation failed:", error.message);
19 }
20}

Last updated: April 2026