1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
//! # HOLOS — a fast, dependency-free Hyperdimensional Computing (HDC / VSA) engine.
//!
//! HDC represents information as very high-dimensional vectors (~10,000-D) and computes
//! with three cheap algebraic operations plus an associative memory:
//!
//! - **bind** (`⊗`): associate two hypervectors (XOR) — invertible, result orthogonal to both.
//! - **bundle** (`⊕`): superpose several (majority) — result similar to all of them.
//! - **permute** (`ρ`): rotate — encode order / sequences.
//! - **cleanup**: nearest-neighbor search over an [`ItemMemory`] to decode a noisy result.
//!
//! The flagship [`Hypervector`] uses the **BSC** (Binary Spatter Code) model, bit-packed into
//! `u64` words so operations become XOR + hardware popcount — very fast and cache-friendly.
//! A bipolar [`map::MapVector`] model is also provided for tasks that favor linear bundling.
//!
//! ```
//! use holos_core::{Hypervector, Rng};
//! let mut rng = Rng::new(42);
//! let d = 10_000;
//! let role = Hypervector::random(d, &mut rng);
//! let value = Hypervector::random(d, &mut rng);
//! let bound = role.bind(&value); // associate role↔value
//! assert!(bound.bind(&role).similarity(&value) > 0.99); // unbind recovers value
//! ```
pub use ;
pub use Classifier;
pub use LevelEncoder;
pub use ItemMemory;
pub use Rng;