Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
quorum-rs
Rust SDK and CLI for multi-agent deliberation systems — agents that propose, evaluate, and reach quorum on outcomes over a NATS-based orchestration protocol. Library and binary ship in the same crate.
Install
As a library:
[]
= "0.6"
As the quorum CLI (run, status, trace, tui, init):
Default features build the binary (cli + tui). To use as a pure library and skip the CLI deps (clap, ratatui, etc.):
[]
= { = "0.6", = false, = ["audit"] }
MSRV: Rust 1.85 (uses Edition 2024).
CLI quick reference
quorum init Bootstrap an `nsed.yaml` workspace config
quorum redeem <code> Redeem a JWT invite — writes ~/.nsed/operator.token
and (for unified codes) ~/.nsed/agent.creds + .seed
quorum serve Run an agent fleet from agent.yml. Reads creds
from ~/.nsed/agent.creds (default)
quorum run <task> Submit a deliberation task to the orchestrator
quorum status Health check + agent status
quorum trace <job_id> Show a deliberation trace (verdict + evaluations)
quorum tui Interactive terminal UI (live deliberation view)
run, status, trace, tui read ./nsed.yaml by default (--config <path> to override).
serve reads ./agent.yml by default.
What's inside
| Module | Key types | Purpose |
|---|---|---|
agents |
NsedAgent, AgentContext, Proposal, Evaluation, ChatCapable, OutputLeakDetector |
Agent trait + deliberation data structures + pluggable output guard |
agents::config |
AgentConfig, TaskPrecision |
Agent configuration (model, provider, limits) |
providers |
ProviderFactory, ProviderRegistry, cli_base |
Dispatch registry mapping provider.type → agent factory (register custom providers without forking); cli_base shares exec/mcp subprocess spawn + timeout helpers |
llms |
AiModel, RequestConfig, SimpleOpenAIModel, OpenAICompatibleModel, RateLimiter |
LLM abstraction + production streaming client + simulator / stub for tests |
prompts |
PromptSet, DefaultPromptSet |
Prompt template interface + benchmark-validated default proposer/evaluator templates |
tools |
Tool, ToolDefinition, ScopedGrepTool, ScopedReadFileTool |
Tool-use interface (OpenAI function calling) + sandboxed filesystem tools |
workers |
NatsNsedWorker, WorkerConfig, NatsScratchpadStore, WorkerHook, UserToolHandlerFactory |
NATS JetStream worker runtime |
middleware |
AgentMiddleware, MiddlewarePipeline, MiddlewareConfig, RuleBasedMiddleware, LlmModerationMiddleware, BinaryMiddleware, DylibMiddleware |
Pluggable validation/moderation + YAML config + external-process dispatch |
status |
AgentStatusSnapshot, SharedAgentStatus, server, multi_server |
Real-time status types + optional HTTP dashboard (feature status-server) |
nats_utils |
connect_nats, sanitize_subject_component, NatsAuth |
NATS helpers + authentication |
telemetry |
TelemetryEvent, TelemetryConfig, TelemetryEmitter |
Per-agent telemetry event catalog |
Quick start — build a custom agent
use ;
use SimpleOpenAIModel;
use ;
use async_trait;
use Result;
async
Use the reference agent
If you want the full ReAct loop, structured proposer/evaluator outputs, retry + repair, tool injection, and benchmark-validated prompts, use ProposerEvaluatorAgent instead of implementing NsedAgent from scratch:
use ;
use OpenAICompatibleModel;
use DefaultPromptSet;
use ;
# async
Pre-built agent shells
For agents you don't write in Rust:
| Type | Use when |
|---|---|
ExecAgent |
The agent is a process you exec (any language); deliberation I/O via stdin/stdout JSON |
McpAgent / ClaudeAgent |
The agent is an MCP server (Claude Code, generic MCP) wrapped via the SDK runtime |
Features
default = ["audit"]audit— enables cryptographic signing of agent outputs viaquorum-crypto-corestatus-server— embedded axum dashboard for live agent + fleet status (HTTP)
Sister crates
Part of the quorum-rs workspace:
llm-repair— JSON-repair / markdown-extraction / tool-call recovery for malformed LLM outputquorum-crypto-core— ed25519 / secp256k1 / SHA3 + audit envelope (used by theauditfeature)
License
Dual-licensed under either:
- Apache License, Version 2.0 (LICENSE-APACHE or https://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or https://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.