oxios_kernel/coordination.rs
1//! Coordination primitives — multi-agent work distribution and consensus.
2//!
3//! Re-exports oxi-sdk 0.23.0's coordination primitives for use by the
4//! orchestrator and other kernel components.
5//!
6//! # Available Primitives
7//!
8//! - **WorkQueue**: Priority-based atomic task queue with claim/complete lifecycle.
9//! Use for distributing independent subtasks across agents.
10//! - **SharedMemory**: Versioned KV store with optimistic locking.
11//! Use for sharing state between agents in a group.
12//! - **Consensus**: Simple majority/unanimity voting.
13//! Use for evaluation, approval, and decision-making.
14//! - **CoordinatedGroup**: Fan-out, vote, and map-reduce over AgentHandles.
15//! Use for structured multi-agent workflows.
16//!
17//! # Usage
18//!
19//! ```ignore
20//! use oxi_sdk::coordination::{WorkQueue, WorkQueueConfig};
21//!
22//! let queue = WorkQueue::new(WorkQueueConfig::default());
23//! // queue.submit(WorkItem { id: "task-1".into(), .. });
24//! // let item = queue.claim("agent-1");
25//! // queue.complete("task-1", WorkResult { output: "...".into(), success: true });
26//! ```
27
28// Re-exports removed (#11) — use `oxi_sdk::` directly for coordination primitives.
29// The types available: Consensus, CoordinatedGroup, CoordinatedGroupBuilder,
30// GroupResult, MemoryEntry, MemoryEvent, MemoryKey, SharedMemory, VoteResult,
31// WorkEvent, WorkItem, WorkQueue, WorkQueueConfig, WorkQueueStats, WorkResult,
32// WorkStatus.